X-Git-Url: https://delta.frontaccounting.com/gitweb/?a=blobdiff_plain;ds=sidebyside;f=sales%2Fcustomer_credit_invoice.php;h=2d13e54729cb5eb2b2969803c9eae4867cc5518f;hb=4d4371fb200bb27fd6b680ebd2d1aaa450a0be7e;hp=7d318a9f18a61b92f3e73c1d2c1ff1a731291eeb;hpb=818719f38b8327cdca616d58b13913dbd174d96a;p=fa-stable.git diff --git a/sales/customer_credit_invoice.php b/sales/customer_credit_invoice.php index 7d318a9f..2d13e547 100644 --- a/sales/customer_credit_invoice.php +++ b/sales/customer_credit_invoice.php @@ -1,13 +1,13 @@ . + See the License here . ***********************************************************************/ //--------------------------------------------------------------------------- // @@ -152,6 +152,9 @@ function check_quantities() { $ok =1; foreach ($_SESSION['Items']->line_items as $line_no=>$itm) { + if ($itm->quantity == $itm->qty_done) { + continue; // this line was fully credited/removed + } if (isset($_POST['Line'.$line_no])) { if (check_num('Line'.$line_no, 0, $itm->quantity)) { $_SESSION['Items']->line_items[$line_no]->qty_dispatched = @@ -226,7 +229,7 @@ function display_credit_items() { global $table_style, $table_style2; - start_form(false, true); + start_form(); hidden('cart_id'); start_table("$table_style2 width=80%", 5); @@ -287,8 +290,8 @@ function display_credit_items() $k = 0; //row colour counter foreach ($_SESSION['Items']->line_items as $line_no=>$ln_itm) { - if ($ln_itm->quantity==$ln_itm->qty_done) { - continue; // this line was fully credited + if ($ln_itm->quantity == $ln_itm->qty_done) { + continue; // this line was fully credited/removed } alt_table_row_color($k); @@ -382,7 +385,7 @@ display_credit_options(); echo "
"; submit('Update', _("Update"), true, _('Update credit value for quantities entered'), true); echo " "; -submit('ProcessCredit', _("Process Credit Note"), true, '', true); +submit('ProcessCredit', _("Process Credit Note"), true, '', 'default'); echo "
"; end_form();