72 lines
2.2 KiB
HTML
72 lines
2.2 KiB
HTML
<vn-watcher
|
|
vn-id="watcher"
|
|
url="Claims/{{$ctrl.$params.id}}/updateClaim"
|
|
data="$ctrl.claim"
|
|
insert-mode="true"
|
|
form="form">
|
|
</vn-watcher>
|
|
<vn-crud-model
|
|
auto-load="true"
|
|
url="ClaimStates"
|
|
data="claimStates">
|
|
</vn-crud-model>
|
|
<form name="form" ng-submit="$ctrl.onSubmit()" class="vn-w-md">
|
|
<vn-card class="vn-pa-lg">
|
|
<vn-horizontal>
|
|
<vn-textfield
|
|
label="Client"
|
|
ng-model="$ctrl.claim.client.name"
|
|
readonly="true">
|
|
</vn-textfield>
|
|
<vn-textfield
|
|
label="Created"
|
|
field="::$ctrl.claim.created | date:'yyyy-MM-dd HH:mm'"
|
|
readonly="true">
|
|
</vn-textfield>
|
|
</vn-horizontal>
|
|
<vn-horizontal>
|
|
<vn-autocomplete
|
|
disabled="false"
|
|
ng-model="$ctrl.claim.workerFk"
|
|
url="Clients/activeWorkersWithRole"
|
|
show-field="nickname"
|
|
search-function="{firstName: $search}"
|
|
where="{role: 'employee'}"
|
|
label="Attended by">
|
|
</vn-autocomplete>
|
|
<vn-autocomplete
|
|
ng-model="$ctrl.claim.claimStateFk"
|
|
data="claimStates"
|
|
show-field="description"
|
|
value-field="id"
|
|
label="Claim state"
|
|
order="priority ASC"
|
|
vn-focus>
|
|
</vn-autocomplete>
|
|
</vn-horizontal>
|
|
</vn-horizontal>
|
|
<vn-horizontal>
|
|
<vn-textarea
|
|
label="Observation"
|
|
ng-model="$ctrl.claim.observation"
|
|
rule>
|
|
</vn-textarea>
|
|
</vn-horizontal>
|
|
<vn-horizontal>
|
|
<vn-check
|
|
class="vn-mr-md"
|
|
label="Pick up"
|
|
ng-model="$ctrl.claim.hasToPickUp"
|
|
vn-acl="salesAssistant">
|
|
</vn-check>
|
|
</vn-horizontal>
|
|
</vn-card>
|
|
<vn-button-bar>
|
|
<vn-submit label="Save"></vn-submit>
|
|
<vn-button label="Undo changes"
|
|
ng-if="$ctrl.$.form.$dirty"
|
|
ng-click="watcher.loadOriginalData()">
|
|
</vn-button>
|
|
</vn-button-bar>
|
|
</form>
|