motor-admin 0.2.44 → 0.2.47
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/generators/motor/templates/install_api_configs.rb +8 -2
- data/lib/motor/version.rb +1 -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: 7c12ad8020cd49c64760d1e544167c237863738b495b0be60aa070f93191bf8d
|
4
|
+
data.tar.gz: 0b6386ecef9c7b689c52d67f2ebfc8b87057c0b3373cf0ca6aaed944054ff140
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 408c8d3f7995518d226f91e7db296f32618bf8015a0dd999c3725c5252594822ae3c6b2053f9c54e3c0d07a7564b5c56ecc26a127b045242a4b5697f711fde8c
|
7
|
+
data.tar.gz: 23358591d492b92bd02f34de7a6ca495f148ee68709af54a5b35ccebc9e4f0bb94226857ed92ce86a4ca4a0070c0c6eecef200d7c198a3fdcf2a767d2d7e49d9
|
@@ -40,13 +40,19 @@ class <%= migration_class_name %> < ActiveRecord::Migration[<%= ActiveRecord::Mi
|
|
40
40
|
|
41
41
|
add_column :motor_forms, :api_config_name, :string
|
42
42
|
|
43
|
+
MotorForm.reset_column_information
|
44
|
+
|
43
45
|
MotorForm.all.each do |form|
|
44
46
|
if form.api_path.starts_with?('http')
|
45
47
|
url = form.api_path[%r{\Ahttps?://[^/]+}]
|
46
48
|
|
47
|
-
form.preferences[:default_values_api_path]
|
49
|
+
if form.preferences[:default_values_api_path].present?
|
50
|
+
form.preferences[:default_values_api_path] =
|
51
|
+
form.preferences[:default_values_api_path].delete_prefix(url).sub(/\A\/?/, '/')
|
52
|
+
end
|
53
|
+
|
48
54
|
form.update!(api_config_name: MotorApiConfig.find_or_create_by!(name: url, url: url).name,
|
49
|
-
api_path: form.api_path.
|
55
|
+
api_path: form.api_path.delete_prefix(url).sub(/\A\/?/, '/'))
|
50
56
|
else
|
51
57
|
form.update!(api_config_name: MotorApiConfig.find_or_create_by!(name: 'origin', url: '/').name)
|
52
58
|
end
|
data/lib/motor/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: motor-admin
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.2.
|
4
|
+
version: 0.2.47
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Pete Matsyburka
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2021-12-
|
11
|
+
date: 2021-12-29 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: activerecord-filter
|