This commit is contained in:
哆啦好梦
2023-05-16 14:00:37 +08:00
parent 412a6d1427
commit fd3cd5cfdb
2 changed files with 66 additions and 0 deletions

View File

@@ -0,0 +1,29 @@
'use strict';
const { Service } = require('ee-core');
/**
* 示例服务service层为单例
* @class
*/
class ExampleService extends Service {
constructor(ctx) {
super(ctx);
}
/**
* test
*/
async test(args) {
let obj = {
status:'ok',
params: args
}
return obj;
}
}
ExampleService.toString = () => '[class ExampleService]';
module.exports = ExampleService;