qa-kangzai-vue/src/views/map/popup/components/reservoir.vue

35 lines
1.0 KiB
Vue
Raw Normal View History

<template>
<div>
<div>类型{{ getSelectLabel(reservoirTypeList, info.reservoirType) }}</div>
<div>
工程规模{{ getSelectLabel(reservoirLevelList, info.reservoirLevel) }}
</div>
<div>极限库容万立方米{{ info.maxCapacity }}</div>
<div>当前库容万立方米{{ info.currentCapacity }}</div>
</div>
</template>
<script setup>
import { ref } from "vue";
import { getDataDictionary } from "@/request/data_dictionary.js";
import { getSelectLabel } from "@/assets/js/utils.js";
defineProps({
info: Object,
});
const reservoirTypeList = ref([]);
const reservoirLevelList = ref([]);
const fnGetDictData = async () => {
const [typeRes, levelRes] = await Promise.all([
getDataDictionary({ parentId: "848f91ce29ee1f2d078bc6ec69d440df" }),
getDataDictionary({ parentId: "a8b7c6d5e4f3g2h1i0j9k8l7m6n5o4p" }),
]);
reservoirTypeList.value = typeRes.dictionariesList;
reservoirLevelList.value = levelRes.dictionariesList;
};
fnGetDictData();
</script>
<style scoped lang="scss"></style>