readymade 0.2.0 → 0.2.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 CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: bf49169463a122cc9e591dbf0bfa5933c9cac537368da20cc4917b29751658cc
4
- data.tar.gz: 77a1e8ada0ef9dcbf71e646ba50dbfadf88b5d2ea7ab5fc5a0a4facd555748f1
3
+ metadata.gz: 7626ae0687a31a055b912eaa725f049317bc44c38f18ff51b060f71ac188afba
4
+ data.tar.gz: 49de3d0d889bf1ab67e1f424f1c9421b47378e2f5ed10ce6c5cb3e261fcc1e92
5
5
  SHA512:
6
- metadata.gz: 9d1d70fabd566948f6f0993aed6a4446a1259810a53e826809fe752cccfa08cd9654619bbae7316c6a427db23815edc3703c56f727c53808f91f8b0326fc19fa
7
- data.tar.gz: 84aa64e32f1e6465a24734947777507884b6227d2d3e6054b24781f01e609c8a4a7eb02fcc6c59837d8138947f0f6318f6b74e4576d7b37068a3f75351a65273
6
+ metadata.gz: 8775ea40ef291da68cbd8e3527bfc5202a29b30a3664b80649070b288d29c92befb6e596ddcc5a81a8b8ef8af32db6f76302576f1a1a405b3fc2121bdbf54fc3
7
+ data.tar.gz: 8cbcf0794b7ad7597f306cc885479afd61ee1eabb030770d2610f776218e2b005a1b3397e65064bdd00181aab1af8abe91c783575c1b29e54c6ba9296d212de4
data/CHANGELOG.md CHANGED
@@ -1,6 +1,12 @@
1
1
  Changelog
2
2
  All notable changes to this project will be documented in this file.
3
3
 
4
+ ## [0.2.1] - 2022-04-21
5
+
6
+ ### Improvements
7
+
8
+ * Update collection_response controller helper
9
+
4
10
  ## [0.2.0] - 2022-04-13
5
11
 
6
12
  ### Improvements
data/Gemfile.lock CHANGED
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- readymade (0.2.0)
4
+ readymade (0.2.1)
5
5
 
6
6
  GEM
7
7
  remote: https://rubygems.org/
data/README.md CHANGED
@@ -1,12 +1,12 @@
1
- # Readymade 0.1.8
1
+ # Readymade 0.2.1
2
2
 
3
3
  This gems contains basic components to follow [ABDI architecture](https://github.com/OrestF/OrestF/blob/master/abdi/ABDI_architecture.md)
4
4
 
5
5
  ### Tested with ruby:
6
6
 
7
- - 2.7
8
- - 3.0
9
7
  - 3.1
8
+ - 3.0
9
+ - 2.7
10
10
 
11
11
  ## Installation
12
12
 
@@ -38,7 +38,7 @@ Inherit your components from:
38
38
  ```ruby
39
39
  response = Readymade::Response.new(:success, my_data: data)
40
40
  response.success? # true
41
- response =Readymade::Response.new(:fail, errors: errors)
41
+ response = Readymade::Response.new(:fail, errors: errors)
42
42
  response.success? # false
43
43
  response.fail? # true
44
44
  response.status # 'fail'
@@ -25,7 +25,7 @@ module Readymade
25
25
 
26
26
  render_json(
27
27
  {
28
- items: serialize_collection(paginate(collection, options), options),
28
+ (options.delete(:root).presence || :items) => serialize_collection(paginate(collection, options), options),
29
29
  count: collection.count
30
30
  },
31
31
  options[:status] || :ok
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module Readymade
4
- VERSION = '0.2.0'
4
+ VERSION = '0.2.1'
5
5
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: readymade
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.0
4
+ version: 0.2.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - OrestF
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2022-04-13 00:00:00.000000000 Z
11
+ date: 2022-04-21 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: byebug