vona-module-home-base 5.0.13 → 5.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/dist/index.js +16 -26
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -1,14 +1,12 @@
|
|
|
1
1
|
import { BeanInfo, BeanBase, BeanSimple, BeanScopeBase } from 'vona';
|
|
2
|
+
import { __decorate, __param, __metadata } from 'tslib';
|
|
2
3
|
import { Service, Scope } from 'vona-module-a-bean';
|
|
3
4
|
import { DtoMenus } from 'vona-module-a-menu';
|
|
4
5
|
import { Api, v } from 'vona-module-a-openapiutils';
|
|
5
|
-
import {
|
|
6
|
+
import { Web, Arg, Controller } from 'vona-module-a-web';
|
|
6
7
|
import { zhCN, en } from 'zod/locales';
|
|
7
8
|
|
|
8
|
-
|
|
9
|
-
let ServiceMenu = (_dec$2 = Service(), _dec2$2 = BeanInfo({
|
|
10
|
-
module: "home-base"
|
|
11
|
-
}), _dec$2(_class$2 = _dec2$2(_class$2 = class ServiceMenu extends BeanBase {
|
|
9
|
+
let ServiceMenu = class ServiceMenu extends BeanBase {
|
|
12
10
|
async retrieveMenus(publicPath) {
|
|
13
11
|
return await this.bean.menu.retrieveMenus(publicPath, async () => {
|
|
14
12
|
return this._getMenusDefault();
|
|
@@ -24,27 +22,20 @@ let ServiceMenu = (_dec$2 = Service(), _dec2$2 = BeanInfo({
|
|
|
24
22
|
}]
|
|
25
23
|
};
|
|
26
24
|
}
|
|
27
|
-
}
|
|
28
|
-
|
|
29
|
-
function _applyDecoratedDescriptor(i, e, r, n, l) {
|
|
30
|
-
var a = {};
|
|
31
|
-
return Object.keys(n).forEach(function (i) {
|
|
32
|
-
a[i] = n[i];
|
|
33
|
-
}), a.enumerable = !!a.enumerable, a.configurable = !!a.configurable, ("value" in a || a.initializer) && (a.writable = true), a = r.slice().reverse().reduce(function (r, n) {
|
|
34
|
-
return n(i, e, r) || r;
|
|
35
|
-
}, a), l && void 0 !== a.initializer && (a.value = a.initializer ? a.initializer.call(l) : void 0, a.initializer = void 0), void 0 === a.initializer ? (Object.defineProperty(i, e, a), null) : a;
|
|
36
|
-
}
|
|
37
|
-
|
|
38
|
-
var _dec$1, _dec2$1, _dec3, _dec4, _dec5, _dec6, _dec7, _class$1, _class2;
|
|
39
|
-
let ControllerMenu = (_dec$1 = Controller('menu'), _dec2$1 = BeanInfo({
|
|
25
|
+
};
|
|
26
|
+
ServiceMenu = __decorate([Service(), BeanInfo({
|
|
40
27
|
module: "home-base"
|
|
41
|
-
}),
|
|
42
|
-
|
|
43
|
-
|
|
28
|
+
})], ServiceMenu);
|
|
29
|
+
|
|
30
|
+
let ControllerMenu = class ControllerMenu extends BeanBase {
|
|
44
31
|
async retrieveMenus(publicPath) {
|
|
45
32
|
return await this.scope.service.menu.retrieveMenus(publicPath);
|
|
46
33
|
}
|
|
47
|
-
}
|
|
34
|
+
};
|
|
35
|
+
__decorate([Web.get(':publicPath?'), Api.body(v.object(DtoMenus)), __param(0, Arg.param('publicPath', v.optional())), __metadata("design:type", Function), __metadata("design:paramtypes", [String]), __metadata("design:returntype", Promise)], ControllerMenu.prototype, "retrieveMenus", null);
|
|
36
|
+
ControllerMenu = __decorate([Controller('menu'), BeanInfo({
|
|
37
|
+
module: "home-base"
|
|
38
|
+
})], ControllerMenu);
|
|
48
39
|
|
|
49
40
|
class Main extends BeanSimple {
|
|
50
41
|
async moduleLoading() {}
|
|
@@ -58,11 +49,10 @@ class Main extends BeanSimple {
|
|
|
58
49
|
async configLoaded(_config) {}
|
|
59
50
|
}
|
|
60
51
|
|
|
61
|
-
|
|
62
|
-
|
|
52
|
+
let ScopeModuleHomeBase = class ScopeModuleHomeBase extends BeanScopeBase {};
|
|
53
|
+
ScopeModuleHomeBase = __decorate([Scope(), BeanInfo({
|
|
63
54
|
module: "home-base"
|
|
64
|
-
}),
|
|
65
|
-
|
|
55
|
+
})], ScopeModuleHomeBase);
|
|
66
56
|
/** scope: end */
|
|
67
57
|
|
|
68
58
|
export { ControllerMenu, Main, ScopeModuleHomeBase, ServiceMenu };
|