fixing
This commit is contained in:
parent
e9367dea5c
commit
eedddc19ae
1 changed files with 8 additions and 10 deletions
|
|
@ -140,7 +140,7 @@ const refreshData = async () => {
|
|||
async () => {
|
||||
emit("update:statusEdit", false);
|
||||
await props.fetch("Address");
|
||||
fetchProvince()
|
||||
fetchProvince();
|
||||
edit.value = false;
|
||||
onEdit.value = false;
|
||||
},
|
||||
|
|
@ -268,7 +268,7 @@ const fetchProvince = async () => {
|
|||
const data = res.data.result;
|
||||
let option: optionData[] = [];
|
||||
data.map((r: any) => {
|
||||
option.push({ id: r.id.toString(), name: r.name.toString() });
|
||||
option.push({ id: r.id, name: r.name });
|
||||
});
|
||||
Ops.value.provinceOps = option;
|
||||
OpsFilter.value.provinceOps = option;
|
||||
|
|
@ -332,8 +332,7 @@ const fetchProvince = async () => {
|
|||
.catch((e) => {
|
||||
messageError($q, e);
|
||||
})
|
||||
.finally(() => {
|
||||
});
|
||||
.finally(() => {});
|
||||
};
|
||||
|
||||
// ดึงข้อมูลอำเภอ
|
||||
|
|
@ -345,7 +344,7 @@ const fetchDistrict = async (id: string | null, position: string) => {
|
|||
const data = res.data.result.districts;
|
||||
let option: optionData[] = [];
|
||||
data.map((r: any) => {
|
||||
option.push({ id: r.id.toString(), name: r.name.toString() });
|
||||
option.push({ id: r.id, name: r.name });
|
||||
});
|
||||
if (position == "1") {
|
||||
Ops.value.districtOps = option;
|
||||
|
|
@ -375,8 +374,7 @@ const fetchDistrict = async (id: string | null, position: string) => {
|
|||
.catch((e) => {
|
||||
messageError($q, e);
|
||||
})
|
||||
.finally(() => {
|
||||
});
|
||||
.finally(() => {});
|
||||
}
|
||||
};
|
||||
|
||||
|
|
@ -390,9 +388,9 @@ const fetchSubDistrict = async (id: string | null, position: string) => {
|
|||
let option: zipCodeOption[] = [];
|
||||
data.map((r: any) => {
|
||||
option.push({
|
||||
id: r.id.toString(),
|
||||
name: r.name.toString(),
|
||||
zipCode: r.zipCode.toString(),
|
||||
id: r.id,
|
||||
name: r.name,
|
||||
zipCode: r.zipCode,
|
||||
});
|
||||
});
|
||||
if (position == "1") {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue