fix(01): enter hq after create br / 1 input location
This commit is contained in:
parent
19dd009f88
commit
73c7ba8327
4 changed files with 20 additions and 5 deletions
|
|
@ -34,9 +34,9 @@ defineProps<{
|
||||||
<div class="col-12 bordered rounded column">
|
<div class="col-12 bordered rounded column">
|
||||||
<!-- <div class="q-pl-md q-py-sm app-text-muted bordered-b">location</div> -->
|
<!-- <div class="q-pl-md q-py-sm app-text-muted bordered-b">location</div> -->
|
||||||
|
|
||||||
<div v-if="!!longitude && !!latitude" class="col flex flex-center">
|
<div v-if="!!latitude" class="col flex flex-center">
|
||||||
<iframe
|
<iframe
|
||||||
:src="`https://maps.google.com/maps?q=${latitude}, ${longitude}&z=15&output=embed`"
|
:src="`https://maps.google.com/maps?q=${latitude}&z=15&output=embed`"
|
||||||
width="100%"
|
width="100%"
|
||||||
frameborder="0"
|
frameborder="0"
|
||||||
style="border: 0"
|
style="border: 0"
|
||||||
|
|
@ -76,17 +76,17 @@ defineProps<{
|
||||||
:readonly="readonly"
|
:readonly="readonly"
|
||||||
:outlined="outlined"
|
:outlined="outlined"
|
||||||
:dense="dense"
|
:dense="dense"
|
||||||
:label="$t('branch.form.latitude')"
|
:label="$t('branch.form.locationCoordinate')"
|
||||||
class="col q-mr-xs"
|
class="col q-mr-xs"
|
||||||
/>
|
/>
|
||||||
<q-input
|
<!-- <q-input
|
||||||
v-model="longitude"
|
v-model="longitude"
|
||||||
:readonly="readonly"
|
:readonly="readonly"
|
||||||
:outlined="outlined"
|
:outlined="outlined"
|
||||||
:dense="dense"
|
:dense="dense"
|
||||||
:label="$t('branch.form.longitude')"
|
:label="$t('branch.form.longitude')"
|
||||||
class="col q-ml-xs"
|
class="col q-ml-xs"
|
||||||
/>
|
/> -->
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
|
|
|
||||||
|
|
@ -206,6 +206,7 @@ export default {
|
||||||
latitude: 'Latitude',
|
latitude: 'Latitude',
|
||||||
longitude: 'Longitude',
|
longitude: 'Longitude',
|
||||||
webUrl: 'Website URL',
|
webUrl: 'Website URL',
|
||||||
|
locationCoordinate: 'Location coordinates',
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -206,6 +206,7 @@ export default {
|
||||||
latitude: 'ละติจูด',
|
latitude: 'ละติจูด',
|
||||||
longitude: 'ลองจิจูด',
|
longitude: 'ลองจิจูด',
|
||||||
webUrl: 'ที่อยู่เว็บไซต์',
|
webUrl: 'ที่อยู่เว็บไซต์',
|
||||||
|
locationCoordinate: 'ตำแหน่งพิกัด',
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -602,6 +602,19 @@ async function onSubmit() {
|
||||||
formData.value.code = formData.value.code?.slice(0, -5);
|
formData.value.code = formData.value.code?.slice(0, -5);
|
||||||
delete formData.value['codeHeadOffice'];
|
delete formData.value['codeHeadOffice'];
|
||||||
await createBranch();
|
await createBranch();
|
||||||
|
|
||||||
|
fieldSelectedBranch.value.value = '';
|
||||||
|
inputSearch.value = '';
|
||||||
|
currentHq.value = {
|
||||||
|
id: currentRecord.id,
|
||||||
|
code: currentRecord.code,
|
||||||
|
};
|
||||||
|
beforeBranch.value = {
|
||||||
|
id: '',
|
||||||
|
code: '',
|
||||||
|
};
|
||||||
|
expandedTree.value = [];
|
||||||
|
expandedTree.value.push(currentRecord.id);
|
||||||
} else {
|
} else {
|
||||||
dialog({
|
dialog({
|
||||||
color: 'info',
|
color: 'info',
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue