| | |
| | | <div class="expect-position-page-footer"> |
| | | <div class="expect-position-select-wrapper" v-if="checkdList.length > 0"> |
| | | <div class="expect-position-select-item" v-for="(item, index) in checkdList" :key="index"> |
| | | <div class="expect-position-select-item-text">{{ item.name }}</div> |
| | | <div class="expect-position-select-item-text">{{ item.label }}</div> |
| | | <div class="expect-position-select-item-icon-wrapper"> |
| | | <Close |
| | | :size="8" |
| | | class="expect-position-select-item-icon" |
| | | @click="handleDelete(item.id)" |
| | | @click="handleDelete(item.value)" |
| | | /> |
| | | </div> |
| | | </div> |
| | |
| | | |
| | | <script setup lang="ts"> |
| | | import { PositionSelectView } from '@12333/components'; |
| | | import { SearchType } from '@12333/constants'; |
| | | import { useSearchSettingType } from '@12333/hooks'; |
| | | import { CategoryCode } from '@12333/constants'; |
| | | import { useDictionaryDataSelect } from '@12333/hooks'; |
| | | import { Close } from '@nutui/icons-vue-taro'; |
| | | import Taro from '@tarojs/taro'; |
| | | import { size } from 'lodash'; |
| | |
| | | |
| | | const positionList = ref([]); |
| | | |
| | | const { searchSettingTypeList: position } = useSearchSettingType({ |
| | | searchType: SearchType.Position, |
| | | const { dictionaryDataList: position } = useDictionaryDataSelect({ |
| | | categoryCode: CategoryCode.Position, |
| | | }); |
| | | |
| | | const checkdList = computed(() => { |
| | | if (!positionList.value.length) return []; |
| | | return position.value.filter((x) => positionList.value.includes(x.id)); |
| | | return position.value.filter((x) => positionList.value.includes(x.value)); |
| | | }); |
| | | |
| | | function handleDelete(id: string) { |