X-Git-Url: https://delta.frontaccounting.com/gitweb/?a=blobdiff_plain;f=purchasing%2Fview%2Fview_grn.php;h=b2d95bb8e26390226249069d414976456536ef51;hb=bff9e81e76c1110fea3a047220c0b158db11f825;hp=236c462283ff316f328f76e81412a9378cc356ca;hpb=24249d8ad52650e78e342a114d67f048efb9aed4;p=fa-stable.git diff --git a/purchasing/view/view_grn.php b/purchasing/view/view_grn.php index 236c4622..b2d95bb8 100644 --- a/purchasing/view/view_grn.php +++ b/purchasing/view/view_grn.php @@ -37,20 +37,30 @@ display_grn_summary($purchase_order); display_heading2(_("Line Details")); start_table(TABLESTYLE, "width='90%'"); -$th = array(_("Item Code"), _("Item Description"), _("Delivery Date"), _("Quantity"), +$th = array(_("Item Code"), _("Item Description"), _("Required by"), _("Quantity"), _("Unit"), _("Price"), _("Line Total"), _("Quantity Invoiced")); table_header($th); $total = 0; $k = 0; //row colour counter +$overdue_items = false; foreach ($purchase_order->line_items as $stock_item) { $line_total = $stock_item->qty_received * $stock_item->price; - alt_table_row_color($k); + // if overdue and outstanding quantities, then highlight as so + if (date1_greater_date2($purchase_order->orig_order_date, $stock_item->req_del_date)) + { + start_row("class='overduebg'"); + $overdue_items = true; + } + else + { + alt_table_row_color($k); + } label_cell($stock_item->stock_id); label_cell($stock_item->item_description); @@ -83,6 +93,9 @@ end_row(); end_table(1); +if ($overdue_items) + display_note(_("Marked items were delivered overdue."), 0, 0, "class='overduefg'"); + is_voided_display(ST_SUPPRECEIVE, $_GET['trans_no'], _("This delivery has been voided.")); end_page(true, false, false, ST_SUPPRECEIVE, $_GET['trans_no']);