|
@@ -117,14 +117,17 @@ import { steelInterface } from "@/api/modules/thirdBaseApi";
|
|
|
steelInterface.edbAdd({List:this.edbForm.edbDataList}).then(res=>{
|
|
|
if (res.Ret !== 200) return;
|
|
|
this.isAddLoading = true;
|
|
|
- console.log(this.edbForm.edbDataList);
|
|
|
+ // console.log(this.edbForm.edbDataList);
|
|
|
let edbItem = this.edbForm.edbDataList.find(it => it.IndexCode.toUpperCase() == res.Data.IndexCode.toUpperCase())
|
|
|
- if(!edbItem) return
|
|
|
+ if(!edbItem){
|
|
|
+ edbItem=this.edbForm.edbDataList[0]
|
|
|
+ }
|
|
|
let edbIndexCurrent = edbItem?edbItem.edbIndex:0
|
|
|
let selectClassifyNodes=this.$refs['classifyCascader'+edbIndexCurrent][0].getCheckedNodes()[0].path
|
|
|
this.emitParams={
|
|
|
code: res.Data.UniqueCode,
|
|
|
id: res.Data.BaseFromMysteelChemicalIndexId,
|
|
|
+ indexCode:res.Data.IndexCode,
|
|
|
selectClassifyNodes
|
|
|
}
|
|
|
this.getAddBack=true
|
|
@@ -154,7 +157,7 @@ import { steelInterface } from "@/api/modules/thirdBaseApi";
|
|
|
cancelHandle() {
|
|
|
this.isAddLoading = false;
|
|
|
this.edbForm={edbDataList:[{edbIndex:1,IndexCode:'',BaseFromMysteelChemicalClassifyId:''}]}
|
|
|
- this.$refs.edbFormDataListRef.resetFields();
|
|
|
+ this.$refs.edbFormDataListRef && this.$refs.edbFormDataListRef.resetFields();
|
|
|
this.$emit("update:isOpenDialog", false);
|
|
|
if(this.getAddBack){
|
|
|
this.$emit("successCallback", this.emitParams);
|