#911 claim.development
This commit is contained in:
parent
f5b36c5d20
commit
e52012ac41
|
@ -21,12 +21,6 @@
|
|||
data="claimResponsibles"
|
||||
order="description">
|
||||
</vn-crud-model>
|
||||
<vn-crud-model
|
||||
url="/client/api/Clients/activeWorkersWithRole"
|
||||
where="{role: 'salesPerson'}"
|
||||
data="activeSalesPersons"
|
||||
order="firstName">
|
||||
</vn-crud-model>
|
||||
<vn-crud-model
|
||||
url="claim/api/ClaimRedeliveries"
|
||||
data="claimRedeliveries"
|
||||
|
@ -78,8 +72,11 @@
|
|||
vn-one
|
||||
label="Worker"
|
||||
field="claimDevelopment.workerFk"
|
||||
data="activeSalesPersons"
|
||||
url="/client/api/Clients/activeWorkersWithRole"
|
||||
search-function="{firstName: $search}"
|
||||
where="{role: 'employee'}"
|
||||
show-field="firstName"
|
||||
value-field="id"
|
||||
vn-acl="salesAssistant">
|
||||
<tpl-item>{{firstName}} {{name}}</tpl-item>
|
||||
</vn-autocomplete>
|
||||
|
|
|
@ -37,7 +37,11 @@ module.exports = Self => {
|
|||
case 'role':
|
||||
return {'r.name': value};
|
||||
case 'firstName':
|
||||
return {or: [{'w.firstName': {like: `%${value}%`}}, {'w.name': {like: `%${value}%`}}]};
|
||||
return {or: [
|
||||
{'w.firstName': {like: `%${value}%`}},
|
||||
{'w.name': {like: `%${value}%`}},
|
||||
{'u.name': {like: `%${value}%`}}
|
||||
]};
|
||||
case 'id':
|
||||
return {'w.id': value};
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue