claim action now shows ticket
gitea/salix/test This commit looks good Details
gitea/salix/master This commit looks good Details

This commit is contained in:
Gerard 2019-02-21 13:48:34 +01:00
parent 1e199e9d5a
commit 1324d53e1b
2 changed files with 20 additions and 1 deletions

View File

@ -42,6 +42,7 @@
<vn-thead> <vn-thead>
<vn-tr> <vn-tr>
<vn-th number>Id</vn-th> <vn-th number>Id</vn-th>
<vn-th number>Ticket</vn-th>
<vn-th>Destination</vn-th> <vn-th>Destination</vn-th>
<vn-th>Landed</vn-th> <vn-th>Landed</vn-th>
<vn-th number>Quantity</vn-th> <vn-th number>Quantity</vn-th>
@ -62,6 +63,13 @@
{{saleClaimed.sale.itemFk | zeroFill:6}} {{saleClaimed.sale.itemFk | zeroFill:6}}
</span> </span>
</vn-td> </vn-td>
<vn-td number>
<span
class="link"
ng-click="$ctrl.showTicketDescriptor($event, saleClaimed.sale.ticketFk)">
{{::saleClaimed.sale.ticketFk}}
</span>
</vn-td>
<vn-td> <vn-td>
<vn-autocomplete <vn-autocomplete
vn-one vn-one
@ -181,3 +189,6 @@
vn-id="descriptor" vn-id="descriptor"
quicklinks="$ctrl.quicklinks"> quicklinks="$ctrl.quicklinks">
</vn-item-descriptor-popover> </vn-item-descriptor-popover>
<vn-ticket-descriptor-popover
vn-id="ticketDescriptor">
</vn-ticket-descriptor-popover>

View File

@ -67,6 +67,14 @@ class Controller {
}); });
} }
showTicketDescriptor(event, ticketFk) {
this.$.ticketDescriptor.ticketFk = ticketFk;
this.$.ticketDescriptor.parent = event.target;
this.$.ticketDescriptor.show();
event.preventDefault();
}
focusLastInput() { focusLastInput() {
let inputs = document.querySelectorAll('#claimDestinationFk'); let inputs = document.querySelectorAll('#claimDestinationFk');
inputs[inputs.length - 1].querySelector('input').focus(); inputs[inputs.length - 1].querySelector('input').focus();