salix/modules/invoiceOut/front/index/manual/index.html

83 lines
2.6 KiB
HTML

<tpl-title translate>
Create manual invoice
</tpl-title>
<tpl-body id="manifold-form">
<vn-crud-model
auto-load="true"
url="InvoiceOutSerials"
data="invoiceOutSerials"
order="code">
</vn-crud-model>
<vn-crud-model
auto-load="true"
url="TaxAreas"
data="taxAreas"
order="code">
</vn-crud-model>
<div
class="progress vn-my-md"
ng-if="$ctrl.isInvoicing">
<vn-horizontal>
<vn-icon vn-none icon="warning"></vn-icon>
<span vn-none translate>Invoicing in progress...</span>
</vn-horizontal>
</div>
<vn-horizontal class="manifold-panel">
<vn-autocomplete
url="Tickets"
label="Ticket"
search-function="{or: [{id: $search}, {nickname: {like: '%'+$search+'%'}}]}"
show-field="nickname"
value-field="id"
ng-model="$ctrl.invoice.ticketFk"
order="shipped DESC"
on-change="$ctrl.invoice.clientFk = null">
<tpl-item>
{{::id}} - {{::nickname}}
</tpl-item>
</vn-autocomplete>
<vn-none class="or vn-px-md" translate>Or</vn-none>
<vn-autocomplete
url="Clients"
label="Client"
search-function="{or: [{id: $search}, {name: {like: '%'+$search+'%'}}]}"
show-field="name"
value-field="id"
ng-model="$ctrl.invoice.clientFk"
on-change="$ctrl.invoice.ticketFk = null">
</vn-autocomplete>
<vn-date-picker
vn-one
label="Max date"
ng-model="$ctrl.invoice.maxShipped">
</vn-date-picker>
</vn-horizontal>
<vn-horizontal>
<vn-autocomplete
data="invoiceOutSerials"
label="Serial"
show-field="description"
value-field="code"
ng-model="$ctrl.invoice.serial"
required="true">
</vn-autocomplete>
<vn-autocomplete
data="taxAreas"
label="Area"
show-field="code"
value-field="code"
ng-model="$ctrl.invoice.taxArea"
required="true">
</vn-autocomplete>
</vn-horizontal>
<vn-horizontal>
<vn-textfield
label="Reference"
ng-model="$ctrl.invoice.reference">
</vn-textfield>
</vn-horizontal>
</tpl-body>
<tpl-buttons>
<input type="button" response="cancel" translate-attr="{value: 'Cancel'}"/>
<button response="accept" translate vn-focus>Make invoice</button>
</tpl-buttons>