-
Notifications
You must be signed in to change notification settings - Fork 8.5k
DEV: First pass at category_custom_fields
step for Discourse converter
#32905
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
base: dev/mt/intermediate-db-schema
Are you sure you want to change the base?
DEV: First pass at category_custom_fields
step for Discourse converter
#32905
Conversation
end | ||
|
||
def process_item(item) | ||
IntermediateDB::CategoryCustomField.create( |
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.
existing_id
support might be needed here, Chat seeds category custom fields for SiteSetting.staff_category_id
and SiteSetting.general_category_id
. Confirm if it's needed
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.
The importer should do the mapping for existing categories. We shouldn't need to worry about in other steps, I think.
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.
Could you explain how envisage this working?
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.
The converter sets existing_id
for seeded categories. The import step for categories notices the existing_id
and maps it to the seeded category in the destination site. The category doesn't get imported, but the mapping will be stored (similar to how it's done for existing users).
Since the category_id
is mapped, referencing it in category_custom_fields
works and will use the correct seeded category.
4e7cc97
to
30518c1
Compare
30518c1
to
681c53f
Compare
category_custom_fields
step for Discourse converter
This change implements converter step for converting Discourse category custom fields to intermediate DB format needed for import into Discourse
67c4cac
to
90cf9c0
Compare
6a4ffb5
to
f07383b
Compare
This change implements converter step for converting Discourse
category_custom_fields
to intermediate DB format needed for import into Discourse