Bug 5682: Voided Invoices and PO Deliveries showing up in inquiries. Fixed.
authorJoe <joe.hunt.consulting@gmail.com>
Fri, 28 Apr 2023 08:44:35 +0000 (10:44 +0200)
committerJoe <joe.hunt.consulting@gmail.com>
Fri, 28 Apr 2023 08:44:35 +0000 (10:44 +0200)
purchasing/inquiry/supplier_inquiry.php
purchasing/view/view_po.php

index f3c3141e648c6bc72f488739cfd4ef42fe3b60b3..c07ef3b2acf7db6f1a66bb10970ff008e126f24f 100644 (file)
@@ -81,6 +81,8 @@ function due_date($row)
 
 function gl_view($row)
 {
+       if ($row['type'] == ST_SUPPRECEIVE && get_voided_entry(ST_SUPPRECEIVE, $row['trans_no']))
+               return set_icon(ICON_REMOVE, _("Voided."));
        return get_gl_view_str($row["type"], $row["trans_no"]);
 }
 
index c83d12b3e452d972b436c44bbdc309b492ba98e7..ca554b5ebf2089876d76d0d6c6f2860991cfca20 100644 (file)
@@ -118,6 +118,8 @@ if (db_num_rows($grns_result) > 0)
     table_header($th);
     while ($myrow = db_fetch($grns_result))
     {
+       if (get_voided_entry(ST_SUPPRECEIVE, $myrow['id']))
+               continue;
                alt_table_row_color($k);
 
        label_cell(get_trans_view_str(ST_SUPPRECEIVE,$myrow["id"]));
@@ -143,6 +145,8 @@ if (db_num_rows($invoice_result) > 0)
     table_header($th);
     while ($myrow = db_fetch($invoice_result))
     {
+       if (get_voided_entry($myrow["type"],$myrow["trans_no"]))
+               continue;
        alt_table_row_color($k);
 
        label_cell(get_trans_view_str($myrow["type"],$myrow["trans_no"]));