Commit a9891cc3 authored by kaitly205422@163.com's avatar kaitly205422@163.com

固有风险风险等级已选附件丢失

parent a1d4c276
...@@ -11,6 +11,7 @@ ...@@ -11,6 +11,7 @@
<div id="app"> <div id="app">
<!-- :style="{ height: showTab ?appHeight:'100%' }" 之前是给id为app-content 设置的内联样式 id="app-content" --> <!-- :style="{ height: showTab ?appHeight:'100%' }" 之前是给id为app-content 设置的内联样式 id="app-content" -->
<div> <div>
<span v-for="item in cachePage" :key="item">{{ item }}</span>
<transition :name="transitionName"> <transition :name="transitionName">
<keep-alive :include="cachePage"> <keep-alive :include="cachePage">
<router-view class="router-view" /> <router-view class="router-view" />
...@@ -36,7 +37,7 @@ export default { ...@@ -36,7 +37,7 @@ export default {
headH: "", headH: "",
screenH: "", screenH: "",
transitionName: "slide-left", transitionName: "slide-left",
cachePage: ["riskAdd"], cachePage: ["riskAdd", "addInherent"],
// 不需要展示底部tabbar的页面 // 不需要展示底部tabbar的页面
noTab: [ noTab: [
"login", "login",
...@@ -151,6 +152,10 @@ export default { ...@@ -151,6 +152,10 @@ export default {
this.handleCache("riskTaskList", to.name, "taskLedger"); this.handleCache("riskTaskList", to.name, "taskLedger");
} else if (to.name == 'riskView' || from.name == 'riskInherent') { } else if (to.name == 'riskView' || from.name == 'riskInherent') {
this.handleCache("addInherent", to.name, "riskInherent"); this.handleCache("addInherent", to.name, "riskInherent");
} else if (to.name === 'resultPage') {
this.handleCache("addCurrent", to.name, "addCurrent");
} else if (to.name === 'resultPage') {
this.handleCache("addInherent", to.name, "addInherent");
} }
// 列表页面动态添加缓存 // 列表页面动态添加缓存
......
...@@ -314,7 +314,7 @@ ...@@ -314,7 +314,7 @@
<van-popup v-model="measuresDept" position="bottom" :style="{ height: '100%' }"> <van-popup v-model="measuresDept" position="bottom" :style="{ height: '100%' }">
<div class="van-picker__toolbar" style="position: absolute; width: 100%; top: 0"> <div class="van-picker__toolbar" style="position: absolute; width: 100%; top: 0">
<button type="button" class="van-picker__cancel" v-on:click=" <button type="button" class="van-picker__cancel" v-on:click="
{ {
form.measuresDeptId = 0; form.measuresDeptId = 0;
projectDept = false; projectDept = false;
} }
...@@ -432,7 +432,7 @@ ...@@ -432,7 +432,7 @@
<van-popup v-model="measuresDept" position="bottom" :style="{ height: '100%' }"> <van-popup v-model="measuresDept" position="bottom" :style="{ height: '100%' }">
<div class="van-picker__toolbar" style="position: absolute; width: 100%; top: 0"> <div class="van-picker__toolbar" style="position: absolute; width: 100%; top: 0">
<button type="button" class="van-picker__cancel" v-on:click=" <button type="button" class="van-picker__cancel" v-on:click="
{ {
form.measuresDeptId = 0; form.measuresDeptId = 0;
projectDept = false; projectDept = false;
} }
...@@ -477,19 +477,11 @@ export default { ...@@ -477,19 +477,11 @@ export default {
addFloor, addFloor,
}, },
activated() { activated() {
console.log('activated')
this.showSetRank = false; // 再次关闭弹出层 以防万一 this.showSetRank = false; // 再次关闭弹出层 以防万一
this.getList(); debugger;
this.$bus.$on("riskLevelBus", (res) => { this.showGradeDialog = false;
this.showSetRank = false; // 再次关闭弹出层 以防万一 this.$set(this.form, 'level', sessionStorage.getItem("level"));
console.log(Boolean(res));
if (res) {
this.riskRank = res;
} else {
this.setRank = "";
}
// 销毁一下监听事件 不然会越加越多
this.$bus.$off("riskLevelBus");
});
}, },
beforeRouteEnter(to, from, next) { beforeRouteEnter(to, from, next) {
if (from.name == "riskInherent") { if (from.name == "riskInherent") {
...@@ -598,7 +590,16 @@ export default { ...@@ -598,7 +590,16 @@ export default {
buildingIds: "", buildingIds: "",
}; };
}, },
created() { mounted() {
// if (sessionStorage.getItem("buildingId")) {
// this.form.buildingId = sessionStorage.getItem("buildingId");
// }
// if (sessionStorage.getItem("inherenForm") != "") {
// this.form = JSON.parse(sessionStorage.getItem("inherenForm"));
// if (sessionStorage.getItem("level")) {
// this.$set(this.form, 'level', sessionStorage.getItem("level"))
// }
// } else {
if (this.$route.params.inherentId || sessionStorage.getItem("inherentId")) { if (this.$route.params.inherentId || sessionStorage.getItem("inherentId")) {
this.inherentId = this.inherentId =
this.$route.params.inherentId || sessionStorage.getItem("inherentId"); this.$route.params.inherentId || sessionStorage.getItem("inherentId");
...@@ -606,15 +607,7 @@ export default { ...@@ -606,15 +607,7 @@ export default {
this.$route.params.buildingId || sessionStorage.getItem("buildingId"); this.$route.params.buildingId || sessionStorage.getItem("buildingId");
this.postReturnEcho(); this.postReturnEcho();
} }
}, // }
mounted() {
if (sessionStorage.getItem("buildingId")) {
this.form.buildingId = sessionStorage.getItem("buildingId");
}
if (sessionStorage.getItem("inherenForm") != "") {
this.form = JSON.parse(sessionStorage.getItem("inherenForm"));
this.form.level = sessionStorage.getItem("level");
}
}, },
methods: { methods: {
createFloor() { createFloor() {
...@@ -644,7 +637,6 @@ export default { ...@@ -644,7 +637,6 @@ export default {
if (item.measuresUserName == e) if (item.measuresUserName == e)
this.form.measuresUserPhone = item.measuresUserPhone; this.form.measuresUserPhone = item.measuresUserPhone;
}); });
console.log(e, 1111);
}); });
}, },
measuresDeptNameChange(e) { measuresDeptNameChange(e) {
......
...@@ -298,7 +298,7 @@ ...@@ -298,7 +298,7 @@
<van-popup v-model="measuresDept" position="bottom" :style="{ height: '100%' }"> <van-popup v-model="measuresDept" position="bottom" :style="{ height: '100%' }">
<div class="van-picker__toolbar" style="position: absolute; width: 100%; top: 0"> <div class="van-picker__toolbar" style="position: absolute; width: 100%; top: 0">
<button type="button" class="van-picker__cancel" v-on:click=" <button type="button" class="van-picker__cancel" v-on:click="
{ {
form.measuresDeptId = 0; form.measuresDeptId = 0;
projectDept = false; projectDept = false;
} }
...@@ -355,12 +355,14 @@ export default { ...@@ -355,12 +355,14 @@ export default {
activated() { activated() {
this.showSetRank = false; // 再次关闭弹出层 以防万一 this.showSetRank = false; // 再次关闭弹出层 以防万一
if (this.$route.params.taskId) { this.showGradeDialog = false;
this.isShowreturnCause = true; this.$set(this.form, 'level', sessionStorage.getItem("level"));
this.text = "风险上报退回"; // if (this.$route.params.taskId) {
this.taskId = this.$route.params.taskId; // this.isShowreturnCause = true;
this.postReturnEcho(); // this.text = "风险上报退回";
} // this.taskId = this.$route.params.taskId;
// this.postReturnEcho();
// }
// this.getList(); // this.getList();
// this.$bus.$on("riskLevelBus", (res) => { // this.$bus.$on("riskLevelBus", (res) => {
...@@ -485,7 +487,6 @@ export default { ...@@ -485,7 +487,6 @@ export default {
}; };
}, },
created() { created() {
console.log(this.$route)
var userInfo = getUserInfo(); var userInfo = getUserInfo();
this.form.buildingIds = this.form.buildingIds =
this.$route.params.buildingId || sessionStorage.getItem("buildingId"); this.$route.params.buildingId || sessionStorage.getItem("buildingId");
...@@ -502,7 +503,11 @@ export default { ...@@ -502,7 +503,11 @@ export default {
mounted() { mounted() {
if (sessionStorage.getItem("inherenForm") != "") { if (sessionStorage.getItem("inherenForm") != "") {
this.form = JSON.parse(sessionStorage.getItem("inherenForm")); this.form = JSON.parse(sessionStorage.getItem("inherenForm"));
this.form.level = sessionStorage.getItem("level"); if (sessionStorage.getItem("level")) {
setTimeout(() => {
this.form.level = sessionStorage.getItem("level");
}, 0)
}
} else if (this.$store.state.inherentTemplate) { } else if (this.$store.state.inherentTemplate) {
this.form = { ...this.form, ...this.$store.state.inherentTemplate }; this.form = { ...this.form, ...this.$store.state.inherentTemplate };
} }
......
...@@ -9,11 +9,11 @@ module.exports = { ...@@ -9,11 +9,11 @@ module.exports = {
proxy: { proxy: {
//配置跨域 //配置跨域
"/app-api": { "/app-api": {
// target: "http://192.168.4.232:8080/", //这里是后台的地址 target: "http://192.168.4.232:8080/", //这里是后台的地址
// target: "http://localhost:8080/", //这里是后台的地址 // target: "http://localhost:8080/", //这里是后台的地址
// target: 'http://192.168.15.124:8080/', //这里是杨帆的地址 // target: 'http://192.168.15.124:8080/', //这里是杨帆的地址
// target: "http://192.168.14.152:8080/", //这里是鲍德的地址 // target: "http://192.168.14.152:8080/", //这里是鲍德的地址
target: "http://192.168.15.230:8080/", //这里是晓晋的地址 // target: "http://192.168.15.230:8080/", //这里是晓晋的地址
// target: 'http://localhost:8081/', //这里是后台的地址 // target: 'http://localhost:8081/', //这里是后台的地址
// target: 'http://127.0.0.1:8080', //这里是后台的地址 // target: 'http://127.0.0.1:8080', //这里是后台的地址
ws: true, ws: true,
......
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