Mosaic listing, drag and drop upload and more for EasyAdminBundle
- Mosaic / mason listing
- Drag and drop file upload and create records
composer require funcphp/easyadmin-gallery "dev-master"
$bundles = [
...
new Func\EasyAdminGalleryBundle\FuncEasyAdminGalleryBundle(),
...
];
php bin/console assets:install --symlink
set your gallery entitiy controller as Func\EasyAdminGalleryBundle\Controller\GalleryController
easy_admin:
entities:
Gallery:
class: AppBundle\Entity\Gallery # an entity
controller: Func\EasyAdminGalleryBundle\Controller\GalleryController
list:
fields:
# thumbnail field
-
property: 'image'
type: 'image'
base_path: '%path.gallery%'
thumbnail: true ##
# thumbnail text field
-
property: 'title'
thumbnail_text: true ##
# other fields
- 'id'
- 'enabled'
...
...
...
...
...
...
ready to mosaic listing.
easy_admin:
entities:
Gallery:
class: AppBundle\Entity\Gallery # an entity
controller: Func\EasyAdminGalleryBundle\Controller\GalleryController
dragDrop:
#backend values
values:
#column: "value"
imageFile: "%%file%%"
title: "%%file.name%%"
enabled: true
description: "This record created by drag'n drop!"
#frontend values
fields:
#form fields to overwrite values
- 'enabled'
- 'description'
list:
fields:
...
form:
fields:
...
...
...
...
...
...
ready to drag and drop uploading.
- custom list action: mosaic / mason listing
- custom list action: drag and drop file upload and create records
- custom show action: gallery viewing - prev / curr / next
- custom edit action: drag and drop