Commit 147482e9 authored by 刘殿昕's avatar 刘殿昕

Merge branch 'ldx' into dev

parents 990d3cf8 f1862490
...@@ -127,7 +127,7 @@ export default { ...@@ -127,7 +127,7 @@ export default {
buttonList.forEach((item) => { buttonList.forEach((item) => {
item.state = false; item.state = false;
}); });
buttonList.unshift({ id: 0, name: "全部", state: false }); buttonList.unshift({ id: 0, name: "全部", state: true });
buttonList.push({ id: "cloud", name: "云资源", state: false }); buttonList.push({ id: "cloud", name: "云资源", state: false });
buttonList.push({ id: "app", name: "应用镜像", state: false }); buttonList.push({ id: "app", name: "应用镜像", state: false });
this.buttonList = buttonList; this.buttonList = buttonList;
...@@ -147,6 +147,12 @@ export default { ...@@ -147,6 +147,12 @@ export default {
} }
this.buttonList[0].state = !this.buttonList[0].state; this.buttonList[0].state = !this.buttonList[0].state;
} }
let i = this.buttonList.findIndex((item) => {
return item.state == true;
});
if (i == -1) {
this.buttonList[0].state = true;
}
this.pagination.page = 1; this.pagination.page = 1;
this.getData(); this.getData();
}, },
...@@ -179,11 +185,7 @@ export default { ...@@ -179,11 +185,7 @@ export default {
} }
} }
}); });
if (arr.length == 0) { // console.log(service, app, resource);
service = 1;
app = 1;
resource = 1;
}
let params = { let params = {
select: this.search, select: this.search,
page: this.pagination.page, page: this.pagination.page,
......
...@@ -564,7 +564,7 @@ ...@@ -564,7 +564,7 @@
</div> </div>
</el-tab-pane> </el-tab-pane>
</el-tabs> </el-tabs>
<div class="btn_footer"> <div class="btn_footer" v-if="!(activeName == 1 && !formShow)">
<el-button class="submit" @click="submitApp">提交申请</el-button> <el-button class="submit" @click="submitApp">提交申请</el-button>
</div> </div>
</block-radius> </block-radius>
...@@ -1108,6 +1108,8 @@ export default { ...@@ -1108,6 +1108,8 @@ export default {
this.dataDiskList.forEach((item, index) => { this.dataDiskList.forEach((item, index) => {
item.name = `磁盘${index + 1}`; item.name = `磁盘${index + 1}`;
}); });
this.form.link_man = paramsOld.apply_connect_username;
this.form.phone = paramsOld.apply_connect_mobile;
this.formShow = true; this.formShow = true;
} else { } else {
this.formShow = false; this.formShow = false;
......
...@@ -199,7 +199,7 @@ export default { ...@@ -199,7 +199,7 @@ export default {
}); });
this.loop = 0; this.loop = 0;
datas.nodeList.forEach((item) => { datas.nodeList.forEach((item) => {
this.checkClosedLoop(datas.linkList, item.id, end_id); this.checkClosedLoop(datas.linkList, item.id, item.id, end_id);
}); });
datas.linkList.forEach((item) => { datas.linkList.forEach((item) => {
if (start_id == item.endId) { if (start_id == item.endId) {
...@@ -235,28 +235,33 @@ export default { ...@@ -235,28 +235,33 @@ export default {
return false; return false;
} else if (this.loop != 0) { } else if (this.loop != 0) {
this.$message({ this.$message({
message: "存在闭环", message: "不能连接本节点之前的节点",
type: "warning", type: "warning",
}); });
} else { } else {
return datas; return datas;
} }
}, },
checkClosedLoop(arr, id, endding_id) { checkClosedLoop(arr, now_id, id, endding_id) {
// let self = this; let self = this;
// arr.forEach((item) => { if (self.loop == 0) {
// if (item.startId == id) { arr.forEach((item) => {
// if (item.endId == endding_id) { if (item.startId == now_id) {
// return false; if (item.endId == endding_id) {
// } else if (item.endId == id) { return false;
// self.loop++; } else if (item.endId == id) {
// } else { console.log("has loop");
// this.checkClosedLoop(arr, item.endId, endding_id); self.loop++;
// } } else {
// } else { this.checkClosedLoop(arr, item.endId, id, endding_id);
// return false; }
// } } else {
// }); return false;
}
});
} else {
return false;
}
}, },
backToList() { backToList() {
this.$router.push("/progress/designer"); this.$router.push("/progress/designer");
......
...@@ -184,7 +184,7 @@ export default { ...@@ -184,7 +184,7 @@ export default {
}); });
this.loop = 0; this.loop = 0;
datas.nodeList.forEach((item) => { datas.nodeList.forEach((item) => {
this.checkClosedLoop(datas.linkList, item.id, end_id); this.checkClosedLoop(datas.linkList, item.id, item.id, end_id);
}); });
datas.linkList.forEach((item) => { datas.linkList.forEach((item) => {
if (start_id == item.endId) { if (start_id == item.endId) {
...@@ -220,28 +220,33 @@ export default { ...@@ -220,28 +220,33 @@ export default {
return false; return false;
} else if (this.loop != 0) { } else if (this.loop != 0) {
this.$message({ this.$message({
message: "存在闭环", message: "不能连接本节点之前的节点",
type: "warning", type: "warning",
}); });
} else { } else {
return datas; return datas;
} }
}, },
checkClosedLoop(arr, id, endding_id) { checkClosedLoop(arr, now_id, id, endding_id) {
// let self = this; let self = this;
// arr.forEach((item) => { if (self.loop == 0) {
// if (item.startId == id) { arr.forEach((item) => {
// if (item.endId == endding_id) { if (item.startId == now_id) {
// return false; if (item.endId == endding_id) {
// } else if (item.endId == id) { return false;
// self.loop++; } else if (item.endId == id) {
// } else { console.log("has loop");
// this.checkClosedLoop(arr, item.endId, endding_id); self.loop++;
// } } else {
// } else { this.checkClosedLoop(arr, item.endId, id, endding_id);
// return false; }
// } } else {
// }); return false;
}
});
} else {
return false;
}
}, },
backToList() { backToList() {
this.$router.push("/progress/designer"); this.$router.push("/progress/designer");
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment