lrf 2 tahun lalu
induk
melakukan
3bf518fd40
3 mengubah file dengan 19 tambahan dan 0 penghapusan
  1. 4 0
      app/controller/util.js
  2. 2 0
      app/router.js
  3. 13 0
      app/z_router/group.js

+ 4 - 0
app/controller/util.js

@@ -35,5 +35,9 @@ class UtilController extends Controller {
     const data = await this.tradeService.checkCartBuy(this.bodyObject);
     this.ctx.ok({ data });
   }
+
+  async getGroup() {
+    this.ctx.ok({ data: '弃用' });
+  }
 }
 module.exports = CrudController(UtilController, {});

+ 2 - 0
app/router.js

@@ -17,4 +17,6 @@ module.exports = app => {
   require('./z_router/util')(app); // 工具接口
   require('./z_router/trade/pay')(app); // 支付接口
   require('./z_router/statistics/index')(app); // 统计部分
+
+  require('./z_router/group')(app); // 下版本弃用
 };

+ 13 - 0
app/z_router/group.js

@@ -0,0 +1,13 @@
+'use strict';
+// 路由配置
+const path = require('path');
+const regPath = path.resolve('app', 'public', 'routerRegister');
+const routerRegister = require(regPath);
+const rkey = 'group';
+const ckey = 'group';
+const keyZh = '工具接口';
+const routes = [{ method: 'get', path: `${rkey}/getGroup`, controller: 'util.getGroup', zh: 'none' }];
+
+module.exports = app => {
+  routerRegister(app, routes, keyZh, rkey, ckey);
+};