feat: add provide and update template

This commit is contained in:
2019-06-11 16:11:34 +08:00
parent 829ca19b4a
commit 177c001bb8
5 changed files with 48 additions and 11 deletions

View File

@@ -1,5 +1,6 @@
export const DBClient = Symbol.for('DBClient')
export interface DBClient<T = any> {
getProvide(): any;
find(collection: string, filter: object): Promise<T[]>;
findOne(collection: string, filter: Object): Promise<T>;
findOneById(collection: string, objectId: string): Promise<T>;