effective_cpd 0.6.7 → 0.6.9
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/app/controllers/effective/cpd_statements_controller.rb +0 -9
- data/app/views/admin/cpd_cycles/_form_cpd_cycle.html.haml +1 -1
- data/app/views/admin/users/_form_cpd.html.haml +15 -0
- data/app/views/effective/cpd/_dashboard.html.haml +2 -0
- data/lib/effective_cpd/version.rb +1 -1
- metadata +3 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 9fc9c5614b8c87479aef3067320ae4f432255f4214f65d5fb6558cb389c557aa
|
4
|
+
data.tar.gz: 6196e732aaa80aeaf16c8be346d2b28e3fba2251f749bc7038319954cc97d494
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 30b45d45efa81a63adeab41b0da5ce2811e718eb447b77b3419aadddb04b47d01aa9c55d3a71c9615ee56dd19f8a8bfe19b477dd31cc02e2ade811cdbd32038f
|
7
|
+
data.tar.gz: 7af185b1632ff2928c814efca3e8262a4e1c3b366fdbc511cedfecf93e07cadcea7a8da999d4b8d6a18995bffb75f95af0669f5fa384f5d458e4b0ded953b753
|
@@ -14,15 +14,6 @@ module Effective
|
|
14
14
|
CpdScorer.new(user: resource.user).score!
|
15
15
|
end
|
16
16
|
|
17
|
-
# Enforce one statement per user per cycle. Redirect them to an existing statement for this cycle.
|
18
|
-
before_action(only: [:new, :show]) do
|
19
|
-
existing = resource_scope.where.not(id: resource).first
|
20
|
-
|
21
|
-
if existing.present?
|
22
|
-
redirect_to effective_cpd.cpd_cycle_cpd_statement_build_path(existing.cpd_cycle, existing, existing.next_step)
|
23
|
-
end
|
24
|
-
end
|
25
|
-
|
26
17
|
# Enforce cycle availability
|
27
18
|
before_action(only: [:show, :update]) do
|
28
19
|
cycle = resource.cpd_cycle
|
@@ -5,7 +5,7 @@
|
|
5
5
|
= f.date_field :start_at,
|
6
6
|
hint: "The first date statements may be submited for this #{cpd_cycle_label}"
|
7
7
|
|
8
|
-
= f.date_field :end_at,
|
8
|
+
= f.date_field :end_at, date_linked: false,
|
9
9
|
hint: "The last date statements may be created for this #{cpd_cycle_label}. leave blank for no end date."
|
10
10
|
|
11
11
|
= f.number_field :required_score,
|
@@ -0,0 +1,15 @@
|
|
1
|
+
%h2 Statements
|
2
|
+
- datatable = Admin::EffectiveCpdStatementsDatatable.new(user: user)
|
3
|
+
= render_datatable(datatable, inline: true)
|
4
|
+
|
5
|
+
%hr
|
6
|
+
|
7
|
+
%h2 Activities
|
8
|
+
- datatable = Admin::EffectiveCpdStatementActivitiesDatatable.new(user: user)
|
9
|
+
= render_datatable(datatable, inline: true)
|
10
|
+
|
11
|
+
%hr
|
12
|
+
|
13
|
+
%h2 Audits
|
14
|
+
- datatable = Admin::EffectiveCpdAuditsDatatable.new(user: user)
|
15
|
+
= render_datatable(datatable)
|
@@ -18,6 +18,8 @@
|
|
18
18
|
.mt-4
|
19
19
|
%p Please submit a CPD statement for the following available #{cpd_cycles_label}:
|
20
20
|
= render_datatable(available, simple: true)
|
21
|
+
- else
|
22
|
+
%p There are no #{cpd_cycles_label} available to submit. When there are, we'll show them here.
|
21
23
|
|
22
24
|
- completed = EffectiveCpdCompletedStatementsDatatable.new(self)
|
23
25
|
- if completed.present?
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: effective_cpd
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.6.
|
4
|
+
version: 0.6.9
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Code and Effect
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2023-
|
11
|
+
date: 2023-03-03 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: rails
|
@@ -264,6 +264,7 @@ files:
|
|
264
264
|
- app/views/admin/cpd_cycles/_form_cpd_special_rules.html.haml
|
265
265
|
- app/views/admin/cpd_special_rules/_form.html.haml
|
266
266
|
- app/views/admin/cpd_statements/_cpd_statement.html.haml
|
267
|
+
- app/views/admin/users/_form_cpd.html.haml
|
267
268
|
- app/views/effective/cpd/_dashboard.html.haml
|
268
269
|
- app/views/effective/cpd_audit_level_questions/_cpd_audit_level_question.html.haml
|
269
270
|
- app/views/effective/cpd_audit_responses/_cpd_audit_response.html.haml
|