|
@ -40,6 +40,9 @@ class Supplier extends \yii\db\ActiveRecord |
|
|
[['is_delete'], 'integer'], |
|
|
[['is_delete'], 'integer'], |
|
|
[['name', 'full_name', 'address'], 'string', 'max' => 50], |
|
|
[['name', 'full_name', 'address'], 'string', 'max' => 50], |
|
|
[['phone'], 'string', 'max' => 20], |
|
|
[['phone'], 'string', 'max' => 20], |
|
|
|
|
|
['phone', 'filter', 'filter' => 'trim'], |
|
|
|
|
|
['phone','match','pattern'=>'/^[1][34578][0-9]{9}$/'], |
|
|
|
|
|
['phone', 'unique', 'targetClass' => '\antgoods\goods\models\ars\Supplier', 'message' => '手机号已被使用'], |
|
|
]; |
|
|
]; |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|