<?php

namespace app\common\model\odd_job;

use think\Model;

class RensheCodeModel extends Model
{
    protected $connection = 'odd_job';

    //设置表名
    protected $name = 'renshe_code';

    /**
     * 根据类型获取列表
     */
    public static function getList($type)
    {
        return self::where('type', $type)->field('id,name,code')->select();
    }
}