diff --git a/hx-ai-intelligent/src/App.vue b/hx-ai-intelligent/src/App.vue
index 9c90247..1b31526 100644
--- a/hx-ai-intelligent/src/App.vue
+++ b/hx-ai-intelligent/src/App.vue
@@ -48,169 +48,24 @@
height: 100%;
}
}
- // :deep(.ant-menu-item),
- // :deep(.ant-menu-submenu-title) {
- // &:not(.ant-menu-item-selected) {
- // // &:not(.ant-menu-item-active) {
- // .anticon {
- // color: rgb(141, 150, 163);
- // }
- // }
- // }
- // :deep(.ns-content) {
- // // padding-top: 80px !important;
- // }
- // #app {
- // width: 100%;
- // height: 100%;
- // }
-
- // :deep(.ant-menu-title-content) {
- // background: unset !important;
- // z-index: 9 !important;
- // }
- // :deep(.ns-left-menu) {
- // .ant-menu-item-selected {
- // // color: #fff !important;
- // background: @primary-color;
- // border-radius: 12px;
- // // height: 40px;
- // // line-height: 40px;
- // padding: 5px @ns-gap;
- // position: relative;
- // a {
- // color: @white !important;
- // }
- // }
-
- // .ant-menu-item-active,
- // .ant-submenu-item-active {
- // // color: rgba(@primary-color, 0.1) !important;
- // }
- // }
-
- // :deep(.ant-menu-light.ant-menu-horizontal > .ant-menu-item:hover) {
- // // background: @primary-color;
- // }
- // // :deep(.ant-menu-inline .ant-menu-submenu-title) {
- // // color: rgba(255, 255, 255, 0.9) !important;
- // // }
- // :deep(.ns-left-menu .ant-layout-sider-children .ant-menu-sub.ant-menu-inline) {
- // // position: relative;
- // // &::before {
- // // display: flex;
- // // width: 2px;
- // // height: calc(100% - 40px);
- // // position: absolute;
- // // top: 20px;
- // // left: 20px;
- // // content: '';
- // // background-color: rgba(255, 255, 255, 0.2);
- // // }
- // }
-
- // //*************************含tab的 list列表样式 */
- // :deep(.tabListTable) {
- // .ns-table-title {
- // text-align: left;
- // height: 46px;
- // line-height: 46px;
- // font-size: 18px;
- // font-weight: bold;
- // user-select: text;
- // padding-left: 16px;
- // background: #fff;
- // width: calc(100% + 32px);
- // margin-left: -16px;
- // }
- // .tabs-list {
- // overflow: visible !important;
- // }
- // .ant-tabs-nav {
- // width: calc(100% + 32px);
- // margin-left: -16px !important;
- // background: #fff;
- // }
- // .ant-tabs-nav-wrap {
- // padding: 0 16px;
- // }
- // }
-
- // //*********************详情页返回修改 */
- // :deep(.nsDetailView) {
- // min-height: 100%;
- // height: 100%;
- // .ns-detail-content {
- // padding: 0px 24px;
- // border-top: 16px solid #e5ebf0;
- // }
- // .ant-descriptions-item-label {
- // color: rgba(0, 0, 0, 0.5);
- // font-family: PingFang SC;
- // font-size: 14px;
- // }
- // .ant-descriptions-item-content {
- // color: rgba(0, 0, 0, 0.95);
- // font-family: PingFang SC;
- // font-size: 14px;
- // }
- // .ant-descriptions-title {
- // &::after {
- // content: '';
- // width: 75px;
- // height: 7px;
- // display: block;
- // background: linear-gradient(90deg, #537fff 0%, #fff 82.67%);
- // margin-left: 2px;
- // margin-top: -2px;
- // }
- // }
-
- // .ant-descriptions-row > th,
- // .ant-descriptions-row > td {
- // padding-bottom: 8px;
- // }
- // .ns-page-header {
- // margin-bottom: 0 !important;
- // padding-top: 7px !important;
- // padding-bottom: 7px !important;
- // width: calc(100% + 32px);
- // margin-left: -16px;
- // .title {
- // cursor: pointer;
- // font-size: 18px !important;
- // }
- // }
- // .ant-descriptions-header {
- // margin: 16px 0 16px 0 !important;
-
- // .ant-descriptions-title {
- // line-height: 16px;
- // font-size: 16px;
- // }
- // }
- // }
-
- // :deep(.ns-detail .ant-descriptions-header .descriptions-title) {
- // &:after {
- // content: '';
- // width: 75px;
- // height: 7px;
- // display: block;
- // background: linear-gradient(90deg, @primary-color 0%, #fff 82.67%);
- // margin-left: 2px;
- // margin-top: -2px;
- // }
- // }
- // :deep(.ant-descriptions-header .descriptions-title) {
- // &:after {
- // content: '';
- // width: 75px;
- // height: 7px;
- // display: block;
- // background: linear-gradient(90deg, @primary-color 0%, #fff 82.67%);
- // margin-left: 2px;
- // margin-top: -2px;
- // }
- // }
+ :deep(.ant-tree-node-content-wrapper) {
+ overflow: hidden;
+ text-overflow: ellipsis;
+ text-wrap: nowrap;
+ }
+ :deep(.ns-table-search) {
+ .ns-flexv2-form {
+ .ns-operate {
+ text-align: left;
+ margin-left: 0;
+ .ant-btn {
+ margin: 0;
+ margin-right: 6px;
+ }
+ }
+ }
+ .ns-form-body {
+ max-width: 1000px;
+ }
+ }
diff --git a/hx-ai-intelligent/src/api/carbonEmissionFactorLibrary.ts b/hx-ai-intelligent/src/api/carbonEmissionFactorLibrary.ts
index aaad9c2..5d666ad 100644
--- a/hx-ai-intelligent/src/api/carbonEmissionFactorLibrary.ts
+++ b/hx-ai-intelligent/src/api/carbonEmissionFactorLibrary.ts
@@ -31,4 +31,8 @@ export enum quickCalculation {
creat = '/carbon-smart/api/carbon/energy/correlation/creat',
update = '/carbon-smart/api/carbon/energy/correlation/update',
del = '/carbon-smart/api/carbon/energy/correlation/del',
+}
+// 碳排管理-碳排统计接口
+export enum carbonEmission {
+ carbonEmissionStatistics = '/carbon-smart/api/carbon/energy/correlation/carbonEmissionStatistics',
}
\ No newline at end of file
diff --git a/hx-ai-intelligent/src/api/monitor.ts b/hx-ai-intelligent/src/api/monitor.ts
new file mode 100644
index 0000000..62f5064
--- /dev/null
+++ b/hx-ai-intelligent/src/api/monitor.ts
@@ -0,0 +1,13 @@
+export enum deviceMonitor {
+ // getTableList = '/carbon/emission/factor/queryCarbonFactorPage',
+ // addNewData = '/carbon/emission/factor/creatOrUpdate',
+ // editUser = '/carbon-smart/api/user/edit',
+ // frozen = '/carbon-smart/api/user/frozen',
+ // resetPwd = '/carbon-smart/api/user/resetPwd',
+ // del = '/carbon-smart/api/user/del',
+ // batchDel = '/carbon-smart/api/user/batchDel',
+ // getCarbonFactorTree = '/carbon/emission/type/getCarbonFactorTree',
+ // queryDeptTree = '/carbon-smart/api/user/queryDeptTree',
+ // queryUserPerList = '/carbon-smart/api/user/queryUserPerList',
+ getDeviceGraph = '/carbon-smart/api/monitor/getDeviceGraph',
+}
diff --git a/hx-ai-intelligent/src/components/ns-steps.vue b/hx-ai-intelligent/src/components/ns-steps.vue
new file mode 100644
index 0000000..d55f6fd
--- /dev/null
+++ b/hx-ai-intelligent/src/components/ns-steps.vue
@@ -0,0 +1,107 @@
+
+
+
+
+
+
+
+
+
+
+
{{ getStatus(item) }}
+
{{ item.name }}
+
2024-03-11 11:30:06
+
+
+ 工单已完成并通过验收
+
+
+
+
+
+
+
+
+
diff --git a/hx-ai-intelligent/src/icon/gaojingguanli.svg b/hx-ai-intelligent/src/icon/gaojingguanli.svg
index 23227d7..ef3dd02 100644
--- a/hx-ai-intelligent/src/icon/gaojingguanli.svg
+++ b/hx-ai-intelligent/src/icon/gaojingguanli.svg
@@ -1,12 +1 @@
-
-
-
+
\ No newline at end of file
diff --git a/hx-ai-intelligent/src/icon/gaojingtonglan.svg b/hx-ai-intelligent/src/icon/gaojingtonglan.svg
new file mode 100644
index 0000000..0407a0a
--- /dev/null
+++ b/hx-ai-intelligent/src/icon/gaojingtonglan.svg
@@ -0,0 +1,6 @@
+
+
\ No newline at end of file
diff --git a/hx-ai-intelligent/src/icon/status-0.svg b/hx-ai-intelligent/src/icon/status-0.svg
new file mode 100644
index 0000000..d05487a
--- /dev/null
+++ b/hx-ai-intelligent/src/icon/status-0.svg
@@ -0,0 +1,6 @@
+
+
\ No newline at end of file
diff --git a/hx-ai-intelligent/src/icon/status-1.svg b/hx-ai-intelligent/src/icon/status-1.svg
new file mode 100644
index 0000000..7ded55c
--- /dev/null
+++ b/hx-ai-intelligent/src/icon/status-1.svg
@@ -0,0 +1,6 @@
+
+
\ No newline at end of file
diff --git a/hx-ai-intelligent/src/icon/status-2.svg b/hx-ai-intelligent/src/icon/status-2.svg
new file mode 100644
index 0000000..5e24ea9
--- /dev/null
+++ b/hx-ai-intelligent/src/icon/status-2.svg
@@ -0,0 +1,6 @@
+
+
\ No newline at end of file
diff --git a/hx-ai-intelligent/src/icon/status-3.svg b/hx-ai-intelligent/src/icon/status-3.svg
new file mode 100644
index 0000000..3dcdc39
--- /dev/null
+++ b/hx-ai-intelligent/src/icon/status-3.svg
@@ -0,0 +1,6 @@
+
+
\ No newline at end of file
diff --git a/hx-ai-intelligent/src/icon/status-4.svg b/hx-ai-intelligent/src/icon/status-4.svg
new file mode 100644
index 0000000..08e2ae4
--- /dev/null
+++ b/hx-ai-intelligent/src/icon/status-4.svg
@@ -0,0 +1,6 @@
+
+
\ No newline at end of file
diff --git a/hx-ai-intelligent/src/router/alarmManagement.ts b/hx-ai-intelligent/src/router/alarmManagement.ts
index dd930f3..f9d7428 100644
--- a/hx-ai-intelligent/src/router/alarmManagement.ts
+++ b/hx-ai-intelligent/src/router/alarmManagement.ts
@@ -15,7 +15,6 @@ const alarmManagement = {
{
path: 'index',
name: 'alarmOverviewIndex',
- // component: () => import('/nerv-lib/saas/view/menuManage/index.vue'),
component: () => import('/@/view/alarmManagement/alarmOverview/index.vue'),
meta: {
title: '告警总览',
@@ -26,16 +25,15 @@ const alarmManagement = {
],
},
{
- path: 'equipmentAlarm ',
+ path: 'equipmentAlarm',
name: 'EquipmentAlarm',
meta: { title: '设备告警', hideChildren: true, icon: 'gaojingguanli' },
component: Base,
- redirect: { name: 'equipmentAlarmIndex' },
+ redirect: { name: 'EquipmentAlarmIndex' },
children: [
{
path: 'index',
- name: 'equipmentAlarmIndex',
- // component: () => import('/nerv-lib/saas/view/menuManage/index.vue'),
+ name: 'EquipmentAlarmIndex',
component: () => import('/@/view/alarmManagement/equipmentAlarm/index.vue'),
meta: {
title: '设备告警',
@@ -55,11 +53,34 @@ const alarmManagement = {
{
path: 'index',
name: 'alarmSettingsIndex',
- // component: () => import('/nerv-lib/saas/view/menuManage/index.vue'),
component: () => import('/@/view/alarmManagement/alarmSettings/index.vue'),
meta: {
title: '告警设置',
keepAlive: true,
+ operates: [
+ { title: '设备告警新增', code: 'equipmentAlarmAdd' },
+ { title: '设备告警导入', code: 'equipmentAlarmImport' },
+ { title: '设备告警导出', code: 'equipmentAlarmExports' },
+ { title: '设备告警删除', code: 'equipmentAlarmDel' },
+ { title: '设备告警编辑', code: 'equipmentAlarmEdit' },
+ { title: '能源告警新增', code: 'energyAlarmAdd' },
+ { title: '能源告警导入', code: 'energyAlarmImport' },
+ { title: '能源告警导出', code: 'energyAlarmExports' },
+ { title: '能源告警删除', code: 'energyAlarmDel' },
+ { title: '能源告警编辑', code: 'energyAlarmEdit' },
+ { title: '设备告警规则新增', code: 'configureEquipmentAlarmAdd' },
+ { title: '设备告警规则导入', code: 'configureEquipmentAlarmImport' },
+ { title: '设备告警规则导出', code: 'configureEquipmentAlarmExports' },
+ { title: '设备告警规则批量删除', code: 'configureEquipmentAlarmDels' },
+ { title: '设备告警规则编辑', code: 'configureEquipmentAlarmEdit' },
+ { title: '设备告警规则删除', code: 'configureEquipmentAlarmDel' },
+ { title: '能源告警规则新增', code: 'configureEnergyAlarmAdd' },
+ { title: '能源告警规则导入', code: 'configureEnergyAlarmImport' },
+ { title: '能源告警规则导出', code: 'configureEnergyAlarmExports' },
+ { title: '能源告警规则批量删除', code: 'configureEnergyAlarmDels' },
+ { title: '能源告警规则编辑', code: 'configureEnergyAlarmEdit' },
+ { title: '能源告警规则删除', code: 'configureEnergyAlarmDel' },
+ ],
// backApi: [],
},
},
diff --git a/hx-ai-intelligent/src/router/organizationManage.ts b/hx-ai-intelligent/src/router/organizationManage.ts
index e02f7c4..6b5a52e 100644
--- a/hx-ai-intelligent/src/router/organizationManage.ts
+++ b/hx-ai-intelligent/src/router/organizationManage.ts
@@ -31,7 +31,6 @@ const organizationManage = {
{ title: '重置密码', code: 'userCodeReset' },
{ title: '删除', code: 'userDelete' },
],
- // backApi: [],
},
},
],
@@ -50,7 +49,16 @@ const organizationManage = {
meta: {
title: '部门/权限',
keepAlive: true,
- // backApi: [],
+ operates: [
+ { title: '新增部门', code: 'authorityDeptAdd' },
+ { title: '新增子部门', code: 'authorityDeptSonAdd' },
+ { title: '删除部门', code: 'authorityDeptDelete' },
+ { title: '编辑部门', code: 'authorityDeptEdit' },
+ { title: '新增角色', code: 'authorityRoleAdd' },
+ { title: '新增子角色', code: 'authorityRoleSonAdd' },
+ { title: '删除角色', code: 'authorityRoleDelete' },
+ { title: '编辑角色', code: 'authorityRoleEdit' },
+ ],
},
},
],
diff --git a/hx-ai-intelligent/src/view/alarmManagement/alarmOverview/index.vue b/hx-ai-intelligent/src/view/alarmManagement/alarmOverview/index.vue
index 4793714..a26556e 100644
--- a/hx-ai-intelligent/src/view/alarmManagement/alarmOverview/index.vue
+++ b/hx-ai-intelligent/src/view/alarmManagement/alarmOverview/index.vue
@@ -20,7 +20,7 @@
-

+
@@ -45,7 +45,7 @@
import * as echarts from 'echarts';
defineOptions({
- name: 'alarmOverview', // 与页面路由name一致缓存才可生效
+ name: 'alarmOverviewIndex', // 与页面路由name一致缓存才可生效
});
const info = ref({});
@@ -134,13 +134,13 @@
itemGap: 30, // 这里可以调整图例项之间的间距,单位为像素
},
],
- toolbox: {
- show: true,
- feature: {
- restore: {},
- saveAsImage: {},
- },
- },
+ // toolbox: {
+ // show: true,
+ // feature: {
+ // restore: {},
+ // saveAsImage: {},
+ // },
+ // },
calculable: true,
xAxis: [
{
diff --git a/hx-ai-intelligent/src/view/alarmManagement/alarmSettings/energyAlarm/configureEnergyAlarms.vue b/hx-ai-intelligent/src/view/alarmManagement/alarmSettings/energyAlarm/configureEnergyAlarms.vue
index 02a3b8e..79bc3cf 100644
--- a/hx-ai-intelligent/src/view/alarmManagement/alarmSettings/energyAlarm/configureEnergyAlarms.vue
+++ b/hx-ai-intelligent/src/view/alarmManagement/alarmSettings/energyAlarm/configureEnergyAlarms.vue
@@ -106,7 +106,7 @@
headerActions: [
{
label: '新增',
- name: 'RoleTypeAdd',
+ name: 'configureEnergyAlarmAdd',
type: 'primary',
handle: () => {
editConfigureEnergyAlarms.value.toggle(null, configureEnergyAlarmsData.value);
@@ -114,7 +114,7 @@
},
{
label: '导入',
- name: 'groupImport',
+ name: 'configureEnergyAlarmImport',
type: 'primary',
extra: {
// api: props.postImportApi, // 导入接口名
@@ -131,7 +131,7 @@
},
{
label: '导出',
- name: 'groupExports',
+ name: 'configureEnergyAlarmExports',
type: 'primary',
handle: () => {
doWnload('/hx-ai-intelligent/asset/file/whiteListUser.xlsx');
@@ -140,7 +140,7 @@
{
label: '批量删除',
type: 'primary',
- name: 'userBatchDel',
+ name: 'configureEnergyAlarmDels',
confirm: true,
dynamicDisabled: (data: any) => {
return data.list.length === 0;
@@ -205,7 +205,7 @@
actions: [
{
label: '编辑',
- name: 'FeedBackDetail',
+ name: 'configureEnergyAlarmEdit',
dynamicParams: ['uuid', 'appealType'],
handle: (data: any) => {
editConfigureEnergyAlarms.value.toggle(data, configureEnergyAlarmsData.value);
@@ -213,7 +213,7 @@
},
{
label: '删除',
- name: 'FeedBackDetail',
+ name: 'configureEnergyAlarmDel',
dynamicParams: ['uuid', 'appealType'],
confirm: true,
handle: (data: any) => {
diff --git a/hx-ai-intelligent/src/view/alarmManagement/alarmSettings/equipmentAlarm/configureDeviceAlarms.vue b/hx-ai-intelligent/src/view/alarmManagement/alarmSettings/equipmentAlarm/configureDeviceAlarms.vue
index bcb9426..6f92f87 100644
--- a/hx-ai-intelligent/src/view/alarmManagement/alarmSettings/equipmentAlarm/configureDeviceAlarms.vue
+++ b/hx-ai-intelligent/src/view/alarmManagement/alarmSettings/equipmentAlarm/configureDeviceAlarms.vue
@@ -11,6 +11,9 @@
}"
@click="clickSwitch({ enableRules: record.enableRules, record: record })" />
+
+ {{ record.valueType.label }}
+
@@ -79,7 +82,7 @@
headerActions: [
{
label: '新增',
- name: 'RoleTypeAdd',
+ name: 'configureEquipmentAlarmAdd',
type: 'primary',
handle: () => {
editConfigureDeviceAlarms.value.toggle(null, configureDeviceAlarmsData.value);
@@ -87,7 +90,7 @@
},
{
label: '导入',
- name: 'groupImport',
+ name: 'configureEquipmentAlarmImport',
type: 'primary',
extra: {
// api: props.postImportApi, // 导入接口名
@@ -104,7 +107,7 @@
},
{
label: '导出',
- name: 'groupExports',
+ name: 'configureEquipmentAlarmExports',
type: 'primary',
handle: () => {
doWnload('/hx-ai-intelligent/asset/file/whiteListUser.xlsx');
@@ -112,7 +115,7 @@
},
{
label: '批量删除',
- name: 'groupTemDownload',
+ name: 'configureEquipmentAlarmDels',
type: 'primary',
confirm: true,
dynamicDisabled: (data: any) => {
@@ -177,7 +180,7 @@
actions: [
{
label: '编辑',
- name: 'FeedBackDetail',
+ name: 'configureEquipmentAlarmEdit',
dynamicParams: ['uuid', 'appealType'],
handle: (data: any) => {
editConfigureDeviceAlarms.value.toggle(data, configureDeviceAlarmsData);
@@ -185,7 +188,7 @@
},
{
label: '删除',
- name: 'FeedBackDetail',
+ name: 'configureEquipmentAlarmDel',
dynamicParams: ['uuid', 'appealType'],
confirm: true,
handle: (data: any) => {
diff --git a/hx-ai-intelligent/src/view/alarmManagement/alarmSettings/equipmentAlarm/editConfigureDeviceAlarm.vue b/hx-ai-intelligent/src/view/alarmManagement/alarmSettings/equipmentAlarm/editConfigureDeviceAlarm.vue
index 2ccca11..f44bf69 100644
--- a/hx-ai-intelligent/src/view/alarmManagement/alarmSettings/equipmentAlarm/editConfigureDeviceAlarm.vue
+++ b/hx-ai-intelligent/src/view/alarmManagement/alarmSettings/equipmentAlarm/editConfigureDeviceAlarm.vue
@@ -235,8 +235,8 @@
};
//取值类型
const qzOptions = ref([
- { value: 1, label: '实时值', code: '1' },
- { value: 2, label: '平均值', code: '2' },
+ { value: 1, label: '实时值' },
+ { value: 2, label: '平均值' },
]);
//逻辑
const ljOptions = ref([
@@ -331,6 +331,7 @@
infoObject.value.alarmList = infoObject.value.hxAlarmRuleLogicList || [];
delete infoObject.value.hxAlarmRuleLogicList;
infoObject.value.deviceType = selectDevice;
+ infoObject.value.valueType = infoObject.value.valueType.value;
infoObject.value.ruleType = infoObject.value.ruleType + '';
}
});
diff --git a/hx-ai-intelligent/src/view/alarmManagement/alarmSettings/index.vue b/hx-ai-intelligent/src/view/alarmManagement/alarmSettings/index.vue
index 6f59342..83fc3a1 100644
--- a/hx-ai-intelligent/src/view/alarmManagement/alarmSettings/index.vue
+++ b/hx-ai-intelligent/src/view/alarmManagement/alarmSettings/index.vue
@@ -126,7 +126,7 @@
import { ExclamationCircleOutlined } from '@ant-design/icons-vue';
export default {
- name: 'AlarmSettings',
+ name: 'AlarmSettingsIndex',
components: {
editeEquipmentAlarm,
configureDeviceAlarms,
diff --git a/hx-ai-intelligent/src/view/alarmManagement/alarmSettings/notificationManagement/index.vue b/hx-ai-intelligent/src/view/alarmManagement/alarmSettings/notificationManagement/index.vue
index fd33883..74a5db0 100644
--- a/hx-ai-intelligent/src/view/alarmManagement/alarmSettings/notificationManagement/index.vue
+++ b/hx-ai-intelligent/src/view/alarmManagement/alarmSettings/notificationManagement/index.vue
@@ -44,7 +44,7 @@
width: 5px;
height: 15px;
background: inherit;
- background-color: rgba(251, 156, 67, 1);
+ background-color: #2778ff;
border: none;
border-radius: 5px;
-moz-box-shadow: none;
@@ -66,6 +66,9 @@
:scroll="{ x: 800, y: 700 }"
:pagination="pagination">
+
+ {{ record.userRoleInfos?.[0].deptRoleInfoList }}
+
移除
@@ -93,7 +96,7 @@
const columns = [
{
title: '序号',
- dataIndex: 'address',
+ dataIndex: 'index',
width: 80,
fixed: 'left',
customRender: (text: any) => {
@@ -102,7 +105,7 @@
},
{
title: '姓名',
- dataIndex: 'deviceName',
+ dataIndex: 'realName',
width: 80,
fixed: 'left',
key: 'deviceName',
@@ -115,13 +118,13 @@
},
{
title: '组织关系',
- dataIndex: 'site',
+ dataIndex: 'orgName',
key: 'site',
},
{
title: '部门',
- dataIndex: 'department',
- key: 'department',
+ dataIndex: 'address',
+ key: 'address',
},
{
title: '操作',
@@ -155,7 +158,7 @@
visibleModel.value = true;
let ids = [];
dataSource.value.forEach((item) => {
- ids.push(item.id);
+ ids.push(item.userId);
});
linkPeoples.value.getData({ id: ids, data: dataSource });
};
@@ -223,7 +226,7 @@
//移除数据
const remove = (data: any) => {
dataSource.value.forEach((item, index) => {
- if (item.id === data.id) {
+ if (item.userId === data.userId) {
dataSource.value.splice(index, 1);
}
});
@@ -236,7 +239,7 @@
obj.selectList = [];
dataSource.value.forEach((item) => {
obj.selectList.push({
- people: item.id,
+ userId: item.userId,
});
});
console.log(obj, '数据');
diff --git a/hx-ai-intelligent/src/view/alarmManagement/alarmSettings/notificationManagement/linkPeople/index.vue b/hx-ai-intelligent/src/view/alarmManagement/alarmSettings/notificationManagement/linkPeople/index.vue
index a496735..3a8bd4d 100644
--- a/hx-ai-intelligent/src/view/alarmManagement/alarmSettings/notificationManagement/linkPeople/index.vue
+++ b/hx-ai-intelligent/src/view/alarmManagement/alarmSettings/notificationManagement/linkPeople/index.vue
@@ -24,20 +24,18 @@
src="https://files.axshare.com/gsc/4T0UQR/7e/5d/a2/7e5da2a277344db8af30521cefeb70cc/images/告警设置/u150.svg?pageId=1f58c1ba-b461-4fe8-a2b3-295f1e7b0aa0" />
-
人员列表
+ :size="'middle'">
+
+
+ {{ record.userRoleInfos?.[0].deptRoleInfoList }}
+
+
+
@@ -69,51 +74,23 @@
import { ref, watch, computed } from 'vue';
import { defineComponent } from 'vue';
import type { TreeProps } from 'ant-design-vue';
- import { device } from '/@/api/deviceManage';
+ import { origanizemanage } from '/@/api/origanizemanage';
+ import { department } from '/@/api/origanizemanage';
+
import { http } from '/nerv-lib/util';
// import { editTreeConfig } from './config';
-
- const x = 3;
- const y = 2;
- const z = 1;
- const genData: TreeProps['treeData'] = [];
-
- const generateData = (_level: number, _preKey?: string, _tns?: TreeProps['treeData']) => {
- const preKey = _preKey || '0';
- const tns = _tns || genData;
-
- const children = [];
- for (let i = 0; i < x; i++) {
- const key = `${preKey}-${i}`;
- tns.push({ title: key, key });
- if (i < y) {
- children.push(key);
- }
- }
- if (_level < 0) {
- return tns;
- }
- const level = _level - 1;
- children.forEach((key, index) => {
- tns[index].children = [];
- return generateData(level, key, tns[index].children);
- });
- };
- generateData(z);
-
+ //搜索存储
const dataList: TreeProps['treeData'] = [];
const generateList = (data: TreeProps['treeData']) => {
for (let i = 0; i < data.length; i++) {
const node = data[i];
const key = node.key;
- dataList.push({ key, title: key });
+ dataList.push({ key, title: node.title });
if (node.children) {
generateList(node.children);
}
}
};
- generateList(genData);
-
const getParentKey = (
key: string | number,
tree: TreeProps['treeData'],
@@ -133,55 +110,101 @@
};
export default defineComponent({
setup(props, { emit }) {
- // const config = computed(() => {
- // return editTreeConfig(result);
- // });
//组织数
const orgId = ref('');
const result = JSON.parse(sessionStorage.getItem('ORGID')!);
orgId.value = result;
const dataSource = ref([]);
+ const loading = ref(false);
const selectedRowKey = ref([]);
const selectedRow = ref([]);
- const name = ref(null);
+ const realName = ref(null);
+ // 树方法
+ const expandedKeys = ref<(string | number)[]>([]);
+ const selectedKeys = ref([]);
+ const searchValue = ref('');
+ const deviceName = ref('');
+ const autoExpandParent = ref(true);
+ const deptTreeData = ref([]);
+ //选择 组织
+ const selectOrgId = ref('');
+ selectOrgId.value = result;
+ //选择部门
+ const selectDeptId = ref('');
+
const onSearch = () => {
+ pagination.value.current = 1;
+ getList();
+ };
+ const onSelect = (selectedKeys: any, info: any) => {
+ selectedKeys.value = selectedKeys;
+ if (info.node.dataRef.deptInfo) {
+ selectDeptId.value = info.node.dataRef.deptInfo.deptId;
+ selectOrgId.value = info.node.dataRef.deptInfo.orgId;
+ }
+ if (info.node.dataRef.orgInfo) {
+ selectOrgId.value = info.node.dataRef.orgInfo.orgId;
+ selectDeptId.value = '';
+ }
+ pagination.value.current = 1;
+ getList();
+ };
+ // 递归处理部门树数据
+ const processDepartmentTree = (tree) => {
+ tree.forEach((item) => {
+ item.deptInfo = item.deptInfo;
+ item.key = item.deptInfo.deptId;
+ item.title = item.deptInfo.deptName;
+ item.children = processDepartmentTree(item.children); // 递归处理子节点
+ });
+ return tree;
+ };
+
+ // 获取部门树
+ const getDepartList = (params) => {
+ return http.post(department.queryDeptTree, params).then((res) => {
+ const result = res.data.map((item) => ({
+ key: item.orgInfo.orgId,
+ orgInfo: item.orgInfo,
+ title: item.orgInfo.orgName,
+ children: processDepartmentTree(item.deptTrees),
+ }));
+
+ return result;
+ });
+ };
+ //获取树
+ const getTreeData = () => {
+ getDepartList({ orgId: orgId.value }).then((res) => {
+ deptTreeData.value = res;
+ selectedKeys.value = [orgId.value];
+ generateList(deptTreeData.value);
+ });
+ };
+ //获取列表
+ const getList = () => {
+ loading.value = true;
http
- .post(device.queryDevicePage, {
+ .post(origanizemanage.userList, {
pageNum: pagination.value.current,
pageSize: pagination.value.pageSize,
- deviceName: name.value,
- orgId: orgId.value,
+ orgId: selectOrgId.value,
+ deptId: selectDeptId.value,
+ realName: realName.value,
})
.then((res) => {
dataSource.value = res.data.records;
pagination.value.total = res.data.total;
+ loading.value = false;
});
};
- const onSelect = (selectedKeys: any, info: any) => {
- console.log('selected', selectedKeys, info.node.dataRef);
- pagination.value.current = 1;
- onSearch();
- };
-
const handleChangePage = (current: number, pageSize: number) => {
pagination.value.current = current;
pagination.value.pageSize = pageSize;
- http
- .post(device.queryDevicePage, {
- pageNum: pagination.value.current,
- pageSize: pagination.value.pageSize,
- orgId: orgId.value,
- })
- .then((res) => {
- dataSource.value = res.data.records;
- pagination.value.total = res.data.total;
- });
- console.log(selectedRowKey.value, selectedRow.value);
+ getList();
};
- const onSelectChange = (selectedRowKeys: any, selectedRows: any) => {
- console.log(selectedRowKeys, selectedRows);
- console.log(selectedRows, '数据');
+ const onSelectChange = (selectedRowKeys: any, selectedRows: any) => {
selectedRowKey.value = selectedRowKeys;
selectedRow.value = selectedRows;
};
@@ -200,14 +223,14 @@
const columns = [
{
title: '序号',
- dataIndex: 'address',
+ dataIndex: 'index',
customRender: (text: any) => {
return text.index + 1;
},
},
{
title: '姓名',
- dataIndex: 'deviceName',
+ dataIndex: 'realName',
},
{
title: '性别',
@@ -215,7 +238,7 @@
},
{
title: '组织关系',
- dataIndex: 'address',
+ dataIndex: 'orgName',
},
{
title: '部门 ',
@@ -227,48 +250,32 @@
emit('handleOk', { id: selectedRowKey.value, data: selectedRow.value });
show.value = false;
pagination.value.current = 1;
+ realName.value = null;
+ searchValue.value = '';
};
const getData = (data: any) => {
selectedRow.value = data.data;
selectedRowKey.value = data.id;
show.value = true;
- http
- .post(device.queryDevicePage, {
- pageNum: pagination.value.current,
- pageSize: pagination.value.pageSize,
- orgId: orgId.value,
- })
- .then((res) => {
- dataSource.value = res.data.records;
- pagination.value.total = res.data.total;
- });
+ //获取列表
+ getList();
+ //获取树
+ getTreeData();
};
const show = ref(false);
const handleCancel = () => {
// 处理取消按钮的逻辑
pagination.value.current = 1;
+ realName.value = null;
emit('handleCancel', null);
show.value = false;
};
- // 树方法
- const expandedKeys = ref<(string | number)[]>([]);
- const searchValue = ref('');
- const deviceName = ref('');
- const autoExpandParent = ref(true);
- const gData = ref(genData);
-
- const onExpand = (keys: string[]) => {
- expandedKeys.value = keys;
- autoExpandParent.value = false;
- console.log(keys, '数据');
- };
watch(searchValue, (value) => {
- console.log(gData.value, '数据');
-
const expanded = dataList
.map((item: TreeProps['treeData'][number]) => {
if (item.title.indexOf(value) > -1) {
- return getParentKey(item.key, gData.value);
+ console.log(item.title.indexOf(value));
+ return getParentKey(item.key, deptTreeData.value);
}
return null;
})
@@ -276,30 +283,35 @@
expandedKeys.value = expanded;
searchValue.value = value;
autoExpandParent.value = true;
- console.log(expandedKeys.value, '数据');
});
return {
columns,
- name,
+ realName,
orgId,
- // config,
+ processDepartmentTree,
onSearch,
+ getList,
+ loading,
dataSource,
onSelect,
- gData,
- onExpand,
+ deptTreeData,
selectedRow,
selectedRowKey,
autoExpandParent,
expandedKeys,
+ selectedKeys,
onSelectChange,
pagination,
handleOk,
show,
getData,
+ getTreeData,
+ getDepartList,
searchValue,
deviceName,
handleCancel,
+ selectDeptId,
+ selectOrgId,
};
},
});
@@ -313,7 +325,7 @@
width: 5px;
height: 15px;
background: inherit;
- background-color: rgba(251, 156, 67, 1);
+ background-color: @primary-color;
border: none;
border-radius: 5px;
-moz-box-shadow: none;
diff --git a/hx-ai-intelligent/src/view/alarmManagement/alarmSettings/ts/energyAlarmConfig.ts b/hx-ai-intelligent/src/view/alarmManagement/alarmSettings/ts/energyAlarmConfig.ts
index d5caddf..5edbf31 100644
--- a/hx-ai-intelligent/src/view/alarmManagement/alarmSettings/ts/energyAlarmConfig.ts
+++ b/hx-ai-intelligent/src/view/alarmManagement/alarmSettings/ts/energyAlarmConfig.ts
@@ -57,7 +57,7 @@ export const energyAlarmConfigs = (
headerActions: [
{
label: '新增',
- name: 'RoleTypeAdd',
+ name: 'energyAlarmAdd',
type: 'primary',
handle: () => {
editeEnergyAlarm.value.toggle();
@@ -65,7 +65,7 @@ export const energyAlarmConfigs = (
},
{
label: '导入',
- name: 'groupImport',
+ name: 'energyAlarmImport',
type: 'primary',
extra: {
title: '设备信息', // 弹窗title
@@ -81,7 +81,7 @@ export const energyAlarmConfigs = (
},
{
label: '导出',
- name: 'groupExports',
+ name: 'energyAlarmExports',
type: 'primary',
handle: () => {
doWnload('/hx-ai-intelligent/asset/file/whiteListUser.xlsx');
@@ -95,7 +95,7 @@ export const energyAlarmConfigs = (
actions: [
{
label: '编辑',
- name: 'FeedBackDetail',
+ name: 'energyAlarmEdit',
dynamicParams: ['uuid', 'appealType'],
handle: (data: any) => {
data.monitorFrequency = data.monitorFrequency.value;
@@ -106,7 +106,7 @@ export const energyAlarmConfigs = (
},
{
label: '配置',
- name: 'FeedBackDetail',
+ name: 'alarmSettingsIndex',
dynamicParams: ['uuid', 'appealType'],
handle: (data: any) => {
energyAlarm.value = !energyAlarm.value;
@@ -115,7 +115,7 @@ export const energyAlarmConfigs = (
},
{
label: '删除',
- name: 'FeedBackDetail',
+ name: 'energyAlarmDel',
dynamicParams: ['uuid', 'appealType'],
confirm: true,
handle: (data: any) => {
diff --git a/hx-ai-intelligent/src/view/alarmManagement/alarmSettings/ts/equipmentAlarmConfig.ts b/hx-ai-intelligent/src/view/alarmManagement/alarmSettings/ts/equipmentAlarmConfig.ts
index 16cc06a..e435364 100644
--- a/hx-ai-intelligent/src/view/alarmManagement/alarmSettings/ts/equipmentAlarmConfig.ts
+++ b/hx-ai-intelligent/src/view/alarmManagement/alarmSettings/ts/equipmentAlarmConfig.ts
@@ -61,7 +61,7 @@ export const equipmentAlarmTableConfig = (
headerActions: [
{
label: '新增',
- name: 'RoleTypeAdd',
+ name: 'equipmentAlarmAdd',
type: 'primary',
handle: () => {
editEquipmentAlarm.value.toggle();
@@ -69,7 +69,7 @@ export const equipmentAlarmTableConfig = (
},
{
label: '导入',
- name: 'groupImport',
+ name: 'equipmentAlarmImport',
type: 'primary',
extra: {
// api: props.postImportApi, // 导入接口名
@@ -86,7 +86,7 @@ export const equipmentAlarmTableConfig = (
},
{
label: '导出',
- name: 'groupExports',
+ name: 'equipmentAlarmExports',
type: 'primary',
handle: () => {
doWnload('/hx-ai-intelligent/asset/file/whiteListUser.xlsx');
@@ -100,7 +100,7 @@ export const equipmentAlarmTableConfig = (
actions: [
{
label: '编辑',
- name: 'FeedBackDetail',
+ name: 'equipmentAlarmEdit',
dynamicParams: ['uuid', 'appealType'],
handle: (data: any) => {
data.priority = data.priority.value;
@@ -111,7 +111,7 @@ export const equipmentAlarmTableConfig = (
},
{
label: '配置',
- name: 'FeedBackDetail',
+ name: 'alarmSettingsIndex',
dynamicParams: ['uuid', 'appealType'],
handle: (data: any) => {
equipmentAlarm.value = !equipmentAlarm.value;
@@ -120,7 +120,7 @@ export const equipmentAlarmTableConfig = (
},
{
label: '删除',
- name: 'FeedBackDetail',
+ name: 'equipmentAlarmDel',
dynamicParams: ['uuid', 'appealType'],
confirm: true,
handle: (data: any) => {
diff --git a/hx-ai-intelligent/src/view/alarmManagement/equipmentAlarm/index.vue b/hx-ai-intelligent/src/view/alarmManagement/equipmentAlarm/index.vue
index 59d78bf..a8e00cc 100644
--- a/hx-ai-intelligent/src/view/alarmManagement/equipmentAlarm/index.vue
+++ b/hx-ai-intelligent/src/view/alarmManagement/equipmentAlarm/index.vue
@@ -12,6 +12,7 @@
import { ref } from 'vue';
export default {
+ name: 'EquipmentAlarmIndex',
components: { Look, Status },
setup() {
diff --git a/hx-ai-intelligent/src/view/alarmManagement/equipmentAlarm/look.vue b/hx-ai-intelligent/src/view/alarmManagement/equipmentAlarm/look.vue
index 62e9a31..baeb5df 100644
--- a/hx-ai-intelligent/src/view/alarmManagement/equipmentAlarm/look.vue
+++ b/hx-ai-intelligent/src/view/alarmManagement/equipmentAlarm/look.vue
@@ -8,7 +8,7 @@
:cancel="handleClose"
placement="right"
@close="handleClose">
-
+
+
+
+
+
+ 紧急
+ 新告警
+ C003
+ 用电量超标
当日用电量超出预设值
+ 1栋10层低压柜
+ 0
+
+
+
+ 确定
+
-
diff --git a/hx-ai-intelligent/src/view/alarmManagement/equipmentAlarm/status.vue b/hx-ai-intelligent/src/view/alarmManagement/equipmentAlarm/status.vue
index d6cb122..9ec1b01 100644
--- a/hx-ai-intelligent/src/view/alarmManagement/equipmentAlarm/status.vue
+++ b/hx-ai-intelligent/src/view/alarmManagement/equipmentAlarm/status.vue
@@ -8,16 +8,81 @@
:cancel="handleClose"
placement="right"
@close="handleClose">
- 状态
+
+ Content of Tab Pane 1
+
+
+
+
+
+
+ 创建工单
+ 确定
+
+
diff --git a/hx-ai-intelligent/src/view/alarmManagement/equipmentAlarm/ts/config.ts b/hx-ai-intelligent/src/view/alarmManagement/equipmentAlarm/ts/config.ts
index 8adc472..8d4092f 100644
--- a/hx-ai-intelligent/src/view/alarmManagement/equipmentAlarm/ts/config.ts
+++ b/hx-ai-intelligent/src/view/alarmManagement/equipmentAlarm/ts/config.ts
@@ -130,18 +130,10 @@ export const notificationtableConfig = (look: any, status: any) => {
],
},
},
- {
- field: 'provider',
- label: '告警标题',
- component: 'NsInput',
- componentProps: {
- placeholder: '请输入告警标题关键字',
- },
- },
{
field: 'provider',
label: '错误码',
- component: 'NsInputApi',
+ component: 'NsInput',
componentProps: {
placeholder: '请输入告警错误码',
},
diff --git a/hx-ai-intelligent/src/view/carbonEmissionManage/carbonEmissionStatistics/carbonEmissions/index copy.vue b/hx-ai-intelligent/src/view/carbonEmissionManage/carbonEmissionStatistics/carbonEmissions/index copy.vue
deleted file mode 100644
index c205a2d..0000000
--- a/hx-ai-intelligent/src/view/carbonEmissionManage/carbonEmissionStatistics/carbonEmissions/index copy.vue
+++ /dev/null
@@ -1,179 +0,0 @@
-
-
-
-
-
-
-
diff --git a/hx-ai-intelligent/src/view/carbonEmissionManage/carbonEmissionStatistics/carbonEmissions/index.vue b/hx-ai-intelligent/src/view/carbonEmissionManage/carbonEmissionStatistics/carbonEmissions/index.vue
index be5bf5b..9298666 100644
--- a/hx-ai-intelligent/src/view/carbonEmissionManage/carbonEmissionStatistics/carbonEmissions/index.vue
+++ b/hx-ai-intelligent/src/view/carbonEmissionManage/carbonEmissionStatistics/carbonEmissions/index.vue
@@ -1,13 +1,13 @@
-
+
();
- const total = ref()
- const queryParams = ref({
- pageNum: 1,
- pageSize: 10,
- })
const orgId = ref('');
const result = JSON.parse(sessionStorage.getItem('ORGID')!);
orgId.value = result;
const fetch = (api, params = { orgId } ) => {
return http.post(api, params);
};
+ const data = ref([]);
+ const selectYear = ref(dayjs( new Date().getFullYear().toString()));
+ const total = ref()
+ const queryParams = ref({
+ pageNum: 1,
+ pageSize: 10,
+ year: selectYear.value.format('YYYY'),
+ orgId: orgId.value
+ })
// 年份选择改变触发
const changeYearData = () => {
- queryParams.value.year = selectYear.value.format('YYYY')
+ queryParams.value.year = selectYear.value
getTableList()
}
+ // 表头
+ const column: TableColumnsType [] = [
+ {
+ title: '排放类型',
+ dataIndex: 'cnValue',
+ customCell: (record, rowIndex) => {
+ if (rowIndex == undefined) {
+ return {
+ rowSpan: 0,
+ colSpan: 0,
+ };
+ }
+ const rowSpan = getRowSpan('cnValue', record, data.value);
+ if (rowIndex != 0 && data.value[rowIndex - 1].name == record.name) {
+ return {
+ rowSpan: 0,
+ colSpan: 0,
+ };
+ }
+ return {
+ rowSpan: rowSpan,
+ };
+ },
+ },
+ {
+ title: '能源种类',
+ dataIndex: 'energyType',
+ },
+ {
+ title: '计量单位',
+ dataIndex: 'unit',
+ },
+ {
+ title: '加权平均',
+ dataIndex: 'averageFactorValue',
+ },
+ {
+ title: '全年',
+ dataIndex: 'carbonYearly',
+ },
+ {
+ title: '1月',
+ dataIndex: 'jan',
+ },
+ {
+ title: '2月',
+ dataIndex: 'feb',
+ },
+ {
+ title: '3月',
+ dataIndex: 'mar',
+ },
+ {
+ title: '4月',
+ dataIndex: 'apr',
+ },
+ {
+ title: '5月',
+ dataIndex: 'may',
+ },
+ {
+ title: '6月',
+ dataIndex: 'jun',
+ },
+ {
+ title: '7月',
+ dataIndex: 'jul',
+ },
+ {
+ title: '8月',
+ dataIndex: 'aug',
+ },
+ {
+ title: '9月',
+ dataIndex: 'sep',
+ },
+ {
+ title: '10月',
+ dataIndex: 'oct',
+ },
+ {
+ title: '11月',
+ dataIndex: 'nov',
+ },
+ {
+ title: '12月',
+ dataIndex: 'dec',
+ },
+ ];
+ // 合并单元格
+ const getRowSpan = (dataIndex: string, record: any, data: any, dependents: string[] = []) => {
+ let rowSpan = 1;
+ for (let i = data.indexOf(record) + 1; i < data.length; i++) {
+ let shouldMerge = true;
+ for (const dependent of dependents) {
+ if (data[i][dependent] !== record[dependent]) {
+ shouldMerge = false;
+ break;
+ }
+ }
+ if (shouldMerge && data[i][dataIndex] === record[dataIndex]) {
+ rowSpan++;
+ } else {
+ break;
+ }
+ }
+ return rowSpan;
+ };
// 获取表格数据
const getTableList = () => {
- fetch(energyConsumption.pageList , queryParams.value).then((res) => {
+ fetch(carbonEmission.carbonEmissionStatistics , queryParams.value).then((res) => {
data.value = res.data.records
total.value = res.data.total
});
diff --git a/hx-ai-intelligent/src/view/carbonEmissionManage/carbonEmissionStatistics/config.ts b/hx-ai-intelligent/src/view/carbonEmissionManage/carbonEmissionStatistics/config.ts
index 6c8fd15..6f69329 100644
--- a/hx-ai-intelligent/src/view/carbonEmissionManage/carbonEmissionStatistics/config.ts
+++ b/hx-ai-intelligent/src/view/carbonEmissionManage/carbonEmissionStatistics/config.ts
@@ -1,3 +1,4 @@
+// 能耗统计表表头
export const tableColumns = [
{
title: '序号',
@@ -78,6 +79,7 @@ export const tableColumns = [
width: 130
},
];
+// 碳排速算表表头
export const columns = [
{
title: '序号',
@@ -101,8 +103,8 @@ export const columns = [
},
{
title: '启用时间',
- className: 'startTime ',
- dataIndex: 'startTime ',
+ className: 'startTime',
+ dataIndex: 'startTime',
},
{
title: '结束时间',
@@ -120,6 +122,7 @@ export const columns = [
width: 130
},
];
+// 碳排速算新增页中表头
export const drawerColumns = [
{
title: '名称',
diff --git a/hx-ai-intelligent/src/view/carbonEmissionManage/carbonEmissionStatistics/energyConsumption/index.vue b/hx-ai-intelligent/src/view/carbonEmissionManage/carbonEmissionStatistics/energyConsumption/index.vue
index 7026fdb..78ff753 100644
--- a/hx-ai-intelligent/src/view/carbonEmissionManage/carbonEmissionStatistics/energyConsumption/index.vue
+++ b/hx-ai-intelligent/src/view/carbonEmissionManage/carbonEmissionStatistics/energyConsumption/index.vue
@@ -16,7 +16,7 @@
-
+