Update master prior to v3.1.1#3174
Merged
Merged
Conversation
DCC Issue https://github.com/DigitalCurationCentre/DMPonline-Service/issues/698 Changes: - added format: json and changed sort option to sort_field: 'templates.version', sort_direction: :desc to the paginable_renderise call in the history() method of paginable/templates_controller.
Referenced in a comment in DCC bug 698 https://github.com/DigitalCurationCentre/DMPonline-Service/issues/698#issuecomment-1096577463 Fix involved following change: - in app/policies/department_policy the index?() policy method reference @department (which does not exist). Even changing @department to @record fails as @record is the Department class (not an instance of Department). Inspect of @record in index?() shows "Department(id: integer, name: string, code: string, org_id: integer, created_at: datetime, updated_at: datetime)". So replaced (@user.can_org_admin? && @user.org.id == @department.org_id) || @user.can_super_admin? by @user.can_org_admin? || @user.can_super_admin? as @department is nil and @record.org_id id not defined for a Class object Department.
…_view_all_broken DCC Bug 698 - Fix for broken Template History functionality.
…rtments_broken Referenced in DCC Bug 698 - The School departments functionality broken.
Fix the 'expand/collapse button not work on after creating multiple sections on org_admin/template section
DCC issue https://github.com/DigitalCurationCentre/DMPonline-Service/issues/703 Problem is that in concerns/exportable_plan.rb the method prepare_coversheet_for_csv(csv, _headings, hash) assumes hash[:attribution] is an ActiveRecord::Relation when it is always a string with a single author created in prepare_coversheet() method. Hence hash[:attribution].many? throws an error in csv << [if hash[:attribution].many?. Changes for fix: - in prepare_coversheet_for_csv(csv, _headings, hash) added csv << [_('Creator:'), format(_('%{author}'), author: hash[:attribution])] instead and removed csv << [if hash[:attribution].many?...]
remove margin settings from PDF stylesheet and set initial zoom level…
…_plan_page DCC bug 406 - Download plan with coversheet is broken.
"/api/v0/plans?page=ALL" was timing out because the processing was taking too long. Fix for bug https://github.com/DigitalCurationCentre/DMPonline-Service/issues/722 The following change seems to make a difference: - in /api/v0/plans_controller.rb the index() method replaced includes() with preload(): @plans = org_admin_plans.includes([{ roles: :user }, { answers: :question_options }, template: [{ phases: { sections: { questions: %i[question_format themes] } } }, :org]])
…ans_call_timing_out DCC bug 722 - Fix for dealing with situation where Rest API call
…o disappear." Cause is commit bb5941e "Added toggleable guidance/comments section" the following changes were made to file app/javascript/src/utils/sectionUpdate.js: the question containers classes were changed as follows .row -> .question-body & .col-md-8 -> .question-section: - <div class="row"> - <div class="col-md-8"> + <div class="question-body"> + <div class="question-section"> This broke the function getQuestionDiv() in app/javascript/src/utils/sectionUpdate.js. Fix for issue #3163. Changes: - in app/javascript/src/utils/sectionUpdate.js the function was updated as follows: -export const getQuestionDiv = (id) => $(`#answer-form-${id}`).closest('.row'); +export const getQuestionDiv = (id) => $(`#answer-form-${id}`).closest('.question-body');
fix font face of pdf download
…g_plans_display_none
…ns_causing_plans_display_none Roadmap bug #3163 - Fix for bug "Conditional question causing plans …
Add array judgement for creators in text and csv download
download. Fix for Roadmap issue #3104. Changes: - added <%= option.is_default? ? ' - ' + _('default') : '' %> to option text in export template in docx and pdf.
…_answers_do_not_download Bug #3104 - Fix for pre-ticked answers do not appear in Template
one could only share plan if it is 100% completed. When this is set in property config/initializers/_dmproadmap.rb, e.g., 188: config.x.plans.default_percentage_answered = 50. Fix for Roadmap bug #3086. In app/models/phase.rb method visibility_allowed?(plan) is broken because the first line in method always return 0 unless the Rational() is 1 in value = Rational(num_answered_questions(plan), plan.num_questions) * 100 Change: - we fix issue by converting the Rational() value to a float as follows value = Rational(num_answered_questions(plan), plan.num_questions).to_f * 100
…ity_plan_public_DMPs_only_appear_if_100_per_filled Roadmap bug 3086 - The share feature for Org plan visibility was broken:
metadata standard does not always have locations
This file contains hidden or 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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary of fixes: