- 编辑
+ 编辑
新增子节点
上移
下移
@@ -67,7 +67,13 @@
-
+
+
+
+ {{ record.emissionGas.label }}
+
+
+
@@ -406,10 +412,11 @@
editTreeNode.value.type = 'create'
};
// 编辑树节点
- const editTreeNodeData = () => {
+ const editTreeNodeData = (data) => {
operationTree.value='编辑'
treeNodeAdd.value = true;
editTreeNode.value.type = 'update'
+ addTreeNode.value = data.emissionName
}
// 删除树节点
const deleteTreeNode = () => {
@@ -681,6 +688,9 @@
opMap.value.type = 'edit';
opMap.value.fuc = (formData: any) => {
formData.emissionType = formData.emissionType[formData.emissionType.length - 1]
+ if(formData.emissionGas.value){
+ formData.emissionGas = formData.emissionGas.value
+ }
return http.post(carbonEmissionFactorLibrary.creatOrUpdate, formData).then(() => {
mainRef.value?.nsTableRef.reload();
visible.value = false;
@@ -738,27 +748,27 @@
options: [
{
label: 'CO2',
- value: '1',
+ value: 1,
},
{
label: 'CO2e',
- value: '2',
+ value: 2,
},
{
label: 'SF6',
- value:'3',
+ value:3,
},
{
label: 'CH4',
- value: '4',
+ value: 4,
},
{
label: 'PFCs',
- value: '5',
+ value: 5,
},
{
label: 'HFCs',
- value: '6',
+ value: 6,
},
],
},
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 15a471c..410741c 100644
--- a/hx-ai-intelligent/src/view/carbonEmissionManage/carbonEmissionStatistics/energyConsumption/index.vue
+++ b/hx-ai-intelligent/src/view/carbonEmissionManage/carbonEmissionStatistics/energyConsumption/index.vue
@@ -27,7 +27,7 @@