Files
2026-06-28 21:34:58 -04:00

2.3 KiB

2026-06-28T21:21:36Z

You are the Worker for Milestone 2: Backend & DB. Your working directory is /home/ti/git/homaroma/.agents/worker_m2_1. Your task is to implement the backend and database changes for the Premium Mega Menu.

Please perform the following steps:

  1. Update apps/backend/prisma/schema.prisma:
    • Add rootImage String? to the Menu model.
    • Add columnImage String? and hoverImage String? to the MenuItem model.
  2. Run database migration:
    • Run bunx prisma migrate dev --name add_menu_image_fields inside apps/backend/.
    • Ensure the Prisma client is regenerated.
  3. Update packages/types/index.ts:
    • Update the MenuItem interface to include optional columnImage?: string | null and hoverImage?: string | null.
    • Update the Menu interface to include optional rootImage?: string | null.
  4. Update apps/backend/src/routes/menus.ts:
    • Modify the request schema validation (using Elysia TypeBox validator t) and payload parsing in both the POST / and PUT /:name routes to support rootImage, columnImage, and hoverImage fields.
    • Modify database transaction block in PUT /:name to insert/update the new fields (columnImage, hoverImage) for menu items, and update rootImage for the menu.
  5. Update MCP Server files if needed:
    • Check and update apps/mcp-server/menu-tools.ts helper function validateMenuItems to support columnImage and hoverImage (both string or null).
    • Check and update apps/mcp-server/menu-toolkit.ts to add rootImage, columnImage, and hoverImage to the upsert_menu tool schema definition, pass them in case "upsert_menu" handler to backend request, and display rootImage in dryRun preview.
  6. Verify backend compilation:
    • Run typechecks and builds for backend, types, and mcp-server. Ensure no errors.

Write a progress report outlining exactly what files were modified, and the build results to /home/ti/git/homaroma/.agents/worker_m2_1/handoff.md.

MANDATORY INTEGRITY WARNING: DO NOT CHEAT. All implementations must be genuine. DO NOT hardcode test results, create dummy/facade implementations, or circumvent the intended task. A Forensic Auditor will independently verify your work. Integrity violations WILL be detected and your work WILL be rejected.

Once finished, send a message back with the path to your handoff.md and a summary of your results.