2017 © Pedro PelĆ”ez
 

yii2-extension yii2-validator

ValidaƧƵes de documentos do Brasil e Portugal

image

rafaelrabaco/yii2-validator

ValidaƧƵes de documentos do Brasil e Portugal

  • Friday, August 11, 2017
  • by rafaelrabaco
  • Repository
  • 1 Watchers
  • 0 Stars
  • 496 Installations
  • PHP
  • 0 Dependents
  • 0 Suggesters
  • 0 Forks
  • 0 Open issues
  • 3 Versions
  • 4 % Grown

The README.md

Yii 2 Validator

Yii2 Extension that provide validations and features for Brazilian and Portugal localization, (*1)

  • CPF: Cadastro de pessoa fĆ­sica (BR)
  • CNPJ: Cadastro nacional de pessoa jurĆ­dica (BR)
  • CEI: Cadastro especĆ­fico no INSS (BR)
  • NIF: NĆŗmero de identificaĆ§Ć£o fiscal (PT)

Yii2 CircleCI Minimum PHP Version Latest Stable Version Total Downloads, (*2)

Installation

The preferred way to install this extension is through composer., (*3)

Either run, (*4)

php composer.phar require --prefer-dist rafaelrabaco/yii2-validator "*"

or add, (*5)

"rafaelrabaco/yii2-validator": "*"

to the require section of your composer.json file., (*6)

Usage

Add the rules as the following example, (*7)


use Yii; use yii\base\Model; use rafaelrabaco\validator\CpfValidator; use rafaelrabaco\validator\CnpjValidator; use rafaelrabaco\validator\CeiValidator; use rafaelrabaco\validator\NifValidator; class PersonForm extends Model { public $name; public $cpf; public $cnpj; public $cei; public $nif; /** * @return array the validation rules. */ public function rules() { return [ // name is required ['name', 'required'], // cpf validator ['cpf', CpfValidator::className()], // cnpj validator ['cnpj', CnpjValidator::className()], // cei validator ['cei', CeiValidator::className()] // nif validator ['nif', NifValidator::className()] ]; } }

The Versions

11/08 2017

dev-master

9999999-dev

ValidaƧƵes de documentos do Brasil e Portugal

  Sources   Download

BSD-3-Clause

The Requires

 

The Development Requires

by Rafael RabaƧo

validator model yii brazil brasil cnpj cpf br portugal nif pt

11/08 2017

1.0.1

1.0.1.0

ValidaƧƵes de documentos do Brasil e Portugal

  Sources   Download

BSD-3-Clause

The Requires

 

The Development Requires

by Rafael RabaƧo

validator model yii brazil brasil cnpj cpf br portugal nif pt

11/08 2017

1.0.0

1.0.0.0

ValidaƧƵes de documentos do Brasil e Portugal

  Sources   Download

BSD-3-Clause

The Requires

 

The Development Requires

by Rafael RabaƧo

validator model yii brazil brasil cnpj cpf br portugal nif pt