完成签约之后直接添加人员,录入下发凭证
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

599 lines
22 KiB

  1. webpackJsonp([35],{
  2. /***/ "DWzc":
  3. /***/ (function(module, exports) {
  4. // removed by extract-text-webpack-plugin
  5. /***/ }),
  6. /***/ "KwGp":
  7. /***/ (function(module, __webpack_exports__, __webpack_require__) {
  8. "use strict";
  9. Object.defineProperty(__webpack_exports__, "__esModule", { value: true });
  10. // EXTERNAL MODULE: ./node_modules/babel-runtime/core-js/object/keys.js
  11. var keys = __webpack_require__("fZjL");
  12. var keys_default = /*#__PURE__*/__webpack_require__.n(keys);
  13. // EXTERNAL MODULE: ./node_modules/babel-runtime/core-js/get-iterator.js
  14. var get_iterator = __webpack_require__("BO1k");
  15. var get_iterator_default = /*#__PURE__*/__webpack_require__.n(get_iterator);
  16. // EXTERNAL MODULE: ./node_modules/babel-runtime/core-js/json/stringify.js
  17. var stringify = __webpack_require__("mvHQ");
  18. var stringify_default = /*#__PURE__*/__webpack_require__.n(stringify);
  19. // EXTERNAL MODULE: ./src/api/index.js + 5 modules
  20. var api = __webpack_require__("gyMJ");
  21. // EXTERNAL MODULE: ./node_modules/axios/index.js
  22. var axios = __webpack_require__("mtWM");
  23. var axios_default = /*#__PURE__*/__webpack_require__.n(axios);
  24. // EXTERNAL MODULE: ./src/utils/index.js
  25. var utils = __webpack_require__("0xDb");
  26. // EXTERNAL MODULE: ./node_modules/moment/moment.js
  27. var moment = __webpack_require__("PJh5");
  28. var moment_default = /*#__PURE__*/__webpack_require__.n(moment);
  29. // CONCATENATED MODULE: ./node_modules/babel-loader/lib!./node_modules/vue-loader/lib/selector.js?type=script&index=0!./src/views/doorMagnetism/alarmRecord.vue
  30. //
  31. //
  32. //
  33. //
  34. //
  35. //
  36. //
  37. //
  38. //
  39. //
  40. //
  41. //
  42. //
  43. //
  44. //
  45. //
  46. //
  47. //
  48. //
  49. //
  50. //
  51. //
  52. //
  53. //
  54. //
  55. //
  56. //
  57. //
  58. //
  59. //
  60. //
  61. //
  62. //
  63. //
  64. //
  65. //
  66. //
  67. //
  68. //
  69. //
  70. //
  71. //
  72. //
  73. //
  74. //
  75. //
  76. //
  77. //
  78. //
  79. //
  80. //
  81. //
  82. //
  83. //
  84. //
  85. //
  86. //
  87. //
  88. //
  89. //
  90. //
  91. //
  92. //
  93. //
  94. //
  95. //
  96. //
  97. //
  98. //
  99. //
  100. //
  101. //
  102. //
  103. //
  104. //
  105. //
  106. //
  107. //
  108. //
  109. //
  110. //
  111. //
  112. //
  113. //
  114. //
  115. //
  116. //
  117. //
  118. //
  119. //
  120. //
  121. //
  122. //
  123. //
  124. //
  125. //
  126. //
  127. //
  128. //
  129. //
  130. //
  131. //
  132. //
  133. //
  134. //
  135. //
  136. //
  137. //
  138. //
  139. //
  140. //
  141. //
  142. //
  143. //
  144. //
  145. //
  146. //
  147. //
  148. //
  149. //
  150. //
  151. //
  152. //
  153. //
  154. //
  155. //
  156. //
  157. //
  158. //
  159. //
  160. //
  161. //
  162. //
  163. //
  164. //
  165. //
  166. //
  167. //
  168. //
  169. //
  170. //
  171. //
  172. //
  173. //
  174. //
  175. // import XLSX from "xlsx";
  176. /* harmony default export */ var alarmRecord = ({
  177. inject: ['reload'],
  178. name: "alarmRecord",
  179. data: function data() {
  180. return {
  181. selectoption: [],
  182. selectoptionValue: '',
  183. alertType: [{
  184. value: '0',
  185. label: '心跳'
  186. }, {
  187. value: '1',
  188. label: '开门报警'
  189. }, {
  190. value: '2',
  191. label: '低电报警'
  192. }, {
  193. value: '4',
  194. label: '防拆报警'
  195. }, {
  196. value: '5',
  197. label: '设备故障报警'
  198. }, {
  199. value: '13',
  200. label: '设备测试'
  201. }, {
  202. value: '17',
  203. label: '关门报警'
  204. }, {
  205. value: '18',
  206. label: '低电压恢复与上电开机'
  207. }, {
  208. value: '20',
  209. label: '防拆恢复'
  210. }, {
  211. value: '21',
  212. label: '故障恢复'
  213. }, {
  214. value: '30',
  215. label: '添加子设备'
  216. }, {
  217. value: '31',
  218. label: '删除子设备'
  219. }, {
  220. value: '170',
  221. label: '设备ACK'
  222. }],
  223. searchForm: {
  224. operateCode: '',
  225. roomName: '',
  226. time: '',
  227. name: "",
  228. deviceNum: '',
  229. siteIds: '',
  230. startBattery: '',
  231. endBattery: '',
  232. startTime: '',
  233. endTime: ''
  234. },
  235. titleText: '设备未处理报警记录(IMEI:860709056256857)',
  236. textarea: '', //批量处理备注
  237. dialogVisible: false,
  238. dialogVisible1: false,
  239. input: '',
  240. content: '切换单个/多个查询模式',
  241. selected: true,
  242. advancedQueryStatus: false,
  243. advancedQueryText: '高级查询',
  244. formInline: {
  245. region: ''
  246. },
  247. tableData: [],
  248. rowStyle: {
  249. background: '#f8f9fa',
  250. fontSize: '12px'
  251. },
  252. multipleSelection: [],
  253. currentPage: 1,
  254. batch: true,
  255. pageTotal: 0,
  256. pageSize: 10,
  257. roomData: [],
  258. checkNodeId: '',
  259. selectRow: [],
  260. userInfo: {
  261. type: ''
  262. }
  263. };
  264. },
  265. created: function created() {
  266. this.userInfo = JSON.parse(localStorage.getItem('info'));
  267. this.selectoption = JSON.parse(localStorage.getItem('selectoption'));
  268. this.selectoptionValue = localStorage.getItem('tenantId');
  269. this.getReportList();
  270. this.getlist();
  271. },
  272. mounted: function mounted() {},
  273. computed: {},
  274. methods: {
  275. selectTenantId: function selectTenantId(e) {
  276. localStorage.setItem('tenantId', e);
  277. this.reload();
  278. },
  279. exportFun: function exportFun() {
  280. var q = this.yz(this.searchForm);
  281. var data = {
  282. fileName: "报警记录",
  283. q: stringify_default()(q)
  284. };
  285. Object(api["b" /* downloadPost */])(data, this.$api.deviceReport).then(function (res) {
  286. var link = document.createElement("a");
  287. var blob = new Blob([res], {
  288. type: "application/vnd.ms-excel"
  289. });
  290. var objectUrl = URL.createObjectURL(blob);
  291. link.href = objectUrl;
  292. link.download = "报警记录.xlsx";
  293. link.click();
  294. URL.revokeObjectURL(objectUrl);
  295. });
  296. },
  297. // 选择房源
  298. checkNode: function checkNode(e) {
  299. this.checkNodeId = e;
  300. // var str=this.getCascaderObj([e[e.length-1]],this.roomData)
  301. // console.log(str)
  302. var selectRow = [];
  303. // this.roomData.map((li,index)=>{
  304. // if(li.id==e[0]){
  305. // selectRow=li
  306. // }
  307. // })
  308. selectRow = this.getChild(this.roomData, e[e.length - 1], []);
  309. // console.log(arr)
  310. // this.selectRow=selectRow
  311. this.searchForm.siteIds = selectRow;
  312. },
  313. getChild: function getChild(nodes, item, arr) {
  314. var _iteratorNormalCompletion = true;
  315. var _didIteratorError = false;
  316. var _iteratorError = undefined;
  317. try {
  318. for (var _iterator = get_iterator_default()(nodes), _step; !(_iteratorNormalCompletion = (_step = _iterator.next()).done); _iteratorNormalCompletion = true) {
  319. var el = _step.value;
  320. if (el.id === item) {
  321. arr.push(el.id);
  322. if (el.children) {
  323. this.childNodesDeep(el.children, arr);
  324. }
  325. } else if (el.children) {
  326. this.getChild(el.children, item, arr);
  327. }
  328. }
  329. } catch (err) {
  330. _didIteratorError = true;
  331. _iteratorError = err;
  332. } finally {
  333. try {
  334. if (!_iteratorNormalCompletion && _iterator.return) {
  335. _iterator.return();
  336. }
  337. } finally {
  338. if (_didIteratorError) {
  339. throw _iteratorError;
  340. }
  341. }
  342. }
  343. return arr;
  344. },
  345. childNodesDeep: function childNodesDeep(nodes, arr) {
  346. var _this = this;
  347. if (nodes) nodes.forEach(function (ele) {
  348. arr.push(ele.id);
  349. if (ele.children) {
  350. _this.childNodesDeep(ele.children, arr);
  351. }
  352. });
  353. },
  354. getCascaderObj: function getCascaderObj(val, opt) {
  355. return val.map(function (value, index, array) {
  356. var _iteratorNormalCompletion2 = true;
  357. var _didIteratorError2 = false;
  358. var _iteratorError2 = undefined;
  359. try {
  360. for (var _iterator2 = get_iterator_default()(opt), _step2; !(_iteratorNormalCompletion2 = (_step2 = _iterator2.next()).done); _iteratorNormalCompletion2 = true) {
  361. var itm = _step2.value;
  362. if (itm.value == value) {
  363. opt = itm.children;
  364. return itm;
  365. }
  366. }
  367. } catch (err) {
  368. _didIteratorError2 = true;
  369. _iteratorError2 = err;
  370. } finally {
  371. try {
  372. if (!_iteratorNormalCompletion2 && _iterator2.return) {
  373. _iterator2.return();
  374. }
  375. } finally {
  376. if (_didIteratorError2) {
  377. throw _iteratorError2;
  378. }
  379. }
  380. }
  381. return null;
  382. });
  383. },
  384. // 获取列表
  385. getlist: function getlist() {
  386. var _this2 = this;
  387. var data = {};
  388. Object(api["d" /* httpGet */])(data, this.$api.getPlaceList).then(function (res) {
  389. if (res.data.list.length > 0) {
  390. var arrdata = Object(utils["n" /* uniqueArray */])(res.data.list, "id");
  391. _this2.roomData = Object(utils["p" /* ztreeToElementTree */])(arrdata, {});
  392. }
  393. });
  394. },
  395. reset: function reset() {
  396. this.searchForm = {
  397. operateCode: '',
  398. roomName: '',
  399. time: '',
  400. name: "",
  401. deviceNum: '',
  402. siteIds: '',
  403. startBattery: '',
  404. endBattery: '',
  405. startTime: '',
  406. endTime: ''
  407. };
  408. },
  409. yz: function yz(obj) {
  410. var str = {};
  411. keys_default()(obj).forEach(function (key) {
  412. if (obj[key] != '' && key != 'roomName' && key != 'time') {
  413. str[key] = obj[key];
  414. }
  415. });
  416. return str;
  417. },
  418. getReportList: function getReportList() {
  419. var _this3 = this;
  420. var q = this.yz(this.searchForm);
  421. var data = {
  422. pageNum: this.currentPage,
  423. pageSize: this.pageSize,
  424. orderType: 'desc',
  425. orderBy: "createAt",
  426. q: stringify_default()(q)
  427. };
  428. Object(api["g" /* httpPost */])(data, this.$api.getReportList).then(function (res) {
  429. if (res.success) {
  430. res.data.list.map(function (li) {
  431. li.createAt = moment_default()(li.createAt).format('YYYY/MM/DD HH:mm:ss');
  432. });
  433. _this3.tableData = res.data.list;
  434. _this3.pageTotal = res.data.total;
  435. } else {
  436. _this3.$message.console.error("查询失败");
  437. }
  438. });
  439. },
  440. // 未处理记录打开
  441. recordFun: function recordFun() {
  442. this.dialogVisible1 = true;
  443. },
  444. // 未处理记录处理关闭
  445. handleClose1: function handleClose1(done) {
  446. done();
  447. },
  448. // 批量处理关闭
  449. handleClose: function handleClose(done) {
  450. done();
  451. },
  452. // 批量处理
  453. batchProcessing: function batchProcessing() {
  454. this.dialogVisible = true;
  455. },
  456. // 分页
  457. handleSizeChange: function handleSizeChange(val) {
  458. this.pageSize = val;
  459. this.getReportList();
  460. console.log("\u6BCF\u9875 " + val + " \u6761");
  461. },
  462. handleCurrentChange: function handleCurrentChange(val) {
  463. this.currentPage = val;
  464. this.getReportList();
  465. console.log("\u5F53\u524D\u9875: " + val);
  466. },
  467. // 表头样式
  468. rowClass: function rowClass(_ref) {
  469. var row = _ref.row,
  470. rowIndex = _ref.rowIndex;
  471. return "background:#f8f9fa;color:#333;font-blod:none;font-size:12px;";
  472. },
  473. // 表格勾选
  474. handleSelectionChange: function handleSelectionChange(val) {
  475. if (val.length > 0) {
  476. this.batch = false;
  477. } else {
  478. this.batch = true;
  479. }
  480. },
  481. // 高级查询显示
  482. advancedQueryFun: function advancedQueryFun() {
  483. if (this.advancedQueryStatus) {
  484. this.advancedQueryText = "高级查询";
  485. this.advancedQueryStatus = false;
  486. } else {
  487. this.advancedQueryText = "同用查询";
  488. this.advancedQueryStatus = true;
  489. }
  490. },
  491. // 批量处理备注监控
  492. textareaFun: function textareaFun(e) {
  493. this.textarea = e;
  494. },
  495. // 输入监控
  496. InputFun: function InputFun(e, name) {
  497. if (name == 'startBattery' || name == 'endBattery') {
  498. if (Number(e) < 0) {
  499. e = 0;
  500. }
  501. if (Number(e) > 100) {
  502. e = 100;
  503. }
  504. }
  505. if (name == "time") {
  506. this.searchForm.startTime = moment_default()(e[0]).format('YYYY-MM-DD HH:mm:ss');
  507. this.searchForm.endTime = moment_default()(e[1]).format('YYYY-MM-DD HH:mm:ss');
  508. }
  509. this.searchForm[name] = e;
  510. },
  511. // 单个/多个查询切换
  512. switchFun: function switchFun() {
  513. this.selected = !this.selected;
  514. }
  515. }
  516. });
  517. // CONCATENATED MODULE: ./node_modules/vue-loader/lib/template-compiler?{"id":"data-v-e0592f90","hasScoped":true,"transformToRequire":{"video":["src","poster"],"source":"src","img":"src","image":"xlink:href"},"buble":{"transforms":{}}}!./node_modules/vue-loader/lib/selector.js?type=template&index=0!./src/views/doorMagnetism/alarmRecord.vue
  518. var render = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('div',{attrs:{"id":"container"}},[_c('div',{staticClass:"alarmrecord"},[_c('el-card',{staticClass:"box-card"},[_c('el-row',{},[_c('div',{staticClass:"search"},[_c('div',{staticClass:"inputInline"},[(_vm.userInfo.type==0)?_c('el-select',{staticClass:"w150",staticStyle:{"width":"1.5rem"},attrs:{"size":"mini","placeholder":"请选择数据中心"},on:{"change":_vm.selectTenantId},model:{value:(_vm.selectoptionValue),callback:function ($$v) {_vm.selectoptionValue=$$v},expression:"selectoptionValue"}},_vm._l((_vm.selectoption),function(item){return _c('el-option',{key:item.value,attrs:{"label":item.label,"value":item.value}})}),1):_vm._e(),_vm._v(" "),_c('el-cascader',{staticClass:"w150",attrs:{"options":_vm.roomData,"popper-class":"cascadername","props":{ checkStrictly: true },"clearable":"","size":"mini"},on:{"change":_vm.checkNode},model:{value:(_vm.searchForm.roomName),callback:function ($$v) {_vm.$set(_vm.searchForm, "roomName", $$v)},expression:"searchForm.roomName"}}),_vm._v(" "),_c('el-input',{staticClass:"w150",attrs:{"clearable":true,"placeholder":"设备名称","size":"mini"},on:{"input":function($event){return _vm.InputFun($event,'deviceNum')}},model:{value:(_vm.searchForm.deviceNum),callback:function ($$v) {_vm.$set(_vm.searchForm, "deviceNum", $$v)},expression:"searchForm.deviceNum"}}),_vm._v(" "),_c('el-input',{staticClass:"w150",attrs:{"clearable":true,"placeholder":"IMEI","size":"mini"},on:{"input":function($event){return _vm.InputFun($event,'imei')}},model:{value:(_vm.searchForm.imei),callback:function ($$v) {_vm.$set(_vm.searchForm, "imei", $$v)},expression:"searchForm.imei"}}),_vm._v(" "),_c('el-date-picker',{staticClass:"w250",attrs:{"size":"mini","type":"datetimerange","range-separator":"至","start-placeholder":"开始日期","end-placeholder":"结束日期"},on:{"input":function($event){return _vm.InputFun($event,'time')}},model:{value:(_vm.searchForm.time),callback:function ($$v) {_vm.$set(_vm.searchForm, "time", $$v)},expression:"searchForm.time"}}),_vm._v(" "),_c('div',{staticClass:"quantity"},[_vm._v("\n 电量: "),_c('el-input',{staticClass:"w50",attrs:{"placeholder":"","clearable":"","size":"mini"},on:{"input":function($event){return _vm.InputFun($event,'startBattery')}},model:{value:(_vm.searchForm.startBattery),callback:function ($$v) {_vm.$set(_vm.searchForm, "startBattery", $$v)},expression:"searchForm.startBattery"}},[_c('template',{slot:"append"},[_vm._v("%")])],2),_vm._v(" - "),_c('el-input',{staticClass:"w50",attrs:{"placeholder":"","clearable":"","size":"mini"},on:{"input":function($event){return _vm.InputFun($event,'endBattery')}},model:{value:(_vm.searchForm.endBattery),callback:function ($$v) {_vm.$set(_vm.searchForm, "endBattery", $$v)},expression:"searchForm.endBattery"}},[_c('template',{slot:"append"},[_vm._v("%")])],2)],1),_vm._v(" "),_c('div',{staticClass:"quantity"},[_c('el-select',{staticClass:"w150",attrs:{"clearable":"","placeholder":"报警类型","size":"mini"},on:{"input":function($event){return _vm.InputFun($event,'operateCode')}},model:{value:(_vm.searchForm.operateCode),callback:function ($$v) {_vm.$set(_vm.searchForm, "operateCode", $$v)},expression:"searchForm.operateCode"}},_vm._l((_vm.alertType),function(item){return _c('el-option',{key:item.value,attrs:{"label":item.label,"value":item.value}})}),1)],1)],1),_vm._v(" "),_c('el-button',{attrs:{"size":"mini"},on:{"click":_vm.reset}},[_vm._v("重置")]),_vm._v(" "),_c('el-button',{attrs:{"type":"primary","size":"mini"},on:{"click":_vm.getReportList}},[_vm._v("查询")])],1)]),_vm._v(" "),_c('el-row',{staticClass:"marginTop"},[_c('div',{staticClass:"tablecell"},[_c('el-row',{staticClass:"floatRight"},[_c('el-button',{attrs:{"type":"primary","size":"mini"},on:{"click":_vm.exportFun}},[_vm._v("导出")])],1),_vm._v(" "),_c('el-table',{ref:"multipleTable",staticStyle:{"width":"100%"},attrs:{"data":_vm.tableData,"border":true,"tooltip-effect":"dark","header-cell-style":_vm.rowClass,"cell-style":{fontSize:'12px
  519. var staticRenderFns = []
  520. var esExports = { render: render, staticRenderFns: staticRenderFns }
  521. /* harmony default export */ var doorMagnetism_alarmRecord = (esExports);
  522. // CONCATENATED MODULE: ./src/views/doorMagnetism/alarmRecord.vue
  523. function injectStyle (ssrContext) {
  524. __webpack_require__("DWzc")
  525. }
  526. var normalizeComponent = __webpack_require__("VU/8")
  527. /* script */
  528. /* template */
  529. /* template functional */
  530. var __vue_template_functional__ = false
  531. /* styles */
  532. var __vue_styles__ = injectStyle
  533. /* scopeId */
  534. var __vue_scopeId__ = "data-v-e0592f90"
  535. /* moduleIdentifier (server only) */
  536. var __vue_module_identifier__ = null
  537. var Component = normalizeComponent(
  538. alarmRecord,
  539. doorMagnetism_alarmRecord,
  540. __vue_template_functional__,
  541. __vue_styles__,
  542. __vue_scopeId__,
  543. __vue_module_identifier__
  544. )
  545. /* harmony default export */ var views_doorMagnetism_alarmRecord = __webpack_exports__["default"] = (Component.exports);
  546. /***/ })
  547. });