petergate 1.0.2 → 1.0.3

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
  SHA1:
3
- metadata.gz: 02fcc936703a7764d3e360c97fd577d2bb9c2ff2
4
- data.tar.gz: 0d71fa88703d732bd82a790ae16eae8e1c6890ad
3
+ metadata.gz: de06a08ec4ff4aef5960901b33c6ce1c5f62cc37
4
+ data.tar.gz: 5fc28c5ba7fd611458d8071ea2b7b30a9f80aa61
5
5
  SHA512:
6
- metadata.gz: 906c4d8507b98f3bc0e8b512bf6e878f07e4757c63795091408775e4fdc480caf6c31fd4b8210d26ec6584ff37f9735432cb0a7b0b5bfe8cfbad9f752cecbe1b
7
- data.tar.gz: 5f0622280f7d006c159f5fda9881de0f6ef4bea4d69d8bdd25ad7f3a0e391704a9ffedefcc6e83b9ca2b9957b618225391ca55b2640175c104dac0ffe71f14f9
6
+ metadata.gz: 1ea77c11bb3d86744de4b05fad7179e1cac58e1f26befbb2d8083bcec67aa73c924270c64a90cc87a7cb07cc45d891e48b0ef58710b0c2676e60b22461036fb8
7
+ data.tar.gz: 09f2720549ba5c40e27deaf18e585e7cdfcfa50bebff6930dd87df9b17ed7ca5e6aa411f96490a1e6eb4b050b6bb7bb194af85ec6fc95c6796d17dea8e657590
data/README.md CHANGED
@@ -54,6 +54,9 @@ Setup permissions in your controllers the same as you would for a before filter
54
54
 
55
55
  ```ruby
56
56
  access all: [:show, :index], user: ALLREST
57
+
58
+ # one other options that might seem a bit weird is to put a group of roles in an array:
59
+ access [:all, :user] => [:show, :index]
57
60
  ```
58
61
 
59
62
  Inside your views you can use logged_in?(:admin, :customer, :etc) to show or hide content.
@@ -1,3 +1,3 @@
1
1
  module Petergate
2
- VERSION = "1.0.2"
2
+ VERSION = "1.0.3"
3
3
  end
@@ -5,7 +5,7 @@ require_dependency "<%= namespaced_file_path %>/application_controller"
5
5
  <% module_namespacing do -%>
6
6
  class <%= controller_class_name %>Controller < ApplicationController
7
7
  before_action :set_<%= singular_table_name %>, only: [:show, :edit, :update, :destroy]
8
- access [:user, :all] => [:index, :show, :new, :edit, :create, :update, :destroy]
8
+ access all: [:index, :show, :new, :edit, :create, :update, :destroy]
9
9
 
10
10
  # GET <%= route_url %>
11
11
  def index
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: petergate
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.2
4
+ version: 1.0.3
5
5
  platform: ruby
6
6
  authors:
7
7
  - Isaac Sloan
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2015-01-20 00:00:00.000000000 Z
11
+ date: 2015-01-27 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler
@@ -94,7 +94,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
94
94
  version: '0'
95
95
  requirements: []
96
96
  rubyforge_project:
97
- rubygems_version: 2.2.2
97
+ rubygems_version: 2.4.5
98
98
  signing_key:
99
99
  specification_version: 4
100
100
  summary: Authorization system allowing verbose easy read controller syntax.