Skip to content

Commit

Permalink
remove validators && update README.md
Browse files Browse the repository at this point in the history
  • Loading branch information
forecho committed May 29, 2018
1 parent 092a593 commit 3d586c5
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 124 deletions.
30 changes: 8 additions & 22 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -45,30 +45,16 @@ if (!ModelHelper::saveAll(Post::tableName(), $rows)) {
}
```

**中国身份证号码验证**
**Global Functions**

```php
public function rules()
{
return [
// ...
['id_card', '\yiier\helpers\validators\IdCardValidator'],
// code
];
}
```

**Array Validator**
change `composer.json` file, add this:

```php
public function rules()
{
return [
// ...
['product_ids', '\yiier\helpers\validators\ArrayValidator'],
// code
];
}
```
"autoload": {
"files": [
"vendor/yiier/yii2-helpers/GlobalFunctions.php"
]
},
```

……
20 changes: 0 additions & 20 deletions validators/ArrayValidator.php

This file was deleted.

82 changes: 0 additions & 82 deletions validators/IdCardValidator.php

This file was deleted.

0 comments on commit 3d586c5

Please sign in to comment.