@webtypen/webframez-core 0.2.2 → 0.2.4
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.
|
@@ -14,6 +14,7 @@ const { Command } = require("commander");
|
|
|
14
14
|
const Config_1 = require("./Config");
|
|
15
15
|
const BuildFinishCommand_1 = require("./Commands/BuildFinishCommand");
|
|
16
16
|
const QueueJobsRegisty_1 = require("./Queue/QueueJobsRegisty");
|
|
17
|
+
const QueueRunCommand_1 = require("./Commands/QueueRunCommand");
|
|
17
18
|
class ConsoleApplication {
|
|
18
19
|
/**
|
|
19
20
|
* Init the routes and start the http-server
|
|
@@ -26,7 +27,7 @@ class ConsoleApplication {
|
|
|
26
27
|
}
|
|
27
28
|
const program = new Command();
|
|
28
29
|
program.name("webframez console").description("CLI to some JavaScript string utilities").version("0.0.1");
|
|
29
|
-
const systemCommands = [BuildFinishCommand_1.BuildFinishCommand];
|
|
30
|
+
const systemCommands = [QueueRunCommand_1.QueueRunCommand, BuildFinishCommand_1.BuildFinishCommand];
|
|
30
31
|
for (let command of systemCommands) {
|
|
31
32
|
if (!command.signature) {
|
|
32
33
|
continue;
|
|
@@ -340,8 +340,9 @@ class DataBuilder {
|
|
|
340
340
|
}
|
|
341
341
|
}
|
|
342
342
|
let redirect = undefined;
|
|
343
|
-
|
|
344
|
-
|
|
343
|
+
const forms = typeof type.forms === "function" ? yield type.forms(req) : type.forms;
|
|
344
|
+
if (forms && forms.main && forms.main.onSaveRedirect && typeof forms.main.onSaveRedirect === "function") {
|
|
345
|
+
redirect = yield forms.main.onSaveRedirect(element, req);
|
|
345
346
|
}
|
|
346
347
|
return {
|
|
347
348
|
status: "success",
|
package/dist/index.d.ts
CHANGED
|
@@ -22,3 +22,6 @@ export * from "./Facades/StorageDrivers/BaseStorageDriver";
|
|
|
22
22
|
export * from "./Facades/Storage";
|
|
23
23
|
export * from "./DataBuilder/DataBuilder";
|
|
24
24
|
export * from "./DataBuilder/DataBuilderController";
|
|
25
|
+
export * from "./Queue/BaseQueueJob";
|
|
26
|
+
export * from "./Queue/QueueJob";
|
|
27
|
+
export * from "./Queue/QueueJobsRegisty";
|
package/dist/index.js
CHANGED
|
@@ -38,3 +38,6 @@ __exportStar(require("./Facades/StorageDrivers/BaseStorageDriver"), exports);
|
|
|
38
38
|
__exportStar(require("./Facades/Storage"), exports);
|
|
39
39
|
__exportStar(require("./DataBuilder/DataBuilder"), exports);
|
|
40
40
|
__exportStar(require("./DataBuilder/DataBuilderController"), exports);
|
|
41
|
+
__exportStar(require("./Queue/BaseQueueJob"), exports);
|
|
42
|
+
__exportStar(require("./Queue/QueueJob"), exports);
|
|
43
|
+
__exportStar(require("./Queue/QueueJobsRegisty"), exports);
|
package/package.json
CHANGED
|
@@ -2,6 +2,7 @@ const { Command } = require("commander");
|
|
|
2
2
|
import { Config } from "./Config";
|
|
3
3
|
import { BuildFinishCommand } from "./Commands/BuildFinishCommand";
|
|
4
4
|
import { QueueJobsRegisty } from "./Queue/QueueJobsRegisty";
|
|
5
|
+
import { QueueRunCommand } from "./Commands/QueueRunCommand";
|
|
5
6
|
|
|
6
7
|
export class ConsoleApplication {
|
|
7
8
|
/**
|
|
@@ -17,7 +18,7 @@ export class ConsoleApplication {
|
|
|
17
18
|
const program = new Command();
|
|
18
19
|
program.name("webframez console").description("CLI to some JavaScript string utilities").version("0.0.1");
|
|
19
20
|
|
|
20
|
-
const systemCommands = [BuildFinishCommand];
|
|
21
|
+
const systemCommands = [QueueRunCommand, BuildFinishCommand];
|
|
21
22
|
for (let command of systemCommands) {
|
|
22
23
|
if (!command.signature) {
|
|
23
24
|
continue;
|
|
@@ -419,8 +419,9 @@ export class DataBuilder {
|
|
|
419
419
|
}
|
|
420
420
|
|
|
421
421
|
let redirect: any = undefined;
|
|
422
|
-
|
|
423
|
-
|
|
422
|
+
const forms = typeof type.forms === "function" ? await type.forms(req) : type.forms;
|
|
423
|
+
if (forms && forms.main && forms.main.onSaveRedirect && typeof forms.main.onSaveRedirect === "function") {
|
|
424
|
+
redirect = await forms.main.onSaveRedirect(element, req);
|
|
424
425
|
}
|
|
425
426
|
|
|
426
427
|
return {
|
package/src/index.ts
CHANGED
|
@@ -22,3 +22,6 @@ export * from "./Facades/StorageDrivers/BaseStorageDriver";
|
|
|
22
22
|
export * from "./Facades/Storage";
|
|
23
23
|
export * from "./DataBuilder/DataBuilder";
|
|
24
24
|
export * from "./DataBuilder/DataBuilderController";
|
|
25
|
+
export * from "./Queue/BaseQueueJob";
|
|
26
|
+
export * from "./Queue/QueueJob";
|
|
27
|
+
export * from "./Queue/QueueJobsRegisty";
|