Merge branch 'master' into 349-anonymous_access
This commit is contained in:
commit
71e28cf3f3
|
@ -9,11 +9,11 @@ class PagesController < ApplicationController
|
||||||
|
|
||||||
def tour_inside
|
def tour_inside
|
||||||
@entries = case params[:id]
|
@entries = case params[:id]
|
||||||
when 'projects'
|
when 'builds'
|
||||||
%w(repo builds monitoring)
|
%w(repo builds monitoring)
|
||||||
when 'sources'
|
when 'sources'
|
||||||
%w(source history annotation edit)
|
%w(source history annotation edit)
|
||||||
when 'builds'
|
when 'projects'
|
||||||
%w(control git tracker)
|
%w(control git tracker)
|
||||||
end
|
end
|
||||||
render "pages/tour/tour-inside", :layout => 'tour'
|
render "pages/tour/tour-inside", :layout => 'tour'
|
||||||
|
|
|
@ -59,7 +59,7 @@ class Ability
|
||||||
can [:read, :archive], Project, :owner_type => 'Group', :owner_id => user.group_ids
|
can [:read, :archive], Project, :owner_type => 'Group', :owner_id => user.group_ids
|
||||||
can([:read, :membered], Project, read_relations_for('projects')) {|project| local_reader? project}
|
can([:read, :membered], Project, read_relations_for('projects')) {|project| local_reader? project}
|
||||||
can(:write, Project) {|project| local_writer? project} # for grack
|
can(:write, Project) {|project| local_writer? project} # for grack
|
||||||
can([:update, :sections, :manage_collaborators], Project) {|project| local_admin? project}
|
can([:update, :sections, :manage_collaborators, :autocomplete_maintainers], Project) {|project| local_admin? project}
|
||||||
can(:fork, Project) {|project| can? :read, project}
|
can(:fork, Project) {|project| can? :read, project}
|
||||||
can(:fork, Project) {|project| project.owner_type == 'Group' and can? :update, project.owner}
|
can(:fork, Project) {|project| project.owner_type == 'Group' and can? :update, project.owner}
|
||||||
can(:destroy, Project) {|project| owner? project}
|
can(:destroy, Project) {|project| owner? project}
|
||||||
|
|
Loading…
Reference in New Issue