getNavigationBehavior (Client API reference)
Returns a navigation behavior object for a stage that can be used to define whether the Create button is available for users to create other table record in a cross-table business process flow navigation scenario.
Note
This method is available only for Unified Interface.
Syntax
stageObj.getNavigationBehavior().allowCreateNew = function () {
return true|false;
}
Returns
Type: Object
Description: An object with the allowCreateNew
property that lets you define whether the Create button will be available in a stage so that user can create an instance of tableB from the tableA form in a cross-table business process flow navigation scenario.
For example, here is the Create button in the Develop stage of the AccountToContactProcess sample business process flow that lets you create a Contact record from the Account form.
The allowCreateNew
property will return undefined for business process flow records that do not implement cross-table navigation.
Example
The following sample code shows how you can hide or display the Create button for an active stage of a business process flow depending on its name.
function sampleFunction(executionContext) {
var formContext = executionContext.getFormContext();
formContext.data.process.getActiveStage().getNavigationBehavior().allowCreateNew = function () {
if (formContext.data.process.getName() === 'Test Process') {
return false; // Create button is not available
}
else {
return true; // Create button is available
}
}
}
Related articles
피드백
https://aka.ms/ContentUserFeedback
출시 예정: 2024년 내내 콘텐츠에 대한 피드백 메커니즘으로 GitHub 문제를 단계적으로 폐지하고 이를 새로운 피드백 시스템으로 바꿀 예정입니다. 자세한 내용은 다음을 참조하세요.다음에 대한 사용자 의견 제출 및 보기