更新细节
This commit is contained in:
parent
bed415a1e5
commit
ffef7fc1db
|
@ -23,7 +23,7 @@
|
|||
filterable
|
||||
placeholder="请输入用户信息"
|
||||
:remote-method="queryUser"
|
||||
@blur="selectedUser"
|
||||
@change="selectedUser"
|
||||
:loading="loading"
|
||||
>
|
||||
<el-option
|
||||
|
@ -42,7 +42,6 @@
|
|||
filterable
|
||||
placeholder="请输入土地信息"
|
||||
:remote-method="queryLand"
|
||||
@focus="selectedLand"
|
||||
:loading="loading"
|
||||
>
|
||||
<el-option
|
||||
|
@ -155,6 +154,7 @@ const queryUser = async (query: string) => {
|
|||
const selectedUser = (value: any) => {
|
||||
optionsData.land = []
|
||||
formData.land_id = ''
|
||||
queryLand(value)
|
||||
}
|
||||
|
||||
const queryLand = async (user_id: string) => {
|
||||
|
@ -167,10 +167,6 @@ const queryLand = async (user_id: string) => {
|
|||
loading.value = false
|
||||
}
|
||||
|
||||
const selectedLand = () => {
|
||||
queryLand(formData.user_id)
|
||||
}
|
||||
|
||||
// 提交按钮
|
||||
const handleSubmit = async () => {
|
||||
await formRef.value?.validate()
|
||||
|
@ -192,11 +188,14 @@ const generateUuid = () => {
|
|||
const open = (type = 'add') => {
|
||||
mode.value = type
|
||||
popupRef.value?.open()
|
||||
formData.code = generateUuid()
|
||||
formData.code = generateUuid()
|
||||
getUserInfo()
|
||||
.then((res: any) => {
|
||||
const root = res.user.root ?? 0
|
||||
formData.root = root
|
||||
if (type == 'edit') {
|
||||
queryLand(formData.user_id)
|
||||
}
|
||||
})
|
||||
.catch((err: any) => {
|
||||
console.log('err', err)
|
||||
|
|
Loading…
Reference in New Issue