mirror of
https://codeup.aliyun.com/67762337eccfc218f6110e0e/vue/fe-manage.git
synced 2025-12-06 09:26:44 +08:00
Merge branch 'zcwy_0827_pingcode817' into dev_master
This commit is contained in:
@@ -11,7 +11,7 @@
|
||||
:options="options"
|
||||
showSearch
|
||||
allowClear
|
||||
@select="handleSelect"
|
||||
@change="handleChange"
|
||||
>
|
||||
</a-select>
|
||||
</template>
|
||||
@@ -25,19 +25,20 @@ const props = defineProps({
|
||||
})
|
||||
const emit = defineEmits(['update:value','update:label'])
|
||||
const store = useStore();
|
||||
const numValue = ref(props.value)
|
||||
const handleSelect = (value,option) => {
|
||||
emit('update:value',value)
|
||||
emit('update:label',option.id)
|
||||
};
|
||||
const numValue = ref(props.value||null)
|
||||
const handleChange = (value,option)=>{
|
||||
emit('update:value',value || '')
|
||||
emit('update:label',option?.label || '')
|
||||
}
|
||||
onMounted(() => {
|
||||
// console.log(store.state.project_number,'xixixixii')
|
||||
// console.log(store.state.project_number,'store.state.project_number')
|
||||
});
|
||||
const options = ref([
|
||||
{id:4,value:1,label:1},
|
||||
{id:5,value:2,label:2},
|
||||
{id:6,value:3,label:3},
|
||||
])
|
||||
const options = computed(()=>store.state.project_number.map(e => {
|
||||
return{
|
||||
value: e.value,
|
||||
label: e.name
|
||||
}
|
||||
}))
|
||||
</script>
|
||||
|
||||
<style lang="scss" scoped>
|
||||
|
||||
@@ -344,8 +344,8 @@ export default {
|
||||
});
|
||||
watch(()=>state.projectInfo.boeFlag,(val)=>{
|
||||
if(!val){
|
||||
state.projectInfo.numValue = null
|
||||
state.projectInfo.numLabel = null
|
||||
state.projectInfo.numValue = ''
|
||||
state.projectInfo.numLabel = ''
|
||||
}
|
||||
})
|
||||
|
||||
|
||||
Reference in New Issue
Block a user