vona-module-a-mail 5.0.2 → 5.0.5

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -88,6 +88,9 @@ declare module 'vona-module-a-mail' {
88
88
  count<T extends IModelSelectCountParams<EntityMail, ModelMail, ModelJoins>, ModelJoins extends TypeModelsClassLikeGeneral | undefined = undefined>(params?: T, options?: IModelMethodOptions, modelJoins?: ModelJoins): Promise<BigNumber | undefined>;
89
89
  aggregate<T extends IModelSelectAggrParams<EntityMail, ModelMail, ModelJoins>, ModelJoins extends TypeModelsClassLikeGeneral | undefined = undefined>(params?: T, options?: IModelMethodOptions, modelJoins?: ModelJoins): Promise<TypeModelAggrRelationResult<T>>;
90
90
  group<T extends IModelSelectGroupParams<EntityMail, ModelMail, ModelJoins>, ModelJoins extends TypeModelsClassLikeGeneral | undefined = undefined>(params?: T, options?: IModelMethodOptions, modelJoins?: ModelJoins): Promise<TypeModelGroupRelationResult<EntityMail, T>[]>;
91
+ getById<T extends IModelGetOptions<EntityMail, ModelMail>>(id: TableIdentity, options?: T): Promise<TypeModelRelationResult<EntityMail, ModelMail, T> | undefined>;
92
+ updateById<T extends IModelUpdateOptions<EntityMail, ModelMail>>(id: TableIdentity, data: TypeModelMutateRelationData<EntityMail, ModelMail, T>, options?: T): Promise<TypeModelMutateRelationData<EntityMail, ModelMail, T>>;
93
+ deleteById<T extends IModelDeleteOptions<EntityMail, ModelMail>>(id: TableIdentity, options?: T): Promise<void>;
91
94
  }
92
95
  }
93
96
  declare module 'vona-module-a-orm' {
package/dist/index.js CHANGED
@@ -121,9 +121,7 @@ let ServiceMail = (_dec$3 = Service(), _dec2$3 = BeanInfo({
121
121
  module: "a-mail"
122
122
  }), _dec$3(_class$3 = _dec2$3(_class$3 = class ServiceMail extends BeanBase {
123
123
  async sendById(id) {
124
- const mail = await this.scope.model.mail.get({
125
- id
126
- });
124
+ const mail = await this.scope.model.mail.getById(id);
127
125
  if (!mail) return;
128
126
  const clientName = mail.client;
129
127
  // client
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "vona-module-a-mail",
3
3
  "type": "module",
4
- "version": "5.0.2",
4
+ "version": "5.0.5",
5
5
  "title": "a-mail",
6
6
  "vonaModule": {
7
7
  "fileVersion": 1,