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

Add gender support for performer #371

Merged
merged 12 commits into from
Mar 31, 2020

Conversation

hiddenpants255
Copy link
Contributor

I have added "gender" field in "performers" table and update the UI to allow gender selection.

@hiddenpants255
Copy link
Contributor Author

I was branched from wrong commit. Reversing b6d722a, which is for different PR.

@bnkai
Copy link
Collaborator

bnkai commented Feb 16, 2020

From a quick look at the code it seems to me that the import/export functionality (task_import.go task_export.go ) isn't updated to reflect the addition of the gender attribute.

@WithoutPants
Copy link
Collaborator

I'd prefer to have the gender be an enum of possible values (like in https://github.com/stashapp/stash-box/blob/stash_prototype/graphql/schema/types/performer.graphql) rather than a free-text field.

@bnkai bnkai added the feature Pull requests that add a new feature label Feb 29, 2020
@yoshnopa
Copy link
Contributor

yoshnopa commented Mar 7, 2020

Can I do anything to help on this one?
The import and export are easy enough and I can add them, but I don't quite understand what about the enum should be done. There are no enums in the current stash code in that regard (for example, compare the code for ethnicity, which should work in a similar if not identical fashion). Instead, the code you show is from another project. Could you maybe explain @WithoutPants

@WithoutPants
Copy link
Collaborator

The stashbox code I linked is adapted from the same codebase as stash, so shouldn't be too difficult to port over. You'll need to add the gender enum and change the gender types of the Performer type and the inputs, as well as the filter. The stashbox code should also give an indication as to how the translation works between enum and string.

@WithoutPants
Copy link
Collaborator

Changed the gender field to an enum of: Male, Female, Transgender Male, Transgender Female, Intersex.

Added import/export changes.
Bumped the migration version number. May need to do it again depending on when it is merged.
Ported UI changes to 2.5 and added filtering.

@lots0logs
Copy link

bump

😇

@WithoutPants WithoutPants merged commit 494b794 into stashapp:develop Mar 31, 2020
@WithoutPants WithoutPants added this to the Version 0.2.0 milestone Apr 1, 2020
Anon247 pushed a commit to Anon247/stash that referenced this pull request Apr 11, 2020
Co-authored-by: HiddenPants255 <>
Co-authored-by: WithoutPants <[email protected]>
Tweeticoats pushed a commit to Tweeticoats/stash that referenced this pull request Feb 1, 2021
Co-authored-by: HiddenPants255 <>
Co-authored-by: WithoutPants <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature Pull requests that add a new feature
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants