1
0
mirror of https://github.com/e107inc/e107.git synced 2025-08-04 21:57:51 +02:00

* A few bug fixes and some code re-org

This commit is contained in:
bugrain
2009-07-15 00:15:01 +00:00
parent 89509d0de8
commit 113ed5f7e7
2 changed files with 354 additions and 387 deletions

View File

@@ -11,8 +11,8 @@
| GNU General Public License (http://gnu.org).
|
| $Source: /cvs_backup/e107_0.8/e107_plugins/download/admin_download.php,v $
| $Revision: 1.1 $
| $Date: 2009-07-14 23:53:02 $
| $Revision: 1.2 $
| $Date: 2009-07-15 00:15:01 $
| $Author: bugrain $
+----------------------------------------------------------------------------+
*/
@@ -253,7 +253,7 @@ if ($action == "create")
}
if ($delete == 'category')
if (isset($delete) && $delete == 'category')
{
if (admin_update($sql->db_Delete('download_category', 'download_category_id='.$del_id), 'delete', DOWLAN_49." #".$del_id." ".DOWLAN_36))
{
@@ -269,7 +269,7 @@ if ($action == 'cat')
}
if ($delete == 'main')
if (isset($delete) && $delete == 'main')
{
$result = $sql->db_Delete('download', 'download_id='.$del_id);
if ($result)
@@ -320,6 +320,7 @@ if ($action == "opt")
if ($action == 'maint')
{
global $pref, $ns;
if (isset($_POST['dl_maint'])) {
switch ($_POST['dl_maint'])
{
case 'duplicates':
@@ -409,11 +410,11 @@ if ($action == 'maint')
$text .= '<td>'.$file['fname'].'</td>';
$text .= '<td>'.$filets.'</td>';
$text .= '<td>'.$filesize.'</td>';
//TODO $text .= '<td>
//TODO <a href="'.e_SELF.'?create.add.'. urlencode($file["fname"]).'">'.E_16_CREATE.'</a>
//TODO <input type="image" title="'.LAN_DELETE.'" name="delete[main_'.$file["fname"].']" src="'.ADMIN_DELETE_ICON_PATH.'" onclick=\'return jsconfirm("'.$tp->toJS(DOWLAN_173.' [ '.$file["fname"].' ]').'") \'/>
//TODO </td>';
//TODO $text .= '</tr>';
//TODO $text .= '<td>
//TODO <a href="'.e_SELF.'?create.add.'. urlencode($file["fname"]).'">'.E_16_CREATE.'</a>
//TODO <input type="image" title="'.LAN_DELETE.'" name="delete[main_'.$file["fname"].']" src="'.ADMIN_DELETE_ICON_PATH.'" onclick=\'return jsconfirm("'.$tp->toJS(DOWLAN_173.' [ '.$file["fname"].' ]').'") \'/>
//TODO </td>';
//TODO $text .= '</tr>';
}
}
if ($foundSome) {
@@ -627,8 +628,9 @@ if ($action == 'maint')
exit();
break;
}
default:
{
}
}
else {
$title = DOWLAN_193;
$text = DOWLAN_179;
$eform = new e_form();
@@ -693,7 +695,6 @@ if ($action == 'maint')
</fieldset>
</form>
";
}
}
$ns->tablerender(DOWLAN_165.$title, $text);
}

View File

@@ -11,8 +11,8 @@
| GNU General Public License (http://gnu.org).
|
| $Source: /cvs_backup/e107_0.8/e107_plugins/download/help.php,v $
| $Revision: 1.2 $
| $Date: 2009-02-11 21:41:54 $
| $Revision: 1.3 $
| $Date: 2009-07-15 00:15:01 $
| $Author: bugrain $
+----------------------------------------------------------------------------+
*/
@@ -23,7 +23,6 @@ if (e_QUERY)
{
$tmp = explode(".", e_QUERY);
$action = $tmp[0];
$subAction = $tmp[1];
}
switch($action) {
@@ -40,42 +39,9 @@ switch($action) {
break;
}
case 'maint' :{
switch($subAction) {
case 'duplicates': {
$text = DOWLAN_HELP_5_1;
break;
}
case 'orphans': {
$text = DOWLAN_HELP_5_2;
break;
}
case 'missing': {
$text = DOWLAN_HELP_5_3;
break;
}
case 'inactive': {
$text = DOWLAN_HELP_5_4;
break;
}
case 'nocategory': {
$text = DOWLAN_HELP_5_5;
break;
}
case 'filesize': {
$text = DOWLAN_HELP_5_6;
break;
}
case 'log': {
$text = DOWLAN_HELP_5_7;
break;
}
default: {
$text = DOWLAN_HELP_5;
break;
}
}
break;
}
case 'limits' :{
$text = DOWLAN_HELP_6;
break;