mumuki-classroom 9.0.0 → 9.3.0
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: 1c52ddd69280576cfbe86800891c56a355b3618991b5f709b19a9d0f502eb976
|
4
|
+
data.tar.gz: 1749aaae4be5d8c350bbb2707f7a7f5602e65e8fe96f22e9672a11b95025bd54
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 13201c8103505af9ff5700c0395ff4f463e335f99bd7025375fdceef3d8935d89b124a9761143bcc61ef1251d11e24f754090503488700df3584e1cabc30183b
|
7
|
+
data.tar.gz: 45b0dc56a36e3cedfd1da37b355bc5ec2e39642e331b8b3e303ca4e4423ad68e88fc1440b7f0b765bf2c236b3d249e7b7b06e43222b8749158b30071b07fb31b
|
@@ -17,8 +17,8 @@ module Reporting
|
|
17
17
|
main_pipeline << {'$match': query}
|
18
18
|
main_pipeline.concat searching.pipeline
|
19
19
|
main_pipeline.concat sorting.pipeline
|
20
|
-
main_pipeline << {'$project': projection}
|
21
20
|
main_pipeline << {'$sort': sorting.order_by(ordering)}
|
21
|
+
main_pipeline << {'$project': projection}
|
22
22
|
end
|
23
23
|
|
24
24
|
end
|
@@ -2,7 +2,7 @@ module Sorting
|
|
2
2
|
|
3
3
|
def self.aggregate(collection, query, paginated_params, query_params)
|
4
4
|
reporting_pipeline = Reporting.build_pipeline(collection, query, paginated_params, query_params, projection)
|
5
|
-
query = collection.collection.aggregate(pipeline
|
5
|
+
query = collection.collection.aggregate(pipeline(paginated_params, reporting_pipeline), allow_disk_use: true).first # Must allow disk use for sorting large collections by non-index
|
6
6
|
query_results(query)
|
7
7
|
end
|
8
8
|
|
@@ -1,8 +1,18 @@
|
|
1
1
|
class Mumuki::Classroom::App < Sinatra::Application
|
2
2
|
Mumukit::Platform.map_organization_routes!(self) do
|
3
|
+
helpers do
|
4
|
+
def list_teachers(matcher)
|
5
|
+
authorize! :headmaster
|
6
|
+
{teachers: Mumuki::Classroom::Teacher.where(matcher).as_json}
|
7
|
+
end
|
8
|
+
end
|
9
|
+
|
10
|
+
get '/teachers' do
|
11
|
+
list_teachers with_organization
|
12
|
+
end
|
13
|
+
|
3
14
|
get '/courses/:course/teachers' do
|
4
|
-
|
5
|
-
{teachers: Mumuki::Classroom::Teacher.where(with_organization_and_course).as_json}
|
15
|
+
list_teachers with_organization_and_course
|
6
16
|
end
|
7
17
|
|
8
18
|
post '/courses/:course/teachers' do
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: mumuki-classroom
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 9.
|
4
|
+
version: 9.3.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Franco Bulgarelli
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2021-
|
11
|
+
date: 2021-05-13 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: rails
|
@@ -86,14 +86,14 @@ dependencies:
|
|
86
86
|
requirements:
|
87
87
|
- - "~>"
|
88
88
|
- !ruby/object:Gem::Version
|
89
|
-
version: 9.
|
89
|
+
version: 9.3.0
|
90
90
|
type: :runtime
|
91
91
|
prerelease: false
|
92
92
|
version_requirements: !ruby/object:Gem::Requirement
|
93
93
|
requirements:
|
94
94
|
- - "~>"
|
95
95
|
- !ruby/object:Gem::Version
|
96
|
-
version: 9.
|
96
|
+
version: 9.3.0
|
97
97
|
- !ruby/object:Gem::Dependency
|
98
98
|
name: mumukit-login
|
99
99
|
requirement: !ruby/object:Gem::Requirement
|
@@ -222,6 +222,7 @@ files:
|
|
222
222
|
- LICENSE
|
223
223
|
- README.md
|
224
224
|
- Rakefile
|
225
|
+
- config/initializers/inflections.rb
|
225
226
|
- lib/mumuki/classroom.rb
|
226
227
|
- lib/mumuki/classroom/collection.rb
|
227
228
|
- lib/mumuki/classroom/engine.rb
|