After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 138368 - Altering resource assignments does not trigger save reminder
Altering resource assignments does not trigger save reminder
Status: RESOLVED FIXED
Product: planner
Classification: Other
Component: General
unspecified
Other Linux
: Normal normal
: 0.12
Assigned To: planner-maint
planner-maint
Depends on:
Blocks:
 
 
Reported: 2004-03-28 23:42 UTC by Malcolm Tredinnick
Modified: 2004-12-22 21:47 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
This tweaks libplanner/mrp-assignment.c and planner-task-dialog.c. (2.44 KB, patch)
2004-04-15 04:15 UTC, Lincoln Phipps
none Details | Review

Description Malcolm Tredinnick 2004-03-28 23:42:49 UTC
If I load in an existing project and alter a resource assignment (in this
particular case, I adjusted the load of one person from 50% to 35% on one task),
the "save" button and menu items do not become sensitive.
Comment 1 Lincoln Phipps 2004-03-29 02:35:07 UTC
Note the following diff works, though my own sandbox has other stuff
in planner-task-dialog.c so the actual lines will be offset. Around 
line 902 in task_dialog_resource_units_cell_edited() we need to insert,
		mrp_object_changed (MRP_OBJECT (resource));

Diff is thus...

Index: src/planner-task-dialog.c
===================================================================
RCS file: /cvs/gnome/planner/src/planner-task-dialog.c,v
retrieving revision 1.3
diff -u -B -b -p -r1.3 planner-task-dialog.c
--- src/planner-task-dialog.c	17 Mar 2004 19:28:12 -0000	1.3
+++ src/planner-task-dialog.c	29 Mar 2004 02:32:47 -0000
@@ -900,6 +957,7 @@ task_dialog_resource_units_cell_edited (
 		g_object_set (assignment,
 			      "units", atoi (new_text),
 			      NULL);
+		mrp_object_changed (MRP_OBJECT (resource));
 	}
 }
 

I think  the issue is that adding assignments and other big stuff 
eventually gets a changed message but editing this cell didn't.

Warning - none of the planner-task-dialog.c raises a undo/redo anyway
but at least with that change above the Save button gets activated.

Rgds,
Lincoln.
Comment 2 Richard Hult 2004-03-29 08:42:01 UTC
This isn't quite right, it should be done in libplanner/ somewhere.
Comment 3 Lincoln Phipps 2004-04-15 04:15:17 UTC
Created attachment 26676 [details] [review]
This tweaks libplanner/mrp-assignment.c and planner-task-dialog.c.

See the patch - it has the cludge to get over fact that object->priv->project
doesn't exist for assignments so calling mrp_object_changed with an assignment
as your object won't work expecially for setting units.
Comment 4 Richard Hult 2004-04-15 18:09:37 UTC
Committed a variant of this, thanks!

Closing this since it does't make a lot of sense to keep it open and the bug is
not very critical (in a real-fix way).