Commit Graph

539 Commits

Author SHA1 Message Date
DmytroHryshyn 28acbe549a
chore: [app dir bootstrapping 9]: replace useSearchParams with useCompatSearchParams hook (#12056)
Co-authored-by: zomars <zomars@me.com>
2023-11-16 13:38:27 -07:00
Carina Wollendorfer 7d09ccb0d7
fix: add sendgrid-specific header only for SendGrid smtp server (#11932)
Co-authored-by: CarinaWolli <wollencarina@gmail.com>
2023-11-16 13:51:30 -03:00
Morgan 0a39f53a4b
fix(stripePaymentCallback): better errors (#12223)
Co-authored-by: Joe Au-Yeung <65426560+joeauyeung@users.noreply.github.com>
Co-authored-by: Keith Williams <keithwillcode@gmail.com>
2023-11-16 08:48:46 +00:00
Udit Takkar 371a0f7245
feat: booking errors logging (#12325)
Fixes: https://github.com/calcom/cal.com/issues/12297
Fixes https://github.com/calcom/cal.com/issues/11234

- Displaying error message and X-Vercel-Id( Unique Request Id ) to user on book event form
- Improve error logging 
- Add Error codes

Few things to discuss

1) How to handle calendar integration failures ?
   Currently if for example google integration is broken and someone is trying to book that person then we log the error but don't inform the user that the google calendar is broken and the meeting goes through.
   
 Should I throw error when integration is broken ?
   
<img width="758" alt="Screenshot 2023-11-12 at 12 52 36 AM" src="https://github.com/calcom/cal.com/assets/53316345/c4d921c4-9c8a-4b9b-82a2-bbe0fdbcb3d4">

   
2)  How to handle conferencing app failures? 
 We just default to Cal Video  as location if we are unable to generated conferencing url and log the error and not inform the user(organizer).
2023-11-15 12:52:19 -07:00
Carina Wollendorfer 270d4f6e82
fix: round-robin booked out of availability (#12376)
## What does this PR do?

Fixes that it can happen that Round Robin host is booked outside of availability. 

I found and fixed the following two scenarios where this can happen: 
- when host has a date override
- when host is available for only a part the event time (for example, booking time 9:00-11:00 and user is only available between 10:00-11:00)

Fixes #10315
Fixes #11690

It also fixes that it can happen that round robin doesn't correctly pick the luck user (least recently booked). This happened when a user was an attendee of a booking before, then we always compared this booking and never the actual last booking of this user. 

## Type of change

- [x] Bug fix (non-breaking change which fixes an issue)

## How should this be tested?

#### Booked outside of availability: 
1. 
- Create Round Robin event and assign user1 and user2 as round robin hosts
   - event duration: 120 minutes 
- user 1 availability: 
  - Monday to Friday 9:00-17:00
- user2 availability: 
  - Monday to Friday 10:00-17:00
- Book event at a 9:00 slot -> check if i user1 is booked 
- Book event again at a 9:00 slot -> check if user1 is booked again (user2 is not available at that time)

2.
- Change availability of user2
   - Mark Monday as unavailable 
   -   Add date override on any day this month 
- Book any Monday this month -> see that user 1 is booked 
- Again Book any Monday this month -> see that user 1 is booked again 

#### Wrong lucky user 
- Book event and add user1's email as the attendee email address
- Book several slots where both users should be available, and see that it alternates between user1 and user2 (before it ended up always booking user1)

## Mandatory Tasks

- [ ] Make sure you have self-reviewed the code. A decent size PR without self-review might be rejected.
2023-11-15 12:49:03 -07:00
DmytroHryshyn 48e7b616b8
chore: [app dir bootstrapping 10] adds ab tests middleware (#12045)
## What does this PR do?
 - Adds AB tests middleware that redirects users to the app-dir pages with probability that is defined by env var
 
<!-- Please include a summary of the change and which issue is fixed. Please also include relevant motivation and context. List any dependencies that are required for this change. -->

Fixes # (issue)

<!-- Please provide a loom video for visual changes to speed up reviews
 Loom Video: https://www.loom.com/
-->

## Requirement/Documentation

<!-- Please provide all documents that are important to understand the reason of that PR. -->

This PR requires new env variables:
`APP_ROUTER_EVENT_TYPES_ENABLED`  - boolean that defines if app dir event-types page redirect is enabled
`AB_TEST_BUCKET_PROBABILITY` - number [0, 100] that defines the percentage of users getting redirected to the app dir pages

## Type of change

<!-- Please delete bullets that are not relevant. -->

- [ ] Bug fix (non-breaking change which fixes an issue)
- [x] Chore (refactoring code, technical debt, workflow improvements)
- [ ] New feature (non-breaking change which adds functionality)
- [ ] Breaking change (fix or feature that would cause existing functionality to not work as expected)
- [ ] This change requires a documentation update

## How should this be tested?

<!-- Please describe the tests that you ran to verify your changes. Provide instructions so we can reproduce. Please also list any relevant details for your test configuration. Write details that help to start the tests -->
Does not requires testing, implements middleware as a dead code

## Mandatory Tasks

- [x] Make sure you have self-reviewed the code. A decent size PR without self-review might be rejected.
2023-11-15 11:06:18 -07:00
Erik a804a29516
feat: Stripe paid apps flow (#12103)
* chore: Stripe paid apps flow

* chore: Subscription

* chore: Webhooks

* chore: Abstract functions

* chore: Lockfile

* chore: Webhook handler

* chore: Use catch-all

* chore: Webhook changes, etc

* chore: Cleanup

* chore: Use actual price id

* chore: Updates

* chore: Install normally until expiry date

* Disable team install for paid apps and cal.ai\

* Fix the same at another place

* Fix Typescript error

* redactedCause doesnt have message has enumerable prop

* Fix reinstallation of an already installed app

* chore: Remove unused deps

* chore: Ensure index

* chore: Price in usd

* chore: PR suggestion

* Fix missing packages in yarn.lock

---------

Co-authored-by: Hariom <hariombalhara@gmail.com>
Co-authored-by: Peer Richelsen <peeroke@gmail.com>
2023-11-15 09:29:41 -03:00
Mehul a519941b81
fix avatar remove button (#12249) 2023-11-15 15:23:33 +05:30
Hariom Balhara 9d06f6dd0e
fix: Fix 'Book a new time' link in request-reschedule for Team Event (#12261)
Co-authored-by: Carina Wollendorfer <30310907+CarinaWolli@users.noreply.github.com>
Co-authored-by: Alex van Andel <me@alexvanandel.com>
2023-11-14 13:23:44 -07:00
Hariom Balhara 8c2ce972cc
fix: team booking page having same slug as the org (#12213) 2023-11-14 18:25:46 +05:30
Carina Wollendorfer f29328e6a2
fix: meeting url variable in workflow notifitcations (#12308)
Co-authored-by: CarinaWolli <wollencarina@gmail.com>
2023-11-13 09:28:15 -05:00
Peer Richelsen 518ec4f605
feat: added /enterprise upgrade tip (#12207) 2023-11-13 13:55:28 +02:00
Hariom 412f15814e Add removeItem to webstorage 2023-11-11 11:16:35 +00:00
gitstart-app[bot] e4b2464548
fix: Fix "could not book the meeting" issue (fix-confirmBookingIssue) (#12305)
Co-authored-by: gitstart-calcom <gitstart-calcom@users.noreply.github.com>
Co-authored-by: GitStart-Cal.com <121884634+gitstart-calcom@users.noreply.github.com>
2023-11-09 18:43:48 -03:00
Ash Davis 0d1b6ea5b2
feat: configure availability time picker interval by env variable (#12174) 2023-11-09 09:50:42 -05:00
Hariom Balhara 8deee738c2
fix: Recurring Booking - Check for conflicts on first 2 slots only (#11774)
* Add recurring booking tests and fix the bug

* Fix recurring booking tests supporting the new link verification assertions

* Convert tab to spaces
2023-11-09 17:00:51 +05:30
Carina Wollendorfer 7bb42ba577
fix: booking limits (#12172)
Co-authored-by: CarinaWolli <wollencarina@gmail.com>
2023-11-07 14:17:05 -03:00
gitstart-app[bot] d28e20e92e
fix: Fix "Could not book the meeting" issue (fix-bookingIssue) (#12252)
Co-authored-by: gitstart-calcom <gitstart-calcom@users.noreply.github.com>
2023-11-07 12:33:49 -03:00
Carina Wollendorfer 8b89d6635a
fix: recurring events with calendar connections (#12250)
Co-authored-by: CarinaWolli <wollencarina@gmail.com>
2023-11-07 12:09:56 -03:00
Benny Joo 13ec810cb9
fix: [app dir bootstrapping 8] `useParamsWithFallback` hook and add tests (#12041)
* fix: first solution using RouterContext

* fix: second solution by importing router from next/compat/router

* fix return type
2023-11-07 13:48:02 +00:00
Alex van Andel dd0c2dbff2
fix: Set the dateFrom to startOf day otherwise bad fromOffset is used (#12210) 2023-11-03 03:13:42 +00:00
Hariom Balhara d8356e9a5b
fix: Make sure if header is set already, it isn't set again (#12194) 2023-11-02 09:22:16 -03:00
Hariom Balhara 9a80bb6194
fix: Skip failing tests (#12144) 2023-10-30 09:05:05 +00:00
Joe Au-Yeung 2831fb2b57
refactor: Falling Back to `FirstCalendarCredential` (#11986) 2023-10-27 11:52:56 -04:00
Siddharth Movaliya f9ad99e572
feat: Lock timezone on booking page (#11891)
Co-authored-by: CarinaWolli <wollencarina@gmail.com>
2023-10-25 14:16:01 -04:00
Hariom Balhara af801df421
Fixes in teams and avatar across org (#12070) 2023-10-25 15:57:29 +05:30
Greg Pabian a9535d3fd4
chore: [app dir bootstrapping 4.1] check nullability of navigation hook return values part 2 (#12065)
Co-authored-by: Omar López <zomars@me.com>
2023-10-24 20:52:59 +00:00
Hariom Balhara b934c74c30
fix: Avatar slug and cal links for cross org users (#12031) 2023-10-24 16:12:36 +05:30
zomars 154af1367a hotfix: unreachable rate limits 2023-10-23 15:14:01 -07:00
Udit Takkar aa54c013f8
fix: allow dots in username (#11706)
* fix: allow dots in username

* test: added unit tests for slugify

* test: add test for username change

* tests: add test  for username and dynamic booking

* fix: type error

---------

Co-authored-by: Peer Richelsen <peeroke@gmail.com>
2023-10-23 13:37:30 +01:00
Greg Pabian 39cfe18ffe
chore: [app dir bootstrapping 4] check nullability of navigation hook return values (#12005) 2023-10-20 16:47:05 -07:00
Hariom Balhara e2414b174a
Handle non-org team with same slug as the organizations requestedSlug (#11996) 2023-10-20 00:05:34 +05:30
Benny Joo 63416d4f33
chore: update `tslog` from 3.2.1 to 4.9.2 (#11717)
Co-authored-by: zomars <zomars@me.com>
2023-10-17 19:00:48 +00:00
DexterStorey 9e927af813
feat: add rate limiting and more error handling to Cal.ai (#11898)
Co-authored-by: tedspare <ted.spare@gmail.com>
2023-10-17 18:26:49 +00:00
Hariom Balhara 59faffe0d5
fix: Requires Confirmation when organizer reschedules (#11848) 2023-10-13 10:22:57 -07:00
sean-brydon dc9a4f0dba
feat: Add rate limting to API (#11783) 2023-10-11 23:44:00 +01:00
Carina Wollendorfer 9d7d838131
fix: missing last day of month
## What does this PR do?

- Fix that the last day in Oktober was always shown as unavailable
This happened when availability was in Europe/London timezone

- Fix that the last day of November was always shown as unavailable
This happened also for other timezones

## Type of change

- [x] Bug fix (non-breaking change which fixes an issue)

## How should this be tested?

I recommend testing it in staging instead of local, as I experienced some different behaviors on local 

- Reproduce the 2 bugs as described before my fix
- If you were able to reproduce it, see if it is fixed with my fixes in this PR (last day of octber and November should be shown as available)
- Check if availability starts and ends at the correct time on days were DST happens
2023-10-11 11:30:35 -07:00
Alex van Andel df29376b0e
fix: Revert deletion of getLocaleFromRequest in #11534 (#11835) 2023-10-11 17:36:32 +00:00
Udit Takkar ebc70feef0
refactor: org settings (#11682) 2023-10-11 10:04:54 +01:00
Greg Pabian 39c3ef0d94
chore: ensure compat type definitions do not break existing types (#11741) 2023-10-10 14:50:15 -07:00
Alex van Andel 150dc3acb9
fix: Remove credentials and some ts fixes (#11794) 2023-10-10 10:08:06 -07:00
Greg Pabian 778485b31d
refactor: implementation of locale calculated server-side (#11534) 2023-10-10 09:36:28 -07:00
Hariom Balhara 2faf24fb98
test: Add collective scheduling tests (#11670) 2023-10-10 09:46:04 +05:30
GitStart-Cal.com 9857b46121
chore: add Navigation in storybook (CALCOM-10760) (#10867)
Co-authored-by: gitstart-calcom <gitstart@users.noreply.github.com>
Co-authored-by: gitstart-calcom <gitstart-calcom@users.noreply.github.com>
Co-authored-by: Peer Richelsen <peeroke@gmail.com>
2023-10-09 08:45:54 +00:00
alannnc b4315b186a
fix: seated event type public id cancels/reschedule entire booking without auth (#11667)
Co-authored-by: Keith Williams <keithwillcode@gmail.com>
2023-10-06 13:17:15 -03:00
Aldrin 3e08c66888
refactor: Use template literal instead of '+' operator (#11444)
Co-authored-by: Peer Richelsen <peeroke@gmail.com>
Co-authored-by: zomars <zomars@me.com>
2023-10-03 11:52:19 -07:00
Hariom Balhara a186b130cb
fix: Use only the first connected calendar as fallback to create event (#11668) 2023-10-03 10:45:18 -07:00
Hariom Balhara 3ca7456885
test: Booking flow App failure and ics file tests and improved logging (#11646) 2023-10-02 16:21:04 +05:30
Peer Richelsen 07bfaec24e
fix: inverted logos and new logo for cal video (#11633)
* new logo for cal video

* fixed cal video and other inverted icons

* Discard changes to apps/web/components/eventtype/EventAdvancedTab.tsx

* moved function to lib
2023-10-02 11:36:37 +01:00
Hariom Balhara caf1b4c5d7
test: More tests in booking flow (#11510) 2023-09-30 13:28:52 +00:00