|
|
@ -35,8 +35,10 @@ |
|
|
|
data.energyType.substring(data.energyType.indexOf(searchValue) + searchValue.length) |
|
|
|
}} |
|
|
|
</span> --> |
|
|
|
<span v-if="data.code">{{ truncatedName(data.energyType + data.code) }}</span> |
|
|
|
<span v-else>{{ truncatedName(data.energyType) }}</span> |
|
|
|
<span v-if="data.code" :title="data.energyType + data.code"> |
|
|
|
{{ truncatedName(data.energyType + data.code) }} |
|
|
|
</span> |
|
|
|
<span v-else :title="data.energyType">{{ truncatedName(data.energyType) }}</span> |
|
|
|
</template> |
|
|
|
</a-tree> |
|
|
|
</div> |
|
|
@ -228,8 +230,10 @@ |
|
|
|
autoExpandParent.value = false; |
|
|
|
}; |
|
|
|
const truncatedName = (name) => { |
|
|
|
if (name.length > 8) { |
|
|
|
return name.substring(0, 8) + '...'; |
|
|
|
if (name) { |
|
|
|
if (name.length > 8) { |
|
|
|
return name.substring(0, 8) + '...'; |
|
|
|
} |
|
|
|
} |
|
|
|
return name; |
|
|
|
}; |
|
|
@ -511,12 +515,14 @@ |
|
|
|
const config = setFactorConfig(orgId.value, treeId.value, tableId.value); |
|
|
|
const selectFactor = () => { |
|
|
|
openVisible.value = true; |
|
|
|
nextTick(() => { |
|
|
|
setFactorRef.value.nsTableRef.params.emissionList = treeId.value; |
|
|
|
setFactorRef.value.nsTableRef.treeElRef.selectedKeys = treeId.value; |
|
|
|
setFactorRef.value.nsTableRef.rowSelection.selectedRowKeys = tableId.value; |
|
|
|
setFactorRef.value.nsTableRef.reload(); |
|
|
|
}); |
|
|
|
if (treeId.value.length > 0) { |
|
|
|
nextTick(() => { |
|
|
|
setFactorRef.value.nsTableRef.params.emissionList = treeId.value; |
|
|
|
setFactorRef.value.nsTableRef.treeElRef.selectedKeys = treeId.value; |
|
|
|
setFactorRef.value.nsTableRef.rowSelection.selectedRowKeys = tableId.value; |
|
|
|
setFactorRef.value.nsTableRef.reload(); |
|
|
|
}); |
|
|
|
} |
|
|
|
}; |
|
|
|
const btnClick = () => { |
|
|
|
let selectRowKeys = setFactorRef.value?.nsTableRef.tableState.selectedRowKeys; |
|
|
@ -585,6 +591,7 @@ |
|
|
|
box-shadow: 0px 2px 20px rgb(69 123 234 / 20%); |
|
|
|
:deep(.ns-table-main) { |
|
|
|
border-radius: 8px !important; |
|
|
|
margin-top: unset !important; |
|
|
|
} |
|
|
|
} |
|
|
|
:deep(.ant-table-container) { |
|
|
|