From 12ade737f1a57c771bc2d6f131c0e0612a56f087 Mon Sep 17 00:00:00 2001 From: Anusha Ranganathan Date: Wed, 23 Oct 2024 12:57:30 +0530 Subject: [PATCH 1/6] Replaced UI to old style for repository --- .../templates/account/user/_repository.html | 86 +++---------------- 1 file changed, 10 insertions(+), 76 deletions(-) diff --git a/service/templates/account/user/_repository.html b/service/templates/account/user/_repository.html index d2c51e9d..291c2d66 100644 --- a/service/templates/account/user/_repository.html +++ b/service/templates/account/user/_repository.html @@ -1,77 +1,11 @@ - -
Routing History - -
- -
Profile settings - - - - -
- {% include 'account/user/repository/_profile_settings.html' %} -
-
- {% include 'account/user/repository/_profile_settings_form.html' %} -
-
- {% include 'account/user/_update_email.html' %} -
-
- {% include 'account/user/_update_password.html' %} -
-
- -
Repository configuration for matching - -
- -
- -
- {% include 'account/user/repository/_matching_details_form.html' %} -
-
- -
Licenses associated with your institution - -
- {% include 'account/user/repository/_select_licenses.html' %} -
-
- -
Sword settings - - -
- {% include 'account/user/repository/_sword_settings.html' %} -
-
- {% include 'account/user/repository/_sword_settings_form.html' %} -
-
- -
Sword status - {% if sword_status.status == 'problem' %} - {% set cls = "warning" %} - {% elif sword_status.status == 'failing' %} - {% set cls = "danger" %} - {% else %} - {% set cls = "success" %} - {% endif %} - {{ sword_status.status }} - - {% include 'account/user/repository/_modify_sword_status_form.html' %} -
- {% include 'account/user/repository/_sword_status.html' %} -
-
+{% include 'account/user/repository/_matching_details_form.html' %} +{% include 'account/user/repository/_matching_details_link.html' %} +{% include 'account/user/repository/_routing_history_link.html' %} +{% include 'account/user/repository/_select_licenses.html' %} +{% include 'account/user/repository/_profile_settings_form.html' %} +{% include 'account/user/repository/_sword_settings_form.html' %} +{% include 'account/user/repository/_sword_status.html' %} +{% include 'account/user/_update_email.html' %} +{% include 'account/user/_update_password.html' %} + From 9fdb62ae03f8b2eb5d76219752802c9cc5ba1381 Mon Sep 17 00:00:00 2001 From: Anusha Ranganathan Date: Wed, 23 Oct 2024 16:33:13 +0530 Subject: [PATCH 2/6] Replaced UI to old style for publisher --- .../templates/account/user/_publisher.html | 14 ++- .../user/publisher/_connection_details.html | 14 +++ .../publisher/_connection_details_sftp.html | 11 +++ .../user/publisher/_list_ssh_keys.html | 93 ++++++++++++++++++ .../_matched_notifications_accordion.html | 6 -- .../user/publisher/_matching_history.html | 10 ++ .../_rejected_notifications_accordion.html | 6 -- .../user/publisher/_routing_status.html | 31 ++++++ .../publisher/_routing_status_accordion.html | 18 ---- .../account/user/publisher/_sftp_details.html | 13 --- .../account/user/publisher/_sftp_form.html | 28 ------ .../user/publisher/_sftp_list_ssh_keys.html | 95 ------------------- .../publisher/_sftp_server_settings_form.html | 33 +++++++ 13 files changed, 198 insertions(+), 174 deletions(-) create mode 100644 service/templates/account/user/publisher/_connection_details.html create mode 100644 service/templates/account/user/publisher/_connection_details_sftp.html create mode 100644 service/templates/account/user/publisher/_list_ssh_keys.html delete mode 100644 service/templates/account/user/publisher/_matched_notifications_accordion.html create mode 100644 service/templates/account/user/publisher/_matching_history.html delete mode 100644 service/templates/account/user/publisher/_rejected_notifications_accordion.html create mode 100644 service/templates/account/user/publisher/_routing_status.html delete mode 100644 service/templates/account/user/publisher/_routing_status_accordion.html delete mode 100644 service/templates/account/user/publisher/_sftp_details.html delete mode 100644 service/templates/account/user/publisher/_sftp_form.html delete mode 100644 service/templates/account/user/publisher/_sftp_list_ssh_keys.html create mode 100644 service/templates/account/user/publisher/_sftp_server_settings_form.html diff --git a/service/templates/account/user/_publisher.html b/service/templates/account/user/_publisher.html index 2d7806d1..48740885 100644 --- a/service/templates/account/user/_publisher.html +++ b/service/templates/account/user/_publisher.html @@ -1,8 +1,6 @@ -{% include 'account/user/publisher/_routing_status_accordion.html' %} -{% include 'account/user/publisher/_matched_notifications_accordion.html' %} -{% include 'account/user/publisher/_rejected_notifications_accordion.html' %} -{% include 'account/user/publisher/_default_license_accordion.html' %} -{#% include 'account/user/publisher/_default_embargo_accordion.html' %#} -{% include 'account/user/publisher/_sftp_accordion.html' %} -{% include 'account/user/publisher/_profile_details_accordion.thml' %} -{% include 'account/user/publisher/_connection_details_accordion.html' %} +{% include 'account/user/publisher/_routing_status.html' %} +{#% include 'account/user/publisher/_update_embargo.html' %#} +{% include 'account/user/publisher/_matching_history.html' %} +{% include 'account/user/publisher/_default_license_form.html' %} +{% include 'account/user/publisher/_connection_details.html' %} + diff --git a/service/templates/account/user/publisher/_connection_details.html b/service/templates/account/user/publisher/_connection_details.html new file mode 100644 index 00000000..60a2292d --- /dev/null +++ b/service/templates/account/user/publisher/_connection_details.html @@ -0,0 +1,14 @@ +
+

Connecting to DeepGreen

+
+ {% include 'account/user/publisher/_connection_details_api.html' %} +
+ {% include 'account/user/publisher/_connection_details_sword.html' %} +
+ {% include 'account/user/publisher/_connection_details_sftp.html' %} + {% include 'account/user/publisher/_sftp_server_settings_form.html' %} + {#% include 'account/user/publisher/_delete_sftp_server_details.html' %#} +
+ {% include 'account/user/publisher/_list_ssh_keys.html' %} + {% include 'account/user/publisher/_add_ssh_key.html' %} +
\ No newline at end of file diff --git a/service/templates/account/user/publisher/_connection_details_sftp.html b/service/templates/account/user/publisher/_connection_details_sftp.html new file mode 100644 index 00000000..74eb04e9 --- /dev/null +++ b/service/templates/account/user/publisher/_connection_details_sftp.html @@ -0,0 +1,11 @@ +

Connecting via SFTP

+
+
+
SFTP username
+
{{ account.sftp_server_username }}
+
SFTP server URL
+
{{ account.sftp_server_url }}
+
SFTP server port
+
{{ account.sftp_server_port }}
+

+
\ No newline at end of file diff --git a/service/templates/account/user/publisher/_list_ssh_keys.html b/service/templates/account/user/publisher/_list_ssh_keys.html new file mode 100644 index 00000000..cb88cba3 --- /dev/null +++ b/service/templates/account/user/publisher/_list_ssh_keys.html @@ -0,0 +1,93 @@ +

SSH keys

+
+
+
Title
+
SSH public key
+
Status
+
Action
+
+
+
{{ deepgreen_ssh_key['title'] }}
+
+
{{ deepgreen_ssh_key['public_key'] }}
+
+
+
Active
+
+
+
+ {% if account.ssh_keys|length > 0 %} + {% for ssh_key in account.ssh_keys[::-1] %} +
+
+ {% if ssh_key.get('title', '') %} + {{ ssh_key['title'] }} + {% endif %} +
+
+ {% if ssh_key.get('public_key', '') %} +
{{ ssh_key['public_key'] }}
+ {% endif %} +
+
+ {% if ssh_key.get('status', '') %} + {% if ssh_key['status'] == 'new' %} +
{{ ssh_key['status'] }}
+ {% elif ssh_key['status'] == 'active' %} +
{{ ssh_key['status'] }}
+ {% else %} +
{{ ssh_key['status'] }}
+ {% endif %} + {% endif %} +
+
+ {% if ssh_key.get('status', '') %} + {% if ssh_key.get('status', '') == 'new' and current_user.is_super %} +
+
    + + +
+

+
+
    + + +
+
+ {% endif %} + {% if ssh_key.get('status', '') == 'inactive' %} +
+
    + + +
+

+
+
    + + +
+
+ {% endif %} + {% if ssh_key.get('status', '') == 'active' %} +
+
    + + +
+
+ {% endif %} + {% endif %} +
+
+ {% endfor %} + {% else %} +
+

Add your SSH public key to connect to the SFTP server

+

Once the key is active, Send a directory (alternatively a flat ZIP file) for each + single publication notification. There should be no files in the top level of + your SFTP folder.

+
+ {% endif %} +
\ No newline at end of file diff --git a/service/templates/account/user/publisher/_matched_notifications_accordion.html b/service/templates/account/user/publisher/_matched_notifications_accordion.html deleted file mode 100644 index ab5e069b..00000000 --- a/service/templates/account/user/publisher/_matched_notifications_accordion.html +++ /dev/null @@ -1,6 +0,0 @@ -
Matched notifications history - -
\ No newline at end of file diff --git a/service/templates/account/user/publisher/_matching_history.html b/service/templates/account/user/publisher/_matching_history.html new file mode 100644 index 00000000..93913d10 --- /dev/null +++ b/service/templates/account/user/publisher/_matching_history.html @@ -0,0 +1,10 @@ +
+

View and download matching history

+ +
+ +
\ No newline at end of file diff --git a/service/templates/account/user/publisher/_rejected_notifications_accordion.html b/service/templates/account/user/publisher/_rejected_notifications_accordion.html deleted file mode 100644 index e3bce99d..00000000 --- a/service/templates/account/user/publisher/_rejected_notifications_accordion.html +++ /dev/null @@ -1,6 +0,0 @@ -
Rejected notifications history - -
\ No newline at end of file diff --git a/service/templates/account/user/publisher/_routing_status.html b/service/templates/account/user/publisher/_routing_status.html new file mode 100644 index 00000000..a6b624ef --- /dev/null +++ b/service/templates/account/user/publisher/_routing_status.html @@ -0,0 +1,31 @@ +
+

Routing status

+
+
+
Routing status
+
+ {% if account.publisher_routing_status == 'active' %} +
+ {{ account.publisher_routing_status }}
+ {% else %} +
+ {{ account.publisher_routing_status }}
+ {% endif %} +
+
+
+
+ {% set routing_action = "activate" %} + {% set action_label = "Set routing status to active" %} + {% if account.publisher_routing_status == 'active' %} + {% set routing_action = "deactivate" %} + {% set action_label = "Set routing status to inactive" %} + {% endif %} +
+
+ +
+
+
+
\ No newline at end of file diff --git a/service/templates/account/user/publisher/_routing_status_accordion.html b/service/templates/account/user/publisher/_routing_status_accordion.html deleted file mode 100644 index 105cdb4f..00000000 --- a/service/templates/account/user/publisher/_routing_status_accordion.html +++ /dev/null @@ -1,18 +0,0 @@ -
Routing Status - {% if account.publisher_routing_status == 'active' %} - {{ account.publisher_routing_status }} - {% else %} - {{ account.publisher_routing_status }} - {% endif %} - - {% set routing_action = "activate" %} - {% set action_label = "Set routing status to active" %} - {% if account.publisher_routing_status == 'active' %} - {% set routing_action = "deactivate" %} - {% set action_label = "Set routing status to inactive" %} - {% endif %} -
- -
-
diff --git a/service/templates/account/user/publisher/_sftp_details.html b/service/templates/account/user/publisher/_sftp_details.html deleted file mode 100644 index 864c88c6..00000000 --- a/service/templates/account/user/publisher/_sftp_details.html +++ /dev/null @@ -1,13 +0,0 @@ -
-

Connecting via SFTP

-
-
-
SFTP username
-
{{ account.sftp_server_username }}
-
SFTP server URL
-
{{ account.sftp_server_url }}
-
SFTP server port
-
{{ account.sftp_server_port }}
-

-
-
\ No newline at end of file diff --git a/service/templates/account/user/publisher/_sftp_form.html b/service/templates/account/user/publisher/_sftp_form.html deleted file mode 100644 index 5e1cdfd4..00000000 --- a/service/templates/account/user/publisher/_sftp_form.html +++ /dev/null @@ -1,28 +0,0 @@ -{% if current_user.is_super %} -
-

Manage SFTP server settings

-

If any of the values in the form are left blank, it will revert to the default value

-
-
-
    -
  • - SFTP username - -
  • -
  • - SFTP server URL - -
  • -
  • - SFTP server port - -
  • -
- -
-
-
-{% endif %} \ No newline at end of file diff --git a/service/templates/account/user/publisher/_sftp_list_ssh_keys.html b/service/templates/account/user/publisher/_sftp_list_ssh_keys.html deleted file mode 100644 index fb9df8c5..00000000 --- a/service/templates/account/user/publisher/_sftp_list_ssh_keys.html +++ /dev/null @@ -1,95 +0,0 @@ -
-

SSH keys

-
-
-
Title
-
SSH public key
-
Status
-
Action
-
-
-
{{ deepgreen_ssh_key['title'] }}
-
-
{{ deepgreen_ssh_key['public_key'] }}
-
-
-
Active
-
-
-
- {% if account.ssh_keys|length > 0 %} - {% for ssh_key in account.ssh_keys[::-1] %} -
-
- {% if ssh_key.get('title', '') %} - {{ ssh_key['title'] }} - {% endif %} -
-
- {% if ssh_key.get('public_key', '') %} -
{{ ssh_key['public_key'] }}
- {% endif %} -
-
- {% if ssh_key.get('status', '') %} - {% if ssh_key['status'] == 'new' %} -
{{ ssh_key['status'] }}
- {% elif ssh_key['status'] == 'active' %} -
{{ ssh_key['status'] }}
- {% else %} -
{{ ssh_key['status'] }}
- {% endif %} - {% endif %} -
-
- {% if ssh_key.get('status', '') %} - {% if ssh_key.get('status', '') == 'new' and current_user.is_super %} -
-
    - - -
-

-
-
    - - -
-
- {% endif %} - {% if ssh_key.get('status', '') == 'inactive' %} -
-
    - - -
-

-
-
    - - -
-
- {% endif %} - {% if ssh_key.get('status', '') == 'active' %} -
-
    - - -
-
- {% endif %} - {% endif %} -
-
- {% endfor %} - {% else %} -
-

Add your SSH public key to connect to the SFTP server

-

Once the key is active, Send a directory (alternatively a flat ZIP file) for each - single publication notification. There should be no files in the top level of - your SFTP folder.

-
- {% endif %} -
-
diff --git a/service/templates/account/user/publisher/_sftp_server_settings_form.html b/service/templates/account/user/publisher/_sftp_server_settings_form.html new file mode 100644 index 00000000..5c793e99 --- /dev/null +++ b/service/templates/account/user/publisher/_sftp_server_settings_form.html @@ -0,0 +1,33 @@ +{% if current_user.is_super %} +
+ +
+ +{% endif %} \ No newline at end of file From 673f97edfdcf47c13c3f5b1a2ce612ab1070361a Mon Sep 17 00:00:00 2001 From: Anusha Ranganathan Date: Wed, 23 Oct 2024 16:50:06 +0530 Subject: [PATCH 3/6] Changed style of reporitory user page to juse accoridions --- .../templates/account/user/_repository.html | 17 ++++++----------- .../user/repository/_licenses_accordion.html | 7 +++++++ .../_profile_settings_accordion.html | 19 +++++++++++++++++++ .../repository/_repo_config_accordion.html | 14 ++++++++++++++ .../_routing_history_accordion.html | 7 +++++++ .../repository/_sword_settings_accordion.html | 11 +++++++++++ .../repository/_sword_status_accordion.html | 18 ++++++++++++++++++ 7 files changed, 82 insertions(+), 11 deletions(-) create mode 100644 service/templates/account/user/repository/_licenses_accordion.html create mode 100644 service/templates/account/user/repository/_profile_settings_accordion.html create mode 100644 service/templates/account/user/repository/_repo_config_accordion.html create mode 100644 service/templates/account/user/repository/_routing_history_accordion.html create mode 100644 service/templates/account/user/repository/_sword_settings_accordion.html create mode 100644 service/templates/account/user/repository/_sword_status_accordion.html diff --git a/service/templates/account/user/_repository.html b/service/templates/account/user/_repository.html index 291c2d66..b8653fa2 100644 --- a/service/templates/account/user/_repository.html +++ b/service/templates/account/user/_repository.html @@ -1,11 +1,6 @@ -{% include 'account/user/repository/_matching_details_form.html' %} -{% include 'account/user/repository/_matching_details_link.html' %} -{% include 'account/user/repository/_routing_history_link.html' %} -{% include 'account/user/repository/_select_licenses.html' %} -{% include 'account/user/repository/_profile_settings_form.html' %} -{% include 'account/user/repository/_sword_settings_form.html' %} -{% include 'account/user/repository/_sword_status.html' %} -{% include 'account/user/_update_email.html' %} -{% include 'account/user/_update_password.html' %} - - +{% include 'account/user/repository/_routing_history_accordion.html' %} +{% include 'account/user/repository/_profile_settings_accordion.html' %} +{% include 'account/user/repository/_repo_config_accordion.html' %} +{% include 'account/user/repository/_licenses_accordion.html' %} +{% include 'account/user/repository/_sword_settings_accordion.html' %} +{% include 'account/user/repository/_sword_status_accordion.html' %} diff --git a/service/templates/account/user/repository/_licenses_accordion.html b/service/templates/account/user/repository/_licenses_accordion.html new file mode 100644 index 00000000..7a69b346 --- /dev/null +++ b/service/templates/account/user/repository/_licenses_accordion.html @@ -0,0 +1,7 @@ + +
Licenses associated with your institution + +
+ {% include 'account/user/repository/_select_licenses.html' %} +
+
\ No newline at end of file diff --git a/service/templates/account/user/repository/_profile_settings_accordion.html b/service/templates/account/user/repository/_profile_settings_accordion.html new file mode 100644 index 00000000..e4138c7e --- /dev/null +++ b/service/templates/account/user/repository/_profile_settings_accordion.html @@ -0,0 +1,19 @@ + +
Profile settings + + + + +
+ {% include 'account/user/repository/_profile_settings.html' %} +
+
+ {% include 'account/user/repository/_profile_settings_form.html' %} +
+
+ {% include 'account/user/_update_email.html' %} +
+
+ {% include 'account/user/_update_password.html' %} +
+
\ No newline at end of file diff --git a/service/templates/account/user/repository/_repo_config_accordion.html b/service/templates/account/user/repository/_repo_config_accordion.html new file mode 100644 index 00000000..74372468 --- /dev/null +++ b/service/templates/account/user/repository/_repo_config_accordion.html @@ -0,0 +1,14 @@ + +
Repository configuration for matching + +
+ +
+ +
+ {% include 'account/user/repository/_matching_details_form.html' %} +
+
\ No newline at end of file diff --git a/service/templates/account/user/repository/_routing_history_accordion.html b/service/templates/account/user/repository/_routing_history_accordion.html new file mode 100644 index 00000000..10420dcd --- /dev/null +++ b/service/templates/account/user/repository/_routing_history_accordion.html @@ -0,0 +1,7 @@ + +
Routing History + +
\ No newline at end of file diff --git a/service/templates/account/user/repository/_sword_settings_accordion.html b/service/templates/account/user/repository/_sword_settings_accordion.html new file mode 100644 index 00000000..9040afa5 --- /dev/null +++ b/service/templates/account/user/repository/_sword_settings_accordion.html @@ -0,0 +1,11 @@ + +
Sword settings + + +
+ {% include 'account/user/repository/_sword_settings.html' %} +
+
+ {% include 'account/user/repository/_sword_settings_form.html' %} +
+
\ No newline at end of file diff --git a/service/templates/account/user/repository/_sword_status_accordion.html b/service/templates/account/user/repository/_sword_status_accordion.html new file mode 100644 index 00000000..20a166ea --- /dev/null +++ b/service/templates/account/user/repository/_sword_status_accordion.html @@ -0,0 +1,18 @@ + +
Sword status + {% if sword_status.status == 'problem' %} + {% set cls = "warning" %} + {% elif sword_status.status == 'failing' %} + {% set cls = "danger" %} + {% else %} + {% set cls = "success" %} + {% endif %} + {{ sword_status.status }} + + {% include 'account/user/repository/_modify_sword_status_form.html' %} +
+ {% include 'account/user/repository/_sword_status.html' %} +
+
\ No newline at end of file From 54fefbdfe61366922e39d2c68726170659ba4f13 Mon Sep 17 00:00:00 2001 From: Anusha Ranganathan Date: Wed, 23 Oct 2024 16:56:50 +0530 Subject: [PATCH 4/6] Renamed and modified connection_details_sftp --- .../user/publisher/_connection_details_sftp.html | 11 ----------- .../account/user/publisher/_sftp_details.html | 13 +++++++++++++ 2 files changed, 13 insertions(+), 11 deletions(-) delete mode 100644 service/templates/account/user/publisher/_connection_details_sftp.html create mode 100644 service/templates/account/user/publisher/_sftp_details.html diff --git a/service/templates/account/user/publisher/_connection_details_sftp.html b/service/templates/account/user/publisher/_connection_details_sftp.html deleted file mode 100644 index 74eb04e9..00000000 --- a/service/templates/account/user/publisher/_connection_details_sftp.html +++ /dev/null @@ -1,11 +0,0 @@ -

Connecting via SFTP

-
-
-
SFTP username
-
{{ account.sftp_server_username }}
-
SFTP server URL
-
{{ account.sftp_server_url }}
-
SFTP server port
-
{{ account.sftp_server_port }}
-

-
\ No newline at end of file diff --git a/service/templates/account/user/publisher/_sftp_details.html b/service/templates/account/user/publisher/_sftp_details.html new file mode 100644 index 00000000..864c88c6 --- /dev/null +++ b/service/templates/account/user/publisher/_sftp_details.html @@ -0,0 +1,13 @@ +
+

Connecting via SFTP

+
+
+
SFTP username
+
{{ account.sftp_server_username }}
+
SFTP server URL
+
{{ account.sftp_server_url }}
+
SFTP server port
+
{{ account.sftp_server_port }}
+

+
+
\ No newline at end of file From b68d9a04edc279f687567bb40a02d1e4e3eb91ea Mon Sep 17 00:00:00 2001 From: Anusha Ranganathan Date: Wed, 23 Oct 2024 17:30:46 +0530 Subject: [PATCH 5/6] Files renamed --- ...atching_history.html => _matched_notifications_accordion.html} | 0 .../{_routing_status.html => _routing_status_accordion.html} | 0 .../{_sftp_server_settings_form.html => _sftp_form.html} | 0 .../publisher/{_list_ssh_keys.html => _sftp_list_ssh_keys.html} | 0 4 files changed, 0 insertions(+), 0 deletions(-) rename service/templates/account/user/publisher/{_matching_history.html => _matched_notifications_accordion.html} (100%) rename service/templates/account/user/publisher/{_routing_status.html => _routing_status_accordion.html} (100%) rename service/templates/account/user/publisher/{_sftp_server_settings_form.html => _sftp_form.html} (100%) rename service/templates/account/user/publisher/{_list_ssh_keys.html => _sftp_list_ssh_keys.html} (100%) diff --git a/service/templates/account/user/publisher/_matching_history.html b/service/templates/account/user/publisher/_matched_notifications_accordion.html similarity index 100% rename from service/templates/account/user/publisher/_matching_history.html rename to service/templates/account/user/publisher/_matched_notifications_accordion.html diff --git a/service/templates/account/user/publisher/_routing_status.html b/service/templates/account/user/publisher/_routing_status_accordion.html similarity index 100% rename from service/templates/account/user/publisher/_routing_status.html rename to service/templates/account/user/publisher/_routing_status_accordion.html diff --git a/service/templates/account/user/publisher/_sftp_server_settings_form.html b/service/templates/account/user/publisher/_sftp_form.html similarity index 100% rename from service/templates/account/user/publisher/_sftp_server_settings_form.html rename to service/templates/account/user/publisher/_sftp_form.html diff --git a/service/templates/account/user/publisher/_list_ssh_keys.html b/service/templates/account/user/publisher/_sftp_list_ssh_keys.html similarity index 100% rename from service/templates/account/user/publisher/_list_ssh_keys.html rename to service/templates/account/user/publisher/_sftp_list_ssh_keys.html From 4f89988fb7e7819121b85978de0bb5ca69aa0636 Mon Sep 17 00:00:00 2001 From: Anusha Ranganathan Date: Wed, 23 Oct 2024 17:37:49 +0530 Subject: [PATCH 6/6] Changed style of publisher user page to use accordions --- .../templates/account/user/_publisher.html | 14 +- .../_matched_notifications_accordion.html | 14 +- .../_rejected_notifications_accordion.html | 6 + .../publisher/_routing_status_accordion.html | 49 ++--- .../account/user/publisher/_sftp_form.html | 57 +++--- .../user/publisher/_sftp_list_ssh_keys.html | 170 +++++++++--------- 6 files changed, 149 insertions(+), 161 deletions(-) create mode 100644 service/templates/account/user/publisher/_rejected_notifications_accordion.html diff --git a/service/templates/account/user/_publisher.html b/service/templates/account/user/_publisher.html index 48740885..2d7806d1 100644 --- a/service/templates/account/user/_publisher.html +++ b/service/templates/account/user/_publisher.html @@ -1,6 +1,8 @@ -{% include 'account/user/publisher/_routing_status.html' %} -{#% include 'account/user/publisher/_update_embargo.html' %#} -{% include 'account/user/publisher/_matching_history.html' %} -{% include 'account/user/publisher/_default_license_form.html' %} -{% include 'account/user/publisher/_connection_details.html' %} - +{% include 'account/user/publisher/_routing_status_accordion.html' %} +{% include 'account/user/publisher/_matched_notifications_accordion.html' %} +{% include 'account/user/publisher/_rejected_notifications_accordion.html' %} +{% include 'account/user/publisher/_default_license_accordion.html' %} +{#% include 'account/user/publisher/_default_embargo_accordion.html' %#} +{% include 'account/user/publisher/_sftp_accordion.html' %} +{% include 'account/user/publisher/_profile_details_accordion.thml' %} +{% include 'account/user/publisher/_connection_details_accordion.html' %} diff --git a/service/templates/account/user/publisher/_matched_notifications_accordion.html b/service/templates/account/user/publisher/_matched_notifications_accordion.html index 93913d10..ab5e069b 100644 --- a/service/templates/account/user/publisher/_matched_notifications_accordion.html +++ b/service/templates/account/user/publisher/_matched_notifications_accordion.html @@ -1,10 +1,6 @@ -
-

View and download matching history

- -
- +
Matched notifications history +
\ No newline at end of file diff --git a/service/templates/account/user/publisher/_rejected_notifications_accordion.html b/service/templates/account/user/publisher/_rejected_notifications_accordion.html new file mode 100644 index 00000000..e3bce99d --- /dev/null +++ b/service/templates/account/user/publisher/_rejected_notifications_accordion.html @@ -0,0 +1,6 @@ +
Rejected notifications history + +
\ No newline at end of file diff --git a/service/templates/account/user/publisher/_routing_status_accordion.html b/service/templates/account/user/publisher/_routing_status_accordion.html index a6b624ef..105cdb4f 100644 --- a/service/templates/account/user/publisher/_routing_status_accordion.html +++ b/service/templates/account/user/publisher/_routing_status_accordion.html @@ -1,31 +1,18 @@ -
-

Routing status

-
-
-
Routing status
-
- {% if account.publisher_routing_status == 'active' %} -
- {{ account.publisher_routing_status }}
- {% else %} -
- {{ account.publisher_routing_status }}
- {% endif %} -
-
-
-
- {% set routing_action = "activate" %} - {% set action_label = "Set routing status to active" %} - {% if account.publisher_routing_status == 'active' %} - {% set routing_action = "deactivate" %} - {% set action_label = "Set routing status to inactive" %} - {% endif %} -
-
- -
-
-
-
\ No newline at end of file +
Routing Status + {% if account.publisher_routing_status == 'active' %} + {{ account.publisher_routing_status }} + {% else %} + {{ account.publisher_routing_status }} + {% endif %} + + {% set routing_action = "activate" %} + {% set action_label = "Set routing status to active" %} + {% if account.publisher_routing_status == 'active' %} + {% set routing_action = "deactivate" %} + {% set action_label = "Set routing status to inactive" %} + {% endif %} +
+ +
+
diff --git a/service/templates/account/user/publisher/_sftp_form.html b/service/templates/account/user/publisher/_sftp_form.html index 5c793e99..5e1cdfd4 100644 --- a/service/templates/account/user/publisher/_sftp_form.html +++ b/service/templates/account/user/publisher/_sftp_form.html @@ -1,33 +1,28 @@ {% if current_user.is_super %} -
- -
- +
+

Manage SFTP server settings

+

If any of the values in the form are left blank, it will revert to the default value

+
+
+
    +
  • + SFTP username + +
  • +
  • + SFTP server URL + +
  • +
  • + SFTP server port + +
  • +
+ +
+
+
{% endif %} \ No newline at end of file diff --git a/service/templates/account/user/publisher/_sftp_list_ssh_keys.html b/service/templates/account/user/publisher/_sftp_list_ssh_keys.html index cb88cba3..fb9df8c5 100644 --- a/service/templates/account/user/publisher/_sftp_list_ssh_keys.html +++ b/service/templates/account/user/publisher/_sftp_list_ssh_keys.html @@ -1,93 +1,95 @@ -

SSH keys

-
+
+

SSH keys

+
-
Title
-
SSH public key
-
Status
-
Action
+
Title
+
SSH public key
+
Status
+
Action
-
{{ deepgreen_ssh_key['title'] }}
-
-
{{ deepgreen_ssh_key['public_key'] }}
-
-
-
Active
-
-
+
{{ deepgreen_ssh_key['title'] }}
+
+
{{ deepgreen_ssh_key['public_key'] }}
+
+
+
Active
+
+
{% if account.ssh_keys|length > 0 %} - {% for ssh_key in account.ssh_keys[::-1] %} -
-
- {% if ssh_key.get('title', '') %} - {{ ssh_key['title'] }} - {% endif %} -
-
- {% if ssh_key.get('public_key', '') %} -
{{ ssh_key['public_key'] }}
- {% endif %} -
-
- {% if ssh_key.get('status', '') %} - {% if ssh_key['status'] == 'new' %} -
{{ ssh_key['status'] }}
- {% elif ssh_key['status'] == 'active' %} -
{{ ssh_key['status'] }}
- {% else %} -
{{ ssh_key['status'] }}
- {% endif %} - {% endif %} -
-
- {% if ssh_key.get('status', '') %} - {% if ssh_key.get('status', '') == 'new' and current_user.is_super %} -
-
    - - -
-

-
-
    - - -
-
- {% endif %} - {% if ssh_key.get('status', '') == 'inactive' %} -
-
    - - -
-

-
-
    - - -
-
- {% endif %} - {% if ssh_key.get('status', '') == 'active' %} -
-
    - - -
-
- {% endif %} - {% endif %} -
-
- {% endfor %} - {% else %} + {% for ssh_key in account.ssh_keys[::-1] %}
+
+ {% if ssh_key.get('title', '') %} + {{ ssh_key['title'] }} + {% endif %} +
+
+ {% if ssh_key.get('public_key', '') %} +
{{ ssh_key['public_key'] }}
+ {% endif %} +
+
+ {% if ssh_key.get('status', '') %} + {% if ssh_key['status'] == 'new' %} +
{{ ssh_key['status'] }}
+ {% elif ssh_key['status'] == 'active' %} +
{{ ssh_key['status'] }}
+ {% else %} +
{{ ssh_key['status'] }}
+ {% endif %} + {% endif %} +
+
+ {% if ssh_key.get('status', '') %} + {% if ssh_key.get('status', '') == 'new' and current_user.is_super %} +
+
    + + +
+

+
+
    + + +
+
+ {% endif %} + {% if ssh_key.get('status', '') == 'inactive' %} +
+
    + + +
+

+
+
    + + +
+
+ {% endif %} + {% if ssh_key.get('status', '') == 'active' %} +
+
    + + +
+
+ {% endif %} + {% endif %} +
+
+ {% endfor %} + {% else %} +

Add your SSH public key to connect to the SFTP server

Once the key is active, Send a directory (alternatively a flat ZIP file) for each - single publication notification. There should be no files in the top level of - your SFTP folder.

-
+ single publication notification. There should be no files in the top level of + your SFTP folder.

+
{% endif %} -
\ No newline at end of file +
+