Running 0.8.7i with Thold 0.4.9.
When we want to temporarily disable (not delete) certain thresholds, we disable them by clicking on the red button on the 'thold' tab.
When someone modifies the threshold template (perhaps changing an upper or lower limit), all of the disabled thresholds
become enabled again.
Is this the intended behavior?
Thank you,
Ross Kusler
Saving a thold template reactivates disabled tholds
Moderators: Developers, Moderators
Re: Saving a thold template reactivates disabled tholds
It seems so.
When saving a threshold template, its values (including "Enabled" field) will apply to all thresholds using the template.
If you want to avoid this behavior, try to modify 'thold/thold_functions.php'.
Please at your own risks.
When saving a threshold template, its values (including "Enabled" field) will apply to all thresholds using the template.
If you want to avoid this behavior, try to modify 'thold/thold_functions.php'.
Code: Select all
function thold_template_update_thresholds ($id) {
db_execute("UPDATE thold_data, thold_template
SET thold_data.thold_hi = thold_template.thold_hi,
...
thold_data.thold_enabled = thold_template.thold_enabled, <=== delete this line
...
WHERE thold_data.template=$id AND thold_data.template_enabled='on' AND thold_template.id=$id");
...
}
Re: Saving a thold template reactivates disabled tholds
Threshold Enabled is part of the template so everything is either enabled or disabled when the templated is changed. Edit the Threshold you disabled and uncheck the Template Propogation Enabled box. Changes to the template no longer affect the Threshold.
Wizzer
Wizzer
Who is online
Users browsing this forum: No registered users and 0 guests