<?php

namespace App\Models;
use Illuminate\Database\Eloquent\SoftDeletes;

class StudentConsult extends Base
{
    //表名声明
    protected $table = 'gz_student_consult';
    use SoftDeletes;

    //主键声明
    protected $primaryKey = 'id';
    protected $dates = ['deleted_at'];


    public function selectinfoForPaginate(array $where, $field = ["*"], $offset, $perPage )
    {
        return  StudentConsult::where($where)->orderBy('id', 'desc')->skip($offset)->take($perPage)->get($field)->toArray();
    }
    public function selectinfoForPaginateCount(array $where )
    {
        return  StudentConsult::where($where)->count();
    }





}
