Skip to content

Commit

Permalink
Merge pull request #101 from ministryofjustice/robs-test
Browse files Browse the repository at this point in the history
Added version 2 design for risk and updated content
  • Loading branch information
rwk-moj authored May 5, 2021
2 parents 1f6b6ca + f84fcb7 commit eb4b842
Show file tree
Hide file tree
Showing 4 changed files with 193 additions and 65 deletions.
24 changes: 9 additions & 15 deletions app/views/sprint-12/make-a-referral/3-referral-task-list.html
Original file line number Diff line number Diff line change
Expand Up @@ -21,20 +21,10 @@ <h1 class="govuk-heading-xl">Make a referral

<ol class="moj-task-list">
<li>
{% if data["service-user-details-checked"] %}

<strong class="govuk-tag govuk-tag app-task-list__tag">
in progress
</strong>
{% elseif data["service-user-id"] %}
<strong class="govuk-tag govuk-tag app-task-list__tag">
completed
</strong>
{% else %}
<strong class="govuk-tag govuk-tag--grey app-task-list__tag">
not started
</strong>
{% endif %}

<h2 class="moj-task-list__section">
<span class="moj-task-list__section-number">1.
</span>
Expand All @@ -58,6 +48,7 @@ <h2 class="moj-task-list__section">
</li>
</li>
</ul>


<li>
{% if data["found-interventions"] %}
Expand Down Expand Up @@ -103,7 +94,7 @@ <h2 class="moj-task-list__section">
</strong>
{% else %}
<strong class="govuk-tag govuk-tag--grey app-task-list__tag">
not started
cannot start yet
</strong>
{% endif %}

Expand All @@ -115,7 +106,7 @@ <h2 class="moj-task-list__section">
<ul class="moj-task-list__items">
<li class="moj-task-list__item">
{% if data["found-interventions"] %}
<a class="moj-task-list__task-name" href="risk-information">Details of this part will depend on the services you choose</a >
<a class="moj-task-list__task-name" href="risk-information">Details of this part will depend on the services you choose</a>
{% else %}
<span class="app-task-list__task-name">
Details of this part will depend on the services you choose
Expand All @@ -124,8 +115,11 @@ <h2 class="moj-task-list__section">
</li>
</ul>
</li>
<li>
<strong class="govuk-tag govuk-tag--grey app-task-list__tag">
Cannot start yet
</strong>


<h2 class="moj-task-list__section">
<span class="moj-task-list__section-number">4.
</span>
Expand All @@ -147,7 +141,7 @@ <h2 class="moj-task-list__section">
<li>
{% if data["social-inclusion-more-information-completed"] and data["accommodation-more-info-completed"] and data["responsible-officer-information-completed"] %}
<strong class="govuk-tag govuk-tag--grey app-task-list__tag">
not started
cannot start yet
</strong>
{% else %}
<strong class="govuk-tag govuk-tag--grey app-task-list__tag">
Expand Down
32 changes: 0 additions & 32 deletions app/views/sprint-12/make-a-referral/4-service-user-details.html
Original file line number Diff line number Diff line change
Expand Up @@ -92,38 +92,6 @@ <h2 class="govuk-heading-l">Service user information</h2>
Flat 2<br>27 Test Walk<br>SY16 1AQ<br><br>Private rental
</dd>
</div>
<div class="govuk-summary-list__row">
<dt class="govuk-summary-list__key govuk-!-width-one-third">
OGRS score
</dt>
<dd class="govuk-summary-list__value">
50
</dd>
</div>
<div class="govuk-summary-list__row">
<dt class="govuk-summary-list__key govuk-!-width-one-third">
ROSHA score
</dt>
<dd class="govuk-summary-list__value">
Medium
</dd>
</div>
<div class="govuk-summary-list__row">
<dt class="govuk-summary-list__key govuk-!-width-one-third">
RM2000 score
</dt>
<dd class="govuk-summary-list__value">
Medium
</dd>
</div>
<div class="govuk-summary-list__row">
<dt class="govuk-summary-list__key govuk-!-width-one-third">
SARA score
</dt>
<dd class="govuk-summary-list__value">
Low
</dd>
</div>
<div class="govuk-summary-list__row">
<dt class="govuk-summary-list__key govuk-!-width-one-third">
Needs
Expand Down
37 changes: 19 additions & 18 deletions app/views/sprint-12/make-a-referral/5-risk-information.html
Original file line number Diff line number Diff line change
Expand Up @@ -49,8 +49,8 @@ <h1 class="govuk-heading-xl">
text: "Low"
},
{
value: "no-information",
text: "No information available",
value: "please-select",
text: "Please select",
selected: true
}
]
Expand All @@ -66,20 +66,20 @@ <h1 class="govuk-heading-xl">
items: [
{
value: "high",
text: "High",
selected: true
text: "High"
},
{
value: "medium",
text: "Medium"
text: "Medium",
selected: true
},
{
value: "low",
text: "Low"
},
{
value: "no-information",
text: "No information available"
value: "please-select",
text: "Please select"
}
]
}) }}
Expand All @@ -106,16 +106,16 @@ <h1 class="govuk-heading-xl">
},
{
value: "medium",
text: "Medium",
selected: true
text: "Medium"
},
{
value: "low",
text: "Low"
text: "Low",
selected: true
},
{
value: "no-information",
text: "No information available"
value: "please-select",
text: "Please select"
}
]
}) }}
Expand All @@ -142,8 +142,8 @@ <h1 class="govuk-heading-xl">
selected: true
},
{
value: "no-information",
text: "No information available"
value: "please-select",
text: "Please select"
}
]
}) }}
Expand All @@ -170,8 +170,8 @@ <h1 class="govuk-heading-xl">
text: "Low"
},
{
value: "no-information",
text: "No information available"
value: "please-select",
text: "Please select"
}
]
}) }}
Expand All @@ -184,9 +184,10 @@ <h1 class="govuk-heading-xl">
</div>
</div>
</div>

<div class="govuk-grid-column-one-third">
<p class="govuk-body"><a href="5a-risk-information" title="Version 2 of risk design">Version 2</a></p>
</div>
</div>

<div class="govuk-grid-row">
<div class="govuk-grid-column-two-thirds">
<form action="6-needs-and-requirements" method="post" class="form">
Expand Down
165 changes: 165 additions & 0 deletions app/views/sprint-12/make-a-referral/5a-risk-information.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,165 @@
{% extends "layout.html" %}

{% block pageTitle %}
Risk information
{% endblock %}

{% block header %}
{{ super() }}
{% set currentPage = "make-a-referral" %}
{% include "../includes/primary-navigation.html" %}
{% endblock %}

{% block beforeContent %}
{{ govukBackLink({
text: "Back",
href: "javascript: window.history.go(-1)"
}) }}
{% endblock %}

{% block content %}
<div class="govuk-grid-row">
<div class="govuk-grid-column-two-thirds">
<h1 class="govuk-heading-xl">
Alex's risk information
</h1>
<p class="gov-uk-body">Here are Alex’s risks as captured in OASys. This is what the service provider will see. In case you consider any of them to be out of date, please select a score that better represents the current level of risk.</p>
<p class="gov-uk-body">Note: Any updates to risk information will not be captured in OASys and an assessment will need to be completed.</p>

<h2 class="govuk-heading-m">Risk to adult</h2>
<p>
<strong class="govuk-tag govuk-tag--red">
High
</strong>
<a href="#">Edit risk</a>
<div class="govuk-form-group">
<label class="govuk-label" for="more-detail">
Additional information for the provider about Alex’s risks
</label>
<textarea class="govuk-textarea" id="more-detail" name="more-detail" rows="5"></textarea>
</div>
</p>
<h2 class="govuk-heading-m">Risk to public</h2>
<p>
<strong class="govuk-tag govuk-tag--green">
Low
</strong>
<a href="#">Edit risk</a>
<div class="govuk-form-group">
<label class="govuk-label" for="more-detail">
Additional information for the provider about Alex’s risks
</label>
<textarea class="govuk-textarea" id="more-detail" name="more-detail" rows="5"></textarea>
</div>
</p>
<h2 class="govuk-heading-m">Risk to children</h2>
<p>
<strong class="govuk-tag govuk-tag--orange">
Medium
</strong>
<a href="#">Edit risk</a>
<div class="govuk-form-group">
<label class="govuk-label" for="more-detail">
Additional information for the provider about Alex’s risks
</label>
<textarea class="govuk-textarea" id="more-detail" name="more-detail" rows="5"></textarea>
</div>
</p>
<h2 class="govuk-heading-m">Risk of self harm</h2>
<p>
<strong class="govuk-tag govuk-tag--orange">
Medium
</strong>
<a href="#">Edit risk</a>
<div class="govuk-form-group">
<label class="govuk-label" for="more-detail">
Additional information for the provider about Alex’s risks
</label>
<textarea class="govuk-textarea" id="more-detail" name="more-detail" rows="5"></textarea>
</div>
</p>
<h2 class="govuk-heading-m">Risk to staff</h2>
<p>
<strong class="govuk-tag govuk-tag--green">
Low
</strong>
<details class="govuk-details" data-module="govuk-details">
<summary class="govuk-details__summary">
<span class="govuk-details__summary-text">
Change risk score
</span>
</summary>
{{ govukRadios({
idPrefix: "where-do-you-live",
name: "where-do-you-live",
fieldset: {
legend: {
text: "Where do you live?",
isPageHeading: true,
classes: "govuk-fieldset__legend--s"
}
},
items: [
{
value: "high",
text: "High"
},
{
value: "medium",
text: "medium"
},
{
value: "low",
text: "low"
}
]
}) }}
</details>
<div class="govuk-form-group">
<label class="govuk-label" for="more-detail">
Additional information for the provider about Alex’s risks
</label>
<textarea class="govuk-textarea" id="more-detail" name="more-detail" rows="5"></textarea>
</div>
</p>
</div>
<div class="govuk-grid-column-one-third">
<p class="govuk-body"><a href="5-risk-information" title="Version 2 of risk design">Version 1</a></p>
</div>
</div>

<div class="govuk-grid-row">
<div class="govuk-grid-column-two-thirds">
<form action="6-needs-and-requirements" method="post" class="form">
<fieldset class="govuk-fieldset">
<div class="govuk-form-group govuk-!-margin-bottom-9 moj-confirm-box">
{{ govukCheckboxes({
idPrefix: "confirm-risk",
name: "confirm-risk",
fieldset: {
legend: {
text: "Please confirm that Alex's risk information is up to date",
isPageHeading: false,
classes: "govuk-fieldset__legend--m"
}
},
items: [
{
value: "confirm-risk",
text: "I confirm that this is the most up to date risk information"
}
]
}) }}
</div>
</fieldset>

<input type="hidden" name="risk-information-completed" value="yes"/>
<button class="govuk-button" data-module="govuk-button">
Save and continue
</button>
</form>
</div>
</div>

{% endblock %}

0 comments on commit eb4b842

Please sign in to comment.