add v2 routes, controllers
This commit is contained in:
1 parent
f4b76baaa2
commit
6d0c560948
38 files changed
+1532
-3
No files matched your search
@@ -1,6 +1,8 @@
|
||||
import { ITokenizedUser, IMaintenance, Maintenance } from "../../../db/v2/models/index.js";
|
||||
import ApiError from "../../../utils/ApiError.js";
|
||||
|
||||
const SERVICE_NAME = "MaintenanceServiceV2";
|
||||
|
||||
export interface IMaintenanceService {
|
||||
create: (
|
||||
tokenizedUser: ITokenizedUser,
|
||||
@@ -18,6 +20,7 @@ export interface IMaintenanceService {
|
||||
type MaintenanceCache = Map<string, IMaintenance[]>;
|
||||
|
||||
class MaintenanceService implements IMaintenanceService {
|
||||
static SERVICE_NAME = SERVICE_NAME;
|
||||
private maintenanceCache: MaintenanceCache;
|
||||
private lastRefresh: number;
|
||||
private CACHE_TTL_MS = 60 * 1000;
|
||||
|
||||
Reference in new issue
Block a user