whj 11 maanden geleden
bovenliggende
commit
5abab50ce6

+ 1 - 1
src/router/generator-platform-routers.js

@@ -479,7 +479,7 @@ const rootRouter = {
   name: 'index',
   component: 'BasicLayout',
   meta: { title: '首页' },
-  redirect: '/WorkplaceBacklog',
+  redirect: '/workplace',
   type: 1,
   children: []
 }

+ 1 - 1
src/views/Login.vue

@@ -217,7 +217,7 @@ export default {
     },
     loginSuccess(res) {
       // 延迟 1 秒显示欢迎信息
-      this.$router.push({ path: '/WorkplaceBacklog' })
+      this.$router.push({ path: '/workplace' })
       setTimeout(() => {
         this.$notification.success({
           message: '欢迎',

+ 126 - 130
src/views/workplace/backlog/NewWorkplaceBacklog.vue

@@ -10,24 +10,24 @@
             </a-row>
             <a-row type="flex" justify="space-between" :gutter="[0,16]" style="flex:1;font-size:18px;font-weight: 500;">
               <a-col style="width:110px;">
-                <a-badge color="#3066EC "/>
+                <a-badge color="#3066EC " />
                 <span style="color:#3066EC ;"><a style="color:#3066EC ;" target="_block" href="/repair/wait?type=1">待接单 &nbsp; {{ topData.completedRepairNum }}</a></span>
 
               </a-col>
               <a-col style="width:110px;">
-                <a-badge color="#3066EC "/>
+                <a-badge color="#3066EC " />
                 <span style="color:#3066EC ;"><a style="color:#3066EC ;" target="_block" href="/repair/form/mine?type=1">维修中 &nbsp; {{ topData.waitForRepairNum }}</a></span>
               </a-col>
 
             </a-row>
             <a-row type="flex" justify="space-between" :gutter="[0,16]" style="flex:1;font-size:18px;font-weight: 500;">
               <a-col style="width:110px;">
-                <a-badge color="#3066EC "/>
+                <a-badge color="#3066EC " />
                 <span style="color:#3066EC ;"><a style="color:#3066EC ;" target="_block" href="/repair/form?type=1&searchType=3">待审核 &nbsp; {{ topData.verifyRepairNum }}</a></span>
 
               </a-col>
               <a-col style="width:110px;">
-                <a-badge color="#3066EC "/>
+                <a-badge color="#3066EC " />
                 <span style="color:#3066EC ;"><a style="color:#3066EC ;" target="_block" href="/repair/form?type=1&searchType=5">已驳回 &nbsp; {{ topData.refusedRepairNum }}</a></span>
 
               </a-col>
@@ -43,24 +43,24 @@
             </a-row>
             <a-row type="flex" justify="space-between" :gutter="[0,16]" style="flex:1;font-size:18px;font-weight: 500;">
               <a-col style="width:110px;">
-                <a-badge color="#3066EC "/>
+                <a-badge color="#3066EC " />
                 <span style="color:#3066EC ;"><a style="color:#3066EC ;" target="_block" href="/repair/wait?type=2">待接单 &nbsp; {{ topData.outCompletedRepairNum }}</a></span>
 
               </a-col>
               <a-col style="width:110px;">
-                <a-badge color="#3066EC "/>
+                <a-badge color="#3066EC " />
                 <span style="color:#3066EC ;"><a style="color:#3066EC ;" target="_block" href="/repair/form/mine?type=2">待维修 &nbsp; {{ topData.outWaitForRepairNum }}</a></span>
               </a-col>
 
             </a-row>
             <a-row type="flex" justify="space-between" :gutter="[0,16]" style="flex:1;font-size:18px;font-weight: 500;">
               <a-col style="width:110px;">
-                <a-badge color="#3066EC "/>
+                <a-badge color="#3066EC " />
                 <span style="color:#3066EC ;"><a style="color:#3066EC ;" target="_block" href="/repair/form?type=2&searchType=3">待审核 &nbsp; {{ topData.outVerifyRepairNum }}</a></span>
 
               </a-col>
               <a-col style="width:110px;">
-                <a-badge color="#3066EC "/>
+                <a-badge color="#3066EC " />
                 <span style="color:#3066EC ;"><a style="color:#3066EC ;" target="_block" href="/repair/form?type=2&searchType=5">已驳回 &nbsp; {{ topData.outRefusedRepairNum }}</a></span>
               </a-col>
             </a-row>
@@ -105,17 +105,17 @@
         <a-col class="gutter-row" :span="4">
           <div style="height: 471px;display:flex;flex-direction:column;justify-content: space-between">
             <a style="color:#fff;" target="_block" href="/repair/form/mine?type=1">
-              <div class="btn" style="background:linear-gradient(to right,#36B5FA,#3066EC);" >
-                <my-icon type="icon-weixiu" style="font-size:58px;"/>
+              <div class="btn" style="background:linear-gradient(to right,#36B5FA,#3066EC);">
+                <my-icon type="icon-weixiu" style="font-size:58px;" />
                 <span>维修</span>
               </div>
             </a>
             <div class="btn" style="background:linear-gradient(to right,#36B5FA,#3066EC);" @click="$refs.repairForm.base({},{filter: -1})">
-              <my-icon type="icon-baoxiu-xuanzhong-copy" style="font-size:58px;color:#fff;"/>
+              <my-icon type="icon-baoxiu-xuanzhong-copy" style="font-size:58px;color:#fff;" />
               <span>报修</span>
             </div>
             <div class="btn" style="background:linear-gradient(to right,#36B5FA,#3066EC);" @click="$refs.sparePickForm.base()">
-              <my-icon type="icon-tubiaozhizuomoban-copy" style="font-size:58px;color:#fff;"/>
+              <my-icon type="icon-tubiaozhizuomoban-copy" style="font-size:58px;color:#fff;" />
               <span>领用</span>
             </div>
             <div class="btn" style="background:linear-gradient(to right,#36B5FA,#3066EC);" @click="$refs.sparebackform.base()">
@@ -138,15 +138,13 @@
               </div>
               <div>
                 <a href="/operate/article/Article" target="_block"> 查看全部
-                  <my-icon type="icon-xiangyou-copy" style="font-size:13px;"/></a>
+                  <my-icon type="icon-xiangyou-copy" style="font-size:13px;" /></a>
               </div>
             </div>
-            <div
-              class="demo-infinite-container"
-            >
+            <div class="demo-infinite-container">
               <a-list size="small" bordered :data-source="information">
                 <a-list-item slot="renderItem" slot-scope="item,index" :class="{discolor: index%2}">
-                  <a-list-item-meta @click="handleView(item)" >
+                  <a-list-item-meta @click="handleView(item)">
                     <div slot="title" style="cursor:pointer">{{ item.title }}</div>
                   </a-list-item-meta>
                   <div>{{ item.updateTime }}</div>
@@ -164,19 +162,10 @@
               </div>
               <a href="WorkplaceBacklog" target="_block">
                 查看全部
-                <my-icon type="icon-xiangyou-copy" style="font-size:13px;"/>
+                <my-icon type="icon-xiangyou-copy" style="font-size:13px;" />
               </a>
             </div>
-            <s-table
-              ref="table"
-              size="small"
-              bordered
-              rowKey="id"
-              :columns="columns"
-              :data="loadData"
-              :pageSize="10"
-              :scroll="{ y: 400 }"
-            >
+            <s-table ref="table" size="small" bordered rowKey="id" :columns="columns" :data="loadData" :pageSize="10" :scroll="{ y: 400 }">
               <span slot="action" slot-scope="record">
                 <template>
                   <a @click="handle(record)">详情</a>
@@ -205,7 +194,12 @@ import RepairForm from '@/views/repair/application-form/modules/BaseForm.vue'
 import SpareBackForm from '@/views/store/sparebackform/modules/BaseForm'
 import SparePickForm from '@/views/store/sparepickform/modules/BaseForm'
 import { getArticlePage, fetchArticle } from '@/api/operate/article'
-import { getWorkplaceBacklogUserPage, getWorkplaceBacklogTopData, getWorkplaceBacklogWeekData, getWorkplaceBacklogPie } from '@/api/workplace/backlog'
+import {
+  getWorkplaceBacklogUserPage,
+  getWorkplaceBacklogTopData,
+  getWorkplaceBacklogWeekData,
+  getWorkplaceBacklogPie,
+} from '@/api/workplace/backlog'
 import { getCalendarNotice } from '@/api/repair/application-form'
 import { Chart } from '@antv/g2'
 import cookie from 'vue-cookie'
@@ -217,9 +211,9 @@ export default {
     SparePickForm,
     SpareBackForm,
     RepairForm,
-    Chart
+    Chart,
   },
-  data () {
+  data() {
     return {
       equipmentData: [],
       lineData: [],
@@ -232,13 +226,12 @@ export default {
         repairStartTimeStart: '',
         repairStartTimeEnd: '',
         searchStartTime: '',
-        searchEndTime: ''
+        searchEndTime: '',
       },
       queryParam: {
-        status: 1
+        status: 1,
       },
-      information: [
-      ],
+      information: [],
       columns: [
         {
           title: '序号',
@@ -246,8 +239,10 @@ export default {
           align: 'center',
           width: 50,
           customRender: (text, record, index) => {
-            return `${(this.$refs.table.localPagination.current - 1) * this.$refs.table.localPagination.pageSize + index + 1}`
-          }
+            return `${
+              (this.$refs.table.localPagination.current - 1) * this.$refs.table.localPagination.pageSize + index + 1
+            }`
+          },
         },
         {
           title: '类型',
@@ -256,7 +251,7 @@ export default {
           width: 100,
           customRender: (text, record, index) => {
             return this.typeDict[text]
-          }
+          },
         },
         {
           title: '详细类型',
@@ -265,7 +260,7 @@ export default {
           width: 140,
           customRender: (text, record, index) => {
             return this.typeDetailDict[text]
-          }
+          },
         },
         {
           title: '内容',
@@ -273,13 +268,13 @@ export default {
           align: 'center',
           width: 460,
           ellipsis: true,
-          scopedSlots: { customRender: 'content' }
+          scopedSlots: { customRender: 'content' },
         },
         {
           title: '时间',
           align: 'center',
           width: 160,
-          dataIndex: 'createdTime'
+          dataIndex: 'createdTime',
         },
         {
           title: '状态',
@@ -287,32 +282,31 @@ export default {
           dataIndex: 'status',
           width: 100,
           customRender: (text, record, index) => {
-            return (text === 1 ? '未读' : '已读')
-          }
+            return text === 1 ? '未读' : '已读'
+          },
         },
         {
           title: '操作',
           key: 'action',
           width: 150,
           align: 'center',
-          scopedSlots: { customRender: 'action' }
-        }
+          scopedSlots: { customRender: 'action' },
+        },
       ],
       // 加载数据方法 必须为 Promise 对象
-      loadData: parameter => {
+      loadData: (parameter) => {
         parameter = {
           ...parameter,
-          ...this.queryParam
+          ...this.queryParam,
         }
-        return getWorkplaceBacklogUserPage(parameter)
-          .then(res => {
-            return res.data
-          })
-      }
+        return getWorkplaceBacklogUserPage(parameter).then((res) => {
+          return res.data
+        })
+      },
     }
   },
   computed: {
-    role () {
+    role() {
       if (this.$store.state.user.roles.join().includes('workplace-repair-manage')) {
         return 'workplace-repair-manage'
       } else if (this.$store.state.user.roles.join().includes('workplace-repair-normal')) {
@@ -321,18 +315,17 @@ export default {
         return 'undifined'
       }
     },
-    chartOption1 () {
+    chartOption1() {
       return {
         legend: {
           top: '10%',
-          type: 'scroll'
-
+          type: 'scroll',
         },
         grid: {
           left: '3%',
           right: '4%',
           bottom: '3%',
-          containLabel: true
+          containLabel: true,
         },
         series: [
           {
@@ -346,16 +339,16 @@ export default {
               fontSize: 16,
               overflow: 'breakAll',
               labelLine: {
-                length: 3
-              }
+                length: 3,
+              },
             },
 
-            data: this.equipmentData
-          }
-        ]
+            data: this.equipmentData,
+          },
+        ],
       }
     },
-    chartOption2 () {
+    chartOption2() {
       return {
         // tooltip: {
         //   trigger: 'axis',
@@ -368,45 +361,46 @@ export default {
           left: '3%',
           right: '4%',
           bottom: '3%',
-          containLabel: true
+          containLabel: true,
         },
         yAxis: {
-          type: 'value'
+          type: 'value',
         },
         xAxis: {
           type: 'category',
-          data: this.lineData.map(item => item.weekDayName)
+          data: this.lineData.map((item) => item.weekDayName),
         },
         series: [
           {
             name: '维修单数',
             type: 'bar',
-            data: this.lineData.map(item => item.tempTotalNum),
+            data: this.lineData.map((item) => item.tempTotalNum),
             itemStyle: {
               normal: {
                 label: {
                   show: true, // 开启显示
                   position: 'top', // 在上方显示
-                  textStyle: { // 数值样式
+                  textStyle: {
+                    // 数值样式
                     color: 'black',
-                    fontSize: 16
-                  }
-                }
-              }
-            }
-          }
-        ]
+                    fontSize: 16,
+                  },
+                },
+              },
+            },
+          },
+        ],
       }
-    }
+    },
   },
-  created () {
+  created() {
     this.getdate()
     this.getDict()
     this.toCalendar()
     this.getInfo()
   },
   methods: {
-    getdate () {
+    getdate() {
       const date = new Date()
       const year = date.getFullYear()
       const month = date.getMonth()
@@ -414,22 +408,21 @@ export default {
         repairStartTimeStart: `${year}-0${month + 1}-01 00:00:00`,
         repairStartTimeEnd: this.BaseTool.Date.formatter(date, this.BaseTool.Date.PICKER_NORM_DATETIME_PATTERN),
         searchStartTime: `${year}-0${month + 1}-01`,
-        searchEndTime: this.BaseTool.Date.formatter(date, this.BaseTool.Date.PICKER_NORM_DATE_PATTERN)
-
+        searchEndTime: this.BaseTool.Date.formatter(date, this.BaseTool.Date.PICKER_NORM_DATE_PATTERN),
       }
     },
-    getDict () {
+    getDict() {
       this.typeDict = this.DictCache.getLabelByValueMapByType(this.DictCache.TYPE.WORKPLACE_BACKLOG_TYPE)
       this.typeDetailDict = this.DictCache.getLabelByValueMapByType(this.DictCache.TYPE.WORKPLACE_BACKLOG_DETAIL_TYPE)
     },
-    getInfo () {
+    getInfo() {
       if (this.role === 'undifined') {
         // this.$error('您的角色未赋予该权限')
         alert('您的角色未赋予该权限')
-        this.$router.push({ path: '/WorkplaceBacklog' })
+        this.$router.push({ path: '/workplace' })
       }
 
-      getWorkplaceBacklogTopData(this.role).then(res => {
+      getWorkplaceBacklogTopData(this.role).then((res) => {
         this.topData = res.data
       })
       getArticlePage({
@@ -437,73 +430,72 @@ export default {
         pageSize: 10,
         dataScope: {
           sortBy: 'desc',
-          sortName: 'update_time'
-        }
-      }).then(res => {
+          sortName: 'update_time',
+        },
+      }).then((res) => {
         this.information = res.data.rows
       })
-      getWorkplaceBacklogWeekData(this.role).then(res => {
+      getWorkplaceBacklogWeekData(this.role).then((res) => {
         this.lineData = res.data
       })
-      getWorkplaceBacklogPie(this.role).then(res => {
+      getWorkplaceBacklogPie(this.role).then((res) => {
         const data = res.data.reduce((pre, item) => {
           pre.push({
             name: item.typeName,
-            value: item.fee
+            value: item.fee,
           })
           return pre
         }, [])
-        this.$nextTick(() => {
-        })
+        this.$nextTick(() => {})
 
         this.equipmentData = data
       })
     },
-    handleView (record) {
-      fetchArticle({ id: record.id }).then(res => {
+    handleView(record) {
+      fetchArticle({ id: record.id }).then((res) => {
         const modal = this.$refs.detailModal
         modal.base(res.data)
       })
     },
-    toCalendar () {
+    toCalendar() {
       const repairTips = cookie.get('repairTips')
       if (repairTips === '1') {
-        getCalendarNotice().then(res => {
+        getCalendarNotice().then((res) => {
           const router = this.$router
           cookie.set('repairTips', 2, 7)
           if (res.data !== null && res.data.length > 0) {
             this.$confirm({
               title: '提示',
               content: () => {
-                return (<div>
-              近一周工单任务如下: <br />
-                  {
-                    res.data.map(item => {
-                      return <div>{item.calendarDate + ' : ' + item.num }</div>
-                    })
-                  }
-                </div>)
+                return (
+                  <div>
+                    近一周工单任务如下: <br />
+                    {res.data.map((item) => {
+                      return <div>{item.calendarDate + ' : ' + item.num}</div>
+                    })}
+                  </div>
+                )
               },
               okText: '去查看',
               icon: 'info-circle',
-              onOk () {
+              onOk() {
                 return new Promise((resolve, reject) => {
                   router.push({ path: '/repaire/calendar' })
                   resolve()
-                }).catch(err => {
+                }).catch((err) => {
                   this.$message.error({
                     title: '错误',
-                    description: err.message
+                    description: err.message,
                   })
                 })
               },
-              onCancel () {}
+              onCancel() {},
             })
           }
         })
       }
-    }
-  }
+    },
+  },
 }
 </script>
 
@@ -514,45 +506,49 @@ export default {
   font-family: PingFang SC;
 }
 .gutter-box {
-  display:flex;
-  flex-direction:column;
+  display: flex;
+  flex-direction: column;
   justify-content: space-between;
   background: #fff;
   padding: 18px 41px;
   height: 170px;
 }
-.btn{
-height: 113px;
-width: 100%;
-color: #fff!important;
-font-size:28px;
-border-radius: 20px;
-display:flex;
-align-items: center;
-justify-content: space-around;
+.btn {
+  height: 113px;
+  width: 100%;
+  color: #fff !important;
+  font-size: 28px;
+  border-radius: 20px;
+  display: flex;
+  align-items: center;
+  justify-content: space-around;
 }
-.btn:hover{
-  cursor:pointer;
+.btn:hover {
+  cursor: pointer;
 }
-.information{
+.information {
   background: #fff;
   padding: 30px 12px;
   height: 500px;
-  color:#666;
+  color: #666;
 }
-.discolor{
-  background: #EFEFFB;
+.discolor {
+  background: #efeffb;
 }
 .demo-infinite-container {
   overflow: auto;
   height: 400px;
 }
- /deep/ .ant-table-placeholder{
-  height:360px;
+/deep/ .ant-table-placeholder {
+  height: 360px;
   display: flex;
   flex-direction: column;
   align-items: center;
   justify-content: center;
 }
-::-webkit-scrollbar { width: 0; height: 0; color: transparent; }
+::-webkit-scrollbar {
+  width: 0;
+  height: 0;
+  color: transparent;
+}
 </style>

+ 144 - 145
src/views/workplace/backlog/StoreWorkplaceBacklog.vue

@@ -11,11 +11,11 @@
               </a-row>
               <a-row type="flex" justify="space-between" :gutter="[0,16]" style="flex:1;font-size:18px;font-weight: 500;">
                 <a-col style="width:130px;">
-                  <a-badge color="#3066EC "/>
+                  <a-badge color="#3066EC " />
                   <a href="/in/store/myform?type=1&status=1" target="_block"><span style="color:#3066EC ;">采购入库 &nbsp; {{ topData.purchaseApplyNum }}</span></a>
                 </a-col>
                 <a-col style="width:130px;">
-                  <a-badge color="#3066EC "/>
+                  <a-badge color="#3066EC " />
                   <a href="/in/store/myform?type=2&status=1" target="_block">
                     <span style="color:#3066EC ;">闲置入库 &nbsp; {{ topData.spareBackApplyNum }}</span>
                   </a>
@@ -23,14 +23,14 @@
               </a-row>
               <a-row type="flex" justify="space-between" :gutter="[0,16]" style="flex:1;font-size:18px;font-weight: 500;">
                 <a-col style="width:130px;">
-                  <a-badge color="#3066EC "/>
+                  <a-badge color="#3066EC " />
                   <a href="/in/store/myform?type=3&status=1" target="_block">
                     <span style="color:#3066EC ;">调拨入库 &nbsp; {{ topData.applyDBNum }}</span>
 
                   </a>
                 </a-col>
                 <a-col style="width:130px;">
-                  <a-badge color="#3066EC "/>
+                  <a-badge color="#3066EC " />
                   <a href="/in/store/myform?type=6&status=1" target="_block">
 
                     <span style="color:#3066EC ;">其他入库 &nbsp; {{ topData.otherNum }}</span>
@@ -51,13 +51,13 @@
               </a-row>
               <a-row type="flex" justify="space-between" :gutter="[0,16]" style="flex:1;font-size:18px;font-weight: 500;">
                 <a-col style="width:130px;">
-                  <a-badge color="#3066EC "/>
+                  <a-badge color="#3066EC " />
                   <a href="/out/store/myform?type=2&status=1" target="_block">
                     <span style="color:#3066EC ;">调拨出库 &nbsp; {{ topData.outDBNum }}</span>
                   </a>
                 </a-col>
                 <a-col style="width:130px;">
-                  <a-badge color="#3066EC "/>
+                  <a-badge color="#3066EC " />
                   <a href="/out/store/myform?type=1&status=1" target="_block">
                     <span style="color:#3066EC ;">领用出库 &nbsp; {{ topData.lyNum }}</span>
                   </a>
@@ -65,13 +65,13 @@
               </a-row>
               <a-row type="flex" justify="space-between" :gutter="[0,16]" style="flex:1;font-size:18px;font-weight: 500;">
                 <a-col style="width:130px;">
-                  <a-badge color="#3066EC "/>
+                  <a-badge color="#3066EC " />
                   <a href="/out/store/myform?type=3&status=1" target="_block">
                     <span style="color:#3066EC ;">报废出库 &nbsp; {{ topData.bfNum }}</span>
                   </a>
                 </a-col>
                 <a-col style="width:130px;">
-                  <a-badge color="#3066EC "/>
+                  <a-badge color="#3066EC " />
                   <a href="/out/store/myform?type=6&status=1" target="_block">
 
                     <span style="color:#3066EC ;">其他出库 &nbsp; {{ topData.otherOutNum }}</span>
@@ -108,7 +108,7 @@
             <div style="height: 471px;background: #FFFFFF;padding:24px">
               <div style="display:flex;justify-content: space-between;width:160px;height: 18px; font-size:16px;color: #555555; ">
                 <div>备件类型数量统计</div>
-              <!-- <div>设备总数100</div> -->
+                <!-- <div>设备总数100</div> -->
               </div>
               <chart-view height="400px" :chartOption="chartOption1" />
             </div>
@@ -125,19 +125,19 @@
           <a-col class="gutter-row" :span="4">
             <div style="height: 471px;display:flex;flex-direction:column;justify-content: space-between">
               <div class="btn" style="background:linear-gradient(to right,#36B5FA,#3066EC);" @click="handleOutAdd">
-                <my-icon type="icon-chukuguanli" style="font-size:58px;"/>
+                <my-icon type="icon-chukuguanli" style="font-size:58px;" />
                 <span>出库</span>
               </div>
               <div class="btn" style="background:linear-gradient(to right,#36B5FA,#3066EC);" @click="handleInAdd">
-                <my-icon type="icon-rukuguanli" style="font-size:58px;"/>
+                <my-icon type="icon-rukuguanli" style="font-size:58px;" />
                 <span>入库</span>
               </div>
               <div class="btn" style="background:linear-gradient(to right,#36B5FA,#3066EC);">
-                <my-icon type="icon-zichanguanli-zichantiaobo" style="font-size:58px;"/>
+                <my-icon type="icon-zichanguanli-zichantiaobo" style="font-size:58px;" />
                 <span>调拨</span>
               </div>
               <div class="btn" style="background:linear-gradient(to right,#36B5FA,#3066EC);" @click="$refs.addStore.base()">
-                <my-icon type="icon-xinzengyugengxinhuopindangan-copy" style="font-size:58px;"/>
+                <my-icon type="icon-xinzengyugengxinhuopindangan-copy" style="font-size:58px;" />
                 <span>新增</span>
               </div>
             </div>
@@ -153,17 +153,15 @@
                   <div style=" width: 17px;height: 17px;background: #3462FD;border-radius: 50%;"></div>
                   <div style="font-size: 18px;font-weight: 800;color: #333333;">资料</div>
                 </div>
-                <div >
+                <div>
                   <a href="/operate/article/Article" target="_block"> 查看全部
-                    <my-icon type="icon-xiangyou-copy" style="font-size:13px;"/></a>
+                    <my-icon type="icon-xiangyou-copy" style="font-size:13px;" /></a>
                 </div>
               </div>
-              <div
-                class="demo-infinite-container"
-              >
+              <div class="demo-infinite-container">
                 <a-list size="small" bordered :data-source="information">
                   <a-list-item slot="renderItem" slot-scope="item,index" :class="{discolor: index%2}">
-                    <a-list-item-meta @click="handleView(item)" >
+                    <a-list-item-meta @click="handleView(item)">
                       <div slot="title" style="cursor:pointer">{{ item.title }}</div>
                     </a-list-item-meta>
                     <div>{{ item.updateTime }}</div>
@@ -181,19 +179,10 @@
                 </div>
                 <a href="WorkplaceBacklog" target="_block">
                   查看全部
-                  <my-icon type="icon-xiangyou-copy" style="font-size:13px;"/>
+                  <my-icon type="icon-xiangyou-copy" style="font-size:13px;" />
                 </a>
               </div>
-              <s-table
-                ref="table"
-                size="small"
-                bordered
-                rowKey="id"
-                :columns="columns"
-                :data="loadData"
-                :pageSize="10"
-                :scroll="{ y: 400 }"
-              >
+              <s-table ref="table" size="small" bordered rowKey="id" :columns="columns" :data="loadData" :pageSize="10" :scroll="{ y: 400 }">
                 <span slot="action" slot-scope="record">
                   <template>
                     <a @click="handle(record)">详情</a>
@@ -223,7 +212,12 @@ import InBaseFrom from '@/views/store/instoreform/modules/BaseForm.vue'
 import OutBaseFrom from '@/views/store/outstoreform/modules/BaseForm.vue'
 import { getArticlePage, fetchArticle } from '@/api/operate/article'
 import { STable } from '@/components'
-import { getWorkplaceBacklogUserPage, getWorkplaceBacklogTopData, getWorkplaceBacklogWeekData, getWorkplaceBacklogPie } from '@/api/workplace/backlog'
+import {
+  getWorkplaceBacklogUserPage,
+  getWorkplaceBacklogTopData,
+  getWorkplaceBacklogWeekData,
+  getWorkplaceBacklogPie,
+} from '@/api/workplace/backlog'
 import { getCalendarNotice } from '@/api/repair/application-form'
 import { Chart } from '@antv/g2'
 import cookie from 'vue-cookie'
@@ -235,51 +229,50 @@ export default {
     AddStore,
     InBaseFrom,
     OutBaseFrom,
-    Chart
+    Chart,
   },
-  data () {
+  data() {
     return {
       visible: true,
-      equipmentData: [
-      ],
-      lineData: [
-      ],
+      equipmentData: [],
+      lineData: [],
       storeNums: 0,
       allCount: 100,
       chartPie: null,
       chartLine: null,
       topData: null,
       queryParam: {
-        status: 1
+        status: 1,
       },
       information: [
         {
           name: '项目管理通知',
-          time: '2022-4-7'
+          time: '2022-4-7',
         },
         {
           name: '项目管理通知',
-          time: '2022-4-7'
+          time: '2022-4-7',
         },
         {
           name: '项目管理通知',
-          time: '2022-4-7'
+          time: '2022-4-7',
         },
         {
           name: '项目管理通知',
-          time: '2022-4-7'
-        }, {
+          time: '2022-4-7',
+        },
+        {
           name: '项目管理通知',
-          time: '2022-4-7'
+          time: '2022-4-7',
         },
         {
           name: '项目管理通知',
-          time: '2022-4-7'
+          time: '2022-4-7',
         },
         {
           name: '项目管理通知',
-          time: '2022-4-7'
-        }
+          time: '2022-4-7',
+        },
       ],
       columns: [
         {
@@ -288,8 +281,10 @@ export default {
           align: 'center',
           width: 50,
           customRender: (text, record, index) => {
-            return `${(this.$refs.table.localPagination.current - 1) * this.$refs.table.localPagination.pageSize + index + 1}`
-          }
+            return `${
+              (this.$refs.table.localPagination.current - 1) * this.$refs.table.localPagination.pageSize + index + 1
+            }`
+          },
         },
         {
           title: '类型',
@@ -298,7 +293,7 @@ export default {
           width: 100,
           customRender: (text, record, index) => {
             return this.typeDict[text]
-          }
+          },
         },
         {
           title: '详细类型',
@@ -307,7 +302,7 @@ export default {
           width: 140,
           customRender: (text, record, index) => {
             return this.typeDetailDict[text]
-          }
+          },
         },
         {
           title: '内容',
@@ -315,13 +310,13 @@ export default {
           align: 'center',
           width: 460,
           ellipsis: true,
-          scopedSlots: { customRender: 'content' }
+          scopedSlots: { customRender: 'content' },
         },
         {
           title: '时间',
           align: 'center',
           width: 160,
-          dataIndex: 'createdTime'
+          dataIndex: 'createdTime',
         },
         {
           title: '状态',
@@ -329,32 +324,31 @@ export default {
           dataIndex: 'status',
           width: 100,
           customRender: (text, record, index) => {
-            return (text === 1 ? '未读' : '已读')
-          }
+            return text === 1 ? '未读' : '已读'
+          },
         },
         {
           title: '操作',
           key: 'action',
           width: 150,
           align: 'center',
-          scopedSlots: { customRender: 'action' }
-        }
+          scopedSlots: { customRender: 'action' },
+        },
       ],
       // 加载数据方法 必须为 Promise 对象
-      loadData: parameter => {
+      loadData: (parameter) => {
         parameter = {
           ...parameter,
-          ...this.queryParam
+          ...this.queryParam,
         }
-        return getWorkplaceBacklogUserPage(parameter)
-          .then(res => {
-            return res.data
-          })
-      }
+        return getWorkplaceBacklogUserPage(parameter).then((res) => {
+          return res.data
+        })
+      },
     }
   },
   computed: {
-    role () {
+    role() {
       if (this.$store.state.user.roles.join().includes('workplace_store_manage')) {
         return 'workplace_store_manage'
       } else if (this.$store.state.user.roles.join().includes('workplace_store_normal')) {
@@ -363,17 +357,17 @@ export default {
         return 'undifined'
       }
     },
-    chartOption1 () {
+    chartOption1() {
       return {
         legend: {
           type: 'scroll',
-          top: '10%'
+          top: '10%',
         },
         grid: {
           left: '3%',
           right: '4%',
           bottom: '3%',
-          containLabel: true
+          containLabel: true,
         },
         series: [
           {
@@ -387,16 +381,16 @@ export default {
               fontSize: 16,
               overflow: 'breakAll',
               labelLine: {
-                length: 3
-              }
+                length: 3,
+              },
             },
 
-            data: this.equipmentData
-          }
-        ]
+            data: this.equipmentData,
+          },
+        ],
       }
     },
-    chartOption2 () {
+    chartOption2() {
       return {
         // tooltip: {
         //   trigger: 'axis',
@@ -409,91 +403,92 @@ export default {
           left: '3%',
           right: '4%',
           bottom: '3%',
-          containLabel: true
+          containLabel: true,
         },
         yAxis: {
-          type: 'value'
+          type: 'value',
         },
         xAxis: {
           type: 'category',
-          data: this.lineData.inStoreDetailVOS.map(item => item.weekDayName)
+          data: this.lineData.inStoreDetailVOS.map((item) => item.weekDayName),
         },
         series: [
           {
             name: '入库数',
             type: 'bar',
-            data: this.lineData.inStoreDetailVOS.map(item => item.num),
+            data: this.lineData.inStoreDetailVOS.map((item) => item.num),
             itemStyle: {
               normal: {
                 label: {
                   show: true, // 开启显示
                   position: 'top', // 在上方显示
-                  textStyle: { // 数值样式
+                  textStyle: {
+                    // 数值样式
                     color: 'black',
-                    fontSize: 16
-                  }
-                }
-              }
-            }
+                    fontSize: 16,
+                  },
+                },
+              },
+            },
           },
           {
             name: '出库数',
             type: 'bar',
-            data: this.lineData.outStoreDetailVOS.map(item => item.num),
+            data: this.lineData.outStoreDetailVOS.map((item) => item.num),
             itemStyle: {
               normal: {
                 label: {
                   show: true, // 开启显示
                   position: 'top', // 在上方显示
-                  textStyle: { // 数值样式
+                  textStyle: {
+                    // 数值样式
                     color: 'black',
-                    fontSize: 16
-                  }
-                }
-              }
-            }
-          }
-        ]
+                    fontSize: 16,
+                  },
+                },
+              },
+            },
+          },
+        ],
       }
-    }
+    },
   },
-  created () {
+  created() {
     this.getDict()
     this.getInfo()
     this.toCalendar()
   },
-  mounted () {
-  },
+  mounted() {},
   methods: {
-    getDict () {
+    getDict() {
       this.typeDict = this.DictCache.getLabelByValueMapByType(this.DictCache.TYPE.WORKPLACE_BACKLOG_TYPE)
       this.typeDetailDict = this.DictCache.getLabelByValueMapByType(this.DictCache.TYPE.WORKPLACE_BACKLOG_DETAIL_TYPE)
     },
-    getInfo () {
+    getInfo() {
       if (this.role === 'undifined') {
         // this.$error('您的角色未赋予该权限')
         alert('您的角色未赋予该权限')
-        this.$router.push({ path: '/WorkplaceBacklog' })
+        this.$router.push({ path: '/workplace' })
       }
       getArticlePage({
         pageNum: 1,
         pageSize: 10,
         dataScope: {
           sortBy: 'desc',
-          sortName: 'update_time'
-        }
-      }).then(res => {
+          sortName: 'update_time',
+        },
+      }).then((res) => {
         this.information = res.data.rows
       })
       Promise.all([
         getWorkplaceBacklogWeekData(this.role),
         getWorkplaceBacklogPie(this.role),
-        getWorkplaceBacklogTopData(this.role)
-      ]).then(res => {
+        getWorkplaceBacklogTopData(this.role),
+      ]).then((res) => {
         const data2 = res[1].data.reduce((pre, item) => {
           pre.push({
             name: item.name,
-            value: item.currentStock
+            value: item.currentStock,
           })
           return pre
         }, [])
@@ -503,65 +498,65 @@ export default {
         console.log(res[0].data)
       })
     },
-    handleView (record) {
-      fetchArticle({ id: record.id }).then(res => {
+    handleView(record) {
+      fetchArticle({ id: record.id }).then((res) => {
         const modal = this.$refs.detailModal
         modal.base(res.data)
       })
     },
-    handleOk () {
+    handleOk() {
       this.visible = true
       this.getDict()
     },
-    handleInAdd () {
+    handleInAdd() {
       this.visible = false
       const modal = this.$refs.inBaseModal
       modal.base()
     },
-    handleOutAdd () {
+    handleOutAdd() {
       this.visible = false
       const modal = this.$refs.outBaseModal
       modal.base()
     },
-    toCalendar () {
+    toCalendar() {
       const repairTips = cookie.get('repairTips')
       if (repairTips === '1') {
-        getCalendarNotice().then(res => {
+        getCalendarNotice().then((res) => {
           const router = this.$router
           cookie.set('repairTips', 2, 7)
           if (res.data !== null && res.data.length > 0) {
             this.$confirm({
               title: '提示',
               content: () => {
-                return (<div>
-              近一周工单任务如下: <br />
-                  {
-                    res.data.map(item => {
-                      return <div>{item.calendarDate + ' : ' + item.num }</div>
-                    })
-                  }
-                </div>)
+                return (
+                  <div>
+                    近一周工单任务如下: <br />
+                    {res.data.map((item) => {
+                      return <div>{item.calendarDate + ' : ' + item.num}</div>
+                    })}
+                  </div>
+                )
               },
               okText: '去查看',
               icon: 'info-circle',
-              onOk () {
+              onOk() {
                 return new Promise((resolve, reject) => {
                   router.push({ path: '/repaire/calendar' })
                   resolve()
-                }).catch(err => {
+                }).catch((err) => {
                   this.$message.error({
                     title: '错误',
-                    description: err.message
+                    description: err.message,
                   })
                 })
               },
-              onCancel () {}
+              onCancel() {},
             })
           }
         })
       }
-    }
-  }
+    },
+  },
 }
 </script>
 
@@ -572,42 +567,46 @@ export default {
   font-family: PingFang SC;
 }
 .gutter-box {
-  display:flex;
-  flex-direction:column;
+  display: flex;
+  flex-direction: column;
   justify-content: space-between;
   background: #fff;
   padding: 18px 41px;
   height: 170px;
 }
-.btn{
-height: 113px;
-width: 100%;
-color: #fff!important;
-font-size:28px;
-border-radius: 20px;
-display:flex;
-align-items: center;
-justify-content: space-around;
+.btn {
+  height: 113px;
+  width: 100%;
+  color: #fff !important;
+  font-size: 28px;
+  border-radius: 20px;
+  display: flex;
+  align-items: center;
+  justify-content: space-around;
 }
-.information{
+.information {
   background: #fff;
   padding: 30px 12px;
   height: 500px;
-  color:#666;
+  color: #666;
 }
-.discolor{
-  background: #EFEFFB;
+.discolor {
+  background: #efeffb;
 }
 .demo-infinite-container {
   overflow: auto;
   height: 400px;
 }
- /deep/ .ant-table-placeholder{
-  height:360px;
+/deep/ .ant-table-placeholder {
+  height: 360px;
   display: flex;
   flex-direction: column;
   align-items: center;
   justify-content: center;
 }
-::-webkit-scrollbar { width: 0; height: 0; color: transparent; }
+::-webkit-scrollbar {
+  width: 0;
+  height: 0;
+  color: transparent;
+}
 </style>

+ 0 - 2
src/views/workplace/publish/Executed.vue

@@ -72,8 +72,6 @@
         <span slot="action" slot-scope="record">
           <template>
             <a @click="handleView(record)">查看</a>
-            <operation-button @click="handleEdit(record)">修改</operation-button>
-            <operation-button :type="2" title="确认发送" @confirm="handleSend(record.id)">发送</operation-button>
           </template>
         </span>
       </s-table>