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

Set a default display name only when none is specified #15013

Merged
merged 3 commits into from
Jan 8, 2024

Conversation

giannik
Copy link
Contributor

@giannik giannik commented Jan 8, 2024

fixes #14985

@hishamco
Copy link
Member

hishamco commented Jan 8, 2024

I saw you closed the PR #15012, you can fix the code on the same PR next time

@giannik
Copy link
Contributor Author

giannik commented Jan 8, 2024

@hishamco yep i messed up something.

@MikeAlhayek MikeAlhayek changed the title set field display name only if empty Set a default display name only when none is specified Jan 8, 2024
@MikeAlhayek
Copy link
Member

@giannik thank you for looking into this. I was actually getting ready to submit a PR then saw yours. So instead, I hijacked you PR to provide a complete solutions.

In your original PR, creating a field from migration will cause an exception. So I update the code to ensure it works on both cases "UI or migration"

@MikeAlhayek MikeAlhayek enabled auto-merge (squash) January 8, 2024 21:32
@MikeAlhayek MikeAlhayek merged commit 0dab071 into OrchardCMS:main Jan 8, 2024
3 checks passed
MikeAlhayek added a commit that referenced this pull request Jan 8, 2024
@MikeAlhayek MikeAlhayek mentioned this pull request Jan 8, 2024
@MikeAlhayek MikeAlhayek added this to the 1.8 milestone Jan 9, 2024
urbanit pushed a commit to urbanit/OrchardCore that referenced this pull request Mar 18, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Editing a field of a content type causes the display name to change directly to the technical name.
3 participants