laravel-moderation
laravel-moderation copied to clipboard
A simple Content Moderation System for Laravel 5.* that allows you to Approve or Reject resources like posts, comments, users, etc.
markApproved, markRejected, ... functions incompatible with models with attributes with array casts
I have a model with an `array` cast on one attribute `foo`. ```php protected $casts = [ 'foo' => 'array', ]; ``` But the SQL type is `VARCHAR`. When the...
How can I customize when I approve a model and manually assign the user for moderated_by like $model->moderated_by = 'String user id' ?
For models with an array cast, the attributesToArray() method returns the cast array instead of the serialized array. So usage of `markApproved(), markRejected(), markPostponed() and markPending()` methods of the `Moderatable`...
Is there a way to have more than one moderator per model row? As far as I can tell, it's more of a boolean of approved/declined etc for a row,...
I get page not found errors when trying to access a model for editing that hasn't been approved yet. I'm using restful routes and controllers, along with route-model-binding. I suspect...
When strict mode is off rejected items are excluded by default through a global scope on the boot method. This is to be expected, however, it doesn't appear possible to...
Hi All, I am using Laravel 5.1 and getting the following issue with this package. ``` "Interface 'Illuminate\\Database\\Eloquent\\Scope' not found", // error details "file": "/home/vagrant/projects/laravel/MyApp/vendor/hootlex/laravel-moderation/src/ModerationScope.php", "class": "Symfony\\Component\\Debug\\Exception\\FatalErrorException", ``` In my...
I was thinking about writing a package like this one but with one additional feature : **update the model table only when the changes are confirmed.** ### Problem Imagine a...
Hey, very nice package. However, if this flow does not work with your process, you need to hack it. What do you think about adding a possibility to add a...