Is there a way to export the url of a file in October to a database table? I currently have a model called "Image" that stores the url by doing the following:
public $attachOne = [
'image' => ['System\Models\File']
];
I'm storing other attributes in the model list (called columns.yaml) and in the database, I'd like to add the url here if possible?
columns:
id:
label: ID
type: number
name:
label: Name
type: text
searchable: true
sortable: true
Its relatively easy, you just need to add Accessor
In your modal add this Accessor
And in your modal's columns
Now it will show the image's path as a column and you can export its value.
if any doubt please comment.