Changeset - 0ebec9b88d13
[Not reviewed]
default
0 1 0
Marcin Kuzminski - 15 years ago 2010-08-19 22:38:00
marcin@python-works.com
added jump to revision from file history.
1 file changed with 15 insertions and 3 deletions:
0 comments (0 inline, 0 general)
pylons_app/templates/files/files_source.html
Show inline comments
 
@@ -17,8 +17,9 @@
 
		<div>
 
		${h.form(h.url('files_diff_home',repo_name=c.repo_name,f_path=c.f_path),method='get')}
 
		${h.hidden('diff2',c.files_list.last_changeset._short)}
 
		${h.select('diff1','',c.file_history)}
 
		${h.submit('diff','diff',class_="ui-button ui-widget ui-state-default ui-corner-all")}
 
		${h.select('diff1',c.files_list.last_changeset._short,c.file_history)}
 
		${h.submit('diff','diff to revision',class_="ui-button ui-widget ui-state-default ui-corner-all")}
 
		${h.submit('show_rev','show at revision',class_="ui-button ui-widget ui-state-default ui-corner-all")}
 
		${h.end_form()}
 
		</div>
 
	</dd>
 
@@ -33,4 +34,15 @@
 
	<div class="code-body">
 
		${h.pygmentize(c.files_list,linenos=True,anchorlinenos=True,lineanchors='S',cssclass="code-highlight")}
 
	</div>
 
</div>
 
\ No newline at end of file
 
</div>
 

	
 
<script type="text/javascript">
 
YAHOO.util.Event.onDOMReady(function(){
 
    YAHOO.util.Event.addListener('show_rev','click',function(e){
 
    	YAHOO.util.Event.preventDefault(e);
 
        var cs = YAHOO.util.Dom.get('diff1').value;
 
        var url = "${h.url('files_home',repo_name=c.repo_name,revision='__CS__',f_path=c.f_path)}".replace('__CS__',cs);
 
        window.location = url;
 
        });
 
   });
 
</script>
 
\ No newline at end of file
0 comments (0 inline, 0 general)