fix: changed resolve endpoint contract form get to post
This commit is contained in:
@@ -0,0 +1,25 @@
|
||||
import * as React from 'react';
|
||||
import type { WebPartContext } from '@microsoft/sp-webpart-base';
|
||||
|
||||
export interface IApprovalViewProps {
|
||||
context: WebPartContext;
|
||||
itemId: number;
|
||||
}
|
||||
|
||||
type ViewComponent = React.ComponentType<IApprovalViewProps>;
|
||||
|
||||
/**
|
||||
* Реестр форм «только для чтения» (режим согласующего): ключ формы → ленивый просмотр.
|
||||
* Добавить просмотр = создать <Форма>View.tsx + строка здесь.
|
||||
*/
|
||||
const viewRegistry: Record<string, React.LazyExoticComponent<ViewComponent>> = {
|
||||
'recruiting-hire': React.lazy(
|
||||
() => import(/* webpackChunkName: 'view-recruiting-hire' */ './RecruitingHire/RecruitingHireView')
|
||||
)
|
||||
};
|
||||
|
||||
export function getViewComponent(
|
||||
formKey: string
|
||||
): React.LazyExoticComponent<ViewComponent> | undefined {
|
||||
return viewRegistry[formKey];
|
||||
}
|
||||
Reference in New Issue
Block a user