|
|
@ -87,7 +87,7 @@ import request from '@/common/request.js' |
|
|
|
submit(){ |
|
|
|
this.$refs.form.validate().then(async valid=>{ |
|
|
|
if(valid){ |
|
|
|
var res=await request("/api/AddWarehouseApi/add",{ |
|
|
|
var res=await request("/api/WarehouseManageApi/addOrUpdate",{ |
|
|
|
method:"post", |
|
|
|
body:{ |
|
|
|
...this.formData, |
|
|
@ -107,12 +107,15 @@ import request from '@/common/request.js' |
|
|
|
} |
|
|
|
}) |
|
|
|
}, |
|
|
|
async getDetail(warehouseId){ |
|
|
|
var res=await request("/api/WarehouseManageApi/addOrUpdate",{ |
|
|
|
params:{warehouseId} |
|
|
|
async getDetail(id){ |
|
|
|
var res=await request("/api/WarehouseManageApi/queryById",{ |
|
|
|
params:{id} |
|
|
|
}) |
|
|
|
if(res.statu){ |
|
|
|
this.formData=res.data.upper |
|
|
|
this.formData=res.data |
|
|
|
this.fields.warehousePic.value=res.data.warehousePic |
|
|
|
this.formData.warehousePic=res.data.warehousePic?.split?.(",")?.filter?.(v=>v)||[] |
|
|
|
this.fields.warehouseType.value=[res.data.warehouseType] |
|
|
|
}else{ |
|
|
|
uni.showModal({ |
|
|
|
title:"提示", |
|
|
|