Mercurial > public > mercurial-scm > hg-stable
diff mercurial/hgweb/webcommands.py @ 19396:afc23eddc324
hgweb: show current search query in the input field
author | Alexander Plavin <me@aplavin.ru> |
---|---|
date | Thu, 11 Jul 2013 17:01:54 +0400 |
parents | 7d2a7f8e9da4 |
children | 55b9d98a1ef4 |
line wrap: on
line diff
--- a/mercurial/hgweb/webcommands.py Sun Jul 14 17:23:07 2013 +0200 +++ b/mercurial/hgweb/webcommands.py Thu Jul 11 17:01:54 2013 +0400 @@ -185,11 +185,13 @@ def changelog(web, req, tmpl, shortlog=False): + query = '' if 'node' in req.form: ctx = webutil.changectx(web.repo, req) else: if 'rev' in req.form: - hi = req.form['rev'][0] + query = req.form['rev'][0] + hi = query else: hi = 'tip' try: @@ -256,7 +258,7 @@ entries=lambda **x: changelist(latestonly=False, **x), latestentry=lambda **x: changelist(latestonly=True, **x), archives=web.archivelist("tip"), revcount=revcount, - morevars=morevars, lessvars=lessvars) + morevars=morevars, lessvars=lessvars, query=query) def shortlog(web, req, tmpl): return changelog(web, req, tmpl, shortlog = True)