ish_manager 0.1.8.206 → 0.1.8.207

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 0fd1be840fd507f350cfc75d8c4c267709e94f31a5f41d251a543565e7a67bcf
4
- data.tar.gz: b96ab99b2937d56799cd4c7e3de1dfacc823b0aaab961d4fab85667e32bd0406
3
+ metadata.gz: 1af4799b090fc634e74b7605e890cdb48c5943eefda72c678a1776d69a0ba0c8
4
+ data.tar.gz: 2fafcf153b594790bccc35deea8306c593928087d3d886a3ee69dc625eba6d15
5
5
  SHA512:
6
- metadata.gz: db6068530e44db76e82ac301f5a14e8cec2c8e42beebdf9d3a9175485448af4b25775029f380fce5cc3bb7035146c4aa7fdee674ae42d0e6398ec049d85d9dca
7
- data.tar.gz: 86c4f0ea86fdd93c63f0efc2b412c9e2301db9807299e1f43a83f85c01b51945492fc1c9b4df8927b52b58f57cad8ba644d035c45451ea2d9de2de60c96314c6
6
+ metadata.gz: abd3153488ee26001cf517dc150f5e97935d4478f694fc0884fb08ece79b8b25ac97a52d2e53c7bb654a20fc24247a9d6460265dd7107780cdf1738ae45068ec
7
+ data.tar.gz: ddf55012e848280194221981aa739274133f7e92529ebde2d32c67bbd9d9ee290b4d3222663519f81e9a5325a2e3306235cb26f023a74893de984effbb20b3ef
@@ -3,7 +3,7 @@ class IshManager::CitiesController < IshManager::ApplicationController
3
3
  before_action :sett_city, :only => [ :show, :edit ]
4
4
 
5
5
  def index
6
- authorize! :cities_index, Manager
6
+ authorize! :index, City
7
7
  @cities = City.all
8
8
  @city = City.new
9
9
  @photo = Photo.new
@@ -60,7 +60,7 @@ class IshManager::CitiesController < IshManager::ApplicationController
60
60
  end
61
61
 
62
62
  def change_profile_pic
63
- authorize! :change_profile_pic, City
63
+ authorize! :update, City
64
64
  @city = City.find params[:id]
65
65
  @photo = Photo.new params[:photo]
66
66
  @photo.user = @current_user
@@ -18,18 +18,17 @@ class IshManager::Ability
18
18
 
19
19
  can [ :home ], ::IshManager::Ability
20
20
 
21
- can [ :friends_index, :friends_new ], ::IshModels::UserProfile
22
-
23
21
  #
24
- # role admin, manager
22
+ # role admin
25
23
  #
26
- if user.profile && [ :admin, :manager ].include?( user.profile.role_name )
24
+ if user.profile && [ :admin ].include?( user.profile.role_name )
27
25
 
28
26
  can [ :create_newsitem, :show, :new_feature, :create_feature,
29
27
  :index, :new, :create, :edit, :update ], City
30
28
  can [ :manage ], ::CoTailors
31
29
 
32
30
  can [ :new ], ::Feature
31
+ can [ :friends_index, :friends_new ], ::IshModels::UserProfile
33
32
 
34
33
  can [ :index, :new, :create, :create_photo ], ::Gallery
35
34
  can [ :edit, :update ], ::Gallery do |g|
@@ -59,6 +58,15 @@ class IshManager::Ability
59
58
 
60
59
  end
61
60
 
61
+ #
62
+ # role manager
63
+ #
64
+ if user.profile && :manager == user.profile.role_name
65
+ can [ :create_newsitem, :show, :new_feature, :create_feature,
66
+ :index, :new, :create, :edit, :update ], City
67
+ end
68
+
69
+
62
70
  #
63
71
  # role guy (and manager)
64
72
  #
@@ -72,9 +80,9 @@ class IshManager::Ability
72
80
  gallery.shared_profiles.include? user.profile
73
81
  end
74
82
 
75
- can [ :index ], ::Report
83
+ # can [ :index ], ::Report
76
84
 
77
- can [ :index ], ::Video
85
+ # can [ :index ], ::Video
78
86
 
79
87
  end
80
88
 
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: ish_manager
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.8.206
4
+ version: 0.1.8.207
5
5
  platform: ruby
6
6
  authors:
7
7
  - piousbox