feat: add attributes to the ModalAction
Add the onFinishAction and onCancelAction which are from the ListPage component to the ModalAction, add the modalProps to the ModalAction, these attritubes will make custom operations in the ModalAction to easily control the ListPage Change-Id: Ibd81bc6331fa09a3c70fcfc6f1f72ccc3e6f9c37
This commit is contained in:
@@ -455,7 +455,15 @@ export class ActionButton extends Component {
|
||||
if (!visible) {
|
||||
return null;
|
||||
}
|
||||
const { title, action, item, containerProps, items } = this.props;
|
||||
const {
|
||||
title,
|
||||
action,
|
||||
item,
|
||||
containerProps,
|
||||
items,
|
||||
onFinishAction,
|
||||
onCancelAction,
|
||||
} = this.props;
|
||||
const ActionComponent = action;
|
||||
const {
|
||||
okText,
|
||||
@@ -493,6 +501,9 @@ export class ActionButton extends Component {
|
||||
items={items}
|
||||
ref={this.formRef}
|
||||
containerProps={containerProps}
|
||||
onFinishAction={onFinishAction}
|
||||
onCancelAction={onCancelAction}
|
||||
modalProps={modalProps}
|
||||
/>
|
||||
</Modal>
|
||||
);
|
||||
|
Reference in New Issue
Block a user