@vyr/element-plus 0.0.13 → 0.0.15
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +1 -22
- package/build/actor/ElButtonActor.d.ts +0 -11
- package/build/actor/ElButtonActor.js +0 -32
- package/build/actor/ElButtonActor.js.map +0 -1
- package/build/actor/ElCascaderActor.d.ts +0 -12
- package/build/actor/ElCascaderActor.js +0 -33
- package/build/actor/ElCascaderActor.js.map +0 -1
- package/build/actor/ElCheckboxActor.d.ts +0 -12
- package/build/actor/ElCheckboxActor.js +0 -34
- package/build/actor/ElCheckboxActor.js.map +0 -1
- package/build/actor/ElColActor.d.ts +0 -14
- package/build/actor/ElColActor.js +0 -25
- package/build/actor/ElColActor.js.map +0 -1
- package/build/actor/ElDatePickerActor.d.ts +0 -12
- package/build/actor/ElDatePickerActor.js +0 -31
- package/build/actor/ElDatePickerActor.js.map +0 -1
- package/build/actor/ElDialogActor.d.ts +0 -11
- package/build/actor/ElDialogActor.js +0 -28
- package/build/actor/ElDialogActor.js.map +0 -1
- package/build/actor/ElFormActor.d.ts +0 -12
- package/build/actor/ElFormActor.js +0 -33
- package/build/actor/ElFormActor.js.map +0 -1
- package/build/actor/ElFormItemActor.d.ts +0 -23
- package/build/actor/ElFormItemActor.js +0 -73
- package/build/actor/ElFormItemActor.js.map +0 -1
- package/build/actor/ElInputActor.d.ts +0 -25
- package/build/actor/ElInputActor.js +0 -36
- package/build/actor/ElInputActor.js.map +0 -1
- package/build/actor/ElInputNumberActor.d.ts +0 -12
- package/build/actor/ElInputNumberActor.js +0 -28
- package/build/actor/ElInputNumberActor.js.map +0 -1
- package/build/actor/ElMenuActor.d.ts +0 -11
- package/build/actor/ElMenuActor.js +0 -25
- package/build/actor/ElMenuActor.js.map +0 -1
- package/build/actor/ElMenuItemActor.d.ts +0 -17
- package/build/actor/ElMenuItemActor.js +0 -33
- package/build/actor/ElMenuItemActor.js.map +0 -1
- package/build/actor/ElPaginationActor.d.ts +0 -21
- package/build/actor/ElPaginationActor.js +0 -81
- package/build/actor/ElPaginationActor.js.map +0 -1
- package/build/actor/ElRadioActor.d.ts +0 -12
- package/build/actor/ElRadioActor.js +0 -34
- package/build/actor/ElRadioActor.js.map +0 -1
- package/build/actor/ElRowActor.d.ts +0 -14
- package/build/actor/ElRowActor.js +0 -26
- package/build/actor/ElRowActor.js.map +0 -1
- package/build/actor/ElSelectActor.d.ts +0 -12
- package/build/actor/ElSelectActor.js +0 -37
- package/build/actor/ElSelectActor.js.map +0 -1
- package/build/actor/ElSubMenuActor.d.ts +0 -17
- package/build/actor/ElSubMenuActor.js +0 -33
- package/build/actor/ElSubMenuActor.js.map +0 -1
- package/build/actor/ElSwitchActor.d.ts +0 -9
- package/build/actor/ElSwitchActor.js +0 -17
- package/build/actor/ElSwitchActor.js.map +0 -1
- package/build/actor/ElTableActor.d.ts +0 -11
- package/build/actor/ElTableActor.js +0 -25
- package/build/actor/ElTableActor.js.map +0 -1
- package/build/actor/ElTableColumnActor.d.ts +0 -26
- package/build/actor/ElTableColumnActor.js +0 -57
- package/build/actor/ElTableColumnActor.js.map +0 -1
- package/build/actor/index.d.ts +0 -20
- package/build/actor/index.js +0 -21
- package/build/actor/index.js.map +0 -1
- package/build/asset/index.d.ts +0 -1
- package/build/asset/index.js +0 -18
- package/build/asset/index.js.map +0 -1
- package/build/descriptor/ElButtonDescriptor.d.ts +0 -16
- package/build/descriptor/ElButtonDescriptor.js +0 -29
- package/build/descriptor/ElButtonDescriptor.js.map +0 -1
- package/build/descriptor/ElCascaderDescriptor.d.ts +0 -19
- package/build/descriptor/ElCascaderDescriptor.js +0 -35
- package/build/descriptor/ElCascaderDescriptor.js.map +0 -1
- package/build/descriptor/ElCheckboxDescriptor.d.ts +0 -18
- package/build/descriptor/ElCheckboxDescriptor.js +0 -33
- package/build/descriptor/ElCheckboxDescriptor.js.map +0 -1
- package/build/descriptor/ElColDescriptor.d.ts +0 -9
- package/build/descriptor/ElColDescriptor.js +0 -14
- package/build/descriptor/ElColDescriptor.js.map +0 -1
- package/build/descriptor/ElDatePickerDescriptor.d.ts +0 -19
- package/build/descriptor/ElDatePickerDescriptor.js +0 -35
- package/build/descriptor/ElDatePickerDescriptor.js.map +0 -1
- package/build/descriptor/ElDialogDescriptor.d.ts +0 -9
- package/build/descriptor/ElDialogDescriptor.js +0 -18
- package/build/descriptor/ElDialogDescriptor.js.map +0 -1
- package/build/descriptor/ElFormDescriptor.d.ts +0 -19
- package/build/descriptor/ElFormDescriptor.js +0 -44
- package/build/descriptor/ElFormDescriptor.js.map +0 -1
- package/build/descriptor/ElFormItemDescriptor.d.ts +0 -9
- package/build/descriptor/ElFormItemDescriptor.js +0 -5
- package/build/descriptor/ElFormItemDescriptor.js.map +0 -1
- package/build/descriptor/ElInputDescriptor.d.ts +0 -25
- package/build/descriptor/ElInputDescriptor.js +0 -47
- package/build/descriptor/ElInputDescriptor.js.map +0 -1
- package/build/descriptor/ElInputNumberDescriptor.d.ts +0 -17
- package/build/descriptor/ElInputNumberDescriptor.js +0 -31
- package/build/descriptor/ElInputNumberDescriptor.js.map +0 -1
- package/build/descriptor/ElMenuDescriptor.d.ts +0 -12
- package/build/descriptor/ElMenuDescriptor.js +0 -21
- package/build/descriptor/ElMenuDescriptor.js.map +0 -1
- package/build/descriptor/ElMenuItemDescriptor.d.ts +0 -10
- package/build/descriptor/ElMenuItemDescriptor.js +0 -16
- package/build/descriptor/ElMenuItemDescriptor.js.map +0 -1
- package/build/descriptor/ElPaginationDescriptor.d.ts +0 -21
- package/build/descriptor/ElPaginationDescriptor.js +0 -43
- package/build/descriptor/ElPaginationDescriptor.js.map +0 -1
- package/build/descriptor/ElRadioDescriptor.d.ts +0 -18
- package/build/descriptor/ElRadioDescriptor.js +0 -33
- package/build/descriptor/ElRadioDescriptor.js.map +0 -1
- package/build/descriptor/ElRowDescriptor.d.ts +0 -10
- package/build/descriptor/ElRowDescriptor.js +0 -16
- package/build/descriptor/ElRowDescriptor.js.map +0 -1
- package/build/descriptor/ElSelectDescriptor.d.ts +0 -19
- package/build/descriptor/ElSelectDescriptor.js +0 -35
- package/build/descriptor/ElSelectDescriptor.js.map +0 -1
- package/build/descriptor/ElSubMenuDescriptor.d.ts +0 -9
- package/build/descriptor/ElSubMenuDescriptor.js +0 -14
- package/build/descriptor/ElSubMenuDescriptor.js.map +0 -1
- package/build/descriptor/ElSwitchDescriptor.d.ts +0 -15
- package/build/descriptor/ElSwitchDescriptor.js +0 -27
- package/build/descriptor/ElSwitchDescriptor.js.map +0 -1
- package/build/descriptor/ElTableColumnDescriptor.d.ts +0 -19
- package/build/descriptor/ElTableColumnDescriptor.js +0 -34
- package/build/descriptor/ElTableColumnDescriptor.js.map +0 -1
- package/build/descriptor/ElTableDescriptor.d.ts +0 -12
- package/build/descriptor/ElTableDescriptor.js +0 -20
- package/build/descriptor/ElTableDescriptor.js.map +0 -1
- package/build/descriptor/index.d.ts +0 -20
- package/build/descriptor/index.js +0 -21
- package/build/descriptor/index.js.map +0 -1
- package/build/index.d.ts +0 -7
- package/build/index.js +0 -8
- package/build/index.js.map +0 -1
- package/build/interpreter/ElButtonInterpreter.d.ts +0 -8
- package/build/interpreter/ElButtonInterpreter.js +0 -13
- package/build/interpreter/ElButtonInterpreter.js.map +0 -1
- package/build/interpreter/ElCascaderInterpreter.d.ts +0 -8
- package/build/interpreter/ElCascaderInterpreter.js +0 -13
- package/build/interpreter/ElCascaderInterpreter.js.map +0 -1
- package/build/interpreter/ElCheckboxInterpreter.d.ts +0 -8
- package/build/interpreter/ElCheckboxInterpreter.js +0 -13
- package/build/interpreter/ElCheckboxInterpreter.js.map +0 -1
- package/build/interpreter/ElColInterpreter.d.ts +0 -8
- package/build/interpreter/ElColInterpreter.js +0 -13
- package/build/interpreter/ElColInterpreter.js.map +0 -1
- package/build/interpreter/ElDatePickerInterpreter.d.ts +0 -8
- package/build/interpreter/ElDatePickerInterpreter.js +0 -13
- package/build/interpreter/ElDatePickerInterpreter.js.map +0 -1
- package/build/interpreter/ElDialogInterpreter.d.ts +0 -8
- package/build/interpreter/ElDialogInterpreter.js +0 -13
- package/build/interpreter/ElDialogInterpreter.js.map +0 -1
- package/build/interpreter/ElFormInterpreter.d.ts +0 -8
- package/build/interpreter/ElFormInterpreter.js +0 -13
- package/build/interpreter/ElFormInterpreter.js.map +0 -1
- package/build/interpreter/ElInputInterpreter.d.ts +0 -8
- package/build/interpreter/ElInputInterpreter.js +0 -13
- package/build/interpreter/ElInputInterpreter.js.map +0 -1
- package/build/interpreter/ElInputNumberInterpreter.d.ts +0 -8
- package/build/interpreter/ElInputNumberInterpreter.js +0 -13
- package/build/interpreter/ElInputNumberInterpreter.js.map +0 -1
- package/build/interpreter/ElMenuInterpreter.d.ts +0 -8
- package/build/interpreter/ElMenuInterpreter.js +0 -13
- package/build/interpreter/ElMenuInterpreter.js.map +0 -1
- package/build/interpreter/ElMenuItemInterpreter.d.ts +0 -8
- package/build/interpreter/ElMenuItemInterpreter.js +0 -13
- package/build/interpreter/ElMenuItemInterpreter.js.map +0 -1
- package/build/interpreter/ElPaginationInterpreter.d.ts +0 -8
- package/build/interpreter/ElPaginationInterpreter.js +0 -13
- package/build/interpreter/ElPaginationInterpreter.js.map +0 -1
- package/build/interpreter/ElRadioInterpreter.d.ts +0 -8
- package/build/interpreter/ElRadioInterpreter.js +0 -13
- package/build/interpreter/ElRadioInterpreter.js.map +0 -1
- package/build/interpreter/ElRowInterpreter.d.ts +0 -8
- package/build/interpreter/ElRowInterpreter.js +0 -13
- package/build/interpreter/ElRowInterpreter.js.map +0 -1
- package/build/interpreter/ElSelectInterpreter.d.ts +0 -8
- package/build/interpreter/ElSelectInterpreter.js +0 -13
- package/build/interpreter/ElSelectInterpreter.js.map +0 -1
- package/build/interpreter/ElSubMenuInterpreter.d.ts +0 -8
- package/build/interpreter/ElSubMenuInterpreter.js +0 -13
- package/build/interpreter/ElSubMenuInterpreter.js.map +0 -1
- package/build/interpreter/ElSwitchInterpreter.d.ts +0 -8
- package/build/interpreter/ElSwitchInterpreter.js +0 -13
- package/build/interpreter/ElSwitchInterpreter.js.map +0 -1
- package/build/interpreter/ElTableColumnInterpreter.d.ts +0 -8
- package/build/interpreter/ElTableColumnInterpreter.js +0 -13
- package/build/interpreter/ElTableColumnInterpreter.js.map +0 -1
- package/build/interpreter/ElTableInterpreter.d.ts +0 -8
- package/build/interpreter/ElTableInterpreter.js +0 -13
- package/build/interpreter/ElTableInterpreter.js.map +0 -1
- package/build/interpreter/index.d.ts +0 -20
- package/build/interpreter/index.js +0 -33
- package/build/interpreter/index.js.map +0 -1
- package/build/locale/Language.d.ts +0 -3
- package/build/locale/Language.js +0 -6
- package/build/locale/Language.js.map +0 -1
- package/build/locale/LanguageProvider.d.ts +0 -21
- package/build/locale/LanguageProvider.js +0 -22
- package/build/locale/LanguageProvider.js.map +0 -1
- package/build/locale/index.d.ts +0 -2
- package/build/locale/index.js +0 -3
- package/build/locale/index.js.map +0 -1
- package/build/preset/execute/ElDialog/close.d.ts +0 -13
- package/build/preset/execute/ElDialog/close.js +0 -35
- package/build/preset/execute/ElDialog/close.js.map +0 -1
- package/build/preset/execute/ElDialog/index.d.ts +0 -2
- package/build/preset/execute/ElDialog/index.js +0 -3
- package/build/preset/execute/ElDialog/index.js.map +0 -1
- package/build/preset/execute/ElDialog/open.d.ts +0 -16
- package/build/preset/execute/ElDialog/open.js +0 -38
- package/build/preset/execute/ElDialog/open.js.map +0 -1
- package/build/preset/execute/ElForm/branch.d.ts +0 -13
- package/build/preset/execute/ElForm/branch.js +0 -34
- package/build/preset/execute/ElForm/branch.js.map +0 -1
- package/build/preset/execute/ElForm/create.d.ts +0 -13
- package/build/preset/execute/ElForm/create.js +0 -22
- package/build/preset/execute/ElForm/create.js.map +0 -1
- package/build/preset/execute/ElForm/edit.d.ts +0 -13
- package/build/preset/execute/ElForm/edit.js +0 -22
- package/build/preset/execute/ElForm/edit.js.map +0 -1
- package/build/preset/execute/ElForm/getData.d.ts +0 -16
- package/build/preset/execute/ElForm/getData.js +0 -41
- package/build/preset/execute/ElForm/getData.js.map +0 -1
- package/build/preset/execute/ElForm/index.d.ts +0 -5
- package/build/preset/execute/ElForm/index.js +0 -6
- package/build/preset/execute/ElForm/index.js.map +0 -1
- package/build/preset/execute/ElForm/reset.d.ts +0 -13
- package/build/preset/execute/ElForm/reset.js +0 -42
- package/build/preset/execute/ElForm/reset.js.map +0 -1
- package/build/preset/execute/ElPagination/getData.d.ts +0 -13
- package/build/preset/execute/ElPagination/getData.js +0 -37
- package/build/preset/execute/ElPagination/getData.js.map +0 -1
- package/build/preset/execute/ElPagination/index.d.ts +0 -2
- package/build/preset/execute/ElPagination/index.js +0 -3
- package/build/preset/execute/ElPagination/index.js.map +0 -1
- package/build/preset/execute/ElPagination/reset.d.ts +0 -13
- package/build/preset/execute/ElPagination/reset.js +0 -34
- package/build/preset/execute/ElPagination/reset.js.map +0 -1
- package/build/preset/execute/ElTable/create.d.ts +0 -9
- package/build/preset/execute/ElTable/create.js +0 -26
- package/build/preset/execute/ElTable/create.js.map +0 -1
- package/build/preset/execute/ElTable/delete.d.ts +0 -9
- package/build/preset/execute/ElTable/delete.js +0 -41
- package/build/preset/execute/ElTable/delete.js.map +0 -1
- package/build/preset/execute/ElTable/edit.d.ts +0 -9
- package/build/preset/execute/ElTable/edit.js +0 -27
- package/build/preset/execute/ElTable/edit.js.map +0 -1
- package/build/preset/execute/ElTable/index.d.ts +0 -3
- package/build/preset/execute/ElTable/index.js +0 -4
- package/build/preset/execute/ElTable/index.js.map +0 -1
- package/build/preset/execute/ElTableColumn/formatter.d.ts +0 -14
- package/build/preset/execute/ElTableColumn/formatter.js +0 -60
- package/build/preset/execute/ElTableColumn/formatter.js.map +0 -1
- package/build/preset/execute/ElTableColumn/index.d.ts +0 -1
- package/build/preset/execute/ElTableColumn/index.js +0 -2
- package/build/preset/execute/ElTableColumn/index.js.map +0 -1
- package/build/preset/execute/index.d.ts +0 -5
- package/build/preset/execute/index.js +0 -6
- package/build/preset/execute/index.js.map +0 -1
- package/build/preset/index.d.ts +0 -3
- package/build/preset/index.js +0 -4
- package/build/preset/index.js.map +0 -1
- package/build/preset/interaction/ElDialog/close.d.ts +0 -5
- package/build/preset/interaction/ElDialog/close.js +0 -19
- package/build/preset/interaction/ElDialog/close.js.map +0 -1
- package/build/preset/interaction/ElDialog/index.d.ts +0 -1
- package/build/preset/interaction/ElDialog/index.js +0 -2
- package/build/preset/interaction/ElDialog/index.js.map +0 -1
- package/build/preset/interaction/ElTable/create.d.ts +0 -7
- package/build/preset/interaction/ElTable/create.js +0 -23
- package/build/preset/interaction/ElTable/create.js.map +0 -1
- package/build/preset/interaction/ElTable/delete.d.ts +0 -7
- package/build/preset/interaction/ElTable/delete.js +0 -23
- package/build/preset/interaction/ElTable/delete.js.map +0 -1
- package/build/preset/interaction/ElTable/edit.d.ts +0 -8
- package/build/preset/interaction/ElTable/edit.js +0 -25
- package/build/preset/interaction/ElTable/edit.js.map +0 -1
- package/build/preset/interaction/ElTable/index.d.ts +0 -6
- package/build/preset/interaction/ElTable/index.js +0 -7
- package/build/preset/interaction/ElTable/index.js.map +0 -1
- package/build/preset/interaction/ElTable/list.d.ts +0 -8
- package/build/preset/interaction/ElTable/list.js +0 -25
- package/build/preset/interaction/ElTable/list.js.map +0 -1
- package/build/preset/interaction/ElTable/reset.d.ts +0 -7
- package/build/preset/interaction/ElTable/reset.js +0 -23
- package/build/preset/interaction/ElTable/reset.js.map +0 -1
- package/build/preset/interaction/ElTable/submit.d.ts +0 -12
- package/build/preset/interaction/ElTable/submit.js +0 -35
- package/build/preset/interaction/ElTable/submit.js.map +0 -1
- package/build/preset/interaction/index.d.ts +0 -2
- package/build/preset/interaction/index.js +0 -3
- package/build/preset/interaction/index.js.map +0 -1
- package/build/utils/form.d.ts +0 -13
- package/build/utils/form.js +0 -61
- package/build/utils/form.js.map +0 -1
- package/build/utils/index.d.ts +0 -3
- package/build/utils/index.js +0 -4
- package/build/utils/index.js.map +0 -1
- package/build/utils/style.d.ts +0 -3
- package/build/utils/style.js +0 -7
- package/build/utils/style.js.map +0 -1
- package/build/utils/validator.d.ts +0 -7
- package/build/utils/validator.js +0 -23
- package/build/utils/validator.js.map +0 -1
|
@@ -1,38 +0,0 @@
|
|
|
1
|
-
import { Asset, Scriptable } from "@vyr/engine";
|
|
2
|
-
import { language } from '../../../locale';
|
|
3
|
-
import { ElDialogDescriptor } from "../../../descriptor";
|
|
4
|
-
const scriptable = Asset.createVirtualUrl('preset/ElDialog/open.ts');
|
|
5
|
-
class InteractionScriptable extends Scriptable {
|
|
6
|
-
async execute(graphics, args) {
|
|
7
|
-
const { input } = args;
|
|
8
|
-
const dialog = input?.user?.dialog.value ?? input.default.dialog.value;
|
|
9
|
-
const title = input?.user?.title.value ?? input.default.title.value;
|
|
10
|
-
const dialogDescriptor = ElDialogDescriptor.get(dialog);
|
|
11
|
-
if (dialogDescriptor === null)
|
|
12
|
-
return;
|
|
13
|
-
dialogDescriptor.title = title;
|
|
14
|
-
dialogDescriptor.visible = true;
|
|
15
|
-
dialogDescriptor.setNeedsUpdate();
|
|
16
|
-
}
|
|
17
|
-
}
|
|
18
|
-
Asset.provider(scriptable, async () => ({ default: InteractionScriptable }));
|
|
19
|
-
const createExecuteInput = (args = {}) => {
|
|
20
|
-
const input = {
|
|
21
|
-
dialog: { value: args.dialog ?? '' },
|
|
22
|
-
title: { value: args.title ?? '' }
|
|
23
|
-
};
|
|
24
|
-
return input;
|
|
25
|
-
};
|
|
26
|
-
const createExecuteNode = (options) => {
|
|
27
|
-
const executeNode = {
|
|
28
|
-
id: options.id,
|
|
29
|
-
label: language.get(scriptable),
|
|
30
|
-
position: { x: options?.position?.x ?? 20, y: options?.position?.y ?? 20 },
|
|
31
|
-
interaction: 'Execute',
|
|
32
|
-
url: scriptable,
|
|
33
|
-
input: createExecuteInput(options.input)
|
|
34
|
-
};
|
|
35
|
-
return executeNode;
|
|
36
|
-
};
|
|
37
|
-
export { scriptable, createExecuteInput, createExecuteNode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G;QACV,MAAM,EAAE,EAAE,KAAK,EAAE,IAAI,CAAC,MAAM,IAAI,EAAE,EAAE;QACpC,KAAK,EAAE,EAAE,KAAK,EAAE,IAAI,CAAC,KAAK,IAAI,EAAE,EAAE;KACrC,CAAA;IAED,OAAO,KAAK,CAAA;AAChB,CAAC,CAAA;AAED,MAAM,iBAAiB,GAAG,CAAC,OAAoD,EAAE,EAAE;IAC/E,MAAM,WAAW,GAAoB;QACjC,EAAE,EAAE,OAAO,CAAC,EAAE;QACd,KAAK,EAAE,QAAQ,CAAC,GAAG,CAAC,UAAiB,CAAC;QACtC,QAAQ,EAAE,EAAE,CAAC,EAAE,OAAO,EAAE,QAAQ,EAAE,CAAC,IAAI,EAAE,EAAE,CAAC,EAAE,OAAO,EAAE,QAAQ,EAAE,CAAC,IAAI,EAAE,EAAE;QAC1E,WAAW,EAAE,SAAS;QACtB,GAAG,EAAE,UAAU;QACf,KAAK,EAAE,kBAAkB,CAAC,OAAO,CAAC,KAAK,CAAC;KAC3C,CAAA;IACD,OAAO,WAAW,CAAA;AACtB,CAAC,CAAA;AAED,OAAO,EACH,UAAU,EACV,kBAAkB,EAClB,iBAAiB,GACpB,CAAA"}
|
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
import { InteractionNode } from "@vyr/engine";
|
|
2
|
-
declare const scriptable: string;
|
|
3
|
-
declare const createExecuteInput: (args?: any) => {
|
|
4
|
-
primaryKey: {
|
|
5
|
-
value: any;
|
|
6
|
-
};
|
|
7
|
-
};
|
|
8
|
-
declare const createExecuteNode: (options: {
|
|
9
|
-
id: string;
|
|
10
|
-
position?: any;
|
|
11
|
-
input?: any;
|
|
12
|
-
}) => InteractionNode;
|
|
13
|
-
export { scriptable, createExecuteInput, createExecuteNode, };
|
|
@@ -1,34 +0,0 @@
|
|
|
1
|
-
import { Asset, Scriptable } from "@vyr/engine";
|
|
2
|
-
import { language } from '../../../locale';
|
|
3
|
-
const scriptable = Asset.createVirtualUrl('preset/ElForm/branch.ts');
|
|
4
|
-
class InteractionScriptable extends Scriptable {
|
|
5
|
-
execute(graphics, args) {
|
|
6
|
-
const { input, result } = args;
|
|
7
|
-
const primaryKey = input?.user?.primaryKey.value ?? input.default.primaryKey.value;
|
|
8
|
-
if (!primaryKey)
|
|
9
|
-
return;
|
|
10
|
-
const formData = result.get(input.previous);
|
|
11
|
-
const value = formData[primaryKey];
|
|
12
|
-
return ['number', 'string'].includes(typeof value) && value.length > 0 ? '1' : '0';
|
|
13
|
-
}
|
|
14
|
-
}
|
|
15
|
-
Asset.provider(scriptable, async () => ({ default: InteractionScriptable }));
|
|
16
|
-
const createExecuteInput = (args = {}) => {
|
|
17
|
-
const input = {
|
|
18
|
-
primaryKey: { value: args.primaryKey ?? 'id' },
|
|
19
|
-
};
|
|
20
|
-
return input;
|
|
21
|
-
};
|
|
22
|
-
const createExecuteNode = (options) => {
|
|
23
|
-
const executeNode = {
|
|
24
|
-
id: options.id,
|
|
25
|
-
label: language.get(scriptable),
|
|
26
|
-
position: { x: options?.position?.x ?? 20, y: options?.position?.y ?? 20 },
|
|
27
|
-
interaction: 'Branch',
|
|
28
|
-
url: scriptable,
|
|
29
|
-
input: createExecuteInput(options.input)
|
|
30
|
-
};
|
|
31
|
-
return executeNode;
|
|
32
|
-
};
|
|
33
|
-
export { scriptable, createExecuteInput, createExecuteNode, };
|
|
34
|
-
//# sourceMappingURL=branch.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"branch.js","sourceRoot":"","sources":["../../../../src/preset/execute/ElForm/branch.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,EAA6B,UAAU,EAAkB,MAAM,aAAa,CAAA;AAC1F,OAAO,EAAE,QAAQ,EAAE,MAAM,iBAAiB,CAAA;AAE1C,MAAM,UAAU,GAAG,KAAK,CAAC,gBAAgB,CAAC,yBAAyB,CAAC,CAAA;AACpE,MAAM,qBAAsB,SAAQ,UAAU;IAC1C,OAAO,CAAC,QAAkB,EAAE,IAA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AG,EAAE,UAAU;QACf,KAAK,EAAE,kBAAkB,CAAC,OAAO,CAAC,KAAK,CAAC;KAC3C,CAAA;IACD,OAAO,WAAW,CAAA;AACtB,CAAC,CAAA;AAED,OAAO,EACH,UAAU,EACV,kBAAkB,EAClB,iBAAiB,GACpB,CAAA"}
|
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
import { InteractionNode } from "@vyr/engine";
|
|
2
|
-
declare const scriptable: string;
|
|
3
|
-
declare const createExecuteInput: (args?: any) => {
|
|
4
|
-
condition: {
|
|
5
|
-
value: any;
|
|
6
|
-
};
|
|
7
|
-
};
|
|
8
|
-
declare const createExecuteNode: (options: {
|
|
9
|
-
id: string;
|
|
10
|
-
position?: any;
|
|
11
|
-
input?: any;
|
|
12
|
-
}) => InteractionNode;
|
|
13
|
-
export { scriptable, createExecuteInput, createExecuteNode, };
|
|
@@ -1,22 +0,0 @@
|
|
|
1
|
-
import { Asset } from "@vyr/engine";
|
|
2
|
-
import { language } from '../../../locale';
|
|
3
|
-
const scriptable = Asset.createVirtualUrl('preset/ElForm/branch/create.ts');
|
|
4
|
-
const createExecuteInput = (args = {}) => {
|
|
5
|
-
const input = {
|
|
6
|
-
condition: { value: args.condition ?? '0' }
|
|
7
|
-
};
|
|
8
|
-
return input;
|
|
9
|
-
};
|
|
10
|
-
const createExecuteNode = (options) => {
|
|
11
|
-
const executeNode = {
|
|
12
|
-
id: options.id,
|
|
13
|
-
label: language.get(scriptable),
|
|
14
|
-
position: { x: options?.position?.x ?? 20, y: options?.position?.y ?? 20 },
|
|
15
|
-
interaction: 'Condition',
|
|
16
|
-
url: '',
|
|
17
|
-
input: createExecuteInput(options.input)
|
|
18
|
-
};
|
|
19
|
-
return executeNode;
|
|
20
|
-
};
|
|
21
|
-
export { scriptable, createExecuteInput, createExecuteNode, };
|
|
22
|
-
//# sourceMappingURL=create.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"create.js","sourceRoot":"","sources":["../../../../src/preset/execute/ElForm/create.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,EAAmB,MAAM,aAAa,CAAA;AACpD,OAAO,EAAE,QAAQ,EAAE,MAAM,iBAAiB,CAAA;AAE1C,MAAM,UAAU,GAAG,KAAK,CAAC,gBAAgB,CAAC,gCAAgC,CAAC,CAAA;AAE3E,MAAM,kBAAkB,GAAG,CAAC,OAAY,EAAE,EAAE,EAAE;IAC1C,MAAM,KAAK,GAAG;QACV,SAAS,EAAE,EAAE,KAAK,EAAE,IAAI,CAAC,SAAS,IAAI,GAAG,EAAE;KAC9C,CAAA;IAED,OAAO,KAAK,CAAA;AAChB,CAAC,CAAA;AAED,MAAM,iBAAiB,GAAG,CAAC,OAAoD,EAAE,EAAE;IAC/E,MAAM,WAAW,GAAoB;QACjC,EAAE,EAAE,OAAO,CAAC,EAAE;QACd,KAAK,EAAE,QAAQ,CAAC,GAAG,CAAC,UAAiB,CAAC;QACtC,QAAQ,EAAE,EAAE,CAAC,EAAE,OAAO,EAAE,QAAQ,EAAE,CAAC,IAAI,EAAE,EAAE,CAAC,EAAE,OAAO,EAAE,QAAQ,EAAE,CAAC,IAAI,EAAE,EAAE;QAC1E,WAAW,EAAE,WAAW;QACxB,GAAG,EAAE,EAAE;QACP,KAAK,EAAE,kBAAkB,CAAC,OAAO,CAAC,KAAK,CAAC;KAC3C,CAAA;IACD,OAAO,WAAW,CAAA;AACtB,CAAC,CAAA;AAED,OAAO,EACH,UAAU,EACV,kBAAkB,EAClB,iBAAiB,GACpB,CAAA"}
|
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
import { InteractionNode } from "@vyr/engine";
|
|
2
|
-
declare const scriptable: string;
|
|
3
|
-
declare const createExecuteInput: (args?: any) => {
|
|
4
|
-
condition: {
|
|
5
|
-
value: any;
|
|
6
|
-
};
|
|
7
|
-
};
|
|
8
|
-
declare const createExecuteNode: (options: {
|
|
9
|
-
id: string;
|
|
10
|
-
position?: any;
|
|
11
|
-
input?: any;
|
|
12
|
-
}) => InteractionNode;
|
|
13
|
-
export { scriptable, createExecuteInput, createExecuteNode, };
|
|
@@ -1,22 +0,0 @@
|
|
|
1
|
-
import { Asset } from "@vyr/engine";
|
|
2
|
-
import { language } from '../../../locale';
|
|
3
|
-
const scriptable = Asset.createVirtualUrl('preset/ElForm/branch/edit.ts');
|
|
4
|
-
const createExecuteInput = (args = {}) => {
|
|
5
|
-
const input = {
|
|
6
|
-
condition: { value: args.condition ?? '1' }
|
|
7
|
-
};
|
|
8
|
-
return input;
|
|
9
|
-
};
|
|
10
|
-
const createExecuteNode = (options) => {
|
|
11
|
-
const executeNode = {
|
|
12
|
-
id: options.id,
|
|
13
|
-
label: language.get(scriptable),
|
|
14
|
-
position: { x: options?.position?.x ?? 20, y: options?.position?.y ?? 20 },
|
|
15
|
-
interaction: 'Condition',
|
|
16
|
-
url: '',
|
|
17
|
-
input: createExecuteInput(options.input)
|
|
18
|
-
};
|
|
19
|
-
return executeNode;
|
|
20
|
-
};
|
|
21
|
-
export { scriptable, createExecuteInput, createExecuteNode, };
|
|
22
|
-
//# sourceMappingURL=edit.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"edit.js","sourceRoot":"","sources":["../../../../src/preset/execute/ElForm/edit.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,EAAmB,MAAM,aAAa,CAAA;AACpD,OAAO,EAAE,QAAQ,EAAE,MAAM,iBAAiB,CAAA;AAE1C,MAAM,UAAU,GAAG,KAAK,CAAC,gBAAgB,CAAC,8BAA8B,CAAC,CAAA;AAEzE,MAAM,kBAAkB,GAAG,CAAC,OAAY,EAAE,EAAE,EAAE;IAC1C,MAAM,KAAK,GAAG;QACV,SAAS,EAAE,EAAE,KAAK,EAAE,IAAI,CAAC,SAAS,IAAI,GAAG,EAAE;KAC9C,CAAA;IAED,OAAO,KAAK,CAAA;AAChB,CAAC,CAAA;AAED,MAAM,iBAAiB,GAAG,CAAC,OAAoD,EAAE,EAAE;IAC/E,MAAM,WAAW,GAAoB;QACjC,EAAE,EAAE,OAAO,CAAC,EAAE;QACd,KAAK,EAAE,QAAQ,CAAC,GAAG,CAAC,UAAiB,CAAC;QACtC,QAAQ,EAAE,EAAE,CAAC,EAAE,OAAO,EAAE,QAAQ,EAAE,CAAC,IAAI,EAAE,EAAE,CAAC,EAAE,OAAO,EAAE,QAAQ,EAAE,CAAC,IAAI,EAAE,EAAE;QAC1E,WAAW,EAAE,WAAW;QACxB,GAAG,EAAE,EAAE;QACP,KAAK,EAAE,kBAAkB,CAAC,OAAO,CAAC,KAAK,CAAC;KAC3C,CAAA;IACD,OAAO,WAAW,CAAA;AACtB,CAAC,CAAA;AAED,OAAO,EACH,UAAU,EACV,kBAAkB,EAClB,iBAAiB,GACpB,CAAA"}
|
|
@@ -1,16 +0,0 @@
|
|
|
1
|
-
import { InteractionNode } from "@vyr/engine";
|
|
2
|
-
declare const scriptable: string;
|
|
3
|
-
declare const createExecuteInput: (args?: any) => {
|
|
4
|
-
form: {
|
|
5
|
-
value: any;
|
|
6
|
-
};
|
|
7
|
-
validate: {
|
|
8
|
-
value: any;
|
|
9
|
-
};
|
|
10
|
-
};
|
|
11
|
-
declare const createExecuteNode: (options: {
|
|
12
|
-
id: string;
|
|
13
|
-
position?: any;
|
|
14
|
-
input?: any;
|
|
15
|
-
}) => InteractionNode;
|
|
16
|
-
export { scriptable, createExecuteInput, createExecuteNode, };
|
|
@@ -1,41 +0,0 @@
|
|
|
1
|
-
import { Asset, Descriptor, Scriptable } from "@vyr/engine";
|
|
2
|
-
import { language } from '../../../locale';
|
|
3
|
-
import { ElFormDescriptor } from "../../../descriptor";
|
|
4
|
-
const scriptable = Asset.createVirtualUrl('preset/ElForm/getData.ts');
|
|
5
|
-
class InteractionScriptable extends Scriptable {
|
|
6
|
-
async execute(graphics, args) {
|
|
7
|
-
const { input } = args;
|
|
8
|
-
const form = input?.user?.form.value ?? input.default.form.value;
|
|
9
|
-
const validate = input?.user?.validate.value ?? input.default.validate.value;
|
|
10
|
-
const formDescriptor = Descriptor.get(form);
|
|
11
|
-
if (formDescriptor instanceof ElFormDescriptor) {
|
|
12
|
-
if (validate === '1')
|
|
13
|
-
await formDescriptor.validate(graphics);
|
|
14
|
-
return await formDescriptor.getData(graphics);
|
|
15
|
-
}
|
|
16
|
-
else {
|
|
17
|
-
return {};
|
|
18
|
-
}
|
|
19
|
-
}
|
|
20
|
-
}
|
|
21
|
-
Asset.provider(scriptable, async () => ({ default: InteractionScriptable }));
|
|
22
|
-
const createExecuteInput = (args = {}) => {
|
|
23
|
-
const input = {
|
|
24
|
-
form: { value: args.form ?? '' },
|
|
25
|
-
validate: { value: args.validate ?? '0' },
|
|
26
|
-
};
|
|
27
|
-
return input;
|
|
28
|
-
};
|
|
29
|
-
const createExecuteNode = (options) => {
|
|
30
|
-
const executeNode = {
|
|
31
|
-
id: options.id,
|
|
32
|
-
label: language.get(scriptable),
|
|
33
|
-
position: { x: options?.position?.x ?? 20, y: options?.position?.y ?? 20 },
|
|
34
|
-
interaction: 'Execute',
|
|
35
|
-
url: scriptable,
|
|
36
|
-
input: createExecuteInput(options.input)
|
|
37
|
-
};
|
|
38
|
-
return executeNode;
|
|
39
|
-
};
|
|
40
|
-
export { scriptable, createExecuteInput, createExecuteNode, };
|
|
41
|
-
//# sourceMappingURL=getData.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"getData.js","sourceRoot":"","sources":["../../../../src/preset/execute/ElForm/getData.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,EAAE,UAAU,EAA6B,UAAU,EAAkB,MAAM,aAAa,CAAA;AACtG,OAAO,EAAE,QAAQ,EAAE,MAAM,iBAAiB,CAAA;AAC1C,OAAO,EAAE,gBAAgB,EAAE,MAAM,qBAAqB,CAAA;AAEtD,MAAM,UAAU,GAAG,KAAK,CAAC,gBAAgB,CAAC,0BAA0B,CAAC,CAAA;AACrE,MAAM,qBAAsB,SAAQ,UAAU;I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C,GAAG,CAAC,UAAiB,CAAC;QACtC,QAAQ,EAAE,EAAE,CAAC,EAAE,OAAO,EAAE,QAAQ,EAAE,CAAC,IAAI,EAAE,EAAE,CAAC,EAAE,OAAO,EAAE,QAAQ,EAAE,CAAC,IAAI,EAAE,EAAE;QAC1E,WAAW,EAAE,SAAS;QACtB,GAAG,EAAE,UAAU;QACf,KAAK,EAAE,kBAAkB,CAAC,OAAO,CAAC,KAAK,CAAC;KAC3C,CAAA;IACD,OAAO,WAAW,CAAA;AACtB,CAAC,CAAA;AAED,OAAO,EACH,UAAU,EACV,kBAAkB,EAClB,iBAAiB,GACpB,CAAA"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../src/preset/execute/ElForm/index.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,OAAO,MAAM,WAAW,CAAA;AACpC,OAAO,KAAK,KAAK,MAAM,SAAS,CAAA;AAChC,OAAO,KAAK,MAAM,MAAM,UAAU,CAAA;AAClC,OAAO,KAAK,MAAM,MAAM,UAAU,CAAA;AAClC,OAAO,KAAK,IAAI,MAAM,QAAQ,CAAA"}
|
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
import { InteractionNode } from "@vyr/engine";
|
|
2
|
-
declare const scriptable: string;
|
|
3
|
-
declare const createExecuteInput: (args?: any) => {
|
|
4
|
-
form: {
|
|
5
|
-
value: any;
|
|
6
|
-
};
|
|
7
|
-
};
|
|
8
|
-
declare const createExecuteNode: (options: {
|
|
9
|
-
id: string;
|
|
10
|
-
position?: any;
|
|
11
|
-
input?: any;
|
|
12
|
-
}) => InteractionNode;
|
|
13
|
-
export { scriptable, createExecuteInput, createExecuteNode, };
|
|
@@ -1,42 +0,0 @@
|
|
|
1
|
-
import { Asset, Descriptor, Scriptable, AsyncTask } from "@vyr/engine";
|
|
2
|
-
import { language } from '../../../locale';
|
|
3
|
-
import { ElFormDescriptor, ElFormItemDescriptor } from "../../../descriptor";
|
|
4
|
-
const scriptable = Asset.createVirtualUrl('preset/ElForm/reset.ts');
|
|
5
|
-
class InteractionScriptable extends Scriptable {
|
|
6
|
-
async execute(graphics, args) {
|
|
7
|
-
const { input } = args;
|
|
8
|
-
const form = input?.user?.form.value ?? input.default.form.value;
|
|
9
|
-
const formDescriptor = Descriptor.get(form);
|
|
10
|
-
if (formDescriptor instanceof ElFormDescriptor) {
|
|
11
|
-
for (const item of formDescriptor.children) {
|
|
12
|
-
if (item instanceof ElFormItemDescriptor) {
|
|
13
|
-
item.modelValue = '';
|
|
14
|
-
item.setNeedsUpdate();
|
|
15
|
-
}
|
|
16
|
-
}
|
|
17
|
-
}
|
|
18
|
-
const task = new AsyncTask();
|
|
19
|
-
graphics.engine.listen('afterRender', () => { task.run(); }, { once: true });
|
|
20
|
-
await task.done();
|
|
21
|
-
}
|
|
22
|
-
}
|
|
23
|
-
Asset.provider(scriptable, async () => ({ default: InteractionScriptable }));
|
|
24
|
-
const createExecuteInput = (args = {}) => {
|
|
25
|
-
const input = {
|
|
26
|
-
form: { value: args.form ?? '' },
|
|
27
|
-
};
|
|
28
|
-
return input;
|
|
29
|
-
};
|
|
30
|
-
const createExecuteNode = (options) => {
|
|
31
|
-
const executeNode = {
|
|
32
|
-
id: options.id,
|
|
33
|
-
label: language.get(scriptable),
|
|
34
|
-
position: { x: options?.position?.x ?? 20, y: options?.position?.y ?? 20 },
|
|
35
|
-
interaction: 'Execute',
|
|
36
|
-
url: scriptable,
|
|
37
|
-
input: createExecuteInput(options.input)
|
|
38
|
-
};
|
|
39
|
-
return executeNode;
|
|
40
|
-
};
|
|
41
|
-
export { scriptable, createExecuteInput, createExecuteNode, };
|
|
42
|
-
//# sourceMappingURL=reset.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"reset.js","sourceRoot":"","sources":["../../../../src/preset/execute/ElForm/reset.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,EAAE,UAAU,EAA6B,UAAU,EAA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kB,GAAG,CAAC,OAAY,EAAE,EAAE,EAAE;IAC1C,MAAM,KAAK,GAAG;QACV,IAAI,EAAE,EAAE,KAAK,EAAE,IAAI,CAAC,IAAI,IAAI,EAAE,EAAE;KACnC,CAAA;IAED,OAAO,KAAK,CAAA;AAChB,CAAC,CAAA;AAED,MAAM,iBAAiB,GAAG,CAAC,OAAoD,EAAE,EAAE;IAC/E,MAAM,WAAW,GAAoB;QACjC,EAAE,EAAE,OAAO,CAAC,EAAE;QACd,KAAK,EAAE,QAAQ,CAAC,GAAG,CAAC,UAAiB,CAAC;QACtC,QAAQ,EAAE,EAAE,CAAC,EAAE,OAAO,EAAE,QAAQ,EAAE,CAAC,IAAI,EAAE,EAAE,CAAC,EAAE,OAAO,EAAE,QAAQ,EAAE,CAAC,IAAI,EAAE,EAAE;QAC1E,WAAW,EAAE,SAAS;QACtB,GAAG,EAAE,UAAU;QACf,KAAK,EAAE,kBAAkB,CAAC,OAAO,CAAC,KAAK,CAAC;KAC3C,CAAA;IACD,OAAO,WAAW,CAAA;AACtB,CAAC,CAAA;AAED,OAAO,EACH,UAAU,EACV,kBAAkB,EAClB,iBAAiB,GACpB,CAAA"}
|
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
import { InteractionNode } from "@vyr/engine";
|
|
2
|
-
declare const scriptable: string;
|
|
3
|
-
declare const createExecuteInput: (args?: any) => {
|
|
4
|
-
pagination: {
|
|
5
|
-
value: any;
|
|
6
|
-
};
|
|
7
|
-
};
|
|
8
|
-
declare const createExecuteNode: (options: {
|
|
9
|
-
id: string;
|
|
10
|
-
position?: any;
|
|
11
|
-
input?: any;
|
|
12
|
-
}) => InteractionNode;
|
|
13
|
-
export { scriptable, createExecuteInput, createExecuteNode, };
|
|
@@ -1,37 +0,0 @@
|
|
|
1
|
-
import { Asset, Descriptor, Scriptable } from "@vyr/engine";
|
|
2
|
-
import { language } from '../../../locale';
|
|
3
|
-
import { ElPaginationDescriptor } from "../../../descriptor";
|
|
4
|
-
const scriptable = Asset.createVirtualUrl('preset/ElPagination/getData.ts');
|
|
5
|
-
class InteractionScriptable extends Scriptable {
|
|
6
|
-
execute(graphics, args) {
|
|
7
|
-
const { input } = args;
|
|
8
|
-
const pagination = input?.user?.pagination.value ?? input.default.pagination.value;
|
|
9
|
-
const paginationDescriptor = Descriptor.get(pagination);
|
|
10
|
-
if (paginationDescriptor instanceof ElPaginationDescriptor) {
|
|
11
|
-
return paginationDescriptor.getData(graphics);
|
|
12
|
-
}
|
|
13
|
-
else {
|
|
14
|
-
return {};
|
|
15
|
-
}
|
|
16
|
-
}
|
|
17
|
-
}
|
|
18
|
-
Asset.provider(scriptable, async () => ({ default: InteractionScriptable }));
|
|
19
|
-
const createExecuteInput = (args = {}) => {
|
|
20
|
-
const input = {
|
|
21
|
-
pagination: { value: args.pagination ?? '' }
|
|
22
|
-
};
|
|
23
|
-
return input;
|
|
24
|
-
};
|
|
25
|
-
const createExecuteNode = (options) => {
|
|
26
|
-
const executeNode = {
|
|
27
|
-
id: options.id,
|
|
28
|
-
label: language.get(scriptable),
|
|
29
|
-
position: { x: options?.position?.x ?? 20, y: options?.position?.y ?? 20 },
|
|
30
|
-
interaction: 'Execute',
|
|
31
|
-
url: scriptable,
|
|
32
|
-
input: createExecuteInput(options.input)
|
|
33
|
-
};
|
|
34
|
-
return executeNode;
|
|
35
|
-
};
|
|
36
|
-
export { scriptable, createExecuteInput, createExecuteNode, };
|
|
37
|
-
//# sourceMappingURL=getData.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"getData.js","sourceRoot":"","sources":["../../../../src/preset/execute/ElPagination/getData.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,EAAE,UAAU,EAA6B,UAAU,EAAkB,MAAM,aAAa,CAAA;AACtG,OAAO,EAAE,QAAQ,EAAE,MAAM,iBAAiB,CAAA;AAC1C,OAAO,EAAE,sBAAsB,EAAE,MAAM,qBAAqB,CAAA;AAE5D,MAAM,UAAU,GAAG,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,UAAU;QACf,KAAK,EAAE,kBAAkB,CAAC,OAAO,CAAC,KAAK,CAAC;KAC3C,CAAA;IACD,OAAO,WAAW,CAAA;AACtB,CAAC,CAAA;AAED,OAAO,EACH,UAAU,EACV,kBAAkB,EAClB,iBAAiB,GACpB,CAAA"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../src/preset/execute/ElPagination/index.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,OAAO,MAAM,WAAW,CAAA;AACpC,OAAO,KAAK,KAAK,MAAM,SAAS,CAAA"}
|
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
import { InteractionNode } from "@vyr/engine";
|
|
2
|
-
declare const scriptable: string;
|
|
3
|
-
declare const createExecuteInput: (args?: any) => {
|
|
4
|
-
pagination: {
|
|
5
|
-
value: any;
|
|
6
|
-
};
|
|
7
|
-
};
|
|
8
|
-
declare const createExecuteNode: (options: {
|
|
9
|
-
id: string;
|
|
10
|
-
position?: any;
|
|
11
|
-
input?: any;
|
|
12
|
-
}) => InteractionNode;
|
|
13
|
-
export { scriptable, createExecuteInput, createExecuteNode, };
|
|
@@ -1,34 +0,0 @@
|
|
|
1
|
-
import { Asset, Descriptor, Scriptable } from "@vyr/engine";
|
|
2
|
-
import { language } from '../../../locale';
|
|
3
|
-
import { ElPaginationDescriptor } from "../../../descriptor";
|
|
4
|
-
const scriptable = Asset.createVirtualUrl('preset/ElPagination/reset.ts');
|
|
5
|
-
class InteractionScriptable extends Scriptable {
|
|
6
|
-
async execute(graphics, args) {
|
|
7
|
-
const { input } = args;
|
|
8
|
-
const pagination = input?.user?.pagination.value ?? input.default.pagination.value;
|
|
9
|
-
const paginationDescriptor = Descriptor.get(pagination);
|
|
10
|
-
if (paginationDescriptor instanceof ElPaginationDescriptor) {
|
|
11
|
-
paginationDescriptor.reset(graphics);
|
|
12
|
-
}
|
|
13
|
-
}
|
|
14
|
-
}
|
|
15
|
-
Asset.provider(scriptable, async () => ({ default: InteractionScriptable }));
|
|
16
|
-
const createExecuteInput = (args = {}) => {
|
|
17
|
-
const input = {
|
|
18
|
-
pagination: { value: args.pagination ?? '' },
|
|
19
|
-
};
|
|
20
|
-
return input;
|
|
21
|
-
};
|
|
22
|
-
const createExecuteNode = (options) => {
|
|
23
|
-
const executeNode = {
|
|
24
|
-
id: options.id,
|
|
25
|
-
label: language.get(scriptable),
|
|
26
|
-
position: { x: options?.position?.x ?? 20, y: options?.position?.y ?? 20 },
|
|
27
|
-
interaction: 'Execute',
|
|
28
|
-
url: scriptable,
|
|
29
|
-
input: createExecuteInput(options.input)
|
|
30
|
-
};
|
|
31
|
-
return executeNode;
|
|
32
|
-
};
|
|
33
|
-
export { scriptable, createExecuteInput, createExecuteNode, };
|
|
34
|
-
//# sourceMappingURL=reset.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"reset.js","sourceRoot":"","sources":["../../../../src/preset/execute/ElPagination/reset.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,EAAE,UAAU,EAA6B,UAAU,EAAkB,MAAM,aAAa,CAAA;AACtG,OAAO,EAAE,QAAQ,EAAE,MAAM,iBAAiB,CAAA;AAC1C,OAAO,EAAE,sBAAsB,EAAE,MAAM,qBAAqB,CAAA;AAE5D,MAAM,UAAU,GAAG,KAAK,CAAC,gBAAgB,CAAC,8BAA8B,CAAC,CAAA;AACzE,MAAM,qBAAsB,SAAQ,UAAU;IAC1C,KAAK,CAAC,OAAO,CAAC,QAAkB,EAAE,IAAoB;QAClD,MAAM,EAAE,KAAK,EAAE,GAAG,IAAI,CAAA;QACtB,MAAM,UAAU,GAAG,KAAK,EAAE,IAAI,EAAE,UAAU,CAAC,KAAK,IAAI,KAAK,CAAC,OAAO,CAAC,UAAU,CAAC,KAAK,CAAA;QAElF,MAAM,oBAAoB,GAAG,UAAU,CAAC,GAAG,CAAyB,UAAU,CAAC,CAAA;QAC/E,IAAI,oBAAoB,YAAY,sBAAsB,EAAE,CAAC;YACzD,oBAAoB,CAAC,KAAK,CAAC,QAAQ,CAAC,CAAA;QACxC,CAAC;IACL,CAAC;CACJ;AACD,KAAK,CAAC,QAAQ,CAAC,UAAU,EAAE,KAAK,IAAI,EAAE,CAAC,CAAC,EAAE,OAAO,EAAE,qBAAqB,EAAE,CAAC,CAAC,CAAA;AAE5E,MAAM,kBAAkB,GAAG,CAAC,OAAY,EAAE,EAAE,EAAE;IAC1C,MAAM,KAAK,GAAG;QACV,UAAU,EAAE,EAAE,KAAK,EAAE,IAAI,CAAC,UAAU,IAAI,EAAE,EAAE;KAC/C,CAAA;IAED,OAAO,KAAK,CAAA;AAChB,CAAC,CAAA;AAED,MAAM,iBAAiB,GAAG,CAAC,OAAoD,EAAE,EAAE;IAC/E,MAAM,WAAW,GAAoB;QACjC,EAAE,EAAE,OAAO,CAAC,EAAE;QACd,KAAK,EAAE,QAAQ,CAAC,GAAG,CAAC,UAAiB,CAAC;QACtC,QAAQ,EAAE,EAAE,CAAC,EAAE,OAAO,EAAE,QAAQ,EAAE,CAAC,IAAI,EAAE,EAAE,CAAC,EAAE,OAAO,EAAE,QAAQ,EAAE,CAAC,IAAI,EAAE,EAAE;QAC1E,WAAW,EAAE,SAAS;QACtB,GAAG,EAAE,UAAU;QACf,KAAK,EAAE,kBAAkB,CAAC,OAAO,CAAC,KAAK,CAAC;KAC3C,CAAA;IACD,OAAO,WAAW,CAAA;AACtB,CAAC,CAAA;AAED,OAAO,EACH,UAAU,EACV,kBAAkB,EAClB,iBAAiB,GACpB,CAAA"}
|
|
@@ -1,9 +0,0 @@
|
|
|
1
|
-
import { InteractionNode } from "@vyr/engine";
|
|
2
|
-
declare const scriptable: string;
|
|
3
|
-
declare const createExecuteInput: (args?: any) => {};
|
|
4
|
-
declare const createExecuteNode: (options: {
|
|
5
|
-
id: string;
|
|
6
|
-
position?: any;
|
|
7
|
-
input?: any;
|
|
8
|
-
}) => InteractionNode;
|
|
9
|
-
export { scriptable, createExecuteInput, createExecuteNode, };
|
|
@@ -1,26 +0,0 @@
|
|
|
1
|
-
import { Asset, Scriptable } from "@vyr/engine";
|
|
2
|
-
import { language } from '../../../locale';
|
|
3
|
-
const scriptable = Asset.createVirtualUrl('preset/ElTable/create.ts');
|
|
4
|
-
class InteractionScriptable extends Scriptable {
|
|
5
|
-
async execute(graphics, args) {
|
|
6
|
-
return {};
|
|
7
|
-
}
|
|
8
|
-
}
|
|
9
|
-
Asset.provider(scriptable, async () => ({ default: InteractionScriptable }));
|
|
10
|
-
const createExecuteInput = (args = {}) => {
|
|
11
|
-
const input = {};
|
|
12
|
-
return input;
|
|
13
|
-
};
|
|
14
|
-
const createExecuteNode = (options) => {
|
|
15
|
-
const executeNode = {
|
|
16
|
-
id: options.id,
|
|
17
|
-
label: language.get(scriptable),
|
|
18
|
-
position: { x: options?.position?.x ?? 20, y: options?.position?.y ?? 20 },
|
|
19
|
-
interaction: 'Execute',
|
|
20
|
-
url: scriptable,
|
|
21
|
-
input: createExecuteInput(options.input)
|
|
22
|
-
};
|
|
23
|
-
return executeNode;
|
|
24
|
-
};
|
|
25
|
-
export { scriptable, createExecuteInput, createExecuteNode, };
|
|
26
|
-
//# sourceMappingURL=create.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"create.js","sourceRoot":"","sources":["../../../../src/preset/execute/ElTable/create.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,EAA6B,UAAU,EAAkB,MAAM,aAAa,CAAA;AAC1F,OAAO,EAAE,QAAQ,EAAE,MAAM,iBAAiB,CAAA;AAE1C,MAAM,UAAU,GAAG,KAAK,CAAC,gBAAgB,CAAC,0BAA0B,CAAC,CAAA;AACrE,MAAM,qBAAsB,SAAQ,UAAU;IAC1C,KAAK,CAAC,OAAO,CAAC,QAAkB,EAAE,IAAoB;QAElD,OAAO,EAAE,CAAA;IACb,CAAC;CACJ;AACD,KAAK,CAAC,QAAQ,CAAC,UAAU,EAAE,KAAK,IAAI,EAAE,CAAC,CAAC,EAAE,OAAO,EAAE,qBAAqB,EAAE,CAAC,CAAC,CAAA;AAE5E,MAAM,kBAAkB,GAAG,CAAC,OAAY,EAAE,EAAE,EAAE;IAC1C,MAAM,KAAK,GAAG,EACb,CAAA;IAED,OAAO,KAAK,CAAA;AAChB,CAAC,CAAA;AAED,MAAM,iBAAiB,GAAG,CAAC,OAAoD,EAAE,EAAE;IAC/E,MAAM,WAAW,GAAoB;QACjC,EAAE,EAAE,OAAO,CAAC,EAAE;QACd,KAAK,EAAE,QAAQ,CAAC,GAAG,CAAC,UAAiB,CAAC;QACtC,QAAQ,EAAE,EAAE,CAAC,EAAE,OAAO,EAAE,QAAQ,EAAE,CAAC,IAAI,EAAE,EAAE,CAAC,EAAE,OAAO,EAAE,QAAQ,EAAE,CAAC,IAAI,EAAE,EAAE;QAC1E,WAAW,EAAE,SAAS;QACtB,GAAG,EAAE,UAAU;QACf,KAAK,EAAE,kBAAkB,CAAC,OAAO,CAAC,KAAK,CAAC;KAC3C,CAAA;IACD,OAAO,WAAW,CAAA;AACtB,CAAC,CAAA;AAED,OAAO,EACH,UAAU,EACV,kBAAkB,EAClB,iBAAiB,GACpB,CAAA"}
|
|
@@ -1,9 +0,0 @@
|
|
|
1
|
-
import { InteractionNode } from "@vyr/engine";
|
|
2
|
-
declare const scriptable: string;
|
|
3
|
-
declare const createExecuteInput: (args?: any) => {};
|
|
4
|
-
declare const createExecuteNode: (options: {
|
|
5
|
-
id: string;
|
|
6
|
-
position?: any;
|
|
7
|
-
input?: any;
|
|
8
|
-
}) => InteractionNode;
|
|
9
|
-
export { scriptable, createExecuteInput, createExecuteNode, };
|
|
@@ -1,41 +0,0 @@
|
|
|
1
|
-
import { ElMessageBox } from "element-plus";
|
|
2
|
-
import { Asset, Scriptable } from "@vyr/engine";
|
|
3
|
-
import { ElTableColumnDescriptor } from "../../../descriptor";
|
|
4
|
-
import { language } from '../../../locale';
|
|
5
|
-
const scriptable = Asset.createVirtualUrl('preset/ElTable/delete.ts');
|
|
6
|
-
class InteractionScriptable extends Scriptable {
|
|
7
|
-
async execute(graphics, args) {
|
|
8
|
-
const { VYR_STORE, trigger } = args;
|
|
9
|
-
return new Promise((resolve, reject) => {
|
|
10
|
-
const { parent } = trigger.traceAncestor(false);
|
|
11
|
-
if (parent instanceof ElTableColumnDescriptor) {
|
|
12
|
-
ElMessageBox.confirm(language.get('preset.ElTable.delete.message'), { type: 'warning', title: language.get('preset.ElMessageBox.title'), }).then(() => {
|
|
13
|
-
resolve(VYR_STORE.slot.row);
|
|
14
|
-
}).catch(err => {
|
|
15
|
-
reject(err);
|
|
16
|
-
});
|
|
17
|
-
}
|
|
18
|
-
else {
|
|
19
|
-
reject();
|
|
20
|
-
}
|
|
21
|
-
});
|
|
22
|
-
}
|
|
23
|
-
}
|
|
24
|
-
Asset.provider(scriptable, async () => ({ default: InteractionScriptable }));
|
|
25
|
-
const createExecuteInput = (args = {}) => {
|
|
26
|
-
const input = {};
|
|
27
|
-
return input;
|
|
28
|
-
};
|
|
29
|
-
const createExecuteNode = (options) => {
|
|
30
|
-
const executeNode = {
|
|
31
|
-
id: options.id,
|
|
32
|
-
label: language.get(scriptable),
|
|
33
|
-
position: { x: 20, y: 20 },
|
|
34
|
-
interaction: 'Execute',
|
|
35
|
-
url: scriptable,
|
|
36
|
-
input: createExecuteInput(options.input)
|
|
37
|
-
};
|
|
38
|
-
return executeNode;
|
|
39
|
-
};
|
|
40
|
-
export { scriptable, createExecuteInput, createExecuteNode, };
|
|
41
|
-
//# sourceMappingURL=delete.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"delete.js","sourceRoot":"","sources":["../../../../src/preset/execute/ElTable/delete.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,YAAY,EAAE,MAAM,cAAc,CAAA;AAC3C,OAAO,EAAE,KAAK,EAA6B,UAAU,EAAE,MAAM,aAAa,CAAA;AAE1E,OAAO,EAAE,uBAAuB,EAAE,MAAM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AiB,GAAG,CAAC,OAAoD,EAAE,EAAE;IAC/E,MAAM,WAAW,GAAoB;QACjC,EAAE,EAAE,OAAO,CAAC,EAAE;QACd,KAAK,EAAE,QAAQ,CAAC,GAAG,CAAC,UAAiB,CAAC;QACtC,QAAQ,EAAE,EAAE,CAAC,EAAE,EAAE,EAAE,CAAC,EAAE,EAAE,EAAE;QAC1B,WAAW,EAAE,SAAS;QACtB,GAAG,EAAE,UAAU;QACf,KAAK,EAAE,kBAAkB,CAAC,OAAO,CAAC,KAAK,CAAC;KAC3C,CAAA;IACD,OAAO,WAAW,CAAA;AACtB,CAAC,CAAA;AAED,OAAO,EACH,UAAU,EACV,kBAAkB,EAClB,iBAAiB,GACpB,CAAA"}
|
|
@@ -1,9 +0,0 @@
|
|
|
1
|
-
import { InteractionNode } from "@vyr/engine";
|
|
2
|
-
declare const scriptable: string;
|
|
3
|
-
declare const createExecuteInput: (args?: any) => {};
|
|
4
|
-
declare const createExecuteNode: (options: {
|
|
5
|
-
id: string;
|
|
6
|
-
position?: any;
|
|
7
|
-
input?: any;
|
|
8
|
-
}) => InteractionNode;
|
|
9
|
-
export { scriptable, createExecuteInput, createExecuteNode, };
|
|
@@ -1,27 +0,0 @@
|
|
|
1
|
-
import { Asset, Scriptable } from "@vyr/engine";
|
|
2
|
-
import { language } from '../../../locale';
|
|
3
|
-
const scriptable = Asset.createVirtualUrl('preset/ElTable/edit.ts');
|
|
4
|
-
class InteractionScriptable extends Scriptable {
|
|
5
|
-
async execute(graphics, args) {
|
|
6
|
-
const { VYR_STORE } = args;
|
|
7
|
-
return VYR_STORE.slot.row;
|
|
8
|
-
}
|
|
9
|
-
}
|
|
10
|
-
Asset.provider(scriptable, async () => ({ default: InteractionScriptable }));
|
|
11
|
-
const createExecuteInput = (args = {}) => {
|
|
12
|
-
const input = {};
|
|
13
|
-
return input;
|
|
14
|
-
};
|
|
15
|
-
const createExecuteNode = (options) => {
|
|
16
|
-
const executeNode = {
|
|
17
|
-
id: options.id,
|
|
18
|
-
label: language.get(scriptable),
|
|
19
|
-
position: { x: options?.position?.x ?? 20, y: options?.position?.y ?? 20 },
|
|
20
|
-
interaction: 'Execute',
|
|
21
|
-
url: scriptable,
|
|
22
|
-
input: createExecuteInput(options.input)
|
|
23
|
-
};
|
|
24
|
-
return executeNode;
|
|
25
|
-
};
|
|
26
|
-
export { scriptable, createExecuteInput, createExecuteNode, };
|
|
27
|
-
//# sourceMappingURL=edit.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"edit.js","sourceRoot":"","sources":["../../../../src/preset/execute/ElTable/edit.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,EAA6B,UAAU,EAAE,MAAM,aAAa,CAAA;AAE1E,OAAO,EAAE,QAAQ,EAAE,MAAM,iBAAiB,CAAA;AAE1C,MAAM,UAAU,GAAG,KAAK,CAAC,gBAAgB,CAAC,wBAAwB,CAAC,CAAA;AACnE,MAAM,qBAAsB,SAAQ,UAAU;IAC1C,KAAK,CAAC,OAAO,CAAC,QAAkB,EAAE,IAAuB;QACrD,MAAM,EAAE,SAAS,EAAE,GAAG,IAAI,CAAA;QAC1B,OAAO,SAAS,CAAC,IAAI,CAAC,GAAG,CAAA;IAC7B,CAAC;CACJ;AACD,KAAK,CAAC,QAAQ,CAAC,UAAU,EAAE,KAAK,IAAI,EAAE,CAAC,CAAC,EAAE,OAAO,EAAE,qBAAqB,EAAE,CAAC,CAAC,CAAA;AAE5E,MAAM,kBAAkB,GAAG,CAAC,OAAY,EAAE,EAAE,EAAE;IAC1C,MAAM,KAAK,GAAG,EACb,CAAA;IAED,OAAO,KAAK,CAAA;AAChB,CAAC,CAAA;AAED,MAAM,iBAAiB,GAAG,CAAC,OAAoD,EAAE,EAAE;IAC/E,MAAM,WAAW,GAAoB;QACjC,EAAE,EAAE,OAAO,CAAC,EAAE;QACd,KAAK,EAAE,QAAQ,CAAC,GAAG,CAAC,UAAiB,CAAC;QACtC,QAAQ,EAAE,EAAE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