Bug 798760 - SLR change reminder with value entry

If the scheduled transaction state is 'Reminder' and also requires
values which have been entered but the state has not been changed to
'To Create' the values are lost when OK button pressed.

This change adds a check of state to the 'variable_value_changed_cb'
and if 'Reminder' changes it to 'To Create'.
This commit is contained in:
Robert Fewell 2023-11-15 16:01:06 +00:00
parent 5b8d29a7d0
commit 78ab605e91

View File

@ -957,6 +957,12 @@ variable_value_changed_cb (GtkCellRendererText *cell,
g_free (value_copy);
return;
}
if (inst->state == SX_INSTANCE_STATE_REMINDER)
{
gnc_sx_instance_model_change_instance_state (dialog->editing_model->instances, inst,
SX_INSTANCE_STATE_TO_CREATE);
}
gnc_sx_instance_model_set_variable (dialog->editing_model->instances, inst, var, &parsed_num);
}