refactoring + remove unnecessary feature
This commit is contained in:
parent
2d577cae9d
commit
153f6cd86b
7 changed files with 36 additions and 50 deletions
|
@ -6,12 +6,10 @@
|
|||
|
||||
.left.prepend-1
|
||||
= form_tag project_commits_path(@project), :method => :get do
|
||||
= select_tag "tag", options_for_select(@project.tags, @branch), :onchange => "this.form.submit();", :class => "", :prompt => "Tags"
|
||||
= select_tag "tag", options_for_select(@project.tags, @tag), :onchange => "this.form.submit();", :class => "", :prompt => "Tags"
|
||||
= text_field_tag "ssh", @project.url_to_repo, :class => ["ssh_project_url", "one_click_select"]
|
||||
.clear
|
||||
- if params[:path]
|
||||
%h3{:style => "color:#555"} /#{params[:path]}
|
||||
%div{:id => dom_id(@project)}
|
||||
= render "commits"
|
||||
|
||||
- remember_refs
|
||||
|
|
|
@ -5,7 +5,7 @@
|
|||
|
||||
.left.prepend-1
|
||||
= form_tag tree_project_path(@project), :method => :get do
|
||||
= select_tag "tag", options_for_select(@project.tags, @branch), :onchange => "this.form.submit();", :class => "", :prompt => "Tags"
|
||||
= select_tag "tag", options_for_select(@project.tags, @tag), :onchange => "this.form.submit();", :class => "", :prompt => "Tags"
|
||||
= text_field_tag "ssh", @project.url_to_repo, :class => ["ssh_project_url","one_click_select"]
|
||||
.clear
|
||||
|
||||
|
@ -18,7 +18,7 @@
|
|||
- if part_path.empty?
|
||||
- part_path = part
|
||||
\/
|
||||
= link_to truncate(part, :length => 40), tree_file_project_path(@project, :path => part_path, :commit_id => @commit.try(:id)), :remote => :true
|
||||
= link_to truncate(part, :length => 40), tree_file_project_path(@project, :path => part_path, :commit_id => @commit.try(:id), :branch => @branch, :tag => @tag), :remote => :true
|
||||
#tree-content-holder
|
||||
- if tree.is_a?(Grit::Blob)
|
||||
= render :partial => "projects/tree_file", :locals => { :name => tree.name, :content => tree.data, :file => tree }
|
||||
|
@ -36,7 +36,7 @@
|
|||
%tr{ :class => "tree-item", :url => tree_file_project_path(@project, @commit.id, file) }
|
||||
%td.tree-item-file-name
|
||||
= image_tag "dir.png"
|
||||
= link_to "..", tree_file_project_path(@project, @commit.id, file), :remote => :true
|
||||
= link_to "..", tree_file_project_path(@project, @commit.id, file, :branch => @branch, :tag => @tag), :remote => :true
|
||||
%td
|
||||
%td
|
||||
|
||||
|
@ -45,9 +45,6 @@
|
|||
- contents.select{ |i| i.is_a?(Grit::Blob)}.each do |content|
|
||||
= render :partial => "projects/tree_item", :locals => { :content => content }
|
||||
|
||||
|
||||
- remember_refs
|
||||
|
||||
:javascript
|
||||
$(function(){
|
||||
$('select#branch').selectmenu({style:'popup', width:200});
|
||||
|
|
|
@ -7,7 +7,7 @@
|
|||
= image_tag "txt.png"
|
||||
- else
|
||||
= image_tag "dir.png"
|
||||
= link_to truncate(content.name, :length => 40), tree_file_project_path(@project, @commit.id, file), :remote => :true
|
||||
= link_to truncate(content.name, :length => 40), tree_file_project_path(@project, @commit.id, file, :branch => @branch, :tag => @tag), :remote => :true
|
||||
%td
|
||||
= time_ago_in_words(content_commit.committed_date)
|
||||
ago
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue