完成签约之后直接添加人员,录入下发凭证
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.

421 lines
13 KiB

  1. webpackJsonp([62],{
  2. /***/ "KhRE":
  3. /***/ (function(module, exports) {
  4. // removed by extract-text-webpack-plugin
  5. /***/ }),
  6. /***/ "eV9u":
  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/json/stringify.js
  11. var stringify = __webpack_require__("mvHQ");
  12. var stringify_default = /*#__PURE__*/__webpack_require__.n(stringify);
  13. // EXTERNAL MODULE: ./src/api/index.js + 5 modules
  14. var api = __webpack_require__("gyMJ");
  15. // EXTERNAL MODULE: ./src/utils/index.js
  16. var utils = __webpack_require__("0xDb");
  17. // EXTERNAL MODULE: ./node_modules/moment/moment.js
  18. var moment = __webpack_require__("PJh5");
  19. var moment_default = /*#__PURE__*/__webpack_require__.n(moment);
  20. // CONCATENATED MODULE: ./node_modules/babel-loader/lib!./node_modules/vue-loader/lib/selector.js?type=script&index=0!./src/views/log/smokeLog.vue
  21. //
  22. //
  23. //
  24. //
  25. //
  26. //
  27. //
  28. //
  29. //
  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. /* harmony default export */ var smokeLog = ({
  55. name: "warningLog",
  56. data: function data() {
  57. return {
  58. query: {
  59. operType: "",
  60. operateName: "",
  61. operModul: ""
  62. },
  63. query1: {
  64. operType: "",
  65. operateName: "",
  66. operModul: ""
  67. },
  68. activeName: "first",
  69. tableData: [],
  70. tableData1: [],
  71. multipleSelection: [],
  72. delList: [],
  73. editVisible: false,
  74. pageTotal: 0,
  75. pageTotal1: 0,
  76. form: {},
  77. idx: -1,
  78. id: -1,
  79. AboutDevice: [],
  80. userInfo: {
  81. type: ''
  82. },
  83. alertTypeList: []
  84. };
  85. },
  86. props: ['deviceNum'],
  87. beforeCreate: function beforeCreate() {},
  88. created: function created() {
  89. this.alertTypeList = this.$MANUFACTURER.alertType.smokeSensationLog;
  90. this.userInfo = JSON.parse(localStorage.getItem('info'));
  91. this.getAboutDevice();
  92. },
  93. mounted: function mounted() {},
  94. methods: {
  95. selectTenantId: function selectTenantId(e) {
  96. localStorage.setItem('tenantId', e);
  97. this.reload();
  98. },
  99. restFun: function restFun() {
  100. var _this = this;
  101. this.query = {
  102. operType: "",
  103. operateName: "",
  104. operModul: ""
  105. };
  106. var q = {};
  107. if (this.deviceNum != '') {
  108. q = {
  109. alertType: this.query.alertType,
  110. deviceNum: this.deviceNum,
  111. deviceType: 4
  112. };
  113. } else {
  114. q = {
  115. alertType: this.query.alertType,
  116. deviceNum: this.query.deviceName,
  117. deviceType: 4
  118. };
  119. }
  120. var data = {
  121. pageNum: 1,
  122. pageSize: 10,
  123. q: this.searchParaProcess(q),
  124. orderBy: "alert_time desc"
  125. };
  126. Object(api["d" /* httpGet */])(data, this.$api.getLockAlert).then(function (res) {
  127. var AboutDevice = _this.AboutDevice;
  128. res.data.list.map(function (li) {
  129. li.createAt = _this.time(+new Date(li.createAt));
  130. li.alertTime = moment_default()(li.alertTime * 1000).format("YYYY-MM-DD HH:mm:ss");
  131. var resultArr = AboutDevice.filter(function (_item) {
  132. return _item.deviceNum == li.deviceNum;
  133. })[0];
  134. if (resultArr) {
  135. li.roomId = resultArr.id;
  136. li.roomName = resultArr.roomName;
  137. }
  138. li['alertTypeDesc'] = '';
  139. var alertTypeDesc = _this.alertTypeList.filter(function (item) {
  140. return item.code == li.alertType;
  141. })[0];
  142. if (alertTypeDesc) {
  143. li['alertTypeDesc'] = alertTypeDesc.desc;
  144. }
  145. });
  146. _this.$store.commit('increment', 1);
  147. _this.tableData = res.data.list;
  148. _this.pageTotal = res.data.total;
  149. });
  150. },
  151. // 查询和房间相关的设备
  152. getAboutDevice: function getAboutDevice() {
  153. var _this2 = this;
  154. var data = {
  155. pageNum: 0,
  156. pageSize: 0,
  157. q: stringify_default()({
  158. lockType: 4
  159. })
  160. };
  161. Object(api["g" /* httpPost */])(data, this.$api.getDeviceItems).then(function (res) {
  162. _this2.AboutDevice = res.data.list;
  163. _this2.getOperates();
  164. });
  165. },
  166. time: function time() {
  167. var time = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : +new Date();
  168. var date = new Date(time + 8 * 3600 * 1000); // 增加8小时
  169. return date.toJSON().substr(0, 19).replace("T", " ");
  170. },
  171. // 获取操作日志
  172. getOperates: function getOperates() {
  173. var _this3 = this;
  174. var q = {};
  175. if (this.deviceNum != '') {
  176. q = {
  177. alertType: this.query.alertType,
  178. deviceNum: this.deviceNum,
  179. deviceType: 4
  180. };
  181. } else {
  182. q = {
  183. alertType: this.query.alertType,
  184. deviceNum: this.query.deviceName,
  185. deviceType: 4
  186. };
  187. }
  188. var data = {
  189. pageNum: 1,
  190. pageSize: 10,
  191. orderBy: "alert_time desc",
  192. q: stringify_default()(q)
  193. // orderType:"desc"
  194. };
  195. Object(api["d" /* httpGet */])(data, this.$api.getLockAlert).then(function (res) {
  196. var AboutDevice = _this3.AboutDevice;
  197. res.data.list.map(function (li) {
  198. li.createAt = _this3.time(+new Date(li.createAt));
  199. li.alertTime = moment_default()(li.alertTime * 1000).format("YYYY-MM-DD HH:mm:ss");
  200. var resultArr = AboutDevice.filter(function (_item) {
  201. return _item.deviceNum == li.deviceNum;
  202. })[0];
  203. if (resultArr) {
  204. li.roomId = resultArr.id;
  205. li.roomName = resultArr.roomName;
  206. }
  207. li['alertTypeDesc'] = '';
  208. var alertTypeDesc = _this3.alertTypeList.filter(function (item) {
  209. return item.code == li.alertType;
  210. })[0];
  211. if (alertTypeDesc) {
  212. li['alertTypeDesc'] = alertTypeDesc.desc;
  213. }
  214. });
  215. _this3.tableData = res.data.list;
  216. _this3.pageTotal = res.data.total;
  217. });
  218. },
  219. //门锁报警同步刷新
  220. getlockAlert: function getlockAlert() {
  221. Object(api["d" /* httpGet */])("", this.$api.getLockAlert1).then(function (res) {});
  222. },
  223. searchParaProcess: function searchParaProcess(obj) {
  224. var myObj;
  225. if (obj.alertType == "" || obj.alertType == "0") {
  226. if (obj.deviceNum == "") {
  227. myObj = {
  228. deviceType: obj.deviceType
  229. };
  230. } else {
  231. myObj = {
  232. deviceNum: obj.deviceNum,
  233. deviceType: obj.deviceType
  234. };
  235. }
  236. } else {
  237. if (obj.deviceNum == "") {
  238. myObj = {
  239. alertType: obj.alertType,
  240. deviceType: obj.deviceType
  241. };
  242. } else {
  243. myObj = {
  244. alertType: obj.alertType,
  245. deviceNum: obj.deviceNum,
  246. deviceType: obj.deviceType
  247. };
  248. }
  249. }
  250. return stringify_default()(myObj);
  251. },
  252. // 触发搜索按钮
  253. handleSearch: function handleSearch() {
  254. var _this4 = this;
  255. this.getlockAlert();
  256. var q = {};
  257. if (this.deviceNum != '') {
  258. q = {
  259. alertType: this.query.alertType,
  260. deviceNum: this.deviceNum,
  261. deviceType: 4
  262. };
  263. } else {
  264. q = {
  265. alertType: this.query.alertType,
  266. deviceNum: this.query.deviceName,
  267. deviceType: 4
  268. };
  269. }
  270. var data = {
  271. pageNum: 1,
  272. pageSize: 10,
  273. q: this.searchParaProcess(q),
  274. orderBy: "alert_time desc"
  275. };
  276. Object(api["d" /* httpGet */])(data, this.$api.getLockAlert).then(function (res) {
  277. var AboutDevice = _this4.AboutDevice;
  278. res.data.list.map(function (li) {
  279. li.createAt = _this4.time(+new Date(li.createAt));
  280. li.alertTime = moment_default()(li.alertTime * 1000).format("YYYY-MM-DD HH:mm:ss");
  281. var resultArr = AboutDevice.filter(function (_item) {
  282. return _item.deviceNum == li.deviceNum;
  283. })[0];
  284. if (resultArr) {
  285. li.roomId = resultArr.id;
  286. li.roomName = resultArr.roomName;
  287. }
  288. li['alertTypeDesc'] = '';
  289. var alertTypeDesc = _this4.alertTypeList.filter(function (item) {
  290. return item.code == li.alertType;
  291. })[0];
  292. if (alertTypeDesc) {
  293. li['alertTypeDesc'] = alertTypeDesc.desc;
  294. }
  295. });
  296. _this4.$store.commit('increment', 1);
  297. _this4.tableData = res.data.list;
  298. _this4.pageTotal = res.data.total;
  299. });
  300. // this.$set(this.query, "pageIndex", 1);
  301. },
  302. // 分页导航
  303. handlePageChange: function handlePageChange(val) {
  304. var _this5 = this;
  305. this.$store.commit('increment', val);
  306. var q = {};
  307. if (this.deviceNum != '') {
  308. q = {
  309. alertType: this.query.alertType,
  310. deviceNum: this.deviceNum,
  311. deviceType: 4
  312. };
  313. } else {
  314. q = {
  315. alertType: this.query.alertType,
  316. deviceNum: this.query.deviceName,
  317. deviceType: 4
  318. };
  319. }
  320. var data = {
  321. pageNum: val,
  322. pageSize: 10,
  323. q: this.searchParaProcess(q),
  324. orderBy: "alert_time desc"
  325. };
  326. Object(api["d" /* httpGet */])(data, this.$api.getLockAlert).then(function (res) {
  327. var AboutDevice = _this5.AboutDevice;
  328. res.data.list.map(function (li) {
  329. li.createAt = _this5.time(+new Date(li.createAt));
  330. li.alertTime = moment_default()(li.alertTime * 1000).format("YYYY-MM-DD HH:mm:ss");
  331. var resultArr = AboutDevice.filter(function (_item) {
  332. return _item.deviceNum == li.deviceNum;
  333. })[0];
  334. if (resultArr) {
  335. li.roomId = resultArr.id;
  336. li.roomName = resultArr.roomName;
  337. }
  338. li['alertTypeDesc'] = '';
  339. var alertTypeDesc = _this5.alertTypeList.filter(function (item) {
  340. return item.code == li.alertType;
  341. })[0];
  342. if (alertTypeDesc) {
  343. li['alertTypeDesc'] = alertTypeDesc.desc;
  344. }
  345. });
  346. _this5.tableData = res.data.list;
  347. _this5.pageTotal = res.data.total;
  348. });
  349. }
  350. }
  351. });
  352. // CONCATENATED MODULE: ./node_modules/vue-loader/lib/template-compiler?{"id":"data-v-65305c34","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/log/smokeLog.vue
  353. var render = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('div',[_c('div',{staticClass:"container"},[_c('div',{staticClass:"handle-box"},[_c('selectoption'),_vm._v(" "),_c('el-input',{staticClass:"handle-input mr10",attrs:{"size":"small","placeholder":"设备号","clearable":true},model:{value:(_vm.query.deviceName),callback:function ($$v) {_vm.$set(_vm.query, "deviceName", $$v)},expression:"query.deviceName"}}),_vm._v(" "),_c('el-select',{staticClass:"handle-select mr10",attrs:{"size":"small","clearable":true,"placeholder":"报警类型"},model:{value:(_vm.query.alertType),callback:function ($$v) {_vm.$set(_vm.query, "alertType", $$v)},expression:"query.alertType"}},_vm._l((_vm.alertTypeList),function(item){return _c('el-option',{key:item.code,attrs:{"label":item.desc,"value":item.code}})}),1),_vm._v(" "),_c('el-button',{attrs:{"type":"primary","size":"small","icon":"el-icon-search"},on:{"click":_vm.handleSearch}},[_vm._v("搜索")]),_vm._v(" "),_c('el-button',{attrs:{"type":"primary","size":"small","icon":"el-icon-search"},on:{"click":_vm.restFun}},[_vm._v("重置")])],1),_vm._v(" "),_c('el-table',{ref:"multipleTable",staticClass:"table",attrs:{"data":_vm.tableData,"border":"","header-cell-class-name":"table-header"}},[_c('el-table-column',{attrs:{"prop":"id","label":"ID"}}),_vm._v(" "),_c('el-table-column',{attrs:{"prop":"deviceNum","label":"设备号"}}),_vm._v(" "),_c('el-table-column',{attrs:{"prop":"roomName","label":"房间名称"}}),_vm._v(" "),_c('el-table-column',{attrs:{"prop":"alertTime","label":"报警时间"}}),_vm._v(" "),_c('el-table-column',{attrs:{"label":"报警类型"},scopedSlots:_vm._u([{key:"default",fn:function(scope){return [_c('span',[_vm._v(_vm._s(scope.row.alertTypeDesc))])]}}])})],1),_vm._v(" "),_c('div',{staticClass:"pagination"},[_c('el-pagination',{attrs:{"background":"","layout":"total, prev, pager, next","current-page":_vm.$store.state.currentPage,"page-size":10,"total":_vm.pageTotal},on:{"current-change":_vm.handlePageChange}})],1)],1)])}
  354. var staticRenderFns = []
  355. var esExports = { render: render, staticRenderFns: staticRenderFns }
  356. /* harmony default export */ var log_smokeLog = (esExports);
  357. // CONCATENATED MODULE: ./src/views/log/smokeLog.vue
  358. function injectStyle (ssrContext) {
  359. __webpack_require__("KhRE")
  360. }
  361. var normalizeComponent = __webpack_require__("VU/8")
  362. /* script */
  363. /* template */
  364. /* template functional */
  365. var __vue_template_functional__ = false
  366. /* styles */
  367. var __vue_styles__ = injectStyle
  368. /* scopeId */
  369. var __vue_scopeId__ = "data-v-65305c34"
  370. /* moduleIdentifier (server only) */
  371. var __vue_module_identifier__ = null
  372. var Component = normalizeComponent(
  373. smokeLog,
  374. log_smokeLog,
  375. __vue_template_functional__,
  376. __vue_styles__,
  377. __vue_scopeId__,
  378. __vue_module_identifier__
  379. )
  380. /* harmony default export */ var views_log_smokeLog = __webpack_exports__["default"] = (Component.exports);
  381. /***/ })
  382. });