2017 © Pedro Peláez
 

yii2-extension yii2-widget

Commonly used widgets

image

buddysoft/yii2-widget

Commonly used widgets

  • JavaScript
  • 1 Dependents
  • 0 Suggesters
  • 1 Forks
  • 0 Open issues
  • 23 Versions
  • 1 % Grown

The README.md

常用组件,都封装在这里

controllers

从 v3.0.0 开始,移除 API 相关代码。, (*1)

generators

自定义 gii generators。, (*2)

  • search: 实现了为 model 创建 search model 的功能

使用方法:, (*3)

在 main-local.php 中按照以下内容修改:, (*4)

$config['modules']['gii'] = [
    'class' => 'yii\gii\Module',
    // 添加下面内容
    'allowedIPs' => ['127.0.0.1', '::1', '192.168.0.*', '192.168.178.20'],
    'generators' => [
        'search' => [
            'class' => 'buddysoft\widget\generators\search\Generator',
            'templates' => [
                'myCrud' => 'buddysoft\widget\generators\search\default',
            ]
        ]
    ]
];

migrations

继承了为 mdmsoft/yii2-admin 模块创建第一个默认用户的 migration,使用方式, (*5)

./yii migrate --migrationPath=@buddysoft/widget/migrations

BDAR 类

  • 自动处理 sid 字段
  • 根据配置参数自动处理 secretFields 和 exceptFields
    // 不需要返回给客户端的字段,所有 Model 通用
    'secretFields' => ['id', 'createdAt', 'updatedAt', 'accessToken'],
    // 在某些请求中,依然需要返回给客户端,但是存在于 secretFields 数组中的字段
    'exceptFields' => [
        [
            'routes' => ['site/login'], // 如果设置了 url rules 重定向,必须使用重定向后的路由
            'models' => ['User'],       // 需要排除特殊字段的 Model 类名字
            'fields' => ['accessToken'],// 需要排除的字段名字
        ],
        [
            'routes' => ['notice/index', 'notice/view', 'receipt/index', 'receipt/view'],
            'models' => ['Notice', 'Receipt'],
            'fields' => ['createdAt', 'updatedAt'],
        ],
    ],

The Versions

08/05 2018

dev-master

9999999-dev https://github.com/liuwanwei/yii2-widget

Commonly used widgets

  Sources   Download

MIT Apache Version 2.0

The Requires

 

07/05 2018
24/04 2018
05/01 2018
05/01 2018
15/09 2017
14/06 2017
02/06 2017
01/06 2017

v1.1.4

1.1.4.0 https://github.com/liuwanwei/yii2-widget

Commonly used widgets

  Sources   Download

Apache Version 2.0

The Requires

 

08/03 2017

v1.1.3

1.1.3.0 https://github.com/liuwanwei/yii2-widget

Commonly used widgets

  Sources   Download

Apache Version 2.0

The Requires

 

08/03 2017

v1.0.0

1.0.0.0 https://github.com/liuwanwei/yii2-widget

Commonly used widgets

  Sources   Download

Apache Version 2.0

The Requires

 

08/03 2017

v1.1.2

1.1.2.0 https://github.com/liuwanwei/yii2-widget

Commonly used widgets

  Sources   Download

Apache Version 2.0

The Requires

 

08/03 2017

v1.1.1

1.1.1.0 https://github.com/liuwanwei/yii2-widget

Commonly used widgets

  Sources   Download

Apache Version 2.0

The Requires

 

28/02 2017

v1.1.0

1.1.0.0 https://github.com/liuwanwei/yii2-widget

Commonly used widgets

  Sources   Download

Apache Version 2.0

The Requires

 

22/02 2017

v1.0.9

1.0.9.0 https://github.com/liuwanwei/yii2-widget

Commonly used widgets

  Sources   Download

Apache Version 2.0

The Requires

 

10/02 2017

v1.0.8

1.0.8.0 https://github.com/liuwanwei/yii2-widget

Commonly used widgets

  Sources   Download

Apache Version 2.0

The Requires

 

08/02 2017

v1.0.7

1.0.7.0 https://github.com/liuwanwei/yii2-widget

Commonly used widgets

  Sources   Download

Apache Version 2.0

The Requires

 

07/02 2017

v1.0.6

1.0.6.0 https://github.com/liuwanwei/yii2-widget

Commonly used widgets

  Sources   Download

Apache Version 2.0

The Requires

 

06/02 2017

v1.0.5

1.0.5.0 https://github.com/liuwanwei/yii2-widget

Commonly used widgets

  Sources   Download

Apache Version 2.0

The Requires

 

23/01 2017

v1.0.4

1.0.4.0 https://github.com/liuwanwei/yii2-widget

Commonly used widgets

  Sources   Download

Apache Version 2.0

The Requires

 

19/01 2017

v1.0.3

1.0.3.0 https://github.com/liuwanwei/yii2-widget

Commonly used widgets

  Sources   Download

Apache Version 2.0

The Requires

 

18/01 2017

v1.0.2

1.0.2.0 https://github.com/liuwanwei/yii2-widget

Commonly used widgets

  Sources   Download

Apache Version 2.0

The Requires

 

18/11 2016

v1.0.1

1.0.1.0 https://github.com/liuwanwei/yii2-widget

Commonly used widgets

  Sources   Download

Apache Version 2.0

The Requires