Function: MnOnTabStateChange
▸ MnOnTabStateChange(tabName): (target: any, key: any, descriptor: PropertyDescriptor) => void
Decorator that marks a method as an event handler for tab state change event.
This event is fired when the tab state changed.
Remarks
Available on pages: Record only.
Registration: Automatic registration at runtime.
For more information, see Microsoft Client API Reference
Example
Notify on form that the tab state changed
@MnComponent({
scope: {
pageType: "record",
table: "contact"
}
})
export class NotifyOnTabStateChangeComponent {
@MnOnTabStateChange("tab_name")
onTabStateChange(eventArg: FormEventArg) {
eventArg.formCtx.ui.setFormNotification("Tab state changed", "INFO", "TabStateChange");
}
}
Parameters
| Name | Type | Description |
|---|---|---|
tabName | ValueOrConfigPropertyMapper<string> | The name of the tab or a callback function that returns the name of the tab from the component configuration. |
Returns
fn
▸ (target, key, descriptor): void
Parameters
| Name | Type |
|---|---|
target | any |
key | any |
descriptor | PropertyDescriptor |
Returns
void