Permissions authorization middleware.

This commit is contained in:
Ahmed Bouhuolia
2019-09-16 01:08:19 +02:00
parent ed4d37c8fb
commit de905d7e7c
23 changed files with 318 additions and 51 deletions

View File

@@ -1,7 +1,6 @@
import bookshelf from './bookshelf';
const Item = bookshelf.Model.extend({
/**
* Table name
*/
@@ -25,6 +24,11 @@ const Item = bookshelf.Model.extend({
category() {
return this.belongsTo('ItemCategory', 'category_id');
},
}, {
/**
* Cascade delete dependents.
*/
dependents: ['ItemMetadata'],
});
export default bookshelf.model('Item', Item);