2509 - Added forms to create new locations + e2e #412

Merged
carlosjr merged 6 commits from 2509-add_geolocation into dev 2020-10-19 18:57:18 +00:00
4 changed files with 8 additions and 7 deletions
Showing only changes of commit 39ea51764b - Show all commits

View File

@ -74,6 +74,8 @@ export default class Controller extends Section {
onResponse(response) { onResponse(response) {
this.address.postalCode = response.code; this.address.postalCode = response.code;
this.address.city = response.city;
this.address.provinceFk = response.provinceFk;
} }
} }

View File

@ -78,6 +78,8 @@ export default class Controller extends Section {
onResponse(response) { onResponse(response) {
this.address.postalCode = response.code; this.address.postalCode = response.code;
this.address.city = response.city;
this.address.provinceFk = response.provinceFk;
} }
} }

View File

@ -5,12 +5,6 @@
insert-mode="true" insert-mode="true"
form="form"> form="form">
</vn-watcher> </vn-watcher>
<vn-crud-model
auto-load="true"
url="Towns/location"
data="townLocations"
order="name">
</vn-crud-model>
<form name="form" vn-http-submit="$ctrl.onSubmit()" class="vn-w-md"> <form name="form" vn-http-submit="$ctrl.onSubmit()" class="vn-w-md">
<vn-card class="vn-pa-lg"> <vn-card class="vn-pa-lg">
<vn-horizontal> <vn-horizontal>
@ -82,7 +76,7 @@
label="City" label="City"
ng-model="$ctrl.client.city" ng-model="$ctrl.client.city"
selection="$ctrl.town" selection="$ctrl.town"
data="townsLocation" url="Towns/location"
fields="['id', 'name', 'provinceFk']" fields="['id', 'name', 'provinceFk']"
value-field="name"> value-field="name">
<tpl-item> <tpl-item>

View File

@ -81,6 +81,9 @@ export default class Controller extends Section {
onResponse(response) { onResponse(response) {
this.client.postcode = response.code; this.client.postcode = response.code;
this.client.city = response.city;
this.client.provinceFk = response.provinceFk;
this.client.countryFk = response.countryFk;
} }
} }