-
Notifications
You must be signed in to change notification settings - Fork 0
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
Feature/sckan 259 #228
Feature/sckan 259 #228
Conversation
if profile.is_reviewer and instance.state in [SentenceState.OPEN, SentenceState.NEEDS_FURTHER_REVIEW]: | ||
return True | ||
|
||
return user.is_staff |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@zsinnema @ddelpiano I assumed that staff/admins should be able to do any transition except the ones from the system.
@@ -4,24 +4,25 @@ export const duplicatesRowsPerPage = 10; | |||
export const autocompleteRows = 100; | |||
|
|||
export const statementStateToColor: StatementStateToColor = { | |||
draft: "primary", // blue |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@ddelpiano @zsinnema I couldn't find in figma what colours to use so I opted for the ones that make more sense to me:
warning -> applied to states that require changes
info -> applied to states that were processed
primary -> applied to the initial state
success -> applied to everything else
@ddelpiano I left this PR as draft so that we don't have dev change while you are testing the release. Please make the PR ready for review and mark @zsinnema as reviewer when you think it's fine to have this PR merged. |
@afonsobspinto did you test the migrations? |
@zsinnema Locally, yes:
|
@afonsobspinto there are some merge conflicts, can you have a look? thanks |
Closes https://metacell.atlassian.net/browse/SCKAN-259 and https://metacell.atlassian.net/browse/SCKAN-253 (only in the frontend, not in the admin page)
Applies the new state machine transitions as defined here:
https://lucid.app/lucidchart/2d9ff911-1a36-4af4-ad4a-4ee88fb58099/edit?invitationId=inv_9147956b-6d03-4711-b691-706787c27efc&page=3R49srWfLI_t#
(All states V2)
Adds migration to remove the previous constraints
Adds migration to change the deprecated states and add new constraints
Renames statementService to statementStateService (same for sentence).
Moves compile_journey out of the statement state service.
Regenerates the API and fixes some type mismatches
Updated the end to end test (but didn't run it)