OctoberCMS How to Preview
I have a controller implements
Backend\Behaviors\ListController I'm able to update or delete selected records from the list (delete by clicking the delete button and update by double click), however, I can't find a way to add preview link to the list and I can't find that mentioned in the documentation. Maybe the answer is easy but I'm still missing it.
I'm able to preview any records if I enter the preview link manually in the URL bar. e.g.
I just want to add the above preview link next to each record in the list.
Thanks in advanced.
Based on the comments above, the only way to do it is by list partials:
You should define custom list column, quoting OctoberCMS documentation:
partial- renders a partial, the path
valuecan refer to a
partialview file otherwise the column name is used as the partial name. Inside the partial these variables are available:
$valueis the default cell value,
$recordis the model used for the cell and
$columnis the configured class object
content: type: partial path: ~/plugins/acme/blog/models/comments/_content_column.htm
- → October CMS Custom Mail Layout
- → How to register middlewares in OctoberCMS plugin?
- → How to add default value in drodown in october cms?
- → Redirect wrong url laravel 5.1
- → laravel blade templating error
- → Get environment value in controller
- → After copying Laravel from one PC to another it shows a strange error from helpers.php
- → Laravel 5.1 page authentication using routes
- → Trait 'IlluminateFoundationBusDispatchesJobs' not found
- → How to fix error while installing Laravel first time?
- → How to eager load and query a pivot table using Eloquent - Laravel 5
- → Any advantages of adding an id column to a pivot table in Laravel?
- → Laravel 5 Cashier Middleware Routing Error