123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566 |
- <?php
- namespace app\models;
- use Yii;
- /**
- * This is the model class for table "{{%url_rule}}".
- *
- * @property int $id ID
- * @property string $unique_no 唯一标识符
- * @property string $bak 备注
- * @property string $type 规则类型
- * @property int $is_html 生成HTML
- * @property string $from_rule URL规则
- * @property string $to_rule 请求处理方式
- * @property string $args 参数
- * @property string $example 示例
- * @property int $is_system 系统规则
- * @property int $list_order 排序
- */
- class UrlRule extends \app\common\models\EActiveRecord
- {
- /**
- * {@inheritdoc}
- */
- public static function tableName()
- {
- return '{{%url_rule}}';
- }
- /**
- * {@inheritdoc}
- */
- public function rules()
- {
- return [
- [['is_html', 'is_system', 'list_order'], 'integer'],
- [['from_rule', 'to_rule', 'example'], 'required'],
- [['unique_no', 'bak'], 'string', 'max' => 50],
- [['type'], 'string', 'max' => 20],
- [['from_rule', 'to_rule', 'args'], 'string', 'max' => 500],
- [['example'], 'string', 'max' => 255],
- ];
- }
- /**
- * {@inheritdoc}
- */
- public function attributeLabels()
- {
- return [
- 'id' => 'ID',
- 'unique_no' => '唯一标识符',
- 'bak' => '备注',
- 'type' => '规则类型',
- 'is_html' => '生成HTML',
- 'from_rule' => 'URL规则',
- 'to_rule' => '请求处理方式',
- 'args' => '参数',
- 'example' => '示例',
- 'is_system' => '系统规则',
- 'list_order' => '排序',
- ];
- }
- }
|