1

我正在为 Node.js 使用 CompoundJs 框架。

CompoundJs 使用允许关联的 ORM JugglingDB,例如,用户拥有许多设备:

User.hasMany(Device,   {as: 'devices',  foreignKey: 'UserId'});

我希望当我删除一个用户时,他的设备也会被删除。同样,当我向用户展示时,我会看到他的设备。

JugglingDB 提供吗?

4

0 回答 0