From 05e3ce5dedd44478c4ca10a788ad5b9544b567e1 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Roland=20H=C3=A4der?= Date: Mon, 2 Aug 2010 20:27:01 +0000 Subject: [PATCH] This is no longer required, see template admin_add_network_api_translation --- DOCS/TODOs.txt | 1 + .../what-list_network_api_translation.php | 25 ++++++++++--------- 2 files changed, 14 insertions(+), 12 deletions(-) diff --git a/DOCS/TODOs.txt b/DOCS/TODOs.txt index 9f954a2177..a150c0e612 100644 --- a/DOCS/TODOs.txt +++ b/DOCS/TODOs.txt @@ -55,6 +55,7 @@ ./inc/language/de.php:810:// @TODO Are these constants longer used? ./inc/language-functions.php:234: // @TODO These are all valid languages, again hard-coded ./inc/language-functions.php:46:// @TODO Rewrite all language constants to this function. +./inc/language/newsletter_de.php:13: * @TODO This language file is completely out-dated, please do no * ./inc/language/rallye_de.php:13: * @TODO Naming convention not applied for language strings * ./inc/language/refback_de.php:46:// @TODO Rewrite these constants to one ./inc/language/sponsor_de.php:119:// @TODO Rewrite these four constants to one and use sprintf() diff --git a/inc/modules/admin/what-list_network_api_translation.php b/inc/modules/admin/what-list_network_api_translation.php index 3f3fa689a4..97f0a622f3 100644 --- a/inc/modules/admin/what-list_network_api_translation.php +++ b/inc/modules/admin/what-list_network_api_translation.php @@ -68,17 +68,19 @@ if (isGetRequestParameterSet('network')) { // Get its data for template $networkData = getNetworkDataById(getRequestParameter('network')); - // Is a network type selected? - if (!isGetRequestParameterSet('network_type')) { - // Then present a new selection form - outputHtml(generateAdminNetworkTypeList(getRequestParameter('network'), getRequestParameter('network_type'))); + // Init disabled list + $GLOBALS['network_translation_disabled'] = array(); + + // Only show params from given type handler if choosen + $ADD = ''; + if ((isPostRequestParameterSet('network_type_id')) && (!is_array(postRequestParameter('network_type_id')))) { + // Only show from current type handler + $ADD = sprintf(" AND p.`network_type_id`=%s", bigintval(postRequestParameter('network_type_id'))); - // Abort any other processing - return; + // Display message + loadTemplate('admin_settings_saved', false, '{--ADMIN_NETWORK_API_TRANSLATION_LIST_LIMITED_TO_TYPE--}'); } // END - if - // Init disabled list - $GLOBALS['network_translation_disabled'] = array(); // Load all advert codes for given network $result = SQL_QUERY_ESC("SELECT @@ -90,14 +92,13 @@ INNER JOIN ON p.`network_type_id`=t.`network_type_id` WHERE - p.`network_id`=%s AND - p.`network_type_id`=%s + p.`network_id`=%s + ".$ADD." ORDER BY t.`network_type_handle` ASC, p.`network_api_id` ASC", array( - bigintval(getRequestParameter('network')), - bigintval(getRequestParameter('network_type')) + bigintval(getRequestParameter('network')) ), __FILE__, __LINE__); // Do we have entries? -- 2.39.5