Fix admin controller crash: inline table name, fix submit action name
Build / build (push) Successful in 10s
Build / build (push) Successful in 10s
This commit is contained in:
@@ -9,7 +9,7 @@ class AdminSimpleWithdrawalController extends ModuleAdminController
|
||||
public function __construct()
|
||||
{
|
||||
$this->bootstrap = true;
|
||||
$this->table = Simple_withdrawalbutton::TABLE_REQUEST;
|
||||
$this->table = 'simple_withdrawal_request';
|
||||
$this->identifier = 'id_withdrawal_request';
|
||||
$this->lang = false;
|
||||
$this->explicitSelect = true;
|
||||
@@ -83,7 +83,7 @@ class AdminSimpleWithdrawalController extends ModuleAdminController
|
||||
|
||||
public function postProcess()
|
||||
{
|
||||
if (Tools::isSubmit('submitCypWithdrawalStatus')) {
|
||||
if (Tools::isSubmit('submitSimpleWithdrawalStatus')) {
|
||||
$this->processStatusUpdate();
|
||||
return;
|
||||
}
|
||||
@@ -103,7 +103,7 @@ class AdminSimpleWithdrawalController extends ModuleAdminController
|
||||
}
|
||||
|
||||
$ok = Db::getInstance()->update(
|
||||
Simple_withdrawalbutton::TABLE_REQUEST,
|
||||
'simple_withdrawal_request',
|
||||
['status' => $status],
|
||||
'`id_withdrawal_request` = ' . (int) $id
|
||||
);
|
||||
@@ -119,7 +119,7 @@ class AdminSimpleWithdrawalController extends ModuleAdminController
|
||||
{
|
||||
$id = (int) Tools::getValue($this->identifier);
|
||||
$row = Db::getInstance()->getRow(
|
||||
'SELECT * FROM `' . _DB_PREFIX_ . pSQL(Simple_withdrawalbutton::TABLE_REQUEST) . '`
|
||||
'SELECT * FROM `' . _DB_PREFIX_ . pSQL('simple_withdrawal_request') . '`
|
||||
WHERE `id_withdrawal_request` = ' . (int) $id
|
||||
);
|
||||
|
||||
|
||||
@@ -66,7 +66,7 @@
|
||||
<option value="closed" {if $request.status == 'closed'}selected{/if}>{l s='Closed' mod='simple_withdrawalbutton'}</option>
|
||||
</select>
|
||||
</div>
|
||||
<button type="submit" name="submitCypWithdrawalStatus" value="1" class="btn btn-primary">
|
||||
<button type="submit" name="submitSimpleWithdrawalStatus" value="1" class="btn btn-primary">
|
||||
{l s='Update status' mod='simple_withdrawalbutton'}
|
||||
</button>
|
||||
</form>
|
||||
|
||||
Reference in New Issue
Block a user