cal.com icon indicating copy to clipboard operation
cal.com copied to clipboard

fix: individual settings overwritten on editing locked fields of managed event

Open kart1ka opened this issue 1 year ago • 5 comments
trafficstars

What does this PR do?

Individual Event Limits settings of Team Members of a Managed Event were overwritten when any locked field was changed by the Owner of the particular Managed Event. This was caused because fields of Limit tab were changed to unlocked fields in the PR #11936 and the same was not added in the metadata.unlockedFields within the event record in the database.

Fixes #13183

Loom Video: https://www.loom.com/share/f72aa71623154b308dbc10c5891f7260?sid=4b8367c3-d230-4ef2-aff4-8fa7761670cf

Type of change

  • Bug fix (non-breaking change which fixes an issue)

How should this be tested?

  1. Create a managed event and add a member to it.
  2. Set up some individual settings (e.g. Limit future bookings to 30 weekdays) in the limits section of the member.
  3. Go to the managed event and to the "Advanced" section as the event owner.
  4. Change any locked field (e.g. Activate the "Hide notes in calendar" switch) and save it.
  5. Note that the individual settings in the limit tab of the member does not change.

Mandatory Tasks

  • [x] Make sure you have self-reviewed the code. A decent size PR without self-review might be rejected.

kart1ka avatar Jan 18 '24 09:01 kart1ka

@kart1ka is attempting to deploy a commit to the cal Team on Vercel.

A member of the Team first needs to authorize it.

vercel[bot] avatar Jan 18 '24 09:01 vercel[bot]

Thank you for following the naming conventions! 🙏 Feel free to join our discord and post your PR link.

github-actions[bot] avatar Jan 18 '24 09:01 github-actions[bot]

📦 Next.js Bundle Analysis for @calcom/web

This analysis was generated by the Next.js Bundle Analysis action. 🤖

This PR introduced no changes to the JavaScript bundle! 🙌

github-actions[bot] avatar Jan 18 '24 10:01 github-actions[bot]

@alishaz-polymath to take a look because he recently just opened a PR for this too

keithwillcode avatar Jan 18 '24 19:01 keithwillcode

@kart1ka Thank you for the contribution here, but the issue is currently being handled in another PR. Should be fixed in #13292 🙏

alishaz-polymath avatar Jan 18 '24 19:01 alishaz-polymath