Browse Source

供应商对账管理添加询证按钮

hella_online_20241121
yufei_wang 1 week ago
parent
commit
d5b3f9f82a
  1. 11
      src/components/Search/src/Search.vue
  2. 27
      src/views/wms/supplierManage/supplierApbalance/supplierApbalanceMain/index.vue

11
src/components/Search/src/Search.vue

@ -273,6 +273,14 @@ const reset = async () => {
emit('reset', model)
}
const getSearchFormData = async () => {
await unref(elFormRef)?.validate()
const { getFormData } = methods
const model = await getFormData()
console.log(model)
return model
}
const bottonButtonStyle = computed(() => {
return {
textAlign: props.buttomPosition as unknown as 'left' | 'center' | 'right'
@ -293,7 +301,7 @@ const onBlur = async (field, e) => {
}
const Search = ref()
onMounted(() => {})
defineExpose({setFormValues,search}) // open
defineExpose({setFormValues,search,getSearchFormData}) // open
</script>
@ -319,6 +327,7 @@ defineExpose({setFormValues,search}) // 提供 open 方法,用于打开弹窗
>
<template #action>
<div v-if="layout === 'inline'">
<slot name="actionMoreTop"></slot>
<!-- update by 芋艿去除搜索的 type="primary"颜色变淡一点 -->
<ElButton type="info" plain v-if="showSearch" @click="search">
<Icon class="mr-5px" icon="ep:search" />

27
src/views/wms/supplierManage/supplierApbalance/supplierApbalanceMain/index.vue

@ -17,6 +17,13 @@
<el-option v-for="dict in dayList" :key="dict.value" :label="dict.label" :value="dict.value"/>
</el-select>
</template>
<template #actionMoreTop>
<el-button type="primary" @click="confirmationHandle">
<Icon class="mr-5px" icon="ep:" />
询证
<Icon class="ml-5px" icon="ep:" />
</el-button>
</template>
</Search>
</ContentWrap>
@ -347,7 +354,27 @@ const getMonthDay = async ()=>{
console.log('monthList',monthList.value)
}
}
//
const confirmationHandle = async ()=>{
let searchData = await searchRef.value.getSearchFormData()
if((year.value||month.value||day.value)&&(!year.value||!month.value||!day.value)){
message.error('请选择年月日')
return
}
if(month.value.length==1){
month.value = '0'+month.value
}
if((''+day.value).length==1){
day.value = '0' + day.value
}
if(year.value&&month.value&&day.value){
// -- `${year.value}-${month.value}-${day.value}`
}
// searchData.ttSupplier
}
const searchRef = ref()
//
const dayList = ref([])

Loading…
Cancel
Save