ui_bibz 3.0.11 → 3.0.12

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: f5337e14b3b5be637323fc3daee3a8631e9d16eabf12fd2e467f87c3005ca447
4
- data.tar.gz: 8f30eab7ca72300d8832d0a415dc5375da20021685e58dac6a4449d2de7f316c
3
+ metadata.gz: 3de9508c810d547d33326d4a972bd2433e8713dbf9375d8ea190e98c4ad33ddd
4
+ data.tar.gz: c703697faa4486ec6f9ee30bd5c81ad9c0794b7aa183b44d06cbe48cef4a7461
5
5
  SHA512:
6
- metadata.gz: 65c8c8f10e142f1a94653f779471f9ea86909b7334413c2a532c18e6f9750736f891ec6fbeb710bca0370ad861d40cacb2bd30f365abcda8ba042a9f2bdcedf3
7
- data.tar.gz: 960429942f530afe95b51a1a7af8cb586089552e3fc6bd40b940f21df38e463dd8db8daf7613f6343cdcb7e048936dae2ca3d9ee9829e3adcdf3de665aa73032
6
+ metadata.gz: 221ce464b0e8f84b914dd94c81fbfe5dcc34eb8b3534ec9a76fdb660419079ab6232ddf528e2e19ac55ea946c01f99d71e4e3d2cf5063855449333e152b9c5db
7
+ data.tar.gz: 2c0289ea4c25f7ff68ff936f41a8556dd576941124fca9671ccdd0839eb4ec6240989f3f4ab17d01b269841ebf5e2df2a343d3adecd82a3ebe130935e276307f
data/.rubocop.yml CHANGED
@@ -173,3 +173,6 @@ Rails/OutputSafety:
173
173
 
174
174
  Rails/SkipsModelValidations:
175
175
  Enabled: false
176
+
177
+ Style/OpenStructUse:
178
+ Enabled: false
data/Gemfile.lock CHANGED
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- ui_bibz (3.0.11)
4
+ ui_bibz (3.0.12)
5
5
  will-paginate-i18n
6
6
  will_paginate (~> 3.3.0)
7
7
  will_paginate-bootstrap4
@@ -9,60 +9,60 @@ PATH
9
9
  GEM
10
10
  remote: https://rubygems.org/
11
11
  specs:
12
- actioncable (6.1.4.1)
13
- actionpack (= 6.1.4.1)
14
- activesupport (= 6.1.4.1)
12
+ actioncable (6.1.4.4)
13
+ actionpack (= 6.1.4.4)
14
+ activesupport (= 6.1.4.4)
15
15
  nio4r (~> 2.0)
16
16
  websocket-driver (>= 0.6.1)
17
- actionmailbox (6.1.4.1)
18
- actionpack (= 6.1.4.1)
19
- activejob (= 6.1.4.1)
20
- activerecord (= 6.1.4.1)
21
- activestorage (= 6.1.4.1)
22
- activesupport (= 6.1.4.1)
17
+ actionmailbox (6.1.4.4)
18
+ actionpack (= 6.1.4.4)
19
+ activejob (= 6.1.4.4)
20
+ activerecord (= 6.1.4.4)
21
+ activestorage (= 6.1.4.4)
22
+ activesupport (= 6.1.4.4)
23
23
  mail (>= 2.7.1)
24
- actionmailer (6.1.4.1)
25
- actionpack (= 6.1.4.1)
26
- actionview (= 6.1.4.1)
27
- activejob (= 6.1.4.1)
28
- activesupport (= 6.1.4.1)
24
+ actionmailer (6.1.4.4)
25
+ actionpack (= 6.1.4.4)
26
+ actionview (= 6.1.4.4)
27
+ activejob (= 6.1.4.4)
28
+ activesupport (= 6.1.4.4)
29
29
  mail (~> 2.5, >= 2.5.4)
30
30
  rails-dom-testing (~> 2.0)
31
- actionpack (6.1.4.1)
32
- actionview (= 6.1.4.1)
33
- activesupport (= 6.1.4.1)
31
+ actionpack (6.1.4.4)
32
+ actionview (= 6.1.4.4)
33
+ activesupport (= 6.1.4.4)
34
34
  rack (~> 2.0, >= 2.0.9)
35
35
  rack-test (>= 0.6.3)
36
36
  rails-dom-testing (~> 2.0)
37
37
  rails-html-sanitizer (~> 1.0, >= 1.2.0)
38
- actiontext (6.1.4.1)
39
- actionpack (= 6.1.4.1)
40
- activerecord (= 6.1.4.1)
41
- activestorage (= 6.1.4.1)
42
- activesupport (= 6.1.4.1)
38
+ actiontext (6.1.4.4)
39
+ actionpack (= 6.1.4.4)
40
+ activerecord (= 6.1.4.4)
41
+ activestorage (= 6.1.4.4)
42
+ activesupport (= 6.1.4.4)
43
43
  nokogiri (>= 1.8.5)
44
- actionview (6.1.4.1)
45
- activesupport (= 6.1.4.1)
44
+ actionview (6.1.4.4)
45
+ activesupport (= 6.1.4.4)
46
46
  builder (~> 3.1)
47
47
  erubi (~> 1.4)
48
48
  rails-dom-testing (~> 2.0)
49
49
  rails-html-sanitizer (~> 1.1, >= 1.2.0)
50
- activejob (6.1.4.1)
51
- activesupport (= 6.1.4.1)
50
+ activejob (6.1.4.4)
51
+ activesupport (= 6.1.4.4)
52
52
  globalid (>= 0.3.6)
53
- activemodel (6.1.4.1)
54
- activesupport (= 6.1.4.1)
55
- activerecord (6.1.4.1)
56
- activemodel (= 6.1.4.1)
57
- activesupport (= 6.1.4.1)
58
- activestorage (6.1.4.1)
59
- actionpack (= 6.1.4.1)
60
- activejob (= 6.1.4.1)
61
- activerecord (= 6.1.4.1)
62
- activesupport (= 6.1.4.1)
53
+ activemodel (6.1.4.4)
54
+ activesupport (= 6.1.4.4)
55
+ activerecord (6.1.4.4)
56
+ activemodel (= 6.1.4.4)
57
+ activesupport (= 6.1.4.4)
58
+ activestorage (6.1.4.4)
59
+ actionpack (= 6.1.4.4)
60
+ activejob (= 6.1.4.4)
61
+ activerecord (= 6.1.4.4)
62
+ activesupport (= 6.1.4.4)
63
63
  marcel (~> 1.0.0)
64
64
  mini_mime (>= 1.1.0)
65
- activesupport (6.1.4.1)
65
+ activesupport (6.1.4.4)
66
66
  concurrent-ruby (~> 1.0, >= 1.0.2)
67
67
  i18n (>= 1.6, < 2)
68
68
  minitest (>= 5.1)
@@ -106,7 +106,7 @@ GEM
106
106
  rails-dom-testing (>= 1, < 3)
107
107
  railties (>= 4.2.0)
108
108
  thor (>= 0.14, < 2.0)
109
- loofah (2.12.0)
109
+ loofah (2.13.0)
110
110
  crass (~> 1.0.2)
111
111
  nokogiri (>= 1.5.9)
112
112
  mail (2.7.1)
@@ -115,7 +115,7 @@ GEM
115
115
  method_source (1.0.0)
116
116
  mini_mime (1.1.2)
117
117
  mini_portile2 (2.6.1)
118
- minitest (5.14.4)
118
+ minitest (5.15.0)
119
119
  nio4r (2.5.8)
120
120
  nokogiri (1.12.5)
121
121
  mini_portile2 (~> 2.6.1)
@@ -125,35 +125,35 @@ GEM
125
125
  iniparse (~> 1.4)
126
126
  rexml (~> 3.2)
127
127
  parallel (1.21.0)
128
- parser (3.0.3.1)
128
+ parser (3.0.3.2)
129
129
  ast (~> 2.4.1)
130
130
  racc (1.6.0)
131
131
  rack (2.2.3)
132
132
  rack-test (1.1.0)
133
133
  rack (>= 1.0, < 3)
134
- rails (6.1.4.1)
135
- actioncable (= 6.1.4.1)
136
- actionmailbox (= 6.1.4.1)
137
- actionmailer (= 6.1.4.1)
138
- actionpack (= 6.1.4.1)
139
- actiontext (= 6.1.4.1)
140
- actionview (= 6.1.4.1)
141
- activejob (= 6.1.4.1)
142
- activemodel (= 6.1.4.1)
143
- activerecord (= 6.1.4.1)
144
- activestorage (= 6.1.4.1)
145
- activesupport (= 6.1.4.1)
134
+ rails (6.1.4.4)
135
+ actioncable (= 6.1.4.4)
136
+ actionmailbox (= 6.1.4.4)
137
+ actionmailer (= 6.1.4.4)
138
+ actionpack (= 6.1.4.4)
139
+ actiontext (= 6.1.4.4)
140
+ actionview (= 6.1.4.4)
141
+ activejob (= 6.1.4.4)
142
+ activemodel (= 6.1.4.4)
143
+ activerecord (= 6.1.4.4)
144
+ activestorage (= 6.1.4.4)
145
+ activesupport (= 6.1.4.4)
146
146
  bundler (>= 1.15.0)
147
- railties (= 6.1.4.1)
147
+ railties (= 6.1.4.4)
148
148
  sprockets-rails (>= 2.0.0)
149
149
  rails-dom-testing (2.0.3)
150
150
  activesupport (>= 4.2.0)
151
151
  nokogiri (>= 1.6)
152
152
  rails-html-sanitizer (1.4.2)
153
153
  loofah (~> 2.3)
154
- railties (6.1.4.1)
155
- actionpack (= 6.1.4.1)
156
- activesupport (= 6.1.4.1)
154
+ railties (6.1.4.4)
155
+ actionpack (= 6.1.4.4)
156
+ activesupport (= 6.1.4.4)
157
157
  method_source
158
158
  rake (>= 0.13)
159
159
  thor (~> 1.0)
@@ -170,7 +170,7 @@ GEM
170
170
  rubocop-ast (>= 1.12.0, < 2.0)
171
171
  ruby-progressbar (~> 1.7)
172
172
  unicode-display_width (>= 1.4.0, < 3.0)
173
- rubocop-ast (1.14.0)
173
+ rubocop-ast (1.15.0)
174
174
  parser (>= 3.0.1.1)
175
175
  rubocop-minitest (0.17.0)
176
176
  rubocop (>= 0.90, < 2.0)
@@ -197,7 +197,7 @@ GEM
197
197
  sprockets (4.0.2)
198
198
  concurrent-ruby (~> 1.0)
199
199
  rack (> 1, < 3)
200
- sprockets-rails (3.4.1)
200
+ sprockets-rails (3.4.2)
201
201
  actionpack (>= 5.2)
202
202
  activesupport (>= 5.2)
203
203
  sprockets (>= 3.0.0)
@@ -82,7 +82,7 @@ module UiBibz::Concerns::Models::Searchable
82
82
 
83
83
  def self.generate_default_sql(sql)
84
84
  if sorting?
85
- sql.reorder('').paginate(page: @tmp_params[:page], per_page: @tmp_params[:per_page])
85
+ sql.reorder(default_order).paginate(page: @tmp_params[:page], per_page: @tmp_params[:per_page])
86
86
  else
87
87
  sql.reorder(order_sql).paginate(page: @tmp_params[:page], per_page: @tmp_params[:per_page])
88
88
  end
@@ -111,6 +111,10 @@ module UiBibz::Concerns::Models::Searchable
111
111
  @tmp_params[:sort].nil? || @tmp_params[:direction].nil?
112
112
  end
113
113
 
114
+ def self.default_order
115
+ @arguments.dig(:default, :order) || ''
116
+ end
117
+
114
118
  def self.search_by_query(sql)
115
119
  raise 'Add searchable_attributes method in Model' if @searchable_attributes.nil?
116
120
 
data/lib/ui_bibz/infos.rb CHANGED
@@ -12,6 +12,6 @@ module UiBibz
12
12
  REPO = 'git+https://github.com/thooams/ui_bibz.git'
13
13
  EMAIL = 'thomas@hummel.link'
14
14
  AUTHOR = 'Thooams [Thomas HUMMEL]'
15
- VERSION = '3.0.11'
15
+ VERSION = '3.0.12'
16
16
  AUTHORS = ['Thooams'].freeze
17
17
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: ui_bibz
3
3
  version: !ruby/object:Gem::Version
4
- version: 3.0.11
4
+ version: 3.0.12
5
5
  platform: ruby
6
6
  authors:
7
7
  - Thooams [Thomas HUMMEL]
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2021-12-06 00:00:00.000000000 Z
11
+ date: 2021-12-23 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rails