本文整理汇总了PHP中DashboardController::subjectList方法的典型用法代码示例。如果您正苦于以下问题:PHP DashboardController::subjectList方法的具体用法?PHP DashboardController::subjectList怎么用?PHP DashboardController::subjectList使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类DashboardController
的用法示例。
在下文中一共展示了DashboardController::subjectList方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: fetch
function fetch($id)
{
$istook = onlineExamsGrades::where('examId', $id)->where('studentId', $this->data['users']->id)->count();
$onlineExams = onlineExams::where('id', $id)->first()->toArray();
$onlineExams['examClass'] = json_decode($onlineExams['examClass']);
$onlineExams['examQuestion'] = json_decode($onlineExams['examQuestion']);
if (time() > $onlineExams['ExamEndDate'] || time() < $onlineExams['examDate']) {
$onlineExams['finished'] = true;
}
if ($istook > 0) {
$onlineExams['taken'] = true;
}
$onlineExams['examDate'] = date("m/d/Y", $onlineExams['examDate']);
$onlineExams['ExamEndDate'] = date("m/d/Y", $onlineExams['ExamEndDate']);
$DashboardController = new DashboardController();
$onlineExams['subject'] = $DashboardController->subjectList($onlineExams['examClass']);
return $onlineExams;
}
示例2: fetch
function fetch($id)
{
$toReturn = assignments::where('id', $id)->first();
$DashboardController = new DashboardController();
$toReturn['subject'] = $DashboardController->subjectList(json_decode($toReturn->classId, true));
return $toReturn;
}