egg icon indicating copy to clipboard operation
egg copied to clipboard

Cli service

Open sm2017 opened this issue 3 years ago • 2 comments

Is it possible to run a service from cli?

class UserService extends Service {
  async find(uid) {
    const user = await this.ctx.db.query('select * from user where uid = ?', uid);
    return user;
  }
}

Something like this

yarn egg-cli user find 1

sm2017 avatar Jan 20 '21 06:01 sm2017

Reply please!

sm2017 avatar Jan 30 '21 13:01 sm2017

@atian25 Can you please reply?

sm2017 avatar Feb 15 '21 10:02 sm2017