rhino_project_core 0.22.0.beta.3 → 0.22.0.beta.5
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:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 5a2ab53fa629af87782ad13972070920c48a8fae2fc3d9988abc7ade286b2f58
|
4
|
+
data.tar.gz: f16a39aa3e229b5eee2c357517f2731174b7649b09acf411133d863899a73d2c
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: de129122de6f46a98590b6fdc1d786952f74d71e6023bbf1e5d88b8232f7caf2849db6c4947792dab6bc23feaa31d82bfabafe3744e13402944795868c200614
|
7
|
+
data.tar.gz: 4aacbd42bfdb8b3c28e152daddc789966112b0acaf6aebd388882c60b915512b8c0908ca02182cadde72e9d65ebd9ad68bad73e4d1a3d457aa93f623f0a9b3ce
|
@@ -24,7 +24,7 @@ module Rhino
|
|
24
24
|
@models = klass.sieves.resolve(policy_scope(klass), params)
|
25
25
|
render json: {
|
26
26
|
results: @models.eager_load_refs.map { |m| permit_model(m) },
|
27
|
-
total: @models.unscope(:limit, :offset).reselect(
|
27
|
+
total: @models.unscope(:limit, :offset).reselect(klass.primary_key).count
|
28
28
|
}
|
29
29
|
end
|
30
30
|
|
@@ -48,7 +48,7 @@ module Rhino
|
|
48
48
|
return if global_owner?
|
49
49
|
|
50
50
|
inject_into_file model_file, after: /#{owner_call}/ do
|
51
|
-
"\n rhino_references %i[#{reference_attributes.map(&:name).join(' ')}]
|
51
|
+
"\n rhino_references %i[ #{reference_attributes.map(&:name).join(' ')} ]"
|
52
52
|
end
|
53
53
|
end
|
54
54
|
|
data/lib/rhino/sieve/filter.rb
CHANGED
@@ -13,7 +13,7 @@ module Rhino
|
|
13
13
|
|
14
14
|
filter = params[:filter].permit!.to_h
|
15
15
|
scope = scope.joins(get_joins(scope.klass, filter))
|
16
|
-
query = apply_filters(scope, scope.klass, filter).distinct(
|
16
|
+
query = apply_filters(scope, scope.klass, filter).distinct(scope.klass.primary_key)
|
17
17
|
@app.resolve(query, params)
|
18
18
|
end
|
19
19
|
|
data/lib/rhino/sieve/order.rb
CHANGED
@@ -13,7 +13,7 @@ module Rhino
|
|
13
13
|
@param = params[:order]
|
14
14
|
|
15
15
|
# Always append id to the end of the order clause to ensure a stable sort for pagination
|
16
|
-
result = apply_order.order(
|
16
|
+
result = apply_order.order(scope.primary_key)
|
17
17
|
@app.resolve(result, params)
|
18
18
|
end
|
19
19
|
|
data/lib/rhino/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: rhino_project_core
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.22.0.beta.
|
4
|
+
version: 0.22.0.beta.5
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- JP Rosevear
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2024-
|
11
|
+
date: 2024-12-06 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: rails
|
@@ -330,14 +330,14 @@ dependencies:
|
|
330
330
|
requirements:
|
331
331
|
- - '='
|
332
332
|
- !ruby/object:Gem::Version
|
333
|
-
version:
|
333
|
+
version: 2.0.2
|
334
334
|
type: :runtime
|
335
335
|
prerelease: false
|
336
336
|
version_requirements: !ruby/object:Gem::Requirement
|
337
337
|
requirements:
|
338
338
|
- - '='
|
339
339
|
- !ruby/object:Gem::Version
|
340
|
-
version:
|
340
|
+
version: 2.0.2
|
341
341
|
- !ruby/object:Gem::Dependency
|
342
342
|
name: rake
|
343
343
|
requirement: !ruby/object:Gem::Requirement
|