@goweekdays/core 1.1.7 → 1.2.0
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.
- package/CHANGELOG.md +12 -0
- package/dist/index.d.ts +8 -41
- package/dist/index.js +1026 -286
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +1148 -399
- package/dist/index.mjs.map +1 -1
- package/package.json +2 -1
package/CHANGELOG.md
CHANGED
package/dist/index.d.ts
CHANGED
|
@@ -118,7 +118,7 @@ declare function useTokenRepo(): {
|
|
|
118
118
|
token: string;
|
|
119
119
|
user: string | ObjectId;
|
|
120
120
|
}) => Promise<string>;
|
|
121
|
-
getToken: (token: string) => Promise<
|
|
121
|
+
getToken: (token: string) => Promise<any>;
|
|
122
122
|
deleteToken: (token: string) => Promise<mongodb.DeleteResult>;
|
|
123
123
|
};
|
|
124
124
|
|
|
@@ -368,7 +368,7 @@ declare class MFile implements TFile {
|
|
|
368
368
|
declare function useFileRepo(): {
|
|
369
369
|
createFile: (value: TFile, session?: ClientSession) => Promise<string>;
|
|
370
370
|
deleteFileById: (_id: string | ObjectId, session?: ClientSession) => Promise<string>;
|
|
371
|
-
getAllDraftedFiles: () => Promise<
|
|
371
|
+
getAllDraftedFiles: () => Promise<any[]>;
|
|
372
372
|
};
|
|
373
373
|
|
|
374
374
|
declare function useFileService(): {
|
|
@@ -423,11 +423,7 @@ declare function useEntityRepo(): {
|
|
|
423
423
|
page?: number | undefined;
|
|
424
424
|
limit?: number | undefined;
|
|
425
425
|
sort?: {} | undefined;
|
|
426
|
-
}) => Promise<
|
|
427
|
-
items: any[];
|
|
428
|
-
pages: number;
|
|
429
|
-
pageRange: string;
|
|
430
|
-
}>;
|
|
426
|
+
}) => Promise<Record<string, any>>;
|
|
431
427
|
updateEntityFieldById: ({ _id, field, value }?: {
|
|
432
428
|
_id: string | ObjectId;
|
|
433
429
|
field: string;
|
|
@@ -486,11 +482,7 @@ declare function useSubscriptionRepo(): {
|
|
|
486
482
|
limit?: number | undefined;
|
|
487
483
|
sort?: {} | undefined;
|
|
488
484
|
status?: string | undefined;
|
|
489
|
-
}) => Promise<
|
|
490
|
-
items: any[];
|
|
491
|
-
pages: number;
|
|
492
|
-
pageRange: string;
|
|
493
|
-
}>;
|
|
485
|
+
}) => Promise<Record<string, any>>;
|
|
494
486
|
updateStatus: (_id: string | ObjectId, status: string) => Promise<string>;
|
|
495
487
|
getByOrgId: (org: string | ObjectId) => Promise<TSubscription | null>;
|
|
496
488
|
getByAffiliateUserId: (user: string | ObjectId) => Promise<TSubscription | null>;
|
|
@@ -1312,11 +1304,7 @@ declare function usePromoCodeRepo(): {
|
|
|
1312
1304
|
sort?: {} | undefined;
|
|
1313
1305
|
status?: string | undefined;
|
|
1314
1306
|
type?: string | undefined;
|
|
1315
|
-
}) => Promise<
|
|
1316
|
-
items: any[];
|
|
1317
|
-
pages: number;
|
|
1318
|
-
pageRange: string;
|
|
1319
|
-
}>;
|
|
1307
|
+
}) => Promise<Record<string, any>>;
|
|
1320
1308
|
assignByUserId: ({ user, code }?: {
|
|
1321
1309
|
user: string | ObjectId;
|
|
1322
1310
|
code: string;
|
|
@@ -1365,11 +1353,7 @@ declare function useOrderRepo(): {
|
|
|
1365
1353
|
status?: string | undefined;
|
|
1366
1354
|
type?: string | undefined;
|
|
1367
1355
|
id?: string | undefined;
|
|
1368
|
-
}) => Promise<
|
|
1369
|
-
items: any[];
|
|
1370
|
-
pages: number;
|
|
1371
|
-
pageRange: string;
|
|
1372
|
-
}>;
|
|
1356
|
+
}) => Promise<Record<string, any>>;
|
|
1373
1357
|
};
|
|
1374
1358
|
|
|
1375
1359
|
declare function useOrderController(): {
|
|
@@ -2170,14 +2154,7 @@ declare function useCounterRepo(): {
|
|
|
2170
2154
|
createIndex: () => Promise<void>;
|
|
2171
2155
|
createUniqueIndex: () => Promise<void>;
|
|
2172
2156
|
add: (type: string) => Promise<void>;
|
|
2173
|
-
getByType: (type: string) => Promise<
|
|
2174
|
-
type: string;
|
|
2175
|
-
createdAt: Date;
|
|
2176
|
-
count: number;
|
|
2177
|
-
_id?: bson.ObjectId | undefined;
|
|
2178
|
-
updatedAt?: Date | undefined;
|
|
2179
|
-
deletedAt?: Date | undefined;
|
|
2180
|
-
}> | null>;
|
|
2157
|
+
getByType: (type: string) => Promise<any>;
|
|
2181
2158
|
incrementByType: (type: string, session?: ClientSession) => Promise<void>;
|
|
2182
2159
|
};
|
|
2183
2160
|
|
|
@@ -2265,17 +2242,7 @@ declare function usePriceRepo(): {
|
|
|
2265
2242
|
createIndex: () => Promise<void>;
|
|
2266
2243
|
createUniqueIndex: () => Promise<void>;
|
|
2267
2244
|
add: (value: Pick<TPrice, "type" | "name" | "value">) => Promise<void>;
|
|
2268
|
-
getByNameType: (name: string, type: TPriceType) => Promise<
|
|
2269
|
-
type: "one-time-payment" | "other" | "monthly-subscription" | "yearly-subscription";
|
|
2270
|
-
value: number;
|
|
2271
|
-
name: string;
|
|
2272
|
-
_id?: bson.ObjectId | undefined;
|
|
2273
|
-
updatedAt?: Date | undefined;
|
|
2274
|
-
deletedAt?: Date | undefined;
|
|
2275
|
-
createdAt?: Date | undefined;
|
|
2276
|
-
saleValue?: number | undefined;
|
|
2277
|
-
saleExpiry?: Date | undefined;
|
|
2278
|
-
}> | null>;
|
|
2245
|
+
getByNameType: (name: string, type: TPriceType) => Promise<any>;
|
|
2279
2246
|
setSaleValueByType: (value: Pick<TPrice, "type" | "saleValue" | "saleExpiry">, session?: ClientSession) => Promise<void>;
|
|
2280
2247
|
};
|
|
2281
2248
|
|