Skip to content

Instantly share code, notes, and snippets.

Revisions

  1. webbash created this gist Jan 30, 2020.
    7 changes: 7 additions & 0 deletions Laravel Nova Action - conflict between canSee and canRun
    Original file line number Diff line number Diff line change
    @@ -0,0 +1,7 @@
    (new ActionName())
    ->canSee(function () {
    return ! $this->resource->exists || ($this->field === 'some') === true;
    })
    ->canRun(function () {
    return true;
    }),