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

content modelling/949 change name to title #9997

Merged
merged 3 commits into from
Mar 3, 2025

Conversation

Harriethw
Copy link
Contributor

@Harriethw Harriethw commented Feb 27, 2025

https://trello.com/c/bMiirLNG/949-rate-object-attribute-should-be-title

Can be merged once Publishing API changes made: alphagov/publishing-api#3165

Wherever we have the name key on an embedded object it should now be title - including where the key for the object is generated, and on versions.

  • add rake task to change name to title on embedded objects
  • change embedded object name to title
  • change rename updated_embedded_object_name to updated_embedded_object_title

⚠️ This repo is Continuously Deployed: make sure you follow the guidance ⚠️

Follow these steps if you are doing a Rails upgrade.

@Harriethw Harriethw force-pushed the content-modelling/949-change-name-to-title branch 4 times, most recently from 099dcab to 7211bfd Compare February 28, 2025 11:44
@Harriethw Harriethw marked this pull request as ready for review February 28, 2025 11:44
@Harriethw Harriethw requested a review from pezholio February 28, 2025 11:44
@Harriethw Harriethw force-pushed the content-modelling/949-change-name-to-title branch from 7211bfd to c2e21b5 Compare February 28, 2025 12:46
Copy link
Contributor

@pezholio pezholio left a comment

Choose a reason for hiding this comment

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

This seems like all the main parts are catered for. Let's give it a thorough test when it's all in 👍

This follows changes to the embedded object schema
in Publishing API. [1]

It's a bit complicated because we have been using
the `name` everywhere as the key/slug for a rate
within the JSON `details` of a block - so a fair
bit of code touched to update that.

[1] alphagov/publishing-api#3165
this changes the column name on `versions` to
reflect that the new key is `title` on embedded
objects.
@Harriethw Harriethw force-pushed the content-modelling/949-change-name-to-title branch from c2e21b5 to 2e25e55 Compare March 3, 2025 09:49
@Harriethw Harriethw merged commit a2e1777 into main Mar 3, 2025
19 checks passed
@Harriethw Harriethw deleted the content-modelling/949-change-name-to-title branch March 3, 2025 10:05
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.

2 participants