userStatistics.vue 26 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843
  1. <template>
  2. <div>
  3. <a-card :bordered="false">
  4. <div>
  5. <!-- <a-tabs v-has="'user:userStatistics:tab'" :active-key="currentTab" default-active-key="all"-->
  6. <!-- @change="tabChange">-->
  7. <!-- <a-tab-pane key="all" :tab="tabAll"></a-tab-pane>-->
  8. <!-- <a-tab-pane key="undo" :tab="tabUndo"></a-tab-pane>-->
  9. <!-- <a-tab-pane key="uncheck" :tab="tabUncheck"></a-tab-pane>-->
  10. <!-- <a-tab-pane key="checked" :tab="tabChecked"></a-tab-pane>-->
  11. <!-- </a-tabs>-->
  12. <!-- <a-tabs v-has="'admin:userStatistics:tab'" :active-key="currentTab" default-active-key="all"-->
  13. <!-- @change="tabChange">-->
  14. <!-- <a-tab-pane key="all" :tab="tabAll"></a-tab-pane>-->
  15. <!-- <a-tab-pane key="undo" :tab="tabUndo"></a-tab-pane>-->
  16. <!-- <a-tab-pane key="uncheck" :tab="tabUncheck"></a-tab-pane>-->
  17. <!-- <a-tab-pane key="checked" :tab="tabChecked"></a-tab-pane>-->
  18. <!-- <a-tab-pane key="del" :tab="tabDelCheck"></a-tab-pane>-->
  19. <!-- </a-tabs>-->
  20. </div>
  21. <!-- 查询区域 -->
  22. <div class="table-page-search-wrapper">
  23. <a-form layout="inline" @keyup.enter.native="searchQuery">
  24. <a-row :gutter="24">
  25. <a-col :xl="6" :lg="7" :md="8" :sm="24">
  26. <a-form-item label="客户名称">
  27. <j-input placeholder="请输入客户名称" v-model="queryParam.cardName"></j-input>
  28. </a-form-item>
  29. </a-col>
  30. <a-col :xl="6" :lg="7" :md="8" :sm="24">
  31. <a-form-item label="证件编号">
  32. <j-input placeholder="请输入证件编号" v-model="queryParam.cardNo"></j-input>
  33. </a-form-item>
  34. </a-col>
  35. <a-col :span="6">
  36. <a-form-model-item label=" 判研结果 " :labelCol="{ span:5}" :wrapperCol="{ span: 8 }">
  37. <a-select placeholder="请选择判研结果" v-model="queryParam.numberResults" mode="tags">
  38. <a-select-option v-for="item in optionsWithDisabled" :value="item.value">
  39. {{ item.text }}
  40. </a-select-option>
  41. </a-select>
  42. </a-form-model-item>
  43. </a-col>
  44. <a-col :xl="6" :lg="7" :md="8" :sm="24">
  45. <span style="float: left;overflow: hidden;" class="table-page-search-submitButtons">
  46. <a-button type="primary" @click="searchQuery" icon="search">查询</a-button>
  47. <a-button type="primary" @click="searchReset" icon="reload" style="margin-left: 8px">重置</a-button>
  48. <a @click="handleToggleSearch" style="margin-left: 8px">
  49. {{ toggleSearchStatus ? '收起' : '展开' }}
  50. <a-icon :type="toggleSearchStatus ? 'up' : 'down'"/>
  51. </a>
  52. </span>
  53. </a-col>
  54. </a-row>
  55. <template v-if="toggleSearchStatus">
  56. <a-row :gutter="24">
  57. <a-col :span="6">
  58. <a-form-model-item label=" 上报状态 " :labelCol="{ span:5}" :wrapperCol="{ span: 8 }">
  59. <a-select placeholder="请选择上报状态" v-model="queryParam.status" >
  60. <a-select-option v-for="item in statusList" :value="item.value">
  61. {{ item.text }}
  62. </a-select-option>
  63. </a-select>
  64. </a-form-model-item>
  65. </a-col>
  66. <a-col :span="6">
  67. <a-form-item label=" 办理电话 " :labelCol="{ span:5}" :wrapperCol="{ span: 8 }">
  68. <j-input placeholder="请输入办理电话" v-model="queryParam.newPhone"></j-input>
  69. </a-form-item>
  70. </a-col>
  71. <a-col :span="6">
  72. <a-form-item label=" 创建人 " :labelCol="{ span:5}" :wrapperCol="{ span: 8 }">
  73. <j-input placeholder="请输入创建人" v-model="queryParam.createBy"></j-input>
  74. </a-form-item>
  75. </a-col>
  76. </a-row>
  77. <a-row>
  78. <a-col :span="11" >
  79. <a-form-item label="创建时间" prop="industry" :labelCol="{ span:9}" :wrapperCol="{ span: 10 }">
  80. <j-date :show-time="true" date-format="YYYY-MM-DD" placeholder="请选择开始时间" class="query-group-cust"
  81. id ="cardStartTime" v-model="queryParam.createDateStart" ></j-date>
  82. <span class="query-group-split-cust"></span>
  83. <j-date :show-time="true" date-format="YYYY-MM-DD" placeholder="请选择结束时间" class="query-group-cust"
  84. id="cardEndTime" v-model="queryParam.createDateEnd" ></j-date>
  85. </a-form-item>
  86. </a-col>
  87. <a-col :span="7" style='margin-left: 30px'>
  88. <a-form-item label="创建人营业厅" >
  89. <j-input placeholder="请输入营业厅" v-model="queryParam.businessAddress" style="width: 220px;"></j-input>
  90. </a-form-item>
  91. </a-col>
  92. </a-row>
  93. </template>
  94. </a-form>
  95. </div>
  96. <!-- 操作按钮区域 -->
  97. <div class="table-operator">
  98. <a-button type="primary" icon="download" @click="handleExportXls('入网统计')">导出</a-button>
  99. <!-- 高级查询区域 -->
  100. <a-dropdown v-if="selectedRowKeys.length > 0">
  101. <a-menu slot="overlay">
  102. <a-menu-item key="1" @click="showImproveAndUploadList" v-has="'access:check:lists:up'">
  103. <a-icon type="up"/>
  104. 上报
  105. </a-menu-item>
  106. </a-menu>
  107. <a-button style="margin-left: 8px"> 批量操作
  108. <a-icon type="down"/>
  109. </a-button>
  110. </a-dropdown>
  111. </div>
  112. <!-- table区域-begin -->
  113. <div>
  114. <div class="ant-alert ant-alert-info" style="margin-bottom: 16px;">
  115. <i class="anticon anticon-info-circle ant-alert-icon"></i> 已选择 <a
  116. style="font-weight: 600">{{ selectedRowKeys.length }}</a>项
  117. <a style="margin-left: 24px" @click="onClearSelected">清空</a>
  118. </div>
  119. <a-table
  120. ref="table"
  121. size="middle"
  122. :scroll="{x:true}"
  123. bordered
  124. rowKey="id"
  125. :columns="columns"
  126. :dataSource="dataSource"
  127. :pagination="ipagination"
  128. :loading="loading"
  129. :rowSelection="{selectedRowKeys: selectedRowKeys, onChange: onSelectChange}"
  130. class="j-table-force-nowrap"
  131. @change="handleTableChange">
  132. <template slot="action" slot-scope="text, record">
  133. <div>
  134. <span v-has="'userStatistics:list:update'" v-show=" currentTab != 'del'">
  135. <a @click="showImproveAndUpload(record)">修改</a>
  136. <a-divider type="vertical"/>
  137. </span>
  138. <span v-has="'userStatistics:list:update'" v-show=" currentTab != 'del'">
  139. <a @click="showImproveAndUploadAdmin(record)">上报</a>
  140. <a-divider type="vertical"/>
  141. </span>
  142. <span v-has="'userStatistics:list:notice'" v-show=" currentTab != 'del'">
  143. <a @click="noticeDeal(record)">通知</a>
  144. <a-divider type="vertical"/>
  145. </span>
  146. <span v-has="'userStatistics:list:restore:id'" v-show=" currentTab == 'del'">
  147. <a @click="restoreById(record)">恢复</a>
  148. <a-divider type="vertical"/>
  149. </span>
  150. <span v-has="'userStatistics:list:remove:id'" v-show=" currentTab == 'del'">
  151. <a @click="removeById(record)">彻底删除</a>
  152. <a-divider type="vertical"/>
  153. </span>
  154. <!-- <a-dropdown v-show =" currentTab != 'del'">-->
  155. <!-- <a class="ant-dropdown-link">更多-->
  156. <!-- <a-icon type="down"/>-->
  157. <!-- </a>-->
  158. <!-- <a-menu slot="overlay">-->
  159. <!-- <a-menu-item v-has="'del:userStatistics:list:row:delete'">-->
  160. <!-- <a @click="delFlagById(record)">删除</a>-->
  161. <!-- </a-menu-item>-->
  162. <!-- </a-menu>-->
  163. <!-- </a-dropdown>-->
  164. </div>
  165. </template>
  166. <template v-slot:status="text, record">
  167. <a-badge :status="text | statusEscalation" :text="text | escalationFilter"/>
  168. </template>
  169. <template v-slot:createBy="text, record">
  170. <a @click="showByCreateBy(record)">{{text}}</a>
  171. </template>
  172. <template v-slot:sysBusinessHall="text, record">
  173. <div>{{getSysCompany(text)}}</div>
  174. </template>
  175. <template v-slot:cardNo="text, record">
  176. <a @click="showByCardNo(record)">{{text}}</a>
  177. </template>
  178. <template v-slot:cardName="text, record">
  179. <a @click="showByCardName(record)">{{text}}</a>
  180. </template>
  181. <template v-slot:phone="text, record">
  182. <a @click="showByPhone(record)">{{text}}</a>
  183. </template>
  184. <template v-slot:numberResults="text, record">
  185. <a-badge :status="text | statusTypeFilter" :text="text | statusFilter"/>
  186. </template>
  187. <template v-slot:newPhone="text, record">
  188. <div>{{newPhone(text)}}</div>
  189. </template>
  190. <template v-slot:newBusinessAddress="text, record">
  191. <div>{{getSysCompany(text)}}</div>
  192. </template>
  193. <template v-slot:rowIndex="text,records,index">
  194. {{ (ipagination.current - 1) * ipagination.pageSize + Number(index) + 1 }}
  195. </template>
  196. </a-table>
  197. </div>
  198. </a-card>
  199. </div>
  200. </template>
  201. <script>
  202. import {getAction, postAction,deleteAction} from "@api/manage";
  203. import {JeecgListMixin} from '@/mixins/JeecgListMixin'
  204. import '@/assets/less/TableExpand.less'
  205. export default {
  206. name: "userStatistics",
  207. mixins: [JeecgListMixin],
  208. inject: ['closeCurrent'],
  209. data() {
  210. return {
  211. optionsWithDisabled:
  212. [{
  213. text: '非高危',
  214. value: '1',
  215. }, {
  216. text: '上报关停',
  217. value: '2',
  218. }, {
  219. text: '上报蓝/紫',
  220. value: '3',
  221. } ],
  222. statusList:
  223. [{
  224. text: '上报成功',
  225. value: '1',
  226. }, {
  227. text: '未上报',
  228. value: '0',
  229. }],
  230. company:'',
  231. sysCompany: [],
  232. ipagination:{
  233. current: 1,
  234. pageSize: 10,
  235. pageSizeOptions: ['10', '20', '30','300'],
  236. showTotal: (total, range) => {
  237. return range[0] + "-" + range[1] + " 共" + total + "条"
  238. },
  239. showQuickJumper: true,
  240. showSizeChanger: true,
  241. total: 0
  242. },
  243. numberResults: null,
  244. /**统计标签*/
  245. currentTab: 'all',
  246. tabAll: '全部(0)',
  247. tabUndo: '非高危(0)',
  248. tabUncheck: '上报蓝紫名单(0)',
  249. tabChecked: '上报关停(0)',
  250. tabDelCheck: "已删除(0)",
  251. allCount: 0,
  252. tabUndoCount: 0,
  253. tabUncheckCount: 0,
  254. tabCheckedCount: 0,
  255. delCount: 0,
  256. /* table选中keys*/
  257. selectedRowKeys: [],
  258. /* table选中records*/
  259. selectionRows: [],
  260. /* 查询条件-请不要在queryParam中声明非字符串值的属性 */
  261. queryParam: {},
  262. url: {
  263. getCompany: "/sysCompany/list",
  264. typeCount: "/businessReminderCard/type/count",
  265. list: "/businessReminderCard/list",
  266. delete: "/businessReminderCard/delete/flagById",
  267. removeById: "/businessReminderCard/deleteById",
  268. restoreById: "/businessReminderCard/restoreById",
  269. notice: "/smsCheck/customerInfo/notice",
  270. exportXlsUrl: "/businessReminderCard/exportXls",
  271. },
  272. /**表单
  273. * 入网用户统计:身份证号/姓名/办理电话/创建人/创建人所属营业厅/更新人/更新人营业厅/研判结果/
  274. * */
  275. columns: [
  276. {
  277. title: '#',
  278. dataIndex: '',
  279. key: 'rowIndex',
  280. width: 60,
  281. align: "center",
  282. scopedSlots: {customRender: 'rowIndex'}
  283. },
  284. {
  285. title: '证件编号',
  286. align: "center",
  287. sorter: true,
  288. dataIndex: 'cardNo',
  289. scopedSlots: {customRender: 'cardNo'}
  290. }, {
  291. title: '客户名称',
  292. align: "center",
  293. sorter: true,
  294. dataIndex: 'cardName'
  295. // scopedSlots: {customRender: 'cardName'}
  296. }, {
  297. title: '创建人',
  298. align: "center",
  299. sorter: true,
  300. dataIndex: 'createBy'
  301. // scopedSlots: {customRender: 'createBy'}
  302. }, {
  303. title: '创建时间',
  304. align: "center",
  305. sorter: true,
  306. dataIndex: 'createTime'
  307. }, {
  308. title: '创建人营业厅地址',
  309. align: "center",
  310. sorter: true,
  311. dataIndex: 'businessAddress'
  312. //scopedSlots: {customRender: 'sysBusinessHall'}
  313. },
  314. // {
  315. // title: '更新人',
  316. // align: "center",
  317. // sorter: true,
  318. // dataIndex: 'updateBy'
  319. // }, {
  320. // title: '更新人营业厅',
  321. // align: "center",
  322. // sorter: true,
  323. // dataIndex: 'newBusinessAddress'
  324. //scopedSlots: {customRender: 'newBusinessAddress'}
  325. // },
  326. // {
  327. // title: '拨测联系电话',
  328. // align: "center",
  329. // sorter: true,
  330. // dataIndex: 'phone',
  331. // scopedSlots: {customRender: 'phone'}
  332. // /* customRender: function (text, record, index) {
  333. // return "<span style='color: #1890FF'>{{text}}</span>"
  334. // }*/
  335. // },
  336. // {
  337. // title: '拨测结果',
  338. // align: "center",
  339. // sorter: true,
  340. // dataIndex: 'calltestResults',
  341. // customRender: function (text, record, index) {
  342. // if (text === '1') {
  343. // return '关机';
  344. // } else if (text === '2') {
  345. // return '未接通';
  346. // } else if (text === '3') {
  347. // return '可接通不知晓入网事宜';
  348. // } else if (text === '4') {
  349. // return '可接通认可办理';
  350. // }
  351. // return '';
  352. // }
  353. // },
  354. // {
  355. // title: '现用号码运营商',
  356. // align: "center",
  357. // dataIndex: 'operator',
  358. // customRender: function (text, record, index) {
  359. // if (text === '1') {
  360. // return '本地运营商';
  361. // } else if (text === '2') {
  362. // return '异地运营商';
  363. // }
  364. // return ''
  365. // }
  366. // },
  367. // {
  368. // title: '现用号码运营商类型',
  369. // align: "center",
  370. // dataIndex: 'operatorType',
  371. // customRender: function (text, record, index) {
  372. // if (text === '1') {
  373. // return '移动';
  374. // } else if (text === '2') {
  375. // return '联通';
  376. // } else if (text === '3') {
  377. // return '电信';
  378. // } else if (text === '4') {
  379. // return '其他';
  380. // }
  381. // return ''
  382. // }
  383. // },
  384. // {
  385. // title: '现用号码使用年限',
  386. // align: "center",
  387. // sorter: true,
  388. // dataIndex: 'useLife'
  389. // },
  390. // {
  391. // title: '客户名下有无电信号码',
  392. // align: "center",
  393. // dataIndex: 'isDxNumber',
  394. // customRender: function (text, record, index) {
  395. // if (text == '1') {
  396. // return '有';
  397. // } else if (text == '2') {
  398. // return '无';
  399. // }
  400. // return '';
  401. // }
  402. // },
  403. // {
  404. // title: '创建人',
  405. // align: "center",
  406. // dataIndex: 'createBy'
  407. // },
  408. // {
  409. // title: '创建时间',
  410. // align: "center",
  411. // sorter: true,
  412. // dataIndex: 'createTime'
  413. // },
  414. // {
  415. // title: '更新人',
  416. // align: "center",
  417. // dataIndex: 'updateBy'
  418. // },
  419. // {
  420. // title: '更新使时间',
  421. // align: "center",
  422. // sorter: true,
  423. // dataIndex: 'updateTime'
  424. // },
  425. // },
  426. {
  427. title: '办理电话',
  428. align: "center",
  429. sorter: true,
  430. width: 200,
  431. dataIndex: 'newPhone',
  432. scopedSlots: {customRender: 'newPhone'}
  433. },
  434. {
  435. title: '研判结果',
  436. align: "center",
  437. sorter: true,
  438. dataIndex: 'numberResults',
  439. scopedSlots: {customRender: 'numberResults'}
  440. /*customRender: function (text, record, index) {
  441. if (text == '1') {
  442. return '非高危';
  443. } else if (text == '2') {
  444. return '上报蓝紫名单';
  445. } else if (text == '3') {
  446. return '上报关停';
  447. }
  448. return '';
  449. }*/
  450. },{
  451. title: '上报状态',
  452. align: "center",
  453. sorter: true,
  454. dataIndex: 'status',
  455. scopedSlots: {customRender: 'status'}
  456. },
  457. {
  458. title: '操作',
  459. dataIndex: 'action',
  460. align: "center",
  461. scopedSlots: {customRender: 'action'}
  462. }
  463. ],
  464. }
  465. },
  466. filters: {
  467. statusTypeFilter(type) {
  468. const statusTypeMap = {
  469. '1': 'success',
  470. '2': 'processing',
  471. '3': 'warning',
  472. '4': 'warning',
  473. '3,4': 'warning',
  474. '4,3': 'warning',
  475. }
  476. return statusTypeMap[type]
  477. },
  478. statusFilter(status) {
  479. const statusMap = {
  480. '1': '非高危',
  481. '2': '上报关停',
  482. '3': '上报蓝名单',
  483. '4': '上报紫名单',
  484. '3,4':'上报蓝/紫名单',
  485. '4,3':'上报蓝/紫名单',
  486. }
  487. return statusMap[status]
  488. },
  489. statusEscalation(type) {
  490. const statusTypeMap = {
  491. '1': 'success',
  492. '0': 'warning',
  493. }
  494. return statusTypeMap[type]
  495. },
  496. escalationFilter(status) {
  497. const statusMap = {
  498. '0': '未上报',
  499. '1': '上报成功',
  500. }
  501. return statusMap[status]
  502. }
  503. },
  504. created() {
  505. /**获取研判结果统计数*/
  506. this.typeCount();
  507. this.getSysCompanyData();
  508. },
  509. methods: {
  510. getSysCompanyData(){
  511. let data = {
  512. };
  513. getAction(this.url.getCompany, data).then((res) => {
  514. if (res.success) {
  515. let result = res.result;
  516. console.log(result + "result");
  517. if (result != null) {
  518. this.sysCompany = result;
  519. }
  520. }
  521. })
  522. },
  523. getSysCompany(id) {
  524. for (var item of this.sysCompany) {
  525. for (var it of item.sysBusinessHallList) {
  526. if (it.id === id) {
  527. return it.name
  528. }
  529. }
  530. }
  531. },
  532. newPhone(newPhones){
  533. var phone='';
  534. newPhones = newPhones.split(',');
  535. for (var item of newPhones) {
  536. phone+=item+' '
  537. }
  538. return phone
  539. },
  540. showByCreateBy(record){
  541. this.selectRefresh();
  542. this.selectedRowKeys = [];
  543. this.selectionRows = [];
  544. },
  545. showByBusinessAddresse(record){
  546. let queryParam = {
  547. "businessAddress":record.businessAddress,
  548. "cardNo":this.queryParam.cardNo,
  549. "cardName":this.queryParam.cardName,
  550. "newPhone":this.queryParam.newPhone,
  551. "createDateStart":this.queryParam.createDateStart,
  552. "createDateEnd":this.queryParam.createDateEnd
  553. }
  554. this.loadData(null,queryParam);
  555. this.selectedRowKeys = [];
  556. this.selectionRows = [];
  557. },
  558. showByPhone(record){
  559. this.selectRefresh();
  560. this.selectedRowKeys = [];
  561. this.selectionRows = [];
  562. },
  563. showByCardNo(record){
  564. // let queryParam = {
  565. // "cardNo":record.cardNo,
  566. // "cardName":this.queryParam.cardName
  567. // }
  568. // this.loadData(null,queryParam);
  569. // this.selectedRowKeys = [];
  570. // this.selectionRows = [];
  571. // this.$router.go({
  572. // path:'/networkAccess/registration',
  573. // query: {
  574. // close:true
  575. // }
  576. // })
  577. //this.$router.push({path: '/networkAccess/registrationSelect', query: {id: record.id,cardNo: record.cardNo,isDisabled:true}});
  578. this.$router.push({path: '/networkAccess/registrationSelect', query: {id: record.id,isDisabled:true}});
  579. },
  580. showByCardName(record){
  581. this.selectRefresh();
  582. this.selectedRowKeys = [];
  583. this.selectionRows = [];
  584. },
  585. /**标签监听*/
  586. tabChange(key) {
  587. this.url.list = "/businessReminderCard/list"
  588. if (key == "all") {
  589. this.numberResults = null;
  590. this.queryParam.numberResults_MultiString = this.numberResults;
  591. this.currentTab = 'all';
  592. } else if (key == "undo") {
  593. this.numberResults = "1";
  594. this.queryParam.numberResults_MultiString = this.numberResults;
  595. this.currentTab = 'undo';
  596. } else if (key == "uncheck") {
  597. this.numberResults = "2";
  598. this.queryParam.numberResults_MultiString = this.numberResults;
  599. this.currentTab = 'uncheck';
  600. } else if (key == "checked") {
  601. this.numberResults = "3";
  602. this.queryParam.numberResults_MultiString = this.numberResults;
  603. this.currentTab = 'checked';
  604. } else if (key == "del") {
  605. this.numberResults = null
  606. this.url.list = '/businessReminderCard/delete/list'
  607. this.queryParam.numberResults_MultiString = this.numberResults;
  608. this.currentTab = 'del';
  609. }
  610. this.loadData(1);
  611. },
  612. searchQuery() {
  613. this.loadData(1);
  614. this.selectedRowKeys = [];
  615. this.selectionRows = [];
  616. //this.loadTabNumber(this.task.id);
  617. },
  618. /**统计数量*/
  619. typeCount() {
  620. let that = this;
  621. let url = that.url.typeCount;
  622. getAction(url, {}).then(res => {
  623. if (res.success) {
  624. let result = res.result;
  625. that.tabAll = '全部(' + result.count + ')';
  626. console.log(that.tabAll)
  627. that.tabUndo = '非高危(' + result.unCount + ')';
  628. that.tabUncheck = '上报蓝紫名单(' + result.uncheckCount + ')';
  629. that.tabChecked = '上报关停(' + result.closeCount + ')';
  630. that.tabDelCheck = '已删除(' + result.delCount + ')';
  631. } else {
  632. }
  633. }).finally(() => {
  634. })
  635. },
  636. getDate(){
  637. var today = new Date();
  638. var dd = String(today.getDate()).padStart(2, '0');
  639. var mm = String(today.getMonth() + 1).padStart(2, '0');
  640. var yyyy = today.getFullYear();
  641. today = yyyy+'-'+ mm+'-' +dd;
  642. return today;
  643. },
  644. /**修改*/
  645. showImproveAndUpload(record) {
  646. if (!record.createTime.match(RegExp(this.getDate()))){
  647. return this.$message.warning('非当天创建 禁止修改', 3);
  648. }
  649. //校验
  650. let data = {
  651. ids: [record.id],
  652. }
  653. postAction("/businessReminderCard/check",{ids: data.ids} ).then((res) => {
  654. if (!res.success) {
  655. return this.$message.warning(res.message, 3);
  656. }
  657. this.$router.push({path: '/networkAccess/registrationUpdate', query: {id: record.id}});
  658. })
  659. },
  660. showImproveAndUploadAdmin(record) {
  661. if (record.status==='1'){
  662. return this.$message.warning('上报状态为已上报 请勿重复操作', 3);
  663. }
  664. let data = {
  665. ids: [record.id],
  666. }
  667. postAction("/businessReminderCard/escalation",{ids: data.ids} ).then((res) => {
  668. if (res.success) {
  669. this.$message.success(res.message, 3);
  670. this.loadData(1);
  671. } else {
  672. this.$message.error(res.message);
  673. }
  674. })
  675. },
  676. selectRefresh(){
  677. let queryParam = {
  678. "cardNo":this.queryParam.cardNo,
  679. "cardName":record.cardName,
  680. "newPhone":this.queryParam.newPhone,
  681. "createDateStart":this.queryParam.createDateStart,
  682. "createDateEnd":this.queryParam.createDateEnd,
  683. "sysBusinessHall":this.queryParam.sysBusinessHall,
  684. "status":this.queryParam.status
  685. }
  686. this.loadData(null,queryParam);
  687. },
  688. showImproveAndUploadList() {
  689. for (let i = 0; i < this.selectionRows.length; i++) {
  690. if(this.selectionRows[i].status==='1'){
  691. return this.$message.warning('选中数据中存在已上报的数据...', 3);
  692. }
  693. }
  694. let data = {
  695. ids: this.selectedRowKeys,
  696. }
  697. postAction("/businessReminderCard/escalation",data ).then((res) => {
  698. if (res.success) {
  699. this.$message.success(res.message, 3);
  700. this.loadData(1);
  701. } else {
  702. this.$message.error(res.message);
  703. }
  704. })
  705. },
  706. /**详情*/
  707. showCheckDetail(record) {
  708. let id = record.id;
  709. this.$router.push({path: '/networkAccess/registrationDetails', query: {id: record.id}});
  710. },
  711. /**删除*/
  712. delFlagById(record){
  713. let id = record.id;
  714. let that = this;
  715. let url = that.url.delete;
  716. deleteAction(url, {id: id}).then(res => {
  717. if (res.success) {
  718. this.typeCount();
  719. this.$message.success("删除成功", 7);
  720. this.loadData(1);
  721. } else {
  722. this.$message.error("删除失败", 7);
  723. }
  724. });
  725. },
  726. /**彻底删除*/
  727. removeById(record) {
  728. let id = record.id;
  729. let that = this;
  730. let url = that.url.removeById;
  731. getAction(url, {id: id}).then(res => {
  732. if (res.success) {
  733. this.typeCount();
  734. this.$message.success("删除成功", 7);
  735. this.loadData(1);
  736. } else {
  737. this.$message.error("删除失败", 7);
  738. }
  739. });
  740. },
  741. /**恢复*/
  742. restoreById(record) {
  743. let id = record.id;
  744. let that = this;
  745. let url = that.url.restoreById;
  746. getAction(url, {id: id}).then(res => {
  747. if (res.success) {
  748. this.typeCount();
  749. this.$message.success("恢复成功", 7);
  750. this.loadData(1);
  751. } else {
  752. this.$message.error("恢复失败", 7);
  753. }
  754. });
  755. },
  756. /**通知*/
  757. noticeDeal(record) {
  758. let that = this;
  759. that.$message.info('已通知业务员,对入网信息进行修改!');
  760. }
  761. },
  762. }
  763. </script>
  764. <style scoped>
  765. </style>