|
@@ -152,6 +152,44 @@ export const formSchema: FormSchema[] = [
|
|
|
field: 'thirdType',
|
|
field: 'thirdType',
|
|
|
component: 'Input',
|
|
component: 'Input',
|
|
|
defaultValue: '_thirdPartyUser',
|
|
defaultValue: '_thirdPartyUser',
|
|
|
|
|
+ show: false,
|
|
|
|
|
+ },
|
|
|
|
|
+ {
|
|
|
|
|
+ label: '角色',
|
|
|
|
|
+ field: 'selectedroles',
|
|
|
|
|
+ component: 'ApiSelect',
|
|
|
|
|
+ componentProps: {
|
|
|
|
|
+ mode: 'multiple',
|
|
|
|
|
+ api: getAllRolesList,
|
|
|
|
|
+ labelField: 'roleName',
|
|
|
|
|
+ valueField: 'id',
|
|
|
|
|
+ },
|
|
|
|
|
+ },
|
|
|
|
|
+ {
|
|
|
|
|
+ label: '所属部门',
|
|
|
|
|
+ field: 'selecteddeparts',
|
|
|
|
|
+ component: 'JSelectDept',
|
|
|
|
|
+ required: true,
|
|
|
|
|
+ componentProps: ({ formActionType, formModel }) => {
|
|
|
|
|
+ return {
|
|
|
|
|
+ sync: false,
|
|
|
|
|
+ checkStrictly: true,
|
|
|
|
|
+ defaultExpandLevel: 2,
|
|
|
|
|
+
|
|
|
|
|
+ onSelect: (options, values) => {
|
|
|
|
|
+ const { updateSchema } = formActionType;
|
|
|
|
|
+ //所属部门修改后更新负责部门下拉框数据
|
|
|
|
|
+ updateSchema([
|
|
|
|
|
+ {
|
|
|
|
|
+ field: 'departIds',
|
|
|
|
|
+ componentProps: { options },
|
|
|
|
|
+ },
|
|
|
|
|
+ ]);
|
|
|
|
|
+ //所属部门修改后更新负责部门数据
|
|
|
|
|
+ formModel.departIds && (formModel.departIds = formModel.departIds.filter((item) => values.value.indexOf(item) > -1));
|
|
|
|
|
+ },
|
|
|
|
|
+ };
|
|
|
|
|
+ },
|
|
|
},
|
|
},
|
|
|
];
|
|
];
|
|
|
|
|
|