Event Listener and new content by Tailor

is any way how use Event listener (Event - October CMS - 3.x) for do anything after publish new content by tailor? A need fire some action after add new content.


Hi @PetrVytlacil

This extension code technically meets the given requirements:

\Tailor\Models\EntryRecord::extend(function($model) {
    $model->bindEvent('model.beforeSave', function() use ($model) {
        if ($model->isDirty('draft_mode') && !$model->isDraftStatus()) {
            traceLog('draft was published');
1 Like