sunyize 2 سال پیش
والد
کامیت
acdbcf3f03
2فایلهای تغییر یافته به همراه148 افزوده شده و 141 حذف شده
  1. 1 1
      src/views/networkAccess/registration.vue
  2. 147 140
      src/views/networkAccess/userStatistics.vue

+ 1 - 1
src/views/networkAccess/registration.vue

@@ -3141,7 +3141,7 @@ export default {
         postAction("/businessReminderCard/add", data).then((res) => {
           if (res.success) {
             this.clearModel()
-            this.$message.success(mes, 3);
+            this.$message.success("提交成功", 3);
             this.addIng == true
              location.reload();
             // this.onCance  ()

+ 147 - 140
src/views/networkAccess/userStatistics.vue

@@ -97,19 +97,34 @@
 
             <a-col :span="11" >
               <a-form-item label="创建时间"  prop="industry"      :labelCol="{ span:9}"   :wrapperCol="{ span: 10 }">
-                <j-date :show-time="true" date-format="YYYY-MM-DD" placeholder="请选择开始时间" class="query-group-cust"
+                <j-date :show-time="true" date-format="YYYY-MM-DD HH:mm:ss" placeholder="请选择开始时间" class="query-group-cust"
                         id ="cardStartTime"  v-model="queryParam.createDateStart" ></j-date>
                 <span class="query-group-split-cust"></span>
-                <j-date :show-time="true" date-format="YYYY-MM-DD" placeholder="请选择结束时间" class="query-group-cust"
+                <j-date :show-time="true" date-format="YYYY-MM-DD HH:mm:ss" placeholder="请选择结束时间" class="query-group-cust"
                         id="cardEndTime"  v-model="queryParam.createDateEnd" ></j-date>
               </a-form-item>
             </a-col>
             <a-col :span="7" style='margin-left: 30px'>
-              <a-form-item label="创建人营业厅"  >
+              <a-form-item label="创建人归属部门"  >
                 <j-input placeholder="请输入营业厅" v-model="queryParam.businessAddress" style="width: 220px;"></j-input>
               </a-form-item>
             </a-col>
             </a-row>
+
+            <a-row>
+
+
+              <a-col :span="11" >
+                <a-form-item label="上报时间"  prop="industry"      :labelCol="{ span:9}"   :wrapperCol="{ span: 10 }">
+                  <j-date :show-time="true" date-format="YYYY-MM-DD HH:mm:ss" placeholder="请选择开始时间" class="query-group-cust"
+                          id ="upTimeStart"  v-model="queryParam.upTimeStart" ></j-date>
+                  <span class="query-group-split-cust"></span>
+                  <j-date :show-time="true" date-format="YYYY-MM-DD HH:mm:ss" placeholder="请选择结束时间" class="query-group-cust"
+                          id="upTimeEnd"  v-model="queryParam.upTimeEnd" ></j-date>
+                </a-form-item>
+              </a-col>
+
+            </a-row>
           </template>
         </a-form>
       </div>
@@ -163,11 +178,14 @@
               <a-divider type="vertical"/>
             </span>
 
-              <span v-has="'userStatistics:list:update'" v-show=" currentTab != 'del'">
-              <a @click="showImproveAndUploadAdmin(record)">上报</a>
+              <span v-has="'userStatistics:up'" v-show=" currentTab != 'del'">
+              <a @click="showImproveAndUploadAdmin(record,'2')">上报</a>
+              <a-divider type="vertical"/>
+            </span>
+              <span v-has="'userStatistics:list:upCom'" v-show=" currentTab != 'del'">
+              <a @click="showImproveAndUploadAdminCom(record,'1')">上报分公司</a>
               <a-divider type="vertical"/>
             </span>
-
 
               <span v-has="'userStatistics:list:notice'" v-show=" currentTab != 'del'">
               <a @click="noticeDeal(record)">通知</a>
@@ -230,7 +248,22 @@
           <template v-slot:rowIndex="text,records,index">
             {{ (ipagination.current - 1) * ipagination.pageSize + Number(index) + 1 }}
           </template>
-
+          <template v-slot:current="text, record">
+<!--            <div>{{currentCom(record)}}</div>-->
+<!--            if (record.status==='0'){-->
+<!--            return record.businessAddress-->
+<!--            }-->
+<!--            if (record.status==='1'){-->
+<!--            return '已报分公司'-->
+<!--            }-->
+<!--            if (record.status==='2'){-->
+<!--            return '已完成'-->
+<!--            }-->
+<!--            <div v-if="record.status==='0'"  style="color: red">{{ record.businessAddress }}</div>-->
+<!--            <div v-if="record.status==='1'"  style="color: yellow">{{ 已报分公司 }}</div>-->
+<!--            <div v-if="record.status==='2'"  style="color: greenyellow">{{ 已完成 }}</div>-->
+            <a-badge :color=" record.status  | statusCurrentColor"  :text="record | currentFilter "/>
+          </template>
         </a-table>
 
       </div>
@@ -268,11 +301,13 @@ export default {
       statusList:
         [{
           text: '上报成功',
+          value: '2',
+        },{
+          text: '已报分公司',
           value: '1',
         }, {
-          text: '未上报',
+          text: '新建未报',
           value: '0',
-
         }],
       company:'',
       sysCompany: [],
@@ -353,16 +388,11 @@ export default {
           title: '创建时间',
           align: "center",
           sorter: true,
+          width: 100,
           dataIndex: 'createTime'
         }, {
           title: '创建人归属部门',
-          align: "center",
-          sorter: true,
-          dataIndex: 'businessAddress'
-          //scopedSlots: {customRender: 'sysBusinessHall'}
-
-        },{
-          title: '当前处理部门',
+          width: 100,
           align: "center",
           sorter: true,
           dataIndex: 'businessAddress'
@@ -375,118 +405,7 @@ export default {
           dataIndex: 'upTime'
           //scopedSlots: {customRender: 'sysBusinessHall'}
         },
-        // {
-        //   title: '更新人',
-        //   align: "center",
-        //   sorter: true,
-        //   dataIndex: 'updateBy'
-        // }, {
-        //   title: '更新人营业厅',
-        //   align: "center",
-        //   sorter: true,
-        //   dataIndex: 'newBusinessAddress'
-          //scopedSlots: {customRender: 'newBusinessAddress'}
-          // },
-          // {
-          //   title: '拨测联系电话',
-          //   align: "center",
-          //   sorter: true,
-          //   dataIndex: 'phone',
-          //   scopedSlots: {customRender: 'phone'}
-          //   /* customRender: function (text, record, index) {
-          //      return "<span style='color: #1890FF'>{{text}}</span>"
-          //    }*/
-          // },
-          // {
-          //   title: '拨测结果',
-          //   align: "center",
-          //   sorter: true,
-          //   dataIndex: 'calltestResults',
-          //   customRender: function (text, record, index) {
-          //     if (text === '1') {
-          //       return '关机';
-          //     } else if (text === '2') {
-          //       return '未接通';
-          //     } else if (text === '3') {
-          //       return '可接通不知晓入网事宜';
-          //     } else if (text === '4') {
-          //       return '可接通认可办理';
-          //     }
-          //     return '';
-          //   }
-          // },
-          // {
-          //   title: '现用号码运营商',
-          //   align: "center",
-          //   dataIndex: 'operator',
-          //   customRender: function (text, record, index) {
-          //     if (text === '1') {
-          //       return '本地运营商';
-          //     } else if (text === '2') {
-          //       return '异地运营商';
-          //     }
-          //     return ''
-          //   }
-          // },
-          // {
-          //   title: '现用号码运营商类型',
-          //   align: "center",
-          //   dataIndex: 'operatorType',
-          //   customRender: function (text, record, index) {
-          //     if (text === '1') {
-          //       return '移动';
-          //     } else if (text === '2') {
-          //       return '联通';
-          //     } else if (text === '3') {
-          //       return '电信';
-          //     } else if (text === '4') {
-          //       return '其他';
-          //     }
-          //     return ''
-          //   }
-          // },
-          // {
-          //   title: '现用号码使用年限',
-          //   align: "center",
-          //   sorter: true,
-          //   dataIndex: 'useLife'
-          // },
-          // {
-          //   title: '客户名下有无电信号码',
-          //   align: "center",
-          //   dataIndex: 'isDxNumber',
-          //   customRender: function (text, record, index) {
-          //     if (text == '1') {
-          //       return '有';
-          //     } else if (text == '2') {
-          //       return '无';
-          //     }
-          //     return '';
-          //   }
-          // },
-          // {
-          //   title: '创建人',
-          //   align: "center",
-          //   dataIndex: 'createBy'
-          // },
-          // {
-          //   title: '创建时间',
-          //   align: "center",
-          //   sorter: true,
-          //   dataIndex: 'createTime'
-          // },
-          // {
-          //   title: '更新人',
-          //   align: "center",
-          //   dataIndex: 'updateBy'
-          // },
-          // {
-          //   title: '更新使时间',
-          //   align: "center",
-          //   sorter: true,
-          //   dataIndex: 'updateTime'
-          // },
-      //  },
+
       {
           title: '办理电话',
           align: "center",
@@ -500,7 +419,7 @@ export default {
           align: "center",
           sorter: true,
           dataIndex: 'numberResults',
-          scopedSlots: {customRender: 'numberResults'}
+          scopedSlots: {customRender: 'numberResults'},
           /*customRender: function (text, record, index) {
             if (text == '1') {
               return '非高危';
@@ -511,17 +430,28 @@ export default {
             }
             return '';
           }*/
+        },{
+          title: '当前处理部门',
+          align: "center",
+          sorter: true,
+          dataIndex: 'businessAddress',
+          fixed: 'right',
+          scopedSlots: {customRender: 'current'}
+          //scopedSlots: {customRender: 'sysBusinessHall'}
+
         },{
           title: '上报状态',
           align: "center",
           sorter: true,
           dataIndex: 'status',
+          fixed: 'right',
           scopedSlots: {customRender: 'status'}
         },
         {
           title: '操作',
           dataIndex: 'action',
           align: "center",
+          fixed: 'right',
           scopedSlots: {customRender: 'action'}
         }
       ],
@@ -559,19 +489,40 @@ export default {
     },
     statusEscalationColor(type) {
       const statusTypeMap = {
-        '1': 'green',
+        '2': 'green',
+        '1': 'yellow',
         '0': 'gray',
       }
       console.log(statusTypeMap[type])
       return statusTypeMap[type]
     },
+
+    currentFilter(status) {
+      const statusMap = {
+        '0': status.businessAddress,
+        '1':'已报分公司',
+        '2': '已完成'
+      }
+      return statusMap[status.status]
+    },
+    statusCurrentColor(type) {
+      const statusTypeMap = {
+        '2': 'green',
+        '1': 'yellow',
+        '0': 'gray',
+      }
+      console.log(statusTypeMap[type])
+      return statusTypeMap[type]
+    },
+
     escalationFilter(status) {
       const statusMap = {
-        '0': '未上报',
-        '1': '上报成功',
+        '0': '新建未报',
+        '1':'已报分公司',
+        '2': '上报成功'
       }
       return statusMap[status]
-    }
+    },
   },
   created() {
     /**获取研判结果统计数*/
@@ -588,12 +539,23 @@ export default {
 
     },
     excelOutUp(){
+
       if (this.selectionRows.length===0){
         return this.$message.warning('请重新选择数据...', 3);
       }
       for (let i = 0; i < this.selectionRows.length; i++) {
-        if(this.selectionRows[i].status==='1'){
-          return this.$message.warning('选中数据中存在已上报的数据...', 3);
+        if(this.selectionRows[i].status==='2'){
+          return this.$message.warning('选中数据中存在上报成功的数据...', 3);
+        }
+      }
+      for (let i = 0; i < this.selectionRows.length; i++) {
+        if(this.selectionRows[i].status==='0'){
+          return this.$message.warning('选中数据中存在新建未报的数据...', 3);
+        }
+      }
+      for (let s = 0; s < this.selectionRows.length; s++) {
+        if(this.selectionRows[s].numberResults.indexOf('1')!==-1){
+          return this.$message.warning('选中数据存在非高危数据(请重新选择)...', 3);
         }
       }
       this.excelOut();
@@ -716,7 +678,18 @@ export default {
       }
       return phone
     },
-
+    currentCom(record){
+      //新建未报
+      if (record.status==='0'){
+        return record.businessAddress
+      }
+      if (record.status==='1'){
+        return '已报分公司'
+      }
+      if (record.status==='2'){
+        return '已完成'
+      }
+    },
     showByCreateBy(record){
 
       this.selectRefresh();
@@ -852,10 +825,34 @@ export default {
       })
 
     },
-    showImproveAndUploadAdmin(record) {
+    showImproveAndUploadAdminCom(record,status) {
+      //上报分公司
        if (record.status==='1'){
-         return this.$message.warning('上报状态为已上报 请勿重复操作', 3);
+         return this.$message.warning('上报状态为已上报分公司 请勿重复操作', 3);
        }
+      if (record.status==='2'){
+        return this.$message.warning('上报状态为已上报 请勿重复操作', 3);
+      }
+      let data = {
+        ids: [record.id],
+      }
+      postAction("/businessReminderCard/escalationCom",{ids: data.ids} ).then((res) => {
+        if (res.success) {
+          this.$message.success(res.message, 3);
+          this.loadData(1);
+        } else {
+          this.$message.error(res.message);
+        }
+      })
+    },
+    showImproveAndUploadAdmin(record,status) {
+      //上报
+      if (record.status==='0'){
+        return this.$message.warning('上报状态为新建未报 请先进行上报分公司', 3);
+      }
+      if (record.status==='2'){
+        return this.$message.warning('上报状态为已上报 请勿重复操作', 3);
+      }
       let data = {
         ids: [record.id],
       }
@@ -882,8 +879,18 @@ export default {
     },
     showImproveAndUploadList() {
       for (let i = 0; i < this.selectionRows.length; i++) {
-        if(this.selectionRows[i].status==='1'){
-          return this.$message.warning('选中数据中存在已上报的数据...', 3);
+        if(this.selectionRows[i].status==='2'){
+          return this.$message.warning('选中数据中存在上报成功的数据...', 3);
+        }
+      }
+      for (let i = 0; i < this.selectionRows.length; i++) {
+        if(this.selectionRows[i].status==='0'){
+          return this.$message.warning('选中数据中存在新建未报的数据...', 3);
+        }
+      }
+      for (let s = 0; s < this.selectionRows.length; s++) {
+        if(this.selectionRows[s].numberResults.indexOf('1')!==-1){
+          return this.$message.warning('选中数据存在非高危数据(请重新选择)...', 3);
         }
       }