#837 crear refactor de activeSalesPerson, activeBuyer en uno solo
This commit is contained in:
parent
0e17a090eb
commit
9bd6248632
|
@ -22,7 +22,8 @@
|
|||
order="description">
|
||||
</vn-crud-model>
|
||||
<vn-crud-model
|
||||
url="/client/api/Clients/activeSalesPerson"
|
||||
url="/client/api/Clients/activeWorkersWithRole"
|
||||
where="{role: 'salesPerson'}"
|
||||
data="activeSalesPersons"
|
||||
order="firstName">
|
||||
</vn-crud-model>
|
||||
|
|
|
@ -30,9 +30,11 @@
|
|||
<vn-autocomplete vn-one
|
||||
initial-data="$ctrl.client.salesPerson"
|
||||
field="$ctrl.client.salesPersonFk"
|
||||
url="/client/api/Clients/activeSalesPerson"
|
||||
url="/client/api/Clients/activeWorkersWithRole"
|
||||
show-field="firstName"
|
||||
search-function="{firstName: $search}"
|
||||
value-field="id"
|
||||
where="{role: 'salesPerson'}"
|
||||
label="Salesperson"
|
||||
vn-acl="salesAssistant">
|
||||
<tpl-item>{{firstName}} {{name}}</tpl-item>
|
||||
|
|
|
@ -13,9 +13,11 @@
|
|||
<vn-textfield vn-two label="Comercial Name" field="$ctrl.client.name" vn-focus></vn-textfield>
|
||||
<vn-autocomplete vn-one
|
||||
field="$ctrl.client.salesPersonFk"
|
||||
url="/client/api/Clients/activeSalesPerson"
|
||||
url="/client/api/Clients/activeWorkersWithRole"
|
||||
search-function="{firstName: $search}"
|
||||
show-field="firstName"
|
||||
value-field="id"
|
||||
where="{role: 'salesPerson'}"
|
||||
label="Salesperson">
|
||||
<tpl-item>{{firstName}} {{name}}</tpl-item>
|
||||
</vn-autocomplete>
|
||||
|
|
|
@ -26,14 +26,16 @@
|
|||
model="filter.name">
|
||||
</vn-textfield>
|
||||
<vn-autocomplete
|
||||
vn-one
|
||||
field="filter.salesPersonFk"
|
||||
url="/client/api/Clients/activeSalesPerson"
|
||||
show-field="name"
|
||||
value-field="id"
|
||||
label="Salesperson">
|
||||
<tpl-item>{{firstName}} {{name}}</tpl-item>
|
||||
</vn-autocomplete>
|
||||
vn-one
|
||||
field="filter.salesPersonFk"
|
||||
url="/client/api/Clients/activeWorkersWithRole"
|
||||
search-function="{firstName: $search}"
|
||||
show-field="firstName"
|
||||
value-field="id"
|
||||
where="{role: 'salesPerson'}"
|
||||
label="Salesperson">
|
||||
<tpl-item>{{firstName}} {{name}}</tpl-item>
|
||||
</vn-autocomplete>
|
||||
</vn-horizontal>
|
||||
<vn-horizontal>
|
||||
<vn-textfield
|
||||
|
|
|
@ -12,12 +12,14 @@
|
|||
<vn-horizontal>
|
||||
<vn-textfield vn-one label="Description" field="$ctrl.ticketRequest.description" vn-focus></vn-textfield>
|
||||
<vn-autocomplete
|
||||
vn-one
|
||||
label="Buyer"
|
||||
field="$ctrl.ticketRequest.atenderFk"
|
||||
select-fields="['id', 'name']"
|
||||
url="/client/api/Clients/activeBuyer"
|
||||
show-field="name">
|
||||
vn-one
|
||||
label="Buyer"
|
||||
field="$ctrl.ticketRequest.atenderFk"
|
||||
select-fields="['id', 'firstName']"
|
||||
url="/client/api/Clients/activeWorkersWithRole"
|
||||
where="{role: 'buyer'}"
|
||||
search-function="{firstName: $search}"
|
||||
show-field="firstName">
|
||||
<tpl-item>{{firstName}} {{name}}</tpl-item>
|
||||
</vn-autocomplete>
|
||||
</vn-horizontal>
|
||||
|
|
|
@ -56,9 +56,14 @@
|
|||
<vn-horizontal>
|
||||
<vn-autocomplete
|
||||
vn-one
|
||||
label="Sales person"
|
||||
field="filter.salesPersonFk"
|
||||
url="/api/Workers">
|
||||
url="/client/api/Clients/activeWorkersWithRole"
|
||||
search-function="{firstName: $search}"
|
||||
show-field="firstName"
|
||||
value-field="id"
|
||||
where="{role: 'employee'}"
|
||||
label="Sales person">
|
||||
<tpl-item>{{firstName}} {{name}}</tpl-item>
|
||||
</vn-autocomplete>
|
||||
<vn-autocomplete
|
||||
vn-one
|
||||
|
|
Loading…
Reference in New Issue