weixin.js 471 B

1234567891011121314151617
  1. 'use strict';
  2. const Controller = require('egg').Controller;
  3. const { CrudController } = require('naf-framework-mongoose/lib/controller');
  4. // 微信
  5. class WeixinController extends Controller {
  6. constructor(ctx) {
  7. super(ctx);
  8. this.service = this.ctx.service.system.weixin;
  9. }
  10. async appAuth() {
  11. const data = await this.service.appAuth(this.ctx.query, this.ctx.tenant);
  12. this.ctx.ok({ data });
  13. }
  14. }
  15. module.exports = CrudController(WeixinController, {});