Commit 433881e8 authored by Jean-Paul Saman's avatar Jean-Paul Saman

Add new tab "Loss" to record invoices never paid and considered losses.

parent 1e528799
......@@ -369,9 +369,10 @@ Invoices will not be editable once the status changes from Open for Editing.
<tr valign="top" width="90%">
<td align="right">Invoice Status&nbsp;
<select name="stat" size="1" class="text">
<option value="0">Open for Editing</option>
<option value="1">Pending Payment</option>
<option value="2">Paid</option>
<option <?php if ($invoice_status == "0") print "selected" ?> value="0">Open for Editing</option>
<option <?php if ($invoice_status == "1") print "selected" ?> value="1">Pending Payment</option>
<option <?php if ($invoice_status == "2") print "selected" ?> value="2">Paid</option>
<option <?php if ($invoice_status == "3") print "selected" ?> value="3">Loss</option>
</select>
</td>
</tr>
......
......@@ -45,6 +45,7 @@ $tabBox = new CTabBox( "?m=invoice", dPgetConfig('root_dir') . '/modules/invoice
$tabBox->add( "vw_open", 'Invoices (Open)' );
$tabBox->add( "vw_pend", 'Invoices (Pending)' );
$tabBox->add( "vw_paid", 'Invoices (Paid)' );
$tabBox->add( "vw_loss", 'Invoices (Loss)' );
$tabBox->show();
?>
......@@ -46,6 +46,8 @@ function showtask_inv( &$a, $level=0 ) {
$invoice_status="Pending";
}elseif ($a["invouce_status"] == "2") {
$invoice_status="Paid";
}elseif ($a["invouce_status"] == "3") {^M
$invoice_status="Loss";
}
$start_date=strftime($df,$a["invoice_date"]);
......
<?php
include("vw_inc.php");
echo invoices(3);
?>
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment