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

#2159 Disallow archiving until exercise unpublished from website #2215

Merged
merged 5 commits into from
Dec 1, 2023

Conversation

drieJAC
Copy link
Contributor

@drieJAC drieJAC commented Nov 9, 2023

What's included?

Disallow archiving until exercise is unpublished from website.
Here I'm actually un-publishing at the same time as archiving!

Closes #2159

Who should test?

✅ Product owner
✅ Developers
✅ UTG

How to test?

  • Goto the following url (it may prompt you to login first): https://jac-admin-develop--pr2215-feature-2159-disallo-5vj3g8aa.web.app/exercise/VG7qW7osx4eWUSIxFcT5/details/overview
  • find an exercise that has been published and ensure the vacancy appears in the apply site
  • archive the exercise and ensure a message appears saying 'This application is currently within the application window and is not published on the website' AND it no longer appears as a vacancy
  • unarchive the exercise and check that a message appears saying 'This exercise has been approved. Now you can publish it on the website' AND ensure it reappears as a vacancy.

See video attached below:

Screen.Recording.2023-11-09.at.02.49.11.mov

Risk - how likely is this to impact other areas?

🟢 No risk - this is a self-contained piece of work


PREVIEW:DEVELOP
can be OFF, DEVELOP or STAGING

Ensure both messages cannot be shown as an unpublished AND unarchived exercise was allowing both messages to display.
@drieJAC drieJAC requested review from a team as code owners November 9, 2023 02:54
@drieJAC drieJAC self-assigned this Nov 9, 2023
Copy link

github-actions bot commented Nov 9, 2023

Visit the preview URL for this PR (updated for commit 6d43732):

https://jac-admin-develop--pr2215-feature-2159-disallo-5vj3g8aa.web.app

(expires Sun, 31 Dec 2023 10:40:30 GMT)

🔥 via Firebase Hosting GitHub Action 🌎

Sign: 4e92cf51659207b0ae3509dc5c40edde50edfec0

Copy link
Contributor

@nickaddy nickaddy left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is not working for me; I tried on the Test Assessments Vue 3 exercise. It is published, but when I try to archive it, I just receive the 'Are you sure?' message shown below:

image

Additionally, the message when you try to archive a published exercise should read: "This exercise must be unpublished before it can be archived" and the user should be prevented from archiving until it has been unpublished and removed from Apply.

@nickaddy
Copy link
Contributor

@warrensearle I've checked with Matt and he is content with how Omar has set this up. However, I've just run through the process and I think that when a user attempts to Archive a Live Published exercise, they should receive a modal: "This exercise is Live on Apply; by clicking accept, you authorise the exercise to be removed from Apply and archived" rather than the standard "Are you sure?" standard message. Is this possible?

@nickaddy nickaddy self-requested a review November 30, 2023 13:43
@warrensearle
Copy link
Member

@nickaddy of course, thank you. It will be done 👍

@warrensearle
Copy link
Member

This has been updated now.

Exercise that is published:
image

Exercise that is not published:
image

@nickaddy
Copy link
Contributor

nickaddy commented Dec 1, 2023

@warrensearle Thanks for sorting. I noticed that the message received when unarchiving needs to be changed as it currently relates to archiving:

image

@warrensearle
Copy link
Member

warrensearle commented Dec 1, 2023

Hi @nickaddy good spot! That message has been updated now so we have:

Unarchiving an exercise:
image

We are not done yet though as I spotted a few extra tasks:

  • Hide/disable the Publish button when an exercise is archived
  • Check and refine the logic for bulk archiving of exercises (or remove this functionality?)
image

@warrensearle
Copy link
Member

Hey @nickaddy as agreed I've removed the bulk archive and bulk delete functionality and also disabled the Publish button for archived exercises.

Have also fixed a bug with the layout.

Please do review again

Copy link
Contributor

@nickaddy nickaddy left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Happy days! Thanks for mopping up those other issues alongside :-)

@warrensearle warrensearle merged commit 8e57934 into main Dec 1, 2023
6 checks passed
@warrensearle warrensearle deleted the feature/2159-disallow-archiving-til-unpublished branch December 1, 2023 12:18
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Disallow archiving until exercise unpublished from website
4 participants