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

LGA-3346: Add Children, families and relationships page #60

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
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
1 change: 1 addition & 0 deletions .trufflehog3.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ exclude: # exclude matching issues
- .ruff_cache
- node_modules/**
- .pytest_cache/**
- .idea/**
- message: Examples and data necessary for running auto-tests
paths:
- docs/*.html
Expand Down
2 changes: 2 additions & 0 deletions app/categories/__init__.py
Original file line number Diff line number Diff line change
@@ -1,9 +1,11 @@
from flask import Blueprint
from .domestic_abuse import bp as domestic_abuse_bp
from .discrimination import bp as discrimination_bp
from .family import bp as family_bp

bp = Blueprint("categories", __name__)
bp.register_blueprint(domestic_abuse_bp)
bp.register_blueprint(discrimination_bp)
bp.register_blueprint(family_bp)

from app.categories import routes # noqa: E402,F401
10 changes: 10 additions & 0 deletions app/categories/family/__init__.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
from flask import Blueprint

bp = Blueprint(
"family",
__name__,
template_folder="./templates",
url_prefix="/family",
)

from app.categories.family import routes # noqa: E402,F401
10 changes: 10 additions & 0 deletions app/categories/family/routes.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
from app.categories.family import bp
from flask import render_template, url_for


@bp.route("")
def index():
return render_template(
"categories/family.html",
back_link=url_for("categories.index"),
)
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
{%- from 'govuk_frontend_jinja/components/inset-text/macro.html' import govukInsetText -%}

{% macro cannot_find_your_problem(category_name, next_steps_destination) %}
{{ govukInsetText({
"html": "If you cannot find your problem: children, families, relationships"
}) }}
{% endmacro %}
71 changes: 71 additions & 0 deletions app/templates/categories/family.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,71 @@
{# This page was built as a prototype #}
{% extends "base.html" %}
{%- from 'govuk_frontend_jinja/components/back-link/macro.html' import govukBackLink -%}
{%- from 'govuk_frontend_jinja/components/exit-this-page/macro.html' import govukExitThisPage -%}
{%- from 'categories/components/list-item.html' import list_item, list_item_small -%}
{%- from 'categories/components/cannot-find-your-problem.html' import cannot_find_your_problem -%}

{% block pageTitle %}Family - GOV.UK{% endblock %}

{% block beforeContent%}
{{ super() }}
{{ govukBackLink({
'href': url_for('categories.index'),
'text': "Back"
}) }}
{% endblock %}

{% block content %}

{{ super() }}

<div class="govuk-grid-row">
<div class="govuk-grid-column-two-thirds">
<h1 class="govuk-heading-xl">{% trans %}Children, families and relationships{% endtrans %}</h1>

<br>

{{ list_item(_("Children and social services, children in care"),
_("Help for any problem if social services are involved with a child. Includes children in care, or being adopted. Also special guardianship."),
url_for("categories.index")) }}

{{ list_item(_("Problems with an ex-partner, divorce, when a relationship ends"),
_("If you cannot agree about money, finances and property. Includes contact with children, where children live, and other child arrangements. If an ex-partner is not doing what they agreed. If you’re worried about a child."),
url_for("categories.index")) }}

{{ list_item(_("If there is domestic abuse in your family"),
_("Making arrangements for children and finances. Also, keeping yourself safe, protecting children and legal help to leave the relationship."),
url_for("categories.index")) }}


{{ list_item(_("Family mediation"),
_("Help to cover the costs of family mediation (solve problems about money and children before you go to court"),
url_for("categories.index"))}}

{{ list_item(_("Child taken without your consent"),
_("If a child has been abducted (taken without your permission), including outside the UK."),
url_for("categories.index"))}}

<br>

<h2 class="govuk-heading-m">More problems</h2>

<br>

{{ list_item_small(_("Children with special educational needs and disabilities (SEND)"),
_("Get help with a child's SEND."),
url_for("categories.index")) }}

{{ list_item_small(_("Schools, colleges, other education settings"),
_("Advice about legal action against a school. Includes if a child is out of school, exclusions, transport to school, judicial reviews."),
url_for("categories.index")) }}

{{ list_item_small(_("Forced marriage"),
_("Help with forced marriage and Forced Marriage Protection Orders."),
url_for("categories.index")) }}

{{ cannot_find_your_problem(_("Children, families and relationships"), url_for("categories.family.index")) }}

</div>
</div>
{% endblock %}
7 changes: 1 addition & 6 deletions app/templates/categories/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ <h2 class="govuk-heading-m govuk-!-margin-bottom-4">Most searched problems</h2>
<div class="govuk-grid-column-full govuk-!-padding-left-0">
{{ list_item_arrow("Children, families and relationships",
"Includes children and social services, children in care. Also, help with children and finances if you divorce or split up.",
url_for("categories.index")) }}
url_for("categories.family.index")) }}

{{ list_item_arrow("Discrimination",
"Treated unfairly because of things like your disability or health condition, race, age, sex, religion or pregnancy.",
Expand Down Expand Up @@ -54,8 +54,6 @@ <h2 class="govuk-heading-m govuk-!-margin-bottom-4">Most searched problems</h2>

<br>

</div>

<div class="govuk-grid-column-two-thirds">

<br>
Expand Down Expand Up @@ -96,9 +94,6 @@ <h3 class="govuk-heading-m">Other problems covered by legal aid</h3>
}) }}

</div>

</div>

</div>

{% endblock %}
Loading