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

424 lines
12 KiB

  1. webpackJsonp([70],{
  2. /***/ "BHWL":
  3. /***/ (function(module, __webpack_exports__, __webpack_require__) {
  4. "use strict";
  5. Object.defineProperty(__webpack_exports__, "__esModule", { value: true });
  6. // EXTERNAL MODULE: ./src/api/allFun.js
  7. var allFun = __webpack_require__("mprh");
  8. // EXTERNAL MODULE: ./src/common/echart/index.vue + 4 modules
  9. var echart = __webpack_require__("C3+4");
  10. // EXTERNAL MODULE: ./src/components/scrolllist/index.vue + 2 modules
  11. var scrolllist = __webpack_require__("Lbay");
  12. // CONCATENATED MODULE: ./node_modules/babel-loader/lib!./node_modules/vue-loader/lib/selector.js?type=script&index=0!./src/views/presentationPage/smokeSensationDeviceHomePage.vue
  13. //
  14. //
  15. //
  16. //
  17. //
  18. //
  19. //
  20. //
  21. //
  22. //
  23. //
  24. //
  25. //
  26. //
  27. //
  28. //
  29. //
  30. //
  31. //
  32. //
  33. //
  34. //
  35. //
  36. //
  37. //
  38. //
  39. //
  40. //
  41. //
  42. //
  43. //
  44. // import Schart from "vue-schart";
  45. // import scrollvue from "../components/scrollvue"
  46. /* harmony default export */ var smokeSensationDeviceHomePage = ({
  47. name: "dashboard",
  48. data: function data() {
  49. return {
  50. statisticalParameters: [{
  51. title: '设备总数',
  52. num: '0',
  53. company: '个'
  54. }, {
  55. title: '在线设备',
  56. num: '0',
  57. company: '个'
  58. }, {
  59. title: '离线设备',
  60. num: '0',
  61. company: '个'
  62. }, {
  63. title: '异常设备',
  64. num: '0',
  65. company: '个'
  66. }],
  67. animate: false,
  68. name: localStorage.getItem("ms_username"),
  69. options: {
  70. title: {
  71. text: '烟感报警日志'
  72. },
  73. tooltip: {
  74. trigger: 'axis'
  75. },
  76. color: ['#91cc75', '#ee6666'],
  77. legend: {
  78. data: ['', ''],
  79. textStyle: "#333"
  80. },
  81. textStyle: {
  82. color: "#333"
  83. },
  84. grid: {
  85. left: '3%',
  86. right: '4%',
  87. bottom: '3%',
  88. containLabel: true
  89. },
  90. xAxis: {
  91. type: 'category',
  92. boundaryGap: false,
  93. data: ['Mon', 'Tue', 'Wed', 'Thu', 'Fri', 'Sat', 'Sun'],
  94. axisLabel: {
  95. textStyle: {
  96. color: "#666",
  97. margin: 15
  98. }
  99. }
  100. },
  101. yAxis: {
  102. type: 'value',
  103. axisLabel: {
  104. textStyle: {
  105. color: "#666",
  106. margin: 15
  107. }
  108. }
  109. },
  110. series: [{
  111. name: '',
  112. type: 'line',
  113. // stack: 'Total',
  114. data: [0, 0, 0, 0, 0, 0, 0]
  115. }, {
  116. name: '',
  117. type: 'line',
  118. // stack: 'center',
  119. data: [0, 0, 0, 0, 0, 0, 0]
  120. }]
  121. },
  122. options2: {
  123. title: {
  124. text: '电量分布情况'
  125. },
  126. tooltip: {
  127. trigger: 'item'
  128. },
  129. legend: {
  130. top: '5%',
  131. left: 'center',
  132. textStyle: {
  133. color: "#666"
  134. }
  135. },
  136. series: [{
  137. name: '电量情况',
  138. type: 'pie',
  139. radius: ['40%', '70%'],
  140. avoidLabelOverlap: false,
  141. itemStyle: {
  142. borderRadius: 10,
  143. borderColor: '#fff',
  144. borderWidth: 2
  145. },
  146. label: {
  147. show: false,
  148. position: 'center',
  149. color: "#666"
  150. },
  151. emphasis: {
  152. label: {
  153. show: true,
  154. fontSize: '20',
  155. fontWeight: 'bold'
  156. }
  157. },
  158. labelLine: {
  159. // show: false,
  160. normal: {
  161. length: 15, // 指示线长度
  162. lineStyle: {
  163. color: "#595959" // 指示线颜色
  164. }
  165. }
  166. },
  167. data: [{
  168. value: 0,
  169. name: '0-20%'
  170. }, {
  171. value: 0,
  172. name: '20%-40%'
  173. }, {
  174. value: 0,
  175. name: '40%-60%'
  176. }, {
  177. value: 0,
  178. name: '60%-80%'
  179. }, {
  180. value: 0,
  181. name: '80%-100%'
  182. }]
  183. }]
  184. },
  185. options3: {
  186. title: {
  187. text: '设备电量统计'
  188. },
  189. tooltip: {
  190. trigger: 'axis'
  191. },
  192. color: ['#fac858', '#91cc75', '#ee6666'],
  193. legend: {
  194. data: ['OTA未升级', 'OTA已升级', '低电设备'],
  195. textStyle: "#333"
  196. },
  197. textStyle: {
  198. color: "#333"
  199. },
  200. grid: {
  201. left: '3%',
  202. right: '4%',
  203. bottom: '3%',
  204. containLabel: true
  205. },
  206. xAxis: {
  207. type: 'category',
  208. boundaryGap: false,
  209. data: ['Mon', 'Tue', 'Wed', 'Thu', 'Fri', 'Sat', 'Sun'],
  210. axisLabel: {
  211. textStyle: {
  212. color: "#666",
  213. margin: 15
  214. }
  215. }
  216. },
  217. yAxis: {
  218. type: 'value',
  219. axisLabel: {
  220. textStyle: {
  221. color: "#666",
  222. margin: 15
  223. }
  224. }
  225. },
  226. series: [{
  227. name: 'OTA未升级',
  228. type: 'line',
  229. // stack: 'center',
  230. data: [0, 0, 0, 0, 0, 0, 0]
  231. }, {
  232. name: 'OTA已升级',
  233. type: 'line',
  234. // stack: 'Total',
  235. data: [0, 0, 0, 0, 0, 0, 0]
  236. }, {
  237. name: '低电设备',
  238. type: 'line',
  239. // stack: 'bottom',
  240. data: [0, 1, 0, 0, 0, 0, 0]
  241. }]
  242. },
  243. items: [],
  244. alertTypeList: [],
  245. timersma: null
  246. };
  247. },
  248. components: {
  249. Echart: echart["a" /* default */],
  250. scrolllist: scrolllist["a" /* default */]
  251. // Schart,
  252. // scrollvue
  253. },
  254. beforeDestroy: function beforeDestroy() {
  255. window.clearInterval(this.timersma);
  256. this.timersma = null;
  257. },
  258. created: function created() {
  259. this.alertTypeList = this.$MANUFACTURER.alertType.smokeSensationLog;
  260. },
  261. mounted: function mounted() {
  262. var _this = this;
  263. this.getAnalysis();
  264. this.timersma = window.setInterval(function () {
  265. setTimeout(_this.getlog, 0);
  266. }, 4000);
  267. // setInterval(this.scroll, 1000);
  268. },
  269. methods: {
  270. getlog: function getlog() {
  271. var _this2 = this;
  272. var data = {
  273. deviceType: 4
  274. };
  275. allFun["a" /* default */].getWarningLog(data, function (callback) {
  276. if (callback.success) {
  277. callback.data.list.map(function (li, index) {
  278. li['alertTypeDesc'] = '';
  279. var alertTypeDesc = _this2.alertTypeList.filter(function (item) {
  280. return item.code == li.alertType;
  281. })[0];
  282. if (alertTypeDesc) {
  283. li['alertTypeDesc'] = alertTypeDesc.desc;
  284. } else {
  285. li['alertTypeDesc'] = '';
  286. }
  287. var resultStatus = allFun["a" /* default */].judgmentTimestamp(li.alertTime);
  288. if (resultStatus) {
  289. setTimeout(function () {
  290. _this2.$notify({
  291. title: li.alertTypeDesc,
  292. offset: 200,
  293. duration: 2000,
  294. message: li.alertTypeDesc,
  295. type: 'warning'
  296. });
  297. }, 3000);
  298. } else {}
  299. });
  300. }
  301. });
  302. },
  303. getAnalysis: function getAnalysis() {
  304. var _this3 = this;
  305. allFun["a" /* default */].getAnalysis("", 4, function (callback) {
  306. _this3.statisticalParameters[0].num = callback.total || 0;
  307. _this3.statisticalParameters[1].num = callback.onlineTotal || 0;
  308. _this3.statisticalParameters[2].num = callback.offlineTotal || 0;
  309. _this3.statisticalParameters[3].num = callback.abnormalTotal || 0;
  310. _this3.setOptionsData(callback);
  311. });
  312. allFun["a" /* default */].getAlertTypeOrder('', 4, function (callback) {
  313. if (callback.success) {
  314. if (callback.data.length > 0) {
  315. var days = allFun["a" /* default */].classification();
  316. var array = allFun["a" /* default */].groupBy(callback.data, ["code", "order"], function (cul, data) {
  317. return cul + 1;
  318. });
  319. var loopObjectData = allFun["a" /* default */].loopObject(array, _this3.alertTypeList);
  320. var legendData = [];
  321. loopObjectData.map(function (li) {
  322. legendData.push(li.name);
  323. });
  324. _this3.options.series = loopObjectData;
  325. _this3.options.legend.data = legendData;
  326. _this3.options.xAxis.data = days;
  327. }
  328. } else {
  329. _this3.$message.error(callback.message);
  330. }
  331. });
  332. },
  333. setOptionsData: function setOptionsData(data) {
  334. var options2 = this.options2;
  335. options2.series[0].data[0].value = data.batteryLevel1;
  336. options2.series[0].data[1].value = data.batteryLevel2;
  337. options2.series[0].data[2].value = data.batteryLevel3;
  338. options2.series[0].data[3].value = data.batteryLevel4;
  339. options2.series[0].data[4].value = data.batteryLevel5;
  340. },
  341. tgces: function tgces() {
  342. this.$router.push({
  343. path: "/test"
  344. });
  345. },
  346. scroll: function scroll() {
  347. var _this4 = this;
  348. this.animate = true; // 因为在消息向上滚动的时候需要添加css3过渡动画,所以这里需要设置true
  349. setTimeout(function () {
  350. // 这里直接使用了es6的箭头函数,省去了处理this指向偏移问题,代码也比之前简化了很多
  351. _this4.tableData.push(_this4.tableData[0]); // 将数组的第一个元素添加到数组的
  352. _this4.tableData.shift(); //删除数组的第一个元素
  353. _this4.animate = false; // margin-top 为0 的时候取消过渡动画,实现无缝滚动
  354. }, 500);
  355. },
  356. changeDate: function changeDate() {
  357. var now = new Date().getTime();
  358. this.data.forEach(function (item, index) {
  359. var date = new Date(now - (6 - index) * 86400000);
  360. item.name = date.getFullYear() + "/" + (date.getMonth() + 1) + "/" + date.getDate();
  361. });
  362. }
  363. }
  364. });
  365. // CONCATENATED MODULE: ./node_modules/vue-loader/lib/template-compiler?{"id":"data-v-40469840","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/presentationPage/smokeSensationDeviceHomePage.vue
  366. var render = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('div',{staticClass:"content1"},[_c('el-row',{staticClass:"elrow",attrs:{"gutter":20}},_vm._l((_vm.statisticalParameters),function(item,index){return _c('el-col',{key:index,staticClass:"mrBottom20",attrs:{"span":4}},[_c('el-card',{staticClass:"caredradious",attrs:{"shadow":"always","body-style":{padding:'0px'}}},[_c('div',{staticClass:"grid-content grid-con-1"},[_c('div',{staticClass:"colposition"},[_c('div',{staticClass:"grid-cont-right"},[_c('div',[_vm._v(_vm._s(item.title))]),_vm._v(" "),_c('div',{staticClass:"grid-num"},[_vm._v(_vm._s(item.num)+" "),_c('span',[_vm._v(_vm._s(item.company))])])])])])])],1)}),1),_vm._v(" "),_c('el-row',{staticClass:"elrow",attrs:{"gutter":20}},[_c('el-col',{attrs:{"span":12}},[_c('el-card',{attrs:{"shadow":"hover"}},[_c('Echart',{staticClass:"schart",attrs:{"options":_vm.options,"width":"100%","height":"18vw"}})],1)],1),_vm._v(" "),_c('el-col',{attrs:{"span":12}},[_c('el-card',{attrs:{"shadow":"hover"}},[_c('Echart',{staticClass:"schart",attrs:{"options":_vm.options2,"width":"100%","height":"18vw"}})],1)],1)],1)],1)}
  367. var staticRenderFns = []
  368. var esExports = { render: render, staticRenderFns: staticRenderFns }
  369. /* harmony default export */ var presentationPage_smokeSensationDeviceHomePage = (esExports);
  370. // CONCATENATED MODULE: ./src/views/presentationPage/smokeSensationDeviceHomePage.vue
  371. function injectStyle (ssrContext) {
  372. __webpack_require__("ahpT")
  373. }
  374. var normalizeComponent = __webpack_require__("VU/8")
  375. /* script */
  376. /* template */
  377. /* template functional */
  378. var __vue_template_functional__ = false
  379. /* styles */
  380. var __vue_styles__ = injectStyle
  381. /* scopeId */
  382. var __vue_scopeId__ = "data-v-40469840"
  383. /* moduleIdentifier (server only) */
  384. var __vue_module_identifier__ = null
  385. var Component = normalizeComponent(
  386. smokeSensationDeviceHomePage,
  387. presentationPage_smokeSensationDeviceHomePage,
  388. __vue_template_functional__,
  389. __vue_styles__,
  390. __vue_scopeId__,
  391. __vue_module_identifier__
  392. )
  393. /* harmony default export */ var views_presentationPage_smokeSensationDeviceHomePage = __webpack_exports__["default"] = (Component.exports);
  394. /***/ }),
  395. /***/ "ahpT":
  396. /***/ (function(module, exports) {
  397. // removed by extract-text-webpack-plugin
  398. /***/ })
  399. });