merge
parent
ff3f4dcfe4
commit
ef1b3d879a
|
|
@ -36,14 +36,14 @@
|
||||||
@change="handleStreetChange"
|
@change="handleStreetChange"
|
||||||
/>
|
/>
|
||||||
</a-form-item>
|
</a-form-item>
|
||||||
<!-- <a-form-item label="村/社区" name="communityid">
|
<a-form-item label="村/社区" name="communityid">
|
||||||
<a-select
|
<a-select
|
||||||
v-model:value="formState.communityid"
|
v-model:value="formState.communityid"
|
||||||
:options="data.communityOptions"
|
:options="data.communityOptions"
|
||||||
:field-names="{ label: 'name', value: 'id' }"
|
:field-names="{ label: 'name', value: 'id' }"
|
||||||
@change="handleCommunityChange"
|
@change="handleCommunityChange"
|
||||||
/>
|
/>
|
||||||
</a-form-item> -->
|
</a-form-item>
|
||||||
</a-form>
|
</a-form>
|
||||||
</a-modal>
|
</a-modal>
|
||||||
|
|
||||||
|
|
@ -84,14 +84,14 @@
|
||||||
@change="handleStreetChange"
|
@change="handleStreetChange"
|
||||||
/>
|
/>
|
||||||
</a-form-item>
|
</a-form-item>
|
||||||
<!-- <a-form-item label="村/社区" name="communityid">
|
<a-form-item label="村/社区" name="communityid">
|
||||||
<a-select
|
<a-select
|
||||||
v-model:value="formState.communityid"
|
v-model:value="formState.communityid"
|
||||||
:options="data.communityOptions"
|
:options="data.communityOptions"
|
||||||
:field-names="{ label: 'name', value: 'id' }"
|
:field-names="{ label: 'name', value: 'id' }"
|
||||||
@change="handleCommunityChange"
|
@change="handleCommunityChange"
|
||||||
/>
|
/>
|
||||||
</a-form-item> -->
|
</a-form-item>
|
||||||
</a-form>
|
</a-form>
|
||||||
</a-modal>
|
</a-modal>
|
||||||
</div>
|
</div>
|
||||||
|
|
@ -123,12 +123,12 @@
|
||||||
const rules = ref({
|
const rules = ref({
|
||||||
countyid: [{ required: true, message: '县区不能为空', trigger: 'blur' }],
|
countyid: [{ required: true, message: '县区不能为空', trigger: 'blur' }],
|
||||||
streetid: [{ required: true, message: '乡镇不能为空', trigger: 'blur' }],
|
streetid: [{ required: true, message: '乡镇不能为空', trigger: 'blur' }],
|
||||||
// communityid: [{ required: true, message: '村/社区不能为空', trigger: 'blur' }],
|
communityid: [{ required: true, message: '村/社区不能为空', trigger: 'blur' }],
|
||||||
});
|
});
|
||||||
const data = reactive({
|
const data = reactive({
|
||||||
countyOptions: [],
|
countyOptions: [],
|
||||||
streetOptions: [],
|
streetOptions: [],
|
||||||
// communityOptions: [],
|
communityOptions: [],
|
||||||
});
|
});
|
||||||
|
|
||||||
watch(
|
watch(
|
||||||
|
|
@ -157,19 +157,19 @@
|
||||||
data.streetOptions = res;
|
data.streetOptions = res;
|
||||||
});
|
});
|
||||||
formState.value.streetid = '';
|
formState.value.streetid = '';
|
||||||
// formState.value.communityid = '';
|
formState.value.communityid = '';
|
||||||
}
|
}
|
||||||
async function handleStreetChange(value, option) {
|
async function handleStreetChange(value, option) {
|
||||||
formState.value.streetid = value;
|
formState.value.streetid = value;
|
||||||
formState.value.streetname = option.name;
|
formState.value.streetname = option.name;
|
||||||
// getOptions(value).then((res) => {
|
getOptions(value).then((res) => {
|
||||||
// data.communityOptions = res;
|
data.communityOptions = res;
|
||||||
// });
|
});
|
||||||
|
}
|
||||||
|
async function handleCommunityChange(value, option) {
|
||||||
|
formState.value.communityid = value;
|
||||||
|
formState.value.communityname = option.name;
|
||||||
}
|
}
|
||||||
// async function handleCommunityChange(value, option) {
|
|
||||||
// formState.value.communityid = value;
|
|
||||||
// formState.value.communityname = option.name;
|
|
||||||
// }
|
|
||||||
async function getOptions(value) {
|
async function getOptions(value) {
|
||||||
const data = await getChildrenTree({
|
const data = await getChildrenTree({
|
||||||
parentId: value,
|
parentId: value,
|
||||||
|
|
@ -192,9 +192,9 @@
|
||||||
data.streetOptions = res;
|
data.streetOptions = res;
|
||||||
});
|
});
|
||||||
// 获取村/社区数据
|
// 获取村/社区数据
|
||||||
// getOptions(formState.value.streetid).then((res) => {
|
getOptions(formState.value.streetid).then((res) => {
|
||||||
// data.communityOptions = res;
|
data.communityOptions = res;
|
||||||
// });
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
function handlerCloseModal() {
|
function handlerCloseModal() {
|
||||||
|
|
@ -211,8 +211,8 @@
|
||||||
countyname: formState.value.countyname,
|
countyname: formState.value.countyname,
|
||||||
streetid: formState.value.streetid,
|
streetid: formState.value.streetid,
|
||||||
streetname: formState.value.streetname,
|
streetname: formState.value.streetname,
|
||||||
// communityid: formState.value.communityid,
|
communityid: formState.value.communityid,
|
||||||
// communityname: formState.value.communityname,
|
communityname: formState.value.communityname,
|
||||||
};
|
};
|
||||||
console.log(querys);
|
console.log(querys);
|
||||||
const data = await UpdateDroneCaseInfo(querys);
|
const data = await UpdateDroneCaseInfo(querys);
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue