d9ecb329 by 杨威

新建流程修改

1 parent 438df8cd
...@@ -32,10 +32,23 @@ ...@@ -32,10 +32,23 @@
32 <span>{{ item.name }}</span> 32 <span>{{ item.name }}</span>
33 </div> 33 </div>
34 <div class="top-items"> 34 <div class="top-items">
35 <el-menu :default-active="activeIndex" class="el-menu-demo" mode="horizontal" @select="handleSelect" :router="true"> 35 <el-menu
36 :default-active="activeIndex"
37 class="el-menu-demo"
38 mode="horizontal"
39 @select="handleSelect"
40 :router="true"
41 >
36 <el-submenu index="2"> 42 <el-submenu index="2">
37 <template slot="title">临时网页开发路由跳转</template> 43 <template slot="title"
38 <el-menu-item v-for="(item,index) in tempTab" :index="item.path" :key="'tempTab'+index">{{item.name}}</el-menu-item> 44 >临时网页开发路由跳转</template
45 >
46 <el-menu-item
47 v-for="(item, index) in tempTab"
48 :index="item.path"
49 :key="'tempTab' + index"
50 >{{ item.name }}</el-menu-item
51 >
39 </el-submenu> 52 </el-submenu>
40 </el-menu> 53 </el-menu>
41 </div> 54 </div>
...@@ -43,6 +56,13 @@ ...@@ -43,6 +56,13 @@
43 <div class="header-bottom"> 56 <div class="header-bottom">
44 <Navigation ref="navigation"></Navigation> 57 <Navigation ref="navigation"></Navigation>
45 </div> 58 </div>
59 <el-dialog
60 title="新建"
61 :visible.sync="dialogVisible"
62 width="40%"
63 >
64 <Create @closeDialog="closeDialog"></Create>
65 </el-dialog>
46 </el-header> 66 </el-header>
47 <el-main> 67 <el-main>
48 <router-view /> 68 <router-view />
...@@ -55,16 +75,18 @@ ...@@ -55,16 +75,18 @@
55 import util from "@/libs/util.js"; 75 import util from "@/libs/util.js";
56 import screenfull from "screenfull"; 76 import screenfull from "screenfull";
57 import Navigation from "../components/IvyElement/navigation"; 77 import Navigation from "../components/IvyElement/navigation";
78 import Create from "./panel/create/index";
58 import LineTree from "../components/lineTree/lineTree"; 79 import LineTree from "../components/lineTree/lineTree";
59 import { setTimeout } from "timers"; 80 import { setTimeout } from "timers";
60 export default { 81 export default {
61 components: { 82 components: {
62 Navigation, 83 Navigation,
63 LineTree, 84 LineTree,
85 Create,
64 }, 86 },
65 data() { 87 data() {
66 return { 88 return {
67 activeIndex:'1', 89 activeIndex: "1",
68 navigationList: [], 90 navigationList: [],
69 isActive: false, 91 isActive: false,
70 textLogo: false, 92 textLogo: false,
...@@ -72,43 +94,43 @@ export default { ...@@ -72,43 +94,43 @@ export default {
72 defaultActive: "", 94 defaultActive: "",
73 headTop: [ 95 headTop: [
74 { 96 {
75 path:"/create", 97 path: "/create",
76 select: false, 98 select: false,
77 }, 99 },
78 { 100 {
79 path:"/add", 101 path: "/add",
80 select: false, 102 select: false,
81 }, 103 },
82 { 104 {
83 path:"/modify", 105 path: "/modify",
84 select: false, 106 select: false,
85 }, 107 },
86 { 108 {
87 path:"/change", 109 path: "/change",
88 select: false, 110 select: false,
89 }, 111 },
90 { 112 {
91 path:"/search", 113 path: "/search",
92 select: false, 114 select: false,
93 } 115 },
94 ], 116 ],
95 tempTab:[ 117 tempTab: [
96 { 118 {
97 path:'/zrz', 119 path: "/zrz",
98 name:'自然幢' 120 name: "自然幢",
99 }, 121 },
100 { 122 {
101 path:'/dz', 123 path: "/dz",
102 name:'多幢' 124 name: "多幢",
103 }, 125 },
104 { 126 {
105 path:'/h', 127 path: "/h",
106 name:'户' 128 name: "户",
107 }, 129 },
108 { 130 {
109 path:'/zd', 131 path: "/zd",
110 name:'宗地' 132 name: "宗地",
111 } 133 },
112 ], 134 ],
113 // 上导航选中id 135 // 上导航选中id
114 indId: undefined, 136 indId: undefined,
...@@ -144,14 +166,14 @@ export default { ...@@ -144,14 +166,14 @@ export default {
144 children: [ 166 children: [
145 { 167 {
146 label: "宗地代码1933", 168 label: "宗地代码1933",
147 isZD:true 169 isZD: true,
148 }, 170 },
149 { 171 {
150 label: "自然幢2100", 172 label: "自然幢2100",
151 isZD:false 173 isZD: false,
152 }, 174 },
153 ], 175 ],
154 } 176 },
155 ], 177 ],
156 }, 178 },
157 { 179 {
...@@ -177,6 +199,7 @@ export default { ...@@ -177,6 +199,7 @@ export default {
177 children: [], 199 children: [],
178 }, 200 },
179 ], 201 ],
202 dialogVisible: false,
180 }; 203 };
181 }, 204 },
182 computed: { 205 computed: {
...@@ -264,13 +287,19 @@ export default { ...@@ -264,13 +287,19 @@ export default {
264 } 287 }
265 }, 288 },
266 selectTopItems(ind) { 289 selectTopItems(ind) {
267 this.indId = ind; 290 if (ind == 0) {
268 // this.menuSelect(this.navigationList, ind); 291 //点击新建,弹框
269 // this.$store.dispatch("setTabs/init_tabs"); 292 this.dialogVisible = true;
270 // this.$store.dispatch("setTabs/set_active_index", "/panel"); 293 } else {
271 this.$router.push(this.headTop[ind].path); 294 this.dialogVisible = false;
272 this.navSelect(ind); 295 this.indId = ind;
273 // util.cookies.set("indId", ind); 296 // this.menuSelect(this.navigationList, ind);
297 // this.$store.dispatch("setTabs/init_tabs");
298 // this.$store.dispatch("setTabs/set_active_index", "/panel");
299 this.$router.push(this.headTop[ind].path);
300 this.navSelect(ind);
301 // util.cookies.set("indId", ind);
302 }
274 }, 303 },
275 // 上导航选中id 304 // 上导航选中id
276 navSelect(id) { 305 navSelect(id) {
...@@ -290,11 +319,15 @@ export default { ...@@ -290,11 +319,15 @@ export default {
290 screenfull.toggle(); 319 screenfull.toggle();
291 }, 320 },
292 //树控件点击事件 321 //树控件点击事件
293 itemClick(data){ 322 itemClick(data) {
294 console.log(data); 323 console.log(data);
295 }, 324 },
296 handleSelect(key, keyPath) { 325 handleSelect(key, keyPath) {
297 console.log(key, keyPath); 326 console.log(key, keyPath);
327 },
328 //关闭新建子组件弹框
329 closeDialog(){
330 this.dialogVisible = false;
298 } 331 }
299 }, 332 },
300 }; 333 };
...@@ -399,7 +432,7 @@ export default { ...@@ -399,7 +432,7 @@ export default {
399 } 432 }
400 433
401 .el-main { 434 .el-main {
402 background-color: #F1F4FC; 435 background-color: #f1f4fc;
403 color: #333; 436 color: #333;
404 // text-align: center; 437 // text-align: center;
405 // line-height: 160px; 438 // line-height: 160px;
......