@ -59,7 +59,8 @@ switch ($att->pageparams->action) {
case att_preferences_page_params::ACTION_ADD:
$newacronym = optional_param('newacronym', null, PARAM_TEXT);
$newdescription = optional_param('newdescription', null, PARAM_TEXT);
$newgrade = optional_param('newgrade', 0, PARAM_INT);
$newgrade = optional_param('newgrade', 0, PARAM_RAW);
$newgrade = unformat_float($newgrade);
$att->add_status($newacronym, $newdescription, $newgrade);
if ($pageparams->statusset > $maxstatusset) {
@ -103,7 +104,10 @@ switch ($att->pageparams->action) {
case att_preferences_page_params::ACTION_SAVE:
$acronym = required_param_array('acronym', PARAM_MULTILANG);
$description = required_param_array('description', PARAM_MULTILANG);
$grade = required_param_array('grade', PARAM_INT);
$grade = required_param_array('grade', PARAM_RAW);
foreach ($grade as & $val) {
$val = unformat_float($val);
}
$statuses = $att->get_statuses(false);
foreach ($acronym as $id => $v) {