Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Bugfix/empro withdrawn card text #4344

Merged
merged 2 commits into from
Oct 11, 2023
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
29 changes: 17 additions & 12 deletions portal/eproms/templates/eproms/assessment_engine/ae_macros.html
Original file line number Diff line number Diff line change
Expand Up @@ -95,21 +95,26 @@ <h4 class="portal-description-title">
{%- call render_card_content(
title_text=_("%(substudy_title)s Questionnaire", substudy_title=substudy_title),
card_class="portal-description-incomplete" if substudy_assessment_is_ready else "disabled") -%}
{%- if not substudy_assessment_is_ready -%}
{%- if substudy_due_date -%}
<div class="text-content">{{_("Your %(substudy_title)s questionnaire is due on %(substudy_due_date)s. Please complete your open %(registry)s questionnaire first, to activate this one. Thank you for participating.",
substudy_title=substudy_title,
substudy_due_date=substudy_due_date,
registry=_(assessment_status.assigning_authority))}}</div>
{%- if substudy_assessment_status.overall_status == OverallStatus.withdrawn -%}
<!-- Patient withdrawn, display appropriate text on card -->
<p>{{_("The assessment is no longer available. A research staff member will contact you for assistance.")}}</p>
{%- else -%}
{%- if not substudy_assessment_is_ready -%}
{%- if substudy_due_date -%}
<div class="text-content">{{_("Your %(substudy_title)s questionnaire is due on %(substudy_due_date)s. Please complete your open %(registry)s questionnaire first, to activate this one. Thank you for participating.",
substudy_title=substudy_title,
substudy_due_date=substudy_due_date,
registry=_(assessment_status.assigning_authority))}}</div>
{%- else -%}
<div class="text-content">{{_("Please complete your open %(registry)s questionnaire first, to activate this one. Thank you for participating.",
registry=_(assessment_status.assigning_authority))}}</div>
{%- endif -%}
{%- else -%}
<div class="text-content">{{_("Please complete your open %(registry)s questionnaire first, to activate this one. Thank you for participating.",
registry=_(assessment_status.assigning_authority))}}</div>
<div class="text-content">{{_("Your questionnaire is ready. Please complete by %(substudy_due_date)s. By participating, we'll better understand your experience and offer useful tips and support.", substudy_due_date=substudy_due_date)}}</div>
{%- endif -%}
{%- else -%}
<div class="text-content">{{_("Your questionnaire is ready. Please complete by %(substudy_due_date)s. By participating, we'll better understand your experience and offer useful tips and support.", substudy_due_date=substudy_due_date)}}</div>
{{render_call_to_button(button_label=button_label, button_url=url_for('assessment_engine_api.present_needed'))}}
<!-- display any error if for some reason the assessment is not ready -->
{%- endif -%}
{{render_call_to_button(button_label=button_label, button_url=url_for('assessment_engine_api.present_needed'))}}
<!-- display any error if for some reason the assessment is not ready -->
{%- if substudy_assessment_errors and substudy_assessment_errors|length %}
<div class="error-message">
<span class='glyphicon glyphicon-alert warning icon' aria-hidden='true'></span>
Expand Down
Loading