1 |
- {"remainingRequest":"/Users/caoge/Desktop/地质现场/VehicleMonitor-WEB/node_modules/vue-loader/lib/index.js??vue-loader-options!/Users/caoge/Desktop/地质现场/VehicleMonitor-WEB/src/views/simulatedUpload/index.vue?vue&type=script&lang=js","dependencies":[{"path":"/Users/caoge/Desktop/地质现场/VehicleMonitor-WEB/src/views/simulatedUpload/index.vue","mtime":1708395041889},{"path":"/Users/caoge/Desktop/地质现场/VehicleMonitor-WEB/node_modules/cache-loader/dist/cjs.js","mtime":1708395146433},{"path":"/Users/caoge/Desktop/地质现场/VehicleMonitor-WEB/node_modules/babel-loader/lib/index.js","mtime":1708395147257},{"path":"/Users/caoge/Desktop/地质现场/VehicleMonitor-WEB/node_modules/cache-loader/dist/cjs.js","mtime":1708395146433},{"path":"/Users/caoge/Desktop/地质现场/VehicleMonitor-WEB/node_modules/vue-loader/lib/index.js","mtime":1708395147382}],"contextDependencies":[],"result":[{"type":"Buffer","data":"base64:Ly8KLy8KLy8KLy8KLy8KLy8KLy8KLy8KLy8KLy8KLy8KLy8KLy8KLy8KLy8KLy8KLy8KLy8KLy8KLy8KLy8KLy8KLy8KLy8KLy8KLy8KLy8KLy8KLy8KLy8KLy8KLy8KLy8KLy8KLy8KLy8KLy8KLy8KLy8KLy8KLy8KLy8KLy8KLy8KLy8KLy8KLy8KLy8KLy8KLy8KLy8KLy8KLy8KLy8KLy8KLy8KLy8KLy8KLy8KLy8KLy8KLy8KLy8KLy8KLy8KLy8KLy8KLy8KLy8KLy8KLy8KCmltcG9ydCB7IGdldEFuYWxvZ0RhdGEgLGFkZEFsYXJtVGVtcG9yYXJ5LHNlbmRBbGFybSxlZGl0QWxhcm1UZW1wb3JhcnksZGlzYXJtaW5nQWxhcm19IGZyb20gIkAvYXBpL2FuYWxvZ0RhdGEiOwppbXBvcnQgYWRkRGlhbG9nIGZyb20gJy4vY29tcG9uZW50cy9hZGREaWFsb2cudnVlJzsKaW1wb3J0IGRldGFpbHNEaWFsb2cgZnJvbSAnLi9jb21wb25lbnRzL2RldGFpbHNEaWFsb2cudnVlJwppbXBvcnQgZWRpdERpYWxvZyBmcm9tICcuL2NvbXBvbmVudHMvZWRpdERpYWxvZy52dWUnCmltcG9ydCBkaXNhcm1pbmdBbGFybURpYWxvZyBmcm9tICcuL2NvbXBvbmVudHMvZGlzYXJtaW5nQWxhcm1EaWFsb2cudnVlJwpleHBvcnQgZGVmYXVsdCB7CiAgICBuYW1lIDonc2ltdWxhdGVkVXBsb2FkJywKICAgIGNvbXBvbmVudHM6ewogICAgICAgIGFkZERpYWxvZywKICAgICAgICBkZXRhaWxzRGlhbG9nLAogICAgICAgIGVkaXREaWFsb2csCiAgICAgICAgZGlzYXJtaW5nQWxhcm1EaWFsb2cKICAgIH0sCiAgICBkYXRhKCkgewogICAgICAgIHJldHVybiB7CiAgICAgICAgICAgIHRhYmxlRGF0YTpbXSwKICAgICAgICAgICAgc2VhcmNoRGF0YTp7CiAgICAgICAgICAgICAgICBwYWdlTnVtOiAxLAogICAgICAgICAgICAgICAgcGFnZVNpemU6IDEwLCAgICAgICAgICAgICAgICAKICAgICAgICAgICAgfSwKICAgICAgICAgICAgdG90YWw6MCwKICAgICAgICAgICAgYWRkRGlhbG9nRGF0YTp7CiAgICAgICAgICAgICAgZGlhbG9nVmlzaWJsZTogZmFsc2UsCiAgICAgICAgICAgICAgZGF0YToge30gIAogICAgICAgICAgICB9LAogICAgICAgICAgICBkZXRhaWxzRGlhbG9nRGF0YTp7CiAgICAgICAgICAgICAgZGlhbG9nVmlzaWJsZTogZmFsc2UsCiAgICAgICAgICAgICAgZGF0YToge30gCiAgICAgICAgICAgIH0sCiAgICAgICAgICAgIGVkaXREaWFsb2dEYXRhOnsKICAgICAgICAgICAgICBkaWFsb2dWaXNpYmxlOiBmYWxzZSwKICAgICAgICAgICAgICBkYXRhOiB7fSAKICAgICAgICAgICAgfSwKICAgICAgICAgICAgZGlzYXJtaW5nQWxhcm1EYXRhOnsKICAgICAgICAgICAgICBkaWFsb2dWaXNpYmxlOiBmYWxzZSwKICAgICAgICAgICAgICBkYXRhOiB7fSAKICAgICAgICAgICAgfQogICAgICAgIH0KICAgIH0sCiAgICBjcmVhdGVkKCkgewogICAgICAgIHRoaXMuZ2V0TGlzdCh0aGlzLnNlYXJjaERhdGEpCiAgICB9LAogICAgbWV0aG9kczp7CiAgICAgICAgZ2V0TGlzdChwYXJhbXMpIHsKICAgICAgICAgICAgZ2V0QW5hbG9nRGF0YShwYXJhbXMpLnRoZW4ocmVzID0+IHsgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICBpZihyZXMuY29kZSA9PSAyMDApIHsKICAgICAgICAgICAgICAgICAgICB0aGlzLnRhYmxlRGF0YSA9IHJlcy5kYXRhLnJlY29yZHMKICAgICAgICAgICAgICAgICAgICB0aGlzLnRvdGFsID0gcmVzLmRhdGEudG90YWwKICAgICAgICAgICAgICAgIH0KICAgICAgICAgICAgfSkKICAgICAgICB9LAogICAgICAgIGhhbmRsZVNpemVDaGFuZ2UodmFsKSB7CiAgICAgICAgICAgIHRoaXMuc2VhcmNoRGF0YS5wYWdlU2l6ZSA9IHZhbAogICAgICAgICAgICB0aGlzLmdldExpc3QodGhpcy5zZWFyY2hEYXRhKQogICAgICAgIH0sCiAgICAgICAgaGFuZGxlQ3VycmVudENoYW5nZSh2YWwpIHsKICAgICAgICAgICAgdGhpcy5zZWFyY2hEYXRhLnBhZ2VOdW0gPSB2YWwKICAgICAgICAgICAgdGhpcy5nZXRMaXN0KHRoaXMuc2VhcmNoRGF0YSkKICAgICAgICB9LAogICAgICAgIGFkZEJ0bigpIHsKICAgICAgICAgICAgdGhpcy5hZGREaWFsb2dEYXRhLmRpYWxvZ1Zpc2libGUgPSB0cnVlCiAgICAgICAgfSwKICAgICAgICBhZGRJbWl0YXRlRGF0YShwYXlsb2FkKSB7CiAgICAgICAgICAgIGFkZEFsYXJtVGVtcG9yYXJ5KHBheWxvYWQpLnRoZW4ocmVzID0+IHsgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICBpZihyZXMuY29kZSA9PSAyMDApIHsKICAgICAgICAgICAgICAgICAgICB0aGlzLiRtZXNzYWdlKHsKICAgICAgICAgICAgICAgICAgICAgICAgdHlwZTogJ3N1Y2Nlc3MnLAogICAgICAgICAgICAgICAgICAgICAgICBtZXNzYWdlOiAn5paw5aKe5oiQ5YqfIScKICAgICAgICAgICAgICAgICAgICB9KTsKICAgICAgICAgICAgICAgICAgICB0aGlzLmdldExpc3QodGhpcy5zZWFyY2hEYXRhKQogICAgICAgICAgICAgICAgICAgIHRoaXMuYWRkRGlhbG9nRGF0YS5kaWFsb2dWaXNpYmxlID0gZmFsc2UKICAgICAgICAgICAgICAgIH1lbHNlewogICAgICAgICAgICAgICAgICAgIHRoaXMuJG1lc3NhZ2UoewogICAgICAgICAgICAgICAgICAgICAgICB0eXBlOiAnZXJyb3InLAogICAgICAgICAgICAgICAgICAgICAgICBtZXNzYWdlOiByZXMubXNnCiAgICAgICAgICAgICAgICAgICAgfSk7IAogICAgICAgICAgICAgICAgfQogICAgICAgICAgICB9KQogICAgICAgIH0sICAKICAgICAgICBsb29rRGV0YWlscyhyb3cpIHsKICAgICAgICAgICAgcm93LmFsYXJtVHlwZSA9IHJvdy5hbGFybVR5cGUudG9TdHJpbmcoKQogICAgICAgICAgICByb3cuYWxhcm1MZXZlbCA9IHJvdy5hbGFybUxldmVsLnRvU3RyaW5nKCkKICAgICAgICAgICAgcm93LmxpbmVEaXIgPSByb3cubGluZURpci50b1N0cmluZygpCiAgICAgICAgICAgIGlmKHJvdy5zb3VyY2UpIHJvdy5zb3VyY2UgPSByb3cuc291cmNlLnRvU3RyaW5nKCkgICAgICAgICAgICAKICAgICAgICAgICAgdGhpcy5kZXRhaWxzRGlhbG9nRGF0YS5kYXRhID0gcm93CiAgICAgICAgICAgIHRoaXMuZGV0YWlsc0RpYWxvZ0RhdGEuZGlhbG9nVmlzaWJsZSA9IHRydWUKICAgICAgICB9LAogICAgICAgIGVkaXRCdG4ocm93KSB7CiAgICAgICAgICByb3cuYWxhcm1UeXBlID0gcm93LmFsYXJtVHlwZS50b1N0cmluZygpCiAgICAgICAgICAgIHJvdy5hbGFybUxldmVsID0gcm93LmFsYXJtTGV2ZWwudG9TdHJpbmcoKQogICAgICAgICAgICByb3cubGluZURpciA9IHJvdy5saW5lRGlyLnRvU3RyaW5nKCkKICAgICAgICAgICAgaWYocm93LnNvdXJjZSkgcm93LnNvdXJjZSA9IHJvdy5zb3VyY2UudG9TdHJpbmcoKQogICAgICAgICAgICB0aGlzLmVkaXREaWFsb2dEYXRhLmRhdGEgPSByb3cKICAgICAgICAgICAgdGhpcy5lZGl0RGlhbG9nRGF0YS5kaWFsb2dWaXNpYmxlID0gdHJ1ZQogICAgICAgIH0sIAogICAgICAgIGRpc2FybWluZ0J0bih2YWwpIHsgICAgICAgICAgCiAgICAgICAgICB0aGlzLmRpc2FybWluZ0FsYXJtRGF0YS5kaWFsb2dWaXNpYmxlID0gdHJ1ZQogICAgICAgICAgdGhpcy5kaXNhcm1pbmdBbGFybURhdGEuZGF0YS5hbGFybUlkID0gdmFsLmFsYXJtSWQKICAgICAgICAgIHRoaXMuZGlzYXJtaW5nQWxhcm1EYXRhLmRhdGEucmVsZWFzZVRpbWUgPSAnJwogICAgICAgICAgdGhpcy5kaXNhcm1pbmdBbGFybURhdGEuZGF0YS5yZWxlYXNlQ29udGVudCA9ICcnCiAgICAgICAgfSwKICAgICAgICBkaXNhcm1pbmdBbGFybShwYXlsb2FkKSB7ICAgICAgICAgCiAgICAgICAgICBkaXNhcm1pbmdBbGFybShwYXlsb2FkKS50aGVuKHJlcyA9PiB7ICAgICAgICAgICAgCiAgICAgICAgICAgIGlmKHJlcy5jb2RlID09IDIwMCkgewogICAgICAgICAgICAgIHRoaXMuJG1lc3NhZ2UoewogICAgICAgICAgICAgICAgICAgICAgICB0eXBlOiAnc3VjY2VzcycsCiAgICAgICAgICAgICAgICAgICAgICAgIG1lc3NhZ2U6ICfop6PpmaTmiqXorabmiJDlip8hJwogICAgICAgICAgICAgICAgICAgIH0pOwogICAgICAgICAgICAgICAgICAgIHRoaXMuZ2V0TGlzdCh0aGlzLnNlYXJjaERhdGEpCiAgICAgICAgICAgICAgICAgICAgdGhpcy5kaXNhcm1pbmdBbGFybURhdGEuZGlhbG9nVmlzaWJsZSA9IGZhbHNlICAgIAogICAgICAgICAgICB9ZWxzZXsKICAgICAgICAgICAgICB0aGlzLiRtZXNzYWdlKHsKICAgICAgICAgICAgICAgICAgICAgICAgdHlwZTogJ2Vycm9yJywKICAgICAgICAgICAgICAgICAgICAgICAgbWVzc2FnZTogcmVzLm1zZwogICAgICAgICAgICAgICAgICAgIH0pOwogICAgICAgICAgICB9CiAgICAgICAgICB9KQogICAgICAgIH0sCiAgICAgICAgZWRpdEltaXRhdGVEYXRhKHBheWxvYWQpeyAgICAgICAgICAKICAgICAgICAgIGVkaXRBbGFybVRlbXBvcmFyeShwYXlsb2FkKS50aGVuKHJlcyA9PiB7ICAgICAgICAgICAgCiAgICAgICAgICAgIGlmKHJlcy5jb2RlID09IDIwMCkgewogICAgICAgICAgICAgIHRoaXMuJG1lc3NhZ2UoewogICAgICAgICAgICAgICAgICAgICAgICB0eXBlOiAnc3VjY2VzcycsCiAgICAgICAgICAgICAgICAgICAgICAgIG1lc3NhZ2U6ICfkv67mlLnmiJDlip8hJwogICAgICAgICAgICAgICAgICAgIH0pOwogICAgICAgICAgICAgICAgdGhpcy5nZXRMaXN0KHRoaXMuc2VhcmNoRGF0YSkgCiAgICAgICAgICAgICAgICB0aGlzLmVkaXREaWFsb2dEYXRhLmRpYWxvZ1Zpc2libGUgPSBmYWxzZSAgCiAgICAgICAgICAgIH1lbHNlewogICAgICAgICAgICAgIHRoaXMuJG1lc3NhZ2UoewogICAgICAgICAgICAgICAgICAgICAgICB0eXBlOiAnZXJyb3InLAogICAgICAgICAgICAgICAgICAgICAgICBtZXNzYWdlOiByZXMubWVzc2FnZQogICAgICAgICAgICAgICAgICAgIH0pOwogICAgICAgICAgICB9CiAgICAgICAgICB9KQogICAgICAgIH0sICAKICAgICAgICBzZW5kaW5nQWxhcm1zKHNjb3BlKSB7ICAgICAgICAgIAogICAgICAgICAgdGhpcy4kY29uZmlybSgn56Gu5a6a6KaB5Y+R6YCB5oql6K2m5ZCXPycsICfkv6Hmga/mj5DnpLonLCB7CiAgICAgICAgICAgIGNvbmZpcm1CdXR0b25UZXh0OiAn56Gu5a6aJywKICAgICAgICAgICAgY2FuY2VsQnV0dG9uVGV4dDogJ+WPlua2iCcsCiAgICAgICAgICAgIHR5cGU6ICd3YXJuaW5nJwogICAgICAgICAgfSkudGhlbigoKSA9PiB7CiAgICAgICAgICAgIHNlbmRBbGFybShzY29wZS5pZCkudGhlbihyZXMgPT4gewogICAgICAgICAgICAgIGlmKHJlcy5jb2RlID09IDIwMCkgewogICAgICAgICAgICAgICAgdGhpcy4kbWVzc2FnZSh7CiAgICAgICAgICAgICAgICAgIHR5cGU6ICdzdWNjZXNzJywKICAgICAgICAgICAgICAgICAgbWVzc2FnZTogJ+WPkemAgeaKpeitpuaIkOWKnyEnCiAgICAgICAgICAgICAgICB9KTsKICAgICAgICAgICAgICAgIHRoaXMuZ2V0TGlzdCh0aGlzLnNlYXJjaERhdGEpCiAgICAgICAgICAgICAgfWVsc2V7CiAgICAgICAgICAgICAgICB0aGlzLiRtZXNzYWdlKHsKICAgICAgICAgICAgICAgICAgdHlwZTogJ2Vycm9yJywKICAgICAgICAgICAgICAgICAgbWVzc2FnZTogcmVzLm1zZwogICAgICAgICAgICAgICAgfSk7CiAgICAgICAgICAgICAgfQogICAgICAgICAgICAgIAogICAgICAgICAgICB9KQogICAgICAgICAgfSkuY2F0Y2goKCkgPT4gewogICAgICAgICAgICB0aGlzLiRtZXNzYWdlKHsKICAgICAgICAgICAgICB0eXBlOiAnaW5mbycsCiAgICAgICAgICAgICAgbWVzc2FnZTogJ+W3suWPlua2iCcKICAgICAgICAgICAgfSk7CiAgICAgICAgICB9KQogICAgICAgIH0KICAgIH0KfQo="},{"version":3,"sources":["index.vue"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAwEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA","file":"index.vue","sourceRoot":"src/views/simulatedUpload","sourcesContent":["<template>\n <div class=\"dashboard-container\">\n <div class=\"table-content\">\n <div style=\"width: 100%;height: 30px;\">\n <div class=\"btn\" style=\"margin-right: -3px;\" @click=\"addBtn\">新增</div>\n </div>\n <el-table ref=\"multipleTable\" :data=\"tableData\" tooltip-effect=\"dark\" style=\"width: 100%\">\n <el-table-column type=\"index\" label=\"序号\" width=\"60px\">\n </el-table-column>\n <el-table-column prop=\"alarmTime\" label=\"报警时间\"> \n </el-table-column>\n <el-table-column prop=\"alarmRailway\" label=\"报警线路编码\">\n </el-table-column>\n <el-table-column prop=\"railwayName\" label=\"报警线路\">\n </el-table-column>\n <el-table-column label=\"报警行别\">\n <template slot-scope=\"scope\">\n {{ scope.row.lineDir == 1 ? '上行' : '下行' }}\n </template>\n </el-table-column>\n <el-table-column prop=\"alarmMiles\" label=\"报警里程位置\">\n </el-table-column>\n <el-table-column label=\"报警附件\">\n <template slot-scope=\"scope\" v-if=\"scope.row.fileUrl\">\n <img :src=\"scope.row.fileUrl\" style=\"width: 100px;height: 100px;\"/>\n </template>\n <template slot-scope=\"scope\" v-else></template>\n </el-table-column>\n <el-table-column label=\"报警类型\" width=\"160px\" prop=\"alarmTypeName\"> \n </el-table-column>\n <el-table-column prop=\"alarmLevel\" label=\"报警级别\">\n </el-table-column>\n <el-table-column prop=\"alarmConfidence\" label=\"报警置信度\">\n </el-table-column>\n <el-table-column prop=\"content\" label=\"报警内容\">\n </el-table-column>\n <el-table-column label=\"模拟状态\">\n <template slot-scope=\"scope\">\n {{ scope.row.stareName }}\n </template>\n </el-table-column>\n <el-table-column label=\"模拟生效\">\n <template slot-scope=\"scope\">\n <div class=\"operateBtn\">\n <div v-if=\"scope.row.stareName == '未生效'\" @click=\"sendingAlarms(scope.row)\">发送报警</div>\n </div> \n </template>\n </el-table-column>\n <el-table-column label=\"操作\" width=\"200px\">\n <template slot-scope=\"scope\">\n <div class=\"operateBtn\"> \n <!-- <div>删除</div> -->\n <div @click=\"lookDetails(scope.row)\">详情查看</div>\n <div v-if=\"scope.row.stareName != '已生效'\" @click=\"editBtn(scope.row)\">修改</div> \n <div v-if=\"scope.row.stareName == '已生效'\" @click=\"disarmingBtn(scope.row)\">解除报警</div>\n </div>\n </template>\n </el-table-column>\n </el-table>\n <div class=\"pagination\">\n <el-pagination @size-change=\"handleSizeChange\" @current-change=\"handleCurrentChange\" :page-sizes=\"[10, 15, 20]\"\n :page-size=\"searchData.pageSize\" layout=\"total, sizes, prev, pager, next, jumper\" :total=\"total\">\n </el-pagination>\n </div>\n <addDialog v-if=\"addDialogData.dialogVisible\" :addDialogData=\"addDialogData\" @addImitateData=\"addImitateData\"></addDialog>\n <detailsDialog v-if=\"detailsDialogData.dialogVisible\" :detailsDialogData=\"detailsDialogData\"></detailsDialog>\n <editDialog v-if=\"editDialogData.dialogVisible\" :editDialogData=\"editDialogData\" @editImitateData=\"editImitateData\"></editDialog>\n <disarmingAlarmDialog v-if=\"disarmingAlarmData.dialogVisible\" :disarmingAlarmData=\"disarmingAlarmData\" @disarmingAlarm=\"disarmingAlarm\"></disarmingAlarmDialog>\n </div>\n </div>\n</template>\n<script>\nimport { getAnalogData ,addAlarmTemporary,sendAlarm,editAlarmTemporary,disarmingAlarm} from \"@/api/analogData\";\nimport addDialog from './components/addDialog.vue';\nimport detailsDialog from './components/detailsDialog.vue'\nimport editDialog from './components/editDialog.vue'\nimport disarmingAlarmDialog from './components/disarmingAlarmDialog.vue'\nexport default {\n name :'simulatedUpload',\n components:{\n addDialog,\n detailsDialog,\n editDialog,\n disarmingAlarmDialog\n },\n data() {\n return {\n tableData:[],\n searchData:{\n pageNum: 1,\n pageSize: 10, \n },\n total:0,\n addDialogData:{\n dialogVisible: false,\n data: {} \n },\n detailsDialogData:{\n dialogVisible: false,\n data: {} \n },\n editDialogData:{\n dialogVisible: false,\n data: {} \n },\n disarmingAlarmData:{\n dialogVisible: false,\n data: {} \n }\n }\n },\n created() {\n this.getList(this.searchData)\n },\n methods:{\n getList(params) {\n getAnalogData(params).then(res => { \n if(res.code == 200) {\n this.tableData = res.data.records\n this.total = res.data.total\n }\n })\n },\n handleSizeChange(val) {\n this.searchData.pageSize = val\n this.getList(this.searchData)\n },\n handleCurrentChange(val) {\n this.searchData.pageNum = val\n this.getList(this.searchData)\n },\n addBtn() {\n this.addDialogData.dialogVisible = true\n },\n addImitateData(payload) {\n addAlarmTemporary(payload).then(res => { \n if(res.code == 200) {\n this.$message({\n type: 'success',\n message: '新增成功!'\n });\n this.getList(this.searchData)\n this.addDialogData.dialogVisible = false\n }else{\n this.$message({\n type: 'error',\n message: res.msg\n }); \n }\n })\n }, \n lookDetails(row) {\n row.alarmType = row.alarmType.toString()\n row.alarmLevel = row.alarmLevel.toString()\n row.lineDir = row.lineDir.toString()\n if(row.source) row.source = row.source.toString() \n this.detailsDialogData.data = row\n this.detailsDialogData.dialogVisible = true\n },\n editBtn(row) {\n row.alarmType = row.alarmType.toString()\n row.alarmLevel = row.alarmLevel.toString()\n row.lineDir = row.lineDir.toString()\n if(row.source) row.source = row.source.toString()\n this.editDialogData.data = row\n this.editDialogData.dialogVisible = true\n }, \n disarmingBtn(val) { \n this.disarmingAlarmData.dialogVisible = true\n this.disarmingAlarmData.data.alarmId = val.alarmId\n this.disarmingAlarmData.data.releaseTime = ''\n this.disarmingAlarmData.data.releaseContent = ''\n },\n disarmingAlarm(payload) { \n disarmingAlarm(payload).then(res => { \n if(res.code == 200) {\n this.$message({\n type: 'success',\n message: '解除报警成功!'\n });\n this.getList(this.searchData)\n this.disarmingAlarmData.dialogVisible = false \n }else{\n this.$message({\n type: 'error',\n message: res.msg\n });\n }\n })\n },\n editImitateData(payload){ \n editAlarmTemporary(payload).then(res => { \n if(res.code == 200) {\n this.$message({\n type: 'success',\n message: '修改成功!'\n });\n this.getList(this.searchData) \n this.editDialogData.dialogVisible = false \n }else{\n this.$message({\n type: 'error',\n message: res.message\n });\n }\n })\n }, \n sendingAlarms(scope) { \n this.$confirm('确定要发送报警吗?', '信息提示', {\n confirmButtonText: '确定',\n cancelButtonText: '取消',\n type: 'warning'\n }).then(() => {\n sendAlarm(scope.id).then(res => {\n if(res.code == 200) {\n this.$message({\n type: 'success',\n message: '发送报警成功!'\n });\n this.getList(this.searchData)\n }else{\n this.$message({\n type: 'error',\n message: res.msg\n });\n }\n \n })\n }).catch(() => {\n this.$message({\n type: 'info',\n message: '已取消'\n });\n })\n }\n }\n}\n</script>\n<style lang=\"scss\" scoped>\n.dashboard {\n &-container {\n margin: 30px;\n }\n\n &-text {\n font-size: 30px;\n line-height: 46px;\n }\n}\n.dashboard-container {\n .search-content {\n width: 100%;\n height: 74px;\n background-color: #fff;\n display: flex;\n align-items: center;\n padding-left: 10px;\n\n .el-input {\n margin: 0 10px;\n }\n\n .el-select {\n margin: 0 10px;\n }\n\n .search-btn {\n display: flex;\n align-items: center;\n height: 100%; \n margin-left: 10px;\n\n div {\n // margin: 0 6px;\n display: inline-block;\n width: 80px;\n height: 40px;\n border-radius: 2px;\n font-size: 14px;\n line-height: 40px;\n text-align: center;\n }\n\n div:hover {\n cursor: pointer;\n }\n\n .search {\n margin-right: 10px;\n background-color: #2766DD;\n color: #F7F8FB;\n }\n\n .search:hover {\n background-color: #4D85F4;\n }\n\n .reset {\n color: #333334;\n border: 1px solid #D7D7D7;\n }\n\n .reset:hover {\n color: #1F9FFF;\n border: 1px solid #1F9FFF;\n }\n }\n }\n\n .table-content {\n margin-top: 15px;\n width: 100%;\n background-color: #fff;\n padding: 0 20px 20px;\n\n .btn {\n margin: 15px 20px 15px 0;\n cursor: pointer;\n float: left;\n text-align: center;\n width: 98px;\n height: 34px;\n border-radius: 2px;\n border: 1px solid #ABC7FD;\n line-height: 34px;\n font-weight: 400;\n font-size: 14px;\n color: #2250C8;\n background-color: #E7EEFF;\n }\n\n .btn:hover {\n color: #FFFFFF;\n background-color: #2250C8;\n border: 1px solid #2250C8;\n }\n\n .btn:active {\n color: #FFFFFF;\n background-color: #194DA4;\n border: 1px solid #194DA4;\n }\n\n .startUsing {\n width: 54px;\n height: 24px;\n margin: 14.5px auto 0;\n line-height: 24px;\n text-align: center;\n font-size: 12px;\n color: #00974D;\n border-radius: 4px;\n background-color: #E7FAF0;\n border: 1px solid #BEFDDD;\n }\n\n .Deactivate {\n width: 54px;\n height: 24px;\n margin: 14.5px auto 0;\n line-height: 24px;\n text-align: center;\n font-size: 12px;\n color: #FF9933;\n border-radius: 4px;\n background-color: #FFF3E8;\n border: 1px solid #FDE6CF;\n }\n\n .operateBtn {\n display: flex;\n justify-content: center;\n color: #2866DD;\n\n div {\n font-size: 14px;\n margin: 0 5px;\n cursor: pointer;\n }\n }\n\n .pagination {\n margin: 10px 0;\n width: 100%;\n height: 20px;\n\n .el-pagination {\n float: right;\n margin: 10px 0;\n }\n }\n }\n\n}\n</style>"]}]}
|