-
Notifications
You must be signed in to change notification settings - Fork 745
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
sitemappriority for new page set to 0.5 #4441
sitemappriority for new page set to 0.5 #4441
Conversation
Is the history of this issue that 0.5 was the default before the Persona Bar, and then we lost that default when the page settings was moved to the Persona Bar? We probably also need to add a script to add 0.5 as the value for all pages missing a value, right? I had thought that there was a setting somewhere to control the default value, but didn't find it after a quick search. Does anyone remember that being configurable, or did I make that up? |
Yes, that is indeed what happened. In the server side code you will find the default too, if you search for "0.5F", which is probably why it does work when adding multiple pages.
I don't think that's possible, because we can't see which pages have been set to 0 intentionally, and which because it was the default.
I'm not aware of that setting. I looked at what needs to be done to create such a setting, but I think that would be a nice enhancement and not so much a bug fix. |
I have put this on hold to review further. If memory serves good we have a site level default priority setting that had a problems with the value being a double in one place and an int somewhere else. I kinda remember there was a PR to fix that issue but I am on mobile now. At any rate if that is the case, we should default to that value and not 0.5 IMO |
Well, apparently memory did not serve good, the other PR must be just solving that value mismatch on one of those exiting fields, but we do not have a site-level default. So I am ok with this PR. |
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.
Looks good to me
Fixes #3081
Summary
I added the default value for sitemapPriority on the client, since several other "controls" get their ddefault values there too, and since I didn't really find a better place for it.
I concidered PagesController.GetDefaultSettings but that didn't seem right either.
This change adds the default value to the property that is being used for the value of the dropdown. When the page is saved, this value is posted to the server too and correctly saved.