优化DepartmentSelectTree

master
LiuJiaNan 2026-01-22 16:24:50 +08:00
parent 575fd8243f
commit fa39577d88
2 changed files with 4 additions and 1 deletions

View File

@ -12,7 +12,7 @@ export interface Params {
/** 企业类型 */
inType?: number[];
/** 企业类型 */
enterpriseType?: number[];
enterpriseType?: number[] | number;
}
/**

View File

@ -56,6 +56,9 @@ function DepartmentSelectTree(props) {
requestUrl = "/basicInfo/department/listAllTreeByCorpType";
actualParams.eqCorpinfoId = undefined;
actualParams.eqParentId = undefined;
if (actualParams.enterpriseType && !Array.isArray(actualParams.enterpriseType)) {
actualParams.enterpriseType = [actualParams.enterpriseType];
}
}
const { data } = await request(requestUrl, "post", actualParams);