|
15 | 15 | # BASIS, AND THERE IS NO OBLIGATION WHATSOEVER TO PROVIDE MAINTENANCE, |
16 | 16 | # SUPPORT, UPDATES, ENHANCEMENTS, OR MODIFICATIONS. |
17 | 17 | # |
18 | | -# $Id: cgi_client.py,v 1.98 2002-01-14 02:20:14 richard Exp $ |
| 18 | +# $Id: cgi_client.py,v 1.99 2002-01-16 03:02:42 richard Exp $ |
19 | 19 |
|
20 | 20 | __doc__ = """ |
21 | 21 | WWW request handler (also used in the stand-alone server). |
@@ -343,8 +343,16 @@ def _add_assignedto_to_nosy(self, props): |
343 | 343 | return |
344 | 344 | assignedto_id = props['assignedto'] |
345 | 345 | if not props.has_key('nosy'): |
346 | | - props['nosy'] = [assignedto_id] |
347 | | - elif assignedto_id not in props['nosy']: |
| 346 | + # load current nosy |
| 347 | + if self.nodeid: |
| 348 | + cl = self.db.classes[self.classname] |
| 349 | + l = cl.get(self.nodeid, 'nosy') |
| 350 | + if assignedto_id in l: |
| 351 | + return |
| 352 | + props['nosy'] = l |
| 353 | + else: |
| 354 | + props['nosy'] = [] |
| 355 | + if assignedto_id not in props['nosy']: |
348 | 356 | props['nosy'].append(assignedto_id) |
349 | 357 |
|
350 | 358 | def _changenode(self, props): |
@@ -1165,6 +1173,15 @@ def parsePropsFromForm(db, cl, form, nodeid=0): |
1165 | 1173 |
|
1166 | 1174 | # |
1167 | 1175 | # $Log: not supported by cvs2svn $ |
| 1176 | +# Revision 1.98 2002/01/14 02:20:14 richard |
| 1177 | +# . changed all config accesses so they access either the instance or the |
| 1178 | +# config attriubute on the db. This means that all config is obtained from |
| 1179 | +# instance_config instead of the mish-mash of classes. This will make |
| 1180 | +# switching to a ConfigParser setup easier too, I hope. |
| 1181 | +# |
| 1182 | +# At a minimum, this makes migration a _little_ easier (a lot easier in the |
| 1183 | +# 0.5.0 switch, I hope!) |
| 1184 | +# |
1168 | 1185 | # Revision 1.97 2002/01/11 23:22:29 richard |
1169 | 1186 | # . #502437 ] rogue reactor and unittest |
1170 | 1187 | # in short, the nosy reactor was modifying the nosy list. That code had |
|
0 commit comments