Skip to content

feat: Extended the menu/order metadata#18

Draft
radektomasek wants to merge 1 commit intomasterfrom
feat_extend_menu_artifacts
Draft

feat: Extended the menu/order metadata#18
radektomasek wants to merge 1 commit intomasterfrom
feat_extend_menu_artifacts

Conversation

@radektomasek
Copy link
Copy Markdown
Contributor

Enrich selections with itemGroup and salesCategory names

Resolves missing human-readable names on the selections table by building in-memory lookup dictionaries from the menus data and injecting them before writing orders to CSV.

Changes

  • component.py: Added _item_group_names and _sales_category_names dicts on __init__
  • component.py: download_menus now populates both lookup dicts from menus_menuGroups and menus_menuGroups_menuItems parsed output
  • component.py: download_orders enriches each record in orders_checks_selections with itemGroup_name and salesCategory_name before writing
  • component.py: Reordered run() to call download_menus before download_orders so lookups are populated in time
  • parser_mapping.json: Added itemGroup_name and salesCategory_name to selections.column_mappings

How to test

  1. Configure the component with both menus and orders in the endpoints list
  2. Run the component against a restaurant that has orders
  3. Open the output selections.csv and verify:
    • itemGroup_name is populated with the menu group name (e.g. "Burgers") and matches the itemGroup_guid
    • salesCategory_name is populated (e.g. "Food") and matches the salesCategory_guid
    • Cross-reference both values against menuGroups.csv and menuItems.csv from the same run
  4. Verify selections where itemGroup_guid or salesCategory_guid is empty/null produce empty strings rather than errors
  5. Run with multiple restaurants to confirm lookups accumulate correctly across restaurants

@radektomasek radektomasek requested a review from pandyandy April 10, 2026 21:30
@radektomasek radektomasek self-assigned this Apr 10, 2026
@radektomasek radektomasek marked this pull request as draft April 10, 2026 21:30
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.

1 participant