liyuanpeng 3 years ago
parent
commit
ac3ba7c343

+ 2 - 2
public/index.html

@@ -18,8 +18,8 @@
   <div id="app"></div>
   <!-- built files will be auto injected -->
   <script type="text/javascript">
-    window.staticHost = 'http://10.230.26.15:8000/spfm';
-    // window.staticHost = 'http://114.215.71.182:29600';
+    // window.staticHost = 'http://10.230.26.15:8000/spfm';
+    window.staticHost = 'http://114.215.71.182:29600';
     // window.staticHost = 'http://192.168.2.143:9600/';
   </script>
 </body>

+ 91 - 72
src/components/p-menu-item.vue

@@ -1,88 +1,107 @@
 <template>
-    <div>
-        <template v-for="(menu, index) in menuData">
-            <el-submenu :key="menu.index" :index="
+	<div>
+		<template v-for="(menu, index) in menuData">
+			<el-submenu :key="menu.index" :index="
           menu.rountPath == '' || menu.rountPath == '#'
             ? menu.name + index
             : menu.rountPath
-        "
-                v-if="menu.children" @click="handelRouterTo(menu)">
-                <template slot="title">
-                    <i class="el-icon-location"></i>
-                    <el-tooltip class="item" effect="dark" :content="menu.name" placement="right" v-if="menu.name.length > 9"><span>{{ menu.name }}</span>
-                    </el-tooltip>
-                    <span v-else>{{ menu.name }}</span>
-                </template>
-                <MenuTree :menuData="menu.children"></MenuTree>
-            </el-submenu>
-            <el-menu-item v-show="menu.systemflag!=1" @click="handelRouterTo(menu)" :index="menu.rountPath == '' ? menu.name : menu.rountPath"
-                :key="menu.index" v-else>
-                <el-tooltip class="item" effect="dark" :content="menu.name" placement="right" v-if="menu.name.length > 9"><span>{{ menu.name }}</span>
-                </el-tooltip>
-                <span v-else>{{ menu.name }}</span>
-            </el-menu-item>
-        </template>
-    </div>
+        " v-if="menu.children" @click="handelRouterTo(menu)">
+				<template slot="title">
+					<i style="color: #409eff !important" class="el-icon-location"></i>
+					<el-tooltip class="item" effect="dark" :content="menu.name" placement="right"
+						v-if="menu.name.length > 9"><span>{{ menu.name }}</span>
+					</el-tooltip>
+					<span v-else>{{ menu.name }}</span>
+				</template>
+				<MenuTree :menuData="menu.children"></MenuTree>
+			</el-submenu>
+			<el-menu-item v-show="menu.systemflag != 1" @click="handelRouterTo(menu)"
+				:index="menu.rountPath == '' ? menu.name : menu.rountPath" :key="menu.index" v-else>
+				<el-tooltip class="item" effect="dark" :content="menu.name" placement="right"
+					v-if="menu.name.length > 9"><span>{{ menu.name }}</span>
+				</el-tooltip>
+				<span v-else>{{ menu.name }}</span>
+			</el-menu-item>
+		</template>
+	</div>
 </template>
 
 <script>
-    export default {
-        name: "MenuTree",
-        props: ["menuData"],
-        methods: {
-            handleOpen(e) {
-                if (e.indexOf("/") != -1) {
-                    if (this.$route.path != e) {
-                        this.$router.push(e);
-                    }
-                }
-            },
-            handleClose() {},
-            handelRouterTo(item) {
-                if(item.systemflag == '1'){
-                    return
-                }
-                for (let i = 0; i < this.$store.state.tabList.length; i++) {
-                    if (this.$store.state.tabList[i].rountPath === item.rountPath) {
-                        this.$store.state.tabList[i]=item;
-                    }
-                }
-                let set = new Set([...this.$store.state.tabList,item]);
-                set.add(item);
-                this.$store.commit("setDefaultActive", item.rountPath);
-                this.$store.commit("setTabList", Array.from(set));
-            },
-        },
-    };
+	export default {
+		name: "MenuTree",
+		props: ["menuData"],
+		methods: {
+			handleOpen(e) {
+				if (e.indexOf("/") != -1) {
+					if (this.$route.path != e) {
+						this.$router.push(e);
+					}
+				}
+			},
+			handleClose() {},
+			handelRouterTo(item) {
+				if (item.systemflag == "1") {
+					return;
+				}
+				for (let i = 0; i < this.$store.state.tabList.length; i++) {
+					if (this.$store.state.tabList[i].rountPath === item.rountPath) {
+						this.$store.state.tabList[i] = item;
+					}
+				}
+				let set = new Set([...this.$store.state.tabList, item]);
+				set.add(item);
+				this.$store.commit("setDefaultActive", item.rountPath);
+				this.$store.commit("setTabList", Array.from(set));
+			},
+		},
+	};
 </script>
+<style>
+	.el-submenu {
+		border-bottom: 1px solid #f2f2f2;
+	}
 
+	.is-opened .el-submenu__title {
+		background-color: #ecf5ff !important;
+	}
+
+	.el-submenu__title {
+		/* background-color: #ecf5ff;
+  border-radius: 30px;
+  margin-bottom: 10px; */
+	}
+
+	.el-submenu.is-active .el-submenu__title {
+		/* background-color: #ecf5ff; */
+	}
+</style>
 <style lang="scss" scoped>
-    .el-menu-item {
-        overflow: hidden;
-        text-overflow: ellipsis;
-        white-space: nowrap;
-        width: 50px;
+	.el-menu-item {
+		overflow: hidden;
+		text-overflow: ellipsis;
+		white-space: nowrap;
+		width: 50px;
 
-        span {
-            padding-right: 10px;
-        }
-    }
+		span {
+			padding-right: 10px;
+		}
+	}
 
-    .el-menu--vertical {
-        .el-menu-item {
-            width: auto !important;
+	.el-menu--vertical {
+		.el-menu-item {
+			width: auto !important;
 
-            span {
-                padding-right: 0;
-            }
-        }
-    }
+			span {
+				padding-right: 0;
+			}
+		}
+	}
 
-    .bgc {
-        background-color: #f56c6c;
-    }
+	.bgc {
+		background-color: #f56c6c;
+	}
 
-    .bgcChild {
-        background-color: #f56c6c;
-    }
+	.bgcChild {
+		background-color: #f56c6c;
+	}
 </style>

+ 151 - 185
src/components/p-menu.vue

@@ -1,203 +1,169 @@
 <template>
-  <div class="p-menu">
-    <!-- <div style="height:60px;background-color: #0b82ff;"></div> -->
-    <!-- <el-card class="card" ref="menuCard"> -->
-      <el-menu
-        class="el-menu-vertical-demo"
-        :default-active="getDefaultActive"
-        router
-        :collapse="collapse"
-        @open="handleOpen"
-        @close="handleClose"
-      >
-        <div class="menu-logo" style="height: 60px; line-height: 60px">
-          <img
-            width="95%"
-            style="text-align: center; vertical-align: middle"
-            src="../assets/newlogo.png"
-            alt=""
-          />
-        </div>
-        <!-- 引入组件 -->
-        <div class="menuScoll">
-          <menuItem :menuData="data" class="menuScoll-box"> </menuItem>
-        </div>
-      </el-menu>
-    <!-- </el-card> -->
-  </div>
+	<div class="p-menu">
+		<!-- <div style="height:60px;background-color: #0b82ff;"></div> -->
+		<!-- <el-card class="card" ref="menuCard"> -->
+		<el-menu class="el-menu-vertical-demo" :default-active="getDefaultActive" router :collapse="collapse"
+			@open="handleOpen" @close="handleClose" active-text-color="#71A6FD">
+			<div class="menu-logo" style="height: 60px; line-height: 60px">
+				<img width="95%" style="text-align: center; vertical-align: middle" src="../assets/newlogo1.png"
+					alt="" />
+			</div>
+			<!-- 引入组件 -->
+			<div class="menuScoll">
+				<menuItem :menuData="data" class="menuScoll-box">
+				</menuItem>
+			</div>
+		</el-menu>
+		<!-- </el-card> -->
+	</div>
 </template>
 
 <script>
-export default {
-  props: {
-    //菜单数据源类型Array<JsonObject>,具体格式参考data/menu-list.js
-    data: {
-      required: false,
-      type: Array,
-      default() {
-        return [];
-      },
-    },
-  },
-  components: {
-    menuItem: () => import(/* webpackChunkName: "system" */ "./p-menu-item"),
-  },
-  computed: {
-    getDefaultActive() {
-      return this.$store.state.defaultActive;
-    },
-    collapse() {
-      return this.$store.state.collapse;
-    },
-  },
-  data() {
-    return {
-      defaultActiveMenuItem: {},
-    };
-  },
-  mounted() {
-    if (this.data.length > 0) {
-      this.recursion(this.data);
-    }
-  },
-  updated() {
-    if (this.data.length > 0) {
-      // let tabList;
-      // if (this.data[0].children) {
-      //   tabList = [this.data[0].children[0]];
-      // } else {
-      //   tabList = [this.data[0]];
-      // }
-
-      //   for (let item of this.data) {
-      //     if (item.children) {
-      //       for (let childrenItem of item.children) {
-      //         if (childrenItem.rountPath == this.$route.path) {
-      //           this.handelRouterTo(childrenItem);
-      //           return;
-      //         }
-      //       }
-      //     }
-      //     if (item.rountPath == this.$route.path) {
-      //       this.handelRouterTo(item);
-      //       return;
-      //     }
-      //   }
-      this.recursion(this.data);
-      //   this.$store.commit("setDefaultActive", this.data[0].rountPath);
-      //   this.$store.commit("setTabList", tabList);
-      //   if (this.$route.path != this.data[0].rountPath) {
-      //     this.$router.push(this.data[0].rountPath);
-      //   }
-      //   this.defaultActiveMenuItem = this.data[0];
-    }
-  },
-  methods: {
-    recursion(data) {
-      for (let item of data) {
-        if (item.children != "") {
-          this.recursion(item.children);
-        } else if (item.rountPath == this.$route.path) {
-          if (item.systemflag != "1") {
-            this.handelRouterTo(item);
-            return;
-          }
-        }
-      }
-    },
-    handleOpen(e) {
-      if (e.indexOf("/") != -1) {
-        if (this.$route.path != e) {
-          this.$router.push(e);
-        }
-      }
-    },
-    handleClose() {},
-    handelRouterTo(item) {
-      if (item.systemflag == "1") {
-        return;
-      }
-      let defaults = this.$store.state.tabList.filter((row) => {
-        let rountPath = row.hasOwnProperty("rountPath")
-          ? row.rountPath
-          : row.jspUrl;
-        if (rountPath == item.rountPath) {
-          return row;
-        }
-      });
-      if (defaults.length == 1) {
-        return;
-      }
-      let set = new Set([...this.$store.state.tabList, item]);
-      set.add(item);
-      this.$store.commit("setDefaultActive", item.rountPath);
-      this.$store.commit("setTabList", Array.from(set));
-    },
-  },
-};
+	export default {
+		props: {
+			//菜单数据源类型Array<JsonObject>,具体格式参考data/menu-list.js
+			data: {
+				required: false,
+				type: Array,
+				default () {
+					return [];
+				},
+			},
+		},
+		components: {
+			menuItem: () => import( /* webpackChunkName: "system" */ "./p-menu-item"),
+		},
+		computed: {
+			getDefaultActive() {
+				return this.$store.state.defaultActive;
+			},
+			collapse() {
+				return this.$store.state.collapse;
+			},
+		},
+		data() {
+			return {
+				defaultActiveMenuItem: {},
+			};
+		},
+		mounted() {
+			if (this.data.length > 0) {
+				this.recursion(this.data);
+			}
+		},
+		updated() {
+			if (this.data.length > 0) {
+			
+				this.recursion(this.data);
+				
+			}
+		},
+		methods: {
+			recursion(data) {
+				for (let item of data) {
+					if (item.children != "") {
+						this.recursion(item.children);
+					} else if (item.rountPath == this.$route.path) {
+						if (item.systemflag != "1") {
+							this.handelRouterTo(item);
+							return;
+						}
+					}
+				}
+			},
+			handleOpen(e) {
+				if (e.indexOf("/") != -1) {
+					if (this.$route.path != e) {
+						this.$router.push(e);
+					}
+				}
+			},
+			handleClose() {},
+			handelRouterTo(item) {
+				if (item.systemflag == "1") {
+					return;
+				}
+				let defaults = this.$store.state.tabList.filter((row) => {
+					let rountPath = row.hasOwnProperty("rountPath") ?
+						row.rountPath :
+						row.jspUrl;
+					if (rountPath == item.rountPath) {
+						return row;
+					}
+				});
+				if (defaults.length == 1) {
+					return;
+				}
+				let set = new Set([...this.$store.state.tabList, item]);
+				set.add(item);
+				this.$store.commit("setDefaultActive", item.rountPath);
+				this.$store.commit("setTabList", Array.from(set));
+			},
+		},
+	};
 </script>
 <style>
-.el-menu--collapse .menu-logo {
-  background-image: url(../assets/leftlogo.png);
-  background-repeat: no-repeat;
-  background-size: 50% 50%;
-  background-position-x: 50%;
-  background-position-y: 50%;
-}
+	.el-menu--collapse .menu-logo {
+		background-image: url(../assets/leftlogo.png);
+		background-repeat: no-repeat;
+		background-size: 50% 50%;
+		background-position-x: 50%;
+		background-position-y: 50%;
+	}
 
-.menu-logo {
-  border: 1px solid #f2f2f2;
-}
+	.menu-logo {
+		border: 1px solid #f2f2f2;
+	}
 
-.el-menu--collapse .menu-logo img {
-  display: none;
-}
+	.el-menu--collapse .menu-logo img {
+		display: none;
+	}
 
-.el-menu--collapse .el-submenu__title span {
-  display: none;
-}
+	.el-menu--collapse .el-submenu__title span {
+		display: none;
+	}
 
-.el-menu--collapse .el-submenu__title .el-submenu__icon-arrow {
-  display: none;
-}
+	.el-menu--collapse .el-submenu__title .el-submenu__icon-arrow {
+		display: none;
+	}
 
-.p-menu .el-menu-vertical-demo:not(.el-menu--collapse) {
-  width: 200px;
-  min-height: 400px;
-}
+	.p-menu .el-menu-vertical-demo:not(.el-menu--collapse) {
+		width: 200px;
+		min-height: 400px;
+	}
 </style>
 <style scoped="scoped" lang="scss">
-.p-menu {
-  height: 100%;
-  // padding-left: 50px;
-  // padding-top: 38px;
-  max-width: 200px;
-  background-color: white;
-  overflow: hidden;
+	.p-menu {
+		height: 100%;
+		// padding-left: 50px;
+		// padding-top: 38px;
+		max-width: 200px;
+		background-color: white;
+		overflow: hidden;
 
-  .card {
-    width: 100%;
-    flex-grow: 0;
-    flex-shrink: 0;
-    height: 100%;
-    max-height: 100%;
+		.card {
+			width: 100%;
+			flex-grow: 0;
+			flex-shrink: 0;
+			height: 100%;
+			max-height: 100%;
 
-    /deep/ .el-card__body {
-      padding: 0px;
-    }
-  }
-}
+			/deep/ .el-card__body {
+				padding: 0px;
+			}
+		}
+	}
 
-.menuScoll {
-  width: 100%;
-  height: 100%;
-  overflow: hidden;
+	.menuScoll {
+		width: 100%;
+		height: 100%;
+		overflow: hidden;
 
-  .menuScoll-box {
-    width: calc(100% + 20px);
-    max-height: 100vh;
-    padding-bottom: 60px;
-    overflow-y: scroll;
-  }
-}
+		.menuScoll-box {
+			width: calc(100% + 20px);
+			max-height: calc(100vh - 60px);
+			padding-bottom: 60px;
+			overflow-y: scroll;
+		}
+	}
 </style>

File diff suppressed because it is too large
+ 487 - 527
src/pages/login/login.vue


+ 1 - 1
src/pages/main/funcInit/manageLnit.vue

@@ -409,7 +409,7 @@
                     method: "post",
                     headers: {
                         "Content-Type": "application/json",
-                        "page": '{"pageNo":"' + n + '","pageSize":"10"}'
+                        "page": '{"pageNo":"' + n + '","pageSize":"50"}'
                     },
                     data: {},
                 }).then((res) => {

+ 2 - 101
src/pages/main/leader/index.vue

@@ -3,7 +3,7 @@
         <div class="container-box">
             <div class="mc-top">
                 <div class="mc-top-left">
-                    <el-row :gutter="10">
+                    <el-row >
                         <el-col :span="24">
                             <div class="car-line">
                                 <el-carousel height="40px" direction="vertical" trigger="click">
@@ -25,41 +25,6 @@
                         <ProcessingInstruction></ProcessingInstruction>
                     </el-row>
                 </div>
-                <div class="mc-top-right">
-                    <div class="inner-box" :style="myHeightauto">
-                        <div class="right-title-box" v-for="(item, index) in rightData" :key="index"
-                            @click="changeSts(item)">
-                            <span :class="`iconfont ${
-                  item.sts == '0'
-                    ? 'icon-shizhong'
-                    : item.sts == '1'
-                    ? 'icon-bofang'
-                    : item.sts == '2'
-                    ? 'icon-duihaobeifen'
-                    : item.sts == '3'
-                    ? 'icon-duihaobeifen1'
-                    : item.sts == '4'
-                    ? 'icon-guanbi'
-                    : ''
-                }`" :style="`vertical-align: middle;margin:0 5px;color:${
-                  item.sts == '0'
-                    ? 'green'
-                    : item.sts == '1'
-                    ? 'green'
-                    : item.sts == '2'
-                    ? '#026BFF'
-                    : item.sts == '3'
-                    ? '#C5DBFB'
-                    : item.sts == '4'
-                    ? 'red'
-                    : ''
-                }`"></span>
-                            <el-tooltip class="item" effect="dark" :content="item.reqTitle" placement="top-start">
-                                <span class="right-title">{{ item.reqTitle }}</span>
-                            </el-tooltip>
-                        </div>
-                    </div>
-                </div>
             </div>
         </div>
         <div class="if-box-top" v-if="ifrshow" @keyup.esc="ifrshow = false">
@@ -94,50 +59,6 @@
                 <el-button @click="dialogStatus=false">取 消</el-button>
             </div> -->
         </el-dialog>
-        <el-dialog title="修改需求" :visible.sync="indexDialogStatus" width="50%" :close-on-press-escape="false"
-            :show-close="false" :destroy-on-close="true" :modal-append-to-body="false" :close-on-click-modal="false">
-            <el-form :model="formData" ref="ruleForm" label-width="120px" class="demo-ruleForm" :rules="rules">
-                <el-form-item label="需求标题" prop="reqTitle">
-                    <el-input placeholder="请输入需求标题" v-model="formData.reqTitle"></el-input>
-                </el-form-item>
-                <el-form-item label="需求描述" prop="reqDesc">
-                    <el-input placeholder="请输入需求描述" v-model="formData.reqDesc"></el-input>
-                </el-form-item>
-                <el-form-item label="单元" prop="unitCode">
-                    <el-select @change="changetype" v-model="formData.unitCode" placeholder="单元名称" style="width: 100%">
-                        <el-option v-for="item in lineopt" :key="item.lineId" :label="item.lineName"
-                            :value="item.lineId">
-                        </el-option>
-                    </el-select>
-                </el-form-item>
-                <el-form-item label="期望上线时间" prop="requiredTime">
-                    <el-date-picker v-model="formData.requiredTime" type="datetime" placeholder="选择日期时间"
-                        value-format="yyyy-MM-dd hh:mm:ss" style="width: 100%">
-                    </el-date-picker>
-                </el-form-item>
-                <el-form-item label="计划上线时间" prop="planTime">
-                    <el-date-picker v-model="formData.planTime" type="datetime" placeholder="选择日期时间"
-                        value-format="yyyy-MM-dd hh:mm:ss" style="width: 100%">
-                    </el-date-picker>
-                </el-form-item>
-                <el-form-item label="实际上线时间" prop="finishTime">
-                    <el-date-picker v-model="formData.finishTime" type="datetime" placeholder="选择日期时间"
-                        value-format="yyyy-MM-dd hh:mm:ss" style="width: 100%">
-                    </el-date-picker>
-                </el-form-item>
-                <el-form-item label="状态" prop="sts">
-                    <el-select style="width: 100%" v-model="formData.sts" @change="formmat">
-                        <el-option v-for="items in stsOptions" :key="items.value" :label="items.label"
-                            :value="items.value">
-                        </el-option>
-                    </el-select>
-                </el-form-item>
-            </el-form>
-            <div slot="footer" class="dialog-footer">
-                <el-button @click="resetUser('ruleForm')">取 消</el-button>
-                <el-button @click="subUser('ruleForm')">确 定</el-button>
-            </div>
-        </el-dialog>
     </div>
 </template>
 <script>
@@ -276,7 +197,6 @@
                             type: "success",
                             message: "修改成功",
                         });
-                        this.getRightData();
                         this.indexDialogStatus = false;
                     }
                 }
@@ -286,24 +206,6 @@
                 this.$refs[formName].resetFields();
                 this.indexDialogStatus = false;
             },
-            // 需求详情
-            changeSts(val) {
-                this.indexDialogStatus = true;
-                this.formData = JSON.parse(JSON.stringify(val));
-            },
-            // 获取右侧需求数据
-            getRightData() {
-                this.$http({
-                    url: "/market/cReqInfo/queryList",
-                    method: "post",
-                    headers: {
-                        "Content-Type": "application/json",
-                    },
-                    data: {},
-                }).then((res) => {
-                    this.rightData = res.data;
-                });
-            },
             //统一高度
             hAuto() {
                 if (this.$refs.boxtLeft) {
@@ -398,7 +300,6 @@
         mounted() {
             this.getLineOpations();
             this.getNotice();
-            this.getRightData();
         },
         created() {
             // this.hAuto();
@@ -444,7 +345,7 @@
     }
 
     .mc-wrap .mc-top-left {
-        width: 80%;
+        width: 100%;
         margin-right: 15px;
     }
 

+ 2 - 2
vue.config.js

@@ -93,8 +93,8 @@ module.exports = {
                 // target: 'http://192.168.2.145:9600/spfm',
                 // target: 'http://192.168.2.149:9600',
                 // target: 'http://10.64.42.70:8088/',
-                // target: 'http://114.215.71.182:29600',
-                target: 'http://10.230.26.15:8000/spfm',
+                target: 'http://114.215.71.182:29600',
+                // target: 'http://10.230.26.15:8000/spfm',
                 // target: 'http://192.168.2.143:9600/',
                 // target: 'http://192.168.2.170:9600/',
                 // target: 'http://192.168.2.169:9600/',