<?php


namespace app\admin\validate;


class CurrencyValidate extends BaseValidate
{

     /**
      * 设置校验规则
      * @var string[]
      */
    protected $rule = [
        'currency' => 'require',
        'short_currency' => 'require',
        'img' => 'require',
    ];

    /**
     * 参数描述
     * @var string[]
     */
    protected $field = [
        'currency' => '币种',
        'short_currency' => '短币种',
        'img' => '图标',
    ];

    /**
     * @notes 编辑场景
     */
    public function sceneEdit()
    {
        return $this->only(['id','currency', 'short_currency', 'img']);
    }

    public function sceneId()
    {
        return $this->only(['id']);
    }

}