nassau/kunstmaan-node-settings-bundle 问题修复 & 功能扩展

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

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

nassau/kunstmaan-node-settings-bundle

Composer 安装命令:

composer require nassau/kunstmaan-node-settings-bundle

包简介

README 文档

README

Installation

Just composer require nassau/kunstmaan-node-settings-bundle and add \Nassau\KunstmaanNodeSettingsBundle\NodeSettingsBundle to your AppKernel file.

Usage

  1. Create an Entity to hold your settings (it’s best if it has relation to a NodeTranslation, but it’s up to you) and a FormType for it
  2. Create a SettingsHandler. To do this implement the \Nassau\KunstmaanNodeSettingsBundle\Services\NodeSettingsHandlerInterface interface and register that service in the container with a nassau.node_settings tag
  3. Your form type will automatically show up when editing the node, and the entity will be persisted on save. Et voilà!

Kitchen sink

The whole aim of this bundle is to be simple. So instead of creating everything from scratch, let’s use some existing boilerplate.

AbstractNodeSettingEntity

Use this class as a base for your entity so you’d have a nodeTranslation association defined out of the box.

AbstractNodeSettingsHandler

Extend this class to have a simpler handler. It will use defaults for most of the values and only require you to set:

  • The name of the entity class for your settings
  • The name of the form type class
  • And the name of the handler itself

The settings node will be automatically fetched and saved based on the current NodeTranslation.

Examples

Ok, so you still don’t get it and need a TL;DR or an example? Look at the examples

统计信息

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

GitHub 信息

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

其他信息

  • 授权协议: MIT
  • 更新时间: 2016-08-23

承接程序开发

PHP开发

VUE

Vue开发

前端开发

小程序开发

公众号开发

系统定制

数据库设计

云部署

网站建设

安全加固