Hi Mark,
congratulations on the awesome plugin.
I have an element repositioning problem, i use moodle Version 3.10 and
adaptable template. When i create a model and i use the reposition item
and save all, in the db the background save in the column posy the value
-12 and this value is application on all item before it's saved in
database.
i have half solved editing file ajax.php
// Loop through the data.
/foreach ($values as $value) {
$element = new stdClass();
$element->id = $value->id;
$element->posx = $value->posx;
$element->posy = $value->posy;
$DB->update_record('customcert_elements', $element);
}/
// HALF FIX Loop through the data.
foreach ($va
lues as $value) {
if($value->posy == -12){
$element = new stdClass();
$element->id = $value->id;
$element->posx = $value->posx;
$element->posy = $value->posy+12;
}
else {
$element = new stdClass();
$element->id = $value->id;
$element->posx = $value->posx;
$element->posy = $value->posy;
}
$DB->update_record('customcert_elements', $element);
}
but the problem it's not resolve because $value->posy it is not always -12.
do you have any suggestions?
could it be a bug?
tnx