我在尝试使用Sequelize和Typescript时遇到了以下错误,这两个我都是新手: (node:17276) UnhandledPromiseRejectionWarning: TypeError: week.calculateDays is not a function 我的路由正在使用的控制器中包含以下内容: import { Request, Response } from "expre
假设我有一个客户,他有一个订单列表和一个愿望列表。在我的模型中,我有一个ClientRepo、OrderRepo和WishListRepo。在控制器中,我应该在哪里实例化这些存储库?让它们成为类级别的实例是个好主意吗?OrderRepo.getOrdersForClientId(clientId);
// put the variables i