base_editing_bootstrap 1.5.0 → 1.5.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/CHANGELOG.md +8 -0
- data/app/helpers/utilities/form_helper.rb +2 -2
- data/app/helpers/utilities/search_helper.rb +2 -2
- data/app/helpers/utilities/template_helper.rb +17 -4
- data/lib/base_editing_bootstrap/VERSION +1 -1
- metadata +2 -9
- data/app/assets/images/base_editing_bootstrap/.keep +0 -0
- data/app/assets/stylesheets/base_editing_bootstrap/.keep +0 -0
- data/app/controllers/concerns/.keep +0 -0
- data/app/jobs/.keep +0 -0
- data/app/mailers/.keep +0 -0
- data/app/models/.keep +0 -0
- data/app/models/concerns/.keep +0 -0
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: aee3afb2ce6b96c834dbc1491588c42355e8e726ce1ba030f1ebd9c31d368800
|
4
|
+
data.tar.gz: 6ee2f8827e7ec00045a710c113f1e432a874a3900d840257f9602902aaad6466
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: ce1a79b4abb27bc8f1297b7100bdc0ed5beb6589a0fe2ddf0915bc5f258a85cfa071644a84f35ff1b0a03444c57246d15bebb2a1dcf9a738c654675f48f45b19
|
7
|
+
data.tar.gz: b65de7345289bb1ef0724f27279a4afba4017ca3620714982b94f1fdc958e0322b91c8ee9a3e3ccc82040bd5c2a7b632b376a34f5e95d7ee7c00364e8efd57e3
|
data/CHANGELOG.md
CHANGED
@@ -2,6 +2,14 @@
|
|
2
2
|
All notable changes to this project will be documented in this file. See [conventional commits](https://www.conventionalcommits.org/) for commit guidelines.
|
3
3
|
|
4
4
|
- - -
|
5
|
+
## 1.5.1 - 2025-01-22
|
6
|
+
#### Bug Fixes
|
7
|
+
- Ricerca template anche con contesto del controller - (ac93a9f) - Marino Bonetti
|
8
|
+
#### Miscellaneous Chores
|
9
|
+
- Remove unused files - (0b56f94) - Marino Bonetti
|
10
|
+
|
11
|
+
- - -
|
12
|
+
|
5
13
|
## 1.5.0 - 2025-01-16
|
6
14
|
#### Documentation
|
7
15
|
- Update documentation - (3a29e34) - Marino Bonetti
|
@@ -71,8 +71,8 @@ module Utilities
|
|
71
71
|
"form_field",
|
72
72
|
generic_field
|
73
73
|
)
|
74
|
-
Rails.logger.debug { "#{type}->#{generic_field}->#{template}->#{ locals.inspect}" }
|
75
|
-
render
|
74
|
+
Rails.logger.debug { "#{type}->#{generic_field}->#{template.short_identifier}->#{ locals.inspect}" }
|
75
|
+
template.render(self, locals)
|
76
76
|
end
|
77
77
|
|
78
78
|
end
|
@@ -32,7 +32,7 @@ module Utilities
|
|
32
32
|
# @return [ActiveSupport::SafeBuffer]
|
33
33
|
def render_cell_field(obj, field)
|
34
34
|
template = template_for_column(obj.class, field, "cell_field")
|
35
|
-
render
|
35
|
+
template.render(self,{obj:, field:})
|
36
36
|
end
|
37
37
|
|
38
38
|
##
|
@@ -42,7 +42,7 @@ module Utilities
|
|
42
42
|
# @return [ActiveSupport::SafeBuffer]
|
43
43
|
def render_header_cell_field(search_instance, field)
|
44
44
|
template = template_for_column(search_instance.model_klass, field, "header_field")
|
45
|
-
render
|
45
|
+
template.render(self,{obj: search_instance.model_klass, field:, search_instance: search_instance})
|
46
46
|
end
|
47
47
|
|
48
48
|
##
|
@@ -17,10 +17,23 @@ module Utilities::TemplateHelper
|
|
17
17
|
# avere la partial_path
|
18
18
|
partial_path = (obj.respond_to? :to_partial_path) ? obj.to_partial_path : obj._to_partial_path
|
19
19
|
obj_base_path = "#{partial_path}/#{base_path}"
|
20
|
-
|
21
|
-
|
22
|
-
|
23
|
-
|
20
|
+
|
21
|
+
# Precedenza modello e campo specifico
|
22
|
+
if lookup_context.exists?(field, [obj_base_path], true)
|
23
|
+
return lookup_context.find(field, [obj_base_path], true)
|
24
|
+
end
|
25
|
+
# Ricerca tramite campo generico e prefissi di contesto che contiene anche controller e namespace di controller
|
26
|
+
if lookup_context.exists?("#{base_path}/#{generic_field}", lookup_context.prefixes, true)
|
27
|
+
view = lookup_context.find_all("#{base_path}/#{generic_field}", lookup_context.prefixes, true)
|
28
|
+
return view.first
|
29
|
+
end
|
30
|
+
if lookup_context.exists?(generic_field, [obj_base_path], true)
|
31
|
+
return lookup_context.find(generic_field, [obj_base_path], true)
|
32
|
+
end
|
33
|
+
if lookup_context.exists?("base_editing/#{base_path}/#{generic_field}", [], true)
|
34
|
+
return lookup_context.find_all("base_editing/#{base_path}/#{generic_field}", [], true).first
|
35
|
+
end
|
36
|
+
lookup_context.find("base_editing/#{base_path}/base", [], true)
|
24
37
|
end
|
25
38
|
|
26
39
|
end
|
@@ -1 +1 @@
|
|
1
|
-
1.5.
|
1
|
+
1.5.1
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: base_editing_bootstrap
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.5.
|
4
|
+
version: 1.5.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Marino Bonetti
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2025-01-
|
11
|
+
date: 2025-01-22 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: rails
|
@@ -320,11 +320,8 @@ files:
|
|
320
320
|
- README.md
|
321
321
|
- Rakefile
|
322
322
|
- app/assets/config/base_editing_bootstrap_manifest.js
|
323
|
-
- app/assets/images/base_editing_bootstrap/.keep
|
324
|
-
- app/assets/stylesheets/base_editing_bootstrap/.keep
|
325
323
|
- app/controllers/.keep
|
326
324
|
- app/controllers/base_editing_controller.rb
|
327
|
-
- app/controllers/concerns/.keep
|
328
325
|
- app/controllers/restricted_area_controller.rb
|
329
326
|
- app/helpers/.keep
|
330
327
|
- app/helpers/base_editing_helper.rb
|
@@ -334,10 +331,6 @@ files:
|
|
334
331
|
- app/helpers/utilities/page_helper.rb
|
335
332
|
- app/helpers/utilities/search_helper.rb
|
336
333
|
- app/helpers/utilities/template_helper.rb
|
337
|
-
- app/jobs/.keep
|
338
|
-
- app/mailers/.keep
|
339
|
-
- app/models/.keep
|
340
|
-
- app/models/concerns/.keep
|
341
334
|
- app/policies/base_model_policy.rb
|
342
335
|
- app/views/.keep
|
343
336
|
- app/views/base_editing/_edit_page_title_header.html.erb
|
File without changes
|
File without changes
|
File without changes
|
data/app/jobs/.keep
DELETED
File without changes
|
data/app/mailers/.keep
DELETED
File without changes
|
data/app/models/.keep
DELETED
File without changes
|
data/app/models/concerns/.keep
DELETED
File without changes
|