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

Feature/auth rework #44

Merged
merged 30 commits into from Nov 29, 2020
Merged

Feature/auth rework #44

merged 30 commits into from Nov 29, 2020

Conversation

itinerare
Copy link
Collaborator

@itinerare itinerare commented Nov 17, 2020

  • Rework alias storage; move to new table
  • Change verification checking and alias setting to fit new storage method
  • Rework user alias checking/display for new storage method
  • Add additional information to sites config for construction of links, etc
  • Add auth and primary_alias toggles to sites config-- controlling whether it should be offered as an auth provider and whether aliases from the site can be a user's primary alias
  • Build out a single alias info migration command; has an additional option, --drop-columns, which drops the alias columns when it is finished moving information either to user_id or url columns. It's recommended to run it without once and ensure data has been moved properly before running it again with the option.
  • Update character ownership to use URL instead of alias
  • Update character owner display to use prettyProfileLink function/handle a variety of sites
  • Update character logs to use URL
  • Add helper function to check if a URL is from a site used for auth, and if so, if it corresponds to an on-site user
  • Add helper function to format 'name'@'link' string without link
  • Tidy up art/design credit entry
  • Remove search by alias from masterlist/MYO/sublist search
  • Update item artist credits to new system/to use user ID
  • Update user alias display in admin panel to support multiple aliases per user, specify site the alias is associated with
  • Update clearing user aliases to support multiple aliases per user
  • Fix MYO slots not being transferrable to alias/URL/offsite users Cannot admin transfer MYO to an alias. #49

- Add more validation on art/design credit linking
Thanks to Cy for table structure
- Create user alias table
- Add has_alias bool to users table
- Alter User model to suit, create UserAlias model
- Add basic url to sites config for construction of links from aliases
- Add command for moving existing aliases from users table to user_aliases table
- Index both the above and url column of character image creators
- Consolidate alias update commands into one and update character image creator command for new system
- Update character logs
- Update alias migration command with character logs
- Add helper function to check if an alias belongs to a site used for auth and if so, to a user
- Add helper function to just return 'name'@'site' without link
- Tidy up art/design credits
@itinerare itinerare added this to the v2.0.0 milestone Nov 17, 2020
Copy link
Owner

@corowne corowne left a comment

Choose a reason for hiding this comment

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

Looks good, just a few things:

  • Admin panel (editing a user) - in the clear alias section, the alias textbox still uses the old alias as its value so the box is blank
  • Admin\Users\UserController.php - related to the above; postUserAlias (to clear the old alias) needs to be updated to use the new alias table too
  • BrowseController.php - masterlist character/MYO/sublist search by username still searches on owner_alias, user search by alias still searches on alias column on users

(Also not sure if within scope of this update - items still use artist_alias)

app/Models/User/User.php Outdated Show resolved Hide resolved
app/Models/User/UserAlias.php Outdated Show resolved Hide resolved
app/Helpers/Helpers.php Outdated Show resolved Hide resolved
- Add item artist alias migration to command
- Add more feedback to alias migration command as it runs
- Add validation to character owner URL
- Add tag stripping to report URLs
- Make submission URL nullable/non-required
…iases

- Update user alias clearing for new storage system/to support multiple aliases
- Fix display bug on admin index page
@itinerare
Copy link
Collaborator Author

All requested changes made-- I updated item artists to the new system as well. Going to take a look at addressing #49 before requesting review again though.

@itinerare itinerare linked an issue Nov 25, 2020 that may be closed by this pull request
@itinerare itinerare mentioned this pull request Nov 25, 2020
28 tasks
Copy link
Owner

@corowne corowne left a comment

Choose a reason for hiding this comment

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

Looks good I think, just one last thing!

…text for multiple aliases

- Add checks to see if user has remaning aliases, and if any are valid primary aliases, in alias clear processing
Copy link
Owner

@corowne corowne left a comment

Choose a reason for hiding this comment

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

Good to go I think!

@itinerare itinerare added the reviewed Pull requests that have received community review and are pending merge label Nov 29, 2020
@itinerare itinerare merged commit 0517c23 into develop Nov 29, 2020
@itinerare itinerare deleted the feature/auth-rework branch November 29, 2020 13:08
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
reviewed Pull requests that have received community review and are pending merge
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Cannot admin transfer MYO to an alias.
2 participants