tramway-core 1.17.4 → 1.17.4.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.
- checksums.yaml +4 -4
- data/app/forms/tramway/core/application_form.rb +3 -1
- data/lib/tramway/core/version.rb +1 -1
- data/lib/yaml/errors.yml +3 -1
- metadata +2 -2
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 57df1e172fb15f98f9ab50d1ae0bef18e19d0e163b8f0255e9aeaeaa58fc4b22
|
|
4
|
+
data.tar.gz: 20c663842281a6e479c84d729c2ebd1f36cb9a1b67d99b8c914d2e3f144d255a
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 32af3b950613212b2b5d0e7eaec1ca66e5630235303dc178d8d0837135e382bea64a4b5bad3763510847d0b82b0cb0d3363c14bb3efafe8c5bd38080fb78d375
|
|
7
|
+
data.tar.gz: ae8206f0a248457834f8d6befbc089d94638f692e43682f212a637ca76e58261b42d564761cebf12051bc2acd7e01535402020c858e4614ebbe1f676ed5012f0
|
|
@@ -123,8 +123,10 @@ class Tramway::Core::ApplicationForm < ::Reform::Form
|
|
|
123
123
|
|
|
124
124
|
def save
|
|
125
125
|
super
|
|
126
|
+
rescue ArgumentError => e
|
|
127
|
+
Tramway::Error.raise_error :tramway, :core, :application_form, :save, :argument_error, message: e.message
|
|
126
128
|
rescue StandardError => e
|
|
127
|
-
Tramway::Error.raise_error :tramway, :core, :application_form, :
|
|
129
|
+
Tramway::Error.raise_error :tramway, :core, :application_form, :save, :looks_like_you_have_method,
|
|
128
130
|
method_name: e.name.to_s.gsub('=', ''), model_class: @@model_class, class_name: self.class
|
|
129
131
|
end
|
|
130
132
|
end
|
data/lib/tramway/core/version.rb
CHANGED
data/lib/yaml/errors.yml
CHANGED
|
@@ -13,8 +13,10 @@ tramway:
|
|
|
13
13
|
validates:
|
|
14
14
|
you_need_to_set_model_class: 'You need to set `model_class` name while using validations. Just write `self.model_class = YOUR_MODEL_NAME` in the class area.'
|
|
15
15
|
submit:
|
|
16
|
-
looks_like_you_have_method: "Looks like you have method `%{method_name}` in %{model_class}. You should rename it or rename property in %{class_name}"
|
|
17
16
|
params_should_not_be_nil: "ApplicationForm::Params should not be nil"
|
|
17
|
+
save:
|
|
18
|
+
looks_like_you_have_method: "Looks like you have method `%{method_name}` in %{model_class}. You should rename it or rename property in %{class_name}"
|
|
19
|
+
argument_error: "We have ArgumentError with message: %{message}"
|
|
18
20
|
model_class:
|
|
19
21
|
there_is_not_model_class: "There is not model class name for %{name}. Should be %{model_class_name} or you can use another class to initialize form object or just initialize form with object."
|
|
20
22
|
concerns:
|
metadata
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: tramway-core
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 1.17.4
|
|
4
|
+
version: 1.17.4.1
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Pavel Kalashnikov
|
|
@@ -9,7 +9,7 @@ authors:
|
|
|
9
9
|
autorequire:
|
|
10
10
|
bindir: bin
|
|
11
11
|
cert_chain: []
|
|
12
|
-
date: 2020-03-
|
|
12
|
+
date: 2020-03-29 00:00:00.000000000 Z
|
|
13
13
|
dependencies:
|
|
14
14
|
- !ruby/object:Gem::Dependency
|
|
15
15
|
name: audited
|