/** * @author wuweiru * @date 2020/10/14 */ import { Inject, Injectable } from '@nestjs/common'; import { Model } from 'mongoose'; import { InjectModel } from '@nestjs/mongoose'; import { WeChatCode } from '../model/wechat'; import { BaseService } from '../../../base/base.service'; import { MongoDBCollection } from '../../../constant'; import { UserService } from '../../user/service/user.service'; @Injectable() export class WeChatService extends BaseService { constructor( @InjectModel(MongoDBCollection.WeChatCode) protected readonly model: Model, @Inject('UserService') private readonly userService: UserService ) { super(model); } }