diff --git a/.env.development b/.env.development index dcd92e6..a76eccb 100644 --- a/.env.development +++ b/.env.development @@ -4,6 +4,7 @@ VITE_SERVER_PORT = 8888 VITE_BASE_API = /api VITE_FILE_API = /api # VITE_BASE_PATH = http://192.168.1.9:8888 +# VITE_BASE_PATH = http://192.168.110.98:8888 VITE_BASE_PATH = https://www.xingoil.com/api VITE_POSITION = open VITE_EDITOR = code diff --git a/src/api/equipment/alarmRecord.js b/src/api/equipment/alarmRecord.js new file mode 100644 index 0000000..11ca8d7 --- /dev/null +++ b/src/api/equipment/alarmRecord.js @@ -0,0 +1,9 @@ +import service from '@/utils/request' + +export const getDeviceWarnList = (data) => { + return service({ + url: '/device/getDeviceWarnList', + method: 'post', + data: data + }) +} diff --git a/src/api/equipment/list.js b/src/api/equipment/list.js index 42da02c..2f6c65f 100644 --- a/src/api/equipment/list.js +++ b/src/api/equipment/list.js @@ -15,3 +15,11 @@ export const deviceOperation = (data) => { data: data }) } + +export const getDeviceDetailsInfoByRemote = (data) => { + return service({ + url: '/device/getDeviceDetailsInfoByRemote', + method: 'post', + data: data + }) +} diff --git a/src/pathInfo.json b/src/pathInfo.json index 538297d..a82b8d1 100644 --- a/src/pathInfo.json +++ b/src/pathInfo.json @@ -11,6 +11,7 @@ "/src/view/dashboard/components/table.vue": "Table", "/src/view/dashboard/components/wiki.vue": "Wiki", "/src/view/dashboard/index.vue": "Dashboard", + "/src/view/equipment/alarmRecord/index.vue": "Index", "/src/view/equipment/gateway/index.vue": "Index", "/src/view/equipment/list/index.vue": "Index", "/src/view/equipment/particulars/index.vue": "Index", diff --git a/src/pinia/modules/app.js b/src/pinia/modules/app.js index b0265a9..f69af14 100644 --- a/src/pinia/modules/app.js +++ b/src/pinia/modules/app.js @@ -108,7 +108,7 @@ export const useAppStore = defineStore('app', () => { layout_side_width: 256, layout_side_collapsed_width: 80, layout_side_item_height: 48, - show_watermark: true, + show_watermark: false, side_mode: 'normal', // 页面过渡动画配置 transition_type: 'slide' diff --git a/src/style/element_visiable.scss b/src/style/element_visiable.scss index 59f4583..6c9bbff 100644 --- a/src/style/element_visiable.scss +++ b/src/style/element_visiable.scss @@ -135,3 +135,39 @@ html.dark { --el-fill-color-light: rgb(15, 23, 42); --el-fill-color: rgb(15, 23, 42); } + +html.dark.login-light-mode { + --el-bg-color: #ffffff !important; + --el-bg-color-overlay: #ffffff !important; + --el-text-color-primary: #303133 !important; + --el-text-color-regular: #606266 !important; + --el-text-color-secondary: #909399 !important; + --el-text-color-placeholder: #a8abb2 !important; + --el-border-color: #dcdfe6 !important; + --el-border-color-light: #e4e7ed !important; + --el-border-color-lighter: #ebeef5 !important; + --el-fill-color: #f5f7fa !important; + --el-fill-color-light: #f5f7fa !important; + --el-fill-color-lighter: #fafafa !important; + --el-fill-color-blank: #ffffff !important; + --el-input-bg-color: #ffffff !important; + --el-input-border-color: #dcdfe6 !important; + --el-input-hover-border-color: #c0c4cc !important; + --el-input-focus-border-color: #409eff !important; + --el-input-text-color: #303133 !important; + --el-input-placeholder-text-color: #a8abb2 !important; + --el-button-bg-color: #ffffff !important; + --el-button-border-color: #dcdfe6 !important; + --el-button-text-color: #606266 !important; + --el-button-hover-bg-color: #ecf5ff !important; + --el-button-hover-border-color: #c6e2ff !important; + --el-button-hover-text-color: #409eff !important; + --el-button-active-bg-color: #3a8ee6 !important; + --el-button-active-border-color: #3a8ee6 !important; + --el-button-active-text-color: #ffffff !important; + --el-button-disabled-bg-color: #f5f7fa !important; + --el-button-disabled-border-color: #e4e7ed !important; + --el-button-disabled-text-color: #a0cff4 !important; + --el-form-label-font-size: 14px !important; + --el-form-border-color-hover: #409eff !important; +} diff --git a/src/view/equipment/alarmRecord/index.vue b/src/view/equipment/alarmRecord/index.vue new file mode 100644 index 0000000..89f1a49 --- /dev/null +++ b/src/view/equipment/alarmRecord/index.vue @@ -0,0 +1,121 @@ + + + + + + + + + + + + + + 查询 + 重置 + + + + + + 新增用户 + + + + + + + + + {{ scope.row.gatewayLong }} + + {{ scope.row.gatewayLat }} + + + + + + + + + + + + + diff --git a/src/view/equipment/list/index.vue b/src/view/equipment/list/index.vue index 9917057..769e9c8 100644 --- a/src/view/equipment/list/index.vue +++ b/src/view/equipment/list/index.vue @@ -31,11 +31,11 @@ {{ row.cbId || '未设置' }} - + {{ row.gatewayId || '未设置' }} @@ -48,6 +48,13 @@ }} + + + {{ + ['正常', '远程合闸禁止', '锁定'][row.lockStatus] + }} + + {{ row.netStatus == 1 ? '在线' : '离线' }} @@ -55,20 +62,44 @@ + + + + {{ row.createTime || '未设置' }} - + - 分闸 - 合闸 - - + + + 分闸 + + 合闸 + + 解锁 + + + + 更多 + + + + + + + + + 实时数据 + + + + + + @@ -109,7 +140,35 @@ onMounted(() => { getTableData() }) - + // 解锁 + const unlock = async (row) => { + ElMessageBox.confirm('确认解锁吗?', '提示', { + confirmButtonText: '确定', + cancelButtonText: '取消', + type: 'warning' + }).then(async () => { + const res = await serve.deviceOperation({ + id: row.ID, + gatewayId: row.gatewayId, + para: '0xAD' + }) + if (res.code === 0) { + ElMessage.success('操作成功') + getTableData() + } + }) + } + // 更新 + const updateParticulars = async (row) => { + const res = await serve.getDeviceDetailsInfoByRemote({ + deviceId: row.ID + }) + if (res.code === 0) { + ElMessage.success('更新成功') + } else { + // ElMessage.error(res.msg || '更新失败') + } + } // 合分闸 const changeStatus = (row) => { ElMessageBox.confirm(row.deviceStatus == 1 ? '确认分闸吗?' : '确认合闸吗?', '提示', { @@ -166,8 +225,20 @@ } - diff --git a/src/view/equipment/particulars/index.vue b/src/view/equipment/particulars/index.vue index 03912af..1a84ed0 100644 --- a/src/view/equipment/particulars/index.vue +++ b/src/view/equipment/particulars/index.vue @@ -21,9 +21,10 @@ + - {{ row.runtime || '' }} + {{ row.runtime || '' }} @@ -31,7 +32,12 @@ {{ row.signalQuality || '' }} - + + + {{ row.leakageCurrent || '' }} + + + {{ row.leakageCurrent || '' }} @@ -41,36 +47,31 @@ {{ row.cumulativeElectricity || '' }} - + {{ row.current || '' }} - - - {{ row.powerFactor || '' }} - - - + {{ row.internalTemperature || '' }} - + {{ row.nLowerTemperature || '' }} - + {{ row.powerFactor || '' }} - + - + diff --git a/src/view/login/index.vue b/src/view/login/index.vue index fd397dd..bf2749c 100644 --- a/src/view/login/index.vue +++ b/src/view/login/index.vue @@ -1,5 +1,5 @@ - +