CGradeBook::GetList
CDBResult CGradeBook::GetList( array arOrder = Array("ID"=>"DESC"), array arFilter = Array() );
The GetList method returns a list of the grade book records filtered by arFilter and sorted in the arOrder order. The current user access permissions are respected.
Parameters
Parameter | Description |
---|---|
arOrder |
An array in the format array("filter field"=>"sort
order" [, ...]). The sorting field can have the following values:
|
arFilter |
An array in the format array("filtered
field"=>"filter value" [, ...]). The following
values are possible:
"filter values" is a single value or an array. Optional. By default, records are not filtered. |
Return Values
The method returns an instance of the CDBResult object.
See Also
Example
<? if (CModule::IncludeModule("learning")) { $TEST_ID = 45; $res = CGradebook::GetList( Array("ID" => "ASC"), Array("TEST_ID" => $TEST_ID) ); while ($arGradebook = $res->GetNext()) { echo "Student: ".$arGradebook["USER_NAME"]. "; Test name: ".$arGradebook["TEST_NAME"]. "; Completed: ".$arGradebook["COMPLETED"]."<br>"; } } ?>
<? if (CModule::IncludeModule("learning")) { $TEST_ID = 45; $STUDENT_ID = 3; $res = CGradebook::GetList( Array("ID" => "ASC"), Array("CHECK_PERMISSIONS" => "N", "TEST_ID" => $TEST_ID, "STUDENT_ID" => $STUDENT_ID) ); while ($arGradebook = $res->GetNext()) { echo "Student: ".$arGradebook["USER_NAME"]. "; Test name: ".$arGradebook["TEST_NAME"]. "; Completed: ".$arGradebook["COMPLETED"]."<br>"; } } ?>
© «Bitrix24», 2001-2024