projects
/
fa-stable.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Payment_terms table normalization.
[fa-stable.git]
/
sales
/
customer_invoice.php
diff --git
a/sales/customer_invoice.php
b/sales/customer_invoice.php
index 20af722a3ce0603ee77064c449cb4af573231b80..2bc41391938c720dae8a96b6f3bc547ae3ff056e 100644
(file)
--- a/
sales/customer_invoice.php
+++ b/
sales/customer_invoice.php
@@
-341,7
+341,7
@@
function check_data()
return false;
}
} else {
return false;
}
} else {
- if (($_SESSION['Items']->payment_terms['
days_before_due'] == -1
) && !count($_SESSION['Items']->prepayments)) {
+ if (($_SESSION['Items']->payment_terms['
type'] == PTT_PREPAY
) && !count($_SESSION['Items']->prepayments)) {
display_error(_("There is no non-invoiced payments for this order. If you want to issue final invoice, select delayed or cash payment terms."));
return false;
}
display_error(_("There is no non-invoiced payments for this order. If you want to issue final invoice, select delayed or cash payment terms."));
return false;
}
@@
-385,7
+385,7
@@
if(list_updated('payment')) {
$_POST['Comments'] = '';
$Ajax->activate('due_date');
$Ajax->activate('options');
$_POST['Comments'] = '';
$Ajax->activate('due_date');
$Ajax->activate('options');
- if ($order->payment_terms['
cash_sale']
) {
+ if ($order->payment_terms['
type'] == PTT_CASH
) {
$_POST['Location'] = $order->Location = $order->pos['pos_location'];
$order->location_name = $order->pos['location_name'];
}
$_POST['Location'] = $order->Location = $order->pos['pos_location'];
$order->location_name = $order->pos['location_name'];
}