增加指标集类型接口

main
yangyuanshuai 9 months ago
parent d8ae3cc028
commit cea89e47ba

@ -65,3 +65,18 @@ export const getIndexType = ({ paramName, systemCode }): Promise<IResponse> => {
});
};
/** 查询指标集类型树形结构 */
export const getIndexSetTreeApi = async () => {
const res = await request.post({
url: '/RepIndexSet/spi/dataset/RepIndexSet/IndexSetTree',
});
if (res?.body?.menutree?.length > 0) {
const data = res.body.menutree
return data.sort((a:AppCustomRouteRecordRaw, b:AppCustomRouteRecordRaw) => {
return a?.props?.sort && b?.props?.sort ? a.props.sort - b.props.sort : 0
});
}
return [];
};

@ -7,7 +7,8 @@ import {
delRepIndexSetApi,
queryRepIndexSetApi,
importExcelApiUrl,
exportExcelApi
exportExcelApi,
getIndexSetTreeApi
} from '@/api/dataset/RepIndexSet'
import { TableData } from '@/api/dataset/RepIndexSet/types'
@ -185,7 +186,7 @@ const searchSchema = reactive<FormSchema[]>([
},
component: 'TreeSelect',
optionApi: async () => {
const res = await getIndexCategoryTreeApi();
const res = await getIndexSetTreeApi();
IndexTypeParamsList.value = res;
indexType_param_LIST.value = res;
res.forEach(item=>{

Loading…
Cancel
Save