[Trac-tickets] [The Trac Project] #2839: require username,
comment when changing stuff
The Trac Project
noreply at edgewall.com
Mon Mar 6 05:56:14 CST 2006
#2839: require username, comment when changing stuff
------------------------------------+---------------------------------------
Reporter: joramagten at hotmail.com | Owner: jonas
Type: defect | Status: new
Priority: normal | Milestone:
Component: general | Version: 0.9.3
Severity: normal | Keywords: author comment
------------------------------------+---------------------------------------
when editing a wiki page, roadmap, timeline, ...
require an author and comment
this to force users to add comments when committing
I edited the function save in source:trunk/trac/wiki/model.py
{{{
def save(self, author, comment, remote_addr, t=None, db=None):
...
if t is None:
t = time.time()
if author == None or author == "" :
raise TracError('Author field is empty')
if comment == None or comment == "" :
raise TracError('Comment field is empty')
if self.text != self.old_text:
cursor = db.cursor()
...
}}}
also in source:/trunk/templates/wiki.cs " (optional)" should be removed
{{{
248 <div class="field">
249 <label>Comment about this change (optional):<br />
250 <input id="comment" type="text" name="comment" size="60"
value="<?cs
251 var:wiki.comment?>" /></label>
252 </div><br />
}}}
* maybe this should better be done with an option in the config file
* it might also be better to handle this in the POST processing of the
form and color the field RED?
--
Ticket URL: <http://projects.edgewall.com/trac/ticket/2839>
The Trac Project <http://trac.edgewall.com/>
More information about the Trac-Tickets
mailing list