docs:修复demo问题

This commit is contained in:
hsm-lv 2022-04-29 18:15:33 +08:00
parent 34621b22aa
commit 6f95fb6db6
2 changed files with 43 additions and 29 deletions

View File

@ -195,16 +195,20 @@ order: 9
actions: [
{
actionType: 'toast',
args: {
msg: 'confirm'
}
}
]
},
cancel: {
actions: [
{
actionType: 'toast',
args: {
msg: 'cancel'
}
}
]
}
}
@ -346,16 +350,20 @@ order: 9
actions: [
{
actionType: 'toast',
args: {
msg: 'confirm'
}
}
]
},
cancel: {
actions: [
{
actionType: 'toast',
args: {
msg: 'cancel'
}
}
]
}
}
@ -2382,7 +2390,7 @@ order: 9
actionType: 'changeActiveKey',
componentId: 'tabs-change-receiver',
args: {
activeKey: 1
activeKey: 2
}
}
]

View File

@ -10,7 +10,12 @@ import { ICmptAction } from './CmptAction';
import {IContinueAction} from './ContinueAction';
import {ICopyAction} from './CopyAction';
import {ICustomAction} from './CustomAction';
import { IAlertAction, IConfirmAction, IDialogAction, ICloseDialogAction } from './DialogAction';
import {
IAlertAction,
IConfirmAction,
IDialogAction,
ICloseDialogAction
} from './DialogAction';
import {IDrawerAction, ICloseDrawerAction} from './DrawerAction';
import {IEmailAction} from './EmailAction';
import {ILinkAction} from './LinkAction';
@ -20,7 +25,6 @@ import { IParallelAction } from './ParallelAction';
import {ISwitchAction} from './SwitchAction';
import {IToastAction} from './ToastAction';
// 循环动作执行状态
export enum LoopStatus {
NORMAL,
@ -161,7 +165,9 @@ export const runAction = async (
let args = event.data;
if (actionConfig.args) {
args = dataMapping(actionConfig.args, mergeData, (key) => ['adaptor', 'responseAdaptor', 'requestAdaptor'].includes(key));
args = dataMapping(actionConfig.args, mergeData, key =>
['adaptor', 'responseAdaptor', 'requestAdaptor'].includes(key)
);
}
await actionInstrance.run(