Merge branch 'dwb' of e.coding.net:g-cphe0354/yinshoukeguanliduan/management into gyq
This commit is contained in:
commit
af774198d5
|
|
@ -51,7 +51,12 @@
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
<!-- <el-table-column label="最近入库量" prop="lasterInStock" /> -->
|
<!-- <el-table-column label="最近入库量" prop="lasterInStock" /> -->
|
||||||
<el-table-column label="库存数量" prop="stockNumber" />
|
<el-table-column label="库存数量" prop="stockNumber">
|
||||||
|
<template v-slot="scope">
|
||||||
|
{{ scope.row.stockNumber - scope.row.stockConsume }}
|
||||||
|
</template>
|
||||||
|
</el-table-column>
|
||||||
|
|
||||||
<el-table-column label="预警值" prop="conWarning" />
|
<el-table-column label="预警值" prop="conWarning" />
|
||||||
<!-- <el-table-column label="单位耗材值" prop="surplusStock" /> -->
|
<!-- <el-table-column label="单位耗材值" prop="surplusStock" /> -->
|
||||||
<!-- <el-table-column label="排序" prop="sort" sortable /> -->
|
<!-- <el-table-column label="排序" prop="sort" sortable /> -->
|
||||||
|
|
@ -106,6 +111,9 @@
|
||||||
<el-form-item label="耗材信息名称" prop="conName">
|
<el-form-item label="耗材信息名称" prop="conName">
|
||||||
<el-input v-model="ruleForm.conName" placeholder="请输入耗材信息名称"></el-input>
|
<el-input v-model="ruleForm.conName" placeholder="请输入耗材信息名称"></el-input>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
|
<el-form-item label="耗材信息代码" prop="conCode">
|
||||||
|
<el-input v-model="ruleForm.conCode" placeholder="请输入耗材信息名称"></el-input>
|
||||||
|
</el-form-item>
|
||||||
<el-form-item label="耗材价格" prop="price">
|
<el-form-item label="耗材价格" prop="price">
|
||||||
<el-input v-model="ruleForm.price" placeholder="请输入耗材价格"></el-input>
|
<el-input v-model="ruleForm.price" placeholder="请输入耗材价格"></el-input>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
|
|
@ -386,7 +394,7 @@ export default {
|
||||||
},
|
},
|
||||||
// 选择的类型
|
// 选择的类型
|
||||||
tableDatatypetable(item) {
|
tableDatatypetable(item) {
|
||||||
this.ruleForm.conCode = item.conTypeCode
|
// this.ruleForm.conCode = item.conTypeCode
|
||||||
this.ruleForm.conNames = item.conTypeName
|
this.ruleForm.conNames = item.conTypeName
|
||||||
this.ruleForm.conTypeId = item.id
|
this.ruleForm.conTypeId = item.id
|
||||||
this.typedialogshow = false
|
this.typedialogshow = false
|
||||||
|
|
|
||||||
|
|
@ -472,11 +472,10 @@ export default {
|
||||||
});
|
});
|
||||||
this.informationdialogshowedit = false
|
this.informationdialogshowedit = false
|
||||||
} else {
|
} else {
|
||||||
|
let { id, consInfoId, surplusStock,isDistribute } = this.addSelect[0]
|
||||||
|
// isDistribute1为共享库存-商品,0不共享是多规格
|
||||||
let { id, consInfoId, surplusStock } = this.addSelect[0]
|
// 如果isDistribute为0 是多规格的时候
|
||||||
// 1为共享库存
|
if (isDistribute != 1) {
|
||||||
if (this.addSelect[0].isDistribute != 1) {
|
|
||||||
surplusStock = this.addSelect[0].skuList[0].surplusStock
|
surplusStock = this.addSelect[0].skuList[0].surplusStock
|
||||||
}
|
}
|
||||||
let obj = {
|
let obj = {
|
||||||
|
|
@ -490,6 +489,9 @@ export default {
|
||||||
ele.skuId = ele.id
|
ele.skuId = ele.id
|
||||||
ele.conInfoId = consInfoId
|
ele.conInfoId = consInfoId
|
||||||
// ele.surplusStock = surplusStock
|
// ele.surplusStock = surplusStock
|
||||||
|
if (isDistribute == 1) {
|
||||||
|
ele.surplusStock = surplusStock
|
||||||
|
}
|
||||||
if (!ele.skuId || !ele.surplusStock) {
|
if (!ele.skuId || !ele.surplusStock) {
|
||||||
isgongx = true
|
isgongx = true
|
||||||
} else {
|
} else {
|
||||||
|
|
@ -500,18 +502,9 @@ export default {
|
||||||
this.$message.error('请选择耗材信息与输入耗材值')
|
this.$message.error('请选择耗材信息与输入耗材值')
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
obj.skuInfos = this.addSelect[0].skuList
|
|
||||||
// } else {
|
|
||||||
|
|
||||||
// if (!consInfoId) {
|
obj.skuInfos = this.addSelect[0].skuList
|
||||||
// this.$message.error('请选择耗材信息')
|
|
||||||
// return
|
|
||||||
// }
|
|
||||||
// if (!surplusStock) {
|
|
||||||
// this.$message.error('请输入耗材值')
|
|
||||||
// return
|
|
||||||
// }
|
|
||||||
// }
|
|
||||||
await posttbProskuCons(obj)
|
await posttbProskuCons(obj)
|
||||||
this.$message({
|
this.$message({
|
||||||
message: '新增成功',
|
message: '新增成功',
|
||||||
|
|
@ -519,12 +512,6 @@ export default {
|
||||||
});
|
});
|
||||||
this.ALLisDistribute = null
|
this.ALLisDistribute = null
|
||||||
this.dialogshow = false
|
this.dialogshow = false
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
this.$refs[formName].resetFields()
|
this.$refs[formName].resetFields()
|
||||||
this.getTableData()
|
this.getTableData()
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue