diff --git a/app/assets/stylesheets/themes/blue2/linkboxes.css.scss b/app/assets/stylesheets/themes/blue2/linkboxes.css.scss index 1ebf7ec..ea57d92 100644 --- a/app/assets/stylesheets/themes/blue2/linkboxes.css.scss +++ b/app/assets/stylesheets/themes/blue2/linkboxes.css.scss @@ -78,46 +78,54 @@ ul.linklist li a i{ ul.linklist > li a.linkbox { border-radius: 0; - border: none; - border-color:white; + border: $box-border; +/* border-color:white;*/ padding-top: 7px; - margin-bottom:1px; - margin-top:1px; + margin-bottom:0px; + margin-top:0px; + +/* border-bottom: $box-border; + border-top: $box-border; +*/ + border-color:white; +/* border-bottom-color:white; */ } ul.linklist > li a.linkbox:hover { - border-bottom: $box-border; - + border: $box-border; border-top: $box-border; box-shadow: none; + border-color: black; background: #FCFCFC; - margin: 0; - margin-bottom:0px; +/* margin: 0; + margin-bottom:0px;*/ } -ul.linklist > li:first-child a.linkbox { margin-top:1px;} +ul.linklist > li:first-child a.linkbox {} -ul.linklist > li:last-child a.linkbox { margin-bottom:1px; +ul.linklist > li:last-child a.linkbox { } ul.linklist > li:first-child a.linkbox { border-top-left-radius:$box-border-radius; border-top-right-radius:$box-border-radius; - border-top:none; - +/* border-top:$box-border; */ + margin-top:0px; } ul.linklist > li:last-child a.linkbox { border-bottom-left-radius:$box-border-radius; border-bottom-right-radius:$box-border-radius; - border-bottom:none; +/* border-bottom:$box-border;*/ +margin-bottom:0px; } ul.linklist { border-radius: $box-border-radius; border: $box-border; +/* box-shadow: 0px 0px 1px 1px lightgray;*/ } diff --git a/app/controllers/users_controller.rb b/app/controllers/users_controller.rb index 1e73890..32d4474 100755 --- a/app/controllers/users_controller.rb +++ b/app/controllers/users_controller.rb @@ -1,8 +1,20 @@ class UsersController < ApplicationController def index + authorize!(:index,User) @users = User.all end + def show + @user=User.find(params[:id]) + authorize!(:show, @user) + + end + def set_preferred_theme + @user=User.find(params[:id]) + authorize!(:set_preferred_theme, @user) + redirect_to user_url + end def add_role + authorize!(:add_role, User) @user= User.find(params[:id]) if (params[:role]=="fetuser" && can?(:addfetuser,User)) @user.add_role(params[:role]) @@ -13,6 +25,8 @@ class UsersController < ApplicationController redirect_to users_url end def fb_set_default_publish_page + authorize!(:doadmin, User) + if Fetsite::Application.config.facebookconfig_enabled if params["page"].nil? || !(current_user.provider=="facebook") redirect_to intern_home_index_path @@ -27,6 +41,7 @@ class UsersController < ApplicationController end def all_update + authorize! :doadmin,User params[:users].each do |id,u| user=User.find(id) user.fetprofile = Fetprofile.find(u[:fetprofile_id].to_i) if u[:fetprofile_id].to_i>0 diff --git a/app/models/ability.rb b/app/models/ability.rb index 4a43e08..f10f098 100755 --- a/app/models/ability.rb +++ b/app/models/ability.rb @@ -152,6 +152,7 @@ end can :show, Neuigkeit, :cache_is_published=>true, :rubrik=>{:public=>true} if loggedin + can :show, :id => user.id end if( user.has_role?("fetuser") || user.has_role?("fetadmin")) @@ -169,6 +170,9 @@ end if user.has_role?("fetadmin") can :addfetuser, User can :addfetadmin, User + can :add_role, User + can :show, User + can :index, User can :edit, User can :manage, User end diff --git a/app/views/themes/blue2/fetprofiles/show.html.erb b/app/views/themes/blue2/fetprofiles/show.html.erb index 4036269..2d6f85f 100644 --- a/app/views/themes/blue2/fetprofiles/show.html.erb +++ b/app/views/themes/blue2/fetprofiles/show.html.erb @@ -67,7 +67,7 @@ end <% if can?(:edit, @fetprofile) %>
- + <%= link_to ff_icon("icon-pencil")+I18n.t('common.edit'), edit_fetprofile_path(@fetprofile) if can?(:edit, @fetprofile) %> <%= link_to fa_icon("trash")+I18n.t('common.delete'), fetprofile_path(@fetprofile),method: :delete, data: { confirm: "Are you sure?" } if can?(:delete, @fetprofile) %> diff --git a/app/views/users/index.html.erb b/app/views/users/index.html.erb index 30fc2c1..782ca37 100755 --- a/app/views/users/index.html.erb +++ b/app/views/users/index.html.erb @@ -33,7 +33,7 @@ <%= semantic_fields_for "users[#{user.id}]", user do |f|%> - <%= f.input :fetprofile ,:label=>false , :as=>:select , :collection=>Fetprofile.all %> + <%= f.input :fetprofile ,:label=>false , :as=>:select , :collection=>Fetprofile.order(:vorname,:nachname) %> <% end %>