weboftalent/page-with-image 问题修复 & 功能扩展

解决BUG、新增功能、兼容多环境部署,快速响应你的开发需求

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

weboftalent/page-with-image

Composer 安装命令:

composer require weboftalent/page-with-image

包简介

Same as a standard page but with the addition of a main image

README 文档

README

Build Status Scrutinizer Code Quality Code Coverage Build Status codecov.io

Latest Stable Version Latest Unstable Version Total Downloads License Monthly Downloads Daily Downloads

Dependency Status Reference Status

codecov.io

Maintainers

##Introduction

This module provides for rendering subpages as images of folders, which themselves can contain similar folders. Images can also be attached to third party module page types and rendered in the same way.

##Documentation

Provided Page Types

A PageWithImage is container within a PageWithImageFolder. Both are the same as a standard Page, but with the addition of a main image (MainImage field).

Extending Provided Page Types

One can simply extend PageWithImage adding whatever is needed for the subclass as appropriate.

class AnimalPage extends PageWithImage {
	private static $db = array('Name' => 'Varchar');
}

The above class AnimalPage will appear when right clicking on a PageWithImageFolder to add a new subpage.

Using the AddImageExtension

There are 2 configuration changes required for a Page type that does not already have an attached image.

  • Add the AddImageExtension
  • Allow the third party Page type be a child of PageWithImageFolder (otherwise you can't add it) To do this add a config file, say pagewithimage.yml in your own module or mysite/_config directory with YML as per the following:
---
Name: yoursitepagewithimage
After: pagewithimage
---
PageWithImageFolder:
  allowed_children:
    - PageWithImage
    - ThirdPartyPage
ThirdPartyPage:
  extensions:
    - AddImageExtension

Repeat for each ThirdPartyPage type that you would like to have an image.

##Requirements

  • SilverStripe 3.1

##TODO

  • Tests

统计信息

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

GitHub 信息

  • Stars: 0
  • Watchers: 1
  • Forks: 1
  • 开发语言: PHP

其他信息

  • 授权协议: BSD-3-Clause
  • 更新时间: 2016-01-19

承接程序开发

PHP开发

VUE

Vue开发

前端开发

小程序开发

公众号开发

系统定制

数据库设计

云部署

网站建设

安全加固