realtime-validations 0.1.0 → 0.1.1
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.
- data/README.rdoc +16 -16
- data/lib/realtime-validations/version.rb +1 -1
- metadata +9 -9
data/README.rdoc
CHANGED
@@ -23,16 +23,16 @@ This gem is simple. Very simple. It is developed with some things in mind:
|
|
23
23
|
* Someone updates some validation on some model, and javascript is forgotten to be updated.
|
24
24
|
* You need to replicate the same logic in two different languages with their implementation
|
25
25
|
differences.
|
26
|
-
|
27
|
-
|
28
|
-
|
29
|
-
|
30
|
-
|
31
|
-
|
32
|
-
|
33
|
-
|
34
|
-
|
35
|
-
|
26
|
+
* Highly configurable.
|
27
|
+
* There are three hooks to configure the behaviour as you want.
|
28
|
+
1. Server: when the Controller module is included into the ValidationsController class.
|
29
|
+
* Here you can remove or add filters.
|
30
|
+
2. Server: before asking for the model validity.
|
31
|
+
* You can add extra information to the model here based on the knowledge of the current
|
32
|
+
situation of the ApplicationController, such as the current client id or user id.
|
33
|
+
3. Client: before sending the request to the ValidationsController.
|
34
|
+
* Here you are able to add more information to the request, for instance retrieving it
|
35
|
+
from a meta tag on the page or wherever you want, is up to you.
|
36
36
|
|
37
37
|
== Dependencies
|
38
38
|
|
@@ -47,23 +47,23 @@ Installation is very easy on your own project:
|
|
47
47
|
|
48
48
|
=== Gemfile
|
49
49
|
|
50
|
-
gem 'realtime-validations'
|
50
|
+
gem 'realtime-validations'
|
51
51
|
|
52
52
|
=== Running generators
|
53
53
|
|
54
|
-
rails g realtime_validations:install
|
54
|
+
rails g realtime_validations:install
|
55
55
|
|
56
56
|
=== Assets pipeline
|
57
57
|
|
58
58
|
Include the core javascript of the application:
|
59
59
|
|
60
|
-
# app/assets/javascripts/application.js
|
61
|
-
//= require realtime_validations
|
60
|
+
# app/assets/javascripts/application.js
|
61
|
+
//= require realtime_validations
|
62
62
|
|
63
63
|
For now it is necessary to include the stylesheet too, but it will be optional in next versions:
|
64
64
|
|
65
|
-
# app/assets/stylesheets/application.css
|
66
|
-
*= require realtime_validations
|
65
|
+
# app/assets/stylesheets/application.css
|
66
|
+
*= require realtime_validations
|
67
67
|
|
68
68
|
== Usage
|
69
69
|
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: realtime-validations
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.1.
|
4
|
+
version: 0.1.1
|
5
5
|
prerelease:
|
6
6
|
platform: ruby
|
7
7
|
authors:
|
@@ -13,7 +13,7 @@ date: 2012-01-02 00:00:00.000000000 Z
|
|
13
13
|
dependencies:
|
14
14
|
- !ruby/object:Gem::Dependency
|
15
15
|
name: rails
|
16
|
-
requirement: &
|
16
|
+
requirement: &25332020 !ruby/object:Gem::Requirement
|
17
17
|
none: false
|
18
18
|
requirements:
|
19
19
|
- - ! '>='
|
@@ -21,18 +21,18 @@ dependencies:
|
|
21
21
|
version: 3.1.3
|
22
22
|
type: :runtime
|
23
23
|
prerelease: false
|
24
|
-
version_requirements: *
|
24
|
+
version_requirements: *25332020
|
25
25
|
- !ruby/object:Gem::Dependency
|
26
|
-
name:
|
27
|
-
requirement: &
|
26
|
+
name: jquery-rails
|
27
|
+
requirement: &25331520 !ruby/object:Gem::Requirement
|
28
28
|
none: false
|
29
29
|
requirements:
|
30
30
|
- - ! '>='
|
31
31
|
- !ruby/object:Gem::Version
|
32
|
-
version:
|
33
|
-
type: :
|
32
|
+
version: 2.0.0
|
33
|
+
type: :runtime
|
34
34
|
prerelease: false
|
35
|
-
version_requirements: *
|
35
|
+
version_requirements: *25331520
|
36
36
|
description: Form real time validations for free on Rails applications
|
37
37
|
email:
|
38
38
|
- ereslibre@gmail.com
|
@@ -84,7 +84,7 @@ files:
|
|
84
84
|
- test/dummy/app/helpers/application_helper.rb
|
85
85
|
- test/dummy/Rakefile
|
86
86
|
- test/realtime-validations_test.rb
|
87
|
-
homepage:
|
87
|
+
homepage: https://github.com/ereslibre/realtime-validations/wiki
|
88
88
|
licenses: []
|
89
89
|
post_install_message:
|
90
90
|
rdoc_options: []
|