-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
ER-764 Remove deprecated non-CMS files (#774)
* - Retire unused libraries, content, environment variables, tests, and code - Add missing specs, correct inaccurate specs and boost coverage over 90% - Rename methods and objects to be semantic and consistent - Refactor helpers and controllers simplifying logic - Dry up training controllers moving common logic into a module - Prune, consolidate and organise locales for fewer microcopy resources - Update documentation, pipelines, docker and linting exemptions - Replace remaining ActiveHash objects - Namespace new models used in the registration journey - Add migration and seeding task for CMS powered user setting options - Add setting, role and authority data debugging panel - Make verbose console output optional * Extra relevant user journey tickets * Retest using genuine content * Revert to demo content in review
- Loading branch information
1 parent
ea243e5
commit 33b5bed
Showing
373 changed files
with
2,322 additions
and
22,940 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,32 +1,47 @@ | ||
# | ||
# OPTIMIZE: potentially dry-er course content controllers | ||
# | ||
module Learning | ||
# def mod_name | ||
# params[:training_module_id] | ||
# end | ||
# @return [String] | ||
def mod_name | ||
params[:training_module_id] | ||
end | ||
|
||
# def content_name | ||
# params[:id] | ||
# end | ||
# @return [String] | ||
def content_name | ||
params[:id] | ||
end | ||
|
||
# def mod | ||
# Training::Module.by_name(mod_name) | ||
# end | ||
# @return [Training::Module] | ||
def mod | ||
Training::Module.by_name(mod_name) | ||
end | ||
|
||
# def content | ||
# mod.page_by_name(content_name) | ||
# end | ||
# @return [Training::Page, Training::Video, Training::Question] | ||
def content | ||
mod.page_by_name(content_name) | ||
end | ||
|
||
# def module_progress | ||
# ContentfulModuleOverviewDecorator.new(progress) | ||
# end | ||
# @return [ModuleOverviewDecorator] | ||
def module_progress | ||
ModuleOverviewDecorator.new(progress_service) | ||
end | ||
|
||
# def progress_bar | ||
# ContentfulModuleProgressBarDecorator.new(progress) | ||
# end | ||
# @return [ModuleProgressBarDecorator] | ||
def progress_bar | ||
ModuleProgressBarDecorator.new(progress_service) | ||
end | ||
|
||
# def progress | ||
# helpers.cms_module_progress(mod) | ||
# end | ||
# @return [AssessmentProgress] | ||
def assessment | ||
helpers.assessment_progress_service(mod) | ||
end | ||
|
||
# @return [ModuleProgress] | ||
def progress_service | ||
helpers.module_progress_service(mod) | ||
end | ||
|
||
# @note memoization ensures validation errors work | ||
# @return [UserAnswer, Response] | ||
def current_user_response | ||
@current_user_response ||= current_user.response_for(content) | ||
end | ||
end |
Oops, something went wrong.