active_preview 0.1.2 → 0.1.3

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: 889b89b88ed0233e99903e3476854a4ac7b0b0c0d46da07df3f6a5221bcb57d7
4
- data.tar.gz: 4396bc99b473040e8e01997874d59219b06e81a5a37fce73f48e9abdc26747b1
3
+ metadata.gz: 0e596b87c4f53216ef8eb93e095da11fff8399f39f0d7eafa5b9aa1d08db2392
4
+ data.tar.gz: '049cbc159cbbcd5f11843704e2f68b9f84c29f41d0a9918a8fd63aebdb4ffcc1'
5
5
  SHA512:
6
- metadata.gz: 7018167fdb991cdd0b1a35e9e8977cdea558fe752f30ea95ea02ecfb6c7cce4311b332670158cc9d14dda12078d7988e3b5ea6ccf78014be314c6a0fa4906dde
7
- data.tar.gz: 9b14a4d453741b1519724a7c3d9fa0492c3c6cef05f973a4f12f940cbcedfd6898a5cde168be8a2a59fa14c3af5c094f1160919a7cabe3d45f07e0c1d1e4cf21
6
+ metadata.gz: f5e499eb31f2668b5f5ed2e9fb907e2f012cb8fd409ab0a367095e342468872c4bdf98f8dae2b3086876eeb4e5e37dfef379d237a04e728c909beab0b5a3790d
7
+ data.tar.gz: 6ec6c1ae20d3130bf15680f7a5473f88c59f88bd5a9730ce4d38a12d2c39543c17acc05b7dabf5b3d5d497c8c8c52b5512e77537eadb4d449affa02f8b0ca011
@@ -56,8 +56,8 @@ module ActivePreview
56
56
  saved = model.send(association).order(:id)
57
57
  child_klass = class_of_association(base_class: klass,
58
58
  association: association)
59
- BatchPreviewBuilder.build(klass: child_klass, saved_models: saved,
60
- params: child_params, parent: preview)
59
+ BatchBuilder.build(klass: child_klass, saved_models: saved,
60
+ params: child_params, parent: preview)
61
61
  end
62
62
 
63
63
  def associate_parent
@@ -73,9 +73,8 @@ module ActivePreview
73
73
  next if updated_associations.include?(a)
74
74
  saved = [*model.send(a)]
75
75
  next if saved.empty?
76
- to_assign = BatchPreviewBuilder.build(klass: saved.first.class,
77
- saved_models: saved,
78
- parent: preview)
76
+ to_assign = BatchBuilder.build(klass: saved.first.class,
77
+ saved_models: saved, parent: preview)
79
78
  to_assign = to_assign.first if singular? a
80
79
  preview.send("#{a}=", to_assign)
81
80
  end
@@ -3,7 +3,7 @@ module ActivePreview
3
3
  extend ActiveSupport::Concern
4
4
 
5
5
  def preview(params)
6
- PreviewBuilder.build(model: self, params: params)
6
+ Builder.build(model: self, params: params)
7
7
  end
8
8
  end
9
9
  end
@@ -1,3 +1,3 @@
1
1
  module ActivePreview
2
- VERSION = "0.1.2"
2
+ VERSION = "0.1.3"
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: active_preview
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.2
4
+ version: 0.1.3
5
5
  platform: ruby
6
6
  authors:
7
7
  - Syd Young