mirror of
https://github.com/advplyr/audiobookshelf.git
synced 2026-03-02 22:19:40 +00:00
Update model casing & associations
This commit is contained in:
parent
2131a65299
commit
54ca58e610
45 changed files with 830 additions and 561 deletions
|
|
@ -15,13 +15,13 @@ module.exports = (sequelize) => {
|
|||
end: DataTypes.FLOAT
|
||||
}, {
|
||||
sequelize,
|
||||
modelName: 'BookChapter'
|
||||
modelName: 'bookChapter'
|
||||
})
|
||||
|
||||
const { Book } = sequelize.models
|
||||
const { book } = sequelize.models
|
||||
|
||||
Book.hasMany(BookChapter)
|
||||
BookChapter.belongsTo(Book)
|
||||
book.hasMany(BookChapter)
|
||||
BookChapter.belongsTo(book)
|
||||
|
||||
return BookChapter
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue