Changeset - b4d9680cd164
[Not reviewed]
celery
0 3 0
Marcin Kuzminski - 15 years ago 2010-09-22 04:31:21
marcin@python-works.com
some code fixes templates+helpers new rfc date without tz, added timerproxy formatting
3 files changed with 3 insertions and 1 deletions:
0 comments (0 inline, 0 general)
pylons_app/lib/helpers.py
Show inline comments
 
@@ -322,12 +322,13 @@ email_or_none = lambda x: util.email(x) 
 
person = lambda x: _person(x)
 
hgdate = lambda  x: "%d %d" % x
 
isodate = lambda  x: util.datestr(x, '%Y-%m-%d %H:%M %1%2')
 
isodatesec = lambda  x: util.datestr(x, '%Y-%m-%d %H:%M:%S %1%2')
 
localdate = lambda  x: (x[0], util.makedate()[1])
 
rfc822date = lambda  x: util.datestr(x, "%a, %d %b %Y %H:%M:%S %1%2")
 
rfc822date_notz = lambda  x: util.datestr(x, "%a, %d %b %Y %H:%M:%S")
 
rfc3339date = lambda  x: util.datestr(x, "%Y-%m-%dT%H:%M:%S%1:%2")
 
time_ago = lambda x: util.datestr(_age(x), "%a, %d %b %Y %H:%M:%S %1%2")
 

	
 

	
 
#===============================================================================
 
# PERMS
pylons_app/lib/timerproxy.py
Show inline comments
 
@@ -18,12 +18,13 @@ def one_space_trim(s):
 
    
 
def format_sql(sql):
 
    sql = color_sql(sql)
 
    sql = sql.replace('\n', '')
 
    sql = one_space_trim(sql)
 
    sql = sql\
 
        .replace(',', ',\n\t')\
 
        .replace('SELECT', '\n\tSELECT \n\t')\
 
        .replace('UPDATE', '\n\tUPDATE \n\t')\
 
        .replace('DELETE', '\n\tDELETE \n\t')\
 
        .replace('FROM', '\n\tFROM')\
 
        .replace('ORDER BY', '\n\tORDER BY')\
 
        .replace('LIMIT', '\n\tLIMIT')\
pylons_app/templates/shortlog/shortlog_data.html
Show inline comments
 
@@ -10,13 +10,13 @@
 
		<th class="left">${_('tags')}</th>
 
		<th class="left">${_('links')}</th>
 
		
 
	</tr>
 
%for cnt,cs in enumerate(c.repo_changesets):
 
	<tr class="parity${cnt%2}">
 
		<td>${h.age(cs._ctx.date())}</td>
 
		<td>${h.age(cs._ctx.date())} - ${h.rfc822date_notz(cs._ctx.date())} </td>
 
		<td title="${cs.author}">${h.person(cs.author)}</td>
 
		<td>r${cs.revision}:${cs.raw_id}</td>
 
		<td>
 
			${h.link_to(h.truncate(cs.message,60),
 
			h.url('changeset_home',repo_name=c.repo_name,revision=cs._short),
 
			title=cs.message)}
0 comments (0 inline, 0 general)