FOGProject / fogproject

An open source computer cloning & management system
https://fogproject.org
GNU General Public License v3.0
1.1k stars 221 forks source link

TaskTypeEdit plugin, damages records in the database and more #499

Closed Pieshka closed 1 year ago

Pieshka commented 1 year ago

I have the TaskTypeEdit plugin running at my site, which I use to edit existing task types. I have noticed two problems with its operation.

Firstly, when editing or adding a task, there is a problem with the Is Advanced option. If it is checked then normally in the database the ttIsAdvanced attribute for the task type, is set to '1' and the task normally displays in the advanced task list. But when this field is unchecked, instead of "0" in the database, nothing is assigned to the ttIsAdvanced attribute so that it does not display anywhere at all. I have to manually edit the database and set this attribute to "0".

The second problem is the operation of the form itself when editing the task type. Well, when I select to edit a task type, the values of the Kernel Args field and the status of the Is Advanced field do not load (even if Is Advanced has been selected).

It would be good if this was fixed, as it's a bit inconvenient to have to remember the kernel arguments all the time when editing, as well as editing the database manually.

My configuration: FOG 1.5.9.193 PHP 8 Fedora 36

Sebastian-Roth commented 1 year ago

I can imagine this being a PHP 8 issue. Do you see any warnings, errors or exceptions in the Apache or PHP-FPM logs?

It's hard enough to maintain the FOG core code and plugins do get even less attention. But I will try to look into this and see if I can fix this plugin.

Pieshka commented 1 year ago

The strange thing is that PHP does not return any errors. And there are none in the Apache logs either.

Sebastian-Roth commented 1 year ago

@Piotr86PL Found and fixed in FOG 1.5.9.204 (latest dev-branch).