action_interceptor 0.1.0 → 0.1.1

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: 329436e7ee0f1ad6c5ce0f1891cfe6c8ae7dbe76
4
- data.tar.gz: 6f0b1b10adf2484ec53cb35245bcc02bf5d3e6d6
3
+ metadata.gz: 3d95ea3cccfec859ff09714908a18ef5eb904cc4
4
+ data.tar.gz: a4f7eeb9e36816a430ba2dff877dace1cbac493f
5
5
  SHA512:
6
- metadata.gz: 1cbcf3eae9d54f8b3fd53e8b72708312af35a89336951246f933ecda523ef265525ce655825cecd83a150ed173fe6007936a29d5db834ca9ada91157afede299
7
- data.tar.gz: d7bfd96282fe7e6b6b79b723250b694e7fca4f45bb623079824b53d582323dbc339dc4dbc15b68a72656356a6a357ff4c04220098b1915a13a3341668d335f41
6
+ metadata.gz: 113a616a949887660f1c51c6bfce54eff54e498f86fb3d9c0fe8c252793ab4b1e35f84f89b2d25d952b9484c7dd51b4f8d22fb0a58aadff2b3be89655d45ebf4
7
+ data.tar.gz: 87192d1ba1d37ba5a075cb510762ade41039fc27e2e2edadcd64a3f8ae4685e947f0584ac1e8b0e2e14718ed1e69776fee592c9a3d2b5c8454dfd81e52aa152c
data/README.md CHANGED
@@ -2,6 +2,8 @@
2
2
 
3
3
  [![Build Status](https://travis-ci.org/openstax/action_interceptor.svg?branch=master)](https://travis-ci.org/openstax/action_interceptor)
4
4
 
5
+ [![Code Climate](https://codeclimate.com/github/openstax/action_interceptor.png)](https://codeclimate.com/github/openstax/action_interceptor)
6
+
5
7
  Action Interceptor is a Rails engine that makes it easy to have controllers intercept
6
8
  actions from other controllers, have users perform a task and then return them to where
7
9
  they were when the interception happened.
@@ -0,0 +1,32 @@
1
+ ActionInterceptor.configure do
2
+ # intercepted_url_key(key)
3
+ # Type: Method
4
+ # Arguments: key (Symbol)
5
+ # The parameter/session variable that will hold the intercepted URL.
6
+ # Default: :r
7
+ intercepted_url_key :r
8
+
9
+ # override_url_options(bool)
10
+ # Type: Method
11
+ # Arguments: bool (Boolean)
12
+ # If true, the url_options method will be overriden for any controller that
13
+ # `acts_as_interceptor`. This option causes all links and redirects from any
14
+ # such controller to include a parameter containing the intercepted_url_key
15
+ # and the intercepted url. Set to false to disable for all controllers.
16
+ # If set to false, you must use the interceptor_url_options method to obtain
17
+ # the hash and pass it to any links or redirects that need to use it.
18
+ # Default: true
19
+ override_url_options true
20
+
21
+ # interceptor(interceptor_name, &block)
22
+ # Type: Method
23
+ # Arguments: interceptor name (Symbol or String),
24
+ # &block (Proc)
25
+ # Defines an interceptor.
26
+ # Default: none
27
+ # Example: interceptor :my_name do
28
+ # redirect_to my_action_users_url if some_condition
29
+ # end
30
+ #
31
+ # (Conditionally redirects to :my_action in UsersController)
32
+ end
@@ -1,4 +1,4 @@
1
1
  module ActionInterceptor
2
- VERSION = '0.1.0'
2
+ VERSION = '0.1.1'
3
3
  end
4
4
 
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: action_interceptor
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.0
4
+ version: 0.1.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Dante Soares
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2014-05-27 00:00:00.000000000 Z
11
+ date: 2014-05-30 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rails
@@ -64,6 +64,7 @@ files:
64
64
  - MIT-LICENSE
65
65
  - README.md
66
66
  - Rakefile
67
+ - config/initializers/action_interceptor.rb
67
68
  - lib/action_interceptor.rb
68
69
  - lib/action_interceptor/controller.rb
69
70
  - lib/action_interceptor/encryptor.rb