vigilante 1.0.11 → 1.0.12

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 35ad7c54344e89c133b279637c5c06041ab33863
4
- data.tar.gz: 3e65f24a5a0c3591f78dd204fbe4c5574e07ad9d
3
+ metadata.gz: f3f96733ce7e408ff0b4898584a59e02e9de3c34
4
+ data.tar.gz: efc94e4ef4df468d844279310de3ce068197bea3
5
5
  SHA512:
6
- metadata.gz: e45a7ef2a169fe1f47f60187ee99aee9e1b16631d1c85664e830ce58c18a1e4b703f539005ba960b60c1fdbf6be9e6ba75c6d2d113ba36d9fde11d57024a1795
7
- data.tar.gz: 09855fc6392470a889b1abe7e055b704110c36551656e6caf48536304f1023339a1e2dc3a229cf9b5f1b27d5d5734aa457173353631891d989548a2c9a1fd7c0
6
+ metadata.gz: 7e541628b696d2f01b60a65e260dbbd20c04c7c9e0dea12289d62aeda67862d786b4d123701384a154d080d69ddcb17be09999f45a9c6aecd7ce9dd34ad30ff2
7
+ data.tar.gz: 2879a5834be6ba0727cf07620651eab855d93d49d06991d032a09a779414d651e429f3256616451e24977f3119b8446dc69ea9e22412a31ceaebf40bdf4971a6
data/VERSION CHANGED
@@ -1 +1 @@
1
- 1.0.11
1
+ 1.0.12
@@ -1,10 +1,10 @@
1
1
  .nested-fields.ability-permission-fields
2
2
 
3
- .row-fluid
4
- .span4
3
+ .row
4
+ .col-sm-6
5
5
  #permission_from_list
6
- = f.association :permission, :collection => Permission.all(:order => 'allowed_action'), :prompt => 'Choose an existing permission', :label_method => :allowed_action
7
- .span4
6
+ = f.association :permission, :collection => Permission.order(:allowed_action), :prompt => 'Choose an existing permission', :label_method => :allowed_action
7
+ .col-sm-6
8
8
  #actions-on-permission{:style => 'line-height: 20px; margin-top: 5px;'}
9
9
  - if f.object.new_record?
10
10
  = link_to_add_association 'or create a new permission', f, :permission
@@ -1,74 +1,74 @@
1
1
 
2
- .span6
3
- %table.table
4
- %tr
5
- %th Name
6
- %td= @ability.name
7
- %tr
8
- %th Description
9
- %td= @ability.description
2
+ %table.table
3
+ %tr
4
+ %th Name
5
+ %td= @ability.name
6
+ %tr
7
+ %th Description
8
+ %td= @ability.description
10
9
 
10
+ .row
11
+ .col-sm-8
12
+ %h2 Allowed actions
11
13
 
12
- %h2 Allowed actions
14
+ %table.table
15
+ - @ability.permissions.each do |perm|
16
+ %tr
17
+ %td= perm.allowed_action
13
18
 
14
- %table.table
15
- - @ability.permissions.each do |perm|
16
- %tr
17
- %td= perm.allowed_action
19
+ = link_to 'Edit', edit_ability_path(@ability), :class => 'btn btn-mini' if is_allowed_to?(@ability, :edit)
18
20
 
19
- = link_to 'Edit', edit_ability_path(@ability), :class => 'btn btn-mini' if is_allowed_to?(@ability, :edit)
21
+ .col-sm-4
22
+ #abilities_explanation.help_text.well.small.text-muted
23
+ %p
24
+ Allowed actions are specified as follows:
20
25
 
21
- .span4
22
- #abilities_explanation.help_text.well
23
- %p
24
- Allowed actions are specified as follows:
25
-
26
- %ul
27
- %li
28
- %pre
29
- posts[index, show]
30
- %ul
31
- %li
32
- Only the things that are explicitly specified are allowed.
33
- This declares that on the
34
- %tt
35
- PostsController
36
- only
37
- %tt
38
- index
39
- and
40
- %tt
41
- show
42
- are allowed.
43
- %li
44
- %pre
45
- *[index, show, report]
46
- %ul
47
- %li
48
- We also allow wild-cards. Instead of a controller-name, we could write
49
- %tt
50
- *
51
- which would mean the specified actions would apply to all controllers.
52
- %li
53
- %pre
54
- posts[all]
55
- %ul
56
- %li
57
- If we write
58
- %tt
59
- all
60
- instead of a specific action or list of actions, then all actions are allowed for a given controller.
61
- In this case a user has the ability to access all actions inside the posts_controller.
62
- %li
63
- %pre
64
- *[all]
65
- %ul
66
- %li
67
- By extension, this means a user has the ability to access all actions from all controllers.
68
- %p
69
- When abilities are assigned (authorisation), it is possible to specify the extent of the ability.
70
- What this means depends on your website, but in case of e.g. a blog-host (like blogger), this means that a
71
- %tt
72
- author
73
- 's permissions could only be valid on those blogs he owns or has access to.
26
+ %ul
27
+ %li
28
+ %pre
29
+ posts[index, show]
30
+ %ul
31
+ %li
32
+ Only the things that are explicitly specified are allowed.
33
+ This declares that on the
34
+ %tt
35
+ PostsController
36
+ only
37
+ %tt
38
+ index
39
+ and
40
+ %tt
41
+ show
42
+ are allowed.
43
+ %li
44
+ %pre
45
+ *[index, show, report]
46
+ %ul
47
+ %li
48
+ We also allow wild-cards. Instead of a controller-name, we could write
49
+ %tt
50
+ *
51
+ which would mean the specified actions would apply to all controllers.
52
+ %li
53
+ %pre
54
+ posts[all]
55
+ %ul
56
+ %li
57
+ If we write
58
+ %tt
59
+ all
60
+ instead of a specific action or list of actions, then all actions are allowed for a given controller.
61
+ In this case a user has the ability to access all actions inside the posts_controller.
62
+ %li
63
+ %pre
64
+ *[all]
65
+ %ul
66
+ %li
67
+ By extension, this means a user has the ability to access all actions from all controllers.
68
+ %p
69
+ When abilities are assigned (authorisation), it is possible to specify the extent of the ability.
70
+ What this means depends on your website, but in case of e.g. a blog-host (like blogger), this means that a
71
+ %tt
72
+ author
73
+ 's permissions could only be valid on those blogs he owns or has access to.
74
74
 
data/vigilante.gemspec CHANGED
@@ -2,16 +2,16 @@
2
2
  # DO NOT EDIT THIS FILE DIRECTLY
3
3
  # Instead, edit Jeweler::Tasks in Rakefile, and run 'rake gemspec'
4
4
  # -*- encoding: utf-8 -*-
5
- # stub: vigilante 1.0.11 ruby lib
5
+ # stub: vigilante 1.0.12 ruby lib
6
6
 
7
7
  Gem::Specification.new do |s|
8
8
  s.name = "vigilante"
9
- s.version = "1.0.11"
9
+ s.version = "1.0.12"
10
10
 
11
11
  s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
12
12
  s.require_paths = ["lib"]
13
13
  s.authors = ["Nathan Van der Auwera"]
14
- s.date = "2016-11-07"
14
+ s.date = "2016-11-28"
15
15
  s.description = "Vigilante is a db-backed authorisation, completely configurable and dynamic; where permissions can be limited to extents."
16
16
  s.email = "nathan@dixis.com"
17
17
  s.extra_rdoc_files = [
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: vigilante
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.11
4
+ version: 1.0.12
5
5
  platform: ruby
6
6
  authors:
7
7
  - Nathan Van der Auwera
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2016-11-07 00:00:00.000000000 Z
11
+ date: 2016-11-28 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rails