代码同步 02.14

master
张博文 3 months ago
parent d4bda38391
commit d867b7e7a0

@ -66,14 +66,6 @@
v-hasPermi="['product:harvest-info:delete']">复制</el-button> v-hasPermi="['product:harvest-info:delete']">复制</el-button>
<el-button size="mini" type="text" @click="handleDelete(row)" <el-button size="mini" type="text" @click="handleDelete(row)"
v-hasPermi="['product:harvest-info:delete']">删除</el-button> v-hasPermi="['product:harvest-info:delete']">删除</el-button>
<!--
<el-button v-if="row.blockState == 0" size="mini" type="text" @click="handleState(row,'upChain')"
v-hasPermi="['product:harvest-info:delete']">上传</el-button>
<el-button v-if="row.blockState == 1" size="mini" type="text" @click="handleState(row,'freeze')"
v-hasPermi="['product:harvest-info:delete']">冻结</el-button>
<el-button v-if="row.blockState == 2" size="mini" type="text" @click="handleState(row,'active')"
v-hasPermi="['product:harvest-info:delete']">激活</el-button>
-->
</template> </template>
</el-table-column> </el-table-column>
<div slot="empty"> <div slot="empty">
@ -585,25 +577,10 @@ export default {
} }
}, },
handleDeleteGoods(index,row){ handleDeleteGoods(index, row) {
let id = this.form.id; this.inputsList.splice(index, 1);
if( id ){ this.inputCheckedIdList.splice(index, 1);
let ids = row.id; this.form.harvestBatchs.splice(index, 1);
deleteHarvestBatchs({
ids,
}).then((res)=>{
console.log('删除成功');
let i;
this.inputCheckedIdList.map((item,index)=>{
if(item == row.goodsId) i=index;
});
this.inputsList.splice(i,1)
this.inputCheckedIdList.splice(i,1)
this.form.harvestBatchs.splice(index,1)
});
}else{
this.form.harvestBatchs.splice(index,1)
}
}, },
changeBusiness(){ changeBusiness(){

@ -680,8 +680,13 @@ export default {
}).catch(() => {}); }).catch(() => {});
}, },
// //
importModel(){ importModel() {
this.form.inspectionItems = this.tempList[this.templateId].inspectionItems; this.form.inspectionItems = this.tempList[this.templateId].inspectionItems.map(item => {
return {
...item,
id: null,
}
});
}, },
// //
saveModel(){ saveModel(){

Loading…
Cancel
Save