tranzito_utils 1.1.6 → 1.1.7

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: 8d1e07904241472efe1b83db72f0230386eeb98187d40c10f9be3b76a8f84f4e
4
- data.tar.gz: ca8e5a18eb3b8ff25dc1f7d07f6ace763ae4660b354962b2bcaeb75258f92b8a
3
+ metadata.gz: c14aa414b13b803a8098d4664827129745a29770efe2eb968c7e14da6eb6f1d9
4
+ data.tar.gz: e12e0f60e7dd446a968ea5c176c0638b8840ba7c8157b4722d63c0423fbe095a
5
5
  SHA512:
6
- metadata.gz: b9fa852ea6ec5da71bbbafdb9e99c5f84d299363982f18c5dac3fd90152cb857ec4031abc4dec385f67be5a40464c70cded109be0c6d5d8570a4c6a961370f57
7
- data.tar.gz: 78d17c43a7a0409ef873deea4d565b826336820197ce3d2de10d83c6a7900b877efd19d8998b268d6a39159d2f74429e95fa98adf62c9431418713b872804433
6
+ metadata.gz: 95998f588a239a9e27bad0eb9cef44a233dce7a381ec34289f7d4438e203c5be1e6da5dfe39540e814557f7fb19613f377e7716ecf0d2a765afefcc43ee79da0
7
+ data.tar.gz: 557bd906a23a87a32bc23a5dc73d7e1d5c0b73a7194669a3d17e0779edcaff813abc23ebfd5b7e5d8d5e14c2e02d35080426058984038d65af26d7289c2a8ab3
@@ -0,0 +1,30 @@
1
+ -# Requires locals: collection, name
2
+ - count ||= collection.total_count
3
+ - skip_total ||= false
4
+ - skip_pagination ||= false
5
+ -# override added to convert Created to Imported - for clarity in payroll_times
6
+ - humanized_time_range_column_override ||= nil
7
+
8
+ .row.mt-4.mb-4
9
+ - unless skip_total
10
+ .col-md-5
11
+ %p.pagination-number
12
+ %strong= number_with_delimiter(count)
13
+ Matching #{name.pluralize(count)}
14
+
15
+ -# Almost all have time range...
16
+ - if defined?(@time_range) && @period != "all"
17
+ %em
18
+ - if defined?(@time_range_column)
19
+ %strong
20
+ - if humanized_time_range_column_override.present?
21
+ = humanized_time_range_column_override
22
+ - else
23
+ = humanized_time_range_column(@time_range_column)
24
+ = humanized_time_range(@time_range)
25
+ - unless skip_pagination
26
+ .pagination-flex.justify-content-md-end{class: (skip_total ? "col-12" : "col-md-7")}
27
+ = paginate collection
28
+ - if count > @per_page.to_i
29
+ - per_pages = [10, 25, 50, 100, @per_page.to_i].uniq.sort
30
+ = select_tag :per_page_select, options_for_select(per_pages.map { |i| ["#{i} / page", i] }, selected: @per_page), { class: "form-control per-page-select" }
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module TranzitoUtils
4
- VERSION = "1.1.6"
4
+ VERSION = "1.1.7"
5
5
  end
metadata CHANGED
@@ -1,16 +1,16 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: tranzito_utils
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.1.6
4
+ version: 1.1.7
5
5
  platform: ruby
6
6
  authors:
7
7
  - willbarrettdev
8
8
  - sethherr
9
9
  - hafiz-ahmed
10
- autorequire:
10
+ autorequire:
11
11
  bindir: bin
12
12
  cert_chain: []
13
- date: 2022-10-26 00:00:00.000000000 Z
13
+ date: 2022-11-09 00:00:00.000000000 Z
14
14
  dependencies:
15
15
  - !ruby/object:Gem::Dependency
16
16
  name: rails
@@ -60,6 +60,7 @@ files:
60
60
  - app/assets/stylesheets/tranzito_utils/_table_extensions.scss
61
61
  - app/assets/stylesheets/tranzito_utils/_utilities.scss
62
62
  - app/views/tranzito_utils/_flash_messages.html.haml
63
+ - app/views/tranzito_utils/_pagination.html.haml
63
64
  - app/views/tranzito_utils/_period_select.html.haml
64
65
  - config/locales/en.yml
65
66
  - lib/generators/tranzito_utils/install_generator.rb
@@ -81,7 +82,7 @@ licenses:
81
82
  metadata:
82
83
  homepage_uri: https://github.com/Tranzito/tranzito_utils
83
84
  source_code_uri: https://github.com/Tranzito/tranzito_utils
84
- post_install_message:
85
+ post_install_message:
85
86
  rdoc_options: []
86
87
  require_paths:
87
88
  - lib
@@ -96,8 +97,8 @@ required_rubygems_version: !ruby/object:Gem::Requirement
96
97
  - !ruby/object:Gem::Version
97
98
  version: '0'
98
99
  requirements: []
99
- rubygems_version: 3.1.6
100
- signing_key:
100
+ rubygems_version: 3.1.2
101
+ signing_key:
101
102
  specification_version: 4
102
103
  summary: Ruby gem contain several modules mainly containing the helpers, concerns
103
104
  and services for personal use by Tranzito