$cp_source,'bid'=>$bid,'status'=>1]) ->where('start_date','<=',date('Y-m-d',strtotime('-1 day'))) ->where('end_date','>=',date('Y-m-d',strtotime('-1 day'))) ->first(); } public static function getAllCpBookCalculateBids() { return self::where(['status'=>1]) ->where('start_date','<=',date('Y-m-d',strtotime('-1 day'))) ->where('end_date','>=',date('Y-m-d',strtotime('-1 day'))) ->get() ->pluck('bid') ->all(); } }