浏览代码

Merge branch 'master' of http://47.100.37.243:10080/wutt/lsappBms

5 年之前
父节点
当前提交
80b5eec1a1

二进制
lss_vue/dist.rar


+ 6 - 2
lss_vue/src/views/assets/assets.vue

@@ -76,13 +76,14 @@
                 this.http.post(this.port.assets.list, {
                     'keyName': this.keyWord,
                     'tagId': this.tagId==-1?"":this.tagId,
-                    'pageNum': this.pageNum
+                    'pageNum': 1
                 } , 
                 res => {
                     this.$indicator.close();
                     if (res.code == "ok") {
                         this.list = res.data.list;
                         this.pages = res.data.pages==0?1:res.data.pages;
+                        document.querySelector("#tag"+this.tagId).scrollIntoView(true);
                     } else {
                         this.$toast({
                             message: res.msg,
@@ -138,6 +139,7 @@
                 this.http.post(this.port.label.list, {} , 
                 res => {
                     if (res.code == "ok") {
+                        this.pageNum = 1;
                         this.getList();
                         var array = [{"id":-1 , "name": "全部"}];
                         for(var i in res.data) {
@@ -160,6 +162,7 @@
 
             // 关键词搜索
             searchKeyword() {
+                this.pageNum = 1;
                 this.getList();
             },
 
@@ -191,7 +194,8 @@
             chooseTag(id,type) {
                 $("#"+id).addClass("active").siblings("a").removeClass("active");
                 $("#btn"+id).addClass("active").siblings().removeClass("active");
-                location.href = "#" + id;
+                // location.href = "#" + id;
+                document.querySelector("#tag"+id).scrollIntoView(true);
                 sessionStorage.assetsTab = id;
                 $("._sorting-medical").removeClass("fixed-top");
                 $(".searchkey_btn img").removeClass("rotate")

+ 2 - 2
lss_vue/src/views/assets/assetsOperation.vue

@@ -89,7 +89,7 @@
                 this.$indicator.open();
                 this.http.post(this.port.assets.disposalRecord, {
                     'id': this.id,
-                    'pageNum': this.disPageNum
+                    'pageNum': 1
                 } , 
                 res => {
                     this.$indicator.close();
@@ -150,7 +150,7 @@
                 this.$indicator.open();
                 this.http.post(this.port.assets.maintainRecord, {
                     'id': this.id,
-                    'pageNum': this.maiPageNum
+                    'pageNum': 1
                 } , 
                 res => {
                     this.$indicator.close();

+ 1 - 1
lss_vue/src/views/my/myAssets.vue

@@ -54,7 +54,7 @@
                 this.$indicator.open();
                 this.http.post(this.port.my.list, {
                     'uid': this.user.id,
-                    'pageNum': this.pageNum
+                    'pageNum': 1
                 } , 
                 res => {
                     this.$indicator.close();

+ 1 - 1
lss_vue/src/views/my/myInstitution.vue

@@ -42,7 +42,7 @@
             getList() {
                 this.$indicator.open();
                 this.http.post(this.port.my.insList, {
-                    'pageNum': this.pageNum
+                    'pageNum': 1
                 } , 
                 res => {
                     this.$indicator.close();

+ 1 - 1
lss_vue/src/views/my/myMessage.vue

@@ -45,7 +45,7 @@
                 this.$indicator.open();
                 this.http.post(this.port.my.newList, {
                     'uid': this.user.id,
-                    'pageNum': this.pageNum
+                    'pageNum': 1
                 } , 
                 res => {
                     this.$indicator.close();

+ 1 - 1
lss_vue/src/views/my/myScore.vue

@@ -48,7 +48,7 @@
                 this.$indicator.open();
                 this.http.post(this.port.my.scoreList, {
                     'uid': this.user.id,
-                    'pageNum': this.pageNum
+                    'pageNum': 1
                 } , 
                 res => {
                     this.$indicator.close();

+ 1 - 1
lss_vue/src/views/my/mySuggest.vue

@@ -77,7 +77,7 @@
                 this.$indicator.open();
                 this.http.post(this.port.my.ideaList, {
                     'uid': this.user.id,
-                    'pageNum': this.pageNum,
+                    'pageNum': 1,
                 } , 
                 res => {
                     this.$indicator.close();

+ 6 - 0
lss_vue_wx/src/port.js

@@ -25,6 +25,11 @@ export default {
         addNo: 'goods/goodsNoAdd',                              // 资产编号添加
         delNo: '/goods/delNo',                                  // 删除资产编号
         distribute: '/goods/distribute',                        // 修改资产编号
+        
+        upMold: '/goodsno/update',                              // 上下架设备
+
+        openDoor: '/rackdata/update',                           // 机柜开门
+        rackList: '/goods/rackList',                            // 机架列表
 
         handle: '/goods/handle',                                // 处置资产
 
@@ -41,6 +46,7 @@ export default {
         add: '/task/addOrUpdate',                               // 新增、修改任务
         detail: '/task/detail',                                 // 任务详情
         del: '/task/del',                                       // 删除任务
+        accept: '/task/acceptTask',                             // 接收任务
 
         dynaList: '/taskdynamic/list',                          // 动态列表
         

+ 2 - 0
lss_vue_wx/src/routes.js

@@ -5,6 +5,7 @@ import Home from './views/Home.vue'
 // 资产
 import assets from './views/assets/assets.vue'
 import assetsDetail from './views/assets/assetsDetail.vue'
+import assetsDetailFrame from './views/assets/assetsDetailFrame.vue'
 import assetsRegister from './views/assets/assetsRegister.vue'
 import assetsEdit from './views/assets/assetsEdit.vue'
 import assetsNumber from './views/assets/assetsNumber.vue'
@@ -50,6 +51,7 @@ let routes = [
         children: [
             { path: '/assets', component: assets, name: '资产', meta: {keepAlive: true, parentPath:'/tab_assets'} },
             { path: '/detail/:id', component: assetsDetail, name: '资产详情', meta: {keepAlive: true, parentPath:'/tab_assets'} },
+            { path: '/detailFrame/:id', component: assetsDetailFrame, 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'} },

+ 385 - 13
lss_vue_wx/src/views/assets/assets.vue

@@ -10,12 +10,12 @@
                 <img v-on:click.stop="showList()" class="btn_img" src="../../assets/image/add.png">
                 <div class="btn_list" v-show="popupVisible">
                     <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 v-if="tagId != -2 && tagId != -3" v-on:click="exportExcel()"><img src="../../assets/image/export.png">导出报表</div>
                 </div>
             </div>
             <div class="searchkey">
                 <div class="searchkey_word">
-                    <a v-for="(item,index) in labels" :id="item.id" v-bind:class="{'active':item.id==tagId}" v-on:click="chooseTag(item.id,1)">{{item.name}}</a>
+                    <a v-for="(item,index) in labels" :id="'tag' + item.id" v-bind:class="{'active':item.id==tagId}" v-on:click="chooseTag(item.id,1)">{{item.name}}</a>
                 </div>
                 <div class="searchkey_btn">
                     <img v-on:click="showFilter()" src="../../assets/image/pull_down.png">
@@ -28,11 +28,11 @@
             </ul>
         </section>
         <div class="body">
-            <div class="noList" v-if="list.length==0">
+            <!-- <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 in list" v-on:click="jumpTo(item.id)">
+            </div> v-else  -->
+            <ul v-infinite-scroll="loadMore" infinite-scroll-disabled="loading" infinite-scroll-distance="10" :class="tagId==-2||tagId==-3?'isFrame':''">
+                <li v-if="tagId != -2 && tagId != -3" v-for="item in list" v-on:click="jumpTo(item.id)">
                     <div class="item_img">
                         <img v-if="item.pic != null" v-lazy="item.pic">
                         <img v-else src="../../assets/image/noPic.png">
@@ -41,6 +41,57 @@
                     <div class="text item_int">{{item.modelNumber}}</div>
                     <div class="text item_num">{{item.goodsNos.length}}{{item.unit}}</div>
                 </li>
+                <li v-if="tagId == -2" v-for="item in list" class="one_frame" v-on:click="jumpToFrame(item.id)">
+                    <div class="frame_title">
+                        <span>{{item.name}}</span>
+                        <span>
+                            <mt-button v-if="item.doorStatus==0" size="small" type="primary" v-on:click.native.stop="openDoor(item.id)">开门</mt-button>
+                            <span v-else style="color:red">已开门</span>
+                        </span>
+                    </div>
+                    <div class="frame_number">{{item.modelNumber}}</div>
+                    <div class="frame_label">
+                        <span><span>机架ID:</span>{{item.rackId}}</span>
+                        <span><span>温度:</span>{{item.temp}}</span>
+                        <span><span>湿度:</span>{{item.hum}}</span>
+                    </div>
+                    <div class="frame_detail"> 查看详情 > </div>
+                </li>
+                <li v-if="tagId == -3" v-for="item in list" class="one_device">
+                    <mt-cell-swipe :id="'dev' + item.id" v-if="item.goodsId == null" title="" 
+                        :right="[{ content: '上架', style: { background: '#2680EB', color: '#fff' }, handler: () => chooseDevice(item.id) }]">
+                        <div style="width: 100%;">
+                            <div class="new_title">
+                                <span>{{item.deviceName}}</span>
+                                <span>{{item.modelNo}}</span>
+                                <span>{{item.currentState==0?'禁止':'运行'}}</span>
+                            </div>
+                            <div class="new_label">
+                                <span><span>标签ID:</span>{{item.labelId}}</span>
+                                <span><span>模块ID:</span>{{item.modelId}}</span>
+                                <span><span>U位号:</span>{{item.ubitNum}}</span>
+                                <!-- <span><span>机架ID:</span>{{item.rackId}}</span> -->
+                            </div>
+                        </div>
+                    </mt-cell-swipe>
+                    <mt-cell-swipe :id="'dev' + item.id" v-else title=""
+                        :right="[{ content: '下架', style: { background: 'red', color: '#fff' }, handler: () => handle(item.id) }]">
+                        <div style="width: 100%;">
+                            <div class="new_title">
+                                <span>{{item.deviceName}}</span>
+                                <span>{{item.modelNo}}</span>
+                                <span>{{item.currentState==0?'禁止':'运行'}}</span>
+                            </div>
+                            <div class="new_label">
+                                <span><span>标签ID:</span>{{item.labelId}}</span>
+                                <span><span>模块ID:</span>{{item.modelId}}</span>
+                                <span><span>U位号:</span>{{item.ubitNum}}</span>
+                                <span><span>机架ID:</span>{{item.rackId}}</span>
+                            </div>
+                        </div>
+                    </mt-cell-swipe>
+                </li>
+                
                 <div class="order" v-if="haveMore">
                     <span class="line"></span>
                     <span class="txt">没有更多了</span>
@@ -53,7 +104,7 @@
 
 <script>
     import util from '../../common/js/util'
-    
+    import { MessageBox } from 'mint-ui';
 	export default {
 		data() {
 			return {
@@ -73,16 +124,23 @@
             // 资产列表
             getList() {
                 this.$indicator.open();
+                var tagId = this.tagId==-1?"":this.tagId;
+                if(tagId == -2) {
+                    tagId = -1
+                } else if(tagId == -3) {
+                    tagId = -2
+                }
                 this.http.post(this.port.assets.list, {
                     'keyName': this.keyWord,
-                    'tagId': this.tagId==-1?"":this.tagId,
-                    'pageNum': this.pageNum
+                    'tagId': tagId,
+                    'pageNum': 1
                 } , 
                 res => {
                     this.$indicator.close();
                     if (res.code == "ok") {
                         this.list = res.data.list;
                         this.pages = res.data.pages==0?1:res.data.pages;
+                        document.querySelector("#tag"+this.tagId).scrollIntoView(true);
                     } else {
                         this.$toast({
                             message: res.msg,
@@ -103,9 +161,15 @@
                     this.haveMore = true;
                 } else if(this.pageNum < this.pages) {
                     this.$indicator.open();
+                    var tagId = this.tagId==-1?"":this.tagId;
+                    if(tagId == -2) {
+                        tagId = -1
+                    } else if(tagId == -3) {
+                        tagId = -2
+                    }
                     this.http.post(this.port.assets.list, {
                         'keyName': this.keyWord,
-                        'tagId': this.tagId==-1?"":this.tagId,
+                        'tagId': tagId,
                         'pageNum': ++this.pageNum 
                     } , 
                     res => {
@@ -139,7 +203,7 @@
                 res => {
                     if (res.code == "ok") {
                         this.getList();
-                        var array = [{"id":-1 , "name": "全部"}];
+                        var array = [{"id":-1 , "name": "全部"},{"id":-2,"name":"机架"},{"id":-3,"name":"机架设备"}];
                         for(var i in res.data) {
                             array.push(res.data[i]);
                         }
@@ -191,7 +255,8 @@
             chooseTag(id,type) {
                 $("#"+id).addClass("active").siblings("a").removeClass("active");
                 $("#btn"+id).addClass("active").siblings().removeClass("active");
-                location.href = "#" + id;
+                // location.href = "#" + id;
+                document.querySelector("#tag"+id).scrollIntoView(true);
                 sessionStorage.assetsTab = id;
                 $("._sorting-medical").removeClass("fixed-top");
                 $(".searchkey_btn img").removeClass("rotate")
@@ -199,20 +264,176 @@
                 $(this).removeClass("current");
                 $("._sorting-address").removeClass("fixed-top");
                 $('._navbar').attr('style','position: fixed;top:0;');
-                this.pageNum = 1;
                 this.pages = 1;
                 this.tagId = id;
                 this.getList();
             },
 
+            // 开关门
+            openDoor(id) {
+                MessageBox.confirm('', { 
+                    message: '是否打开机柜?', 
+                    title: '', 
+                    confirmButtonText: '确定', 
+                    cancelButtonText: '取消' 
+                 }).then(action => { 
+                    if (action == 'confirm') {     //确认的回调
+                        this.http.post(this.port.assets.openDoor, {
+                            'goodsId': id,
+                            'doorStatus': 1
+                        } , 
+                        res => {
+                            if (res.code == "ok") {
+                                this.$toast({
+                                    message: "开门成功",
+                                    duration: 2000
+                                });
+                                this.pageNum = 1;
+                                this.getLabels();
+                            } else {
+                                this.$toast({
+                                    message: res.msg,
+                                    duration: 2000
+                                });
+                            }
+                        }, error => {
+                            this.$toast({
+                                message: error,
+                                duration: 2000
+                            });
+                        })
+                    }
+                 }).catch(err => { 
+                 });
+            },
+
+            // 上架
+            chooseDevice(id) {
+                var _this = this;
+                this.http.post(this.port.assets.rackList, {
+                    'tagId': -1
+                } , 
+                res => {
+                    if (res.code == "ok") {
+                        var list = res.data;
+                        var data = [];
+                        for(var i in list) {
+                            data.push({
+                                'id': list[i].id,
+                                'name': list[i].name
+                            })
+                        }
+                        var pickerDiv = document.getElementById("dev"+id);
+                        var pickerView = new PickerView({
+                            bindElem: pickerDiv, 
+                            data: data, 
+                            title: "机架列表", 
+                            leftText: "取消", 
+                            rightText: "确定", 
+                            rightFn: function(selectArr) {
+                                _this.setDevice(id,selectArr[0].id,selectArr[0].name);
+                            }
+                        });
+                    } else {
+                        this.$toast({
+                            message: res.msg,
+                            duration: 2000
+                        });
+                    }
+                }, error => {
+                    this.$toast({
+                        message: error,
+                        duration: 2000
+                    });
+                })
+            },
+
+            setDevice(id,goodsId,name) {
+                MessageBox.confirm('', { 
+                    message: '是否上架至 "'+ name +'" 设备?', 
+                    title: '', 
+                    confirmButtonText: '确定', 
+                    cancelButtonText: '取消' 
+                 }).then(action => { 
+                    if (action == 'confirm') {     //确认的回调
+                        this.http.post(this.port.assets.upMold, {
+                            'id': id,
+                            'goodsId': goodsId
+                        } , 
+                        res => {
+                            if (res.code == "ok") {
+                                this.$toast({
+                                    message: "上架成功",
+                                    duration: 2000
+                                });
+                                this.getList();
+                            } else {
+                                this.$toast({
+                                    message: res.msg,
+                                    duration: 2000
+                                });
+                            }
+                        }, error => {
+                            this.$toast({
+                                message: error,
+                                duration: 2000
+                            });
+                        })
+                    }
+                }).catch(err => { 
+                });
+            },
+
+            // 下架设备
+            handle(id) {
+                MessageBox.confirm('', { 
+                    message: '是否下架该设备?', 
+                    title: '', 
+                    confirmButtonText: '确定', 
+                    cancelButtonText: '取消' 
+                 }).then(action => { 
+                    if (action == 'confirm') {     //确认的回调
+                        this.http.post(this.port.assets.upMold, {
+                            'id': id
+                        } , 
+                        res => {
+                            if (res.code == "ok") {
+                                this.$toast({
+                                    message: "下架成功",
+                                    duration: 2000
+                                });
+                                this.getList();
+                            } else {
+                                this.$toast({
+                                    message: res.msg,
+                                    duration: 2000
+                                });
+                            }
+                        }, error => {
+                            this.$toast({
+                                message: error,
+                                duration: 2000
+                            });
+                        })
+                    }
+                 }).catch(err => { 
+                 });
+            },
+
+            // 路由跳转
             jumpTo(id) {
                 this.$router.push("/detail/" + id);
             },
+
+            jumpToFrame(id) {
+                this.$router.push("/detailFrame/" + id);
+            },
             
             register() {
                 this.$router.push("/assetsRegister");
             },
 
+            // 导出
             exportExcel() {
                 this.$indicator.open();
                 this.http.downloadFile(this.port.assets.listExcel, {
@@ -584,5 +805,156 @@
         font-size: 0.13rem;
         vertical-align: middle;
     }
+
+    .body > ul.isFrame {
+        padding: 0;
+    }
+
+    .body > ul.isFrame > li {
+        border-radius: 0;
+        margin: 0;
+        width: 100%;
+        padding: 0;
+        display: block;
+        margin-bottom: 0.08rem;
+    }
+
+    .new_title {
+        width: 100%;
+    }
+
+    .new_label {
+        width: 100%;
+    }
+
+    .new_title > span {
+        padding: 0.12rem 0;
+        display: inline-block;
+        vertical-align: bottom;
+    }
+
+    .new_title > span:nth-child(1) {
+        max-width: 40%;
+        overflow: hidden;
+        white-space: nowrap;
+        text-overflow: ellipsis;
+        color: #333;
+        font-size: 0.15rem;
+    }
+
+    .new_title > span:nth-child(2) {
+        max-width: 40%;
+        overflow: hidden;
+        white-space: nowrap;
+        text-overflow: ellipsis;
+    }
+
+    .new_title > span:nth-child(3) {
+        float: right;
+        color: #2680EB;
+    }
+
+    .new_label > span {
+        display: inline-block;
+        padding: 0 0 0.05rem 0;
+        width: 49%;
+        overflow: hidden;
+        white-space: nowrap;
+        text-overflow: ellipsis;
+    }
+
+    .new_label > span > span {
+        color: #555;
+        font-size: 0.13rem;
+    }
+
+    .body > ul.isFrame > li.one_frame {
+        padding: 0 0.08rem;
+        box-sizing:border-box;
+    }
+
+    .frame_title > span {
+        padding: 0.12rem 0 0 0;
+        display: inline-block;
+        vertical-align: bottom;
+    }
+
+    .frame_title > span:nth-child(1) {
+        display: inline-block;
+        width: 70%;
+        overflow: hidden;
+        white-space: nowrap;
+        text-overflow: ellipsis;
+        color: #333;
+        font-size: 0.15rem;
+    }
+
+    .frame_title > span:nth-child(2) {
+        float: right;
+        color: #2680EB;
+        padding: 0.1rem 0 0 0;
+    }
+
+    .frame_number {
+        padding: 0.05rem 0;
+        color: #999;
+    }
+
+    .frame_label {
+        padding: 0 0 0.05rem 0;
+    }
+
+    .frame_label > span {
+        display: inline-block;
+        overflow: hidden;
+        white-space: nowrap;
+        text-overflow: ellipsis;
+        color: #888;
+    }
+
+    .frame_label > span:nth-child(1) {
+        width: 40%;
+        float: left;
+    }
+
+    .frame_label > span:nth-child(2) {
+        width: 30%;
+        float: left;
+        text-align: right;
+    }
+
+    .frame_label > span:nth-child(3) {
+        width: 30%;
+        text-align: right;
+    }
+    
+    .frame_label > span > span {
+        color: #555;
+        font-size: 0.13rem;
+    }
+
+    .frame_detail {
+        text-align: right;
+        padding: 0 0.01rem 0.05rem;
+        color: #2680EB;
+        font-size: 0.13rem;
+    }
     /* 列表页 END */
+</style>
+<style>
+    .isFrame .mint-cell-swipe-button {
+        line-height: 0.87rem;
+    }
+
+    .frame_title > span:nth-child(2) .mint-button--small {
+        height: 0.25rem;
+    }
+
+    .one_device .mint-cell-title {
+        display: none;
+    }
+
+    .one_device .mint-cell-value {
+        width: 100%;
+    }
 </style>

+ 0 - 6
lss_vue_wx/src/views/assets/assetsDetail.vue

@@ -424,7 +424,6 @@
     }
 
     .one_assDel {
-        /* padding: 0 0.1rem; */
         margin: 0 0 0.15rem 0;
     }
 
@@ -455,16 +454,11 @@
         text-overflow: ellipsis;
     }
 
-    .one_assDel_head > span:nth-child(1).canJump {
-        /* color: #26a2ff; */
-    }
-
     .one_assDel_head > span:nth-child(2){
         float: right;
     }
 
     .one_assDel_body span {
-        /* display:inline-block; */
         color: #aaa;
         vertical-align: middle;
     }

+ 553 - 0
lss_vue_wx/src/views/assets/assetsDetailFrame.vue

@@ -0,0 +1,553 @@
+<template>
+	<div class="detail">
+        <mt-header class="detail_head" fixed title="资产详情">
+            <router-link to="/assets" slot="left">
+                <mt-button icon="back"></mt-button>
+            </router-link>
+        </mt-header>
+        <div class="detail_body">
+            <div class="detailBox userInfo">
+                <div class="frame_title">
+                    <span>{{detail.name}}</span>
+                    <span>
+                        <mt-button v-if="detail.doorStatus==0" size="small" type="primary" v-on:click.native.stop="openDoor(1)">开门</mt-button>
+                        <span v-else style="color:red">已开门</span>
+                    </span>
+                </div>
+                <div class="frame_number">{{detail.modelNumber}}</div>
+                <div class="frame_label">
+                    <span><span>机架ID:</span>{{detail.rackIp}}</span>
+                    <span><span>温度:</span>{{detail.temp}}</span>
+                    <span><span>湿度:</span>{{detail.hum}}</span>
+                </div>
+            </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_List">
+                    <div class="one_assDel isFrame" v-for="item in delList">
+                        <mt-cell-swipe title="" :right="[
+                            { content: '下架', style: { background: 'red', color: '#fff' }, handler: () => handle(item.id) },
+                        ]">
+                            <div>
+                                <div class="new_title">
+                                    <span>{{item.deviceName}}</span>
+                                    <span>{{item.modelNo}}</span>
+                                    <span>{{item.currentState==0?'禁止':'运行'}}</span>
+                                </div>
+                                <div class="new_label">
+                                    <span><span>标签ID:</span>{{item.labelId}}</span>
+                                    <span><span>模块ID:</span>{{item.modelId}}</span>
+                                    <span><span>U位号:</span>{{item.ubitNum}}</span>
+                                </div>
+                            </div>
+                        </mt-cell-swipe>
+                    </div>
+                </div>
+            </div>
+        </div>
+    </div>
+</template>
+
+<script>
+    import { MessageBox } from 'mint-ui';
+	export default {
+		data() {
+			return {
+                id: this.$route.params.id,
+                power: sessionStorage.getItem("power"),
+                detail: "",
+                delList: [],
+			}
+		},
+		methods: {
+            getDetail() {
+                this.$indicator.open();
+                this.http.post(this.port.assets.detail, {
+                    'id': this.id
+                } , 
+                res => {
+                    this.$indicator.close();
+                    if (res.code == "ok") {
+                        this.detail = res.data;
+                        this.delList = res.data.goodsNosVO;
+                    } else {
+                        this.$toast({
+                            message: res.msg,
+                            duration: 2000
+                        });
+                    }
+                }, error => {
+                    this.$indicator.close();
+                    this.$toast({
+                        message: error,
+                        duration: 2000
+                    });
+                })
+            },
+
+            // 添加资产编号
+            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.push("/assets");
+            },
+
+            // 开门
+            openDoor() {
+                MessageBox.confirm('', { 
+                    message: '是否打开机柜?', 
+                    title: '', 
+                    confirmButtonText: '确定', 
+                    cancelButtonText: '取消' 
+                 }).then(action => { 
+                    if (action == 'confirm') {     //确认的回调
+                        this.http.post(this.port.assets.openDoor, {
+                            'goodsId': this.id,
+                            'doorStatus': 1
+                        } , 
+                        res => {
+                            if (res.code == "ok") {
+                                this.$toast({
+                                    message: "开门成功",
+                                    duration: 2000
+                                });
+                                this.getDetail();
+                            } else {
+                                this.$toast({
+                                    message: res.msg,
+                                    duration: 2000
+                                });
+                            }
+                        }, error => {
+                            this.$toast({
+                                message: error,
+                                duration: 2000
+                            });
+                        })
+                    }
+                 }).catch(err => { 
+                 });
+            },
+
+            // 下架设备
+            handle(id) {
+                MessageBox.confirm('', { 
+                    message: '是否下架该设备?', 
+                    title: '', 
+                    confirmButtonText: '确定', 
+                    cancelButtonText: '取消' 
+                 }).then(action => { 
+                    if (action == 'confirm') {     //确认的回调
+                        this.http.post(this.port.assets.upMold, {
+                            'id': id
+                        } , 
+                        res => {
+                            if (res.code == "ok") {
+                                this.$toast({
+                                    message: "下架成功",
+                                    duration: 2000
+                                });
+                                this.getDetail();
+                            } else {
+                                this.$toast({
+                                    message: res.msg,
+                                    duration: 2000
+                                });
+                            }
+                        }, error => {
+                            this.$toast({
+                                message: error,
+                                duration: 2000
+                            });
+                        })
+                    }
+                 }).catch(err => { 
+                 });
+            }
+        },
+        created() {
+            this.getDetail();
+        },
+		mounted() {
+            
+		}
+	}
+
+</script>
+
+<style scoped>
+    .detail_head {
+        background: #fff;
+        color: #333;
+        height: 0.4rem;
+    }
+
+    .detail_body {
+        margin-top: 0.4rem;
+    }
+
+    .detail {
+        background: #EFEFEF;
+    }
+
+    .detailBox {
+        background: #fff;
+        margin-bottom: 0.11rem;
+    }
+
+    .userInfo {
+        padding: 0 0.1rem 0.12rem;
+    }
+
+    .frame_title > span {
+        padding: 0.12rem 0 0 0;
+        display: inline-block;
+        vertical-align: bottom;
+    }
+
+    .frame_title > span:nth-child(1) {
+        display: inline-block;
+        width: 70%;
+        overflow: hidden;
+        white-space: nowrap;
+        text-overflow: ellipsis;
+        color: #333;
+        font-size: 0.15rem;
+    }
+
+    .frame_title > span:nth-child(2) {
+        float: right;
+        color: #2680EB;
+        padding: 0.1rem 0 0 0;
+    }
+
+    .frame_number {
+        padding: 0.05rem 0;
+        color: #999;
+    }
+
+    .frame_label {
+        padding: 0 0 0.05rem 0;
+    }
+
+    .frame_label > span {
+        display: inline-block;
+        overflow: hidden;
+        white-space: nowrap;
+        text-overflow: ellipsis;
+        color: #888;
+    }
+
+    .frame_label > span:nth-child(1) {
+        width: 40%;
+        float: left;
+    }
+
+    .frame_label > span:nth-child(2) {
+        width: 30%;
+        float: left;
+        text-align: right;
+    }
+
+    .frame_label > span:nth-child(3) {
+        width: 30%;
+        text-align: right;
+    }
+    
+    .frame_label > span > span {
+        color: #555;
+        font-size: 0.13rem;
+    }
+
+    .frame_detail {
+        text-align: right;
+        padding: 0 0.01rem 0.05rem;
+        color: #2680EB;
+        font-size: 0.13rem;
+    }
+
+    .assDel {
+        padding: 0.12rem 0.1rem;
+    }
+
+    .assDel_List {
+        padding-top: 0; 
+    }
+
+    .assDel_Status span {
+        display: inline-block;
+        text-align: center;
+        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; */
+        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 {
+        display:inline-block;
+        vertical-align: middle;
+        color: #666;
+        line-height: 0.4rem;
+    }
+
+    .one_assDel_head > span:nth-child(1){
+        width: 85%;
+        font-size: 0.15rem;
+        overflow: hidden;
+        white-space: nowrap;
+        text-overflow: ellipsis;
+    }
+
+    .one_assDel_head > span:nth-child(2){
+        float: right;
+    }
+
+    .one_assDel_body span {
+        /* display:inline-block; */
+        color: #aaa;
+        vertical-align: middle;
+    }
+
+    .one_assDel_body img {
+        float: right;
+        width: 0.25rem;
+        height: 0.25rem;
+        vertical-align: middle;
+    }
+
+    
+    .new_title {
+        width: 100%;
+    }
+
+    .new_label {
+        width: 100%;
+    }
+
+    .new_title > span {
+        padding: 0.12rem 0;
+        display: inline-block;
+        vertical-align: bottom;
+    }
+
+    .new_title > span:nth-child(1) {
+        max-width: 40%;
+        overflow: hidden;
+        white-space: nowrap;
+        text-overflow: ellipsis;
+        color: #333;
+        font-size: 0.15rem;
+    }
+
+    .new_title > span:nth-child(2) {
+        max-width: 40%;
+        overflow: hidden;
+        white-space: nowrap;
+        text-overflow: ellipsis;
+    }
+
+    .new_title > span:nth-child(3) {
+        float: right;
+        color: #2680EB;
+    }
+
+    .new_label > span {
+        display: inline-block;
+        padding: 0 0 0.05rem 0;
+        width: 49%;
+        overflow: hidden;
+        white-space: nowrap;
+        text-overflow: ellipsis;
+    }
+
+    .new_label > span > span {
+        color: #555;
+        font-size: 0.13rem;
+    }
+
+</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;
+    }
+
+    .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;
+    }
+
+    .isFrame .mint-cell-swipe-button {
+        line-height: 0.83rem;
+    }
+</style>

+ 2 - 2
lss_vue_wx/src/views/assets/assetsOperation.vue

@@ -89,7 +89,7 @@
                 this.$indicator.open();
                 this.http.post(this.port.assets.disposalRecord, {
                     'id': this.id,
-                    'pageNum': this.disPageNum
+                    'pageNum': 1
                 } , 
                 res => {
                     this.$indicator.close();
@@ -150,7 +150,7 @@
                 this.$indicator.open();
                 this.http.post(this.port.assets.maintainRecord, {
                     'id': this.id,
-                    'pageNum': this.maiPageNum
+                    'pageNum': 1
                 } , 
                 res => {
                     this.$indicator.close();

+ 1 - 1
lss_vue_wx/src/views/my/myAssets.vue

@@ -54,7 +54,7 @@
                 this.$indicator.open();
                 this.http.post(this.port.my.list, {
                     'uid': this.user.id,
-                    'pageNum': this.pageNum
+                    'pageNum': 1
                 } , 
                 res => {
                     this.$indicator.close();

+ 1 - 1
lss_vue_wx/src/views/my/myInstitution.vue

@@ -42,7 +42,7 @@
             getList() {
                 this.$indicator.open();
                 this.http.post(this.port.my.insList, {
-                    'pageNum': this.pageNum
+                    'pageNum': 1
                 } , 
                 res => {
                     this.$indicator.close();

+ 1 - 1
lss_vue_wx/src/views/my/myMessage.vue

@@ -45,7 +45,7 @@
                 this.$indicator.open();
                 this.http.post(this.port.my.newList, {
                     'uid': this.user.id,
-                    'pageNum': this.pageNum
+                    'pageNum': 1
                 } , 
                 res => {
                     this.$indicator.close();

+ 1 - 1
lss_vue_wx/src/views/my/myScore.vue

@@ -48,7 +48,7 @@
                 this.$indicator.open();
                 this.http.post(this.port.my.scoreList, {
                     'uid': this.user.id,
-                    'pageNum': this.pageNum
+                    'pageNum': 1
                 } , 
                 res => {
                     this.$indicator.close();

+ 1 - 1
lss_vue_wx/src/views/my/mySuggest.vue

@@ -77,7 +77,7 @@
                 this.$indicator.open();
                 this.http.post(this.port.my.ideaList, {
                     'uid': this.user.id,
-                    'pageNum': this.pageNum,
+                    'pageNum': 1,
                 } , 
                 res => {
                     this.$indicator.close();

+ 15 - 5
lss_vue_wx/src/views/task/task.vue

@@ -36,9 +36,9 @@
             </ul>
             <div class="filter_title">任务日期</div>
             <div class="filter_body task_date">
-                <mt-field label="" placeholder="开始日期" type="date" v-model="start"></mt-field> 
+                <mt-field label="" placeholder="开始日期" type="date" v-model="form.start"></mt-field> 
                 <div class="text">至</div>
-                <mt-field label="" placeholder="结束日期" type="date" v-model="end"></mt-field>
+                <mt-field label="" placeholder="结束日期" type="date" v-model="form.end"></mt-field>
             </div>
             <div class="filter_foot">
                 <mt-button type="default" class="clearFilter" v-on:click.native='clearFilter'>清空</mt-button>
@@ -70,9 +70,13 @@
                     <div class="text item_users">
                         <div class="userInfo">
                             <img src="../../assets/image/userHead.jpg">
-                            <span>{{item.publisherName}}&nbsp;&nbsp;&nbsp; {{item.planTime}}</span>
+                            <span>{{item.publisherName}}&nbsp;&nbsp;{{item.indate}}</span>
                         </div>
                         <div class="allUsers">
+                            <a>
+                                <img v-if="item.recipientHedaPic==null" src="../../assets/image/userHead.jpg">
+                                <img v-else :src="item.recipientHedaPic">
+                            </a>
                             <a v-for="(head,num) in item.participantsVOS">
                                 <img v-if="head.headPic==null" src="../../assets/image/userHead.jpg">
                                 <img v-else :src="head.headPic">
@@ -132,7 +136,7 @@
                 sessionStorage.taskTab = this.selected;
                 this.http.post(this.port.task.list, {
                     'keyName': this.keyWord,
-                    'pageNum': this.pageNum,
+                    'pageNum': 1,
                     'uid': this.user.id,
                     'tagId': this.form.type==-1?"":this.form.type,
                     'state': this.form.status==-1?"":this.form.status,
@@ -525,6 +529,7 @@
     .body > ul li .item_int {
         color: #B5B5B5;
         font-size: 0.12rem;
+        line-height: 0.13rem;
     }
 
     .body > ul li .item_users img {
@@ -594,6 +599,11 @@
     /* 列表页 END */
 </style>
 <style>
+    .tab_head .mint-tab-item-label {
+        font-size: 0.13rem;
+        color: #999;
+    }
+
     .taskHead .tab_head .mint-tab-item {
         padding: 0.08rem 0;
     }
@@ -605,7 +615,7 @@
     .taskHead .tab_head .mint-tab-item.is-selected .mint-tab-item-label {
         color: #333;
         font-size: 0.16rem;
-        font-weight: 600;
+        font-weight: 700;
     }
 
     .task_date .mint-field input {

+ 17 - 7
lss_vue_wx/src/views/task/taskDetail.vue

@@ -4,7 +4,7 @@
             <router-link to="" slot="left">
                 <mt-button icon="back" v-on:click.native='jumpBack()'></mt-button>
             </router-link>
-            <mt-button slot="right" icon="more" v-if="detail.publishId == user.id" v-on:click.native="showList()"></mt-button>
+            <mt-button slot="right" icon="more" v-if="detail.state != 5 && detail.state != 7 && detail.publishId == user.id" v-on:click.native="showList()"></mt-button>
         </mt-header>
         <div class="btn_list" v-show="popupVisible">
             <div v-on:click="show(1)">延期</div>
@@ -153,7 +153,7 @@
         </mt-popup>
 
         <mt-popup v-model="scorePop" position="middle" popup-transition="popup-fade">
-            <div class="mint-popup-div">
+            <div class="mint-popup-div accep">
                 <h4>审核</h4>
                 <mt-radio class="scoreIsPass" title="" v-model="scoreIsPass" :options="['通过', '不通过']"></mt-radio>
                 <div v-if="scoreIsPass=='通过'" style="height:0.25rem;text-align:left;margin:0.12rem 0 0 0;padding: 0.1rem">
@@ -302,6 +302,7 @@
                                     duration: 2000
                                 });
                                 this.getDetail();
+                                this.getDynaList();
                             } else {
                                 this.$toast({
                                     message: res.msg,
@@ -450,9 +451,9 @@
 
             // 接收任务
             receive() {
-                this.http.post(this.port.task.add, {
+                this.http.post(this.port.task.accept, {
                     'id': this.id,
-                    'state': 2
+                    'recipientId': this.user.id
                 } , 
                 res => {
                     if (res.code == "ok") {
@@ -461,6 +462,7 @@
                             duration: 2000
                         });
                         this.getDetail();
+                        this.getDynaList();
                     } else {
                         this.$toast({
                             message: res.msg,
@@ -491,7 +493,7 @@
                 this.$indicator.open();
                 this.http.post(this.port.task.dynaList, {
                     'id': this.id,
-                    'pageNum': this.dynaPageNum,
+                    'pageNum': 1,
                 } , 
                 res => {
                     this.$indicator.close();
@@ -552,7 +554,7 @@
                 this.$indicator.open();
                 this.http.post(this.port.task.examList, {
                     'taskId': this.detail.id,
-                    'pageNum': this.examPageNum,
+                    'pageNum': 1,
                 } , 
                 res => {
                     this.$indicator.close();
@@ -657,7 +659,7 @@
                 this.$indicator.open();
                 this.http.post(this.port.task.fileList, {
                     'taskId': this.detail.id,
-                    'pageNum': this.filePageNum,
+                    'pageNum': 1,
                 } , 
                 res => {
                     this.$indicator.close();
@@ -947,6 +949,9 @@
     .isPass {
         float: right;
         color: #2680eb;
+        width: 0.5rem;
+        height: 0.3rem;
+        text-align: right;
     }
 
     .isPassN {
@@ -1140,6 +1145,11 @@
     .task_tab_head .mint-tab-item.is-selected .mint-tab-item-label {
         font-size: 0.14rem;
         color: #333;
+        font-weight: 700;
+    }
+
+    .mint-cell:last-child {
+        background-image: none; 
     }
 
     .scoreIsPass .mint-cell {

+ 1 - 1
lss_vue_wx/src/views/task/taskEdit.vue

@@ -13,7 +13,7 @@
                 <mt-field label="工作量" placeholder="请输入工作量" type="number" v-model="taskForm.workLoad">天</mt-field>
                 <mt-field label="接收人" id="recUser" placeholder="请选择接收人" v-on:click.native="chooseRec()" disableClear disabled v-model="taskForm.recipientName"></mt-field>
                 <mt-field label="参与人" id="parUser" placeholder="请选择参与人" v-on:click.native="choosePar()" disableClear disabled v-model="taskForm.participantsNames"></mt-field>
-                <mt-field label="任务内容" placeholder="请输入任务内容" type="textarea" rows="4" v-model="taskForm.content"></mt-field>
+                <mt-field label="任务内容" placeholder="请输入任务内容" type="textarea" rows="4" v-model="taskForm.content" class="taskContent"></mt-field>
             </div>
             <div class="detailBox">
                 <mt-field label="付款方" placeholder="请输入付款方" v-model="taskForm.payer"></mt-field>

+ 22 - 1
lss_vue_wx/src/views/task/taskRegister.vue

@@ -13,7 +13,7 @@
                 <mt-field label="工作量" placeholder="请输入工作量" type="number" v-model="taskForm.workLoad">天</mt-field>
                 <mt-field label="接收人" id="recUser" placeholder="请选择接收人" v-on:click.native="chooseRec()" disableClear disabled v-model="taskForm.recipientName"></mt-field>
                 <mt-field label="参与人" id="parUser" placeholder="请选择参与人" v-on:click.native="choosePar()" disableClear disabled v-model="taskForm.participantsNames"></mt-field>
-                <mt-field label="任务内容" placeholder="请输入任务内容" type="textarea" rows="4" v-model="taskForm.content"></mt-field>
+                <mt-field label="任务内容" placeholder="请输入任务内容" type="textarea" rows="4" v-model="taskForm.content" class="taskContent"></mt-field>
             </div>
             <div class="detailBox">
                 <mt-field label="付款方" placeholder="请输入付款方" v-model="taskForm.payer"></mt-field>
@@ -521,6 +521,14 @@
     }
 </style>
 <style>
+    body {
+        background: #efefef;
+    }
+
+    .mint-cell-value input {
+        background: #fff;
+    }
+
     .detail_head .mint-header-title {
         font-weight: 600;
         font-size: 0.15rem;
@@ -545,4 +553,17 @@
     .mint-cell-wrapper {
         background-image: none;
     }
+
+    .taskContent .mint-cell-wrapper {
+        position: relative;
+    }
+
+    .taskContent .mint-cell-title {
+        position: absolute;
+        top: 0;
+    }
+
+    .taskContent .mint-cell-value {
+        margin-left: 105px;
+    }
 </style>

+ 1 - 1
pcbms/src/main/java/com/hssx/pcbms/controller/GoodsController.java

@@ -360,7 +360,7 @@ public class GoodsController {
     @ResponseBody
     public HttpRespMsg getRackList(Goods goods) {
         HttpRespMsg msg = new HttpRespMsg();
-        msg.data = goodsService.list(new QueryWrapper<Goods>().eq("good_type",1).eq("tags_id",-1).select("id","name","rack_id").orderByDesc("indate"));
+        msg.data = goodsService.list(new QueryWrapper<Goods>().eq("good_type",1).eq("tag_id",-1).select("id","name","rack_id").orderByDesc("indate"));
         return msg;
     }