@bmstravel/nvp-plop-templates 0.2.3 → 0.2.5
Sign up to get free protection for your applications and to get access to all the features.
@@ -24,6 +24,7 @@ export const {{pascalCase mixinName}}Mixin = () => {
|
|
24
24
|
/* MOL_METHOD_MIXIN */
|
25
25
|
async {{camelCase mixinMethod}}({ }: {{pascalCase mixinMethod}}Params) {
|
26
26
|
const $this: IBaseService<any, any> = this
|
27
|
+
$this.logger.info("{{camelCase mixinMethod}} parameters", ctx.params)
|
27
28
|
const $cacher = $this.broker.cacher as RedisCacher
|
28
29
|
return {}
|
29
30
|
},
|
@@ -35,10 +36,11 @@ export const {{pascalCase mixinName}}Mixin = () => {
|
|
35
36
|
{{camelCase mixinAction}}: {
|
36
37
|
async handler(ctx: Context<{{pascalCase mixinAction}}Params, any>) {
|
37
38
|
const $this: IBaseService<any, any> = this
|
39
|
+
$this.logger.info("{{camelCase mixinAction}} parameters", ctx.params)
|
38
40
|
return {
|
39
41
|
code: 0,
|
40
42
|
data: {},
|
41
|
-
}
|
43
|
+
}
|
42
44
|
},
|
43
45
|
}
|
44
46
|
}
|
@@ -50,7 +52,7 @@ export const {{pascalCase mixinName}}Mixin = () => {
|
|
50
52
|
params: {},
|
51
53
|
handler(ctx: Context<{{pascalCase mixinEvent}}Params, any>) {
|
52
54
|
const $this: IBaseService<any, any> = this
|
53
|
-
$this.logger.info("
|
55
|
+
$this.logger.info("{{camelCase mixinEvent}} event received, parameters OK!", ctx.params);
|
54
56
|
},
|
55
57
|
}
|
56
58
|
}
|
@@ -58,10 +60,7 @@ export const {{pascalCase mixinName}}Mixin = () => {
|
|
58
60
|
return {
|
59
61
|
{{#filter mixinIncludes "mixins"}}
|
60
62
|
mixins: [],
|
61
|
-
{{else}}
|
62
|
-
|
63
63
|
{{/filter}}
|
64
|
-
{{/if}}
|
65
64
|
{{#if mixinMethod}}
|
66
65
|
methods,
|
67
66
|
{{/if}}
|
package/package.json
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
{
|
2
2
|
"name": "@bmstravel/nvp-plop-templates",
|
3
|
-
"version": "0.2.
|
3
|
+
"version": "0.2.5",
|
4
4
|
"description": "🏆 Using for plop templates",
|
5
5
|
"license": "MIT",
|
6
6
|
"main": "lib/index.js",
|
@@ -15,5 +15,5 @@
|
|
15
15
|
"phongnv86 <phongnguyenvan86@gmail.com>",
|
16
16
|
"phongnv86 <phongnv@media-one.vn>"
|
17
17
|
],
|
18
|
-
"gitHead": "
|
18
|
+
"gitHead": "085c998c35b7c04fe33d302db01d1aacb0868f3a"
|
19
19
|
}
|