Skip to content

[BUG] Duplicate meal plan for a client user should have the current user assigned as they cannot assign themselves #698

@shanthisa

Description

@shanthisa

Describe the bug
Since we removed the functionality to assign user, when we create a duplicate meal plan the new meal plan will not have any user assigned.

To Reproduce
Steps to reproduce the behavior:

  1. Go to 'mealplan page' as a client (app_user role)
  2. Click on 'copy' button in a mealplan
  3. Observe the user of the newly created duplicate meal plan

Expected behavior
The user should be the current logged in user as the client will want to have their id to be associated with their meal plan.

Additional context
Solution: So when it is app_user role who has logged in, duplicate_meal_plan should take the current person id as p_id.

Metadata

Metadata

Assignees

Labels

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions