Co-creator preference and invitations

Description

Add a new preference option "Allow others to invite me to be a co-creator."

If User A has the preference option enabled, then:

  1. User A should see a "Creator Invitations" link in their dashboard sidebar.

  2. If User B tries to add User A as a co-creator, then:

    • The creation's byline should not list A.

    • The creation should not appear in any searches or listings related to A.

    • When User B edits the creation:

      • They should see that User A is invited.

      • They should not be able to delete the invitation.

    • User A should receive an email telling them that they've been invited.

    • The invitation should appear on User A's creator invitations page.

    • When User A tries to view the creation:

      • They should see a notice telling them they have an invitation.

      • They should not see the "Edit" button.

      • They should be able to see the creation even if it's an unposted draft.

      • They should be able to see the creation even if it's an unrevealed work.

  3. When viewing the creator invitations page:

    • Invitations should be arranged in decreasing order by the date of the invitation.

    • If the user have more than 20 invitations, the invitations should be split across multiple pages.

    • The user should be able to select invitations with checkboxes and either Accept or Reject.

    • If the user accepts or rejects an invitation on a later page, they should be redirected back to the same page that they were on when they pressed the "Accept" or "Reject" button.

  4. If User A accepts an invitation, then:

    • The invitation should disappear from the invitations page.

    • The creation's byline should list A.

    • The creation should appear in A's work/series listings after a few minutes.

    • User A should be able to edit the creation.

  5. If User A rejects the invitation, then:

    • The invitation should disappear from the invitations page.

    • The creation's byline should not list A.

    • When User B edits the creation:

      • They should no longer see User A listed as being invited.

      • They should be permitted to re-invite User A to the same creation.

  6. If an archivist tries to add User A as a co-creator, then:

    • User A should be added as a co-creator, not just invited.

    • User A should immediately be listed as a co-creator on the creation.

    • The creation should appear in User A's listings.

    • User A should receive an email telling them that they're listed as a co-creator.

If User A has the preference option disabled (the default), then:

  1. User A should not see a "Creator Invitations" link in their dashboard sidebar.

  2. If User B tries to add User A as a co-creator, then:

    • User B should see an error message saying that's not allowed.

    • User A should not receive an email.

    • The creation should not appear in any searches or listings related to User A.

  3. If A and B are already listed as co-creators on a work, then:

    • User B should be able to edit the work.

    • User B should be able to add User A to any chapter of that work.

    • However, they should not be able to add User A to a chapter of another work.

    • User B should be able to add the work to a series, thus adding User A to the series.

    • User B shouldn't be able to add User A to any other series.

  4. If User A had an invitation from User B before they disabled co-creators, then:

    • User A should not see "Creator Invitations" link in their dashboard sidebar.

    • However, when User A views the work, they should see a notice about an invitation.

    • The notice should link to their "Creator Invitations" page.

    • User A should be able to accept/reject the invitation as normal.

    • User B should be able to edit the creation.

  5. If an archivist tries to add User A as a co-creator, then:

    • They shouldn't get an error.

    • User A should immediately be listed as a co-creator on the creation.

    • The creation should appear in User A's listings.

    • User A should receive an email telling them that they're listed as a co-creator.

Miscellaneous Notes:

  1. Manually adding orphan_account as a co-creator will result in the invitation being automatically accepted.

  2. It's possible to both be listed as a co-creator and invited to be a co-creator simultaneously, if you have multiple pseuds that are invited to the same work and only accept one invitation. However, when you edit the creation, the invitation will silently disappear. (I'm not sure if this behavior is desirable, but it occurs because you implicitly rejected the invitation by not selecting the invited pseud from the "Creator/Pseud(s)" box while editing. And it's not like you need to keep the invitation around, since you're already listed as a co-creator and can change your listed pseuds at any time.)

Other Things to Test:

  1. Check dashboard fandom lists for users and pseuds, since the existing code uses a join on the creatorships table, but it shouldn't include works where the user has only been invited.

  2. Try creating/adding a series to an invalid work, both when first creating the work and when updating it. (An easy way to do this is to enter an invalid Fandom, like "%%%" or some such.)

  3. Make sure that importing still works.

  4. Make sure that importing through the Works API still works as expected.

  5. Make sure that you can still claim a work that was imported for you.

  6. Make sure that you can still add/remove owners from a TagSet.

  7. Make sure that you can still add/remove participants from a Collection.

  8. Try deleting a pseud that has some co-created works/series/chapters and some invitations, and make sure that they behave as expected. Also try checking some comments by that pseud to make sure that the comment author is updated.

  9. Orphan some works and/or series – preferably with some tricky co-creator situations (like a work with different creators listed on different chapters, or a series with different creators listed on different works).

  10. Use the "Remove Me As Co-Creator"/"Remove Me As Author" button for works/series/chapters to make sure that it behaves as expected, particularly when the co-creators are set up in tricky ways.

  11. Make sure that you can still fulfill assignments.

  12. Try inviting co-creators on the Edit Multiple Works page.

  13. Try using the Edit Multiple Works page to change which of your pseuds are listed in the byline.

  14. Try using the Edit Multiple Works page to remove yourself as co-creator.

  15. Try deleting a user who has co-created some works.

Assignee

ticking instant

Reporter

Sarken

Roadmap

Users
Works

Priority

High

Affects versions

Fix versions

Components

BackEnd
FrontEnd

Difficulty

Medium

Required Access Level

Archivist

Milestone

Internal 0.9
Configure