salix/modules/ticket/front/request/create/index.html

54 lines
1.8 KiB
HTML

<mg-ajax path="TicketRequests" options="vnPost"></mg-ajax>
<vn-watcher
vn-id="watcher"
data="$ctrl.ticketRequest"
form="form"
save="post">
</vn-watcher>
<form name="form" ng-submit="$ctrl.onSubmit()" class="vn-ma-md">
<div compact>
<vn-card class="vn-pa-lg">
<vn-horizontal>
<vn-textfield
vn-one
label="Description"
ng-model="$ctrl.ticketRequest.description"
rule
vn-focus>
</vn-textfield>
<vn-autocomplete
vn-one
ng-model="$ctrl.ticketRequest.attenderFk"
url="Clients/activeWorkersWithRole"
show-field="nickname"
search-function="{firstName: $search}"
value-field="id"
where="{role: 'buyer'}"
label="Buyer">
</vn-autocomplete>
</vn-horizontal>
<vn-horizontal>
<vn-input-number
vn-one
min="1"
label="Quantity"
ng-model="$ctrl.ticketRequest.quantity"
rule>
</vn-input-number>
<vn-input-number
vn-one
min="0"
label="Price"
step="0.01"
ng-model="$ctrl.ticketRequest.price"
rule>
</vn-input-number>
</vn-horizontal>
</vn-card>
<vn-button-bar>
<vn-submit label="Create"></vn-submit>
<vn-button ui-sref="ticket.card.request.index" label="Cancel"></vn-button>
</vn-button-bar>
</div>
</form>