master
cody 2 weeks ago
parent a7315e238c
commit a39f384489

@ -148,7 +148,7 @@ class CourseSign extends SoftDeletesModel
*/
public static function yhInvested($start_date = null, $end_date = null, $retList = false)
{
$courseSignByTypeQuery = self::getStudentList($start_date, $end_date, null, null);
$courseSignByTypeQuery = self::getStudentList($start_date, $end_date, 1, null);
$list = Company::whereHas('users', function ($query) use ($courseSignByTypeQuery) {
$query->whereIn('id', $courseSignByTypeQuery->get()->pluck('user_id'));
})->where('is_yh_invested', 1)->get();
@ -171,7 +171,7 @@ class CourseSign extends SoftDeletesModel
*/
public static function genban($start_date, $end_date, $course_ids = null, $retList = false)
{
$courseSignsQuery = self::getStudentList($start_date, $end_date, null, $course_ids);
$courseSignsQuery = self::getStudentList($start_date, $end_date, 1, $course_ids);
$courseSigns = $courseSignsQuery->whereHas('user', function ($query) {
$query->where('from', '跟班学员');
})->get();

Loading…
Cancel
Save