{"remainingRequest":"D:\\jenkins\\workspace\\bzzgj-fvue\\node_modules\\thread-loader\\dist\\cjs.js!D:\\jenkins\\workspace\\bzzgj-fvue\\node_modules\\babel-loader\\lib\\index.js!D:\\jenkins\\workspace\\bzzgj-fvue\\node_modules\\cache-loader\\dist\\cjs.js??ref--0-0!D:\\jenkins\\workspace\\bzzgj-fvue\\node_modules\\vue-loader\\lib\\index.js??vue-loader-options!D:\\jenkins\\workspace\\bzzgj-fvue\\src\\views\\Device\\deviceManage\\components\\modle\\WaterRealDataModel.vue?vue&type=script&lang=js&","dependencies":[{"path":"D:\\jenkins\\workspace\\bzzgj-fvue\\src\\views\\Device\\deviceManage\\components\\modle\\WaterRealDataModel.vue","mtime":1687914898329},{"path":"D:\\jenkins\\workspace\\bzzgj-fvue\\node_modules\\cache-loader\\dist\\cjs.js","mtime":499162500000},{"path":"D:\\jenkins\\workspace\\bzzgj-fvue\\node_modules\\thread-loader\\dist\\cjs.js","mtime":499162500000},{"path":"D:\\jenkins\\workspace\\bzzgj-fvue\\node_modules\\babel-loader\\lib\\index.js","mtime":315532800000},{"path":"D:\\jenkins\\workspace\\bzzgj-fvue\\node_modules\\cache-loader\\dist\\cjs.js","mtime":499162500000},{"path":"D:\\jenkins\\workspace\\bzzgj-fvue\\node_modules\\vue-loader\\lib\\index.js","mtime":499162500000}],"contextDependencies":[],"result":["import \"core-js/modules/es6.function.name\";\nimport \"core-js/modules/web.dom.iterable\";\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\nimport req from '@/request.js';\nimport { TableMixin } from '@/mixins/tableMixin';\nimport equipmentManage from '@/api/device/equipmentManage.js';\nimport productManage from '@/api/device/productManage.js';\nimport dictUtils from '@/components/dict/DictSelectUtils.js';\nexport default {\n name: 'RealTimeData',\n mixins: [TableMixin],\n props: {\n parameter: {\n type: Object,\n default: function _default() {\n return;\n }\n }\n },\n data: function data() {\n return {\n productParams: {},\n productType: {},\n realData: [],\n productTypelx: '',\n dataTypeList: [],\n //数据类型字典\n actionList: [],\n //动作标识字典\n statusList: [],\n //成功状态字典\n querys: [{\n group: 'main',\n operation: 'BETWEEN',\n parentGroup: '',\n property: 'b.coll_time_',\n relation: 'AND',\n value: ''\n }],\n sorter: [{\n direction: 'DESC',\n property: 'collTime'\n }]\n };\n },\n created: function created() {\n console.log(this.parameter);\n this.dataTypeList = dictUtils.getDictItemsFromCache('sjlx');\n this.actionList = dictUtils.getDictItemsFromCache('dzbs');\n this.statusList = dictUtils.getDictItemsFromCache('cgzt');\n this.getProduct();\n },\n mounted: function mounted() {},\n methods: {\n handleUpdate: function handleUpdate(row) {\n console.log(row);\n },\n // 重置\n clearQuerys: function clearQuerys() {\n this.querys[0].value = '';\n },\n getProduct: function getProduct() {\n var _this = this;\n\n productManage.productInfoDetail(this.parameter.productId).then(function (res) {\n _this.productParams = res;\n productManage.productTypeDetail(_this.productParams.typeId).then(function (res) {\n _this.productType = res; // this.loadData()\n });\n });\n },\n loadData: function loadData(page) {\n var _this2 = this;\n\n if (page) {\n this.queryParam.pageBean.page = page;\n }\n\n this.loading = true;\n this.tableData = [];\n this.queryParam.querys = [];\n this.queryParam = Object.assign(this.queryParam, {\n sorter: this.sorter\n });\n\n if (this.querys[0].value) {\n this.queryParam.querys.push(this.querys[0]);\n }\n\n var protal = window.context.portal;\n var requestData = {\n url: \"\".concat(protal, \"/device/data/query?id=\") + this.parameter.id,\n data: this.queryParam,\n method: 'post'\n }; // 根据设备id获取实时数据\n\n req.request(requestData).then(function (res) {\n console.log(res);\n\n if (res.status) {\n _this2.productTypelx = res.data.value.productType;\n _this2.tableData = res.data.value.data.rows;\n _this2.total = res.data.value.data.total;\n\n _this2.$set(_this2.tableData);\n\n _this2.loading = false;\n\n _this2.tableData.forEach(function (item) {\n _this2.dataTypeList.forEach(function (val) {\n if (item.dataType && item.dataType == val.value) {\n item['dataType'] = val.name;\n }\n });\n\n _this2.actionList.forEach(function (val) {\n if (item.action && item.action == val.value) {\n item['action'] = val.name;\n }\n });\n\n _this2.statusList.forEach(function (val) {\n if (item.status && item.status == val.value) {\n item['status'] = val.name;\n }\n });\n });\n }\n }).catch(function (err) {\n console.log(err);\n });\n }\n }\n};",null]}