X-Git-Url: https://delta.frontaccounting.com/gitweb/?a=blobdiff_plain;f=purchasing%2Fsupplier_credit.php;h=513135fc31bd8928b1ccd1a15f5841a1dba08407;hb=4f57367b97832827258d1140ca423a26cf714142;hp=fc16875ce1b1214053447a7cdc30d8ad56c7ac94;hpb=a5242af68e65661edb7175412444dce536a7f311;p=fa-stable.git diff --git a/purchasing/supplier_credit.php b/purchasing/supplier_credit.php index fc16875c..513135fc 100644 --- a/purchasing/supplier_credit.php +++ b/purchasing/supplier_credit.php @@ -130,6 +130,12 @@ if (isset($_POST['AddGLCodeToTrans'])){ } } + if (!is_tax_gl_unique(get_post('gl_code'))) { + display_error(_("Cannot post to GL account used by more than one tax type.")); + set_focus('gl_code'); + $input_error = true; + } + if ($input_error == false) { $_SESSION['supp_trans']->add_gl_codes_to_trans($_POST['gl_code'], $gl_act_name, @@ -319,7 +325,7 @@ if (isset($_POST['go'])) //-------------------------------------------------------------------------------------------------- -start_form(false, true); +start_form(); invoice_header($_SESSION['supp_trans']); if ($_POST['supplier_id']=='') @@ -348,7 +354,7 @@ if (get_post('AddGLCodeToTrans')) $Ajax->activate('inv_tot'); br(); -submit_center('PostCreditNote', _("Enter Credit Note"), true, '', true); +submit_center('PostCreditNote', _("Enter Credit Note"), true, '', 'default'); br(); end_form();