summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: a3cc3b4)
raw | patch | inline | side by side (parent: a3cc3b4)
author | richard <richard@57a73879-2fb5-44c3-a270-3262357dd7e2> | |
Wed, 26 Feb 2003 04:08:04 +0000 (04:08 +0000) | ||
committer | richard <richard@57a73879-2fb5-44c3-a270-3262357dd7e2> | |
Wed, 26 Feb 2003 04:08:04 +0000 (04:08 +0000) |
editing.
git-svn-id: http://svn.roundup-tracker.org/svnroot/roundup/trunk@1545 57a73879-2fb5-44c3-a270-3262357dd7e2
git-svn-id: http://svn.roundup-tracker.org/svnroot/roundup/trunk@1545 57a73879-2fb5-44c3-a270-3262357dd7e2
TODO.txt | patch | blob | history | |
roundup/cgi/client.py | patch | blob | history | |
roundup/cgi/templating.py | patch | blob | history |
diff --git a/TODO.txt b/TODO.txt
index 3b995f2095a25682d9a43d5792810bff8e59930b..6f64a41107f5d0cdabe87d079642b1914fd65a39 100644 (file)
--- a/TODO.txt
+++ b/TODO.txt
pending mailgw Use in-reply-to for determining message lineage when subject
line lets us down
pending mailgw Allow different brackets delimiting [issueNNN] in Subject
+pending mailgw Have mailgw detect reply email with rego OTKs and complete
+ the rego.
pending email email sig could use a "remove me from this list"
<URL>/<designator>?:remove:nosy=me
pending project switch to a Roundup instance for Roundup bug/feature tracking
diff --git a/roundup/cgi/client.py b/roundup/cgi/client.py
index 435f7334947f37ed4e56ef5b651d5660864e20e2..10848f0808401e582e5d5814490bff6e235922d7 100644 (file)
--- a/roundup/cgi/client.py
+++ b/roundup/cgi/client.py
-# $Id: client.py,v 1.97 2003-02-25 10:19:32 richard Exp $
+# $Id: client.py,v 1.98 2003-02-26 04:08:04 richard Exp $
__doc__ = """
WWW request handler (also used in the stand-alone server).
# these are the actions that are available
actions = (
('edit', 'editItemAction'),
- ('editCSV', 'editCSVAction'),
+ ('editcsv', 'editCSVAction'),
('new', 'newItemAction'),
('register', 'registerAction'),
('confrego', 'confRegoAction'),
identifies the method on this object to call. The four basic
actions are defined in the "actions" sequence on this class:
"edit" -> self.editItemAction
+ "editcsv" -> self.editCSVAction
"new" -> self.newItemAction
"register" -> self.registerAction
"confrego" -> self.confRegoAction
index dff1bbcbe405b5cdb409b5e20ddc7d88918a0756..288b6f6e37ed6feafdb9b09b98b4a27bbb92bfdd 100644 (file)
self._prop = prop
self._value = value
self._anonymous = anonymous
+ self._name = name
if not anonymous:
- self._name = '%s%s@%s'%(classname, nodeid, name)
+ self._formname = '%s%s@%s'%(classname, nodeid, name)
else:
- self._name = name
+ self._formname = name
def __repr__(self):
- return '<HTMLProperty(0x%x) %s %r %r>'%(id(self), self._name,
+ return '<HTMLProperty(0x%x) %s %r %r>'%(id(self), self._formname,
self._prop, self._value)
def __str__(self):
return self.plain()
else:
value = cgi.escape(str(self._value))
value = '"'.join(value.split('"'))
- return '<input name="%s" value="%s" size="%s">'%(self._name, value, size)
+ return '<input name="%s" value="%s" size="%s">'%(self._formname, value, size)
def multiline(self, escape=0, rows=5, cols=40):
''' Render a multiline form edit field for the property
value = cgi.escape(str(self._value))
value = '"'.join(value.split('"'))
return '<textarea name="%s" rows="%s" cols="%s">%s</textarea>'%(
- self._name, rows, cols, value)
+ self._formname, rows, cols, value)
def email(self, escape=1):
''' Render the value of the property as an obscured email address
def field(self, size = 30):
''' Render a form edit field for the property.
'''
- return '<input type="password" name="%s" size="%s">'%(self._name, size)
+ return '<input type="password" name="%s" size="%s">'%(self._formname, size)
def confirm(self, size = 30):
''' Render a second form edit field for the property, used for
a field with name ":confirm:name".
'''
return '<input type="password" name=":confirm:%s" size="%s">'%(
- self._name, size)
+ self._formname, size)
class NumberHTMLProperty(HTMLProperty):
def plain(self):
else:
value = cgi.escape(str(self._value))
value = '"'.join(value.split('"'))
- return '<input name="%s" value="%s" size="%s">'%(self._name, value, size)
+ return '<input name="%s" value="%s" size="%s">'%(self._formname, value, size)
class BooleanHTMLProperty(HTMLProperty):
def plain(self):
''' Render a form edit field for the property
'''
checked = self._value and "checked" or ""
- s = '<input type="radio" name="%s" value="yes" %s>Yes'%(self._name,
+ s = '<input type="radio" name="%s" value="yes" %s>Yes'%(self._formname,
checked)
if checked:
checked = ""
else:
checked = "checked"
- s += '<input type="radio" name="%s" value="no" %s>No'%(self._name,
+ s += '<input type="radio" name="%s" value="no" %s>No'%(self._formname,
checked)
return s
DateHTMLProperty.
'''
return DateHTMLProperty(self._client, self._nodeid, self._prop,
- self._name, date.Date('.'))
+ self._formname, date.Date('.'))
def field(self, size = 30):
''' Render a form edit field for the property
else:
value = cgi.escape(str(self._value.local(self._db.getUserTimezone())))
value = '"'.join(value.split('"'))
- return '<input name="%s" value="%s" size="%s">'%(self._name, value, size)
+ return '<input name="%s" value="%s" size="%s">'%(self._formname, value, size)
def reldate(self, pretty=1):
''' Render the interval between the date and now.
''' Return the date/time as a local (timezone offset) date/time.
'''
return DateHTMLProperty(self._client, self._nodeid, self._prop,
- self._name, self._value.local(offset))
+ self._formname, self._value.local(offset))
class IntervalHTMLProperty(HTMLProperty):
def plain(self):
else:
value = cgi.escape(str(self._value))
value = '"'.join(value.split('"'))
- return '<input name="%s" value="%s" size="%s">'%(self._name, value, size)
+ return '<input name="%s" value="%s" size="%s">'%(self._formname, value, size)
class LinkHTMLProperty(HTMLProperty):
''' Link HTMLProperty
sort_on = linkcl.labelprop()
options = linkcl.filter(None, {}, ('+', sort_on), (None, None))
# TODO: make this a field display, not a menu one!
- l = ['<select name="%s">'%self._name]
+ l = ['<select name="%s">'%self._formname]
k = linkcl.labelprop(1)
if self._value is None:
s = 'selected '
sortfunc = make_sort_function(self._db, self._prop.classname)
linkcl = self._db.getclass(self._prop.classname)
- l = ['<select name="%s">'%self._name]
+ l = ['<select name="%s">'%self._formname]
k = linkcl.labelprop(1)
s = ''
if value is None:
k = linkcl.labelprop(1)
value = [linkcl.get(v, k) for v in value]
value = cgi.escape(','.join(value))
- return '<input name="%s" size="%s" value="%s">'%(self._name, size, value)
+ return '<input name="%s" size="%s" value="%s">'%(self._formname, size, value)
def menu(self, size=None, height=None, showid=0, additional=[],
**conditions):
sort_on = ('+', linkcl.labelprop())
options = linkcl.filter(None, conditions, sort_on, (None,None))
height = height or min(len(options), 7)
- l = ['<select multiple name="%s" size="%s">'%(self._name, height)]
+ l = ['<select multiple name="%s" size="%s">'%(self._formname, height)]
k = linkcl.labelprop(1)
# make sure we list the current values if they're retired