bookshelf-cascade-delete icon indicating copy to clipboard operation
bookshelf-cascade-delete copied to clipboard

Cascade delete with Bookshelf.js

Results 10 bookshelf-cascade-delete issues
Sort by recently updated
recently updated
newest added

I'm trying to delete all objects in the list, but only the support table and the news table itself are deleted ``` bookshelf.model('News', { tableName: 'news', files(){ return this.belongsToMany('Files').through('NewsFiles'); },...

It seems like the constructed delete queries only match the IDs, while with [morph relations](http://bookshelfjs.org/#Model-instance-morphOne) you'd have to check both the ID & type columns. This leads to unwanted deletes....

I'm not sure what exactly triggered this in one particular modal. I am also using `bookshelf-paranoia` which also overrides `destroy`. I was able to fix it for my case by...

Ho there, I am using bookshelf with registry plugin and I have the following model: var bookshelf = require('../bin/database'); var cascadeDelete = require('bookshelf-cascade-delete'); bookshelf.plugin(cascadeDelete); bookshelf.plugin('registry'); var Client = bookshelf.Model.extend({ tableName:...

This PR fixes deleting dependents of the `belongsTo` relation, since the model that's being deleted is the one with the foreign key.

This PR improves the test suite by adding the `test/suite.js` file, reducing its boilerplate since tests are equal for both engines.

This PR adds support for target keys that was introduced on tgriesser/bookshelf#1397.

wip

i am trying to achieve something like this and can not find any documentation in this plugin to achieve it basically i want to only delete specific items of the...

This PR adds support for queries explicitly executed on the relation functions.

wip