2029 - Item request fixes & searchbar filters working
gitea/salix/2029-fix_item_request_filters This commit looks good
Details
gitea/salix/2029-fix_item_request_filters This commit looks good
Details
This commit is contained in:
parent
a3a7b4cbaa
commit
3e0fd10b41
|
@ -6,14 +6,15 @@
|
||||||
order="shipped DESC, isOk ASC">
|
order="shipped DESC, isOk ASC">
|
||||||
</vn-crud-model>
|
</vn-crud-model>
|
||||||
<vn-portal slot="topbar">
|
<vn-portal slot="topbar">
|
||||||
<vn-searchbar
|
<vn-searchbar vn-focus
|
||||||
vn-focus
|
|
||||||
panel="vn-request-search-panel"
|
panel="vn-request-search-panel"
|
||||||
on-search="$ctrl.onSearch($params)"
|
suggested-filter="$ctrl.filter.where"
|
||||||
info="Search request by id or alias"
|
info="Search request by id or alias">
|
||||||
suggested-filter="$ctrl.filter.where">
|
|
||||||
</vn-searchbar>
|
</vn-searchbar>
|
||||||
</vn-portal>
|
</vn-portal>
|
||||||
|
<vn-auto-search
|
||||||
|
on-search="$ctrl.onSearch($params)">
|
||||||
|
</vn-auto-search>
|
||||||
<vn-data-viewer model="model">
|
<vn-data-viewer model="model">
|
||||||
<vn-card>
|
<vn-card>
|
||||||
<vn-table model="model">
|
<vn-table model="model">
|
||||||
|
@ -21,8 +22,6 @@
|
||||||
<vn-tr>
|
<vn-tr>
|
||||||
<vn-th field="ticketFk" number>Ticket ID</vn-th>
|
<vn-th field="ticketFk" number>Ticket ID</vn-th>
|
||||||
<vn-th field="shipped">Shipped</vn-th>
|
<vn-th field="shipped">Shipped</vn-th>
|
||||||
<vn-th field="warehouse">Warehouse</vn-th>
|
|
||||||
<vn-th field="salesPersonNickname">SalesPerson</vn-th>
|
|
||||||
<vn-th field="description">Description</vn-th>
|
<vn-th field="description">Description</vn-th>
|
||||||
<vn-th field="quantity" number editable>Requested</vn-th>
|
<vn-th field="quantity" number editable>Requested</vn-th>
|
||||||
<vn-th field="price" number>Price</vn-th>
|
<vn-th field="price" number>Price</vn-th>
|
||||||
|
@ -47,15 +46,7 @@
|
||||||
{{::request.shipped | date: 'dd/MM/yyyy'}}
|
{{::request.shipped | date: 'dd/MM/yyyy'}}
|
||||||
</span>
|
</span>
|
||||||
</vn-td>
|
</vn-td>
|
||||||
<vn-td>{{::request.warehouse}}</vn-td>
|
<vn-td title="{{::request.description}}" expand>{{::request.description}}</vn-td>
|
||||||
<vn-td>
|
|
||||||
<span
|
|
||||||
class="link"
|
|
||||||
ng-click="$ctrl.showWorkerDescriptor($event, request.salesPersonFk)">
|
|
||||||
{{::request.salesPersonNickname}}
|
|
||||||
</span>
|
|
||||||
</vn-td>
|
|
||||||
<vn-td title="{{::request.description}}">{{::request.description}}</vn-td>
|
|
||||||
<vn-td number>{{::request.quantity}}</vn-td>
|
<vn-td number>{{::request.quantity}}</vn-td>
|
||||||
<vn-td number>{{::request.price | currency: 'EUR':2}}</vn-td>
|
<vn-td number>{{::request.price | currency: 'EUR':2}}</vn-td>
|
||||||
<vn-td>
|
<vn-td>
|
||||||
|
@ -82,7 +73,7 @@
|
||||||
</vn-input-number>
|
</vn-input-number>
|
||||||
</field>
|
</field>
|
||||||
</vn-td-editable>
|
</vn-td-editable>
|
||||||
<vn-td>
|
<vn-td expand>
|
||||||
<span
|
<span
|
||||||
class="link"
|
class="link"
|
||||||
ng-click="$ctrl.showItemDescriptor($event, request.itemFk)"
|
ng-click="$ctrl.showItemDescriptor($event, request.itemFk)"
|
||||||
|
@ -101,7 +92,8 @@
|
||||||
ng-if="request.isOk != 0"
|
ng-if="request.isOk != 0"
|
||||||
icon="thumb_down"
|
icon="thumb_down"
|
||||||
ng-click="$ctrl.showDenyReason($event, request)"
|
ng-click="$ctrl.showDenyReason($event, request)"
|
||||||
translate-attr="{title: 'Discard'}">
|
translate-attr="{title: 'Discard'}"
|
||||||
|
tabindex="-1">
|
||||||
</vn-icon-button>
|
</vn-icon-button>
|
||||||
</vn-td>
|
</vn-td>
|
||||||
</vn-tr>
|
</vn-tr>
|
||||||
|
@ -124,7 +116,7 @@
|
||||||
<tpl-body>
|
<tpl-body>
|
||||||
<h5 class="vn-pa-md" translate>Specify the reasons to deny this request</h5>
|
<h5 class="vn-pa-md" translate>Specify the reasons to deny this request</h5>
|
||||||
<vn-horizontal class="vn-pa-md">
|
<vn-horizontal class="vn-pa-md">
|
||||||
<vn-textarea
|
<vn-textarea vn-focus
|
||||||
ng-model="$ctrl.denyObservation">
|
ng-model="$ctrl.denyObservation">
|
||||||
</vn-textarea>
|
</vn-textarea>
|
||||||
</vn-horizontal>
|
</vn-horizontal>
|
||||||
|
|
|
@ -86,6 +86,7 @@ export default class Controller extends Component {
|
||||||
}
|
}
|
||||||
|
|
||||||
onSearch(params) {
|
onSearch(params) {
|
||||||
|
console.log(params);
|
||||||
if (params)
|
if (params)
|
||||||
this.$.model.applyFilter(null, params);
|
this.$.model.applyFilter(null, params);
|
||||||
else
|
else
|
||||||
|
@ -96,7 +97,6 @@ export default class Controller extends Component {
|
||||||
this.selectedRequest = requestId;
|
this.selectedRequest = requestId;
|
||||||
this.$.denyReason.parent = event.target;
|
this.$.denyReason.parent = event.target;
|
||||||
this.$.denyReason.show();
|
this.$.denyReason.show();
|
||||||
document.querySelector('vn-item-request vn-textarea textArea').focus();
|
|
||||||
}
|
}
|
||||||
|
|
||||||
clear() {
|
clear() {
|
||||||
|
|
Loading…
Reference in New Issue