进件修改
This commit is contained in:
@@ -115,7 +115,7 @@
|
||||
|
||||
<script setup>
|
||||
import {
|
||||
onLoad
|
||||
onLoad,onShow
|
||||
} from '@dcloudio/uni-app'
|
||||
import {
|
||||
computed,
|
||||
@@ -293,10 +293,14 @@
|
||||
const options=reactive({})
|
||||
onLoad(async (opt) => {
|
||||
Object.assign(options,opt)
|
||||
if(opt.type=='addBranch'){
|
||||
|
||||
|
||||
})
|
||||
onShow(async()=>{
|
||||
if(options.type=='addBranch'){
|
||||
// 添加分店
|
||||
const res = await await shopInfoApi.getShopDetail({
|
||||
id: opt.id
|
||||
id: options.id
|
||||
})
|
||||
form.isHeadShop=0
|
||||
form.mainId=res.id
|
||||
@@ -306,10 +310,10 @@
|
||||
})
|
||||
return
|
||||
}else{
|
||||
if (opt.id) {
|
||||
if (options.id) {
|
||||
rules.accountName.required = false
|
||||
const res = await await shopInfoApi.getShopDetail({
|
||||
id: opt.id
|
||||
id: options.id
|
||||
})
|
||||
for (let key in form) {
|
||||
form[key] = res[key]
|
||||
@@ -323,7 +327,6 @@
|
||||
})
|
||||
}
|
||||
}
|
||||
|
||||
})
|
||||
watchEffect(()=>{
|
||||
console.log(form.shopType)
|
||||
|
||||
Reference in New Issue
Block a user