定制 buibr/yii2-dynamic-settings 二次开发

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

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

buibr/yii2-dynamic-settings

Composer 安装命令:

composer require buibr/yii2-dynamic-settings

包简介

Dynamic setting management with database table.

README 文档

README

Description

Dynamic setting management with database table.

Installation

composer require buibr/yii2-dynamic-settings

yii migrate --migrationPath=vendor/buibr/yii2-dynamic-settings/migrations/

Usage

Extend settings with new clase.

class Crm extends \buibr\yii2settings\Settings
{
    /**
     * Set the group of settings.
     */
    public static function group()
    {
        return "crm";
    }

    /**
     * The default setting for begining on new installation.
     */
    public static function defaults()
    {
        return [
            [
                'name'      =>'default_vat',
                'value'     => 0,  
                'text'      => 'What is the autoselected VAT ',
                'type'      => self::TYPE_SELECT,
                'source'    => self::SOURCE_CLASS,
                'source_data' => '\app\models\VatGroups'
            ],
            [
                'name'      => 'invoicing_date',
                'value'     => 3,  
                'text'      => 'In which day of the month we will generate invoices for clients.',
                'type'      => self::TYPE_TEXT,
            ],
        ];
    }
}

call like:


foreach(Crm::all() as $sett) {
    $sett->render();
}

统计信息

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

GitHub 信息

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

其他信息

  • 授权协议: MIT
  • 更新时间: 2019-09-03

承接程序开发

PHP开发

VUE

Vue开发

前端开发

小程序开发

公众号开发

系统定制

数据库设计

云部署

网站建设

安全加固