Browse Source

HL-5399 供应商发票申请-切换账号-采购价格审批人的下拉选项列表数据没更新

hella_online_20240819
wangyufei 3 months ago
parent
commit
c017050282
  1. 8
      src/views/wms/supplierManage/supplierinvoice/supplierinvoiceRequestMain/index.vue
  2. 5
      src/views/wms/supplierManage/supplierinvoice/supplierinvoiceRequestMain/supplierinvoiceRequestMain.data.ts

8
src/views/wms/supplierManage/supplierinvoice/supplierinvoiceRequestMain/index.vue

@ -1401,6 +1401,14 @@ const getLoginUserRoleList = async () => {
/** 初始化 **/
onMounted(async () => {
SupplierinvoiceRequestMain.allSchemas.formSchema.forEach(async item=>{
if(item.field == 'procurementCreator'){
//
const procurementCreators = await SupplierinvoiceRequestMainApi.queryUserInfoByRoleCode({ roleCode: 'purchase',pageSize: 1000,pageNo: 1,sort: '',by: 'ASC' })
item.componentProps.options = procurementCreators.list
}
})
getList()
getDefaultSupplier()
getLoginUserRoleList()

5
src/views/wms/supplierManage/supplierinvoice/supplierinvoiceRequestMain/supplierinvoiceRequestMain.data.ts

@ -29,7 +29,7 @@ const requestsettingData = data?.list[0] || {}
userDept.id = userDept.id.toString()
const userDeptArray:any = [userDept]
const procurementCreators = await SupplierinvoiceRequestMainApi.queryUserInfoByRoleCode({ roleCode: 'purchase',pageSize: 1000,pageNo: 1,sort: '',by: 'ASC' })
// const procurementCreators = await SupplierinvoiceRequestMainApi.queryUserInfoByRoleCode({ roleCode: 'purchase',pageSize: 1000,pageNo: 1,sort: '',by: 'ASC' })
/**
* @returns {Array}
*/
@ -809,8 +809,9 @@ export const SupplierinvoiceRequestMain = useCrudSchemas(reactive<CrudSchema[]>(
isDetail:false,
form: {
component: 'Select',
api: () => procurementCreators.list,
// api: () => procurementCreators.list,
componentProps: {
options:[],
optionsAlias: {
labelField: 'nickname',
valueField: 'id'

Loading…
Cancel
Save