Skip to content

fix(custom_fields): serialize legacy meeting objects as a list#875

Open
TahaKhan998 wants to merge 1 commit into
CERNDocumentServer:masterfrom
TahaKhan998:fix/issue-865-conference-ui-compatibility
Open

fix(custom_fields): serialize legacy meeting objects as a list#875
TahaKhan998 wants to merge 1 commit into
CERNDocumentServer:masterfrom
TahaKhan998:fix/issue-865-conference-ui-compatibility

Conversation

@TahaKhan998

@TahaKhan998 TahaKhan998 commented Jul 23, 2026

Copy link
Copy Markdown

Closes #865
This pr adds a serialize-only compatibility list field that wraps a legacy object as a one-item list for reads, leaves arrays unchanged.

)


class BackwardCompatibleMeetingList(fields.List):

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Thanks for taking this one! wouldn't it be easier to implement this only on the new jinja template (CDSMeeting)? Did you consider that?

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

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

I did think about that. A Jinja only fix in CDSMeeting.html would cover the record page, but the edit form still loads custom_fields through the schema dump into ArrayField, so a legacy object would still break there. Doing the wrap in serialize felt cleaner so both paths get a list without touching the widget or allowing object writes.

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.

UI backward compatibility for object conference field

2 participants