mumuki-domain 9.2.0 → 9.2.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/app/models/exercise.rb +7 -2
- data/lib/mumuki/domain/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 1f51de9222a3fb2a4f3a4e1f8498d90baf49b4b47b87662193510a601e5c7905
|
4
|
+
data.tar.gz: b12cf9c00c8b1a2e77e5f758205c89874de9c94e2e5ee8ac3f30f39f6210f272
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: d7ec4c49f78dde3d0422309cf38db8049909eba137b0d4c0ea6b0a27a5d7b475139a351e9c2e272771f9e2b8b59c42c00395511050e3c424369b118b3b23e3d6
|
7
|
+
data.tar.gz: 3bc5e9b62d860e7ec0092352be7ae556ae93c19a2e4173667e3ed8ff3576de8a2bd6bf07128808c64a3ad791c06d8bb358ddfe8d248766b08a3eb1ab54ad51b0
|
data/app/models/exercise.rb
CHANGED
@@ -29,7 +29,7 @@ class Exercise < ApplicationRecord
|
|
29
29
|
defaults { self.submissions_count = 0 }
|
30
30
|
|
31
31
|
def self.default_scope
|
32
|
-
where(manual_evaluation: false) if
|
32
|
+
where(manual_evaluation: false) if hide_manual_evaluation?
|
33
33
|
end
|
34
34
|
|
35
35
|
alias_method :progress_for, :assignment_for
|
@@ -256,6 +256,10 @@ class Exercise < ApplicationRecord
|
|
256
256
|
layouts.keys[0]
|
257
257
|
end
|
258
258
|
|
259
|
+
def self.hide_manual_evaluation?
|
260
|
+
Organization.safe_current&.prevent_manual_evaluation_content
|
261
|
+
end
|
262
|
+
|
259
263
|
def self.with_pending_assignments_for(user, relation)
|
260
264
|
relation.
|
261
265
|
joins("left join assignments assignments
|
@@ -266,6 +270,7 @@ class Exercise < ApplicationRecord
|
|
266
270
|
#{Mumuki::Domain::Status::Submission::Passed.to_i},
|
267
271
|
#{Mumuki::Domain::Status::Submission::ManualEvaluationPending.to_i}
|
268
272
|
)").
|
269
|
-
where('assignments.id is null')
|
273
|
+
where('assignments.id is null').
|
274
|
+
where(('exercises.manual_evaluation = false' if hide_manual_evaluation?))
|
270
275
|
end
|
271
276
|
end
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: mumuki-domain
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 9.2.
|
4
|
+
version: 9.2.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Franco Leonardo Bulgarelli
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2021-05-
|
11
|
+
date: 2021-05-11 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: rails
|