Skip to content

Commit

Permalink
Merge branch 'release' into 'master'
Browse files Browse the repository at this point in the history
Release 73.0

See merge request buckinghamshire-council/bc!720
  • Loading branch information
KIRA009 committed Jul 9, 2024
2 parents 38f23e6 + 2c9c6a1 commit 5f3f426
Show file tree
Hide file tree
Showing 76 changed files with 17,452 additions and 12,282 deletions.
11 changes: 10 additions & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,15 @@
# Release History

## Unreleased
## 73.0 (2024-07-09)

Compare: <https://git.torchbox.com/buckinghamshire-council/bc/compare/72.01...73.0>

- Add new search promotional block on search page
- Add FIS EHCCo search
- Modify FIS search results view
- Modify FIS homepage
- Modify FIS category index page
- Fix accessibility issues from Silktide

## 72.01 (2024-06-26)

Expand Down
1,070 changes: 1,070 additions & 0 deletions bc/blogs/migrations/0018_add_ehcco_search_widget.py

Large diffs are not rendered by default.

559 changes: 559 additions & 0 deletions bc/cases/migrations/0025_add_ehcco_search_widget.py

Large diffs are not rendered by default.

545 changes: 545 additions & 0 deletions bc/events/migrations/0033_add_ehcco_search_widget.py

Large diffs are not rendered by default.

46 changes: 46 additions & 0 deletions bc/family_information/blocks.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,46 @@
from wagtail import blocks


class NCardRowBlock(blocks.StreamBlock):
card = blocks.PageChooserBlock()

def get_context(self, value, parent_context=None):
context = super().get_context(value, parent_context)

# Get the page's class.
context["page_class"] = parent_context["page"]._meta.object_name

# Check if the block is preceded by a heading.
blocks_under_headings = parent_context.get("blocks_under_headings", [])
context["has_heading"] = value in blocks_under_headings

return context


class CardsBlock(NCardRowBlock):
"""A block that displays 3 pages per row, but accepts more than 3 pages."""

class Meta:
label = "Cards"
min_num = 1
template = "patterns/molecules/streamfield/blocks/cards_block.html"


class TwoCardRowBlock(NCardRowBlock):
"""A block that only accepts 2 pages, to display the 2 pages in one row."""

class Meta:
label = "Two-card row"
max_num = 2
min_num = 2
template = "patterns/molecules/streamfield/blocks/two_card_row_block.html"


class ThreeCardRowBlock(NCardRowBlock):
"""A block that only accepts 3 pages, to display the 3 pages in one row."""

class Meta:
label = "Three-card row"
max_num = 3
min_num = 3
template = "patterns/molecules/streamfield/blocks/three_card_row_block.html"
Original file line number Diff line number Diff line change
@@ -0,0 +1,82 @@
# Generated by Django 4.2.11 on 2024-06-07 07:54

import django.db.models.deletion
import wagtail.search.index
from django.db import migrations, models


class Migration(migrations.Migration):

dependencies = [
("family_information", "0010_subsitehomepage_heading"),
]

operations = [
migrations.CreateModel(
name="EHCCo",
fields=[
(
"id",
models.AutoField(
auto_created=True,
primary_key=True,
serialize=False,
verbose_name="ID",
),
),
("name", models.CharField(max_length=255)),
("email", models.EmailField(max_length=254)),
],
options={
"verbose_name": "EHCCo",
"verbose_name_plural": "EHCCos",
},
bases=(wagtail.search.index.Indexed, models.Model),
),
migrations.CreateModel(
name="School",
fields=[
(
"id",
models.AutoField(
auto_created=True,
primary_key=True,
serialize=False,
verbose_name="ID",
),
),
("name", models.TextField()),
(
"hub_email",
models.CharField(
blank=True,
choices=[
(
"sencsb@buckinghamshire.gov.uk",
"sencsb@buckinghamshire.gov.uk",
),
(
"senwyc@buckinghamshire.gov.uk",
"senwyc@buckinghamshire.gov.uk",
),
(
"Senaylesbury@buckinghamshire.gov.uk",
"Senaylesbury@buckinghamshire.gov.uk",
),
],
),
),
(
"ehc_co",
models.ForeignKey(
blank=True,
null=True,
on_delete=django.db.models.deletion.SET_NULL,
related_name="schools",
to="family_information.ehcco",
),
),
],
bases=(wagtail.search.index.Indexed, models.Model),
),
]
Original file line number Diff line number Diff line change
@@ -0,0 +1,75 @@
# Generated by Django 4.2.11 on 2024-06-14 09:20

from django.db import migrations, models
import django.db.models.deletion
import modelcluster.fields
import wagtail.blocks
import wagtail.fields


class Migration(migrations.Migration):

dependencies = [
("family_information", "0010_subsitehomepage_heading"),
]

operations = [
migrations.AddField(
model_name="subsitehomepage",
name="highlighted_cards",
field=wagtail.fields.StreamField(
[
(
"two_card_row",
wagtail.blocks.StreamBlock(
[("card", wagtail.blocks.PageChooserBlock())]
),
),
(
"three_card_row",
wagtail.blocks.StreamBlock(
[("card", wagtail.blocks.PageChooserBlock())]
),
),
],
blank=True,
),
),
migrations.AddField(
model_name="subsitehomepage",
name="top_tasks_heading",
field=models.CharField(
blank=True, default="What do you want to do?", max_length=255
),
),
migrations.CreateModel(
name="SubsiteHomePageTopTask",
fields=[
(
"id",
models.AutoField(
auto_created=True,
primary_key=True,
serialize=False,
verbose_name="ID",
),
),
(
"sort_order",
models.IntegerField(blank=True, editable=False, null=True),
),
(
"source",
modelcluster.fields.ParentalKey(
on_delete=django.db.models.deletion.CASCADE,
related_name="top_tasks",
to="family_information.subsitehomepage",
),
),
],
options={
"ordering": ["sort_order"],
"abstract": False,
},
),
]
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
# Generated by Django 4.2.11 on 2024-06-14 09:20

from django.db import migrations, models
import django.db.models.deletion


class Migration(migrations.Migration):

dependencies = [
("utils", "0014_toptask"),
("family_information", "0011_subsitehomepage_highlighted_cards_and_more"),
]

operations = [
migrations.AddField(
model_name="subsitehomepagetoptask",
name="top_task",
field=models.ForeignKey(
on_delete=django.db.models.deletion.CASCADE,
related_name="+",
to="utils.toptask",
),
),
]
Loading

0 comments on commit 5f3f426

Please sign in to comment.