Skip to content

Commit 7c0c38d

Browse files
author
Richard Jones
committed
Fixed some non-string node ids.
1 parent cdefe0d commit 7c0c38d

File tree

2 files changed

+19
-13
lines changed

2 files changed

+19
-13
lines changed

roundup/cgi_client.py

Lines changed: 12 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
# $Id: cgi_client.py,v 1.3 2001-07-23 03:56:30 richard Exp $
1+
# $Id: cgi_client.py,v 1.4 2001-07-28 00:34:34 richard Exp $
22

33
import os, cgi, pprint, StringIO, urlparse, re, traceback
44

@@ -278,7 +278,7 @@ def showitem(self, message=None):
278278

279279
# now create the message
280280
content = '\n'.join(m)
281-
message_id = self.db.msg.create(author=1, recipients=[],
281+
message_id = self.db.msg.create(author='1', recipients=[],
282282
date=date.Date('.'), summary=summary, content=content)
283283
messages = cl.get(nid, 'messages')
284284
messages.append(message_id)
@@ -324,13 +324,13 @@ def newissue(self, message=None):
324324
continue
325325
proptype = cl.properties[key]
326326
if proptype.isStringType:
327-
value = str(self.form[key].value).strip()
327+
value = self.form[key].value.strip()
328328
elif proptype.isDateType:
329-
value = date.Date(str(self.form[key].value))
329+
value = date.Date(self.form[key].value.strip())
330330
elif proptype.isIntervalType:
331-
value = date.Interval(str(self.form[key].value))
331+
value = date.Interval(self.form[key].value.strip())
332332
elif proptype.isLinkType:
333-
value = str(self.form[key].value).strip()
333+
value = self.form[key].value.strip()
334334
# handle key values
335335
link = cl.properties[key].classname
336336
if not num_re.match(value):
@@ -342,9 +342,9 @@ def newissue(self, message=None):
342342
elif proptype.isMultilinkType:
343343
value = self.form[key]
344344
if type(value) != type([]):
345-
value = [i.strip() for i in str(value.value).split(',')]
345+
value = [i.strip() for i in value.value.split(',')]
346346
else:
347-
value = [str(i.value).strip() for i in value]
347+
value = [i.value.strip() for i in value]
348348
link = cl.properties[key].classname
349349
l = []
350350
for entry in map(str, value):
@@ -402,7 +402,7 @@ def newissue(self, message=None):
402402

403403
# now create the message
404404
content = '\n'.join(m)
405-
message_id = self.db.msg.create(author=1, recipients=[],
405+
message_id = self.db.msg.create(author='1', recipients=[],
406406
date=date.Date('.'), summary=summary, content=content)
407407
messages = cl.get(nid, 'messages')
408408
messages.append(message_id)
@@ -489,6 +489,9 @@ def __del__(self):
489489

490490
#
491491
# $Log: not supported by cvs2svn $
492+
# Revision 1.3 2001/07/23 03:56:30 richard
493+
# oops, missed a config removal
494+
#
492495
# Revision 1.2 2001/07/22 12:09:32 richard
493496
# Final commit of Grande Splite
494497
#

roundup/mailgw.py

Lines changed: 7 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,7 @@
4444
an exception, the original message is bounced back to the sender with the
4545
explanatory message given in the exception.
4646
47-
$Id: mailgw.py,v 1.2 2001-07-22 12:09:32 richard Exp $
47+
$Id: mailgw.py,v 1.3 2001-07-28 00:34:34 richard Exp $
4848
'''
4949

5050

@@ -252,11 +252,11 @@ def handle_message(self, message):
252252
date=date.Date('.'), summary=summary, content=content,
253253
files=files)
254254
if not props.has_key('assignedto'):
255-
props['assignedto'] = 1 # "admin"
255+
props['assignedto'] = '1' # "admin"
256256
if not props.has_key('priority'):
257-
props['priority'] = 1 # "bug-fatal"
257+
props['priority'] = '1' # "bug-fatal"
258258
if not props.has_key('status'):
259-
props['status'] = 1 # "unread"
259+
props['status'] = '1' # "unread"
260260
if not props.has_key('title'):
261261
props['title'] = title
262262
props['messages'] = [message_id]
@@ -267,4 +267,7 @@ def handle_message(self, message):
267267

268268
#
269269
# $Log: not supported by cvs2svn $
270+
# Revision 1.2 2001/07/22 12:09:32 richard
271+
# Final commit of Grande Splite
272+
#
270273
#

0 commit comments

Comments
 (0)