cakephp 3如何在验证中包含组件

时间:2018-10-10 02:56:32

标签: validation cakephp components

在以下验证中,我想包括MasterComponent函数值。

验证

namespace App\Model\Validation;

use Cake\Validation\Validation;
use Cake\Validation\Validator;
class CustomValidation extends Validation
{

组件

namespace App\Controller\Component;

use Cake\Controller\Component;
use Cake\Controller\ComponentRegistry;

/**
 * Master component
 */
class MasterComponent extends Component {

先谢谢您

0 个答案:

没有答案