34 $this->dcl_obj_id = $dclTable->getCollectionObject()->getId();
86 return round($val[
"avg"], 1) .
" (" . $val[
"cnt"] .
")";
102 public function delete()
108 "DELETE FROM il_rating WHERE " .
109 "obj_id = " .
$ilDB->quote((
int) $this->getRecord()->getId(),
"integer") .
" AND " .
110 "obj_type = " .
$ilDB->quote(
"dcl_record",
"text") .
" AND " .
111 "sub_obj_id = " .
$ilDB->quote((
int) $this->
getField()->
getId(),
"integer") .
" AND " .
112 $ilDB->equals(
"sub_obj_type",
"dcl_field",
"text",
true)
115 $query2 =
"DELETE FROM il_dcl_record_field WHERE id = " .
$ilDB->quote($this->
getId(),
"integer");
116 $ilDB->manipulate($query2);
An exception for terminatinating execution or to throw for unit testing.
Confirmation screen class.
Class ilDclBaseFieldModel.
Class ilDclBaseFieldModel.
Class ilDclBaseRecordModel.
static getTableCache($table_id=0)
Class ilDclBaseFieldModel.
addHiddenItemsToConfirmation(ilConfirmationGUI &$confirmation)
setValue($value, $omit_parsing=false)
Set value for record field.
getExportValue()
return Export values
doRead()
Read object data from database.
__construct(ilDclBaseRecordModel $record, ilDclBaseFieldModel $field)
loadValue()
override the loadValue.
doUpdate()
Update object in database.
static getOverallRatingForObject($a_obj_id, $a_obj_type, $a_sub_obj_id=null, $a_sub_obj_type=null, $a_category_id=null)
Get overall rating for an object.
__construct(Container $dic, ilPlugin $plugin)
@inheritDoc