npm_microservice 1.0.27 → 1.0.28
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/dist/service.js +5 -2
- package/dist/services/BaseService.js +5 -2
- package/dist/services/CacheService.js +5 -2
- package/dist/services/SettingService.js +5 -2
- package/dist/services/app/AppTestService.js +5 -2
- package/dist/services/app/BannerService.js +5 -2
- package/dist/services/app/CategoryService.js +5 -2
- package/dist/services/app/NewService.js +5 -2
- package/dist/services/app/RecommendedCourseService.js +5 -2
- package/dist/services/app/SettingAppService.js +5 -2
- package/dist/services/app/TargetService.js +5 -2
- package/dist/services/call_center/CategoryService.js +5 -2
- package/dist/services/call_center/TicketActivityService.js +5 -2
- package/dist/services/call_center/TicketService.js +5 -2
- package/dist/services/call_center/TicketTemplateService.js +5 -2
- package/dist/services/call_center/TicketTopicService.js +5 -2
- package/dist/services/course/CategoryService.js +5 -2
- package/dist/services/course/CourseLessonService.js +5 -2
- package/dist/services/course/StudentService.js +5 -2
- package/dist/services/crm/ContactsService.js +5 -2
- package/dist/services/crm/DeviceService.js +5 -2
- package/dist/services/crm/OpportunitiesService.js +5 -2
- package/dist/services/finance/InvoicesCancelService.js +5 -2
- package/dist/services/finance/InvoicesDetailService.js +5 -2
- package/dist/services/finance/InvoicesLogsAssignService.js +5 -2
- package/dist/services/finance/InvoicesService.js +5 -2
- package/dist/services/finance/PaymentRequestService.js +5 -2
- package/dist/services/finance/PaymentService.js +5 -2
- package/dist/services/finance/VouchersCategoryService.js +5 -2
- package/dist/services/finance/VouchersService.js +5 -2
- package/dist/services/finance/WalletTransactionService.js +5 -2
- package/dist/services/finance/WalletsService.js +5 -2
- package/dist/services/hr/AllowanceService.js +5 -2
- package/dist/services/hr/AnnualLeaveService.js +5 -2
- package/dist/services/hr/CategoryService.js +5 -2
- package/dist/services/hr/DepartmentService.js +5 -2
- package/dist/services/hr/DeviceService.js +5 -2
- package/dist/services/hr/DocumentService.js +5 -2
- package/dist/services/hr/EmployeeExtendService.js +5 -2
- package/dist/services/hr/EmployeeExtendTempService.js +5 -2
- package/dist/services/hr/EmployeeLeaveService.js +5 -2
- package/dist/services/hr/EmployeeQuitService.js +5 -2
- package/dist/services/hr/EmployeeService.js +5 -2
- package/dist/services/hr/EmployeeShiftService.js +5 -2
- package/dist/services/hr/HolidayService.js +5 -2
- package/dist/services/hr/JobTitleService.js +5 -2
- package/dist/services/hr/PositionService.js +5 -2
- package/dist/services/hr/ReasonTypeService.js +5 -2
- package/dist/services/hr/ResignationService.js +5 -2
- package/dist/services/hr/SalaryService.js +5 -2
- package/dist/services/hr/ScheduleOnlineService.js +5 -2
- package/dist/services/hr/ScheduleService.js +5 -2
- package/dist/services/hr/SettingDocumentService.js +5 -2
- package/dist/services/hr/ShiftService.js +5 -2
- package/dist/services/hr/ShiftsCustomerCareService.js +5 -2
- package/dist/services/hr/TicketExtendService.js +5 -2
- package/dist/services/hr/TicketService.js +5 -2
- package/dist/services/hr/TicketTypeService.js +5 -2
- package/dist/services/hr/TrackingConfirmService.js +5 -2
- package/dist/services/hr/TrackingErrorService.js +5 -2
- package/dist/services/inventory/InventoryService.js +5 -2
- package/dist/services/inventory/LogService.js +5 -2
- package/dist/services/inventory/ProductService.js +5 -2
- package/dist/services/inventory/ProductShipmentService.js +5 -2
- package/dist/services/inventory/StoreService.js +5 -2
- package/dist/services/inventory/SupplierService.js +5 -2
- package/dist/services/inventory/TransactionDetailService.js +5 -2
- package/dist/services/inventory/TransactionService.js +5 -2
- package/dist/services/lms/AlbumCategoryService.js +5 -2
- package/dist/services/lms/AlbumFileService.js +5 -2
- package/dist/services/lms/AlbumService.js +5 -2
- package/dist/services/lms/ClassScheduleService.js +5 -2
- package/dist/services/lms/ClassesService.js +5 -2
- package/dist/services/lms/CourseLessonService.js +5 -2
- package/dist/services/lms/CoursePriceService.js +5 -2
- package/dist/services/lms/CourseProductService.js +5 -2
- package/dist/services/lms/CourseService.js +5 -2
- package/dist/services/lms/DocumentCategoryService.js +5 -2
- package/dist/services/lms/DocumentService.js +5 -2
- package/dist/services/lms/LicenseService.js +5 -2
- package/dist/services/lms/PracticeResultService.js +5 -2
- package/dist/services/lms/PracticeService.js +5 -2
- package/dist/services/lms/StudentAgainService.js +5 -2
- package/dist/services/lms/StudentDocumentService.js +5 -2
- package/dist/services/lms/StudentExamTimeService.js +5 -2
- package/dist/services/lms/StudentReviewService.js +5 -2
- package/dist/services/lms/StudentScoreService.js +5 -2
- package/dist/services/lms/StudentService.js +5 -2
- package/dist/services/lms/StudentSettingReviewService.js +5 -2
- package/dist/services/lms/StudentTrackingService.js +5 -2
- package/dist/services/lms/StudentTrialService.js +5 -2
- package/dist/services/notification/AppService.js +5 -2
- package/dist/services/notification/NotificationService.js +5 -2
- package/dist/services/online/CourseLessonService.js +5 -2
- package/dist/services/online/CourseService.js +5 -2
- package/dist/services/online/StudentService.js +5 -2
- package/dist/services/org/BranchRequestService.js +5 -2
- package/dist/services/org/BranchService.js +5 -2
- package/dist/services/org/BranchToMacsService.js +5 -2
- package/dist/services/org/BrandService.js +5 -2
- package/dist/services/org/CitiesService.js +5 -2
- package/dist/services/org/LegalEntityService.js +5 -2
- package/dist/services/pm/NoteService.js +5 -2
- package/dist/services/pm/TaskService.js +5 -2
- package/dist/services/support/CommentService.js +5 -2
- package/dist/services/test/EduTestService.js +5 -2
- package/package.json +1 -1
package/dist/service.js
CHANGED
|
@@ -213,8 +213,11 @@ var require_CacheService = __commonJS({
|
|
|
213
213
|
}
|
|
214
214
|
// Lấy cache theo nhiều ids
|
|
215
215
|
async getCacheByIds(ids = []) {
|
|
216
|
-
|
|
217
|
-
|
|
216
|
+
const validIds = (ids || []).filter(
|
|
217
|
+
(id) => id !== null && id !== void 0 && id !== ""
|
|
218
|
+
);
|
|
219
|
+
if (!this.isCache || !this.redis || !validIds.length) return [];
|
|
220
|
+
const keys = validIds.map(
|
|
218
221
|
(id) => `${this.configService}.${this.service || "unknown"}.${this.module || "unknown"}.id:${id}`
|
|
219
222
|
);
|
|
220
223
|
const results = await this.redis.mget(keys);
|
|
@@ -213,8 +213,11 @@ var require_CacheService = __commonJS({
|
|
|
213
213
|
}
|
|
214
214
|
// Lấy cache theo nhiều ids
|
|
215
215
|
async getCacheByIds(ids = []) {
|
|
216
|
-
|
|
217
|
-
|
|
216
|
+
const validIds = (ids || []).filter(
|
|
217
|
+
(id) => id !== null && id !== void 0 && id !== ""
|
|
218
|
+
);
|
|
219
|
+
if (!this.isCache || !this.redis || !validIds.length) return [];
|
|
220
|
+
const keys = validIds.map(
|
|
218
221
|
(id) => `${this.configService}.${this.service || "unknown"}.${this.module || "unknown"}.id:${id}`
|
|
219
222
|
);
|
|
220
223
|
const results = await this.redis.mget(keys);
|
|
@@ -31,8 +31,11 @@ var CacheService = class {
|
|
|
31
31
|
}
|
|
32
32
|
// Lấy cache theo nhiều ids
|
|
33
33
|
async getCacheByIds(ids = []) {
|
|
34
|
-
|
|
35
|
-
|
|
34
|
+
const validIds = (ids || []).filter(
|
|
35
|
+
(id) => id !== null && id !== void 0 && id !== ""
|
|
36
|
+
);
|
|
37
|
+
if (!this.isCache || !this.redis || !validIds.length) return [];
|
|
38
|
+
const keys = validIds.map(
|
|
36
39
|
(id) => `${this.configService}.${this.service || "unknown"}.${this.module || "unknown"}.id:${id}`
|
|
37
40
|
);
|
|
38
41
|
const results = await this.redis.mget(keys);
|
|
@@ -213,8 +213,11 @@ var require_CacheService = __commonJS({
|
|
|
213
213
|
}
|
|
214
214
|
// Lấy cache theo nhiều ids
|
|
215
215
|
async getCacheByIds(ids = []) {
|
|
216
|
-
|
|
217
|
-
|
|
216
|
+
const validIds = (ids || []).filter(
|
|
217
|
+
(id) => id !== null && id !== void 0 && id !== ""
|
|
218
|
+
);
|
|
219
|
+
if (!this.isCache || !this.redis || !validIds.length) return [];
|
|
220
|
+
const keys = validIds.map(
|
|
218
221
|
(id) => `${this.configService}.${this.service || "unknown"}.${this.module || "unknown"}.id:${id}`
|
|
219
222
|
);
|
|
220
223
|
const results = await this.redis.mget(keys);
|
|
@@ -213,8 +213,11 @@ var require_CacheService = __commonJS({
|
|
|
213
213
|
}
|
|
214
214
|
// Lấy cache theo nhiều ids
|
|
215
215
|
async getCacheByIds(ids = []) {
|
|
216
|
-
|
|
217
|
-
|
|
216
|
+
const validIds = (ids || []).filter(
|
|
217
|
+
(id) => id !== null && id !== void 0 && id !== ""
|
|
218
|
+
);
|
|
219
|
+
if (!this.isCache || !this.redis || !validIds.length) return [];
|
|
220
|
+
const keys = validIds.map(
|
|
218
221
|
(id) => `${this.configService}.${this.service || "unknown"}.${this.module || "unknown"}.id:${id}`
|
|
219
222
|
);
|
|
220
223
|
const results = await this.redis.mget(keys);
|
|
@@ -213,8 +213,11 @@ var require_CacheService = __commonJS({
|
|
|
213
213
|
}
|
|
214
214
|
// Lấy cache theo nhiều ids
|
|
215
215
|
async getCacheByIds(ids = []) {
|
|
216
|
-
|
|
217
|
-
|
|
216
|
+
const validIds = (ids || []).filter(
|
|
217
|
+
(id) => id !== null && id !== void 0 && id !== ""
|
|
218
|
+
);
|
|
219
|
+
if (!this.isCache || !this.redis || !validIds.length) return [];
|
|
220
|
+
const keys = validIds.map(
|
|
218
221
|
(id) => `${this.configService}.${this.service || "unknown"}.${this.module || "unknown"}.id:${id}`
|
|
219
222
|
);
|
|
220
223
|
const results = await this.redis.mget(keys);
|
|
@@ -213,8 +213,11 @@ var require_CacheService = __commonJS({
|
|
|
213
213
|
}
|
|
214
214
|
// Lấy cache theo nhiều ids
|
|
215
215
|
async getCacheByIds(ids = []) {
|
|
216
|
-
|
|
217
|
-
|
|
216
|
+
const validIds = (ids || []).filter(
|
|
217
|
+
(id) => id !== null && id !== void 0 && id !== ""
|
|
218
|
+
);
|
|
219
|
+
if (!this.isCache || !this.redis || !validIds.length) return [];
|
|
220
|
+
const keys = validIds.map(
|
|
218
221
|
(id) => `${this.configService}.${this.service || "unknown"}.${this.module || "unknown"}.id:${id}`
|
|
219
222
|
);
|
|
220
223
|
const results = await this.redis.mget(keys);
|
|
@@ -213,8 +213,11 @@ var require_CacheService = __commonJS({
|
|
|
213
213
|
}
|
|
214
214
|
// Lấy cache theo nhiều ids
|
|
215
215
|
async getCacheByIds(ids = []) {
|
|
216
|
-
|
|
217
|
-
|
|
216
|
+
const validIds = (ids || []).filter(
|
|
217
|
+
(id) => id !== null && id !== void 0 && id !== ""
|
|
218
|
+
);
|
|
219
|
+
if (!this.isCache || !this.redis || !validIds.length) return [];
|
|
220
|
+
const keys = validIds.map(
|
|
218
221
|
(id) => `${this.configService}.${this.service || "unknown"}.${this.module || "unknown"}.id:${id}`
|
|
219
222
|
);
|
|
220
223
|
const results = await this.redis.mget(keys);
|
|
@@ -213,8 +213,11 @@ var require_CacheService = __commonJS({
|
|
|
213
213
|
}
|
|
214
214
|
// Lấy cache theo nhiều ids
|
|
215
215
|
async getCacheByIds(ids = []) {
|
|
216
|
-
|
|
217
|
-
|
|
216
|
+
const validIds = (ids || []).filter(
|
|
217
|
+
(id) => id !== null && id !== void 0 && id !== ""
|
|
218
|
+
);
|
|
219
|
+
if (!this.isCache || !this.redis || !validIds.length) return [];
|
|
220
|
+
const keys = validIds.map(
|
|
218
221
|
(id) => `${this.configService}.${this.service || "unknown"}.${this.module || "unknown"}.id:${id}`
|
|
219
222
|
);
|
|
220
223
|
const results = await this.redis.mget(keys);
|
|
@@ -213,8 +213,11 @@ var require_CacheService = __commonJS({
|
|
|
213
213
|
}
|
|
214
214
|
// Lấy cache theo nhiều ids
|
|
215
215
|
async getCacheByIds(ids = []) {
|
|
216
|
-
|
|
217
|
-
|
|
216
|
+
const validIds = (ids || []).filter(
|
|
217
|
+
(id) => id !== null && id !== void 0 && id !== ""
|
|
218
|
+
);
|
|
219
|
+
if (!this.isCache || !this.redis || !validIds.length) return [];
|
|
220
|
+
const keys = validIds.map(
|
|
218
221
|
(id) => `${this.configService}.${this.service || "unknown"}.${this.module || "unknown"}.id:${id}`
|
|
219
222
|
);
|
|
220
223
|
const results = await this.redis.mget(keys);
|
|
@@ -213,8 +213,11 @@ var require_CacheService = __commonJS({
|
|
|
213
213
|
}
|
|
214
214
|
// Lấy cache theo nhiều ids
|
|
215
215
|
async getCacheByIds(ids = []) {
|
|
216
|
-
|
|
217
|
-
|
|
216
|
+
const validIds = (ids || []).filter(
|
|
217
|
+
(id) => id !== null && id !== void 0 && id !== ""
|
|
218
|
+
);
|
|
219
|
+
if (!this.isCache || !this.redis || !validIds.length) return [];
|
|
220
|
+
const keys = validIds.map(
|
|
218
221
|
(id) => `${this.configService}.${this.service || "unknown"}.${this.module || "unknown"}.id:${id}`
|
|
219
222
|
);
|
|
220
223
|
const results = await this.redis.mget(keys);
|
|
@@ -213,8 +213,11 @@ var require_CacheService = __commonJS({
|
|
|
213
213
|
}
|
|
214
214
|
// Lấy cache theo nhiều ids
|
|
215
215
|
async getCacheByIds(ids = []) {
|
|
216
|
-
|
|
217
|
-
|
|
216
|
+
const validIds = (ids || []).filter(
|
|
217
|
+
(id) => id !== null && id !== void 0 && id !== ""
|
|
218
|
+
);
|
|
219
|
+
if (!this.isCache || !this.redis || !validIds.length) return [];
|
|
220
|
+
const keys = validIds.map(
|
|
218
221
|
(id) => `${this.configService}.${this.service || "unknown"}.${this.module || "unknown"}.id:${id}`
|
|
219
222
|
);
|
|
220
223
|
const results = await this.redis.mget(keys);
|
|
@@ -213,8 +213,11 @@ var require_CacheService = __commonJS({
|
|
|
213
213
|
}
|
|
214
214
|
// Lấy cache theo nhiều ids
|
|
215
215
|
async getCacheByIds(ids = []) {
|
|
216
|
-
|
|
217
|
-
|
|
216
|
+
const validIds = (ids || []).filter(
|
|
217
|
+
(id) => id !== null && id !== void 0 && id !== ""
|
|
218
|
+
);
|
|
219
|
+
if (!this.isCache || !this.redis || !validIds.length) return [];
|
|
220
|
+
const keys = validIds.map(
|
|
218
221
|
(id) => `${this.configService}.${this.service || "unknown"}.${this.module || "unknown"}.id:${id}`
|
|
219
222
|
);
|
|
220
223
|
const results = await this.redis.mget(keys);
|
|
@@ -213,8 +213,11 @@ var require_CacheService = __commonJS({
|
|
|
213
213
|
}
|
|
214
214
|
// Lấy cache theo nhiều ids
|
|
215
215
|
async getCacheByIds(ids = []) {
|
|
216
|
-
|
|
217
|
-
|
|
216
|
+
const validIds = (ids || []).filter(
|
|
217
|
+
(id) => id !== null && id !== void 0 && id !== ""
|
|
218
|
+
);
|
|
219
|
+
if (!this.isCache || !this.redis || !validIds.length) return [];
|
|
220
|
+
const keys = validIds.map(
|
|
218
221
|
(id) => `${this.configService}.${this.service || "unknown"}.${this.module || "unknown"}.id:${id}`
|
|
219
222
|
);
|
|
220
223
|
const results = await this.redis.mget(keys);
|
|
@@ -213,8 +213,11 @@ var require_CacheService = __commonJS({
|
|
|
213
213
|
}
|
|
214
214
|
// Lấy cache theo nhiều ids
|
|
215
215
|
async getCacheByIds(ids = []) {
|
|
216
|
-
|
|
217
|
-
|
|
216
|
+
const validIds = (ids || []).filter(
|
|
217
|
+
(id) => id !== null && id !== void 0 && id !== ""
|
|
218
|
+
);
|
|
219
|
+
if (!this.isCache || !this.redis || !validIds.length) return [];
|
|
220
|
+
const keys = validIds.map(
|
|
218
221
|
(id) => `${this.configService}.${this.service || "unknown"}.${this.module || "unknown"}.id:${id}`
|
|
219
222
|
);
|
|
220
223
|
const results = await this.redis.mget(keys);
|
|
@@ -213,8 +213,11 @@ var require_CacheService = __commonJS({
|
|
|
213
213
|
}
|
|
214
214
|
// Lấy cache theo nhiều ids
|
|
215
215
|
async getCacheByIds(ids = []) {
|
|
216
|
-
|
|
217
|
-
|
|
216
|
+
const validIds = (ids || []).filter(
|
|
217
|
+
(id) => id !== null && id !== void 0 && id !== ""
|
|
218
|
+
);
|
|
219
|
+
if (!this.isCache || !this.redis || !validIds.length) return [];
|
|
220
|
+
const keys = validIds.map(
|
|
218
221
|
(id) => `${this.configService}.${this.service || "unknown"}.${this.module || "unknown"}.id:${id}`
|
|
219
222
|
);
|
|
220
223
|
const results = await this.redis.mget(keys);
|
|
@@ -213,8 +213,11 @@ var require_CacheService = __commonJS({
|
|
|
213
213
|
}
|
|
214
214
|
// Lấy cache theo nhiều ids
|
|
215
215
|
async getCacheByIds(ids = []) {
|
|
216
|
-
|
|
217
|
-
|
|
216
|
+
const validIds = (ids || []).filter(
|
|
217
|
+
(id) => id !== null && id !== void 0 && id !== ""
|
|
218
|
+
);
|
|
219
|
+
if (!this.isCache || !this.redis || !validIds.length) return [];
|
|
220
|
+
const keys = validIds.map(
|
|
218
221
|
(id) => `${this.configService}.${this.service || "unknown"}.${this.module || "unknown"}.id:${id}`
|
|
219
222
|
);
|
|
220
223
|
const results = await this.redis.mget(keys);
|
|
@@ -213,8 +213,11 @@ var require_CacheService = __commonJS({
|
|
|
213
213
|
}
|
|
214
214
|
// Lấy cache theo nhiều ids
|
|
215
215
|
async getCacheByIds(ids = []) {
|
|
216
|
-
|
|
217
|
-
|
|
216
|
+
const validIds = (ids || []).filter(
|
|
217
|
+
(id) => id !== null && id !== void 0 && id !== ""
|
|
218
|
+
);
|
|
219
|
+
if (!this.isCache || !this.redis || !validIds.length) return [];
|
|
220
|
+
const keys = validIds.map(
|
|
218
221
|
(id) => `${this.configService}.${this.service || "unknown"}.${this.module || "unknown"}.id:${id}`
|
|
219
222
|
);
|
|
220
223
|
const results = await this.redis.mget(keys);
|
|
@@ -213,8 +213,11 @@ var require_CacheService = __commonJS({
|
|
|
213
213
|
}
|
|
214
214
|
// Lấy cache theo nhiều ids
|
|
215
215
|
async getCacheByIds(ids = []) {
|
|
216
|
-
|
|
217
|
-
|
|
216
|
+
const validIds = (ids || []).filter(
|
|
217
|
+
(id) => id !== null && id !== void 0 && id !== ""
|
|
218
|
+
);
|
|
219
|
+
if (!this.isCache || !this.redis || !validIds.length) return [];
|
|
220
|
+
const keys = validIds.map(
|
|
218
221
|
(id) => `${this.configService}.${this.service || "unknown"}.${this.module || "unknown"}.id:${id}`
|
|
219
222
|
);
|
|
220
223
|
const results = await this.redis.mget(keys);
|
|
@@ -213,8 +213,11 @@ var require_CacheService = __commonJS({
|
|
|
213
213
|
}
|
|
214
214
|
// Lấy cache theo nhiều ids
|
|
215
215
|
async getCacheByIds(ids = []) {
|
|
216
|
-
|
|
217
|
-
|
|
216
|
+
const validIds = (ids || []).filter(
|
|
217
|
+
(id) => id !== null && id !== void 0 && id !== ""
|
|
218
|
+
);
|
|
219
|
+
if (!this.isCache || !this.redis || !validIds.length) return [];
|
|
220
|
+
const keys = validIds.map(
|
|
218
221
|
(id) => `${this.configService}.${this.service || "unknown"}.${this.module || "unknown"}.id:${id}`
|
|
219
222
|
);
|
|
220
223
|
const results = await this.redis.mget(keys);
|
|
@@ -213,8 +213,11 @@ var require_CacheService = __commonJS({
|
|
|
213
213
|
}
|
|
214
214
|
// Lấy cache theo nhiều ids
|
|
215
215
|
async getCacheByIds(ids = []) {
|
|
216
|
-
|
|
217
|
-
|
|
216
|
+
const validIds = (ids || []).filter(
|
|
217
|
+
(id) => id !== null && id !== void 0 && id !== ""
|
|
218
|
+
);
|
|
219
|
+
if (!this.isCache || !this.redis || !validIds.length) return [];
|
|
220
|
+
const keys = validIds.map(
|
|
218
221
|
(id) => `${this.configService}.${this.service || "unknown"}.${this.module || "unknown"}.id:${id}`
|
|
219
222
|
);
|
|
220
223
|
const results = await this.redis.mget(keys);
|
|
@@ -213,8 +213,11 @@ var require_CacheService = __commonJS({
|
|
|
213
213
|
}
|
|
214
214
|
// Lấy cache theo nhiều ids
|
|
215
215
|
async getCacheByIds(ids = []) {
|
|
216
|
-
|
|
217
|
-
|
|
216
|
+
const validIds = (ids || []).filter(
|
|
217
|
+
(id) => id !== null && id !== void 0 && id !== ""
|
|
218
|
+
);
|
|
219
|
+
if (!this.isCache || !this.redis || !validIds.length) return [];
|
|
220
|
+
const keys = validIds.map(
|
|
218
221
|
(id) => `${this.configService}.${this.service || "unknown"}.${this.module || "unknown"}.id:${id}`
|
|
219
222
|
);
|
|
220
223
|
const results = await this.redis.mget(keys);
|
|
@@ -213,8 +213,11 @@ var require_CacheService = __commonJS({
|
|
|
213
213
|
}
|
|
214
214
|
// Lấy cache theo nhiều ids
|
|
215
215
|
async getCacheByIds(ids = []) {
|
|
216
|
-
|
|
217
|
-
|
|
216
|
+
const validIds = (ids || []).filter(
|
|
217
|
+
(id) => id !== null && id !== void 0 && id !== ""
|
|
218
|
+
);
|
|
219
|
+
if (!this.isCache || !this.redis || !validIds.length) return [];
|
|
220
|
+
const keys = validIds.map(
|
|
218
221
|
(id) => `${this.configService}.${this.service || "unknown"}.${this.module || "unknown"}.id:${id}`
|
|
219
222
|
);
|
|
220
223
|
const results = await this.redis.mget(keys);
|
|
@@ -213,8 +213,11 @@ var require_CacheService = __commonJS({
|
|
|
213
213
|
}
|
|
214
214
|
// Lấy cache theo nhiều ids
|
|
215
215
|
async getCacheByIds(ids = []) {
|
|
216
|
-
|
|
217
|
-
|
|
216
|
+
const validIds = (ids || []).filter(
|
|
217
|
+
(id) => id !== null && id !== void 0 && id !== ""
|
|
218
|
+
);
|
|
219
|
+
if (!this.isCache || !this.redis || !validIds.length) return [];
|
|
220
|
+
const keys = validIds.map(
|
|
218
221
|
(id) => `${this.configService}.${this.service || "unknown"}.${this.module || "unknown"}.id:${id}`
|
|
219
222
|
);
|
|
220
223
|
const results = await this.redis.mget(keys);
|
|
@@ -213,8 +213,11 @@ var require_CacheService = __commonJS({
|
|
|
213
213
|
}
|
|
214
214
|
// Lấy cache theo nhiều ids
|
|
215
215
|
async getCacheByIds(ids = []) {
|
|
216
|
-
|
|
217
|
-
|
|
216
|
+
const validIds = (ids || []).filter(
|
|
217
|
+
(id) => id !== null && id !== void 0 && id !== ""
|
|
218
|
+
);
|
|
219
|
+
if (!this.isCache || !this.redis || !validIds.length) return [];
|
|
220
|
+
const keys = validIds.map(
|
|
218
221
|
(id) => `${this.configService}.${this.service || "unknown"}.${this.module || "unknown"}.id:${id}`
|
|
219
222
|
);
|
|
220
223
|
const results = await this.redis.mget(keys);
|
|
@@ -213,8 +213,11 @@ var require_CacheService = __commonJS({
|
|
|
213
213
|
}
|
|
214
214
|
// Lấy cache theo nhiều ids
|
|
215
215
|
async getCacheByIds(ids = []) {
|
|
216
|
-
|
|
217
|
-
|
|
216
|
+
const validIds = (ids || []).filter(
|
|
217
|
+
(id) => id !== null && id !== void 0 && id !== ""
|
|
218
|
+
);
|
|
219
|
+
if (!this.isCache || !this.redis || !validIds.length) return [];
|
|
220
|
+
const keys = validIds.map(
|
|
218
221
|
(id) => `${this.configService}.${this.service || "unknown"}.${this.module || "unknown"}.id:${id}`
|
|
219
222
|
);
|
|
220
223
|
const results = await this.redis.mget(keys);
|
|
@@ -213,8 +213,11 @@ var require_CacheService = __commonJS({
|
|
|
213
213
|
}
|
|
214
214
|
// Lấy cache theo nhiều ids
|
|
215
215
|
async getCacheByIds(ids = []) {
|
|
216
|
-
|
|
217
|
-
|
|
216
|
+
const validIds = (ids || []).filter(
|
|
217
|
+
(id) => id !== null && id !== void 0 && id !== ""
|
|
218
|
+
);
|
|
219
|
+
if (!this.isCache || !this.redis || !validIds.length) return [];
|
|
220
|
+
const keys = validIds.map(
|
|
218
221
|
(id) => `${this.configService}.${this.service || "unknown"}.${this.module || "unknown"}.id:${id}`
|
|
219
222
|
);
|
|
220
223
|
const results = await this.redis.mget(keys);
|
|
@@ -213,8 +213,11 @@ var require_CacheService = __commonJS({
|
|
|
213
213
|
}
|
|
214
214
|
// Lấy cache theo nhiều ids
|
|
215
215
|
async getCacheByIds(ids = []) {
|
|
216
|
-
|
|
217
|
-
|
|
216
|
+
const validIds = (ids || []).filter(
|
|
217
|
+
(id) => id !== null && id !== void 0 && id !== ""
|
|
218
|
+
);
|
|
219
|
+
if (!this.isCache || !this.redis || !validIds.length) return [];
|
|
220
|
+
const keys = validIds.map(
|
|
218
221
|
(id) => `${this.configService}.${this.service || "unknown"}.${this.module || "unknown"}.id:${id}`
|
|
219
222
|
);
|
|
220
223
|
const results = await this.redis.mget(keys);
|
|
@@ -213,8 +213,11 @@ var require_CacheService = __commonJS({
|
|
|
213
213
|
}
|
|
214
214
|
// Lấy cache theo nhiều ids
|
|
215
215
|
async getCacheByIds(ids = []) {
|
|
216
|
-
|
|
217
|
-
|
|
216
|
+
const validIds = (ids || []).filter(
|
|
217
|
+
(id) => id !== null && id !== void 0 && id !== ""
|
|
218
|
+
);
|
|
219
|
+
if (!this.isCache || !this.redis || !validIds.length) return [];
|
|
220
|
+
const keys = validIds.map(
|
|
218
221
|
(id) => `${this.configService}.${this.service || "unknown"}.${this.module || "unknown"}.id:${id}`
|
|
219
222
|
);
|
|
220
223
|
const results = await this.redis.mget(keys);
|
|
@@ -213,8 +213,11 @@ var require_CacheService = __commonJS({
|
|
|
213
213
|
}
|
|
214
214
|
// Lấy cache theo nhiều ids
|
|
215
215
|
async getCacheByIds(ids = []) {
|
|
216
|
-
|
|
217
|
-
|
|
216
|
+
const validIds = (ids || []).filter(
|
|
217
|
+
(id) => id !== null && id !== void 0 && id !== ""
|
|
218
|
+
);
|
|
219
|
+
if (!this.isCache || !this.redis || !validIds.length) return [];
|
|
220
|
+
const keys = validIds.map(
|
|
218
221
|
(id) => `${this.configService}.${this.service || "unknown"}.${this.module || "unknown"}.id:${id}`
|
|
219
222
|
);
|
|
220
223
|
const results = await this.redis.mget(keys);
|
|
@@ -213,8 +213,11 @@ var require_CacheService = __commonJS({
|
|
|
213
213
|
}
|
|
214
214
|
// Lấy cache theo nhiều ids
|
|
215
215
|
async getCacheByIds(ids = []) {
|
|
216
|
-
|
|
217
|
-
|
|
216
|
+
const validIds = (ids || []).filter(
|
|
217
|
+
(id) => id !== null && id !== void 0 && id !== ""
|
|
218
|
+
);
|
|
219
|
+
if (!this.isCache || !this.redis || !validIds.length) return [];
|
|
220
|
+
const keys = validIds.map(
|
|
218
221
|
(id) => `${this.configService}.${this.service || "unknown"}.${this.module || "unknown"}.id:${id}`
|
|
219
222
|
);
|
|
220
223
|
const results = await this.redis.mget(keys);
|
|
@@ -213,8 +213,11 @@ var require_CacheService = __commonJS({
|
|
|
213
213
|
}
|
|
214
214
|
// Lấy cache theo nhiều ids
|
|
215
215
|
async getCacheByIds(ids = []) {
|
|
216
|
-
|
|
217
|
-
|
|
216
|
+
const validIds = (ids || []).filter(
|
|
217
|
+
(id) => id !== null && id !== void 0 && id !== ""
|
|
218
|
+
);
|
|
219
|
+
if (!this.isCache || !this.redis || !validIds.length) return [];
|
|
220
|
+
const keys = validIds.map(
|
|
218
221
|
(id) => `${this.configService}.${this.service || "unknown"}.${this.module || "unknown"}.id:${id}`
|
|
219
222
|
);
|
|
220
223
|
const results = await this.redis.mget(keys);
|
|
@@ -213,8 +213,11 @@ var require_CacheService = __commonJS({
|
|
|
213
213
|
}
|
|
214
214
|
// Lấy cache theo nhiều ids
|
|
215
215
|
async getCacheByIds(ids = []) {
|
|
216
|
-
|
|
217
|
-
|
|
216
|
+
const validIds = (ids || []).filter(
|
|
217
|
+
(id) => id !== null && id !== void 0 && id !== ""
|
|
218
|
+
);
|
|
219
|
+
if (!this.isCache || !this.redis || !validIds.length) return [];
|
|
220
|
+
const keys = validIds.map(
|
|
218
221
|
(id) => `${this.configService}.${this.service || "unknown"}.${this.module || "unknown"}.id:${id}`
|
|
219
222
|
);
|
|
220
223
|
const results = await this.redis.mget(keys);
|
|
@@ -213,8 +213,11 @@ var require_CacheService = __commonJS({
|
|
|
213
213
|
}
|
|
214
214
|
// Lấy cache theo nhiều ids
|
|
215
215
|
async getCacheByIds(ids = []) {
|
|
216
|
-
|
|
217
|
-
|
|
216
|
+
const validIds = (ids || []).filter(
|
|
217
|
+
(id) => id !== null && id !== void 0 && id !== ""
|
|
218
|
+
);
|
|
219
|
+
if (!this.isCache || !this.redis || !validIds.length) return [];
|
|
220
|
+
const keys = validIds.map(
|
|
218
221
|
(id) => `${this.configService}.${this.service || "unknown"}.${this.module || "unknown"}.id:${id}`
|
|
219
222
|
);
|
|
220
223
|
const results = await this.redis.mget(keys);
|
|
@@ -213,8 +213,11 @@ var require_CacheService = __commonJS({
|
|
|
213
213
|
}
|
|
214
214
|
// Lấy cache theo nhiều ids
|
|
215
215
|
async getCacheByIds(ids = []) {
|
|
216
|
-
|
|
217
|
-
|
|
216
|
+
const validIds = (ids || []).filter(
|
|
217
|
+
(id) => id !== null && id !== void 0 && id !== ""
|
|
218
|
+
);
|
|
219
|
+
if (!this.isCache || !this.redis || !validIds.length) return [];
|
|
220
|
+
const keys = validIds.map(
|
|
218
221
|
(id) => `${this.configService}.${this.service || "unknown"}.${this.module || "unknown"}.id:${id}`
|
|
219
222
|
);
|
|
220
223
|
const results = await this.redis.mget(keys);
|
|
@@ -213,8 +213,11 @@ var require_CacheService = __commonJS({
|
|
|
213
213
|
}
|
|
214
214
|
// Lấy cache theo nhiều ids
|
|
215
215
|
async getCacheByIds(ids = []) {
|
|
216
|
-
|
|
217
|
-
|
|
216
|
+
const validIds = (ids || []).filter(
|
|
217
|
+
(id) => id !== null && id !== void 0 && id !== ""
|
|
218
|
+
);
|
|
219
|
+
if (!this.isCache || !this.redis || !validIds.length) return [];
|
|
220
|
+
const keys = validIds.map(
|
|
218
221
|
(id) => `${this.configService}.${this.service || "unknown"}.${this.module || "unknown"}.id:${id}`
|
|
219
222
|
);
|
|
220
223
|
const results = await this.redis.mget(keys);
|
|
@@ -213,8 +213,11 @@ var require_CacheService = __commonJS({
|
|
|
213
213
|
}
|
|
214
214
|
// Lấy cache theo nhiều ids
|
|
215
215
|
async getCacheByIds(ids = []) {
|
|
216
|
-
|
|
217
|
-
|
|
216
|
+
const validIds = (ids || []).filter(
|
|
217
|
+
(id) => id !== null && id !== void 0 && id !== ""
|
|
218
|
+
);
|
|
219
|
+
if (!this.isCache || !this.redis || !validIds.length) return [];
|
|
220
|
+
const keys = validIds.map(
|
|
218
221
|
(id) => `${this.configService}.${this.service || "unknown"}.${this.module || "unknown"}.id:${id}`
|
|
219
222
|
);
|
|
220
223
|
const results = await this.redis.mget(keys);
|
|
@@ -213,8 +213,11 @@ var require_CacheService = __commonJS({
|
|
|
213
213
|
}
|
|
214
214
|
// Lấy cache theo nhiều ids
|
|
215
215
|
async getCacheByIds(ids = []) {
|
|
216
|
-
|
|
217
|
-
|
|
216
|
+
const validIds = (ids || []).filter(
|
|
217
|
+
(id) => id !== null && id !== void 0 && id !== ""
|
|
218
|
+
);
|
|
219
|
+
if (!this.isCache || !this.redis || !validIds.length) return [];
|
|
220
|
+
const keys = validIds.map(
|
|
218
221
|
(id) => `${this.configService}.${this.service || "unknown"}.${this.module || "unknown"}.id:${id}`
|
|
219
222
|
);
|
|
220
223
|
const results = await this.redis.mget(keys);
|
|
@@ -213,8 +213,11 @@ var require_CacheService = __commonJS({
|
|
|
213
213
|
}
|
|
214
214
|
// Lấy cache theo nhiều ids
|
|
215
215
|
async getCacheByIds(ids = []) {
|
|
216
|
-
|
|
217
|
-
|
|
216
|
+
const validIds = (ids || []).filter(
|
|
217
|
+
(id) => id !== null && id !== void 0 && id !== ""
|
|
218
|
+
);
|
|
219
|
+
if (!this.isCache || !this.redis || !validIds.length) return [];
|
|
220
|
+
const keys = validIds.map(
|
|
218
221
|
(id) => `${this.configService}.${this.service || "unknown"}.${this.module || "unknown"}.id:${id}`
|
|
219
222
|
);
|
|
220
223
|
const results = await this.redis.mget(keys);
|
|
@@ -213,8 +213,11 @@ var require_CacheService = __commonJS({
|
|
|
213
213
|
}
|
|
214
214
|
// Lấy cache theo nhiều ids
|
|
215
215
|
async getCacheByIds(ids = []) {
|
|
216
|
-
|
|
217
|
-
|
|
216
|
+
const validIds = (ids || []).filter(
|
|
217
|
+
(id) => id !== null && id !== void 0 && id !== ""
|
|
218
|
+
);
|
|
219
|
+
if (!this.isCache || !this.redis || !validIds.length) return [];
|
|
220
|
+
const keys = validIds.map(
|
|
218
221
|
(id) => `${this.configService}.${this.service || "unknown"}.${this.module || "unknown"}.id:${id}`
|
|
219
222
|
);
|
|
220
223
|
const results = await this.redis.mget(keys);
|