Skip to content

Commit

Permalink
Merge pull request #1103 from nationalarchives/chore/remove-delete
Browse files Browse the repository at this point in the history
Remove unused deletion code
  • Loading branch information
jacksonj04 authored Aug 7, 2023
2 parents 7501e06 + fdecea2 commit 3fb7dee
Show file tree
Hide file tree
Showing 6 changed files with 1 addition and 62 deletions.
11 changes: 0 additions & 11 deletions ds_caselaw_editor_ui/sass/includes/_judgment_text_toolbar.scss
Original file line number Diff line number Diff line change
Expand Up @@ -10,17 +10,6 @@
padding: calc($spacer__unit / 2) calc($spacer__unit * 1.5) !important;
}

&__delete {
border-color: $color__red !important;
color: $color__red !important;
&:focus,
&:hover {
background-color: $color__red !important;
color: $color__white !important;
outline-color: $color__red !important;
}
}

&__return-link {
display: inline-block;

Expand Down
10 changes: 0 additions & 10 deletions ds_caselaw_editor_ui/templates/includes/judgment/toolbar.html
Original file line number Diff line number Diff line change
Expand Up @@ -40,16 +40,6 @@
<span class="judgment-toolbar__button button-secondary"
aria-disabled="true">{% translate "judgment.toolbar.download_docx" %}</span>
{% endif %}
{% if judgment.is_failure %}
<form action="{% url "delete" %}" method="post">
{% csrf_token %}
<input type="hidden" name="judgment_uri" value="{{ judgment.uri }}" />
<input type="submit"
name="assign"
class="button-secondary judgment-toolbar__delete"
value="{% translate "judgment.toolbar.delete" %}" />
</form>
{% endif %}
</div>
{% if version %}
<div class="judgment-toolbar__version">
Expand Down
2 changes: 0 additions & 2 deletions judgments/urls.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,6 @@
hold_judgment_button,
prioritise_judgment_button,
)
from .views.delete import delete
from .views.full_text import (
html_view,
html_view_redirect,
Expand Down Expand Up @@ -53,7 +52,6 @@
path("unpublish", unpublish, name="unpublish"),
path("hold", hold, name="hold"),
path("unhold", unhold, name="unhold"),
path("delete", delete, name="delete"),
path("unlock", unlock, name="unlock"),
path("assign", assign_judgment_button, name="assign"),
path("prioritise", prioritise_judgment_button, name="prioritise"),
Expand Down
5 changes: 0 additions & 5 deletions judgments/utils/aws.py
Original file line number Diff line number Diff line change
Expand Up @@ -104,11 +104,6 @@ def delete_from_bucket(uri: str, bucket: str) -> None:
)


def delete_documents(uri: str) -> None:
unpublish_documents(uri)
delete_from_bucket(uri, env("PRIVATE_ASSET_BUCKET"))


def publish_documents(uri: str) -> None:
client = create_s3_client()

Expand Down
25 changes: 0 additions & 25 deletions judgments/views/delete.py

This file was deleted.

10 changes: 1 addition & 9 deletions locale/en_GB/LC_MESSAGES/django.po
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ msgid ""
msgstr ""
"Project-Id-Version: PACKAGE VERSION\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2023-08-03 15:39+0000\n"
"POT-Creation-Date: 2023-08-07 16:14+0000\n"
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
"Language-Team: LANGUAGE <[email protected]>\n"
Expand Down Expand Up @@ -175,10 +175,6 @@ msgstr "Publish"
msgid "judgment.toolbar.download_docx"
msgstr "Download .docx"

#: ds_caselaw_editor_ui/templates/includes/judgment/toolbar.html
msgid "judgment.toolbar.delete"
msgstr "Delete"

#: ds_caselaw_editor_ui/templates/includes/judgments_list_header.html
msgid "judgments.details"
msgstr "Document details:"
Expand Down Expand Up @@ -334,10 +330,6 @@ msgstr ""
msgid "judgments.submitteremail"
msgstr "Contact email"

#: judgments/views/delete.py
msgid "judgment.delete_a_judgment"
msgstr "Delete a document"

#: judgments/views/judgment_hold.py
msgid "judgment.hold.hold_success_flash_message"
msgstr "Document on hold"
Expand Down

0 comments on commit 3fb7dee

Please sign in to comment.