瀏覽代碼

溧水app代码

sunyadv 5 年之前
父節點
當前提交
3bc7a15b79
共有 37 個文件被更改,包括 6336 次插入325 次删除
  1. 14 0
      lss_vue/index.html
  2. 167 0
      lss_vue/src/assets/css/custom-picker.css
  3. 二進制
      lss_vue/src/assets/image/del.png
  4. 二進制
      lss_vue/src/assets/image/delete.png
  5. 二進制
      lss_vue/src/assets/image/downLoad.png
  6. 二進制
      lss_vue/src/assets/image/down_blue.png
  7. 二進制
      lss_vue/src/assets/image/edit.png
  8. 二進制
      lss_vue/src/assets/image/noPic.png
  9. 二進制
      lss_vue/src/assets/image/on_1.png
  10. 二進制
      lss_vue/src/assets/image/on_2.png
  11. 二進制
      lss_vue/src/assets/image/pull_down_blue.png
  12. 302 0
      lss_vue/src/assets/js/custom-picker.js
  13. 16 15
      lss_vue/src/http.js
  14. 4 0
      lss_vue/src/main.js
  15. 42 111
      lss_vue/src/port.js
  16. 29 1
      lss_vue/src/routes.js
  17. 39 1
      lss_vue/src/views/Home.vue
  18. 53 42
      lss_vue/src/views/Login.vue
  19. 55 26
      lss_vue/src/views/assets/assets.vue
  20. 242 39
      lss_vue/src/views/assets/assetsDetail.vue
  21. 522 0
      lss_vue/src/views/assets/assetsEdit.vue
  22. 390 0
      lss_vue/src/views/assets/assetsHandle.vue
  23. 375 0
      lss_vue/src/views/assets/assetsMaintain.vue
  24. 272 0
      lss_vue/src/views/assets/assetsNumber.vue
  25. 371 0
      lss_vue/src/views/assets/assetsOperation.vue
  26. 180 66
      lss_vue/src/views/assets/assetsRegister.vue
  27. 220 3
      lss_vue/src/views/data/data.vue
  28. 19 21
      lss_vue/src/views/my/my.vue
  29. 246 0
      lss_vue/src/views/my/myAddress.vue
  30. 269 0
      lss_vue/src/views/my/myAssets.vue
  31. 847 0
      lss_vue/src/views/my/myGrade.vue
  32. 161 0
      lss_vue/src/views/my/myInsDetail.vue
  33. 297 0
      lss_vue/src/views/my/myInstitution.vue
  34. 229 0
      lss_vue/src/views/my/myMessage.vue
  35. 213 0
      lss_vue/src/views/my/myScore.vue
  36. 272 0
      lss_vue/src/views/my/myScoreDetail.vue
  37. 490 0
      lss_vue/src/views/my/mySuggest.vue

+ 14 - 0
lss_vue/index.html

@@ -90,6 +90,20 @@
             .activeNames .el-collapse-item__wrap {
                 border-bottom: none; 
             }
+            
+            ul, ol { 
+                list-style: none;
+                padding: 0;
+                margin: 0;
+            }
+
+            .mint-toast {
+                z-index: 99999999!important;
+            }
+
+            .mint-indicator-wrapper {
+                z-index: 9999999!important;
+            }
 
             /* 滚动条样式修改 */
             /*滚动条凹槽的颜色,还可以设置边框属性 */

+ 167 - 0
lss_vue/src/assets/css/custom-picker.css

@@ -0,0 +1,167 @@
+@keyframes slideUp {
+  0% {
+    bottom:-40%;
+  }
+  100% {
+    bottom:0;
+  }
+}
+@-moz-keyframes slideUp {
+  0% {
+    bottom:-40%;
+  }
+  100% {
+    bottom:0;
+  }
+}
+@-webkit-keyframes slideUp {
+  0% {
+    bottom:-40%;
+  }
+  100% {
+    bottom:0;
+  }
+}
+@-o-keyframes slideUp {
+  0% {
+    bottom:-40%;
+  }
+  100% {
+    bottom:0;
+  }
+}
+.pickerView-wrap * {
+    margin:0;
+    padding:0;
+    list-style: none;
+    -webkit-box-sizing: border-box;
+    -ms-box-sizing:border-box;
+    -moz-box-sizing:border-box;
+    box-sizing: border-box;
+    font-size: 0;
+}
+.pickerView-wrap {
+    position: fixed;
+    left:0;
+    top:0;
+    height:100%;
+    width:100%;
+	z-index: 666;
+}
+.pickerView-mask {
+    height:100%;
+    width:100%;
+    background:rgba(0,0,0,.5);
+}
+.pickerView-box {
+    height:40%;
+    width:100%;
+    position: absolute;
+    left:0;
+    bottom:0;
+    background: #fff;
+    padding-top:45px;
+    animation: slideUp 0.3s;
+}
+.pickerView-box-header {
+    text-align: center;
+    height:45px;
+    border-bottom:1px solid #ddd;
+    width:100%;
+    padding:0 50px;
+    position: absolute;
+    left:0;
+    top:0;
+    z-index: 10;
+    background: #fff;
+}
+.pickerView-box-header>div {
+    line-height: 44px;
+    font-size: 16px;
+}
+.pickerView-box-header-btn {
+    height:100%;
+    width:50px;
+    position: absolute;
+    top:0;
+}
+.pickerView-box-header-left {
+    left:0;
+    color:#888;
+}
+.pickerView-box-header-right {
+    right:0;
+    color:#108ee9;
+}
+.pickerView-box-header-title {
+    text-align: center;
+    height:100%;
+    width:100%;
+    overflow:hidden;
+    white-space: nowrap;
+    text-overflow: ellipsis;
+}
+.pickerView-box-content-wrap {
+    height:100%;
+    width:100%;
+    overflow: hidden;
+    position: relative;
+    display: -webkit-box;
+    display: -webkit-flex;
+    display: -ms-flexbox;
+    display: flex;
+}
+.pickerView-box-content {
+    -webkit-box-flex: 1;
+    -webkit-flex: 1;
+    -ms-flex: 1;
+    flex: 1;
+    position: relative;
+}
+.pickerView-box-content-mask {
+    position: absolute;
+    left: 0;
+    bottom:0;
+    height: 100%;
+    margin: 0 auto;
+    width: 100%;
+    z-index: 3;
+    background-image: -webkit-linear-gradient(top, rgba(255, 255, 255, 0.95), rgba(255, 255, 255, 0.6)), -webkit-linear-gradient(bottom, rgba(255, 255, 255, 0.95), rgba(255, 255, 255, 0.6));
+    background-image: -webkit-gradient(linear, left top, left bottom, from(rgba(255, 255, 255, 0.95)), to(rgba(255, 255, 255, 0.6))), -webkit-gradient(linear, left bottom, left top, from(rgba(255, 255, 255, 0.95)), to(rgba(255, 255, 255, 0.6)));
+    background-image: linear-gradient(to bottom, rgba(255, 255, 255, 0.95), rgba(255, 255, 255, 0.6)), linear-gradient(to top, rgba(255, 255, 255, 0.95), rgba(255, 255, 255, 0.6));
+    background-position: top, bottom;
+    background-size: 100% 102px;
+    background-repeat: no-repeat;
+}
+.pickerView-box-content-indicator {
+    -webkit-box-sizing: border-box;
+    box-sizing: border-box;
+    width: 100%;
+    height: 34px;
+    position: absolute;
+    left: 0;
+    top: 102px;
+    z-index: 3;
+    border-top: 1PX solid #ddd;
+    border-bottom: 1PX solid #ddd;
+}
+.pickerView-items {
+    position: absolute;
+    left: 0;
+    top: 0;
+    width: 100%;
+    z-index: 1;
+    padding: 102px 0;
+    padding: 102px 0px;
+}
+.pickerView-item {
+    touch-action: manipulation;
+    text-align: center;
+    font-size: 16px;
+    height: 34px;
+    line-height: 34px;
+    color: #000;
+    overflow:hidden;
+    white-space: nowrap;
+    text-overflow: ellipsis;
+}

二進制
lss_vue/src/assets/image/del.png


二進制
lss_vue/src/assets/image/delete.png


二進制
lss_vue/src/assets/image/downLoad.png


二進制
lss_vue/src/assets/image/down_blue.png


二進制
lss_vue/src/assets/image/edit.png


二進制
lss_vue/src/assets/image/noPic.png


二進制
lss_vue/src/assets/image/on_1.png


二進制
lss_vue/src/assets/image/on_2.png


二進制
lss_vue/src/assets/image/pull_down_blue.png


+ 302 - 0
lss_vue/src/assets/js/custom-picker.js

@@ -0,0 +1,302 @@
+/*
+参考网址:原生js实现移动端选择器插件
+https://segmentfault.com/a/1190000013366588
+*/
+// created by zhouatie
+(function () {
+	var util = {
+		extend: function (target) {
+			for (var i = 1, len = arguments.length; i < len; i++) {
+				for (var prop in arguments[i]) {
+					if (arguments[i].hasOwnProperty(prop)) {
+						target[prop] = arguments[i][prop];
+					}
+				}
+			}
+			return target;
+		},
+		indexOf: function (array, item) {
+			var result = -1;
+			for (var i = 0, len = array.length; i < len; i++) {
+				if (array[i] === item) {
+					result = i;
+					break;
+				}
+			}
+			return result;
+		},
+		css: function (elem, obj) {
+			for (var i in obj) {
+				elem.style[i] = obj[i];
+			}
+		},
+		addClass: function (element, className) {
+			var classNames = element.className.split(/\s+/);
+			if (util.indexOf(classNames, className) == -1) {
+				classNames.push(className);
+			}
+			element.className = classNames.join(' ');
+		},
+		removeClass: function (element, className) {
+			var classNames = element.className.split(/\s+/);
+			var index = util.indexOf(classNames, className);
+			if (index !== -1) {
+				classNames.splice(index, 1);
+			}
+			element.className = classNames.join(' ');
+		},
+		hasClass: function (element, className) {
+			if (!element || !element.className) return false;
+			var classNames = element.className.split(/\s+/);
+			return util.indexOf(classNames, className) != -1;
+		},
+		parents: function (elem, pClass) { // 递归函数通过父亲的classname获取元素
+			if (!elem) return null;
+			var parent = elem.parentNode;
+			if (parent === document) return null;
+			if (!this.hasClass(parent, pClass)) parent = this.parents(parent, pClass);
+			return parent;
+		},
+		isObj: function (o) {
+			return Object.prototype.toString.call(o) == "[object Object]";
+		},
+		isArray: function (o) {
+			return Object.prototype.toString.call(o) == "[object Array]";
+		}
+	};
+
+	function PickerView(opt) {
+
+		var _this = this;
+
+		this.Opt = {
+			title: '',
+			leftText: '取消',
+			rightText: '确定',
+			saveFn: function (selectArr) {
+
+			}
+		};
+
+		// 同步参数
+		for (var i in opt) {
+			if (opt[i]) this.Opt[i] = opt[i];
+		}
+
+		this._y_start = "";
+		this._y_move = "";
+		this._y_end = "";
+		this.top_start = 0; // 移动起始点
+		this.isMove = false; // 是否是移动聊天框
+
+		this.elem_wrap = null; // 最外层的容器
+		this.elem_leftBtn = null; // 左按钮元素
+		this.elem_rightBtn = null; // 右按钮元素
+		this.elem_contents = null; // items容器
+		this.elem_mask = null; // 黑色背景
+
+		var selectcache = this.Opt.bindElem.getAttribute("selectcache");
+		this.selectcache = selectcache ? selectcache.split(",") : [];
+		this.selectArr = []; // 选项对应的元素序列号 如:[0,0,0]
+
+		this.init();
+
+	}
+
+	PickerView.VERSION = '1.0.0';
+
+	PickerView.defaultOpt = {
+		headerHeight: 45, // 头部默认高度
+		itemHeight: 34, // 每个item的默认高度
+	};
+
+	PickerView.prototype = {
+		constructor: PickerView,
+		getItemTpl: function (keys) {
+			var item_html = "";
+			for (var i = 0; i < keys.length; i++) {
+                var str = JSON.stringify(keys[i]);
+				item_html += '<div class="pickerView-item" data-item=\''+ str +'\'>' + keys[i].name + '</div>';
+			};
+			return item_html;
+		},
+		getItemsTpl: function (keys) {
+			var fieldIndex = this.selectcache[this.selectArr.length] ? this.selectcache[this.selectArr.length] : 0;
+			this.selectArr.push(fieldIndex);
+			var html = "",
+				len = -fieldIndex * PickerView.defaultOpt.itemHeight,
+				item_html = this.getItemTpl(keys);
+
+			html += '<div index="' + (this.selectArr.length - 1) + '" class="pickerView-box-content">' +
+				'<div style="background-size:100% ' + this.padding + 'px;" class="pickerView-box-content-mask"></div>' +
+				'<div style="top:' + this.padding + 'px;" class="pickerView-box-content-indicator"></div>' +
+				'<div style="padding:' + this.padding + 'px 0;transform:translate3d(0,' + len + 'px,0)" fieldIndex="0" class="pickerView-items">' +
+				item_html +
+				'</div>' +
+				'</div>';
+
+			return html;
+		},
+		renderItems: function (obj) {
+			var _this = this,
+				html = "",
+				arr = obj,
+				isObj = util.isObj(obj);
+
+			if (isObj) arr = Object.keys(obj);
+			html += this.getItemsTpl(arr);
+			var fieldIndex = this.selectArr[this.selectArr.length - 1];
+			if (isObj) html += this.renderItems(obj[arr[fieldIndex]]);
+
+			return html;
+		},
+		getTpl: function () {
+			var html = '<div class="pickerView-mask"></div><div class="pickerView-box">' +
+				'<div class="pickerView-box-header">' +
+				'<div class="pickerView-box-header-left pickerView-box-header-btn">取消</div>' +
+				'<div class="pickerView-box-header-title">' + this.Opt.title + '</div>' +
+				'<div class="pickerView-box-header-right pickerView-box-header-btn">确定</div>' +
+				'</div>' +
+				'<div class="pickerView-box-content-wrap">';
+
+			html += this.renderItems(this.Opt.data);
+			html += '</div></div>';
+
+			return html;
+		},
+		init: function () {
+			var _this = this,
+				body = document.getElementsByTagName("body")[0],
+				div = document.createElement("div");
+
+			div.className = "pickerView-wrap";
+			this.elem_wrap = div;
+			this.padding = (document.documentElement.clientHeight * 0.4 - PickerView.defaultOpt.headerHeight - PickerView.defaultOpt.itemHeight) / 2;
+			div.innerHTML = this.getTpl();
+			body.appendChild(div);
+
+			this.elem_mask = this.elem_wrap.getElementsByClassName("pickerView-mask")[0];
+			this.elem_contents = this.elem_wrap.getElementsByClassName("pickerView-box-content-wrap")[0];
+			this.elem_leftBtn = this.elem_wrap.getElementsByClassName("pickerView-box-header-left")[0];
+			this.elem_rightBtn = this.elem_wrap.getElementsByClassName("pickerView-box-header-right")[0];
+
+			this.elem_contents.addEventListener("touchstart", function (e) {
+				_this.moveObj = util.parents(e.target, "pickerView-box-content").children[2];
+				_this.touchstart(e);
+				e.stopPropagation();
+			}, false);
+			this.elem_contents.addEventListener("touchmove", function (e) {
+				_this.touchmove(e);
+				e.stopPropagation();
+				e.preventDefault();
+			}, false);
+			this.elem_contents.addEventListener("touchend", function (e) {
+				_this.touchend(e);
+				e.stopPropagation();
+			}, false);
+			this.elem_mask.addEventListener("touchend", function (e) {
+				_this.closeComponent();
+				e.stopPropagation();
+				e.preventDefault()
+			}, false);
+			this.elem_leftBtn.addEventListener("touchend", function (e) {
+				_this.closeComponent();
+				e.stopPropagation();
+				e.preventDefault()
+			}, false);
+			this.elem_rightBtn.addEventListener("touchend", function (e) {
+				var selectArr = [];
+				for (var i = 0; i < _this.elem_contents.children.length; i++) {
+					var items = _this.elem_contents.children[i].children[2],
+                        // field = items.children.length > 0 ? items.children[_this.selectArr[i]].innerText : "";
+                        field = items.children.length > 0 ? items.children[_this.selectArr[i]].getAttribute("data-item") : "";
+					selectArr.push(JSON.parse(field));
+				}
+				_this.Opt.rightFn(selectArr);
+				_this.closeComponent();
+				// 绑定元素
+				_this.Opt.bindElem.setAttribute("selectcache", _this.selectArr);
+				e.stopPropagation();
+				e.preventDefault()
+			}, false);
+
+		},
+		touchstart: function (e) {
+			this._y_start = e.touches[0].pageY;
+			this.isMove = false;
+			this.top_start = parseInt(this.moveObj.style.transform.split(",")[1]);
+		},
+		touchmove: function (e) {
+			var _this = this;
+			this.isMove = true;
+			this._y_move = e.touches[0].pageY;
+			var len = parseFloat(this._y_move) - parseFloat(this._y_start) + parseFloat(this.top_start);
+			util.css(_this.moveObj, {
+				"transform": 'translate3d(0,' + len + 'px,0)'
+			})
+			this.top_end = len;
+		},
+		touchend: function (e) {
+			if (!this.isMove) return;
+			this.isMove = false;
+
+			var _this = this,
+				itemHeight = PickerView.defaultOpt.itemHeight,
+				sign = this.top_end >= 0 ? 1 : -1,
+				index = this.moveObj.parentNode.getAttribute("index"),
+				fieldIndex = Math.round(Math.abs(this.top_end) / itemHeight),
+				len = sign * (fieldIndex * itemHeight);
+
+			if (len > 0) {
+				len = 0;
+				fieldIndex = 0;
+			} else if (len < -(this.moveObj.children.length - 1) * itemHeight) {
+				len = -(this.moveObj.children.length - 1) * itemHeight;
+				fieldIndex = this.moveObj.children.length - 1;
+			};
+
+			this.selectArr[index] = fieldIndex;
+			this.moveObj.setAttribute("fieldIndex", fieldIndex);
+
+			this.moveObj.style.transition = "0.3s cubic-bezier(0,0,0.2,1.15)";
+			util.css(_this.moveObj, {
+				"transform": 'translate3d(0,' + len + 'px,0)'
+			});
+			_this.changeNext(index);
+			_this.moveObj.addEventListener("transitionend", function (event) {
+				_this.moveObj.style.transition = "";
+			}, false);
+			_this.moveObj.addEventListener("webkitTransitionEnd", function (event) {
+				_this.moveObj.style.transition = "";
+			}, false);
+
+		},
+		changeNext: function (index) {
+			var data = this.Opt.data,
+				arr = [];
+
+			for (var i = 0; i < this.selectArr.length; i++) {
+				var elem_items = this.elem_contents.children[i].children[2];
+
+				if (i > index) {
+					util.css(elem_items, {
+						"transform": 'translate3d(0,0,0)'
+					});
+					this.selectArr[i] = 0;
+					arr = util.isObj(data) ? Object.keys(data) : data;
+					elem_items.innerHTML = this.getItemTpl(arr);
+					var field = arr[0];
+					data = data[field];
+				} else {
+					var field = elem_items.children[this.selectArr[i]].innerText;
+					data = data[field];
+				}
+			}
+		},
+		closeComponent: function () {
+			var body = document.getElementsByTagName("body")[0];
+			body.removeChild(this.elem_wrap);
+		}
+	}
+	window.PickerView = PickerView;
+})();

+ 16 - 15
lss_vue/src/http.js

@@ -122,27 +122,28 @@ export default {
      * @param fileName 如果是导出 Excel 表格文件名后缀最好用.xls 而不是.xlsx,否则文件可能会因为格式错误导致无法打开
      * @param exception 异常的回调函数
      */
-    downloadFile (url, data, fileName, exception) {
+    downloadFile (url, data, response, exception) {
         axios({
             method: 'post',
             url: handleUrl(url),
-            data: handleParams(data),
+            data: handleParams(qs.stringify(data)),//handleParams(data),
             responseType: 'blob'
         }).then(
             (result) => {
-                const excelBlob = result.data
-                if ('msSaveOrOpenBlob' in navigator) {
-                    window.navigator.msSaveOrOpenBlob(excelBlob, fileName)
-                } else {
-                    const elink = document.createElement('a')
-                    elink.download = fileName
-                    elink.style.display = 'none'
-                    const blob = new Blob([excelBlob])
-                    elink.href = URL.createObjectURL(blob)
-                    document.body.appendChild(elink)
-                    elink.click()
-                    document.body.removeChild(elink)
-                }
+                // const excelBlob = result.data
+                // if ('msSaveOrOpenBlob' in navigator) {
+                //     window.navigator.msSaveOrOpenBlob(excelBlob, fileName)
+                // } else {
+                //     const elink = document.createElement('a')
+                //     elink.download = fileName
+                //     elink.style.display = 'none'
+                //     const blob = new Blob([excelBlob])
+                //     elink.href = URL.createObjectURL(blob)
+                //     document.body.appendChild(elink)
+                //     elink.click()
+                //     document.body.removeChild(elink)
+                // }
+                response(handleResults(result,data))
             }
         ).catch(
             (error) => {

+ 4 - 0
lss_vue/src/main.js

@@ -30,6 +30,10 @@ Vue.use(VueClipboard)
 import 'font-awesome/css/font-awesome.min.css'
 import './assets/iconfont/iconfont.css'
 
+import picker from "./assets/js/custom-picker.js"
+import "./assets/css/custom-picker.css"
+Vue.use(picker)
+
 // Vue.use(ElementUI)
 Vue.use(Mint);
 Vue.use(VueRouter)

+ 42 - 111
lss_vue/src/port.js

@@ -1,132 +1,63 @@
 export default {
     manage: {
-        login: '/user/login', // 登录
-        regist: '/user/regist', //注册
+        login: '/user/login',                                   // 登录
+        regist: '/user/regist',                                 //注册
     },
     pwd: {
-        resetPwd: '/system/updatePwd' // 重置密码
+        resetPwd: '/system/updatePwd'                           // 重置密码
+    },
+    user: {
+        list: '/user/list',                                     // 人员列表
     },
     label: {
-        list: '/goodstags/list',
-        add: '/goodstags/addOrUpdate',
+        list: '/goodstags/list',                                // 标签列表
+        add: '/goodstags/addOrUpdate',                          // 添加标签
+        del: '/goodstags/delTags',                              // 删除标签
     },
     assets: {
-        list: '/goods/list',
-        detail: '/goods/detail',
-        add: '/goods/add',
-        update: '/goods/update',
-    },
-    agency: {
-        list: '/institutional/list',
-        detail: '/institutional/detail',
-        add: '/institutional/add',
-        edit: '/institutional/update',
-        updatePic: '/institutional/updatePics',
-        deletePic: '/institutional/delete'
-    },
-    map: { 
-        mapList: '/company/getCoutomCompanyAndMouldsByUser', // 生产方公司和公司下所属的模具
-        newMap: '/mould/listMap' // 获取地图
-    },
-    project: {
-        addUser: '/user/add',  // 添加或修改用户
-        userList: '/user/list',  // 用户列表
-        delUser: '/user/delete',  // 删除用户
+        list: '/goods/list',                                    // 资产列表
+        detail: '/goods/detail',                                // 资产详情
+        add: '/goods/add',                                      // 添加资产
+        update: '/goods/update',                                // 更新资产
+        upload: '/goods/uploadFile',                            // 上传图片
 
-        addProject: '/project/add', // 添加或修改项目
-        projectList: '/project/list', // 项目列表
-        projectDetail: '/project/detail', // 项目详情
-        projects: '/project/projectList', // 筛选模具列表时作为筛选条件所加载的项目列表
-        projectByUser: '/project/getProjectListByUserAndCompany',// 获取创建人员分配项目时根据当前人和公司获取项目列表
+        detailNo: '/goods/goodsNoDetail',                       // 资产编号详情
+        addNo: 'goods/goodsNoAdd',                              // 资产编号添加
+        delNo: '/goods/delNo',                                  // 删除资产编号
+        distribute: '/goods/distribute',                        // 修改资产编号
 
-        uploadFile: '/projectfile/uploadFile', //项目文档的上传
-        dowloadFile: '/projectfile/dowloadFile', //项目文档的下载
-        fileList: '/projectfile/list', //项目文档列表
-        delFile: '/projectfile/delFile', //项目文档的删除
-        operList: '/projectoperationdynamics/list', //项目操作记录列表
+        handle: '/goods/handle',                                // 处置资产
 
-        getUserList: '/user/getUserList', //获取用户列表
-        getUserById: '/user/getUserListByCompanyIds', // 给项目分配参与人的时候根据公司id获取公司下的人员
+        maintainList: '/goods/isMaintainList',                  // 待维护资产列表
+        maintain: '/goods/maintain',                            // 维护资产
 
-        inviteUser: '/invitationrecord/inviteUser', //添加邀请记录并产生链接
-
-        powerList: '/power/list', // 权限列表
-        powerUpdate: '/power/update', //修改权限
+        disposalRecord: '/goods/operateList',                   // 处置记录
+        exportDis: '/goods/handelRecordExcel',                  // 导出处置记录
+        maintainRecord: '/goods/isMaintainRecord',              // 维护记录
+        exportMain: '/goods/isMaintainRecordExcel',             // 导出维护记录
     },
-    //模具
-    mold: {
-        addMold: '/mould/addOrUpdate', //添加/修改模具设备
-        molds: '/mould/list', //模具列表
-        modelList: '/mould/modelList', //给项目分配模具获取该公司下的模具列表
-        delMold: '/mould/delMould', //删除模具
-
-        moldDetail: '/mould/detail', //模具详情
-        moldFileList: '/mouldfile/list', //获取模具文档
-        moldFileListAll: '/mouldfile/allList', //获取全部模具文档
-        moldFileUpload: '/mouldfile/uploadFile', //上传模具文档
-        moldFileDowload: '/mouldfile/dowloadFile', //模具文档的下载
-        moldFileDowloadList: '/mouldfile/fileList', //获取模具文档下载列表
+    my: {
+        newList: '/newsnotice/getNewsList',                     // 我的消息
+        noReadNum: '/newsnotice/getNoReadNewsCount',            // 未读消息
 
-        moldFileDowloadFile: '/mouldfile/downloadfileList', //批量下载
-        moldFileCheck: '/mouldfile/check', //审批模具文档 
-        exportOperationExcel: '/mouldfile/downloadFileListExcel', //下载操作记录
+        list: '/goods/myList',                                  // 我的资产
 
-        chooseModelList: '/mould/chooseModelList', //编辑项目时显示的模具列表
+        scoreList: '/score/myList',                             // 我的评分
+        scoreDetail: '/score/detail',                           // 我的评分详情
 
-        moldFileDelete: '/mouldfile/delFile', //项目文档的删除
-        moldOperationList: '/mouldoperationdynamics/list', //项目操作记录列表
+        ideaList: '/idea/ideaList',                             // 我的建议
+        ideaAoU: '/idea/addOrUpdate',                           // 建议新增修改
+        draft: '/idea/getDraft',                                // 获取草稿
 
-        partList: '/part/list', //零件列表
-        addPart: '/part/addOrUpdate', //单个零件添加
-        importPart: '/part/importAppLogin',//零件的excel导入
-        partUpload: '/mouldfile/uploadPartFileList', //零件文档的批量上传
+        addressList: '/user/list',                              // 通讯录
+        scoreDetail: '/score/getDetailByTimeAndUid',            // 个人分数详情
+        ideaScore: '/idea/ideaListByTime',                      // TA的建议
+        addOrUpdate: '/score/addOrUpdate',                      // 分数新增修改
+        leaderScore: '/ideacomment/addOrUpdate',                // 添加/修改回复建议
+        delScore: '/ideacomment/del',                           // 删除回复建议
 
-        download: '/mouldfile/download',
-
-        moldMaintain: '/mouldmaintain/maintain', //维护
-        moldMaintainList: '/mouldmaintain/list', //获取列表
-        moldMaintainListGet: '/mould/maintainMouldList', //主页获取保养模具列表
-        moldDiscardListGet: '/mould/scrapMouldList', //主页获取报废模具列表
-        moldChange: '/mould/changeMouldEquipment', //处理告警
-        moldChangeRequirement: '/mouldequipment/getEquipmentListByOldMouldAndUser' //处理告警所需的设备
+        insList: '/institution/list',                           // 管理制度列表
+        insDetail: '/institution/detail',                       // 管理制度详情
     },
-    //基础管理
-    base: {
-        addCompany: '/company/add', // 添加资产方
-        companyList: '/company/list', // 资产方列表
-        delCompany: '/company/delete', // 删除资产方
-
-        getCompanyList: '/company/getCompanyList', // 管理员创建人员时显示公司
-        
-        getCompanys: '/company/getCompanys', // 云模盒所属公司
 
-        addCompanyListToProject: '/company/addCompanyListToProject', // 编辑项目时获取生产方公司
-
-        relationList: '/company/relationList', // 获取关联公司列表
-
-        //ownerComps: '/company/ownerRelateCompany', // 返回当前公司的关联公司列表
-
-        getProduceCompany: '/company/getProduceCompany', // 根据项目id获取生产方列表
-        
-        getInfo: '/company/getProduceCompanyByCurrentUser', // 根据当前人登录人所能看到的公司进行筛选
-
-        addFactory: '/factory/add',  // 添加生产方
-        factoryList: '/factory/list',   // 生产方列表
-        delFactory: '/factory/delete',  // 删除生产方
-
-        editMould: '/mouldequipment/addOrUpdate', // 添加 / 修改云模盒
-        mouldeList: '/mouldequipment/getEquipmentList', // 云模盒列表
-        enableMould: '/mouldequipment/use', // 启用云模盒
-
-        moulds: '/mouldequipment/getMouldEquipmentList', // 创建模具时获取资产方的云模盒列表
-        importMouldEquipmentExcel: '/mouldequipment/importMouldEquipmentExcel', //批量导入云模盒
-        
-        setPacket: '/mouldequipment/use',// 云平台下行配置数据包接口
-        openingAndClosingTimesChart: '/mouldhistory/openingAndClosingTimesChart', //获取云模盒的每日开合次数图表 (时间/次数)
-        openingAndClosingTimesChartCycle: '/mouldhistory/openingAndClosingTimesChartCycle', //获取云模盒的每日开合次数周期 (时间/次数)
-
-    },
-    file: {
-        view: '/pdffile/getPdfFile' // 文件预览
-    }
 }

+ 29 - 1
lss_vue/src/routes.js

@@ -6,12 +6,26 @@ import Home from './views/Home.vue'
 import assets from './views/assets/assets.vue'
 import assetsDetail from './views/assets/assetsDetail.vue'
 import assetsRegister from './views/assets/assetsRegister.vue'
+import assetsEdit from './views/assets/assetsEdit.vue'
+import assetsNumber from './views/assets/assetsNumber.vue'
+import assetsHandle from './views/assets/assetsHandle.vue'
+import assetsOperation from './views/assets/assetsOperation.vue'
+import assetsMaintain from './views/assets/assetsMaintain.vue'
 
 // 数据
 import data from './views/data/data.vue'
 
 // 我的
 import my from './views/my/my.vue'
+import myMessage from './views/my/myMessage.vue'
+import myAssets from './views/my/myAssets.vue'
+import myScore from './views/my/myScore.vue'
+import myScoreDetail from './views/my/myScoreDetail.vue'
+import myAddress from './views/my/myAddress.vue'
+import mySuggest from './views/my/mySuggest.vue'
+import myGrade from './views/my/myGrade.vue'
+import myInstitution from './views/my/myInstitution.vue'
+import myInsDetail from './views/my/myInsDetail.vue'
 
 
 let routes = [
@@ -31,6 +45,11 @@ let routes = [
             { path: '/assets', component: assets, name: '资产', meta: {keepAlive: true, parentPath:'/tab_assets'} },
             { path: '/assets/:id', component: assetsDetail, name: '资产详情', meta: {keepAlive: true, parentPath:'/tab_assets'} },
             { path: '/assetsRegister', component: assetsRegister, name: '登记资产', meta: {keepAlive: true, parentPath:'/tab_assets'} },
+            { path: '/assetsEdit/:id/', component: assetsEdit, name: '资产编辑', meta: {keepAlive: true, parentPath:'/tab_assets'} },
+            { path: '/assetsNumber/:id/:divisionCode/:suffixCode', component: assetsNumber, name: '资产编号', meta: {keepAlive: true, parentPath:'/tab_assets'} },
+            { path: '/assetsHandle/:id', component: assetsHandle, name: '处置资产', meta: {keepAlive: true, parentPath:'/tab_assets'} },
+            { path: '/assetsMaintain/:id', component: assetsMaintain, name: '维护资产', meta: {keepAlive: true, parentPath:'/tab_assets'} },
+            { path: '/assetsOperation/:id', component: assetsOperation, name: '操作记录', meta: {keepAlive: true, parentPath:'/tab_assets'} },
         ]
     },
     // 数据
@@ -50,7 +69,16 @@ let routes = [
         name: '',
         leaf: true,//只有一个节点
         children: [
-            { path: '/my', component: my, name: '我的', meta: {keepAlive: true, parentPath:'/tab_my'} }
+            { path: '/my', component: my, name: '我的', meta: {keepAlive: true, parentPath:'/tab_my'} },
+            { path: '/myMessage', component: myMessage, name: '我的消息', meta: {keepAlive: true, parentPath:'/tab_my'} },
+            { path: '/myAssets', component: myAssets, name: '我的资产', meta: {keepAlive: true, parentPath:'/tab_my'} },
+            { path: '/myScore', component: myScore, name: '我的评分', meta: {keepAlive: true, parentPath:'/tab_my'} },
+            { path: '/myScore/:id', component: myScoreDetail, name: '我的评分详情', meta: {keepAlive: true, parentPath:'/tab_my'} },
+            { path: '/mySuggest', component: mySuggest, name: '我的建议', meta: {keepAlive: true, parentPath:'/tab_my'} },
+            { path: '/myAddress', component: myAddress, name: '通讯录', meta: {keepAlive: true, parentPath:'/tab_my'} },
+            { path: '/myGrade/:id/:name', component: myGrade, name: '打分页面', meta: {keepAlive: true, parentPath:'/tab_my'} },
+            { path: '/myInstitution', component: myInstitution, name: '管理制度', meta: {keepAlive: true, parentPath:'/tab_my'} },
+            { path: '/myInstitution/:id', component: myInsDetail, name: '管理制度详情', meta: {keepAlive: true, parentPath:'/tab_my'} },
         ]
     },
     {

+ 39 - 1
lss_vue/src/views/Home.vue

@@ -15,6 +15,7 @@
             <mt-tab-item id="tab3" @click.native="changeTab(3)">
                 <img v-if="selected == 'tab3'" slot="icon" src="../assets/image/tab_my_choose.png">
                 <img v-else slot="icon" src="../assets/image/tab_my.png">
+                <mt-badge v-if="num != 0" class="myMsg" size="small" type="error">{{num}}</mt-badge>
                 我的
             </mt-tab-item>
         </mt-tabbar>
@@ -29,6 +30,7 @@
                 selected: 'tab1',
                 user: sessionStorage.getItem("user"),
                 showTab: true,
+                num: sessionStorage.noRead,
             };
         },
         methods: {
@@ -38,21 +40,46 @@
                         this.reload();
                     } else {
                         this.$router.push({ path: '/assets' });
+                        this.getNoRead();
                     }
                 } else if(type == 2) {
                     if(this.$router.history.current.fullPath == '/data') {
                         this.reload();
                     } else {
                         this.$router.push({ path: '/data' });
+                        this.getNoRead();
                     }
                 } else if(type == 3) {
                     if(this.$router.history.current.fullPath == '/my') {
                         this.reload();
                     } else {
                         this.$router.push({ path: '/my' });
+                        this.getNoRead();
                     }
                 }
             },
+
+            getNoRead() {
+                this.http.post(this.port.my.noReadNum, {
+                    'uid': this.user.id,
+                } , 
+                res => {
+                    if (res.code == "ok") {
+                        sessionStorage.setItem('noRead', res.data==null?0:res.data);
+                        this.num = sessionStorage.noRead;
+                    } else {
+                        this.$toast({
+                            message: res.msg,
+                            duration: 2000
+                        });
+                    }
+                }, error => {
+                    this.$toast({
+                        message: error,
+                        duration: 2000
+                    });
+                })
+            },
         },
         created() {
             if(this.$router.history.current.meta.parentPath == "/tab_assets") {
@@ -64,7 +91,7 @@
             }
         },
         mounted() {
-             if( this.$router.history.current.fullPath == '/assets' || 
+            if( this.$router.history.current.fullPath == '/assets' || 
                 this.$router.history.current.fullPath == '/data' || 
                 this.$router.history.current.fullPath == '/my') {
                 $(".tabber").show();
@@ -74,6 +101,7 @@
             if (this.user) {
                 var user = JSON.parse(this.user);
                 this.user = user;
+                this.getNoRead();
             } else {
                 this.$router.push("/login");
             }
@@ -90,4 +118,14 @@
     .context_router {
         height: calc(100% - 55px);
     }
+
+    #tab3 {
+        position: relative;
+    }
+
+    .myMsg {
+        position: absolute;
+        right: 0.3rem;
+        top: 0.06rem;
+    }
 </style>

+ 53 - 42
lss_vue/src/views/Login.vue

@@ -15,8 +15,8 @@
                     <!-- <mt-field placeholder="请输入手机号" :state="login.account" type="number" v-model="ruleForm.account"></mt-field>
                          <mt-field placeholder="请输入密码" :state="login.password" type="password" v-model="ruleForm.password"></mt-field> -->
                     <div class="out_input">
-                        <img class="phone" src="../assets/image/phone.png">
-                        <input class="input" placeholder="请输入手机号" v-model="ruleForm.account" />
+                        <img class="phone" src="../assets/image/user.png">
+                        <input class="input" placeholder="请输入账号" v-model="ruleForm.loginName" />
                     </div>
                     <div class="out_input">
                         <img src="../assets/image/password.png">
@@ -71,7 +71,7 @@
                 code: "获取验证码",
                 // 登录信息
                 ruleForm: {
-                    account: '',
+                    loginName: '',
                     password: '',
                     regName: '',
                     regPhone: '',
@@ -80,48 +80,59 @@
                     regPassWord1: '',
                 },
                 login: {
-                    account: "",
+                    loginName: "",
                     password: "",
-                }
+                },
+                canClick: true,
             };
         },
         methods: {
             handleLogin() {
-                if(this.ruleForm.account == "") {
-                    this.$toast({
-                        message: '请输入手机号',
-                        duration: 2000
-                    });
-                    return false;
-                } else if(this.ruleForm.password == "") {
-                    this.$toast({
-                        message: '请输入密码',
-                        duration: 2000
-                    });
-                    return false;
-                } else {
-                    this.$indicator.open();
-                    this.http.post(this.port.manage.login, {
-                        "phone": this.ruleForm.account,
-                        "password": this.ruleForm.password,
-                    } , res => {
-                        this.$indicator.close();
-                        if (res.code == "ok") {
-                            sessionStorage.setItem('user', JSON.stringify(res.data));
-                            this.$router.push({ path: '/assets' });
-                        } else {
-                            this.$toast({
-                                message: res.msg,
-                                duration: 2000
-                            });
-                        }
-                    }, error => {
-                        this.$indicator.close();
+                if(this.canClick) {
+                    this.canClick = false;
+                    if(this.ruleForm.loginName == "") {
                         this.$toast({
-                            message: error,
+                            message: '请输入账号',
                             duration: 2000
                         });
-                    })
+                        return false;
+                    } else if(this.ruleForm.password == "") {
+                        this.$toast({
+                            message: '请输入密码',
+                            duration: 2000
+                        });
+                        return false;
+                    } else {
+                        this.$indicator.open();
+                        this.http.post(this.port.manage.login, {
+                            "loginName": this.ruleForm.loginName,
+                            "password": this.ruleForm.password,
+                        } , res => {
+                            this.canClick = true;
+                            this.$indicator.close();
+                            if (res.code == "ok") {
+                                sessionStorage.setItem('user', JSON.stringify(res.data));
+                                var str = '';
+                                for(var i in res.data.functions) {
+                                    str += res.data.functions[i].code + ",";
+                                }
+                                sessionStorage.setItem('power',str)
+                                this.$router.push({ path: '/assets' });
+                            } else {
+                                this.$toast({
+                                    message: res.msg,
+                                    duration: 2000
+                                });
+                            }
+                        }, error => {
+                            this.canClick = true;
+                            this.$indicator.close();
+                            this.$toast({
+                                message: error,
+                                duration: 2000
+                            });
+                        })
+                    }
                 }
             },
             getCode() {
@@ -189,16 +200,16 @@
                     });
                     return false;
                 } else {
-                    Indicator.open();
+                    this.$indicator.open();
                     this.http.post(this.port.manage.regist, {
                         "name": this.ruleForm.regName,
                         "code": this.ruleForm.regAccount,
                         "phone": this.ruleForm.regPhone,
                         "password": this.ruleForm.regPassWord,
                     } , res => {
-                        Indicator.close();
+                        this.$indicator.close();
                         this.ruleForm = {
-                            account: '',
+                            loginName: '',
                             password: '',
                             regName: '',
                             regPhone: '',
@@ -218,9 +229,9 @@
                             });
                         }
                     }, error => {
-                        Indicator.close();
+                        this.$indicator.close();
                         this.ruleForm = {
-                            account: '',
+                            loginName: '',
                             password: '',
                             regName: '',
                             regPhone: '',

+ 55 - 26
lss_vue/src/views/assets/assets.vue

@@ -9,7 +9,7 @@
             <div class="btn_body">
                 <img v-on:click="showList()" class="btn_img" src="../../assets/image/add.png">
                 <div class="btn_list" v-show="popupVisible">
-                    <div v-on:click="register()"><img src="../../assets/image/register.png">登记资产</div>
+                    <div v-if="power.indexOf('registered_assets') > -1" v-on:click="register()"><img src="../../assets/image/register.png">登记资产</div>
                     <div v-on:click="exportExcel()"><img src="../../assets/image/export.png">导出报表</div>
                 </div>
             </div>
@@ -33,10 +33,13 @@
             </div>
             <ul v-else v-infinite-scroll="loadMore" infinite-scroll-disabled="loading" infinite-scroll-distance="10">
                 <li v-for="item in list" v-on:click="jumpTo(item.id)">
-                    <div class="item_img"><img src="../../assets/image/userHead.jpg"></div>
+                    <div class="item_img">
+                        <img v-if="item.pic != null" v-lazy="item.pic">
+                        <img v-else src="../../assets/image/noPic.png">
+                    </div>
                     <div class="text item_name">{{item.name}}</div>
                     <div class="text item_int">{{item.modelNumber}}</div>
-                    <div class="text item_num">{{item.goodsNos.length}}台</div>
+                    <div class="text item_num">{{item.goodsNos.length}}{{item.unit}}</div>
                 </li>
                 <div class="order" v-if="haveMore">
                     <span class="line"></span>
@@ -55,30 +58,31 @@
 		data() {
 			return {
                 keyWord: "",
+                power: sessionStorage.getItem("power"),
                 list: [],
                 labels: [],
                 pageNum: 1,
-                total: 1,
-                tagId: 0,
+                pages: 1,
+                tagId: -1,
                 popupVisible: false,
                 loading: false,
                 haveMore: false,
 			}
-		},
+        },
 		methods: {
             // 资产列表
             getList() {
                 this.$indicator.open();
                 this.http.post(this.port.assets.list, {
                     'keyName': this.keyWord,
-                    'tagId': this.tagId,
+                    'tagId': this.tagId==-1?"":this.tagId,
                     'pageNum': this.pageNum
                 } , 
                 res => {
                     this.$indicator.close();
                     if (res.code == "ok") {
                         this.list = res.data.list;
-                        this.total = res.data.total==0?1:res.data.total;
+                        this.pages = res.data.pages==0?1:res.data.pages;
                     } else {
                         this.$toast({
                             message: res.msg,
@@ -95,19 +99,19 @@
             },
 
             loadMore() {
-                if(this.pageNum == this.total) {
+                if(this.pageNum == this.pages) {
                     this.haveMore = true;
-                } else if(this.pageNum < this.total) {
-                    this.loading = true;
+                } else if(this.pageNum < this.pages) {
+                    this.$indicator.open();
                     this.http.post(this.port.assets.list, {
                         'keyName': this.keyWord,
-                        'tagId': this.tagId,
-                        'pageNum': this.pageNum ++
+                        'tagId': this.tagId==-1?"":this.tagId,
+                        'pageNum': ++this.pageNum 
                     } , 
                     res => {
-                        this.loading = false;
+                        this.$indicator.close();
                         if (res.code == "ok") {
-                            this.total = res.data.total==0?1:res.data.total;
+                            this.pages = res.data.pages==0?1:res.data.pages;
                             if(res.data.list.length != 0) {
                                 for(var i in res.data.list) {
                                     this.list.push(res.data.list[i]);
@@ -120,7 +124,7 @@
                             });
                         }
                     }, error => {
-                        this.loading = false;
+                        this.$indicator.close();
                         this.$toast({
                             message: error,
                             duration: 2000
@@ -134,9 +138,12 @@
                 this.http.post(this.port.label.list, {} , 
                 res => {
                     if (res.code == "ok") {
-                        this.tagId = res.data[0].id;
                         this.getList();
-                        this.labels = res.data;
+                        var array = [{"id":-1 , "name": "全部"}];
+                        for(var i in res.data) {
+                            array.push(res.data[i]);
+                        }
+                        this.labels = array;
                     } else {
                         this.$toast({
                             message: res.msg,
@@ -184,10 +191,7 @@
             chooseTag(id,type) {
                 $("#"+id).addClass("active").siblings("a").removeClass("active");
                 $("#btn"+id).addClass("active").siblings().removeClass("active");
-                if(type == 0) {
-                    var width = $("#"+id).offset().left;
-                    $(".searchkey_word").animate({scrollLeft:(width - 0.05) + "rem"}, 200);
-                }   
+                location.href = "#" + id
                 $("._sorting-medical").removeClass("fixed-top");
                 $(".searchkey_btn img").removeClass("rotate")
                 $(".searchkey_btn img").addClass("rotate1")
@@ -195,7 +199,7 @@
                 $("._sorting-address").removeClass("fixed-top");
                 $('._navbar').attr('style','position: fixed;top:0;');
                 this.pageNum = 1;
-                this.total = 1;
+                this.pages = 1;
                 this.tagId = id;
                 this.getList();
             },
@@ -209,6 +213,27 @@
             },
 
             exportExcel() {
+                this.http.post(this.port.label.list, {} , 
+                res => {
+                    if (res.code == "ok") {
+                        this.getList();
+                        var array = [{"id":-1 , "name": "全部"}];
+                        for(var i in res.data) {
+                            array.push(res.data[i]);
+                        }
+                        this.labels = array;
+                    } else {
+                        this.$toast({
+                            message: res.msg,
+                            duration: 2000
+                        });
+                    }
+                }, error => {
+                    this.$toast({
+                        message: error,
+                        duration: 2000
+                    });
+                })
                 console.log('导出')
             },
         },
@@ -316,7 +341,7 @@
 
     .btn_list > div {
         width: 0.8rem;
-        font-size: 0.15rem;
+        font-size: 0.13rem;
         padding: 0.1rem 0.15rem;
         border-bottom: 1px solid #efefef;
         text-align: center;
@@ -411,9 +436,13 @@
         font-size: 0.14rem;
         color: #ccc;
         padding: 0 0.12rem;
-        margin: 0.03rem 0.03rem;
+        margin: 0.02rem 0.03rem;
         border: 1px solid #ccc;
         border-radius: 50px;
+        width: 0.8rem;
+        text-align: center;
+        overflow: hidden;
+        text-overflow: ellipsis;
     }
     
     ._sorting-address>ul>li.active {
@@ -477,7 +506,7 @@
         width: 100%;
         padding: 0.81rem 0 0 0;
         /* height: calc(100% - 0.4rem); */
-        height: calc(100% - 0.6rem);
+        height: calc(100% - 0.8rem);
         overflow-y: auto;
         background: #EFEFEF;
     }

+ 242 - 39
lss_vue/src/views/assets/assetsDetail.vue

@@ -4,12 +4,13 @@
             <router-link to="" slot="left">
                 <mt-button icon="back" v-on:click="jumpBack()"></mt-button>
             </router-link>
-            <mt-button slot="right">操作记录</mt-button>
+            <mt-button slot="right" v-if="power.indexOf('assets_operation')>-1" v-on:click.native="jumpTo(3)">操作记录</mt-button>
         </mt-header>
         <div class="detail_body">
-            <div class="detailBox userInfo" v-on:click="jumpTo(0)">
+            <div class="detailBox userInfo" v-on:click="power.indexOf('update_assets') > -1 ?jumpTo(0):''">
                 <div class="left">
-                    <img src="../../assets/image/userHead.jpg">
+                    <img v-if="detail.pic != null" :src="detail.pic">
+                    <img v-else src="../../assets/image/noPic.png">
                 </div>
                 <div class="right">
                     <div>
@@ -19,39 +20,39 @@
                         {{detail.modelNumber}}
                     </div>
                     <div>
-                        <span class="num">{{detail.goodsNos!=null?detail.goodsNos.length:0}}{{detail.unit}}</span>
-                        <span class="arrow"><img src="../../assets/image/on_1.png"></span>
+                        <span class="num">{{detail.goodsNosVO!=null?detail.goodsNosVO.length:0}}{{detail.unit}}</span>
+                        <span v-if="power.indexOf('update_assets')>-1" class="arrow"><img src="../../assets/image/pull_down_blue.png"></span>
                     </div>
                 </div>
             </div>
             <div class="detailBox">
-                <mt-cell title="维护资产" is-link v-on:click.native="jumpTo(1)"></mt-cell>
-                <mt-cell title="资产编号" is-link v-on:click.native="jumpTo(2)"></mt-cell>
+                <mt-cell v-if="power.indexOf('maintenance_assets')>-1" title="维护资产" is-link v-on:click.native="jumpTo(1)"></mt-cell>
+                <mt-cell v-if="power.indexOf('update_assets')>-1" title="资产编号" is-link v-on:click.native="jumpTo(2)"></mt-cell>
             </div>
             <div class="detailBox">
                 <div class="assDel assDel_Head">
                     资产详情列表
+                    <img v-if="power.indexOf('update_assets')>-1" v-on:click="addNo()" src="../../assets/image/add.png">
                 </div>
                 <div class="assDel assDel_Status">
                     <span class="active" v-on:click="changeState(-1)">全部 {{delList.length}}</span>
-                    <span v-on:click="changeState(0)">在用 {{useList.length}}</span>
-                    <span v-on:click="changeState(1)">维护 {{serList.length}}</span>
-                    <span v-on:click="changeState(2)">报废 {{scrList.length}}</span>
-                    <span v-on:click="changeState(3)">未用 {{unuList.length}}</span>
+                    <span v-on:click="changeState(0)">未用 {{unuList.length}}</span>
+                    <span v-on:click="changeState(1)">在用 {{useList.length}}</span>
+                    <span v-on:click="changeState(3)">报废 {{scrList.length}}</span>
                 </div>
                 <div class="assDel assDel_List">
                     <div class="one_assDel" v-for="item in delList" v-if="state == -1 || item.state == state">
-                        <div class="one_assDel_head">
-                            <span class="canJump">{{item.modelNo}}</span>
-                            <span v-if="item.state == 0">在用</span>
-                            <span v-if="item.state == 1">维护</span>
-                            <span v-if="item.state == 2">报废</span>
-                            <span v-if="item.state == 3">未用</span>
-                        </div>
-                        <div class="one_assDel_body">
-                            <span>张旭也 18255585207</span>
-                            <img src="../../assets/image/loadMore.png">
-                        </div>
+                        <mt-cell-swipe :right="edit" :class="item.username==null?'noName':''">
+                            <div class="one_assDel_head">
+                                <span class="canJump"><span style="color:#DC143C;font-weight:600">{{item.isMaintain == 1?"[待维护] ":""}}</span>{{item.modelNo}}</span>
+                                <span v-if="item.state == 0">未用</span>
+                                <span v-if="item.state == 1">在用</span>
+                                <span v-if="item.state == 3">报废</span>
+                            </div>
+                            <div class="one_assDel_body">
+                                <span>{{item.username}} {{item.phone}}</span>
+                            </div>
+                        </mt-cell-swipe>
                     </div>
                 </div>
             </div>
@@ -60,10 +61,12 @@
 </template>
 
 <script>
+    import { MessageBox } from 'mint-ui';
 	export default {
 		data() {
 			return {
                 id: this.$route.params.id,
+                power: sessionStorage.getItem("power"),
                 detail: "",
                 delList: [],
                 useList: [],
@@ -71,6 +74,8 @@
                 scrList: [],
                 unuList: [],
                 state: -1,
+
+                edit: [],
 			}
 		},
 		methods: {
@@ -83,21 +88,20 @@
                     this.$indicator.close();
                     if (res.code == "ok") {
                         this.detail = res.data;
-                        this.delList = res.data.goodsNos;
-                        var list = res.data.goodsNos,
+                        this.delList = res.data.goodsNosVO;
+                        var list = res.data.goodsNosVO,
                             useList = [],
                             serList = [],
                             scrList = [],
                             unuList = [];
                         for(var i in list) {
                             if(list[i].state == 0) {
-                                useList.push(list[i])
+                                unuList.push(list[i])
                             } else if(list[i].state == 1) {
+                                useList.push(list[i])
                                 serList.push(list[i])
-                            } else if(list[i].state == 2) {
-                                scrList.push(list[i])
                             } else if(list[i].state == 3) {
-                                unuList.push(list[i])
+                                scrList.push(list[i])
                             }
                         }
                         this.useList = useList;
@@ -120,15 +124,168 @@
             },
 
             changeState(type) {
-                $(".assDel_Status span:eq("+ (type + 1) +")").addClass("active").siblings().removeClass("active");
+                if(type == 3) {
+                    $(".assDel_Status span:eq(3)").addClass("active").siblings().removeClass("active");
+                } else {
+                    $(".assDel_Status span:eq("+ (type + 1) +")").addClass("active").siblings().removeClass("active");    
+                }
                 this.state = type;
             },
 
+            // 添加资产编号
+            addNo() {
+                MessageBox({
+                    $type:'prompt',
+                    title:'',
+                    message:'添加资产数量',
+                    closeOnClickModal:false,
+                    showCancelButton:true,
+                    inputValidator:function(v){
+                        if (v === null) {
+                           return true;
+                        }
+                        var str = /^[0-9]*[1-9][0-9]*$/;
+                        if(str.test(v) && v != "") {
+                            return true
+                        } else {
+                            return false
+                        }
+                    },
+                    inputErrorMessage:'请输入资产编号数量',
+                    showInput:true
+                }).then(({ value, action }) => {
+                    if(value == null) {
+                        this.$toast({
+                            message: '创建失败',
+                            duration: 2000
+                        });
+                        return false;
+                    } else {
+                        this.$indicator.open();
+                        this.http.post(this.port.assets.addNo, {
+                            'goodsId': this.id,
+                            'count': value
+                        } , 
+                        res => {
+                            this.$indicator.close();
+                            if (res.code == "ok") {
+                                this.$toast({
+                                    message: '创建成功',
+                                    duration: 2000
+                                });
+                                this.getDetail();
+                            } else {
+                                this.$toast({
+                                    message: res.msg,
+                                    duration: 2000
+                                });
+                            }
+                        }, error => {
+                            this.$indicator.close();
+                            this.$toast({
+                                message: error,
+                                duration: 2000
+                            });
+                        })
+                    }
+                }).catch(() => {
+                });
+            },            
+
+            // 删除资产编号
+            deleteNos(id) {
+                MessageBox.confirm('', { 
+                    message: '是否删除该资产?', 
+                        title: '', 
+                        confirmButtonText: '确定', 
+                        cancelButtonText: '取消' 
+                 }).then(action => { 
+                    if (action == 'confirm') {     //确认的回调
+                        this.http.post(this.port.assets.delNo, {
+                            'id': id
+                        } , 
+                        res => {
+                            if (res.code == "ok") {
+                                this.$toast({
+                                    message: "删除成功",
+                                    duration: 2000
+                                });
+                                for(var i in this.delList) {
+                                    if(this.delList[i].id == id) {
+                                        this.delList.splice(i, 1);
+                                    }
+                                }
+                                var list = this.delList,
+                                    useList = [],
+                                    serList = [],
+                                    scrList = [],
+                                    unuList = [];
+                                for(var i in list) {
+                                    if(list[i].state == 0) {
+                                        unuList.push(list[i])
+                                    } else if(list[i].state == 1) {
+                                        useList.push(list[i])
+                                        serList.push(list[i])
+                                    } else if(list[i].state == 3) {
+                                        scrList.push(list[i])
+                                    }
+                                }
+                                this.useList = useList;
+                                this.serList = serList;
+                                this.scrList = scrList;
+                                this.unuList = unuList;
+                            } else {
+                                this.$toast({
+                                    message: res.msg,
+                                    duration: 2000
+                                });
+                            }
+                        }, error => {
+                            this.$toast({
+                                message: error,
+                                duration: 2000
+                            });
+                        })
+                    }
+                 }).catch(err => { 
+                 });
+            },
+
+            // 跳转
             jumpBack() {
                 this.$router.go(-1);
+            },
+
+            jumpTo(type) {
+                if(type == 0) {
+                    this.$router.push("/assetsEdit/" + this.id );
+                } else if(type == 1) {
+                    this.$router.push("/assetsMaintain/" + this.id );
+                } else if(type == 2) {
+                    this.$router.push("/assetsNumber/" + this.id + "/" + this.detail.divisionCode + "/" + this.detail.suffixCode );
+                } else if(type == 3) {
+                    this.$router.push("/assetsOperation/" + this.id );
+                }
+            },
+
+            handle(id) {
+                this.$router.push("/assetsHandle/" + id );
             }
         },
         created() {
+            if(this.power.indexOf('handle_assets') > -1) {
+                this.edit.push({
+                    content: '处置',
+                    style: { background: 'rgba(38,162,255,0.9)', color: '#fff' },
+                    handler: () => handle(item.id)
+                })
+            }
+            if(this.power.indexOf('update_assets') > -1) {
+                this.edit.push({ content: '删除',
+                    style: { background: 'rgba(220,0,0,0.7)', color: '#fff', },
+                    handler: () => deleteNos(item.id)
+                })
+            }
             this.getDetail();
         },
 		mounted() {
@@ -155,7 +312,7 @@
 
     .detailBox {
         background: #fff;
-        margin-bottom: 0.15rem;
+        margin-bottom: 0.11rem;
     }
 
     .userInfo {
@@ -203,6 +360,8 @@
     }
 
     span.arrow img {
+        width: 0.12rem;
+        margin-right: 0.05rem;
         transform: rotate(-90deg);
         -ms-transform: rotate(-90deg); /* IE 9 */
         -moz-transform: rotate(-90deg); /* Firefox */
@@ -214,30 +373,53 @@
         padding: 0.12rem 0.1rem;
     }
 
+    .assDel_List {
+        padding-top: 0; 
+    }
+
     .assDel_Status span {
         display: inline-block;
         text-align: center;
-        width: 18%;
+        width: 24%;
         color: #aaa;
         font-size: 0.15rem;
     }
 
     .assDel_Status span.active {
         color: #26a2ff;
-    }   
+    }
+
+    .assDel_Head img {
+        float: right;
+        width: 0.2rem;
+        height: 0.2rem;
+    }
 
     .one_assDel {
-        padding: 0 0.1rem;
+        /* padding: 0 0.1rem; */
+        margin: 0 0 0.15rem 0;
+    }
+
+    .mint-cell-wrapper {
+        padding: 0;
+    }
+
+    .one_assDel_head {
+        width: 100%;
+    }
+
+    .one_assDel_body {
+        width: 100%;
     }
 
-    .one_assDel_head span {
+    .one_assDel_head > span {
         display:inline-block;
         vertical-align: middle;
         color: #666;
         line-height: 0.4rem;
     }
 
-    .one_assDel_head span:nth-child(1){
+    .one_assDel_head > span:nth-child(1){
         width: 85%;
         font-size: 0.15rem;
         overflow: hidden;
@@ -245,16 +427,16 @@
         text-overflow: ellipsis;
     }
 
-    .one_assDel_head span:nth-child(1).canJump {
-        color: #26a2ff;
+    .one_assDel_head > span:nth-child(1).canJump {
+        /* color: #26a2ff; */
     }
 
-    .one_assDel_head span:nth-child(2){
+    .one_assDel_head > span:nth-child(2){
         float: right;
     }
 
     .one_assDel_body span {
-        display:inline-block;
+        /* display:inline-block; */
         color: #aaa;
         vertical-align: middle;
     }
@@ -279,4 +461,25 @@
     .detailBox .mint-cell {
         padding: 0 0 0 0.02rem;
     }
+
+    .one_assDel .mint-cell-value {
+        display: block;
+        width: 100%;
+    }
+
+    .one_assDel .mint-cell:last-child {
+        background-image: none;
+    }
+
+    .one_assDel .mint-cell-wrapper {
+        background-image: none;
+    }
+
+    .one_assDel .mint-cell-swipe-button {
+        line-height: 0.55rem;
+    }
+
+    .one_assDel .noName .mint-cell-swipe-button {
+        line-height: 48px;
+    }
 </style>

+ 522 - 0
lss_vue/src/views/assets/assetsEdit.vue

@@ -0,0 +1,522 @@
+<template>
+	<div class="detail">
+        <mt-header class="detail_head" fixed title="编辑资产">
+            <router-link to="" slot="left">
+                <mt-button icon="back" v-on:click="jumpBack()"></mt-button>
+            </router-link>
+        </mt-header>
+        <div class="detail_body">
+            <div class="detailBox">
+                <mt-field label="物品名称" placeholder="请输入物品名称" v-model="assetsForm.name"></mt-field>
+                <mt-field label="型号" placeholder="请输入物品型号" v-model="assetsForm.modelNumber"></mt-field>
+                <mt-field label="数量" placeholder="请输入数量" type="number" v-model="assetsForm.number"></mt-field>
+                <mt-field label="单位" placeholder="请输入单位" v-model="assetsForm.unit"></mt-field>
+                <div class="upload">
+                    <div class="left">物品图片</div>
+                    <div class="right upload_add" v-on:click="choosePic()">
+                        <div v-if="assetsForm.pic == null || assetsForm.pic == ''" class="upload_add_image" align="center">
+                            <img src="../../assets/image/camera.png" class="camera">
+                            <p class="font13">添加图片</p>
+                        </div>
+                        <div v-else class="right">
+                            <img class="pic" :src="assetsForm.pic">
+                        </div>
+                    </div>
+                    <input @change="fileChange($event)" type="file" accept="image/*" id="upload_file" style="display: none"/>
+                </div>
+                <mt-field label="地址" placeholder="请输入地址" v-model="assetsForm.address"></mt-field>
+            </div>
+            <div class="detailBox">
+                <mt-field label="生产厂家" placeholder="请输入生产厂家" v-model="assetsForm.factory"></mt-field>
+                <mt-field label="服务期限" placeholder="请输入服务期限" v-model="assetsForm.serviceLife"></mt-field>
+                <mt-field label="下次维护日期" placeholder="请选择下次维护日期" type="date" v-model="assetsForm.nextIndate"></mt-field>
+            </div>
+            <div class="detailBox">
+                <div class="left">所属分类</div>
+                <div class="right">
+                    <ul class="address_first">
+                        <li v-for="(item,index) in labels" :id="'btn'+item.id" v-bind:class="{'active':item.id==tagId}" v-on:click="chooseTag(item.id)">
+                            {{item.name}}
+                            <img v-if="index > 7" v-on:click="delTag(item.id)" src="../../assets/image/del.png">
+                        </li>
+                        <li v-on:click="addNewTag()" class="add">+</li>
+                    </ul>
+                </div>
+            </div>
+            <div class="btn">
+                <mt-button class="allBtn" size="large" type="primary" v-on:click.native="submit()">确定</mt-button>
+                <mt-button class="allBtn" size="large" v-on:click.native="jumpBack()">取消</mt-button>
+            </div>
+        </div>
+    </div>
+</template>
+
+<script>
+    import { MessageBox } from 'mint-ui';
+	export default {
+		data() {
+			return {
+                id: this.$route.params.id,
+                user: JSON.parse(sessionStorage.getItem("user")),
+                assetsForm: {
+                    id: '',
+                    name: '',
+                    modelNumber: '',
+                    number: '',
+                    unit: '',
+                    address: '',
+                    factory: '',
+                    serviceLife: '',
+                    nextIndate: '',
+                    pic: '',
+                    tagId: 0,
+                },
+                labels: [],
+                tagId: 0,
+                limit: 1,
+                canClick: true,
+			}
+		},
+		methods: {
+            // 详情
+            getDetail() {
+                this.$indicator.open();
+                this.http.post(this.port.assets.detail, {
+                    'id': this.id
+                } , 
+                res => {
+                    this.$indicator.close();
+                    if (res.code == "ok") {
+                        this.assetsForm = {
+                            id: this.id,
+                            name: res.data.name,
+                            modelNumber: res.data.modelNumber,
+                            number: res.data.goodsNosVO==null?0:res.data.goodsNosVO.length,
+                            unit: res.data.unit,
+                            address: res.data.address,
+                            factory: res.data.factory,
+                            serviceLife: res.data.serviceLife,
+                            nextIndate: res.data.nextIndate,
+                            pic: res.data.pic,
+                            tagId: res.data.tagId,
+                        }
+                        this.tagId = res.data.tagId
+                        this.getLabels();
+                    } else {
+                        this.$toast({
+                            message: res.msg,
+                            duration: 2000
+                        });
+                    }
+                }, error => {
+                    this.$indicator.close();
+                    this.$toast({
+                        message: error,
+                        duration: 2000
+                    });
+                })
+            },
+
+            // 标签列表
+			getLabels() {
+                this.http.post(this.port.label.list, {} , 
+                res => {
+                    if (res.code == "ok") {
+                        this.labels = res.data;
+                    } else {
+                        this.$toast({
+                            message: res.msg,
+                            duration: 2000
+                        });
+                    }
+                }, error => {
+                    this.$toast({
+                        message: error,
+                        duration: 2000
+                    });
+                })
+            },
+
+            addNewTag() {
+                MessageBox({
+                    $type:'prompt',
+                    title:'',
+                    message:'请输入资产类型名称',
+                    closeOnClickModal:false,
+                    showCancelButton:true,
+                    inputValidator:function(v){
+                        if (v === null) {
+                           return true;
+                        }
+                        if (v != ""){
+                            return true
+                        } else {
+                            return false
+                        }
+                    },
+                    inputErrorMessage:'请输入资产类型名称',
+                    showInput:true
+                }).then(({ value, action }) => {
+                    if(value == null) {
+                        this.$toast({
+                            message: '创建失败',
+                            duration: 2000
+                        });
+                        return false;
+                    } else {
+                        this.$indicator.open();
+                        this.http.post(this.port.label.add, {
+                            'name': value,
+                        } , 
+                        res => {
+                            this.$indicator.close();
+                            if (res.code == "ok") {
+                                this.$toast({
+                                    message: '创建成功',
+                                    duration: 2000
+                                });
+                                this.getLabels();
+                            } else {
+                                this.$toast({
+                                    message: res.msg,
+                                    duration: 2000
+                                });
+                            }
+                        }, error => {
+                            this.$indicator.close();
+                            this.$toast({
+                                message: error,
+                                duration: 2000
+                            });
+                        })
+                    }
+                }).catch(() => {
+                });
+            },
+
+            chooseTag(id) {
+                $("#btn"+id).addClass("active").siblings().removeClass("active");
+                this.assetsForm.tagId = id;
+            },
+
+            delTag(id) {
+                MessageBox.confirm('', { 
+                    message: '是否删除该分类?', 
+                        title: '', 
+                        confirmButtonText: '确定', 
+                        cancelButtonText: '取消' 
+                 }).then(action => { 
+                    if (action == 'confirm') {     //确认的回调
+                        this.http.post(this.port.label.del, {
+                            'id': id
+                        } , 
+                        res => {
+                            if (res.code == "ok") {
+                                this.$toast({
+                                    message: "删除成功",
+                                    duration: 2000
+                                });
+                                this.getLabels();
+                            } else {
+                                this.$toast({
+                                    message: res.msg,
+                                    duration: 2000
+                                });
+                            }
+                        }, error => {
+                            this.$toast({
+                                message: error,
+                                duration: 2000
+                            });
+                        })
+                    }
+                 }).catch(err => { 
+                 });
+            },
+
+            // 图片上传
+            choosePic() {
+                document.getElementById('upload_file').click();
+            },
+
+            fileChange(el) {
+                if (!el.target.files[0].size) return;
+                this.fileAdd(el.target.files[0]);
+                el.target.value = ''
+            },
+
+            fileAdd(file) {
+                //判断是否为图片文件
+                if (file.type.indexOf('image') == -1) {
+                    this.$toast({
+                        message: '请选择图片文件',
+                        duration: 2000
+                    });
+                } else {
+                    var form = new FormData();
+                    form.append("file", file);
+                    this.$indicator.open();
+                    this.http.uploadFile( this.port.assets.upload, form,
+                    res => {
+                        this.$indicator.close();
+                        if (res.code == "ok") {
+                            this.$toast({
+                                message: '上传成功',
+                                duration: 2000
+                            });
+                            this.assetsForm.pic = res.data;
+                            document.getElementById('upload_file').value = "";
+                        } else {
+                            this.$toast({
+                                message: res.msg,
+                                duration: 2000
+                            });
+                        }
+                    },
+                    error => {
+                        this.$indicator.close();
+                        this.$toast({
+                            message: error,
+                            duration: 2000
+                        });
+                    });
+                }
+            },
+
+            // 创建
+            submit() {
+                if(this.canClick) {
+                    this.canClick = false;
+                    if(this.assetsForm.name == null || this.assetsForm.name == "") {
+                        this.$toast({
+                            message: '请输入物品名称',
+                            duration: 2000
+                        });
+                        this.canClick = true;
+                        return false;
+                    } else if(this.assetsForm.number == null || this.assetsForm.number == "") {
+                        this.$toast({
+                            message: '请输入物品数量',
+                            duration: 2000
+                        });
+                        this.canClick = true;
+                        return false;
+                    } else if(this.assetsForm.unit == null || this.assetsForm.unit == "") {
+                        this.$toast({
+                            message: '请输入物品单位',
+                            duration: 2000
+                        });
+                        this.canClick = true;
+                        return false;
+                    } else {
+                        this.$indicator.open();
+                        var _this = this;
+                        this.http.post( this.port.assets.update, this.assetsForm,
+                        res => {
+                            this.$indicator.close();
+                            if (res.code == "ok") {
+                                this.$toast({
+                                    message: '更新成功',
+                                    duration: 2000
+                                });
+                                setTimeout(function(){
+                                    _this.$router.go(-1);
+                                }, 1000);
+                            } else {
+                                this.canClick = true;
+                                this.$toast({
+                                    message: res.msg,
+                                    duration: 2000
+                                });
+                            }
+                        },
+                        error => {
+                            this.canClick = true;
+                            this.$indicator.close();
+                            this.$toast({
+                                message: error,
+                                duration: 2000
+                            });
+                        });
+                    }
+                } else {
+                    this.$toast({
+                        message: '请勿重复提交',
+                        duration: 2000
+                    });
+                }
+            },
+
+            jumpBack() {
+                this.$router.go(-1);
+            }
+        },
+        created() {
+            this.getDetail();
+        },
+		mounted() {
+            
+		}
+	}
+
+</script>
+
+<style scoped>
+    .detail_head {
+        background: #fff;
+        color: #333;
+        height: 0.4rem;
+    }
+
+    .detail_body {
+        margin-top: 0.4rem;
+        padding-bottom: 0.15rem;
+    }
+
+    .detail {
+        background: #EFEFEF;
+    }
+
+    .detailBox {
+        background: #fff;
+        margin-bottom: 0.11rem;
+    }
+
+    .left{
+        float:left;
+        margin: 0.15rem;
+    }
+
+    .upload .left {
+        margin: 0.1rem 0.11rem;
+    }
+
+    .right div{
+        line-height: 0.21rem;
+        white-space: nowrap;
+        overflow: hidden;
+        text-overflow: ellipsis;
+    }
+
+    .btn {
+        width: 80%;
+        margin: 0.2rem auto 80px;
+    }
+
+    .allocation {
+        width: 100%;
+        height: 100%;
+    }
+
+    .address_first .current{
+        background:#eee;
+        color: #6f83ff;
+        border-left: 2px solid #6f83ff;
+    }
+
+    .right > ul {
+        margin: 0;
+        padding: 0;
+        overflow: auto;
+        -webkit-transition-duration: 0.4s;
+        box-sizing:border-box;
+        padding: 0.08rem 0.1rem;
+    }
+
+    .right > ul > li {
+        display: inline-block;
+        height: 0.2rem;
+        line-height: 0.2rem;
+        font-size: 0.14rem;
+        color: #ccc;
+        padding: 0 0.12rem;
+        margin: 0.06rem 0.03rem;
+        border: 1px solid #ccc;
+        border-radius: 50px;
+        min-width: 0.3rem;
+        text-align: center;
+    }
+
+    .right > ul > li.add {
+        border: 1px solid #777;
+        color: #777;
+    }
+    
+    .right > ul > li.active {
+        border: 1px solid #2680EB;
+        color: #2680EB;
+    }
+
+    .upload_add {
+        display: inline-block;
+        margin-bottom: 0.2rem;
+    }
+
+    .upload_add_image {
+        padding-top: 0.08rem;
+        margin: 0.15rem 0 0 0.3rem ;
+        width: 1rem;
+        height: 0.9rem;
+        border: 1px dashed rgba(0, 0, 0, .2);
+    }
+
+    .upload_add-image .camera {
+        font-size: 24px;
+    }
+
+    .upload_add_image p {
+        padding: 0;
+        margin: 0;
+        color: #8e8e8e;
+    }
+
+    .right div img.pic {
+        width: 0.8rem;
+        height: 0.8rem;
+        margin: 0.15rem 0 0 0.3rem ;
+    }
+
+    .textColor {
+        margin-top: 0.4rem;
+        color: #8e8e8e;
+        padding: 0.12rem;
+        font-size: 0.12rem;
+    }
+
+    .example {
+        color: #8e8e8e;
+        padding: 0.02rem 0.12rem;
+        font-size: 0.12rem;
+    }
+
+    .allBtn {
+        width: 80%;
+        margin: 0.18rem auto;
+    }
+</style>
+<style>
+    .detail_head .mint-header-title {
+        font-weight: 600;
+        font-size: 0.15rem;
+    }
+
+    .detail_head .mint-button-text {
+        color: #26a2ff;
+    }
+
+    .detailBox .mint-cell {
+        padding: 0 0 0 0.02rem;
+    }
+    
+    .mint-popup.allocation  {
+        background: #efefef;
+    }
+
+    .mint-msgbox {
+        width: 70%;
+    }
+
+    .mint-cell-wrapper {
+        background-image: none;
+    }
+</style>

+ 390 - 0
lss_vue/src/views/assets/assetsHandle.vue

@@ -0,0 +1,390 @@
+<template>
+	<div class="detail">
+        <mt-header class="detail_head" fixed title="处置资产">
+            <router-link to="" slot="left">
+                <mt-button icon="back" v-on:click="jumpBack()"></mt-button>
+            </router-link>
+        </mt-header>
+        <div class="detail_body">
+            <div class="detailBox">
+                <mt-field label="资产编号" placeholder="请输入物品名称" v-model="detail.modelNo" disabled></mt-field>
+                <mt-field id="state" label="资产状态" placeholder="请选择资产状态" disableClear disabled v-on:click.native="chooseType()" v-model="state"></mt-field>
+                <mt-field v-if="assetsForm.state == 1" id="userId" label="对应人员" placeholder="请选择对应人员" disableClear disabled v-on:click.native="choosePeo()" v-model="userName"></mt-field>
+            </div>
+            <div class="btn">
+                <mt-button class="allBtn" size="large" type="primary" v-on:click.native="submit()">确定</mt-button>
+                <mt-button class="allBtn" size="large" v-on:click.native="jumpBack()">取消</mt-button>
+            </div>
+        </div>
+    </div>
+</template>
+
+<script>
+	export default {
+		data() {
+			return {
+                id: this.$route.params.id,
+                detail: "",
+                users: [],
+                assetsForm: {
+                    id: '',
+                    state: 0,
+                    userId: 0,
+                    currentUserId: JSON.parse(sessionStorage.getItem("user")).id,
+                },
+                state: "",
+                userName: "",
+                popupVisible: false,
+                canClick: true,
+			}
+		},
+		methods: {
+            // 详情
+            getDetail() {
+                this.$indicator.open();
+                this.http.post(this.port.assets.detailNo, {
+                    'id': this.id
+                } , 
+                res => {
+                    this.$indicator.close();
+                    if (res.code == "ok") {
+                        this.detail = res.data;
+                        this.assetsForm = {
+                            id: res.data.id,
+                            state: res.data.state,
+                            userId: res.data.userId == null?0:res.data.userId,
+                            currentUserId: JSON.parse(sessionStorage.getItem("user")).id,
+                        }
+                        if(res.data.state == 0) {
+                            this.state = "未用"
+                        } else if(res.data.state == 1) {
+                            this.state = "在用"
+                        } else if(res.data.state == 3) {
+                            this.state = "报废"
+                        }
+                        this.userName = res.data.username==null?'':res.data.username;
+                    } else {
+                        this.$toast({
+                            message: res.msg,
+                            duration: 2000
+                        });
+                    }
+                }, error => {
+                    this.$indicator.close();
+                    this.$toast({
+                        message: error,
+                        duration: 2000
+                    });
+                })
+            },
+
+            getUserList() {
+                this.http.post(this.port.user.list, {} , 
+                res => {
+                    if (res.code == "ok") {
+                        this.users = res.data;
+                    } else {
+                        this.$toast({
+                            message: res.msg,
+                            duration: 2000
+                        });
+                    }
+                }, error => {
+                    this.$toast({
+                        message: error,
+                        duration: 2000
+                    });
+                })
+            },
+
+            chooseType() {
+                var _this = this;
+                var dataShippingSpace = [
+                    {name: "未用"},
+                    {name: "在用"},
+                    {name: "报废"},
+                ];
+                var pickerDiv = document.getElementById("state");
+                var vCardType = this.detail.state;
+                var pickerView = new PickerView({
+                    bindElem: pickerDiv, 
+                    data: dataShippingSpace, 
+                    title: "资产状态", 
+                    leftText: "取消", 
+                    rightText: "确定", 
+                    rightFn: function(selectArr) {
+                        if (selectArr[0].name == "未用") {
+                            vCardType = "0";
+                            _this.assetsForm.state = 0;
+                            _this.assetsForm.userId = 0;
+                            _this.state = "未用";
+                        } else if (selectArr[0].name == "在用") {
+                            vCardType = "1";
+                            _this.assetsForm.state = 1;
+                            _this.state = "在用";
+                        } else if (selectArr[0].name == "报废") {
+                            vCardType = "3";
+                            _this.assetsForm.state = 3;
+                            _this.assetsForm.userId = 0;
+                            _this.state = "报废";
+                        }
+                    }
+                });
+            },
+
+            choosePeo() {
+                if(this.detail.state != 1) {
+                    var _this = this;
+                    var dataShippingSpace = this.users;
+                    var pickerDiv = document.getElementById("userId");
+                    var vCardType = this.detail.userId;
+                    var pickerView = new PickerView({
+                        bindElem: pickerDiv, 
+                        data: dataShippingSpace, 
+                        title: "对应人员", 
+                        leftText: "取消", 
+                        rightText: "确定", 
+                        rightFn: function(selectArr) {
+                            _this.assetsForm.userId = selectArr[0].id;
+                            _this.userName = selectArr[0].name;
+                        }
+                    });
+                }
+            },
+
+            // 创建
+            submit() {
+                if(this.canClick) {
+                    this.canClick = false;
+                    if(this.assetsForm.state == 1 && this.assetsForm.userId == 0) {
+                        this.$toast({
+                            message: '请选择对应人员',
+                            duration: 2000
+                        });
+                        this.canClick = true;
+                        return false;
+                    } else if(this.detail.state == this.assetsForm.state) {
+                        this.$toast({
+                            message: '请更改状态后提交',
+                            duration: 2000
+                        });
+                        this.canClick = true;
+                        return false;
+                    } else {
+                        this.$indicator.open();
+                        var _this = this;
+                        this.http.post( this.port.assets.handle, this.assetsForm,
+                        res => {
+                            this.$indicator.close();
+                            if (res.code == "ok") {
+                                this.$toast({
+                                    message: '处置成功',
+                                    duration: 2000
+                                });
+                                setTimeout(function(){
+                                    _this.$router.go(-1);
+                                }, 1000);
+                            } else {
+                                this.canClick = true;
+                                this.$toast({
+                                    message: res.msg,
+                                    duration: 2000
+                                });
+                            }
+                        },
+                        error => {
+                            this.canClick = true;
+                            this.$indicator.close();
+                            this.$toast({
+                                message: error,
+                                duration: 2000
+                            });
+                        });
+                    }
+                } else {
+                    this.$toast({
+                        message: '请勿重复提交',
+                        duration: 2000
+                    });
+                }
+            },
+
+            jumpBack() {
+                this.$router.go(-1);
+            }
+        },
+        created() {
+            this.getDetail();
+            this.getUserList();
+        },
+		mounted() {
+            
+		}
+	}
+
+</script>
+
+<style scoped>
+    .detail_head {
+        background: #fff;
+        color: #333;
+        height: 0.4rem;
+    }
+
+    .detail_body {
+        margin-top: 0.4rem;
+        padding-bottom: 0.15rem;
+    }
+
+    .detail {
+        background: #EFEFEF;
+        overflow: hidden;
+    }
+
+    .detailBox {
+        background: #fff;
+        margin-bottom: 0.11rem;
+    }
+
+    .left{
+        float:left;
+        margin: 0.15rem;
+    }
+
+    .upload .left {
+        margin: 0.1rem 0.11rem;
+    }
+
+    .right div{
+        line-height: 0.21rem;
+        white-space: nowrap;
+        overflow: hidden;
+        text-overflow: ellipsis;
+    }
+
+    .btn {
+        width: 80%;
+        margin: 0.2rem auto 80px;
+    }
+
+    .allocation {
+        width: 100%;
+        height: 100%;
+    }
+
+    .address_first .current{
+        background:#eee;
+        color: #6f83ff;
+        border-left: 2px solid #6f83ff;
+    }
+
+    .right > ul {
+        margin: 0;
+        padding: 0;
+        overflow: auto;
+        -webkit-transition-duration: 0.4s;
+        box-sizing:border-box;
+        padding: 0.08rem 0.1rem;
+    }
+
+    .right > ul > li {
+        display: inline-block;
+        height: 0.2rem;
+        line-height: 0.2rem;
+        font-size: 0.14rem;
+        color: #ccc;
+        padding: 0 0.12rem;
+        margin: 0.06rem 0.03rem;
+        border: 1px solid #ccc;
+        border-radius: 50px;
+        min-width: 0.3rem;
+        text-align: center;
+    }
+
+    .right > ul > li.add {
+        border: 1px solid #777;
+        color: #777;
+    }
+    
+    .right > ul > li.active {
+        border: 1px solid #2680EB;
+        color: #2680EB;
+    }
+
+    .upload_add {
+        display: inline-block;
+        margin-bottom: 0.2rem;
+    }
+
+    .upload_add_image {
+        padding-top: 0.08rem;
+        margin: 0.15rem 0 0 0.3rem ;
+        width: 1rem;
+        height: 0.9rem;
+        border: 1px dashed rgba(0, 0, 0, .2);
+    }
+
+    .upload_add-image .camera {
+        font-size: 24px;
+    }
+
+    .upload_add_image p {
+        padding: 0;
+        margin: 0;
+        color: #8e8e8e;
+    }
+
+    .right div img.pic {
+        width: 0.8rem;
+        height: 0.8rem;
+        margin: 0.15rem 0 0 0.3rem ;
+    }
+
+    .textColor {
+        margin-top: 0.4rem;
+        color: #8e8e8e;
+        padding: 0.12rem;
+        font-size: 0.12rem;
+    }
+
+    .example {
+        color: #8e8e8e;
+        padding: 0.02rem 0.12rem;
+        font-size: 0.12rem;
+    }
+
+    .allBtn {
+        width: 80%;
+        margin: 0.18rem auto;
+    }
+</style>
+<style>
+    .detail_head .mint-header-title {
+        font-weight: 600;
+        font-size: 0.15rem;
+    }
+
+    .detail_head .mint-button-text {
+        color: #26a2ff;
+    }
+
+    .detailBox .mint-cell {
+        padding: 0 0 0 0.02rem;
+    }
+    
+    .mint-popup.allocation  {
+        background: #efefef;
+    }
+
+    .mint-msgbox {
+        width: 70%;
+    }
+
+    .mint-cell-wrapper {
+        background-image: none;
+    }
+
+    input:disabled {
+        background: #fff;
+    }
+</style>

+ 375 - 0
lss_vue/src/views/assets/assetsMaintain.vue

@@ -0,0 +1,375 @@
+<template>
+	<div class="detail">
+        <mt-header class="detail_head" fixed title="维护资产">
+            <router-link to="" slot="left">
+                <mt-button icon="back" v-on:click="jumpBack()"></mt-button>
+            </router-link>
+        </mt-header>
+        <div class="detail_body">
+            <div class="detailBox">
+                <div style="padding:0.12rem;">资产编号</div>
+                <mt-field id="userId" placeholder="请选择资产编号" disableClear disabled v-on:click.native="choosePeo()" type="textarea" v-model="idStr"></mt-field>
+            </div>
+            <div class="detailBox">
+                <mt-field label="维护人" placeholder="请输入维护人" v-model="assetsForm.operator"></mt-field>
+                <mt-field label="联系方式" placeholder="请输入维护人联系方式" v-model="assetsForm.operatorPhone"></mt-field>
+            </div>
+            <div class="detailBox">
+                <mt-field label="维护厂家" placeholder="请输入维护厂家" v-model="assetsForm.company"></mt-field>
+                <mt-field label="联系方式" placeholder="请输入维护厂家联系方式" v-model="assetsForm.companyPhone"></mt-field>
+            </div>
+            <div class="btn">
+                <mt-button class="allBtn" size="large" type="primary" v-on:click.native="submit()">确定</mt-button>
+                <mt-button class="allBtn" size="large" v-on:click.native="jumpBack()">取消</mt-button>
+            </div>
+        </div>
+
+        <mt-popup v-model="popupVisible" position="right" class="allocation">
+            <mt-header class="detail_head" fixed title="待维修资产">
+                <router-link to="" slot="left">
+                    <mt-button icon="back" v-on:click="toPrev()"></mt-button>
+                </router-link>
+            </mt-header>
+            <div class="detailBox">
+                <mt-checklist title="checkbox list" v-model="ids" :options="list" @change="checkon"></mt-checklist>
+            </div>
+        </mt-popup>
+    </div>
+</template>
+
+<script>
+	export default {
+		data() {
+			return {
+                id: this.$route.params.id,
+                list: [],
+                ids: [],
+                idStr: '',
+                assetsForm: {
+                    goodsId: this.$route.params.id,
+                    ids: '',
+                    operator: '',
+                    operatorPhone: '',
+                    company: '',
+                    companyPhone: '',
+                },
+                state: "",
+                userName: "",
+                popupVisible: false,
+                canClick: true,
+			}
+		},
+		methods: {
+            // 待维护资产
+            getMainList() {
+                this.http.post(this.port.assets.maintainList, {
+                    'id': this.id
+                } , 
+                res => {
+                    if (res.code == "ok") {
+                        var list = [];
+                        for(var i in res.data) {
+                            list.push({
+                                label: res.data[i].modelNo,
+                                value: res.data[i].id,
+                            })
+                        }
+                        this.list = list;
+                    } else {
+                        this.$toast({
+                            message: res.msg,
+                            duration: 2000
+                        });
+                    }
+                }, error => {
+                    this.$toast({
+                        message: error,
+                        duration: 2000
+                    });
+                })
+            },
+
+            choosePeo() {
+                this.popupVisible = true;
+            },
+
+            toPrev() {
+                this.popupVisible = false;
+            },
+
+            checkon() {
+                this.idStr = "";
+                this.assetsForm.ids = "";
+                for(var i in this.ids) {
+                    for(var j in this.list) {
+                        if(this.ids[i] == this.list[j].value) {
+                            this.idStr += this.list[j].label + ',';
+                            this.assetsForm.ids += this.list[j].value + ',';
+                            break;
+                        }
+                    }
+                }
+                this.idStr = this.idStr.substring(0,this.idStr.length-1)
+                this.assetsForm.ids = this.assetsForm.ids.substring(0,this.assetsForm.ids.length-1)
+            },
+
+            // 创建
+            submit() {
+                if(this.canClick) {
+                    this.canClick = false;
+                    if(this.assetsForm.ids == "") {
+                        this.$toast({
+                            message: '请选择资产编号',
+                            duration: 2000
+                        });
+                        this.canClick = true;
+                        return false;
+                    } else if(this.assetsForm.operator == null || this.assetsForm.operator == "") {
+                        this.$toast({
+                            message: '请输入维护人',
+                            duration: 2000
+                        });
+                        this.canClick = true;
+                        return false;
+                    } else if(this.assetsForm.operatorPhone == null || this.assetsForm.operatorPhone == "") {
+                        this.$toast({
+                            message: '请输入维护人联系方式',
+                            duration: 2000
+                        });
+                        this.canClick = true;
+                        return false;
+                    } else if(this.assetsForm.company == null || this.assetsForm.company == "") {
+                        this.$toast({
+                            message: '请输入维护厂家',
+                            duration: 2000
+                        });
+                        this.canClick = true;
+                        return false;
+                    } else if(this.assetsForm.companyPhone == null || this.assetsForm.companyPhone == "") {
+                        this.$toast({
+                            message: '请输入维护厂家联系方式',
+                            duration: 2000
+                        });
+                        this.canClick = true;
+                        return false;
+                    } else {
+                        this.$indicator.open();
+                        var _this = this;
+                        this.http.post( this.port.assets.maintain, this.assetsForm,
+                        res => {
+                            this.$indicator.close();
+                            if (res.code == "ok") {
+                                this.$toast({
+                                    message: '维护成功',
+                                    duration: 2000
+                                });
+                                setTimeout(function(){
+                                    _this.$router.go(-1);
+                                }, 1000);
+                            } else {
+                                this.canClick = true;
+                                this.$toast({
+                                    message: res.msg,
+                                    duration: 2000
+                                });
+                            }
+                        },
+                        error => {
+                            this.canClick = true;
+                            this.$indicator.close();
+                            this.$toast({
+                                message: error,
+                                duration: 2000
+                            });
+                        });
+                    }
+                } else {
+                    this.$toast({
+                        message: '请勿重复提交',
+                        duration: 2000
+                    });
+                }
+            },
+
+            jumpBack() {
+                this.$router.go(-1);
+            }
+        },
+        created() {
+            this.getMainList();
+        },
+		mounted() {
+            
+		}
+	}
+
+</script>
+
+<style scoped>
+    .detail_head {
+        background: #fff;
+        color: #333;
+        height: 0.4rem;
+    }
+
+    .detail_body {
+        margin-top: 0.4rem;
+        padding-bottom: 0.15rem;
+    }
+
+    .detail {
+        background: #EFEFEF;
+        overflow: hidden;
+    }
+
+    .detailBox {
+        background: #fff;
+        margin-bottom: 0.11rem;
+    }
+
+    .left{
+        float:left;
+        margin: 0.15rem;
+    }
+
+    .upload .left {
+        margin: 0.1rem 0.11rem;
+    }
+
+    .right div{
+        line-height: 0.21rem;
+        white-space: nowrap;
+        overflow: hidden;
+        text-overflow: ellipsis;
+    }
+
+    .btn {
+        width: 80%;
+        margin: 0.2rem auto 80px;
+    }
+
+    .allocation {
+        width: 100%;
+        height: 100%;
+    }
+
+    .address_first .current{
+        background:#eee;
+        color: #6f83ff;
+        border-left: 2px solid #6f83ff;
+    }
+
+    .right > ul {
+        margin: 0;
+        padding: 0;
+        overflow: auto;
+        -webkit-transition-duration: 0.4s;
+        box-sizing:border-box;
+        padding: 0.08rem 0.1rem;
+    }
+
+    .right > ul > li {
+        display: inline-block;
+        height: 0.2rem;
+        line-height: 0.2rem;
+        font-size: 0.14rem;
+        color: #ccc;
+        padding: 0 0.12rem;
+        margin: 0.06rem 0.03rem;
+        border: 1px solid #ccc;
+        border-radius: 50px;
+        min-width: 0.3rem;
+        text-align: center;
+    }
+
+    .right > ul > li.add {
+        border: 1px solid #777;
+        color: #777;
+    }
+    
+    .right > ul > li.active {
+        border: 1px solid #2680EB;
+        color: #2680EB;
+    }
+
+    .upload_add {
+        display: inline-block;
+        margin-bottom: 0.2rem;
+    }
+
+    .upload_add_image {
+        padding-top: 0.08rem;
+        margin: 0.15rem 0 0 0.3rem ;
+        width: 1rem;
+        height: 0.9rem;
+        border: 1px dashed rgba(0, 0, 0, .2);
+    }
+
+    .upload_add-image .camera {
+        font-size: 24px;
+    }
+
+    .upload_add_image p {
+        padding: 0;
+        margin: 0;
+        color: #8e8e8e;
+    }
+
+    .right div img.pic {
+        width: 0.8rem;
+        height: 0.8rem;
+        margin: 0.15rem 0 0 0.3rem ;
+    }
+
+    .textColor {
+        margin-top: 0.4rem;
+        color: #8e8e8e;
+        padding: 0.12rem;
+        font-size: 0.12rem;
+    }
+
+    .example {
+        color: #8e8e8e;
+        padding: 0.02rem 0.12rem;
+        font-size: 0.12rem;
+    }
+
+    .allBtn {
+        width: 80%;
+        margin: 0.18rem auto;
+    }
+</style>
+<style>
+    .detail_head .mint-header-title {
+        font-weight: 600;
+        font-size: 0.15rem;
+    }
+
+    .detail_head .mint-button-text {
+        color: #26a2ff;
+    }
+
+    .detailBox .mint-cell {
+        padding: 0 0 0 0.02rem;
+    }
+    
+    .mint-popup.allocation  {
+        background: #efefef;
+    }
+
+    .mint-msgbox {
+        width: 70%;
+    }
+
+    .mint-cell-wrapper {
+        background-image: none;
+    }
+
+    input:disabled {
+        background: #fff;
+    }
+
+    textarea:disabled {
+        background: #fff;
+    }
+</style>

+ 272 - 0
lss_vue/src/views/assets/assetsNumber.vue

@@ -0,0 +1,272 @@
+<template>
+	<div class="detail">
+        <mt-header class="detail_head" fixed title="分配资产">
+            <router-link to="" slot="left">
+                <mt-button icon="back" v-on:click="jumpBack()"></mt-button>
+            </router-link>
+        </mt-header>
+        <div class="detailBox textColor">
+            资产编号构成:部门编号 + 字母前缀 + 数字序号,字母前缀最多四位,数字序号由系统排序生成
+        </div>
+        <div class="detailBox">
+            <mt-field label="部门编号" placeholder="请输入部门编号" v-model="assetsForm.divisionCode"></mt-field>
+            <mt-field label="字母前缀" placeholder="请输入字母前缀" v-model="assetsForm.suffixCode"></mt-field>
+        </div>
+        <div class="example">示例:Lishui-LXDN0001、Lishui-LXDN0002</div>
+        <mt-button class="allBtn" size="large" type="primary" v-on:click.native="submit()">确定</mt-button>
+        <mt-button class="allBtn" size="large" v-on:click.native="jumpBack()">取消</mt-button>
+    </div>
+</template>
+
+<script>
+	export default {
+		data() {
+			return {
+                user: JSON.parse(sessionStorage.getItem("user")),
+                assetsForm: {
+                    goodsId: this.$route.params.id,
+                    divisionCode: this.$route.params.divisionCode,
+                    suffixCode: this.$route.params.suffixCode,
+                },
+                canClick: true,
+			}
+		},
+		methods: {
+            // 创建
+            submit() {
+                if(this.canClick) {
+                    this.canClick = false;
+                    var reg = /^^[A-Za-z]{1,4}$/;
+                    if(this.assetsForm.divisionCode == null || this.assetsForm.divisionCode == "") {
+                        this.$toast({
+                            message: '请输入部门编号',
+                            duration: 2000
+                        });
+                        this.canClick = true;
+                        return false;
+                    } else if(this.assetsForm.suffixCode == null || this.assetsForm.suffixCode == "") {
+                        this.$toast({
+                            message: '请输入字母前缀',
+                            duration: 2000
+                        });
+                        this.canClick = true;
+                        return false;
+                    } else if(!reg.test(this.assetsForm.suffixCode)) {
+                        this.$toast({
+                            message: '请输入不多于四位字母前缀',
+                            duration: 2000
+                        });
+                        this.canClick = true;
+                        return false;
+                    } else {
+                        this.$indicator.open();
+                        var _this = this;
+                        this.http.post( this.port.assets.distribute, this.assetsForm,
+                        res => {
+                            this.$indicator.close();
+                            if (res.code == "ok") {
+                                this.$toast({
+                                    message: '修改成功',
+                                    duration: 2000
+                                });
+                                setTimeout(function(){
+                                    _this.$router.go(-1);
+                                }, 1000);
+                            } else {
+                                this.canClick = true;
+                                this.$toast({
+                                    message: res.msg,
+                                    duration: 2000
+                                });
+                            }
+                        },
+                        error => {
+                            this.canClick = true;
+                            this.$indicator.close();
+                            this.$toast({
+                                message: error,
+                                duration: 2000
+                            });
+                        });
+                    }
+                } else {
+                    this.$toast({
+                        message: '请勿重复提交',
+                        duration: 2000
+                    });
+                }
+            },
+
+            jumpBack() {
+                this.$router.go(-1);
+            }
+        },
+        created() {
+        },
+		mounted() {
+            
+		}
+	}
+
+</script>
+
+<style scoped>
+    .detail_head {
+        background: #fff;
+        color: #333;
+        height: 0.4rem;
+    }
+
+    .detail_body {
+        margin-top: 0.4rem;
+        padding-bottom: 0.15rem;
+    }
+
+    .detail {
+        background: #EFEFEF;
+        overflow: hidden;
+    }
+
+    .detailBox {
+        background: #fff;
+        margin-bottom: 0.11rem;
+    }
+
+    .left{
+        float:left;
+        margin: 0.15rem;
+    }
+
+    .upload .left {
+        margin: 0.1rem 0.11rem;
+    }
+
+    .right div{
+        line-height: 0.21rem;
+        white-space: nowrap;
+        overflow: hidden;
+        text-overflow: ellipsis;
+    }
+
+    .btn {
+        width: 80%;
+        margin: 0.2rem auto 80px;
+    }
+
+    .allocation {
+        width: 100%;
+        height: 100%;
+    }
+
+    .address_first .current{
+        background:#eee;
+        color: #6f83ff;
+        border-left: 2px solid #6f83ff;
+    }
+
+    .right > ul {
+        margin: 0;
+        padding: 0;
+        overflow: auto;
+        -webkit-transition-duration: 0.4s;
+        box-sizing:border-box;
+        padding: 0.08rem 0.1rem;
+    }
+
+    .right > ul > li {
+        display: inline-block;
+        height: 0.2rem;
+        line-height: 0.2rem;
+        font-size: 0.14rem;
+        color: #ccc;
+        padding: 0 0.12rem;
+        margin: 0.06rem 0.03rem;
+        border: 1px solid #ccc;
+        border-radius: 50px;
+        min-width: 0.3rem;
+        text-align: center;
+    }
+
+    .right > ul > li.add {
+        border: 1px solid #777;
+        color: #777;
+    }
+    
+    .right > ul > li.active {
+        border: 1px solid #2680EB;
+        color: #2680EB;
+    }
+
+    .upload_add {
+        display: inline-block;
+        margin-bottom: 0.2rem;
+    }
+
+    .upload_add_image {
+        padding-top: 0.08rem;
+        margin: 0.15rem 0 0 0.3rem ;
+        width: 1rem;
+        height: 0.9rem;
+        border: 1px dashed rgba(0, 0, 0, .2);
+    }
+
+    .upload_add-image .camera {
+        font-size: 24px;
+    }
+
+    .upload_add_image p {
+        padding: 0;
+        margin: 0;
+        color: #8e8e8e;
+    }
+
+    .right div img.pic {
+        width: 0.8rem;
+        height: 0.8rem;
+        margin: 0.15rem 0 0 0.3rem ;
+    }
+
+    .textColor {
+        margin-top: 0.4rem;
+        color: #8e8e8e;
+        padding: 0.12rem;
+        font-size: 0.12rem;
+    }
+
+    .example {
+        color: #8e8e8e;
+        padding: 0.02rem 0.12rem;
+        font-size: 0.12rem;
+    }
+
+    .allBtn {
+        width: 80%;
+        margin: 0.18rem auto;
+    }
+</style>
+<style>
+    .detail_head .mint-header-title {
+        font-weight: 600;
+        font-size: 0.15rem;
+    }
+
+    .detail_head .mint-button-text {
+        color: #26a2ff;
+    }
+
+    .detailBox .mint-cell {
+        padding: 0 0 0 0.02rem;
+    }
+    
+    .mint-popup.allocation  {
+        background: #efefef;
+    }
+
+    .mint-msgbox {
+        width: 70%;
+    }
+
+    .mint-cell-wrapper {
+        background-image: none;
+    }
+</style>

+ 371 - 0
lss_vue/src/views/assets/assetsOperation.vue

@@ -0,0 +1,371 @@
+<template>
+	<div class="detail">
+        <mt-header class="detail_head" fixed title="操作记录">
+            <router-link to="" slot="left">
+                <mt-button icon="back" v-on:click="jumpBack()"></mt-button>
+            </router-link>
+            <mt-button slot="right" v-on:click="exportExcel()">导出</mt-button>
+        </mt-header>
+        <div class="detail_body">
+            <mt-navbar v-model="selected" class="tab_head" v-on:click.native="changeTab">
+                <mt-tab-item id="tab1">处置记录</mt-tab-item>
+                <mt-tab-item id="tab2">维护记录</mt-tab-item>
+            </mt-navbar>
+            <mt-tab-container v-model="selected">
+                <mt-tab-container-item id="tab1">
+                    <div class="noList" v-if="disList.length==0">
+                        <img src="../../assets/image/noList.png">
+                    </div>
+                    <ul v-else class="recordBox" v-infinite-scroll="loadMoreDis" infinite-scroll-disabled="loading" infinite-scroll-distance="10">
+                        <li v-for="item in disList" class="one_recordBox detailBox">
+                            <div class="record_head">
+                                <div>{{item.modelNo}}</div>
+                                <span v-if="item.goodState == 0">未用</span>
+                                <span v-if="item.goodState == 1">在用</span>
+                                <span v-if="item.goodState == 3">报废</span>
+                            </div>
+                            <div class="record_body">
+                                <div>处置人:{{item.userName}}</div>
+                                <div>处置时间:{{item.indate}}</div>
+                                <div>操作:{{item.content}}</div>
+                            </div>
+                        </li>
+                        <div class="order" v-if="haveMoreDis">
+                            <span class="line"></span>
+                            <span class="txt">没有更多了</span>
+                            <span class="line"></span>
+                        </div>
+                    </ul>
+                </mt-tab-container-item>
+                <mt-tab-container-item id="tab2">
+                    <div class="noList" v-if="maiList.length==0">
+                        <img src="../../assets/image/noList.png">
+                    </div>
+                    <ul v-else class="recordBox" v-infinite-scroll="loadMoreMai" infinite-scroll-disabled="loading" infinite-scroll-distance="10">
+                        <li v-for="item in maiList" class="one_recordBox detailBox">
+                            <div class="record_head">
+                                {{item.modelNo}}
+                            </div>
+                            <div class="record_body">
+                                <div>维护人:{{item.operator}}</div>
+                                <div>联系方式:{{item.operatorPhone}}</div>
+                                <div>维护厂家:{{item.company}}</div>
+                                <div>联系方式:{{item.companyPhone}}</div>
+                            </div>
+                        </li>
+                        <div class="order" v-if="haveMoreDis">
+                            <span class="line"></span>
+                            <span class="txt">没有更多了</span>
+                            <span class="line"></span>
+                        </div>
+                    </ul>
+                </mt-tab-container-item>
+            </mt-tab-container>
+        </div>
+    </div>
+</template>
+
+<script>
+	export default {
+		data() {
+			return {
+                id: this.$route.params.id,
+                selected: "tab1",
+
+                disList: [],
+                disPageNum: 1,
+                disPages: 1,
+                haveMoreDis: false,
+
+                maiList: [],
+                maiPageNum: 1,
+                maiPages: 1,
+                haveMoreMai: false,
+			}
+		},
+		methods: {
+            // 处置记录
+            getListDis() {
+                this.$indicator.open();
+                this.http.post(this.port.assets.disposalRecord, {
+                    'id': this.id,
+                    'pageNum': this.disPageNum
+                } , 
+                res => {
+                    this.$indicator.close();
+                    if (res.code == "ok") {
+                        this.disList = res.data.list;
+                        this.disPages = res.data.pages==0?1:res.data.pages;
+                    } else {
+                        this.$toast({
+                            message: res.msg,
+                            duration: 2000
+                        });
+                    }
+                }, error => {
+                    this.$indicator.close();
+                    this.$toast({
+                        message: error,
+                        duration: 2000
+                    });
+                })
+            },
+
+            loadMoreDis() {
+                if(this.disPageNum == this.disPages) {
+                    this.haveMoreDis = true;
+                } else if(this.disPageNum < this.disPages) {
+                    this.$indicator.open();
+                    this.http.post(this.port.assets.disposalRecord, {
+                        'id': this.id,
+                        'pageNum': ++this.disPageNum
+                    } , 
+                    res => {
+                        this.$indicator.close();
+                        if (res.code == "ok") {
+                            this.disPages = res.data.pages==0?1:res.data.pages;
+                            if(res.data.list.length != 0) {
+                                for(var i in res.data.list) {
+                                    this.disList.push(res.data.list[i]);
+                                }
+                            }
+                        } else {
+                            this.$toast({
+                                message: res.msg,
+                                duration: 2000
+                            });
+                        }
+                    }, error => {
+                        this.$indicator.close();
+                        this.$toast({
+                            message: error,
+                            duration: 2000
+                        });
+                    })
+                }
+            },
+
+            // 维护记录
+            getListMai() {
+                this.$indicator.open();
+                this.http.post(this.port.assets.maintainRecord, {
+                    'id': this.id,
+                    'pageNum': this.maiPageNum
+                } , 
+                res => {
+                    this.$indicator.close();
+                    if (res.code == "ok") {
+                        this.maiList = res.data.list;
+                        this.maiPages = res.data.pages==0?1:res.data.pages;
+                    } else {
+                        this.$toast({
+                            message: res.msg,
+                            duration: 2000
+                        });
+                    }
+                }, error => {
+                    this.$indicator.close();
+                    this.$toast({
+                        message: error,
+                        duration: 2000
+                    });
+                })
+            },
+
+            loadMoreMai() {
+                if(this.maiPageNum == this.maiPages) {
+                    this.haveMoreMai = true;
+                } else if(this.maiPageNum < this.maiPages) {
+                    this.$indicator.open();
+                    this.http.post(this.port.assets.maintainRecord, {
+                        'id': this.id,
+                        'pageNum': ++this.maiPageNum
+                    } , 
+                    res => {
+                        this.$indicator.close();
+                        if (res.code == "ok") {
+                            this.maiPages = res.data.pages==0?1:res.data.pages;
+                            if(res.data.list.length != 0) {
+                                for(var i in res.data.list) {
+                                    this.maiList.push(res.data.list[i]);
+                                }
+                            }
+                        } else {
+                            this.$toast({
+                                message: res.msg,
+                                duration: 2000
+                            });
+                        }
+                    }, error => {
+                        this.$indicator.close();
+                        this.$toast({
+                            message: error,
+                            duration: 2000
+                        });
+                    })
+                }
+            },
+
+            changeTab() {
+                if(this.selected == "tab1") {
+                    this.getListDis();
+                } else {
+                    this.getListMai();
+                }
+            },
+
+            // 导出
+            exportExcel() {
+                this.$indicator.open();
+                if(this.selected == "tab1") {
+                    this.http.downloadFile(this.port.assets.exportDis, {
+                        'id': this.id,
+                    } , 
+                    res => {
+                        this.$indicator.close();
+                        let url = window.URL.createObjectURL(new Blob([res]))
+                        let link = document.createElement('a')
+                        link.style.display = 'none'
+                        link.href = url
+                        link.setAttribute('download', '操作记录.xlsx')
+                        document.body.appendChild(link)
+                        link.click()
+                    }, error => {
+                        this.$indicator.close();
+                        this.$toast({
+                            message: error,
+                            duration: 2000
+                        });
+                    })
+                } else {
+                    this.http.downloadFile(this.port.assets.exportMain, {
+                        'id': this.id,
+                    } , 
+                    res => {
+                        this.$indicator.close();
+                        this.$indicator.close();
+                        let url = window.URL.createObjectURL(new Blob([res]))
+                        let link = document.createElement('a')
+                        link.style.display = 'none'
+                        link.href = url
+                        link.setAttribute('download', '操作记录.xlsx')
+                        document.body.appendChild(link)
+                        link.click()
+                    }, error => {
+                        this.$indicator.close();
+                        this.$toast({
+                            message: error,
+                            duration: 2000
+                        });
+                    })
+                }
+            },
+
+            jumpBack() {
+                this.$router.go(-1);
+            }
+        },
+        created() {
+            this.getListDis();
+        },
+		mounted() {
+            
+		}
+	}
+
+</script>
+
+<style scoped>
+    body {
+        background: #EFEFEF;
+    }
+
+    .detail_head {
+        background: #fff;
+        color: #333;
+        height: 0.4rem;
+    }
+
+    .detail_body {
+        margin-top: 0.8rem;
+        padding-bottom: 0.15rem;
+    }
+
+    .tab_head {
+        position: fixed;
+        width: 100%;
+        top: 0.4rem;
+        z-index: 110;
+    }
+
+    .detail {
+        background: #EFEFEF;
+    }
+
+    .detailBox {
+        background: #fff;
+        margin-bottom: 0.11rem;
+    }
+
+    .recordBox {
+        margin: 0.12rem 0 0 0;
+    }
+
+    .one_recordBox {
+        padding: 0.12rem 0.2rem;
+    }
+
+    .record_head {
+        color: #5FA1F0;
+        padding: 0 0 0.1rem 0;
+        border-bottom: 1px solid #ccc;
+    }
+
+    .record_head > div {
+        width: 85%;
+        display: inline-block;
+        vertical-align: middle;
+    }
+
+    .record_head span {
+        color: #939393;
+        float: right;
+        vertical-align: middle;
+    }
+
+    .record_body {
+        color: #777;
+        font-size: 0.12rem;
+        line-height: 0.23rem;
+        margin-top: 0.12rem;
+    }
+
+    .noList {
+        text-align: center;
+        padding: 1.5rem 0;
+    }
+
+    .noList img {
+        width: 1.2rem;
+        height: 1.2rem;
+    }
+
+    .order {
+        height: 0.6rem;
+        line-height: 0.6rem;
+        text-align: center;
+    }
+
+    .order .line {
+        display: inline-block;
+        width: 1.2rem;
+        border-top: 1px solid #ccc ;
+        vertical-align: middle;
+    }
+
+    .order .txt {
+        color: #ccc;
+        font-size: 0.13rem;
+        vertical-align: middle;
+    }
+</style>

+ 180 - 66
lss_vue/src/views/assets/assetsRegister.vue

@@ -14,10 +14,13 @@
                 <div class="upload">
                     <div class="left">物品图片</div>
                     <div class="right upload_add" v-on:click="choosePic()">
-                        <div class="upload_add_image" align="center">
+                        <div v-if="assetsForm.pic == ''" class="upload_add_image" align="center">
                             <img src="../../assets/image/camera.png" class="camera">
                             <p class="font13">添加图片</p>
                         </div>
+                        <div v-else class="right">
+                            <img class="pic" :src="assetsForm.pic">
+                        </div>
                     </div>
                     <input @change="fileChange($event)" type="file" accept="image/*" id="upload_file" style="display: none"/>
                 </div>
@@ -32,7 +35,10 @@
                 <div class="left">所属分类</div>
                 <div class="right">
                     <ul class="address_first">
-                        <li v-for="(item,index) in labels" :id="'btn'+item.id" v-bind:class="{'active':index==0}" v-on:click="chooseTag(item.id)">{{item.name}}</li>
+                        <li v-for="(item,index) in labels" :id="'btn'+item.id" v-bind:class="{'active':index==0}" v-on:click="chooseTag(item.id)">
+                            {{item.name}}
+                            <img v-if="index > 7" v-on:click="delTag(item.id)" src="../../assets/image/del.png">
+                        </li>
                         <li v-on:click="addNewTag()" class="add">+</li>
                     </ul>
                 </div>
@@ -48,7 +54,7 @@
                 </router-link>
             </mt-header>
             <div class="detailBox textColor">
-                资产编号构成:字母前缀 + 四位数字,请填写字母编号(最多四位)数字编号由系统排序生成
+                资产编号构成:部门编号 + 字母前缀 + 数字序号,字母前缀最多四位,数字序号由系统排序生成
             </div>
             <div class="detailBox">
                 <mt-field label="部门编号" placeholder="请输入部门编号" v-model="assetsForm.deptStr"></mt-field>
@@ -77,17 +83,16 @@
                     factory: '',
                     serviceLife: '',
                     nextIndate: '',
-                    file: '',
+                    pic: '',
+                    tagId: 0,
                     deptStr: '',
                     goodStr: '',
                 },
                 popupVisible: false,
                 labels: [],
                 tagId: 0,
-                img: '',
-                size: 0,
                 limit: 1,
-                imgList: [],
+                canClick: true,
 			}
 		},
 		methods: {
@@ -167,7 +172,42 @@
 
             chooseTag(id) {
                 $("#btn"+id).addClass("active").siblings().removeClass("active");
-                this.tagId = id;
+                this.assetsForm.tagId = id;
+            },
+
+            delTag(id) {
+                MessageBox.confirm('', { 
+                    message: '是否删除该分类?', 
+                        title: '', 
+                        confirmButtonText: '确定', 
+                        cancelButtonText: '取消' 
+                 }).then(action => { 
+                    if (action == 'confirm') {     //确认的回调
+                        this.http.post(this.port.label.del, {
+                            'id': id
+                        } , 
+                        res => {
+                            if (res.code == "ok") {
+                                this.$toast({
+                                    message: "删除成功",
+                                    duration: 2000
+                                });
+                                this.getLabels();
+                            } else {
+                                this.$toast({
+                                    message: res.msg,
+                                    duration: 2000
+                                });
+                            }
+                        }, error => {
+                            this.$toast({
+                                message: error,
+                                duration: 2000
+                            });
+                        })
+                    }
+                 }).catch(err => { 
+                 });
             },
 
             // 图片上传
@@ -182,11 +222,6 @@
             },
 
             fileAdd(file) {
-                if (this.limit !== undefined) this.limit--;
-                if (this.limit !== undefined && this.limit < 0) return;
-
-                //总大小
-                this.size = this.size + file.size;
                 //判断是否为图片文件
                 if (file.type.indexOf('image') == -1) {
                     this.$toast({
@@ -194,69 +229,123 @@
                         duration: 2000
                     });
                 } else {
-                    let reader = new FileReader();
-                    let image = new Image();
-                    let _this = this;
-                    reader.readAsDataURL(file);
-                    reader.onload = function () {
-                        file.src = this.result;
-                        image.onload = function(){
-                            let width = image.width;
-                            let height = image.height;
-                            file.width = width;
-                            file.height = height;
-                            _this.imgList.push({
-                                file
+                    var form = new FormData();
+                    form.append("file", file);
+                    this.$indicator.open();
+                    this.http.uploadFile( this.port.assets.upload, form,
+                    res => {
+                        this.$indicator.close();
+                        if (res.code == "ok") {
+                            this.$toast({
+                                message: '上传成功',
+                                duration: 2000
                             });
-                        };
-                        image.src= file.src;
-                    }
-                    _this.assetsForm.file = reader;
+                            this.assetsForm.pic = res.data;
+                            document.getElementById('upload_file').value = "";
+                        } else {
+                            this.$toast({
+                                message: res.msg,
+                                duration: 2000
+                            });
+                        }
+                    },
+                    error => {
+                        this.$indicator.close();
+                        this.$toast({
+                            message: error,
+                            duration: 2000
+                        });
+                    });
                 }
             },
 
             // 创建
             submit() {
-                // var fileObj = params.file;
-                var form = new FormData();
-                // form.append("file", fileObj);
-                form.append("userId", JSON.parse(sessionStorage.getItem("user")).id);
-                form.append("name", this.assetsForm.name);
-                form.append("modelNumber", this.assetsForm.modelNumber);
-                form.append("number", this.assetsForm.number);
-                form.append("unit", this.assetsForm.unit);
-                form.append("address", this.assetsForm.address);
-                form.append("factory", this.assetsForm.factory);
-                form.append("serviceLife", this.assetsForm.serviceLife);
-                form.append("nextIndate", this.assetsForm.nextIndate);
-                form.append("deptStr", this.assetsForm.deptStr);
-                form.append("goodStr", this.assetsForm.goodStr);
-                this.$indicator.open();
-                this.http.uploadFile( this.port.assets.add, form,
-                res => {
-                    this.$indicator.close();
-                    if (res.code == "ok") {
+                if(this.canClick) {
+                    this.canClick = false;
+                    var reg = /^^[A-Za-z]{1,4}$/;
+                    if(this.assetsForm.name == null || this.assetsForm.name == "") {
                         this.$toast({
-                            message: '创建成功',
+                            message: '请输入物品名称',
                             duration: 2000
                         });
-                        this.$router.push({ path: '/assets' });
-                    } else {
+                        this.canClick = true;
+                        return false;
+                    } else if(this.assetsForm.number == null || this.assetsForm.number == "") {
                         this.$toast({
-                            message: res.msg,
+                            message: '请输入物品数量',
                             duration: 2000
                         });
+                        this.canClick = true;
+                        return false;
+                    } else if(this.assetsForm.unit == null || this.assetsForm.unit == "") {
+                        this.$toast({
+                            message: '请输入物品单位',
+                            duration: 2000
+                        });
+                        this.canClick = true;
+                        return false;
+                    } else if(this.assetsForm.deptStr == null || this.assetsForm.deptStr == "") {
+                        this.$toast({
+                            message: '请输入部门编号',
+                            duration: 2000
+                        });
+                        this.canClick = true;
+                        return false;
+                    } else if(this.assetsForm.goodStr == null || this.assetsForm.goodStr == "") {
+                        this.$toast({
+                            message: '请输入字母前缀',
+                            duration: 2000
+                        });
+                        this.canClick = true;
+                        return false;
+                    } else if(!reg.test(this.assetsForm.goodStr)) {
+                        this.$toast({
+                            message: '请输入不多于四位字母前缀',
+                            duration: 2000
+                        });
+                        this.canClick = true;
+                        return false;
+                    } else {
+                        this.$indicator.open();
+                        var _this = this;
+                        this.http.post( this.port.assets.add, this.assetsForm,
+                        res => {
+                            this.$indicator.close();
+                            if (res.code == "ok") {
+                                this.$toast({
+                                    message: '创建成功',
+                                    duration: 2000
+                                });
+                                setTimeout(function(){
+                                    _this.$router.push({ path: '/assets' });
+                                }, 1000);
+                            } else {
+                                this.canClick = true;
+                                this.$toast({
+                                    message: res.msg,
+                                    duration: 2000
+                                });
+                            }
+                        },
+                        error => {
+                            this.canClick = true;
+                            this.$indicator.close();
+                            this.$toast({
+                                message: error,
+                                duration: 2000
+                            });
+                        });
                     }
-                },
-                error => {
-                    this.$indicator.close();
+                } else {
                     this.$toast({
-                        message: error,
+                        message: '请勿重复提交',
                         duration: 2000
                     });
-                });
+                }
             },
 
+            // 跳转
             toNext() {
                 this.popupVisible = true;
             },
@@ -288,6 +377,7 @@
 
     .detail_body {
         margin-top: 0.4rem;
+        padding-bottom: 0.15rem;
     }
 
     .detail {
@@ -296,16 +386,17 @@
 
     .detailBox {
         background: #fff;
-        margin-bottom: 0.15rem;
+        margin-bottom: 0.11rem;
     }
 
     .left{
-        float:left;
-        margin: 0.15rem;
+        /* float:left; */
+        /* margin: 0.15rem; */
+        padding: 0.15rem 0.15rem 0.1rem 0.15rem;
     }
 
     .upload .left {
-        margin: 0.1rem 0.14rem;
+        /* margin: 0.1rem 0.11rem; */
     }
 
     .right div{
@@ -343,15 +434,24 @@
     .right > ul > li {
         display: inline-block;
         height: 0.2rem;
-        line-height: 0.2rem;
+        line-height: 0.22rem;
         font-size: 0.14rem;
         color: #ccc;
-        padding: 0 0.12rem;
-        margin: 0.06rem 0.03rem;
+        padding: 0.02rem 0.12rem;
+        margin: 0.06rem 0.07rem;
         border: 1px solid #ccc;
         border-radius: 50px;
         min-width: 0.3rem;
         text-align: center;
+        position: relative;
+    }
+
+    .right > ul > li img {
+        position: absolute;
+        top: -0.05rem;
+        right: -0.08rem;
+        width: 0.18rem;
+        height: 0.18rem;
     }
 
     .right > ul > li.add {
@@ -371,7 +471,7 @@
 
     .upload_add_image {
         padding-top: 0.08rem;
-        margin-left: 0.1rem;
+        margin: 0.15rem 0 0 0.3rem ;
         width: 1rem;
         height: 0.9rem;
         border: 1px dashed rgba(0, 0, 0, .2);
@@ -387,6 +487,12 @@
         color: #8e8e8e;
     }
 
+    .right div img.pic {
+        width: 0.8rem;
+        height: 0.8rem;
+        margin: 0.15rem 0 0 0.3rem ;
+    }
+
     .textColor {
         margin-top: 0.4rem;
         color: #8e8e8e;
@@ -422,4 +528,12 @@
     .mint-popup.allocation  {
         background: #efefef;
     }
+
+    .mint-msgbox {
+        width: 70%;
+    }
+
+    .mint-cell-wrapper {
+        background-image: none;
+    }
 </style>

+ 220 - 3
lss_vue/src/views/data/data.vue

@@ -61,6 +61,7 @@
                     <div>当日数据交换量:{{tab3_head1}}</div>
                     <div>数据交换次数:{{tab3_head2}}</div>
                 </div>
+                <div id="tab3_chart1" class="echarts echartsBox"></div>
             </mt-tab-container-item>
         </mt-tab-container>
     </div>
@@ -83,7 +84,7 @@
                 pageNum: 1,
                 tagId: 0,
                 popupVisible: false,
-                department: ['交通', '公安', '卫计', '国土', '城管', '安监', '房产', '教育', '旅游', '水务', '法院', '环保', '财政'],
+                department: ['交通', '公安', '卫计', '国土', '城管', '安监', '房产', '教育', '旅游', '水务', '法院', '环保', '财政'],
 			}
 		},
 		methods: {
@@ -419,6 +420,222 @@
                 myChart.setOption(option);
             },
 
+            // 数据交换
+            set_tab3_chart1(){
+                // var uploadedDataURL = "/asset/get/s/data-1559121268278-ozjd-lXoz.png";
+                // var uploadedDataURL = "/asset/get/s/data-1559121263841-UC5w7mTJ9.png";
+                // var uploadedDataURL = "/asset/get/s/data-1559121259198-sxyPSimU9.png";
+                // var uploadedDataURL = "/asset/get/s/data-1559121254241-xj5JAIBzC.png";
+                // var uploadedDataURL = "/asset/get/s/data-1559121249274-QxHDAdQGy.png";
+                var  colorList=['#afa3f5', '#00d488', '#3feed4', '#3bafff', '#f1bb4c','#afa3f5', '#00d488', '#3feed4', '#3bafff', '#f1bb4c','#afa3f5', '#00d488', '#3feed4', '#3bafff', '#f1bb4c', "rgba(250,250,250,0.5)"];
+                var sportsIcon = {
+                    'a':'../../assets/image/userHead.jpg',
+                    'b':'../../assets/image/userHead.jpg',
+                    'c':'../../assets/image/userHead.jpg',
+                    'd':'../../assets/image/userHead.jpg',
+                    'e':'../../assets/image/userHead.jpg',
+                };
+                var myChart = this.echarts.init(document.getElementById('tab3_chart1'));
+                var option = {
+                    backgroundColor: '#fff',
+                    title: {
+                        text: '80',
+                        subtext: '总量',
+                        x: 'center',
+                        y: 'center',
+                        textStyle: {
+                            fontSize:20,
+                            fontWeight:'normal',
+                            color: ['#333']
+                        },
+                        subtextStyle: {
+                            color: '#666',
+                            fontSize: 12
+                        },
+                    },
+                    grid: {
+                        bottom: 150,
+                        left: 0,
+                        right: '10%'
+                    },
+                    legend: {
+                        show:false,
+                        orient: 'vertical',
+                        top: "middle",
+                        right: "5%",
+                        textStyle: {
+                            color: '#f2f2f2',
+                            fontSize: 13,
+
+                        },
+                        icon: 'roundRect'
+                    },
+                    series: [
+                        // 主要展示层的
+                        {
+                            radius: ['25%', '33%'],
+                            center: ['50%', '50%'],
+                            type: 'pie',
+                            itemStyle: {
+                                normal: {
+                                    color: function(params) {
+                                        return colorList[params.dataIndex]
+                                    }
+                                }
+                            },
+                            labelLine: {
+                                normal: {
+                                    show: true,
+                                    length: 15,
+                                    length2: 120,
+                                    lineStyle: {
+                                        color: '#d3d3d3'
+                                    },
+                                    align: 'right'
+                                },
+                                color: "#000",
+                                emphasis: {
+                                    show: true
+                                }
+                            },
+                            label:{
+                                normal:{
+                                    formatter: function(params){
+                                        var str = '';
+                                        console.log(params)
+                                        switch(params.name){
+                                            case '交通局':str = '{a|}\n{nameStyle|交通局 }'+'{rate|'+params.value+'%}\n' + '{rate|'+params.data.value1+'}';break;
+                                            case '公安局':str = '{b|}\n{nameStyle|公安局 }'+'{rate|'+params.value+'%}\n' + '{rate|'+params.data.value1+'}';break;
+                                            case '卫计局':str = '{c|}\n{nameStyle|卫计局 }'+'{rate|'+params.value+'%}\n' + '{rate|'+params.data.value1+'}';break;
+                                            case '国土局':str = '{d|}\n{nameStyle|国土局 }'+'{rate|'+params.value+'%}\n' + '{rate|'+params.data.value1+'}';break;
+                                            case '城管':str = '{a|}\n{nameStyle|城管 }'+'{rate|'+params.value+'%}\n' + '{rate|'+params.data.value1+'}';break;
+                                            case '安监局':str = '{e|}\n{nameStyle|安监局 }'+'{rate|'+params.value+'%}\n' + '{rate|'+params.data.value1+'}';break;
+                                            case '房产局':str = '{a|}\n{nameStyle|房产局 }'+'{rate|'+params.value+'%}\n' + '{rate|'+params.data.value1+'}';break;
+                                            case '教育局':str = '{e|}\n{nameStyle|教育局 }'+'{rate|'+params.value+'%}\n' + '{rate|'+params.data.value1+'}';break;
+                                            case '旅游局':str = '{a|}\n{nameStyle|旅游局 }'+'{rate|'+params.value+'%}\n' + '{rate|'+params.data.value1+'}';break;
+                                            case '水务局':str = '{e|}\n{nameStyle|水务局 }'+'{rate|'+params.value+'%}\n' + '{rate|'+params.data.value1+'}';break;
+                                            case '法院':str = '{a|}\n{nameStyle|法院 }'+'{rate|'+params.value+'%}\n' + '{rate|'+params.data.value1+'}';break;
+                                            case '环保局':str = '{e|}\n{nameStyle|环保局 }'+'{rate|'+params.value+'%}\n' + '{rate|'+params.data.value1+'}';break;
+                                            case '财政局':str = '{e|}\n{nameStyle|财政局 }'+'{rate|'+params.value+'%}\n' + '{rate|'+params.data.value1+'}';break;
+                                        }
+                                        return str
+                                    },
+                                    padding: [0, -110],
+                                    height: 165,
+                                    rich: {
+                                        a: {
+                                            width:24,
+                                            height:50,
+                                            lineHeight: 50,
+                                            backgroundColor: {
+                                                // image: sportsIcon.e
+                                            },
+                                            align: 'left'
+                                        },
+                                        b: {
+                                            width:24,
+                                            height:50,
+                                            lineHeight: 50,
+                                            backgroundColor: {
+                                                // image: sportsIcon.d
+                                            },
+                                            align: 'left'
+                                        },
+                                        c: {
+                                            width:24,
+                                            height:50,
+                                            lineHeight: 50,
+                                            backgroundColor: {
+                                                // image: sportsIcon.c
+                                            },
+                                            align: 'left'
+                                        },
+                                        d: {
+                                            width:24,
+                                            height:50,
+                                            lineHeight: 50,
+                                            backgroundColor: {
+                                                // image: sportsIcon.b
+                                            },
+                                            align: 'left'
+                                        },
+                                        e: {
+                                            width:24,
+                                            height:50,
+                                            lineHeight: 50,
+                                            backgroundColor: {
+                                                // image: sportsIcon.a
+                                            },
+                                            align: 'left'
+                                        },
+                                        nameStyle: {
+                                            fontSize: 14,
+                                            color: "#555",
+                                            align: 'left'
+                                        },
+                                        rate: {
+                                            fontSize: 12,
+                                            color: "#1ab4b8",
+                                            align: 'left'
+                                        }
+                                    }
+                                }
+                            },
+                            data: [
+                                {value:17, name:'交通局',value1:0,},
+                                {value:23, name:'公安局',value1:10,},
+                                {value:27, name:'卫计局',value1:20,},
+                                {value:33, name:'国土局',value1:30,},
+                                {value:20, name:'安监局',value1:50,},
+                                {value:39, name:'房产局',value1:60,},
+                                {value:29, name:'教育局',value1:70,},
+                                {value:19, name:'旅游局',value1:80,},
+                                {value:39, name:'水务局',value1:90,},
+                                {value:29, name:'法院',value1:100,},
+                                {value:80, name:'城管',value1:110,},
+                                {value:49, name:'环保局',value1:110,},
+                                {value:10, name:'财政局',value1:120,},
+                            ],
+                        },
+                        // 边框的设置
+                        {
+                            radius: ['40%', '47%'],
+                            center: ['50%', '50%'],
+                            type: 'pie',
+                            label: {
+                                normal: {
+                                    show: false
+                                },
+                                emphasis: {
+                                    show: false
+                                }
+                            },
+                            labelLine: {
+                                normal: {
+                                    show: false
+                                },
+                                emphasis: {
+                                    show: false
+                                }
+                            },
+                            animation: false,
+                            tooltip: {
+                                show: false
+                            },
+                            itemStyle: {
+                                normal: {
+                                    color:'rgba(250,250,250,0.5)'
+                                }
+                            },
+                            data: [{
+                                value: 1,
+                            }],
+                        }
+                    ]
+                };
+                myChart.setOption(option);
+            },
+
             changeTab() {
                 if(this.selected == 'tab1') {
                     this.set_tab1_chart1();
@@ -429,7 +646,7 @@
                     this.set_tab2_chart2();
                     this.set_tab2_chart3();
                 } else if(this.selected == 'tab3') {
-                    
+                    this.set_tab3_chart1();
                 }
             }
         },
@@ -486,7 +703,7 @@
     }
 
     .echartsBox {
-        margin-bottom: 0.15rem;
+        margin-bottom: 0.11rem;
     }
 
     .tab1_table {

+ 19 - 21
lss_vue/src/views/my/my.vue

@@ -1,28 +1,27 @@
 <template>
 	<div class="my">
-        <div class="mybox userInfo" v-on:click="jumpTo(0)">
+        <div class="mybox userInfo">
             <div class="left">
-                <img src="../../assets/image/userHead.jpg">
+                <img src="../../assets/image/userHead.png">
             </div>
             <div class="right">
                 <div>
-                    <span class="name">张学</span>
-                    <span class="phone">18255585207</span>
+                    <span class="name">{{user.name}}</span>
+                    <span class="phone">{{user.phone}}</span>
                 </div>
                 <div class="department">
-                    ****公司****部门****组
-                    <span class="arrow"><img src="../../assets/image/on_1.png"></span>
+                    {{user.deptName}}
                 </div>
             </div>
         </div>
         <div class="mybox">
-            <mt-cell title="我的消息" is-link v-on:click.native="jumpTo(1)"><img slot="icon" src="../../assets/image/my_message.png" width="24" height="24"></mt-cell>
+            <mt-cell title="我的消息" is-link v-on:click.native="jumpTo(1)"><mt-badge v-if="newNum!=0" size="small" type="error">{{newNum}}</mt-badge><img slot="icon" src="../../assets/image/my_message.png" width="24" height="24"></mt-cell>
             <mt-cell title="我的资产" is-link v-on:click.native="jumpTo(2)"><img slot="icon" src="../../assets/image/my_assets.png" width="24" height="24"></mt-cell>
-            <mt-cell title="我的评分" is-link v-on:click.native="jumpTo(3)"><img slot="icon" src="../../assets/image/my_score.png" width="24" height="24"></mt-cell>
-            <mt-cell title="我的建议" is-link v-on:click.native="jumpTo(4)"><img slot="icon" src="../../assets/image/my_sug.png" width="24" height="24"></mt-cell>
+            <mt-cell v-if="user.roles[0].rolename != '部门领导'" title="我的评分" is-link v-on:click.native="jumpTo(3)"><img slot="icon" src="../../assets/image/my_score.png" width="24" height="24"></mt-cell>
+            <mt-cell v-if="user.roles[0].rolename != '部门领导'" title="我的建议" is-link v-on:click.native="jumpTo(4)"><img slot="icon" src="../../assets/image/my_sug.png" width="24" height="24"></mt-cell>
         </div>
         <div class="mybox">
-            <mt-cell title="通讯录" is-link v-on:click.native="jumpTo(5)"><img slot="icon" src="../../assets/image/my_com.png" width="24" height="24"></mt-cell>
+            <mt-cell v-if="power.indexOf('address_book_operation')>-1" title="通讯录" is-link v-on:click.native="jumpTo(5)"><img slot="icon" src="../../assets/image/my_com.png" width="24" height="24"></mt-cell>
             <mt-cell title="管理制度" is-link v-on:click.native="jumpTo(6)"><img slot="icon" src="../../assets/image/my_sys.png" width="24" height="24"></mt-cell>
         </div>
     </div>
@@ -32,37 +31,37 @@
 	export default {
 		data() {
 			return {
+                user: JSON.parse(sessionStorage.getItem("user")),
+                power: sessionStorage.getItem("power"),
                 keyWord: "",
                 list: [],
                 labels: [],
                 pageNum: 1,
                 tagId: 0,
                 popupVisible: false,
+                newNum: sessionStorage.noRead,
 			}
 		},
 		methods: {
             jumpTo(type) {
                 switch(type){
-                    case 0:
-                        console.log(1111)
-                        break;
                     case 1:
-                        console.log(1111)
+                        this.$router.push("/myMessage");
                         break;
                     case 2:
-                        console.log(1111)
+                        this.$router.push("/myAssets");
                         break;
                     case 3:
-                        console.log(1111)
+                        this.$router.push("/myScore");
                         break;
                     case 4:
-                        console.log(1111)
+                        this.$router.push("/mySuggest");
                         break;
                     case 5:
-                        console.log(1111)
+                        this.$router.push("/myAddress");
                         break;
                     case 6:
-                        console.log(1111)
+                        this.$router.push("/myInstitution");
                         break;
                     default:
                         return false
@@ -73,7 +72,6 @@
         created() {
         },
 		mounted() {
-            
 		}
 	}
 
@@ -86,7 +84,7 @@
 
     .mybox {
         background: #fff;
-        margin-bottom: 0.15rem;
+        margin-bottom: 0.11rem;
     }
 
     .userInfo {

+ 246 - 0
lss_vue/src/views/my/myAddress.vue

@@ -0,0 +1,246 @@
+<template>
+	<div class="detail">
+        <mt-header class="detail_head" fixed title="通讯录">
+            <router-link to="" slot="left">
+                <mt-button icon="back" v-on:click="jumpBack()"></mt-button>
+            </router-link>
+        </mt-header>
+        <div class="detail_body">
+            <div class="noList" v-if="list.length==0">
+                <img src="../../assets/image/noList.png">
+            </div>  
+            <ul v-else class="recordBox">
+                <li v-for="(item,index) in list" :id="'tab' + item.departmentGuid" class="one_recordBox detailBox">
+                    <div v-on:click="showList('tab'+item.departmentGuid)">
+                        <img :class="item.departmentGuid == user.deptId?'rotate1':'rotate'" src="../../assets/image/down_blue.png"> 
+                        <span>{{item.departmentName}}</span>
+                    </div>
+                    <ul :style="item.departmentGuid == user.deptId?'':'display:none'">
+                        <li v-for="(peo,num) in item.userVOS" class="one_peo">
+                            <div class="one_peo_head">
+                                <img src="../../assets/image/userHead.png">
+                            </div>
+                            <div class="one_peo_body">
+                                <div>{{peo.name}} <span v-if="peo.roleName=='部门领导'" style="color: #5FA1F0;margin-left:0.05rem;font-size:0.12rem;">({{peo.roleName}})</span></div>
+                                <div>{{peo.phone}}</div>
+                            </div>
+                            <div v-if="peo.roleName!='部门领导' && item.departmentGuid == user.deptId && user.roles[0].rolename == '部门领导' && power.indexOf('scoring')>-1" 
+                                class="one_peo_score" v-on:click="toScore(peo.id,peo.name)">
+                                {{peo.totalScore==null?"打分":peo.totalScore + "分"}}
+                                <span class="toScore"><img class="rotate" src="../../assets/image/pull_down_blue.png"></span>
+                            </div>
+                        </li>
+                    </ul>
+                </li>
+            </ul>
+        </div>
+    </div>
+</template>
+
+<script>
+	export default {
+		data() {
+			return {
+                user: JSON.parse(sessionStorage.getItem("user")),
+                power: sessionStorage.getItem("power"),
+                list: [],
+			}
+		},
+		methods: {
+            // 消息列表
+            getList() {
+                this.$indicator.open();
+                this.http.post(this.port.my.addressList, {} , 
+                res => {
+                    this.$indicator.close();
+                    if (res.code == "ok") {
+                        this.list = res.data;
+                    } else {
+                        this.$toast({
+                            message: res.msg,
+                            duration: 2000
+                        });
+                    }
+                }, error => {
+                    this.$indicator.close();
+                    this.$toast({
+                        message: error,
+                        duration: 2000
+                    });
+                })
+            },
+
+            showList(id) {
+                if($('#'+ id +' > div > img').attr('class') == "rotate"){
+                    $('#'+ id +' > ul').slideDown();
+                    $('#'+ id +' > ul .mint-cell-right').css("transform","translate3d(100%, 0, 0)")
+                    $('#'+ id +' > div >img').attr("class","rotate1");
+                } else {
+                    $('#'+ id +' > ul').slideUp();
+                    $('#'+ id +' > ul .mint-cell-right').css("transform","translate3d(100%, 0, 0)")
+                    $('#'+ id +' > div > img').attr("class","rotate");
+                }
+            },
+
+            toScore(id,name) {
+                this.$router.push("/myGrade/" + id + "/" + name)
+            },
+
+            jumpBack() {
+                this.$router.go(-1);
+            }
+        },
+        created() {
+            this.getList();
+        },
+		mounted() {
+		}
+	}
+
+</script>
+
+<style scoped>
+    body {
+        background: #EFEFEF;
+    }
+
+    .detail_head {
+        background: #fff;
+        color: #333;
+        height: 0.4rem;
+    }
+
+    .detail_body {
+        margin-top: 0.4rem;
+        padding-bottom: 0.15rem;
+    }
+
+    .tab_head {
+        position: fixed;
+        width: 100%;
+        top: 0.4rem;
+        z-index: 110;
+    }
+
+    .detail {
+        background: #EFEFEF;
+    }
+
+    .detailBox {
+        background: #fff;
+    }
+
+    .recordBox {
+        margin: 0.12rem 0 0 0;
+    }
+
+    .one_recordBox {
+        padding: 0.12rem 0.2rem;
+    }
+
+    .one_recordBox > div > img {
+        width: 0.15rem;
+        margin-right: 0.1rem;
+        vertical-align: middle;
+    }
+
+    .one_recordBox > div > span {
+        display: inline-block;
+        width:60%;
+        overflow: hidden;
+        white-space: nowrap;
+        text-overflow: ellipsis;
+        vertical-align: middle;
+    }
+
+    .rotate {
+        transform-origin: center center;
+        transform: rotate(-90deg);
+        -webkit-transform: rotate(-90deg);
+        -moz-transform: rotate(-90deg);
+        -ms-transform: rotate(-90deg);
+        -o-transform: rotate(-90deg);
+        transition: transform 0.2s;
+        -moz-transition: -moz-transform 0.2s;
+        -moz-transition: -moz-transform 0.2s;
+        -o-transition: -o-transform 0.2s;
+        -ms-transition: -ms-transform 0.2s;
+    }
+
+    .rotate1 {
+        transform-origin: center center;
+        transform: rotate(0deg);
+        -webkit-transform: rotate(0deg);
+        -moz-transform: rotate(0deg);
+        -ms-transform: rotate(0deg);
+        -o-transform: rotate(0deg);
+        transition: transform 0.2s;
+        -moz-transition: -moz-transform 0.2s;
+        -moz-transition: -moz-transform 0.2s;
+        -o-transition: -o-transform 0.2s;
+        -ms-transition: -ms-transform 0.2s;
+    }
+
+    .one_recordBox > ul {
+        padding: 0 0 0 0.2rem;
+    }
+
+    .toScore img {
+        width: 0.1rem;
+    }
+
+    .one_peo {
+        padding: 0.12rem 0;
+    }
+
+    .one_peo_head {
+        float:left;
+        margin-right: 0.15rem;
+    }
+
+    .one_peo_head img {
+        width: 0.35rem;
+        height: 0.35rem;
+        border-radius: 50%;
+    }
+
+    .one_peo_body {
+        display: inline-block;
+        line-height: 0.2rem;
+        color: #999;
+    }
+
+    .one_peo_body > div:nth-child(1) {
+        color: #333;
+    }
+
+    .one_peo_score {
+        float:right;
+        line-height: 0.4rem;
+        color: #5FA1F0;
+    }
+
+    .noList {
+        text-align: center;
+        padding: 1.5rem 0;
+    }
+
+    .noList img {
+        width: 1.2rem;
+        height: 1.2rem;
+    }
+</style>
+<style>
+    .one_peo .mint-cell-value {
+        display: block;
+        width: 100%;
+    }
+
+    .one_peo .mint-cell:last-child {
+        background-image: none;
+    }
+
+    .one_peo .mint-cell-wrapper {
+        background-image: none;
+    }
+</style>

+ 269 - 0
lss_vue/src/views/my/myAssets.vue

@@ -0,0 +1,269 @@
+<template>
+	<div class="detail">
+        <mt-header class="detail_head" fixed title="我的资产">
+            <router-link to="" slot="left">
+                <mt-button icon="back" v-on:click="jumpBack()"></mt-button>
+            </router-link>
+        </mt-header>
+        <div class="detail_body">
+            <div class="noList" v-if="list.length==0">
+                <img src="../../assets/image/noList.png">
+            </div> 
+            <ul v-else class="recordBox">
+                <li v-for="(item,num) in list" class="one_recordBox detailBox">
+                    <div class="record_head">
+                        <img v-if="item.pic != null" v-lazy="item.pic">
+                        <img v-else src="../../assets/image/noPic.png">
+                    </div>
+                    <div class="record_body">
+                        <div>{{item.name}}</div>
+                        <div>{{item.modelNumber}}</div>
+                        <div :id="'tab' + item.id">
+                            <div :class="item.isShow">
+                                {{item.tag}}
+                                <!-- <span v-for="(tag,index) in item.goodsNos">{{tag.modelNo}}<span v-if="index < (item.goodsNos.length -1)">、</span></span> -->
+                            </div>
+                            <div v-if="item.goodsNos.length > 2" class="click-show" v-on:click="changeType('tab' + item.id, num)">{{item.isShow == 'text-hide'?'展开':'收缩'}}</div>
+                        </div>
+                    </div>
+                </li>
+                <div class="order" v-if="haveMore">
+                    <span class="line"></span>
+                    <span class="txt">没有更多了</span>
+                    <span class="line"></span>
+                </div>
+            </ul>
+        </div>
+    </div>
+</template>
+
+<script>
+	export default {
+		data() {
+			return {
+                user: JSON.parse(sessionStorage.getItem("user")),
+                list: [],
+                pageNum: 1,
+                pages: 1,
+                haveMore: false,
+			}
+		},
+		methods: {
+            // 消息列表
+            getList() {
+                this.$indicator.open();
+                this.http.post(this.port.my.list, {
+                    'uid': this.user.id,
+                    'pageNum': this.pageNum
+                } , 
+                res => {
+                    this.$indicator.close();
+                    if (res.code == "ok") {
+                        var list = res.data.list;
+                        for(var i in list) {
+                            var tag = list[i].goodsNos , str = "";
+                            for(var j in tag) {
+                                str += tag[j].modelNo + "、";
+                            }
+                            str = str.substring(0,str.length-1);
+                            list[i].tag = str;
+                            list[i].isShow = 'text-hide';
+                        }
+                        this.list = list;
+                        this.pages = res.data.pages==0?1:res.data.pages;
+                    } else {
+                        this.$toast({
+                            message: res.msg,
+                            duration: 2000
+                        });
+                    }
+                }, error => {
+                    this.$indicator.close();
+                    this.$toast({
+                        message: error,
+                        duration: 2000
+                    });
+                })
+            },
+
+            loadMore() {
+                if(this.pageNum == this.pages) {
+                    this.haveMore = true;
+                } else if(this.pageNum < this.pages) {
+                    this.$indicator.open();
+                    this.http.post(this.port.my.list, {
+                        'uid': this.user.id,
+                        'pageNum': ++this.pageNum
+                    } , 
+                    res => {
+                        this.$indicator.close();
+                        if (res.code == "ok") {
+                            this.pages = res.data.pages==0?1:res.data.pages;
+                            if(res.data.list.length != 0) {
+                                for(var i in res.data.list) {
+                                    this.list.push(res.data.list[i]);
+                                }
+                            }
+                        } else {
+                            this.$toast({
+                                message: res.msg,
+                                duration: 2000
+                            });
+                        }
+                    }, error => {
+                        this.$indicator.close();
+                        this.$toast({
+                            message: error,
+                            duration: 2000
+                        });
+                    })
+                }
+            },
+
+            changeType(id,num) {
+                if(this.list[num].isShow == "text-hide") {
+                    this.list[num].isShow = "text-show";
+                } else {
+                    this.list[num].isShow = "text-hide";
+                }
+            },
+
+            jumpBack() {
+                this.$router.go(-1);
+            }
+        },
+        created() {
+            this.getList();
+        },
+		mounted() {
+            
+		}
+	}
+
+</script>
+
+<style scoped>
+    body {
+        background: #EFEFEF;
+    }
+
+    .detail {
+        background: #EFEFEF;
+    }
+
+    .detail_head {
+        background: #fff;
+        color: #333;
+        height: 0.4rem;
+    }
+
+    .detail_body {
+        margin-top: 0.4rem;
+        padding-bottom: 0.15rem;
+    }
+
+    .tab_head {
+        position: fixed;
+        width: 100%;
+        top: 0.4rem;
+        z-index: 110;
+    }
+
+    .detailBox {
+        background: #fff;
+        margin-bottom: 0.11rem;
+    }
+
+    .recordBox {
+        margin: 0.12rem 0 0 0;
+    }
+
+    .one_recordBox {
+        padding: 0.12rem 0.2rem;
+    }
+
+    .record_head {
+        float: left;
+        color: #5FA1F0;
+        margin-right: 0.12rem;
+    }
+
+    .record_head img {
+        width: 0.6rem;
+        height: 0.6rem;
+    }
+
+    .record_head > div {
+        width: 100%;
+        display: inline-block;
+        vertical-align: middle;
+    }
+
+    .record_head span {
+        color: #939393;
+        float: right;
+        vertical-align: middle;
+    }
+
+    .record_body {
+        color: #777;
+        font-size: 0.12rem;
+        line-height: 0.23rem;
+    }
+
+    .record_body > div:nth-child(1) {
+        font-size: 0.15rem;
+        font-weight: 600;
+        color: #333;
+    }
+
+    .record_body > div:nth-child(3) .text-hide {
+        padding: 0;
+        overflow: hidden;
+        text-overflow: ellipsis;
+        white-space: nowrap;
+    }
+
+    .record_body > div:nth-child(3) .text-show {
+        overflow: auto;
+        text-overflow: unset;
+        white-space: unset;
+        word-break: break-all;
+    }
+
+    .record_body > div:nth-child(3) .click-show{
+        margin-left: 5px;
+        font-size: 14px;
+        color: #26a2ff;
+        text-align: right;
+    }
+
+    .noList {
+        text-align: center;
+        padding: 1.5rem 0;
+    }
+
+    .noList img {
+        width: 1.2rem;
+        height: 1.2rem;
+    }
+
+    .order {
+        height: 0.6rem;
+        line-height: 0.6rem;
+        text-align: center;
+    }
+
+    .order .line {
+        display: inline-block;
+        width: 1.2rem;
+        border-top: 1px solid #ccc ;
+        vertical-align: middle;
+    }
+
+    .order .txt {
+        color: #ccc;
+        font-size: 0.13rem;
+        vertical-align: middle;
+    }
+</style>

+ 847 - 0
lss_vue/src/views/my/myGrade.vue

@@ -0,0 +1,847 @@
+<template>
+	<div class="detail">
+        <mt-header class="detail_head uName" fixed title="">
+            <router-link to="" slot="left">
+                <mt-button icon="back" v-on:click="jumpBack()">{{name}}</mt-button>
+            </router-link> 
+            <mt-button class="timePicker" slot="right" id="dateTime" v-on:click="timePicker()"><span class="dateTime">{{chooseTime}}</span> <img src="../../assets/image/pull_down.png"></mt-button>
+        </mt-header>
+        <div class="detail_body">
+            <div class="detailBox one_recordBox">
+                <div class="record_head">
+                    <div v-on:click="canEdit&&power.indexOf('scoring')>-1?openPop(1):''">个人分:
+                        <img v-if="canEdit && power.indexOf('scoring')>-1" class="rotate" src="../../assets/image/pull_down_blue.png">
+                        <span>{{detail.personalScore==null?'0分':detail.personalScore + '分'}}</span>
+                    </div>
+                    <div>建议分:<span>{{detail.ideaScoreSum==null?'0分':parseFloat(detail.ideaScoreSum) + '分'}}</span></div>
+                </div>
+                <div class="record_body">
+                    <div v-on:click="toNext()">TA的建议 <span class="toDetail"><img class="rotate" src="../../assets/image/pull_down_blue.png"></span></div>
+                </div>
+            </div>
+            <div class="detailBox one_recordBox">
+                <div class="totalScore">总得分:<span>{{(detail.personalScore==null?0:detail.personalScore) + (detail.ideaScoreSum==null?0:detail.ideaScoreSum) + '分'}}</span></div>
+                <div class="totalReason">
+                    <div v-on:click="canEdit&&power.indexOf('scoring')>-1?openPop(2):''">得分原因 <img v-if="canEdit" src="../../assets/image/edit.png"></div>
+                    <div>
+                        {{detail.reason}}
+                    </div>
+                </div>
+            </div>
+        </div>
+
+        <mt-popup v-model="score" position="middle" popup-transition="popup-fade">
+            <div class="mint-popup-div">
+                <h4>个人分</h4>
+                <mt-field label="" class="input" placeholder="请输入个人分" type="number" disableClear v-model="personalScore"></mt-field>
+                <div class="btns">
+                    <mt-button class="btn" size="small" v-on:click.native="submit(1)">确定</mt-button>
+                    <mt-button class="btn" size="small" v-on:click.native="closePop(1)">取消</mt-button>
+                </div>
+            </div>
+        </mt-popup>
+
+        <mt-popup v-model="reasonPop" position="middle" popup-transition="popup-fade">
+            <div class="mint-popup-div">
+                <h4>得分原因</h4>
+                <mt-field label="" class="input" placeholder="请输入得分原因" type="textarea" rows="4" v-model="reason"></mt-field>
+                <div class="btns">
+                    <mt-button class="btn" size="small" v-on:click.native="submit(2)">确定</mt-button>
+                    <mt-button class="btn" size="small" v-on:click.native="closePop(2)">取消</mt-button>
+                </div>
+            </div>
+        </mt-popup>
+
+        <mt-popup v-model="popupVisible" position="right" class="allocation" id="allocation">
+            <mt-header class="detail_head uName" fixed title="TA的建议">
+                <router-link to="" slot="left">
+                    <mt-button icon="back" v-on:click="toPrev()">{{name}}</mt-button>
+                </router-link>
+            </mt-header>
+            <div class="detail_body">
+                <div class="detailBox one_recordBox" v-for="(item,index) in ideaList">
+                    <div>
+                        <div class="one_suggest_title">
+                            {{item.indate}}
+                            <span v-if="item.ideaComment != null" class="areaday">已打分</span>
+                            <span v-if="power.indexOf('scoring')>-1" v-else class="edit" v-on:click="openSugPop(index)">打分</span>
+                        </div>
+                        <div class="one_suggest_body">
+                            {{item.content}}
+                        </div>
+                        <div class="one_suggest_reply" v-if="item.ideaComment != null">
+                            <div class="reply_title">来自领导的回复</div>
+                            <div class="reply_body">
+                                {{item.ideaComment.content}}
+                                <div>{{item.ideaComment.responder}} <span class="score">得分:<span>{{item.score==null?'0分':item.score + '分'}}</span></span></div>
+                                <div>{{item.ideaComment.indate}}
+                                    <div v-if="power.indexOf('scoring')>-1" class="showMoreBtn" v-on:click.stop="showBtnList(item.id)">
+                                        <img src="../../assets/image/loadMore.png">
+                                        <div :id="'btn' + item.id" class="btn_list hide">
+                                            <div v-on:click="openSugPop(index)"><img src="../../assets/image/register.png"><span>编辑</span></div>
+                                            <div v-on:click="deleteScore(index)"><img src="../../assets/image/delete.png"><span>删除</span></div>
+                                        </div>
+                                    </div>
+                                </div>
+                            </div>
+                        </div>
+                    </div>
+                </div>
+            </div>
+        </mt-popup>
+
+        <mt-popup v-model="sugScorePop" position="middle" popup-transition="popup-fade">
+            <div class="mint-popup-div">
+                <h4>打分</h4>
+                <mt-field label="" class="input" placeholder="请输入建议分" type="number" disableClear v-model="sugScore"></mt-field>
+                <mt-field label="" class="input" placeholder="请输入得分原因" type="textarea" rows="4" v-model="sugContent"></mt-field>
+                <div class="btns">
+                    <mt-button class="btn" size="small" v-on:click.native="submit(3)">确定</mt-button>
+                    <mt-button class="btn" size="small" v-on:click.native="closePop(3)">取消</mt-button>
+                </div>
+            </div>
+        </mt-popup>
+    </div>
+</template>
+
+<script>
+    import { MessageBox } from 'mint-ui';
+	export default {
+		data() {
+			return {
+                id: this.$route.params.id,
+                name: this.$route.params.name,
+                user: JSON.parse(sessionStorage.getItem("user")),
+                power: sessionStorage.getItem("power"),
+                detail: '',
+                date: [],
+                chooseTime: '',
+
+                score: false,
+                personalScore: 0,
+                reasonPop: false,
+                reason: '',
+                popupVisible: false,
+                sugScore: 0,
+                sugContent: '',
+                sugScorePop: false,
+                chooseSugNum: 0,
+
+                ideaList: [],
+                
+                canEdit: true,
+			}
+		},
+		methods: {
+            // 消息列表
+            getDetail() {
+                this.$indicator.open();
+                this.http.post(this.port.my.scoreDetail, {
+                    'uid': this.id,
+                    'time': this.chooseTime
+                } , 
+                res => {
+                    this.$indicator.close();
+                    if (res.code == "ok") {
+                        this.detail = res.data;
+                        this.personalScore = (res.data.personalScore==null?0:res.data.personalScore);
+                        this.reason = (res.data.reason==null?'':res.data.reason);
+                    } else {
+                        this.$toast({
+                            message: res.msg,
+                            duration: 2000
+                        });
+                    }
+                }, error => {
+                    this.$indicator.close();
+                    this.$toast({
+                        message: error,
+                        duration: 2000
+                    });
+                })
+            },
+
+            // 时间筛选
+            timePicker() {
+                var _this = this;
+                var dataShippingSpace = this.date;
+                var pickerDiv = document.getElementById("dateTime");
+                var pickerView = new PickerView({
+                    bindElem: pickerDiv, 
+                    data: dataShippingSpace, 
+                    title: "对应人员", 
+                    leftText: "取消", 
+                    rightText: "确定", 
+                    rightFn: function(selectArr) {
+                        _this.chooseTime = selectArr[0].name;
+                        _this.getDetail();
+                        if(_this.chooseTime == _this.date[0].name) {
+                            _this.canEdit = true
+                        } else {
+                            _this.canEdit = false
+                        }
+                    }
+                });
+            },
+
+            jumpBack() {
+                this.$router.go(-1);
+            },
+
+            toNext() {
+                $(".one_suggest_reply .showMoreBtn .btn_list").addClass("hide").slideUp();
+                this.popupVisible = true;
+                this.$indicator.open();
+                this.http.post(this.port.my.ideaScore, {
+                    'uid': this.id,
+                    'time': this.chooseTime
+                } , 
+                res => {
+                    this.$indicator.close();
+                    if (res.code == "ok") {
+                        this.ideaList = res.data;
+                    } else {
+                        this.$toast({
+                            message: res.msg,
+                            duration: 2000
+                        });
+                    }
+                }, error => {
+                    this.$indicator.close();
+                    this.$toast({
+                        message: error,
+                        duration: 2000
+                    });
+                })
+            },
+
+            toPrev() {
+                var from = {};
+                if(this.detail.scoreId != null) {
+                    from = {
+                        "scoreId": this.detail.scoreId,
+                        "total": this.personalScore + (this.detail.ideaScoreSum == null?0:parseFloat(this.detail.ideaScoreSum)),
+                    }
+                } else {
+                    from = {
+                        "uid": this.id,
+                        "total": this.personalScore + (this.detail.ideaScoreSum == null?0:parseFloat(this.detail.ideaScoreSum)),
+                    }
+                }
+                this.http.post(this.port.my.addOrUpdate, from , 
+                res => {
+                    if (res.code == "ok") {
+                        this.popupVisible = false;
+                        this.getDetail();
+                    } else {
+                        this.$toast({
+                            message: res.msg,
+                            duration: 2000
+                        });
+                    }
+                }, error => {
+                    this.popupVisible = false;
+                    this.$toast({
+                        message: error,
+                        duration: 2000
+                    });
+                })
+            },
+
+            getDate() {
+                const dateData = [];
+                const date1 = new Date();
+                for (let i = 0; i < 36; i++) {
+                    let cur = '';
+                    let tempYear = date1.getFullYear();
+                    let tempMonth = date1.getMonth() - i + 1;
+                    if (tempMonth <= 0) {
+                        tempYear = date1.getFullYear() - Math.floor(tempMonth / -12) - 1; 
+                        tempMonth += (Math.floor(tempMonth / -12) + 1) * 12;
+                    }
+                    if (tempMonth < 10) {
+                        cur = tempYear+ '-0' + tempMonth;
+                    } else {
+                        cur = tempYear+ '-' + tempMonth;
+                    }
+                    dateData.push({
+                        name: cur
+                    });
+                    if(i == 0) {
+                        this.chooseTime = cur;
+                    }
+                }
+                this.date = dateData;
+                this.getDetail();
+            },
+
+            openPop(type) {
+                if(type == 1) {
+                    this.personalScore = this.detail.personalScore==null?0:this.detail.personalScore;
+                    this.score = true;
+                } else if(type == 2) {
+                    this.reason = this.detail.reason==null?'':this.detail.reason;
+                    this.reasonPop = true;
+                }
+            },
+
+            submit(type) {
+                if(type == 1) {
+                    var reg = /^([1]?\d{1,2})$/;
+                    if(!reg.test(this.personalScore)) {
+                        this.$toast({
+                            message: '请输入0-100内的整数',
+                            duration: 2000
+                        });
+                        return false;
+                    } else {
+                        var from = {};
+                        if(this.detail.scoreId != null) {
+                            from = {
+                                "scoreId": this.detail.scoreId,
+                                "personalScore": this.personalScore,
+                                "ideaScore": this.detail.ideaScoreSum == null?0:this.detail.ideaScoreSum,
+                                "total": this.personalScore + (this.detail.ideaScoreSum == null?0:parseFloat(this.detail.ideaScoreSum)),
+                            }
+                        } else {
+                            from = {
+                                "uid": this.id,
+                                "personalScore": this.personalScore,
+                                "ideaScore": this.detail.ideaScoreSum == null?0:this.detail.ideaScoreSum,
+                                "scoringYearMonth": this.chooseTime,
+                                "raterId": this.user.id,
+                                "total": this.personalScore + (this.detail.ideaScoreSum == null?0:parseFloat(this.detail.ideaScoreSum)),
+                            }
+                        }
+                        this.$indicator.open();
+                        this.http.post(this.port.my.addOrUpdate, from , 
+                        res => {
+                            this.$indicator.close();
+                            if (res.code == "ok") {
+                                this.$toast({
+                                    message: "打分成功",
+                                    duration: 2000
+                                });
+                                this.getDetail();
+                                this.score = false;
+                            } else {
+                                this.$toast({
+                                    message: res.msg,
+                                    duration: 2000
+                                });
+                            }
+                        }, error => {
+                            this.$indicator.close();
+                            this.score = false;
+                            this.$toast({
+                                message: error,
+                                duration: 2000
+                            });
+                        })
+                    }
+                } else if(type == 2) {
+                    var from = {};
+                    if(this.detail.scoreId != null) {
+                        from = {
+                            "scoreId": this.detail.scoreId,
+                            "reason": this.reason,
+                        }
+                    } else {
+                        from = {
+                            "uid": this.id,
+                            "reason": this.reason,
+                            "scoringYearMonth": this.chooseTime,
+                            "raterId": this.user.id
+                        }
+                    }
+                    this.$indicator.open();
+                    this.http.post(this.port.my.addOrUpdate, from , 
+                    res => {
+                        this.$indicator.close();
+                        if (res.code == "ok") {
+                            this.$toast({
+                                message: "提交成功",
+                                duration: 2000
+                            });
+                            this.getDetail();
+                            this.reasonPop = false;
+                        } else {
+                            this.$toast({
+                                message: res.msg,
+                                duration: 2000
+                            });
+                        }
+                    }, error => {
+                        this.$indicator.close();
+                        this.reasonPop = false;
+                        this.$toast({
+                            message: error,
+                            duration: 2000
+                        });
+                    })
+                } else {
+                    var reg = /^\-?([0-9]|10)(\.\d)?$/;
+                    if(!reg.test(this.sugScore)) {
+                        this.$toast({
+                            message: '分数区间为-10 ~ 10',
+                            duration: 2000
+                        });
+                        return false;
+                    } else {
+                        var from = {};
+                        if(this.ideaComment != null) {
+                            from = {
+                                "ideaId": this.ideaList[this.chooseSugNum].id,
+                                "score": this.sugScore,
+                                "content": this.sugContent,
+                                "responderId": this.user.id,
+                                "scoreId": this.ideaList[this.chooseSugNum].scoreId,
+                                "id": this.ideaList[this.chooseSugNum].ideaComment.id,
+                            }
+                        } else {
+                            from = {
+                                "ideaId": this.ideaList[this.chooseSugNum].id,
+                                "score": this.sugScore,
+                                "content": this.sugContent,
+                                "responderId": this.user.id,
+                                "scoreId": this.ideaList[this.chooseSugNum].scoreId,
+                            }
+                        }
+                        this.$indicator.open();
+                        this.http.post(this.port.my.leaderScore, from , 
+                        res => {
+                            this.$indicator.close();
+                            if (res.code == "ok") {
+                                this.$toast({
+                                    message: "打分成功",
+                                    duration: 2000
+                                });
+                                this.sugScorePop = false;
+                                this.toNext();
+                            } else {
+                                this.$toast({
+                                    message: res.msg,
+                                    duration: 2000
+                                });
+                            }
+                        }, error => {
+                            this.$indicator.close();
+                            this.sugScorePop = false;
+                            this.$toast({
+                                message: error,
+                                duration: 2000
+                            });
+                        })
+                    }
+                }
+            },
+
+            closePop(type) {
+                if(type == 1) {
+                    this.score = false;
+                } else if(type == 2){
+                    this.reasonPop = false;
+                } else {
+                    this.sugScorePop = false;
+                }
+            },
+
+            openSugPop(i) {
+                this.sugScore = this.ideaList[i].score == null? 0 : this.ideaList[i].score;
+                this.sugContent = this.ideaComment == null? '' : this.ideaComment.content;
+                this.sugScorePop = true;
+                this.chooseSugNum = i;
+            },
+
+            showBtnList(id) {
+                if($("#btn" + id).attr("class").indexOf("hide") == -1) {
+                    $("#btn" + id).slideUp().addClass("hide");
+                } else {
+                    $(".one_suggest_reply .showMoreBtn .btn_list").addClass("hide").slideUp();
+                    $("#btn" + id).slideDown().removeClass("hide");
+                }
+            },
+
+            deleteScore(index) {
+                MessageBox.confirm('', { 
+                    message: '是否删除该分数、评论?', 
+                        title: '', 
+                        confirmButtonText: '确定', 
+                        cancelButtonText: '取消' 
+                 }).then(action => { 
+                    if (action == 'confirm') {     //确认的回调
+                        this.http.post(this.port.my.delScore, {
+                            'id': this.ideaList[index].ideaComment.id,
+                        } , 
+                        res => {
+                            if (res.code == "ok") {
+                                this.$toast({
+                                    message: "删除成功",
+                                    duration: 2000
+                                });
+                                this.toNext();
+                            } else {
+                                this.$toast({
+                                    message: res.msg,
+                                    duration: 2000
+                                });
+                            }
+                        }, error => {
+                            this.$toast({
+                                message: error,
+                                duration: 2000
+                            });
+                        })
+                    }
+                 }).catch(err => { 
+                 });
+            },
+
+            globalClick(callback) {
+                document.getElementById('allocation').onclick = function () {
+                    $(".one_suggest_reply .showMoreBtn .btn_list").addClass("hide").slideUp();
+                }
+            }
+        },
+        created() {
+            this.getDate();
+        },
+		mounted() {
+            this.globalClick();
+		}
+	}
+
+</script>
+
+<style scoped>
+    body {
+        background: #EFEFEF!important;
+    }
+
+    .context_router {
+        background: #EFEFEF;
+    }
+    
+    .detail {
+        background: #EFEFEF;
+    }
+
+    .detail_head {
+        background: #fff;
+        color: #333;
+        height: 0.4rem;
+    }
+
+    .detail_body {
+        margin-top: 0.4rem;
+        padding-bottom: 0.15rem;
+    }
+
+    .detailBox {
+        background: #fff;
+        margin-bottom: 0.11rem;
+    }
+
+    .one_recordBox {
+        padding: 0.12rem 0.2rem;
+    }
+
+    .record_head {
+        padding: 0 0 0.1rem 0;
+        line-height: 0.25rem;
+        border-bottom: 1px solid #ccc;
+    }
+
+    .record_head > div {
+        width: 100%;
+        display: inline-block;
+        vertical-align: middle;
+        line-height: 0.4rem;
+    }
+
+    .record_head > div img {
+        width:0.12rem;
+        float:right;
+        margin: 0.135rem 0 0 0;
+    }
+
+    .record_head > div span {
+        color: #5FA1F0;
+        margin-left: 0.2rem;
+        float: right;
+        margin-right: 0.05rem;
+    }
+
+    .record_body {
+        color: #5FA1F0;
+        font-size: 0.14rem;
+        margin: 0.12rem 0 0 0;
+    }
+
+    .record_body .toDetail {
+        float: right;
+        margin-right: 0.05rem;
+    }
+
+    .record_body .toDetail img {
+        width: 0.12rem;
+    }
+
+    .one_suggest {
+        margin-top: 0.2rem;
+    }
+
+    .one_suggest_title {
+        line-height: 0.3rem;
+    }
+
+    .one_suggest_title span {
+        float: right;
+        font-size: 0.13rem;
+    }
+
+    .one_suggest_title span.areaday {
+        color: #ccc;
+    }
+
+    .one_suggest_title span.edit {
+        color:#5FA1F0;
+    }
+
+    .one_suggest_body {
+        font-size: 0.13rem;
+        line-height: 0.2rem;
+        color: #333;
+    }
+
+    .one_suggest_reply {
+        margin-top: 0.12rem;
+    }
+
+    .reply_title {
+        font-size: 0.12rem;
+        color: #999;
+        margin-bottom: 0.08rem;
+    }
+
+    .reply_body {
+        padding: 0.1rem;
+        background: #EEE;
+        color: #333;
+    }
+
+    .reply_body > div {
+        color: #333;
+        line-height: 0.2rem;
+        font-size: 0.13rem;
+        color: #777;
+    }
+
+    .reply_body > div:nth-child(1) {
+        margin-top: 0.1rem;
+    }
+
+    .reply_body .score {
+        float: right;
+    }
+
+    .reply_body .score span {
+        color: #5FA1F0;
+    }
+
+    .suggestList {
+        display: none;
+    }
+
+    .rotate {
+        transform-origin: center center;
+        transform: rotate(-90deg);
+        -webkit-transform: rotate(-90deg);
+        -moz-transform: rotate(-90deg);
+        -ms-transform: rotate(-90deg);
+        -o-transform: rotate(-90deg);
+        transition: transform 0.2s;
+        -moz-transition: -moz-transform 0.2s;
+        -moz-transition: -moz-transform 0.2s;
+        -o-transition: -o-transform 0.2s;
+        -ms-transition: -ms-transform 0.2s;
+    }
+
+    .rotate1 {
+        transform-origin: center center;
+        transform: rotate(0deg);
+        -webkit-transform: rotate(0deg);
+        -moz-transform: rotate(0deg);
+        -ms-transform: rotate(0deg);
+        -o-transform: rotate(0deg);
+        transition: transform 0.2s;
+        -moz-transition: -moz-transform 0.2s;
+        -moz-transition: -moz-transform 0.2s;
+        -o-transition: -o-transform 0.2s;
+        -ms-transition: -ms-transform 0.2s;
+    }
+
+    .totalScore {
+        line-height: 0.3rem;
+    }
+
+    .totalScore span {
+        color: #5FA1F0;
+        margin-left: 0.2rem;
+        float: right;
+        margin-right: 0.08rem;
+    }
+
+    .totalReason div:nth-child(1) {
+        line-height: 0.3rem;
+    }
+
+    .totalReason div:nth-child(2) {
+        line-height: 0.2rem;
+        color: #777;
+    }
+
+    .totalReason img {
+        float: right;
+        width: 0.15rem;
+        margin: 0.08rem 0.08rem 0 0;
+    }
+
+    .mint-popup {
+        width: 70%;
+        box-sizing: content-box;
+    }
+
+    .mint-popup-div {
+        padding: 0.12rem;
+        background: #fff;
+    }
+
+    .mint-popup-div h4 {
+        margin: 0;
+        padding: 0;
+    }
+
+    .mint-popup-div .mint-cell {
+        margin: 0.2rem 0;
+    }
+
+    .mint-popup-div > div.btns {
+        height: 0.3rem;
+    }
+
+    .mint-popup-div .btn {
+        float: right;
+        margin-right: 0.1rem;
+        background: #fff;
+        box-shadow: none;
+        width: 50%;
+        margin: 0;
+    }
+
+    .mint-popup-div .btn:nth-child(1) {
+        color: #f00;
+    }
+
+    .allocation {
+        width: 100%;
+        height: 100%;
+        background: #EFEFEF;
+    }
+
+    .allocation .detail_body {
+        overflow: auto;
+        height: 100%;
+    }
+
+    .showMoreBtn {
+        display: inline-block;
+        float: right;
+        position: relative;
+    }
+
+    .showMoreBtn img {
+        width: 0.23rem;
+    }
+
+    .btn_list {
+        position: absolute;
+        right: -0.04rem;
+        top: 0.30rem;
+        border:#aaa;
+        background: #fcfcfc;
+        box-shadow: 5px 5px 10px #ccc;
+        z-index: 105;
+    }
+
+    .btn_list:before {
+        display: inline-block;
+        width: 0;
+        height: 0;
+        border: solid transparent;
+        border-width: 10px;
+        border-bottom-color: #fcfcfc;
+        content: "";
+        position: absolute;
+        top: -20px;
+        right: 0.06rem;
+    }
+
+    .btn_list > div {
+        width: 0.6rem;
+        font-size: 0.13rem;
+        padding: 0.1rem 0.15rem;
+        border-bottom: 1px solid #efefef;
+        text-align: center;
+    }
+
+    .btn_list > div img {
+        width: 0.14rem;
+        height: 0.14rem;
+        vertical-align: middle;
+        margin-right: 0.05rem;
+    }
+
+    .btn_list > div span {
+        height: 0.15rem;
+        line-height: 0.15rem;
+        vertical-align: middle;
+    }
+
+    .hide {
+        display: none;
+    }
+</style>
+<style>
+     .uName .is-left .mint-button-text {
+        color: #333;
+        font-size: 0.15rem;
+    }
+
+    #dateTime.timePicker .mint-button-text {
+        color: #333;
+        font-size: 0.15rem;
+        font-weight: 600;
+    }
+
+    #dateTime.timePicker .mint-button-text span.dateTime {
+        vertical-align: middle;
+    }
+
+    #dateTime.timePicker .mint-button-text img {
+        width: 0.22rem;
+        vertical-align: middle;
+    }
+
+    .mint-popup-div input {
+        border: 1px solid #ddd;
+        border-radius: 5px;
+        padding: 0.08rem;
+    }
+
+    .input textarea {
+        border: 1px solid #ddd;
+        border-radius: 5px;
+        padding: 0.08rem;
+    }
+</style>

+ 161 - 0
lss_vue/src/views/my/myInsDetail.vue

@@ -0,0 +1,161 @@
+<template>
+	<div class="detail">
+        <mt-header class="detail_head" fixed title="管理制度">
+            <router-link to="" slot="left">
+                <mt-button icon="back" v-on:click="jumpBack()"></mt-button>
+            </router-link>
+        </mt-header>
+        <div class="detail_body">
+            <div class="title">{{detail.title}}</div>
+            <div class="indate">{{detail.indate}}</div>
+            <div class="content">{{detail.content}}</div>
+            <div class="file">本文附件</div>
+            <div class="fileList">
+                <div class="one_file" v-for="item in detail.institutionFiles" v-on:click="downLoadFile(item.url)">
+                    <div>{{item.name}}</div>
+                    <img  src="../../assets/image/downLoad.png">
+                </div>
+            </div>
+        </div>
+    </div>
+</template>
+
+<script>
+	export default {
+		data() {
+			return {
+                id: this.$route.params.id,
+                user: JSON.parse(sessionStorage.getItem("user")),
+                detail: "",
+			}
+		},
+		methods: {
+            // 消息列表
+            getDetail() {
+                this.$indicator.open();
+                this.http.post(this.port.my.insDetail, {
+                    'id': this.id
+                } , 
+                res => {
+                    this.$indicator.close();
+                    if (res.code == "ok") {
+                        this.detail = res.data;
+                    } else {
+                        this.$toast({
+                            message: res.msg,
+                            duration: 2000
+                        });
+                    }
+                }, error => {
+                    this.$indicator.close();
+                    this.$toast({
+                        message: error,
+                        duration: 2000
+                    });
+                })
+            },
+
+            downLoadFile(url) {
+                // var iframe = document.createElement('iframe');
+                // iframe.style.display = 'none';
+                // iframe.src = "javascript: '<script>location.href=\"" + url + "\"<\/script>'";
+                // document.getElementsByTagName('body')[0].appendChild(iframe);
+
+                var form = document.createElement('form');
+                form.action = url;
+                document.getElementsByTagName('body')[0].appendChild(form);
+                form.submit();
+
+                // var dtask = plus.downloader.createDownload(url);
+                // dtask.addEventListener("statechanged", onStateChanged, false);
+                // dtask.start(); 
+            },
+
+            jumpBack() {
+                this.$router.go(-1);
+            }
+        },
+        created() {
+            this.getDetail();
+        },
+		mounted() {
+            
+		}
+	}
+
+</script>
+
+<style scoped>
+    body {
+        background: #fff;
+    }
+    
+    .detail {
+        background: #fff;
+    }
+
+    .detail_head {
+        background: #fff;
+        color: #333;
+        height: 0.4rem;
+    }
+
+    .detail_body {
+        margin-top: 0.4rem;
+        padding: 0.08rem 0.2rem;
+    }
+
+    .detail_body .title {
+        font-weight: 500;
+        font-size: 0.16rem;
+        line-height: 0.25rem;
+    }
+
+    .detail_body .indate {
+        color: #999;
+        margin: 0.12rem 0 0.12rem 0;
+    }
+
+    .detail_body .content {
+        color: #444;
+        line-height: 0.2rem;
+        /* text-indent: 2em; */
+        padding: 0 0 0.3rem 0;
+        border-bottom: 1px solid #ddd;
+    }
+
+    .detail_body .file {
+        margin: 0.12rem 0 0.08rem 0;
+    }
+
+    .detail_body .one_file {
+        padding: 0.12rem 0.04rem;
+    }
+
+    .detail_body .one_file div {
+        display: inline-block;
+        vertical-align: middle;
+        width: 80%;
+        overflow: hidden;
+        white-space: nowrap;
+        text-overflow: ellipsis;
+        font-size: 0.14rem;
+        color: #333;
+    }
+
+    .detail_body .one_file img {
+        width: 0.15rem;
+        float: right;
+        vertical-align: middle;
+    }
+
+    .noList {
+        text-align: center;
+        padding: 1.5rem 0;
+    }
+
+    .noList img {
+        width: 1.2rem;
+        height: 1.2rem;
+    }
+</style>

+ 297 - 0
lss_vue/src/views/my/myInstitution.vue

@@ -0,0 +1,297 @@
+<template>
+	<div class="detail">
+        <mt-header class="detail_head" fixed title="管理制度">
+            <router-link to="" slot="left">
+                <mt-button icon="back" v-on:click="jumpBack()"></mt-button>
+            </router-link>
+        </mt-header>
+        <div class="detail_body">
+            <div class="noList" v-if="list.length==0">
+                <img src="../../assets/image/noList.png">
+            </div>  
+            <ul v-else v-infinite-scroll="loadMore" infinite-scroll-disabled="loading" infinite-scroll-distance="10">
+                <li v-for="(item,index) in list">
+                    <div class="one_manage" v-on:click="toDetail(item.id)">
+                        <div>{{item.title}}</div>
+                        <div><img class="rotate" src="../../assets/image/pull_down.png"></div>
+                    </div>
+                </li>
+                <div class="order" v-if="haveMore">
+                    <span class="line"></span>
+                    <span class="txt">没有更多了</span>
+                    <span class="line"></span>
+                </div>
+            </ul>
+        </div>
+    </div>
+</template>
+
+<script>
+	export default {
+		data() {
+			return {
+                user: JSON.parse(sessionStorage.getItem("user")),
+                list: [],
+                pageNum: 1,
+                pages: 1,
+                haveMore: false,
+			}
+		},
+		methods: {
+            // 消息列表
+            getList() {
+                this.$indicator.open();
+                this.http.post(this.port.my.insList, {
+                    'pageNum': this.pageNum
+                } , 
+                res => {
+                    this.$indicator.close();
+                    if (res.code == "ok") {
+                        var list = res.data.list;
+                        for(var i in list) {
+                            list[i].isShow = 'text-hide';
+                        }
+                        this.list = list;
+                        this.pages = res.data.pages==0?1:res.data.pages;
+                    } else {
+                        this.$toast({
+                            message: res.msg,
+                            duration: 2000
+                        });
+                    }
+                }, error => {
+                    this.$indicator.close();
+                    this.$toast({
+                        message: error,
+                        duration: 2000
+                    });
+                })
+            },
+
+            loadMore() {
+                if(this.pageNum == this.pages) {
+                    this.haveMore = true;
+                } else if(this.pageNum < this.pages) {
+                    this.$indicator.open();
+                    this.http.post(this.port.my.insList, {
+                        'pageNum': ++this.pageNum
+                    } , 
+                    res => {
+                        this.$indicator.close();
+                        if (res.code == "ok") {
+                            this.pages = res.data.pages==0?1:res.data.pages;
+                            if(res.data.list.length != 0) {
+                                for(var i in res.data.list) {
+                                    this.list.push(res.data.list[i]);
+                                }
+                            }
+                        } else {
+                            this.$toast({
+                                message: res.msg,
+                                duration: 2000
+                            });
+                        }
+                    }, error => {
+                        this.$indicator.close();
+                        this.$toast({
+                            message: error,
+                            duration: 2000
+                        });
+                    })
+                }
+            },
+
+            toDetail(id) {
+                this.$router.push("/myInstitution/" + id);
+            },
+
+            jumpBack() {
+                this.$router.go(-1);
+            }
+        },
+        created() {
+            this.getList();
+        },
+		mounted() {
+            
+		}
+	}
+
+</script>
+
+<style scoped>
+    body {
+        background: #EFEFEF;
+    }
+
+    .detail_head {
+        background: #fff;
+        color: #333;
+        height: 0.4rem;
+    }
+
+    .detail_body {
+        margin-top: 0.4rem;
+        padding-bottom: 0.15rem;
+    }
+
+    .tab_head {
+        position: fixed;
+        width: 100%;
+        top: 0.4rem;
+        z-index: 110;
+    }
+
+    .detail {
+        background: #EFEFEF;
+    }
+
+    .detailBox {
+        background: #fff;
+        margin-bottom: 0.11rem;
+    }
+
+    .recordBox {
+        margin: 0.12rem 0 0 0;
+    }
+
+    .one_recordBox {
+        padding: 0.12rem 0.2rem;
+    }
+
+    .record_head {
+        float: left;
+        color: #5FA1F0;
+        margin-right: 0.12rem;
+    }
+
+    .record_head img {
+        width: 0.6rem;
+        height: 0.6rem;
+    }
+
+    .record_head > div {
+        width: 100%;
+        display: inline-block;
+        vertical-align: middle;
+    }
+
+    .record_head span {
+        color: #939393;
+        float: right;
+        vertical-align: middle;
+    }
+
+    .record_body {
+        color: #777;
+        font-size: 0.12rem;
+        line-height: 0.23rem;
+    }
+
+    .record_body > div:nth-child(1) {
+        font-size: 0.15rem;
+        font-weight: 600;
+        color: #333;
+    }
+
+    .record_body > div:nth-child(3) .text-hide {
+        padding: 0;
+        overflow: hidden;
+        text-overflow: ellipsis;
+        white-space: nowrap;
+    }
+
+    .record_body > div:nth-child(3) .text-show {
+        overflow: auto;
+        text-overflow: unset;
+        white-space: unset;
+    }
+
+    .record_body > div:nth-child(3) .click-show{
+        margin-left: 5px;
+        font-size: 14px;
+        color: #26a2ff;
+        text-align: right;
+    }
+
+    .noList {
+        text-align: center;
+        padding: 1.5rem 0;
+    }
+
+    .noList img {
+        width: 1.2rem;
+        height: 1.2rem;
+    }
+
+    .one_manage {
+        padding: 0.12rem;
+        background: #fff;
+        color: #444;
+    }
+
+    .one_manage div {
+        display: inline-block;
+        vertical-align: middle;
+    }
+
+    .one_manage > div:nth-child(1) {
+        width: 89%;
+        overflow: hidden;
+        white-space: nowrap;
+        text-overflow: ellipsis;
+    }
+
+    .one_manage > div:nth-child(2) {
+        float: right;
+        text-align: right;
+    }
+
+    .one_manage > div:nth-child(2) img {
+        width: 0.15rem;
+        vertical-align: middle;
+    }
+
+    .rotate {
+        transform-origin: center center;
+        transform: rotate(-90deg);
+        -webkit-transform: rotate(-90deg);
+        -moz-transform: rotate(-90deg);
+        -ms-transform: rotate(-90deg);
+        -o-transform: rotate(-90deg);
+        transition: transform 0.2s;
+        -moz-transition: -moz-transform 0.2s;
+        -moz-transition: -moz-transform 0.2s;
+        -o-transition: -o-transform 0.2s;
+        -ms-transition: -ms-transform 0.2s;
+    }
+    
+    .noList {
+        text-align: center;
+        padding: 1.5rem 0;
+    }
+
+    .noList img {
+        width: 1.2rem;
+        height: 1.2rem;
+    }
+
+    .order {
+        height: 0.6rem;
+        line-height: 0.6rem;
+        text-align: center;
+    }
+
+    .order .line {
+        display: inline-block;
+        width: 1.2rem;
+        border-top: 1px solid #ccc ;
+        vertical-align: middle;
+    }
+
+    .order .txt {
+        color: #ccc;
+        font-size: 0.13rem;
+        vertical-align: middle;
+    }
+</style>

+ 229 - 0
lss_vue/src/views/my/myMessage.vue

@@ -0,0 +1,229 @@
+<template>
+	<div class="detail">
+        <mt-header class="detail_head" fixed title="我的消息">
+            <router-link to="" slot="left">
+                <mt-button icon="back" v-on:click="jumpBack()"></mt-button>
+            </router-link>
+        </mt-header>
+        <div class="detail_body">
+            <div class="noList" v-if="list.length==0">
+                <img src="../../assets/image/noList.png">
+            </div>  
+            <ul v-else class="recordBox" v-infinite-scroll="loadMore" infinite-scroll-disabled="loading" infinite-scroll-distance="10">
+                <li v-for="item in list" class="one_recordBox detailBox">
+                    <div class="record_head">
+                        <div>{{item.content}}</div>
+                    </div>
+                    <div class="record_body">
+                        <div>时间:{{item.indate}}</div>
+                    </div>
+                </li>
+                <div class="order" v-if="haveMore">
+                    <span class="line"></span>
+                    <span class="txt">没有更多了</span>
+                    <span class="line"></span>
+                </div>
+            </ul>
+        </div>
+    </div>
+</template>
+
+<script>
+	export default {
+		data() {
+			return {
+                user: JSON.parse(sessionStorage.getItem("user")),
+                list: [],
+                pageNum: 1,
+                pages: 1,
+                haveMore: false,
+			}
+		},
+		methods: {
+            // 消息列表
+            getList() {
+                this.$indicator.open();
+                this.http.post(this.port.my.newList, {
+                    'uid': this.user.id,
+                    'pageNum': this.pageNum
+                } , 
+                res => {
+                    this.$indicator.close();
+                    if (res.code == "ok") {
+                        this.list = res.data.list;
+                        this.pages = res.data.pages==0?1:res.data.pages;
+                    } else {
+                        this.$toast({
+                            message: res.msg,
+                            duration: 2000
+                        });
+                    }
+                }, error => {
+                    this.$indicator.close();
+                    this.$toast({
+                        message: error,
+                        duration: 2000
+                    });
+                })
+            },
+
+            loadMore() {
+                if(this.pageNum == this.pages) {
+                    this.haveMore = true;
+                } else if(this.pageNum < this.pages) {
+                    this.$indicator.open();
+                    this.http.post(this.port.my.newList, {
+                        'id': this.id,
+                        'pageNum': ++this.pageNum
+                    } , 
+                    res => {
+                        this.$indicator.close();
+                        if (res.code == "ok") {
+                            this.pages = res.data.pages==0?1:res.data.pages;
+                            if(res.data.list.length != 0) {
+                                for(var i in res.data.list) {
+                                    this.list.push(res.data.list[i]);
+                                }
+                            }
+                        } else {
+                            this.$toast({
+                                message: res.msg,
+                                duration: 2000
+                            });
+                        }
+                    }, error => {
+                        this.$indicator.close();
+                        this.$toast({
+                            message: error,
+                            duration: 2000
+                        });
+                    })
+                }
+            },
+
+            jumpBack() {
+                this.http.post(this.port.my.noReadNum, {
+                    'uid': this.user.id,
+                } , 
+                res => {
+                    if (res.code == "ok") {
+                        sessionStorage.setItem('noRead', res.data==null?0:res.data);
+                         this.$router.go(-1);
+                    } else {
+                        this.$toast({
+                            message: res.msg,
+                            duration: 2000
+                        });
+                    }
+                }, error => {
+                    this.$toast({
+                        message: error,
+                        duration: 2000
+                    });
+                })
+            }
+        },
+        created() {
+            this.getList();
+        },
+		mounted() {
+            
+		}
+	}
+
+</script>
+
+<style scoped>
+    body {
+        background: #EFEFEF;
+    }
+
+    .detail_head {
+        background: #fff;
+        color: #333;
+        height: 0.4rem;
+    }
+
+    .detail_body {
+        margin-top: 0.4rem;
+        padding-bottom: 0.15rem;
+    }
+
+    .tab_head {
+        position: fixed;
+        width: 100%;
+        top: 0.4rem;
+        z-index: 110;
+    }
+
+    .detail {
+        background: #EFEFEF;
+    }
+
+    .detailBox {
+        background: #fff;
+        margin-bottom: 0.11rem;
+    }
+
+    .recordBox {
+        margin: 0.12rem 0 0 0;
+    }
+
+    .one_recordBox {
+        padding: 0.12rem 0.2rem;
+    }
+
+    .record_head {
+        color: #5FA1F0;
+        padding: 0 0 0.1rem 0;
+        border-bottom: 1px solid #ccc;
+    }
+
+    .record_head > div {
+        width: 100%;
+        display: inline-block;
+        vertical-align: middle;
+    }
+
+    .record_head span {
+        color: #939393;
+        float: right;
+        vertical-align: middle;
+    }
+
+    .record_body {
+        color: #777;
+        font-size: 0.12rem;
+        line-height: 0.23rem;
+        margin-top: 0.12rem;
+    }
+
+    .noList {
+        text-align: center;
+        padding: 1.5rem 0;
+    }
+
+    .noList img {
+        width: 1.2rem;
+        height: 1.2rem;
+    }
+
+    .order {
+        height: 0.6rem;
+        line-height: 0.6rem;
+        text-align: center;
+    }
+
+    .order .line {
+        display: inline-block;
+        width: 1.2rem;
+        border-top: 1px solid #ccc ;
+        vertical-align: middle;
+    }
+
+    .order .txt {
+        color: #ccc;
+        font-size: 0.13rem;
+        vertical-align: middle;
+    }
+</style>

+ 213 - 0
lss_vue/src/views/my/myScore.vue

@@ -0,0 +1,213 @@
+<template>
+	<div class="detail">
+        <mt-header class="detail_head" fixed title="我的评分">
+            <router-link to="" slot="left">
+                <mt-button icon="back" v-on:click="jumpBack()"></mt-button>
+            </router-link>
+        </mt-header>
+        <div class="detail_body">
+            <div class="noList" v-if="list.length==0">
+                <img src="../../assets/image/noList.png">
+            </div> 
+            <ul v-else class="recordBox" v-infinite-scroll="loadMore" infinite-scroll-disabled="loading" infinite-scroll-distance="10">
+                <li v-for="item in list" class="one_recordBox detailBox">
+                    <div class="record_head">
+                        <div>{{parseInt(item.scoringYearMonth.split('-')[1])}}月得分:&nbsp;&nbsp;&nbsp;<span>{{item.total}}分</span></div>
+                    </div>
+                    <div class="record_body">
+                        <div>个人分:{{item.personalScore}}分</div>
+                        <div>建议分:{{item.ideaScore}}分</div>
+                        <div>评分人:{{item.rater}}</div>
+                        <div>时间:{{item.scoringYearMonth}} <span class="toDetail" v-on:click="toDetail(item.scoreId)">查看详情 ></span></div>
+                    </div>
+                </li>
+                <div class="order" v-if="haveMore">
+                    <span class="line"></span>
+                    <span class="txt">没有更多了</span>
+                    <span class="line"></span>
+                </div>
+            </ul>
+        </div>
+    </div>
+</template>
+
+<script>
+	export default {
+		data() {
+			return {
+                user: JSON.parse(sessionStorage.getItem("user")),
+                list: [],
+                pageNum: 1,
+                pages: 1,
+                haveMore: false,
+			}
+		},
+		methods: {
+            // 评分列表
+            getList() {
+                this.$indicator.open();
+                this.http.post(this.port.my.scoreList, {
+                    'uid': this.user.id,
+                    'pageNum': this.pageNum
+                } , 
+                res => {
+                    this.$indicator.close();
+                    if (res.code == "ok") {
+                        this.list = res.data.list;
+                        this.pages = res.data.pages==0?1:res.data.pages;
+                    } else {
+                        this.$toast({
+                            message: res.msg,
+                            duration: 2000
+                        });
+                    }
+                }, error => {
+                    this.$indicator.close();
+                    this.$toast({
+                        message: error,
+                        duration: 2000
+                    });
+                })
+            },
+
+            loadMore() {
+                if(this.pageNum == this.pages) {
+                    this.haveMore = true;
+                } else if(this.pageNum < this.pages) {
+                    this.$indicator.open();
+                    this.http.post(this.port.my.scoreList, {
+                        'uid': this.user.id,
+                        'pageNum': ++this.pageNum
+                    } , 
+                    res => {
+                        this.$indicator.close();
+                        if (res.code == "ok") {
+                            this.pages = res.data.pages==0?1:res.data.pages;
+                            if(res.data.list.length != 0) {
+                                for(var i in res.data.list) {
+                                    this.list.push(res.data.list[i]);
+                                }
+                            }
+                        } else {
+                            this.$toast({
+                                message: res.msg,
+                                duration: 2000
+                            });
+                        }
+                    }, error => {
+                        this.$indicator.close();
+                        this.$toast({
+                            message: error,
+                            duration: 2000
+                        });
+                    })
+                }
+            },
+
+            toDetail(id) {
+                this.$router.push("/myScore/" + id)
+            },
+
+            jumpBack() {
+                this.$router.go(-1);
+            }
+        },
+        created() {
+            this.getList();
+        },
+		mounted() {
+            
+		}
+	}
+
+</script>
+
+<style scoped>
+    body {
+        background: #EFEFEF;
+    }
+    
+    .detail {
+        background: #EFEFEF;
+    }
+
+    .detail_head {
+        background: #fff;
+        color: #333;
+        height: 0.4rem;
+    }
+
+    .detail_body {
+        margin-top: 0.4rem;
+        padding-bottom: 0.15rem;
+    }
+
+    .detailBox {
+        background: #fff;
+        margin-bottom: 0.11rem;
+    }
+
+    .recordBox {
+        margin: 0.12rem 0 0 0;
+    }
+
+    .one_recordBox {
+        padding: 0.12rem 0.2rem;
+    }
+
+    .record_head {
+        padding: 0 0 0.1rem 0;
+        border-bottom: 1px solid #ccc;
+    }
+
+    .record_head > div {
+        width: 100%;
+        display: inline-block;
+        vertical-align: middle;
+    }
+
+    .record_head > div span {
+        color: #5FA1F0;
+    }
+
+    .record_body {
+        color: #777;
+        font-size: 0.12rem;
+        line-height: 0.23rem;
+        margin-top: 0.12rem;
+    }
+
+    .record_body .toDetail {
+        float: right;
+        color: #5FA1F0;
+    }
+
+    .noList {
+        text-align: center;
+        padding: 1.5rem 0;
+    }
+
+    .noList img {
+        width: 1.2rem;
+        height: 1.2rem;
+    }
+
+    .order {
+        height: 0.6rem;
+        line-height: 0.6rem;
+        text-align: center;
+    }
+
+    .order .line {
+        display: inline-block;
+        width: 1.2rem;
+        border-top: 1px solid #ccc ;
+        vertical-align: middle;
+    }
+
+    .order .txt {
+        color: #ccc;
+        font-size: 0.13rem;
+        vertical-align: middle;
+    }
+</style>

+ 272 - 0
lss_vue/src/views/my/myScoreDetail.vue

@@ -0,0 +1,272 @@
+<template>
+	<div class="detail">
+        <mt-header class="detail_head" fixed title="评分详情">
+            <router-link to="" slot="left">
+                <mt-button icon="back" v-on:click="jumpBack()"></mt-button>
+            </router-link>
+        </mt-header>
+        <div class="detail_body">
+            <div class="detailBox one_recordBox">
+                <div class="record_head">
+                    <div>个人分:<span>{{detail.personalScore==null?'0分':detail.personalScore + '分'}}</span></div>
+                    <div>建议分:<span>{{detail.ideaScore==null?'0分':detail.ideaScore + '分'}}</span></div>
+                </div>
+                <div class="record_body">
+                    <div v-on:click="showSuggest()">我的建议 <span class="toDetail"><img class="rotate" src="../../assets/image/pull_down_blue.png"></span></div>
+                </div>
+                <div class="suggestList" >
+                    <div class="one_suggest" v-for="item in detail.ideaVO">
+                        <div class="one_suggest_title">
+                            {{item.indate}}
+                        </div>
+                        <div class="one_suggest_body">
+                            {{item.content}}
+                        </div>
+                        <div class="one_suggest_reply" v-if="item.ideaComment != null">
+                            <div class="reply_title">来自领导的回复</div>
+                            <div class="reply_body">
+                                {{item.ideaComment.content}}
+                                <div>{{item.ideaComment.responder}} <span class="score">得分:<span>{{item.score==null?'0分':item.score + '分'}}</span></span></div>
+                                <div>{{item.ideaComment.indate}}</div>
+                            </div>
+                        </div>
+                    </div>
+                </div>
+            </div>
+            <div class="detailBox one_recordBox">
+                <div class="totalScore">总得分:<span>{{detail.total==null?'0分':detail.total + '分'}}</span></div>
+                <div class="totalReason">
+                    <div>得分原因</div>
+                    <div>
+                        {{detail.reason}}
+                    </div>
+                </div>
+            </div>
+        </div>
+    </div>
+</template>
+
+<script>
+	export default {
+		data() {
+			return {
+                id: this.$route.params.id,
+                detail: '',
+			}
+		},
+		methods: {
+            // 消息列表
+            getDetail() {
+                this.$indicator.open();
+                this.http.post(this.port.my.scoreDetail, {
+                    'scoreId': this.id,
+                } , 
+                res => {
+                    this.$indicator.close();
+                    if (res.code == "ok") {
+                        this.detail = res.data;
+                    } else {
+                        this.$toast({
+                            message: res.msg,
+                            duration: 2000
+                        });
+                    }
+                }, error => {
+                    this.$indicator.close();
+                    this.$toast({
+                        message: error,
+                        duration: 2000
+                    });
+                })
+            },
+
+            showSuggest() {
+                if($('.toDetail img').attr("class") == "rotate") {
+                    $('.suggestList').slideDown();
+                    $('.toDetail img').attr("class","rotate1")
+                } else {
+                    $('.suggestList').slideUp();
+                    $('.toDetail img').attr("class","rotate")
+                }
+            },
+
+            jumpBack() {
+                this.$router.go(-1);
+            }
+        },
+        created() {
+            this.getDetail();
+        },
+		mounted() {
+            
+		}
+	}
+
+</script>
+
+<style scoped>
+    body {
+        background: #EFEFEF!important;
+    }
+
+    .context_router {
+        background: #EFEFEF;
+    }
+    
+    .detail {
+        background: #EFEFEF;
+    }
+
+    .detail_head {
+        background: #fff;
+        color: #333;
+        height: 0.4rem;
+    }
+
+    .detail_body {
+        margin-top: 0.4rem;
+        padding-bottom: 0.15rem;
+    }
+
+    .detailBox {
+        background: #fff;
+        margin-bottom: 0.11rem;
+    }
+
+    .one_recordBox {
+        padding: 0.12rem 0.2rem;
+    }
+
+    .record_head {
+        padding: 0 0 0.1rem 0;
+        line-height: 0.25rem;
+        border-bottom: 1px solid #ccc;
+    }
+
+    .record_head > div {
+        width: 100%;
+        display: inline-block;
+        vertical-align: middle;
+    }
+
+    .record_head > div span {
+        color: #5FA1F0;
+        margin-left: 0.2rem;
+        float: right;
+        margin-right: 0.08rem;
+    }
+
+    .record_body {
+        color: #5FA1F0;
+        font-size: 0.14rem;
+        margin: 0.12rem 0 0 0;
+    }
+
+    .record_body .toDetail {
+        float: right;
+        margin-right: 0.05rem;
+    }
+
+    .record_body .toDetail img {
+        width: 0.12rem;
+    }
+
+    .one_suggest {
+        margin-top: 0.2rem;
+    }
+
+    .one_suggest_title {
+        line-height: 0.3rem;
+    }
+
+    .one_suggest_body {
+        font-size: 0.13rem;
+        line-height: 0.2rem;
+        color: #333;
+    }
+
+    .one_suggest_reply {
+        margin-top: 0.12rem;
+    }
+
+    .reply_title {
+        font-size: 0.12rem;
+        color: #999;
+        margin-bottom: 0.08rem;
+    }
+
+    .reply_body {
+        padding: 0.1rem;
+        background: #EEE;
+        color: #333;
+    }
+
+    .reply_body > div {
+        color: #333;
+        line-height: 0.2rem;
+        font-size: 0.13rem;
+        color: #777;
+    }
+
+    .reply_body > div:nth-child(1) {
+        margin-top: 0.1rem;
+    }
+
+    .reply_body .score {
+        float: right;
+    }
+
+    .reply_body .score span {
+        color: #5FA1F0;
+    }
+
+    .suggestList {
+        display: none;
+    }
+
+    .rotate {
+        transform-origin: center center;
+        transform: rotate(-90deg);
+        -webkit-transform: rotate(-90deg);
+        -moz-transform: rotate(-90deg);
+        -ms-transform: rotate(-90deg);
+        -o-transform: rotate(-90deg);
+        transition: transform 0.2s;
+        -moz-transition: -moz-transform 0.2s;
+        -moz-transition: -moz-transform 0.2s;
+        -o-transition: -o-transform 0.2s;
+        -ms-transition: -ms-transform 0.2s;
+    }
+
+    .rotate1 {
+        transform-origin: center center;
+        transform: rotate(0deg);
+        -webkit-transform: rotate(0deg);
+        -moz-transform: rotate(0deg);
+        -ms-transform: rotate(0deg);
+        -o-transform: rotate(0deg);
+        transition: transform 0.2s;
+        -moz-transition: -moz-transform 0.2s;
+        -moz-transition: -moz-transform 0.2s;
+        -o-transition: -o-transform 0.2s;
+        -ms-transition: -ms-transform 0.2s;
+    }
+
+    .totalScore {
+        line-height: 0.3rem;
+    }
+
+    .totalScore span {
+        color: #5FA1F0;
+        margin-left: 0.2rem;
+    }
+
+    .totalReason div:nth-child(1) {
+        line-height: 0.3rem;
+    }
+
+    .totalReason div:nth-child(2) {
+        line-height: 0.2rem;
+        color: #777;
+    }
+</style>

+ 490 - 0
lss_vue/src/views/my/mySuggest.vue

@@ -0,0 +1,490 @@
+<template>
+	<div class="detail">
+        <mt-header class="detail_head" fixed title="我的建议">
+            <router-link to="" slot="left">
+                <mt-button icon="back" v-on:click="jumpBack()"></mt-button>
+            </router-link> 
+            <mt-button class="timePicker" slot="right" v-if="power.indexOf('make_recommendations')>-1" v-on:click="openPop(-1)">发表建议</mt-button>
+        </mt-header>
+        <div class="detail_body">
+            <div class="noList" v-if="list.length==0">
+                <img src="../../assets/image/noList.png">
+            </div> 
+            <ul v-else class="recordBox">
+                <li v-for="(item,index) in list" class="one_recordBox detailBox">
+                    <div>
+                        <div class="one_suggest_title">
+                            {{item.indate}}
+                            <span v-if="item.ideaComment != null" class="areaday">已打分</span>
+                            <span v-if="power.indexOf('make_recommendations')>-1" v-else class="edit" v-on:click="openPop(index)">修改</span>
+                        </div>
+                        <div class="one_suggest_body">
+                            {{item.content}}
+                        </div>
+                        <div class="one_suggest_reply" v-if="item.ideaComment != null">
+                            <div class="reply_title">来自领导的回复</div>
+                            <div class="reply_body">
+                                {{item.ideaComment.content}}
+                                <div>{{item.ideaComment.responder}} <span class="score">得分:<span>{{item.score==null?'0分':item.score + '分'}}</span></span></div>
+                                <div>{{item.ideaComment.indate}}</div>
+                            </div>
+                        </div>
+                    </div>
+                </li>
+                <div class="order" v-if="haveMore">
+                    <span class="line"></span>
+                    <span class="txt">没有更多了</span>
+                    <span class="line"></span>
+                </div>
+            </ul>
+        </div>
+
+        <mt-popup v-model="popupVisible" position="middle" popup-transition="popup-fade" closeOnClickModal>
+            <div class="mint-popup-div">
+                <h4>建议</h4>
+                <mt-field label="" class="input" placeholder="请输入建议" type="textarea" rows="4" v-model="content"></mt-field>
+                <div class="btns">
+                    <mt-button class="btn" size="small" v-on:click.native="submit()">确定</mt-button>
+                    <mt-button class="btn" size="small" v-on:click.native="closePop()">取消</mt-button>
+                </div>
+            </div>
+        </mt-popup>
+    </div>
+</template>
+
+<script>
+	export default {
+		data() {
+			return {
+                user: JSON.parse(sessionStorage.getItem("user")),
+                power: sessionStorage.getItem("power"),
+                list: [],
+                pageNum: 1,
+                pages: 1,
+                haveMore: false,
+
+                popupVisible: false,
+                content: '',
+                chooseI: -1,
+                draftId: 0,
+
+                canEdit: true,
+			}
+		},
+		methods: {
+            // 消息列表
+            getList() {
+                this.$indicator.open();
+                this.http.post(this.port.my.ideaList, {
+                    'uid': this.user.id,
+                    'pageNum': this.pageNum,
+                } , 
+                res => {
+                    this.$indicator.close();
+                    if (res.code == "ok") {
+                        this.list = res.data.list;
+                        this.pages = res.data.pages==0?1:res.data.pages;
+                    } else {
+                        this.$toast({
+                            message: res.msg,
+                            duration: 2000
+                        });
+                    }
+                }, error => {
+                    this.$indicator.close();
+                    this.$toast({
+                        message: error,
+                        duration: 2000
+                    });
+                })
+            },
+
+            loadMore() {
+                if(this.pageNum == this.pages) {
+                    this.haveMore = true;
+                } else if(this.pageNum < this.pages) {
+                    this.$indicator.open();
+                    this.http.post(this.port.my.ideaList, {
+                        'uid': this.user.id,
+                        'pageNum': ++this.pageNum
+                    } , 
+                    res => {
+                        this.$indicator.close();
+                        if (res.code == "ok") {
+                            this.pages = res.data.pages==0?1:res.data.pages;
+                            if(res.data.list.length != 0) {
+                                for(var i in res.data.list) {
+                                    this.list.push(res.data.list[i]);
+                                }
+                            }
+                        } else {
+                            this.$toast({
+                                message: res.msg,
+                                duration: 2000
+                            });
+                        }
+                    }, error => {
+                        this.$indicator.close();
+                        this.$toast({
+                            message: error,
+                            duration: 2000
+                        });
+                    })
+                }
+            },
+
+            jumpBack() {
+                this.$router.go(-1);
+            },
+
+            openPop(i) {
+                this.chooseI = i;
+                this.draftId = 0;
+                if(i == -1) {
+                    this.http.post(this.port.my.draft, {
+                        "uid": this.user.id
+                    } , 
+                    res => {
+                        if (res.code == "ok") {
+                            if(res.data.content == null) {
+                                this.content = '';
+                                this.draftId = 0;
+                            } else {
+                                this.content = res.data.content;
+                                this.draftId = res.data.id;
+                            }
+                            this.popupVisible = true;
+                        } else {
+                            this.$toast({
+                                message: res.msg,
+                                duration: 2000
+                            });
+                        }
+                    }, error => {
+                        this.$indicator.close();
+                        this.popupVisible = false;
+                        this.$toast({
+                            message: error,
+                            duration: 2000
+                        });
+                    })
+                } else {
+                    this.content = this.list[i].content;
+                    this.popupVisible = true;
+                }
+            },
+
+            submit() {
+                var from = {};
+                if(this.chooseI != -1) {
+                    from = {
+                        "id": this.list[this.chooseI].id,
+                        "content": this.content,
+                        "uid": this.user.id,
+                        "isDraft": 0,
+                    }
+                } else {
+                    if(this.draftId != 0) {
+                        from = {
+                            "id": this.draftId,
+                            "content": this.content,
+                            "scoringYearMonth": this.chooseTime,
+                            "uid": this.user.id,
+                            "isDraft": 0,
+                        }
+                    } else {
+                        from = {
+                            "content": this.content,
+                            "scoringYearMonth": this.chooseTime,
+                            "uid": this.user.id,
+                            "isDraft": 0,
+                        }
+                    }
+                }
+                this.$indicator.open();
+                this.http.post(this.port.my.ideaAoU, from , 
+                res => {
+                    this.$indicator.close();
+                    if (res.code == "ok") {
+                        this.$toast({
+                            message: "提交成功",
+                            duration: 2000
+                        });
+                        this.getList();
+                        this.popupVisible = false;
+                    } else {
+                        this.$toast({
+                            message: res.msg,
+                            duration: 2000
+                        });
+                    }
+                }, error => {
+                    this.$indicator.close();
+                    this.popupVisible = false;
+                    this.$toast({
+                        message: error,
+                        duration: 2000
+                    });
+                })
+            },
+
+            closePop() {
+                if(this.content != "" && this.content != null) {
+                    var from = {};
+                    if(this.chooseI == -1) {
+                        from = {
+                            "content": this.content,
+                            "scoringYearMonth": this.chooseTime,
+                            "uid": this.user.id,
+                            "isDraft": 1,
+                        }
+                    }
+                    this.$indicator.open();
+                    this.http.post(this.port.my.ideaAoU, from , 
+                    res => {
+                        this.$indicator.close();
+                        if (res.code == "ok") {
+                            this.$toast({
+                                message: "当前未提交内容已存为草稿",
+                                duration: 2000
+                            });
+                            this.popupVisible = false;
+                        } else {
+                            this.$toast({
+                                message: res.msg,
+                                duration: 2000
+                            });
+                        }
+                    }, error => {
+                        this.$indicator.close();
+                        this.popupVisible = false;
+                        this.$toast({
+                            message: error,
+                            duration: 2000
+                        });
+                    })
+                } else {
+                    this.popupVisible = false;
+                }
+            }
+        },
+        created() {
+            this.getList();
+        },
+		mounted() {
+            
+		}
+	}
+
+</script>
+
+<style scoped>
+    body {
+        background: #EFEFEF!important;
+    }
+
+    .context_router {
+        background: #EFEFEF;
+    }
+    
+    .detail {
+        background: #EFEFEF;
+    }
+
+    .detail_head {
+        background: #fff;
+        color: #333;
+        height: 0.4rem;
+    }
+
+    .detail_body {
+        margin-top: 0.4rem;
+        padding-bottom: 0.15rem;
+        background: #efefef;
+    }
+
+    .detailBox {
+        background: #fff;
+        margin-bottom: 0.1rem;
+    }
+
+    .one_recordBox {
+        padding: 0.12rem 0.2rem;
+    }
+
+    .record_head {
+        padding: 0 0 0.1rem 0;
+        line-height: 0.25rem;
+        border-bottom: 1px solid #ccc;
+    }
+
+    .record_head > div {
+        width: 100%;
+        display: inline-block;
+        vertical-align: middle;
+        line-height: 0.4rem;
+    }
+
+    .record_head > div img {
+        width:0.12rem;
+        float:right;
+        margin: 0.135rem 0 0 0;
+    }
+
+    .record_head > div span {
+        color: #5FA1F0;
+        margin-left: 0.2rem;
+        float: right;
+        margin-right: 0.05rem;
+    }
+
+    .record_body {
+        color: #5FA1F0;
+        font-size: 0.14rem;
+        margin: 0.12rem 0 0 0;
+    }
+
+    .record_body .toDetail {
+        float: right;
+        margin-right: 0.05rem;
+    }
+
+    .record_body .toDetail img {
+        width: 0.12rem;
+    }
+
+    .one_suggest_title {
+        line-height: 0.3rem;
+    }
+
+    .one_suggest_title span {
+        float: right;
+        font-size: 0.13rem;
+    }
+
+    .one_suggest_title span.areaday {
+        color: #ccc;
+    }
+
+    .one_suggest_title span.edit {
+        color:#5FA1F0;
+    }
+
+    .one_suggest_body {
+        font-size: 0.13rem;
+        line-height: 0.2rem;
+        color: #333;
+    }
+
+    .one_suggest_reply {
+        margin-top: 0.12rem;
+    }
+
+    .reply_title {
+        font-size: 0.12rem;
+        color: #999;
+        margin-bottom: 0.08rem;
+    }
+
+    .reply_body {
+        padding: 0.1rem;
+        background: #EEE;
+        color: #333;
+    }
+
+    .reply_body > div {
+        color: #333;
+        line-height: 0.2rem;
+        font-size: 0.13rem;
+        color: #777;
+    }
+
+    .reply_body > div:nth-child(1) {
+        margin-top: 0.1rem;
+    }
+
+    .reply_body .score {
+        float: right;
+    }
+
+    .reply_body .score span {
+        color: #5FA1F0;
+    }
+
+    .mint-popup {
+        width: 70%;
+        box-sizing: content-box;
+    }
+
+    .mint-popup-div {
+        padding: 0.12rem;
+        background: #fff;
+    }
+
+    .mint-popup-div h4 {
+        margin: 0;
+        padding: 0;
+    }
+
+    .mint-popup-div .mint-cell {
+        margin: 0.2rem 0;
+    }
+
+    .mint-popup-div > div.btns {
+        height: 0.3rem;
+    }
+
+    .mint-popup-div .btn {
+        float: right;
+        margin-right: 0.1rem;
+        background: #fff;
+        box-shadow: none;
+        width: 50%;
+        margin: 0;
+    }
+
+    .mint-popup-div .btn:nth-child(1) {
+        color: #f00;
+    }
+
+    .allocation {
+        width: 100%;
+        height: 100%;
+    }
+
+    .noList {
+        text-align: center;
+        padding: 1.5rem 0;
+    }
+
+    .noList img {
+        width: 1.2rem;
+        height: 1.2rem;
+    }
+
+    .order {
+        height: 0.6rem;
+        line-height: 0.6rem;
+        text-align: center;
+    }
+
+    .order .line {
+        display: inline-block;
+        width: 1.2rem;
+        border-top: 1px solid #ccc ;
+        vertical-align: middle;
+    }
+
+    .order .txt {
+        color: #ccc;
+        font-size: 0.13rem;
+        vertical-align: middle;
+    }
+</style>
+<style>
+    .mint-popup-div input {
+        border: 1px solid #ddd;
+        border-radius: 5px;
+        padding: 0.08rem;
+    }
+</style>