menu
announcement

Spectrum is now read-only. Learn more about the decision in our official announcement.

Twill

Rapidly create a custom admin console that content publishers will love. Twill is an open source CMS toolkit for Laravel, crafted by AREA 17.

Channels
Team

Disabling draft option on create modal.

March 29, 2021 at 10:15pm

Disabling draft option on create modal.

March 29, 2021 at 10:15pm
Hello,
I want to disable Draft/Live toggle option on create model. I see that we can use withPublicationToggle option in form.blade.php definition but it doesn't work in create.blade.php.
I add it using below code:
('vuexStore') window['{{ config('arti.js_namespace') }}'].STORE.publication.withPublicationToggle = false
What is the best way to do it?
Thanks

March 30, 2021 at 10:12am
In your controller you can add: protected $indexOptions = [ 'publish' => false, ];
Edited

March 30, 2021 at 5:24pm
Didn't work. I still have draft option on create modal popup.
Try runningphp artisan view:clearto clear the view cache
Edited