mumuki-domain 7.9.1 → 7.9.2
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:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 0ebe5d37552a117a8d4ee657170a55eefdea340126a6b44f4a31b670420029b4
|
|
4
|
+
data.tar.gz: 8efe4d2b2e478ee887d7c346031e2b0fc87ea3c243991e6cd8d42909c1b361aa
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: ac6768c2f693a49e9d9d63e4c5c55100d98705edd6e4141b49c69c63078a7a72d7b843be81f289f1ea1770abc464bfa365f4895efa79e7caae2504abadac0db8
|
|
7
|
+
data.tar.gz: 12b89e6ebf0e13bcdb0634eb18abfb96bb816296a482503fe504ad54860993a87b93337593fb9e77a7437907dc88ae1d30916dc104e3d8f4f250ab8272fbef7a
|
data/app/models/assignment.rb
CHANGED
|
@@ -42,6 +42,7 @@ class Assignment < Progress
|
|
|
42
42
|
alias_method :parent_content, :guide
|
|
43
43
|
alias_method :user, :submitter
|
|
44
44
|
|
|
45
|
+
after_initialize :set_default_top_submission_status
|
|
45
46
|
before_save :award_experience_points!, :update_top_submission!, if: :submission_status_changed?
|
|
46
47
|
after_save :dirty_parent_by_submission!, if: :completion_changed?
|
|
47
48
|
before_validation :set_current_organization!, unless: :organization
|
|
@@ -51,6 +52,10 @@ class Assignment < Progress
|
|
|
51
52
|
self.organization = Organization.current
|
|
52
53
|
end
|
|
53
54
|
|
|
55
|
+
def set_default_top_submission_status
|
|
56
|
+
self.top_submission_status ||= 0
|
|
57
|
+
end
|
|
58
|
+
|
|
54
59
|
def completion_changed?
|
|
55
60
|
completed_before_last_save? != completed?
|
|
56
61
|
end
|
|
@@ -32,11 +32,11 @@ class Mumuki::Domain::Organization::Settings < Mumukit::Platform::Model
|
|
|
32
32
|
end
|
|
33
33
|
|
|
34
34
|
def disabled_from=(disabled_from)
|
|
35
|
-
@disabled_from = disabled_from
|
|
35
|
+
@disabled_from = disabled_from&.to_time
|
|
36
36
|
end
|
|
37
37
|
|
|
38
38
|
def in_preparation_until=(in_preparation_until)
|
|
39
|
-
@in_preparation_until = in_preparation_until
|
|
39
|
+
@in_preparation_until = in_preparation_until&.to_time
|
|
40
40
|
end
|
|
41
41
|
|
|
42
42
|
def disabled?
|
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: 7.9.
|
|
4
|
+
version: 7.9.2
|
|
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: 2020-09-
|
|
11
|
+
date: 2020-09-17 00:00:00.000000000 Z
|
|
12
12
|
dependencies:
|
|
13
13
|
- !ruby/object:Gem::Dependency
|
|
14
14
|
name: rails
|