kono_utils_bootstrap_view4 0.1.0.pre.rc.4 → 0.1.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/app/concepts/kono_utils/object/cell/base.rb +6 -2
- data/app/concepts/kono_utils/object/cell/forms/fields/date_time_field.rb +1 -1
- data/app/concepts/kono_utils/object/cell/inject.rb +2 -2
- data/app/inputs/tempus_dominus_input.rb +3 -3
- data/app/views/kono_utils/base_editing/edit.html.erb +3 -3
- data/app/views/kono_utils/base_editing/edit.inject.erb +1 -1
- data/app/views/kono_utils/base_editing/index.html.erb +4 -4
- data/app/views/kono_utils/base_editing/new.html.erb +3 -3
- data/app/views/kono_utils/base_editing/new.inject.erb +1 -1
- data/app/views/kono_utils/base_editing/show.html.erb +3 -3
- data/app/views/kono_utils/base_editing/success_create_show.inject.erb +1 -1
- data/app/views/kono_utils/base_editing/success_update_show.inject.erb +1 -1
- data/lib/kono_utils_bootstrap_view4.rb +14 -8
- data/lib/kono_utils_bootstrap_view4/engine.rb +0 -3
- data/lib/kono_utils_bootstrap_view4/version.rb +1 -1
- metadata +10 -18
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: a0869fde7cdac3f227c974d670959740352a6ce8244bff8ec08439264268470f
|
4
|
+
data.tar.gz: 75ed284392e77c09b2ef9033f9f7201c176b88f95c68084c7c896b8c3a74d31b
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: def54fb4f71d919cde8adf72494d258878db8e78c5999a89a40420e14642ccf04bdb7ee40a1fba1300beb8738e8b6ca8132f7b7ad7e861eb2118ac530403ec3e
|
7
|
+
data.tar.gz: 5d92329145a3b55e5eadd638ac64f346a51c27f6143b39543870e868b011561bb1e86cf40b423172aefb5df31aa72c7222bffa0b9f205ea0877f8e999ec0c3b4
|
@@ -81,10 +81,14 @@ module KonoUtils
|
|
81
81
|
base_class.concept_prefix + super + parent_controller.lookup_context.view_paths.collect(&:to_path)
|
82
82
|
end
|
83
83
|
|
84
|
-
def
|
85
|
-
context[:
|
84
|
+
def kono_user
|
85
|
+
context[:kono_user]
|
86
86
|
end
|
87
87
|
|
88
|
+
##
|
89
|
+
# In questo modo se non viene modificato l'utente di pundit, il pundit interno a kono utilizza quello di kono_utils
|
90
|
+
alias_method :current_user, :kono_user
|
91
|
+
|
88
92
|
def title_mod
|
89
93
|
"#{t(:edit)} #{model.mn}"
|
90
94
|
end
|
@@ -46,7 +46,7 @@ module KonoUtils
|
|
46
46
|
form: form,
|
47
47
|
base_class: base_class,
|
48
48
|
nested_layout: nested_layout,
|
49
|
-
|
49
|
+
kono_user: context[:kono_user]
|
50
50
|
}.merge(remote_context)
|
51
51
|
)
|
52
52
|
|
@@ -77,7 +77,7 @@ module KonoUtils
|
|
77
77
|
context: {
|
78
78
|
form: form,
|
79
79
|
base_class: base_class,
|
80
|
-
|
80
|
+
kono_user: context[:kono_user]
|
81
81
|
}.merge(remote_context)
|
82
82
|
)
|
83
83
|
|
@@ -1,11 +1,11 @@
|
|
1
1
|
class TempusDominusInput < SimpleForm::Inputs::Base
|
2
2
|
def input(wrapper_options)
|
3
3
|
|
4
|
-
template.content_tag(:div, class:
|
4
|
+
template.content_tag(:div, class: "input-group date #{ has_errors? ? 'is-invalid' : ''}", data: { target_input: 'nearest'}, id: options[:date_time_picker_identifier]) do
|
5
5
|
|
6
6
|
tmp = ActiveSupport::SafeBuffer.new
|
7
|
-
|
8
|
-
tmp << @builder.text_field(attribute_name,
|
7
|
+
merged_input_options = merge_wrapper_options(input_html_options, wrapper_options)
|
8
|
+
tmp << @builder.text_field(attribute_name, merged_input_options)
|
9
9
|
tmp << div_button
|
10
10
|
|
11
11
|
tmp
|
@@ -1,8 +1,8 @@
|
|
1
1
|
<% content_for :page_title do %>
|
2
|
-
<%= concept(base_class.concept_ns("cell/edits/page_title"), @object, context: {
|
2
|
+
<%= concept(base_class.concept_ns("cell/edits/page_title"), @object, context: {kono_user: kono_user,base_class:base_class}) %>
|
3
3
|
<% end %>
|
4
4
|
<% content_for :side_title do %>
|
5
|
-
<%= concept(base_class.concept_ns("cell/edits/side_title"), @object, context: {
|
5
|
+
<%= concept(base_class.concept_ns("cell/edits/side_title"), @object, context: {kono_user: kono_user,base_class:base_class}) %>
|
6
6
|
<% end %>
|
7
7
|
|
8
|
-
<%= concept(base_class.concept_ns("cell/form"), @object, context: {
|
8
|
+
<%= concept(base_class.concept_ns("cell/form"), @object, context: {kono_user: kono_user,base_class:base_class}) %>
|
@@ -1,2 +1,2 @@
|
|
1
1
|
<%= concept(@object.class.concept_ns("cell/inject"), @object,
|
2
|
-
params: params, context: {
|
2
|
+
params: params, context: {kono_user: kono_user, base_class: @object.class}) -%>
|
@@ -1,10 +1,10 @@
|
|
1
1
|
<% content_for(:page_title) do %>
|
2
|
-
<%= concept(base_class.concept_ns("cell/index/page_title"), @objects, context: {
|
2
|
+
<%= concept(base_class.concept_ns("cell/index/page_title"), @objects, context: {kono_user: kono_user,base_class:base_class}) %>
|
3
3
|
<% end %>
|
4
4
|
<% content_for(:side_title) do %>
|
5
|
-
<%= concept(base_class.concept_ns("cell/index/side_title"), @objects, context: {
|
5
|
+
<%= concept(base_class.concept_ns("cell/index/side_title"), @objects, context: {kono_user: kono_user,base_class:base_class}) %>
|
6
6
|
<% end %>
|
7
7
|
|
8
|
-
<%= concept(base_class.concept_ns("cell/search"), @search, context: {
|
8
|
+
<%= concept(base_class.concept_ns("cell/search"), @search, context: {kono_user: kono_user,base_class:base_class}) unless @search.nil? %>
|
9
9
|
|
10
|
-
<%= concept(base_class.concept_ns("cell/index/table"), @objects, context: {
|
10
|
+
<%= concept(base_class.concept_ns("cell/index/table"), @objects, context: {kono_user: kono_user,base_class:base_class}) %>
|
@@ -1,9 +1,9 @@
|
|
1
1
|
<% content_for(:page_title) do %>
|
2
|
-
<%= concept(base_class.concept_ns("cell/create/page_title"), @object, context: {
|
2
|
+
<%= concept(base_class.concept_ns("cell/create/page_title"), @object, context: {kono_user: kono_user,base_class:base_class}) %>
|
3
3
|
<% end %>
|
4
4
|
<% content_for(:side_title) do %>
|
5
|
-
<%= concept(base_class.concept_ns("cell/create/side_title"), @object, context: {
|
5
|
+
<%= concept(base_class.concept_ns("cell/create/side_title"), @object, context: {kono_user: kono_user,base_class:base_class}) %>
|
6
6
|
<% end %>
|
7
7
|
|
8
8
|
|
9
|
-
<%= concept(base_class.concept_ns("cell/form"), @object, context: {
|
9
|
+
<%= concept(base_class.concept_ns("cell/form"), @object, context: {kono_user: kono_user,base_class:base_class}) %>
|
@@ -1,2 +1,2 @@
|
|
1
1
|
<%= concept(@object.class.concept_ns("cell/inject"), @object,
|
2
|
-
params: params, context: {
|
2
|
+
params: params, context: {kono_user: kono_user, base_class: @object.class}) -%>
|
@@ -1,8 +1,8 @@
|
|
1
1
|
<% content_for :page_title do %>
|
2
|
-
<%= concept(base_class.concept_ns("cell/shows/page_title"), @object, context: {
|
2
|
+
<%= concept(base_class.concept_ns("cell/shows/page_title"), @object, context: {kono_user: kono_user,base_class:base_class}) %>
|
3
3
|
<% end %>
|
4
4
|
<% content_for :side_title do %>
|
5
|
-
<%= concept(base_class.concept_ns("cell/shows/side_title"), @object, context: {
|
5
|
+
<%= concept(base_class.concept_ns("cell/shows/side_title"), @object, context: {kono_user: kono_user,base_class:base_class}) %>
|
6
6
|
<% end %>
|
7
7
|
|
8
|
-
<%= concept(base_class.concept_ns("cell/show"), @object, context: {
|
8
|
+
<%= concept(base_class.concept_ns("cell/show"), @object, context: {kono_user: kono_user,base_class:base_class}) %>
|
@@ -3,4 +3,4 @@
|
|
3
3
|
# target: params[:kono_utils][:modal_upgraded_target_container],
|
4
4
|
html_manipulation_method: 'replaceWith',
|
5
5
|
inject_show_modal: true,
|
6
|
-
context: {
|
6
|
+
context: {kono_user: kono_user, base_class: @object.class}) -%>
|
@@ -1,12 +1,20 @@
|
|
1
|
-
require
|
2
|
-
|
3
|
-
loader.ignore("#{__dir__}/generators")
|
4
|
-
loader.enable_reloading # you need to opt-in before setup
|
5
|
-
loader.setup
|
1
|
+
require 'kono_utils'
|
2
|
+
require 'active_support'
|
6
3
|
|
7
|
-
|
4
|
+
require "kono_utils_bootstrap_view4/engine"
|
8
5
|
|
9
6
|
module KonoUtilsBootstrapView4
|
7
|
+
extend ActiveSupport::Autoload
|
8
|
+
|
9
|
+
autoload :ApplicationIconHelper
|
10
|
+
autoload :BaseClassConceptNs
|
11
|
+
autoload :BaseSearch
|
12
|
+
autoload :Configuration
|
13
|
+
autoload :EditableField
|
14
|
+
autoload :Engine
|
15
|
+
autoload :PaginateProxer
|
16
|
+
autoload :SearchFormBuilder
|
17
|
+
autoload :VERSION
|
10
18
|
|
11
19
|
class << self
|
12
20
|
attr_writer :configuration
|
@@ -22,5 +30,3 @@ module KonoUtilsBootstrapView4
|
|
22
30
|
end
|
23
31
|
|
24
32
|
end
|
25
|
-
|
26
|
-
loader.eager_load
|
@@ -11,9 +11,6 @@ module KonoUtilsBootstrapView4
|
|
11
11
|
require 'data-confirm-modal'
|
12
12
|
require 'kono_utils'
|
13
13
|
|
14
|
-
# questa parte serve a Zeitwerk per identificare concepts come una directory da cui caricare il codice
|
15
|
-
config.autoload_paths << File.expand_path("../../app/concepts", __dir__)
|
16
|
-
|
17
14
|
initializer 'kono_utils_bootstrap_view4.append_views', :before => 'kono_utils.append_views', :group => :all do |app|
|
18
15
|
ActionController::Base.append_view_path KonoUtilsBootstrapView4::Engine.root.join("app", "views", "kono_utils")
|
19
16
|
ActionController::Base.append_view_path KonoUtilsBootstrapView4::Engine.root.join("app", "views", "kono_utils", "base_editing")
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: kono_utils_bootstrap_view4
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.1.
|
4
|
+
version: 0.1.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: 2021-
|
11
|
+
date: 2021-02-15 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: rails
|
@@ -37,6 +37,9 @@ dependencies:
|
|
37
37
|
- - "~>"
|
38
38
|
- !ruby/object:Gem::Version
|
39
39
|
version: '1.1'
|
40
|
+
- - ">="
|
41
|
+
- !ruby/object:Gem::Version
|
42
|
+
version: 1.1.2
|
40
43
|
type: :runtime
|
41
44
|
prerelease: false
|
42
45
|
version_requirements: !ruby/object:Gem::Requirement
|
@@ -44,6 +47,9 @@ dependencies:
|
|
44
47
|
- - "~>"
|
45
48
|
- !ruby/object:Gem::Version
|
46
49
|
version: '1.1'
|
50
|
+
- - ">="
|
51
|
+
- !ruby/object:Gem::Version
|
52
|
+
version: 1.1.2
|
47
53
|
- !ruby/object:Gem::Dependency
|
48
54
|
name: kaminari
|
49
55
|
requirement: !ruby/object:Gem::Requirement
|
@@ -86,20 +92,6 @@ dependencies:
|
|
86
92
|
- - ">="
|
87
93
|
- !ruby/object:Gem::Version
|
88
94
|
version: '0'
|
89
|
-
- !ruby/object:Gem::Dependency
|
90
|
-
name: zeitwerk
|
91
|
-
requirement: !ruby/object:Gem::Requirement
|
92
|
-
requirements:
|
93
|
-
- - ">="
|
94
|
-
- !ruby/object:Gem::Version
|
95
|
-
version: '0'
|
96
|
-
type: :runtime
|
97
|
-
prerelease: false
|
98
|
-
version_requirements: !ruby/object:Gem::Requirement
|
99
|
-
requirements:
|
100
|
-
- - ">="
|
101
|
-
- !ruby/object:Gem::Version
|
102
|
-
version: '0'
|
103
95
|
- !ruby/object:Gem::Dependency
|
104
96
|
name: trailblazer-cells
|
105
97
|
requirement: !ruby/object:Gem::Requirement
|
@@ -380,9 +372,9 @@ required_ruby_version: !ruby/object:Gem::Requirement
|
|
380
372
|
version: '0'
|
381
373
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
382
374
|
requirements:
|
383
|
-
- - "
|
375
|
+
- - ">="
|
384
376
|
- !ruby/object:Gem::Version
|
385
|
-
version:
|
377
|
+
version: '0'
|
386
378
|
requirements: []
|
387
379
|
rubygems_version: 3.0.8
|
388
380
|
signing_key:
|