daloradius
daloradius copied to clipboard
Not possible to update attributes - fix included
Hi,
mng-rad-profiles-edit.php line 243 resets the counter to keep the html fields unique. This results in a conflict and it is not possible to update the fields, if there are both a check and reply in the profile. Attribute number three in either check or reply, is editable.
Fix is to remove line 243 //$editCounter = 0; and let all fields get unique values, regardless if it is check or reply.
I have not checked if this error is present other places.
Thanks for the bug report and suggested fix @kimhaak. Simply removing the counter from the logic in the HTML fields is enough, though?
It seems to be used to create a unique array value:
$name = sprintf('editValues%s[]', $editCounter);
Can you confirm if removing the $editCounter
doesn't break anything?
@kimhaak , this isn't the correct way to fix it. However, I managed to find a solution on my own. Try cloning (or pulling) a more recent version of daloRADIUS.