X-Git-Url: https://git.mxchange.org/?p=mailer.git;a=blobdiff_plain;f=inc%2Fmodules%2Fadmin%2Fwhat-config_wernis.php;h=95b848394f753b7e7c5d64f80ae5e517592a3c04;hp=ccd6fbfbc5960633418c3b3911374f64851c3e6c;hb=61621983cc6d7195fcc7eab29b5f6080ff283b34;hpb=7b0f17cd637e388049d2167811e4332cec1e979b diff --git a/inc/modules/admin/what-config_wernis.php b/inc/modules/admin/what-config_wernis.php index ccd6fbfbc5..95b848394f 100644 --- a/inc/modules/admin/what-config_wernis.php +++ b/inc/modules/admin/what-config_wernis.php @@ -1,7 +1,7 @@ getConfig(('wernis_min_payout')), - 'min_withdraw' => getConfig(('wernis_min_withdraw')), - 'api_id' => getConfig(('wernis_api_id')), - 'api_md5' => getConfig('wernis_api_md5'), - 'api_url' => getConfig('wernis_api_url'), - 'refid' => getConfig(('wernis_refid')), - 'payout_factor' => translateComma(getConfig('wernis_payout_factor')), - 'withdraw_factor' => translateComma(getConfig('wernis_withdraw_factor')), - 'payout_fee_percent' => translateComma(getConfig('wernis_payout_fee_percent')), - 'withdraw_fee_percent' => translateComma(getConfig('wernis_withdraw_fee_percent')), - 'payout_fee_fix' => getConfig(('wernis_payout_fee_fix')), - 'withdraw_fee_fix' => getConfig(('wernis_withdraw_fee_fix')) - ); + // Remove clear password + unsetPostRequestElement('wernis_pass'); - // Prepare payout Y/N selection - if (getConfig('wernis_payout_active') == 'Y') { - // Payout allowed - define('__CFG_WERNIS_PAYOUT_ACTIVE_Y', ' chkecked="checked"'); - define('__CFG_WERNIS_PAYOUT_ACTIVE_N', ''); + // Save settings + adminSaveSettingsFromPostData(); + } else { + // Failed to test the API! + displayMessage(getWernisErrorMessage()); + } } else { - // Payout disabled - define('__CFG_WERNIS_PAYOUT_ACTIVE_Y', ''); - define('__CFG_WERNIS_PAYOUT_ACTIVE_N', ' chkecked="checked"'); - } + // Remove clear password + unsetPostRequestElement('wernis_pass'); - // Prepare withdraw Y/N selection - if (getConfig('wernis_withdraw_active') == 'Y') { - // Payout allowed - define('__CFG_WERNIS_WITHDRAW_ACTIVE_Y', ' chkecked="checked"'); - define('__CFG_WERNIS_WITHDRAW_ACTIVE_N', ''); - } else { - // Payout disabled - define('__CFG_WERNIS_WITHDRAW_ACTIVE_Y', ''); - define('__CFG_WERNIS_WITHDRAW_ACTIVE_N', ' chkecked="checked"'); + // Save it, anyway + adminSaveSettingsFromPostData(); } - +} else { // Load template - LOAD_TEMPLATE("admin_config_wernis", false, $content); + loadTemplate('admin_config_wernis'); } -// +// [EOF] ?>