Update some enum references, render all purchase batch cases/units fields as quantity
This commit is contained in:
parent
feef8a5ecc
commit
0b10021942
3 changed files with 18 additions and 8 deletions
|
@ -6,7 +6,7 @@
|
|||
<script type="text/javascript">
|
||||
|
||||
function show_mode(mode) {
|
||||
if (mode == ${enum.PURCHASE_BATCH_MODE_NEW}) {
|
||||
if (mode == ${enum.PURCHASE_BATCH_MODE_ORDERING}) {
|
||||
$('.field-wrapper.store_uuid').show();
|
||||
$('.field-wrapper.purchase_uuid').hide();
|
||||
$('.field-wrapper.department_uuid').show();
|
||||
|
@ -81,7 +81,7 @@
|
|||
$('.field-wrapper.purchase_uuid select').selectmenu();
|
||||
$('.field-wrapper.department_uuid select').selectmenu();
|
||||
|
||||
show_mode(${form.fieldset.model.mode or enum.PURCHASE_BATCH_MODE_NEW});
|
||||
show_mode(${form.fieldset.model.mode or enum.PURCHASE_BATCH_MODE_ORDERING});
|
||||
|
||||
});
|
||||
|
||||
|
|
|
@ -33,7 +33,7 @@
|
|||
</%def>
|
||||
|
||||
<%def name="leading_buttons()">
|
||||
% if batch.mode == enum.PURCHASE_BATCH_MODE_NEW and not batch.complete and not batch.executed and request.has_perm('purchases.batch.order_form'):
|
||||
% if batch.mode == enum.PURCHASE_BATCH_MODE_ORDERING and not batch.complete and not batch.executed and request.has_perm('purchases.batch.order_form'):
|
||||
<button type="button" id="order-form">Ordering Form</button>
|
||||
% elif batch.mode == enum.PURCHASE_BATCH_MODE_RECEIVING and not batch.complete and not batch.executed and request.has_perm('purchases.batch.receiving_form'):
|
||||
<button type="button" id="receive-form">Receiving Form</button>
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue