X-Git-Url: https://delta.frontaccounting.com/gitweb/?a=blobdiff_plain;ds=sidebyside;f=purchasing%2Fview%2Fview_po.php;h=ca554b5ebf2089876d76d0d6c6f2860991cfca20;hb=331673104c056da093f60cde57d731371fbdc6ee;hp=ef54291f26ff4839e8654a151ff89f26baba8e23;hpb=46c5f7a65a7659a44ae8254c63152074363d3987;p=fa-stable.git
diff --git a/purchasing/view/view_po.php b/purchasing/view/view_po.php
index ef54291f..ca554b5e 100644
--- a/purchasing/view/view_po.php
+++ b/purchasing/view/view_po.php
@@ -17,7 +17,7 @@ include($path_to_root . "/includes/session.inc");
include($path_to_root . "/purchasing/includes/purchasing_ui.inc");
$js = "";
-if ($use_popup_windows)
+if ($SysPrefs->use_popup_windows)
$js .= get_js_open_window(900, 500);
page(_($help_context = "View Purchase Order"), true, false, "", $js);
@@ -27,6 +27,9 @@ if (!isset($_GET['trans_no']))
die ("
" . _("This page must be called with a purchase order number to review."));
}
+if (!empty($SysPrefs->prefs['company_logo_on_views']))
+ company_logo_on_view();
+
display_heading(_("Purchase Order") . " #" . $_GET['trans_no']);
$purchase_order = new purch_order;
@@ -35,19 +38,18 @@ read_po($_GET['trans_no'], $purchase_order);
echo "
";
display_po_summary($purchase_order, true);
-start_table(TABLESTYLE, "width=90%", 6);
+start_table(TABLESTYLE, "width='90%'", 6);
echo "
"; // outer table
display_heading2(_("Line Details"));
-start_table(TABLESTYLE, "colspan=9 width=100%");
+start_table(TABLESTYLE, "width='100%'");
$th = array(_("Item Code"), _("Item Description"), _("Quantity"), _("Unit"), _("Price"),
_("Requested By"), _("Line Total"), _("Quantity Received"), _("Quantity Invoiced"));
table_header($th);
$total = $k = 0;
$overdue_items = false;
-
foreach ($purchase_order->line_items as $stock_item)
{
@@ -116,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"]));
@@ -123,7 +127,7 @@ if (db_num_rows($grns_result) > 0)
label_cell(sql2date($myrow["delivery_date"]));
end_row();
}
- end_table();;
+ end_table();
}
$invoice_result = get_po_invoices_credits($_GET['trans_no']);
@@ -141,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"]));
@@ -155,8 +161,9 @@ echo " |
";
end_table(1); // outer table
+display_allocations_to(PT_SUPPLIER, $purchase_order->supplier_id, ST_PURCHORDER, $purchase_order->order_no, $total + $tax_total);
+
//----------------------------------------------------------------------------------------------------
end_page(true, false, false, ST_PURCHORDER, $_GET['trans_no']);
-?>