|
@@ -171,8 +171,6 @@ import { getAlltree } from "@/api/manager/wbstree";
|
|
|
import { getDictionary } from "@/api/system/dict";
|
|
|
import { dictionarydataType } from "@/api/exctab/editelement";
|
|
|
import {
|
|
|
- tabLazytree,
|
|
|
- getExcelHtmlCol,
|
|
|
excelType,
|
|
|
submitExcelRelationWbsTreeAndElement,
|
|
|
getWbsTypeList,
|
|
@@ -180,11 +178,8 @@ import {
|
|
|
cancelRelation,
|
|
|
saveRelation,
|
|
|
searchNodeTables,
|
|
|
- tabLazytreeAll,
|
|
|
- exctabcellSave,
|
|
|
- exctabcellRemove,
|
|
|
- exctabcellUpdate,
|
|
|
-} from "@/api/exctab/excelmodel";
|
|
|
+ savelinktableInfo
|
|
|
+ } from "@/api/exctab/excelmodel";
|
|
|
import { getColByTabId } from "@/api/manager/AdjustForm";
|
|
|
|
|
|
export default {
|
|
@@ -407,10 +402,16 @@ export default {
|
|
|
});
|
|
|
},
|
|
|
relationMD(row, type) {
|
|
|
+ console.log('关联元素表',row);
|
|
|
//关联取消关联
|
|
|
row.loading = true;
|
|
|
if (type == "关联") {
|
|
|
- saveRelation(row.id, this.from.id, this.tableData)
|
|
|
+ // saveRelation(row.id, this.from.id, this.tableData)
|
|
|
+ savelinktableInfo({
|
|
|
+ linkids: row.id,
|
|
|
+ tabId: this.from.id,
|
|
|
+ type:1
|
|
|
+ })
|
|
|
.then(() => {
|
|
|
row.checknd = true;
|
|
|
row.isLinkTable = 2;
|
|
@@ -501,17 +502,26 @@ export default {
|
|
|
});
|
|
|
return;
|
|
|
}
|
|
|
+ savelinktableInfo({
|
|
|
+ linkids: this.selectNodeIds,
|
|
|
+ tabId: this.from.id,
|
|
|
+ type:2
|
|
|
+ }).then((res)=>{
|
|
|
+ console.log(res,'添加元素表');
|
|
|
|
|
|
- this.submitExcelRelationWbsTreeAndElement({
|
|
|
- nodeName: this.addElementForm.nodeName,
|
|
|
- tableType: this.addElementForm.tableType,
|
|
|
- tableOwner: this.addElementForm.tableOwner,
|
|
|
- wbsId: this.addElementForm.wbsId,
|
|
|
- elementList: this.tableData,
|
|
|
- nodeIds: this.selectNodeIds,
|
|
|
- excelTabId: this.from.id,
|
|
|
- submitStatus: 2,
|
|
|
- });
|
|
|
+ })
|
|
|
+
|
|
|
+ // this.submitExcelRelationWbsTreeAndElement({
|
|
|
+ // nodeName: this.addElementForm.nodeName,
|
|
|
+ // tableType: this.addElementForm.tableType,
|
|
|
+ // tableOwner: this.addElementForm.tableOwner,
|
|
|
+ // wbsId: this.addElementForm.wbsId,
|
|
|
+ // elementList: this.tableData,
|
|
|
+ // nodeIds: this.selectNodeIds,
|
|
|
+ // excelTabId: this.from.id,
|
|
|
+ // submitStatus: 2,
|
|
|
+ // });
|
|
|
+
|
|
|
} else {
|
|
|
this.$message({
|
|
|
type: "warning",
|
|
@@ -592,7 +602,6 @@ export default {
|
|
|
ele.eAllowDeviation = ele.textDeviation;
|
|
|
});
|
|
|
const { data: res } = await submitExcelRelationWbsTreeAndElement(da);
|
|
|
- console.log(res);
|
|
|
if (res.code == 200) {
|
|
|
this.$message({
|
|
|
type: "success",
|
|
@@ -602,11 +611,12 @@ export default {
|
|
|
this.AssociatedPublicClose();
|
|
|
}
|
|
|
},
|
|
|
+
|
|
|
async getColByTabId() {
|
|
|
//获取字段信息
|
|
|
- // const { data: res } = await getColByTabId({tabId: this.from.id });
|
|
|
+ const { data: res } = await getColByTabId({tabId: this.from.id });
|
|
|
|
|
|
- const { data: res } = await getColByTabId({tabId: '1537614072773054466' });
|
|
|
+ // const { data: res } = await getColByTabId({tabId: '1537614072773054466' });
|
|
|
console.log(res);
|
|
|
if (res.code === 200) {
|
|
|
res.data.forEach((element) => {
|