rows_controller 3.2.0 → 3.2.2

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 CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 1c3ce447b8c13f598f9f3f7f0181964d5ffed3c63f53cc6d4cf97d10b2b2a10c
4
- data.tar.gz: c8d44ddd01d94c014bc7e75dffe6e385298e70f23ef20ac17d8548e7e28f22b7
3
+ metadata.gz: 1e2170f9f6c65f946cde43eb8b6c8220a57076795f802d33a7208eb930b2647c
4
+ data.tar.gz: 8219728198be01ce794145e59c755c8344c5a4aafe70450e5aabbbc4314a66a7
5
5
  SHA512:
6
- metadata.gz: 9234c715d7bda274fb2cf6c76badc45faddbadac674e4c22006c0c91dc2d68a72ea2d0b1efc273a339f9ddc7e7852dad99e86bff7b9470a35ad189652c9cf0ac
7
- data.tar.gz: 37128cbbc023ab35b93e47d92dfc37739a0315777f420df68cbf8109c3c28cb3dfe6284ffc8e6548ff53ecd8253a2f0d52486ad4d18244e9b0100e9b77bbad3d
6
+ metadata.gz: 3b449c5947dbe4964c4010182af0eafae256794f59d09840c9c9267ca7060d35664758df66b62779de9db9327cafab7ee10e460b09a1a7179ba136c04ff133a4
7
+ data.tar.gz: de0173ac1f4d5f3ca6e2d6b305a1d29ff3f202f1c6fa271afd98d57d3a1f609704c4d2532b88e966c38b8eca035514df729dc243418fd5d582f082f858b07295
data/MIT-LICENSE CHANGED
@@ -1,4 +1,4 @@
1
- Copyright (c) 2012-2024 Dittmar Krall (www.matiq.com)
1
+ Copyright (c) 2012-2026 Dittmar Krall (www.matiq.com)
2
2
 
3
3
  Permission is hereby granted, free of charge, to any person obtaining
4
4
  a copy of this software and associated documentation files (the
data/README.md CHANGED
@@ -1,9 +1,10 @@
1
1
  # RowsController
2
- [![Gem Version](https://badge.fury.io/rb/rows_controller.svg)](https://badge.fury.io/rb/rows_controller)
3
- [![GEM Downloads](https://img.shields.io/gem/dt/rows_controller?color=168AFE&logo=ruby&logoColor=FE1616)](https://rubygems.org/gems/rows_controller)
4
- [![rake](https://github.com/matique/rows_controller/actions/workflows/rake.yml/badge.svg)](https://github.com/matique/rows_controller/actions/workflows/rake.yml)
5
- [![Ruby Style Guide](https://img.shields.io/badge/code_style-standard-brightgreen.svg)](https://github.com/standardrb/standard)
6
- [![MIT License](https://img.shields.io/badge/license-MIT-blue.svg)](http://choosealicense.com/licenses/mit/)
2
+
3
+ [![Gem Version](https://img.shields.io/gem/v/rows_controller?color=168AFE&logo=rubygems&logoColor=FE1616)](https://rubygems.org/gems/rows_controller)
4
+ [![Downloads](https://img.shields.io/gem/dt/rows_controller?color=168AFE&logo=rubygems&logoColor=FE1616)](https://rubygems.org/gems/rows_controller)
5
+ [![GitHub Build](https://img.shields.io/github/actions/workflow/status/matique/rows_controller/rake.yml?logo=github)](https://github.com/matique/rows_controller/actions/workflows/rake.yml)
6
+ [![Ruby Style Guide](https://img.shields.io/badge/code_style-standard-168AFE.svg)](https://github.com/standardrb/standard)
7
+ [![MIT License](https://img.shields.io/badge/license-MIT-168AFE.svg)](http://choosealicense.com/licenses/mit/)
7
8
 
8
9
  DRYs Rails controllers. Imagine replacing that @order by 'resource' in the
9
10
  controllers/views and, IMHO, an area for DRYing appears.
@@ -30,10 +31,10 @@ class OrdersController < RowsController # < ApplicationController
30
31
  end
31
32
  ~~~
32
33
 
33
- I.e. RowsController defines all the usual methods (index, show, edit,...).
34
+ I.e. _RowsController_ defines all the usual methods (index, show, edit,...).
34
35
 
35
36
  The methods may be redefined in OrdersController
36
- (overwrites methods from RowsController).
37
+ (overwrites methods from _RowsController_).
37
38
 
38
39
  Low level methods like 'resources' may be redefined as well.
39
40
  An example:
@@ -44,21 +45,21 @@ def resources
44
45
  end
45
46
  ~~~
46
47
 
47
- RowsController inherites from ApplicationController, i.e. all the helpers
48
+ _RowsController_ inherites from ApplicationController, i.e. all the helpers
48
49
  defined there will be available.
49
50
 
50
51
 
51
52
  ## Customizing of views
52
53
 
53
- RowsController initializes some instance variables used in the views
54
+ _RowsController_ initializes some instance variables used in the views
54
55
  (e.g. @order, @orders; legacy @row & @rows are still supported).
55
56
  Furthermore, the helpers resource, resources, set_resource and
56
57
  set_resources are available. You guess their usage.
57
58
 
58
59
  Providing e.g. an "#{Rails.root}/app/views/order/index.html.erb"
59
- overwrites the default RowsController view as Rails will first look
60
+ overwrites the default _RowsController_ view as Rails will first look
60
61
  into the directory "#{Rails.root}/app/views" before looking
61
- into the RowsController.
62
+ into the _RowsController_.
62
63
 
63
64
  Similarly, partials '\_row\_buttons' and '\_list\_footer' may be overwritten
64
65
  as well.
@@ -66,7 +67,7 @@ as well.
66
67
 
67
68
  ## model_class
68
69
 
69
- RowsController guesses the model from params[:controller]. This can
70
+ _RowsController_ guesses the model from params[:controller]. This can
70
71
  be changed by:
71
72
 
72
73
  ~~~ruby
@@ -80,14 +81,14 @@ The model class can be retrieved with the helper model_class.
80
81
 
81
82
  ## Rails 8
82
83
 
83
- RowsController 3.2.* is intended for Rails 8+.
84
+ _RowsController_ 3.2.* is intended for Rails 8+.
84
85
  In particular, *turbo stream* is used for row deletion.
85
86
  Older Rails versions may use "gem 'rows_controller', '= 3.1.7'".
86
87
 
87
88
 
88
89
  ## Rails 7
89
90
 
90
- RowsController 3.1.* is intended for Rails 7.
91
+ _RowsController_ 3.1.* is intended for Rails 7.
91
92
  In particular Hotwire caused some quirks
92
93
  which are handled by this version.
93
94
  Compatibility with older Rails versions are not intended
@@ -152,5 +153,5 @@ Look for:
152
153
 
153
154
  ## Miscellaneous
154
155
 
155
- Copyright (c) 2009-2025 Dittmar Krall (www.matiq.com),
156
+ Copyright (c) 2009-2026 Dittmar Krall (www.matiq.com),
156
157
  released under the [MIT license](https://opensource.org/licenses/MIT).
@@ -1,5 +1,3 @@
1
- # frozen_string_literal: true
2
-
3
1
  require "rows/resources"
4
2
  require "rows/model"
5
3
  require "rows/utils"
data/lib/rows/model.rb CHANGED
@@ -1,11 +1,7 @@
1
- # frozen_string_literal: true
2
-
3
1
  module Rows::Model
4
2
  def model_class
5
- # rubocop: disable
6
3
  @_model_class ||= self.class.model_class ||
7
4
  Kernel.const_get(params[:controller].classify)
8
- # rubocop: enable
9
5
  end
10
6
 
11
7
  if Rails::VERSION::MAJOR > 3
@@ -1,5 +1,3 @@
1
- # frozen_string_literal: true
2
-
3
1
  module Rows::Resources
4
2
  def resource
5
3
  @_resource || set_resource
data/lib/rows/utils.rb CHANGED
@@ -1,4 +1,3 @@
1
- # frozen_string_literal: true
2
1
  # rubocop: disable all
3
2
 
4
3
  module Rows::Utils
data/lib/rows/version.rb CHANGED
@@ -1,5 +1,7 @@
1
1
  module Rows
2
- VERSION = "3.2.0" # 2025-02-10
2
+ VERSION = "3.2.2" # 2026-01-02
3
+ # VERSION = "3.2.1" # 2025-06-23
4
+ # VERSION = "3.2.0" # 2025-02-10
3
5
  # VERSION = "3.1.7" # 2024-12-10
4
6
  # VERSION = "3.1.6" # 2024-09-07
5
7
  # VERSION = "3.1.5" # 2024-02-18
@@ -1,5 +1,7 @@
1
1
  module Rows
2
- VERSION = "3.1.7" # 2024-12-10
2
+ VERSION = "3.2.1" # 2025-06-23
3
+ # VERSION = "3.2.0" # 2025-02-10
4
+ # VERSION = "3.1.7" # 2024-12-10
3
5
  # VERSION = "3.1.6" # 2024-09-07
4
6
  # VERSION = "3.1.5" # 2024-02-18
5
7
  # VERSION = "3.1.4" # 2024-02-18
metadata CHANGED
@@ -1,13 +1,13 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: rows_controller
3
3
  version: !ruby/object:Gem::Version
4
- version: 3.2.0
4
+ version: 3.2.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Dittmar Krall
8
8
  bindir: bin
9
9
  cert_chain: []
10
- date: 2025-02-10 00:00:00.000000000 Z
10
+ date: 1980-01-02 00:00:00.000000000 Z
11
11
  dependencies:
12
12
  - !ruby/object:Gem::Dependency
13
13
  name: bundler
@@ -37,20 +37,6 @@ dependencies:
37
37
  - - ">="
38
38
  - !ruby/object:Gem::Version
39
39
  version: '0'
40
- - !ruby/object:Gem::Dependency
41
- name: appraisal
42
- requirement: !ruby/object:Gem::Requirement
43
- requirements:
44
- - - ">="
45
- - !ruby/object:Gem::Version
46
- version: '0'
47
- type: :development
48
- prerelease: false
49
- version_requirements: !ruby/object:Gem::Requirement
50
- requirements:
51
- - - ">="
52
- - !ruby/object:Gem::Version
53
- version: '0'
54
40
  - !ruby/object:Gem::Dependency
55
41
  name: combustion
56
42
  requirement: !ruby/object:Gem::Requirement
@@ -125,14 +111,14 @@ required_ruby_version: !ruby/object:Gem::Requirement
125
111
  requirements:
126
112
  - - ">="
127
113
  - !ruby/object:Gem::Version
128
- version: '0'
114
+ version: '3'
129
115
  required_rubygems_version: !ruby/object:Gem::Requirement
130
116
  requirements:
131
117
  - - ">="
132
118
  - !ruby/object:Gem::Version
133
119
  version: '0'
134
120
  requirements: []
135
- rubygems_version: 3.6.2
121
+ rubygems_version: 4.0.3
136
122
  specification_version: 4
137
123
  summary: RowsController DRYs your controllers.
138
124
  test_files: []