2012-02-27 17:40:46 +00:00
|
|
|
.lineForm.fork
|
2012-03-07 21:34:49 +00:00
|
|
|
= select_tag :branch, branch_selector_options(project), :id => 'branch_selector', :class => 'sel80'
|
2012-03-21 19:55:14 +00:00
|
|
|
%form{:action => '', :method => :get, :id => 'branch_changer', :'data-action' => "#{controller_name}"}
|
2012-02-27 17:40:46 +00:00
|
|
|
.fork
|
2012-03-21 19:55:14 +00:00
|
|
|
%p #{t('layout.projects.current_branch')}:
|
2012-02-27 17:40:46 +00:00
|
|
|
.both
|
2012-02-29 01:30:22 +00:00
|
|
|
|
|
|
|
:javascript
|
|
|
|
$(document).ready(function() {
|
|
|
|
$('select#branch_selector').live('change', function(e) {
|
|
|
|
$form = $('form#branch_changer');
|
|
|
|
$form.attr('action', $(this).val());
|
|
|
|
$form.submit();
|
|
|
|
});
|
2012-03-21 19:55:14 +00:00
|
|
|
});
|