定制 purplespider/silverstripe-basic-gallery-extension 二次开发

按需修改功能、优化性能、对接业务系统,提供一站式技术支持

邮箱:yvsm@zunyunkeji.com | QQ:316430983 | 微信:yvsm316

purplespider/silverstripe-basic-gallery-extension

最新稳定版本:5.0.0

Composer 安装命令:

composer require purplespider/silverstripe-basic-gallery-extension

包简介

Silverstripe CMS Image Gallery Extension

README 文档

README

Introduction

Add this extension to any page type, to get the following batch image upload interface in the CMS:

Screenshot

It allows images to be bulk uploaded, drag and drop reordering and inline caption adding.

Or use the following modules:

Maintainer Contact

Requirements

  • Silverstripe 6

v3 Upgrade Notes

Upgrading to v3 will break existing galleries due to a change to a polymorphic relation, to fix:

  1. Run dev/build
  2. Run /dev/tasks/upgrade-basic-galleries script.

Config

The Extension can be applied to any page type to enable the gallery functionality.

You can also customise the CMS tab that the gallery appears on, as well as the title of the gallery displayed in the CMS, and rename the main Content tab:

---
Name: custom-basic-gallery-extension
After: basic-gallery-extension
---
HomePage:
    extensions:
        - PurpleSpider\BasicGalleryExtension\PhotoGalleryExtension
    gallery-title: Image Gallery
    gallery-cms-tab: Main
    content-cms-tab: Top Content

Automatically Delete Image Files

To automatically delete image files when an image is deleted from a gallery:

---
Name: custom-basic-gallery-extension
After: basic-gallery-extension
---
PurpleSpider\BasicGalleryExtension\PhotoGalleryImage:
    ondelete_delete_image_files: true

This uses Delete Asset If Unused Extension to detect if the image is being used elsewhere on the site, and will only delete it if it isn't. There are caveats though, so check this module's readme, i.e. you might not want to use this on sites that have been upgraded from Silverstripe 3.

统计信息

  • 总下载量: 3.45k
  • 月度下载量: 0
  • 日度下载量: 0
  • 收藏数: 2
  • 点击次数: 1
  • 依赖项目数: 2
  • 推荐数: 0

GitHub 信息

  • Stars: 2
  • Watchers: 2
  • Forks: 2
  • 开发语言: PHP

其他信息

  • 授权协议: BSD-3-Clause
  • 更新时间: 2020-03-13