Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- A.associate = function(models) {
- A.belongsToMany(models.B, {
- through: 'A_B',
- as: 'Bs',
- foreignKey: 'a_id'
- });
- };
- C.associate = function(models) {
- C.hasMany(models.A_B, {
- as: 'ABs',
- foreignKey: 'c_id'
- });
- };
- Error: C.hasMany called with something that's not a subclass of Sequelize.Model
Add Comment
Please, Sign In to add comment