2017 © Pedro Peláez
 

cakephp-plugin entity-column-check

CakePHP EntityColumnCheck

image

satthi/entity-column-check

CakePHP EntityColumnCheck

  • Monday, February 20, 2017
  • by satthi
  • Repository
  • 1 Watchers
  • 0 Stars
  • 1,780 Installations
  • PHP
  • 0 Dependents
  • 0 Suggesters
  • 0 Forks
  • 0 Open issues
  • 6 Versions
  • 148 % Grown

The README.md

entity-column-check

Build Status Scrutinizer Code Quality, (*1)

このプラグインはCakePHP3のEntityにおいて, (*2)

  • プロパティに設定されているもの
  • DBのカラムに該当するもの
  • 特定の例外のカラム

以外のものがセットされている場合にExceptionを返すプラグインです, (*3)

インストール

composer.json, (*4)

{
    "require": {
        "satthi/entity-column-check": "*"
    }
}

composer install, (*5)

使い方

Entity, (*6)

<?php
namespace App\Model\Entity;

use Cake\ORM\Entity;
use EntityColumnCheck\Model\Entity\EntityColumnCheckTrait;

class Topic extends Entity
{
    // 追加項目
    use EntityColumnCheckTrait;
    protected $_accessible = [
        '*' => true,
        'id' => false
    ];
    // 例外として設定するカラム
    protected $entityColumnCheckAllowField = [
        'file',
        'img'
    ];

    //&getメソッドをoverride
    public function &get($property)
    {
        $value = parent::get($property);
        $this->getEntityColumnCheck($property);
        return $value;
    }
}

The Versions

20/02 2017

dev-master

9999999-dev https://github.com/satthi/entity-column-check

CakePHP EntityColumnCheck

  Sources   Download

MIT

The Requires

 

The Development Requires

by Satoru Hagiwara

file cakephp

20/02 2017

0.1.3

0.1.3.0 https://github.com/satthi/entity-column-check

CakePHP EntityColumnCheck

  Sources   Download

MIT

The Requires

 

The Development Requires

by Satoru Hagiwara

file cakephp

20/02 2017

dev-getter_check_fix

dev-getter_check_fix https://github.com/satthi/entity-column-check

CakePHP EntityColumnCheck

  Sources   Download

MIT

The Requires

 

The Development Requires

by Satoru Hagiwara

file cakephp

16/02 2017

0.1.2

0.1.2.0 https://github.com/satthi/entity-column-check

CakePHP EntityColumnCheck

  Sources   Download

MIT

The Requires

 

The Development Requires

by Satoru Hagiwara

file cakephp

01/02 2017

0.1.1

0.1.1.0 https://github.com/satthi/entity-column-check

CakePHP EntityColumnCheck

  Sources   Download

MIT

The Requires

 

The Development Requires

by Satoru Hagiwara

file cakephp

01/02 2017

0.1.0

0.1.0.0 https://github.com/satthi/entity-column-check

CakePHP EntityColumnCheck

  Sources   Download

MIT

The Requires

 

The Development Requires

by Satoru Hagiwara

file cakephp