Commit Graph

257 Commits (637fe4d49c0e7964baf30eed03491fba0f71ffc0)

Author SHA1 Message Date
Alex van Andel 637fe4d49c Allow '0' minimumBookingNotice 2021-12-09 01:45:16 +01:00
Alex van Andel 878c8b8248
Reversed order of custom inputs & notes (#1268) 2021-12-07 21:05:29 +00:00
Joel Lu c43e6783a7
Fix: duplicate team name no prompt (#1267)
* Fix: duplicate team name no prompt

* Fix syntax error for error message
2021-12-07 15:04:34 +00:00
Rory Hughes c109ab1e30
Ensure credential objects come oldest first (#1258)
Given the credentials are loaded based on userId, sort is not consistent.
Without this, events are booked on whichever calendar credential is loaded first. 
813eaa83b7/lib/events/EventManager.ts (L240-L244)

Co-authored-by: Bailey Pumfleet <pumfleet@hey.com>
2021-12-06 13:25:22 +00:00
Alex van Andel 22aa083883
Adds eventTypeId as a parameter (#1217) 2021-12-03 16:18:31 +00:00
Alex van Andel 8c1b69cc0f
Feature/field prefills (#1249)
* Needs more testing, but looks functional

* Add metadata feature to booking create payload

* Forward URL parameters given in link

* Moved stringifying of custom inputs to backend
2021-12-03 10:15:20 +00:00
Mihai C 8322e5c8d1
Emails Revamp (#1201)
* refactor: emails (WIP)

* wip

* wip

* refactor: calendarClient

* chore: remove comment

* feat: new templates

* feat: more templates (wip)

* feat: email templates wip

* feat: email templates wip

* feat: prepare for testing

* For testing stripe integration

* Uses imported BASE_URL

* Fixes types

* use BASE_URL

Co-authored-by: Omar López <zomars@me.com>
Co-authored-by: kodiakhq[bot] <49736102+kodiakhq[bot]@users.noreply.github.com>
2021-11-26 11:03:43 +00:00
Alex van Andel 5b3dd02747
Webhook tweaks + Support added for "Custom payload templates" / x-www-form-urlencoded / json (#1193)
* Changed styling of webhook test & updated <Form> component

* Implements custom webhook formats

Co-authored-by: Bailey Pumfleet <pumfleet@hey.com>
2021-11-22 11:37:07 +00:00
Alex van Andel ffdf0b9217
Fixes user availability to be contextual to the user timezone (#1166)
* WIP, WIP, WIP, WIP

* Adds missing types

* Type fixes for useSlots

* Type fixes

* Fixes periodType 500 error when updating

* Adds missing dayjs plugin and type fixes

* An attempt was made to fix tests

* Save work in progress

* Added UTC overflow to days

* Update lib/availability.ts

Co-authored-by: Alex Johansson <alexander@n1s.se>

* No more magic numbers

* Fixed slots.test & added getWorkingHours.test

* Tests pass, simpler logic, profit?

* Timezone shifting!

* Forgot to unskip tests

* Updated the user page

* Added American seed user, some fixes

* tmp fix so to continue testing availability

* Removed timeZone parameter, fix defaultValue auto-scroll

Co-authored-by: Omar López <zomars@me.com>
Co-authored-by: Alex Johansson <alexander@n1s.se>
2021-11-18 01:03:19 +00:00
Alex van Andel bf659c0b16
Fixed #1015 - Teams user registration is broken (#1090)
* Fixed #1015 - Teams user registration is broken

* Type fixes for avilability form in onboarding

* Re adds missing strings

* Updates user availability in one query

Tested and working correctly

* Fixes seeder and tests

Co-authored-by: Omar López <zomars@me.com>
2021-11-11 05:44:53 +00:00
Alex van Andel 8664d217c9
Feature/availability page revamp (#1032)
* Refactored Schedule component

* Merge branch 'main' into feature/availability-page-revamp

* wip

* Turned value into number, many other TS tweaks

* NodeJS 16x works 100% on my local, but out of scope for this already massive PR

* Fixed TS errors in viewer.tsx and schedule/index.ts

* Reverted next.config.js

* Fixed minor remnant from moving types to @lib/types

* schema comment

* some changes to form handling

* add comments

* Turned ConfigType into number; which seems to be the value preferred by tRPC

* Fixed localized time display during onboarding

* Update components/ui/form/Schedule.tsx

Co-authored-by: Alex Johansson <alexander@n1s.se>

* Added showToast to indicate save success

* Converted number to Date, and also always establish time based on current date

* prevent height flickering of availability

by removing mb-2 of input field

* availabilty: re-added mb-2 but added min-height

* Quite a few bugs discovered, but this seems functional

Co-authored-by: KATT <alexander@n1s.se>
Co-authored-by: Bailey Pumfleet <pumfleet@hey.com>
Co-authored-by: kodiakhq[bot] <49736102+kodiakhq[bot]@users.noreply.github.com>
Co-authored-by: Peer Richelsen <peeroke@gmail.com>
2021-11-10 11:16:32 +00:00
Mihai C 559ccb8ca7
hotfix: zoom location on emails (#1153)
* fix: zoom location on emails

* test: fix

Co-authored-by: Peer Richelsen <peeroke@gmail.com>
2021-11-09 16:27:33 +00:00
Syed Ali Shahbaz a404ca847c
updated event title message (#1132)
* updated event title message

* 4 arguments replaced by an object

* translations

* requested changes

* further requested changes

* test fix and other minor changes

* lint fix
2021-11-08 16:34:12 +05:30
Mihai C debef8119e
Rejected bookings should be displayed in cancelled bookings tab (#1100)
* fix: rejected bookings should be displayed in cancelled bookings tab

* fix: add migration to update status of rejected bookings

* unrelated fix

Co-authored-by: Alex van Andel <me@alexvanandel.com>
2021-11-04 22:24:15 +00:00
Alex Johansson a002b194da
Fix onboarding OAuth callback glitch (#1079) 2021-11-03 10:47:52 +00:00
Alex van Andel b7435b5b93
Fixed orphaning team event types (#1086) 2021-10-31 10:41:42 +00:00
Alex van Andel a5eb3fce28
Allow confirming COLLECTIVE types (#1069) 2021-10-29 01:50:52 +01:00
Mihai C 98829d23d3
fix: type errors and translate ee pages (#1050)
* fix: type errors and translate ee pages

* fix: translation key for composed string

* type fixes

Co-authored-by: Omar López <zomars@me.com>
Co-authored-by: kodiakhq[bot] <49736102+kodiakhq[bot]@users.noreply.github.com>
2021-10-28 22:58:26 +00:00
Alex Johansson dddb494071
rewrite webhooks to trpc (#1065) 2021-10-28 22:52:39 +00:00
Omar López 265b76083a
Fixes integrations api endpoint (#1066) 2021-10-28 22:30:42 +01:00
Omar López e38086b8fe
Refactors video integrations (#1037)
* Fixes error types

* Type fixes

* Refactors video meeting handling

* More type fixes

* Type fixes

* More fixes

* Makes language non optional

* Adds missing translations

* Apply suggestions from code review

Co-authored-by: Alex Johansson <alexander@n1s.se>

* Feedback

Co-authored-by: kodiakhq[bot] <49736102+kodiakhq[bot]@users.noreply.github.com>
Co-authored-by: Alex Johansson <alexander@n1s.se>
2021-10-26 10:17:24 -06:00
Bailey Pumfleet eabb096e14
Ensure you can only delete your own credentials 2021-10-26 16:21:08 +01:00
Alex Johansson a9df3b9ad0
Move cron jobs into GitHub actions (#1006) 2021-10-25 18:16:42 +03:00
Mihai C 8d6fec79d3
feat: add translations for emails and type error fixes overall (#994)
* feat: add translations for forgot password email and misc

* fix: type fixes

* feat: translate invitation email

* fix: e2e tests

* fix: lint

* feat: type fixes and i18n for emails

* Merge main

* fix: jest import on server path

* Merge

* fix: playwright tests

* fix: lint

Co-authored-by: Bailey Pumfleet <pumfleet@hey.com>
2021-10-25 14:05:21 +01:00
Mihai C 356d470e16
fix: lowercase email on signup (#1039) 2021-10-25 09:29:54 +00:00
Mihai C 1043b31cc7
fix: lowercase email when loggin in (#1038) 2021-10-25 14:25:28 +05:30
Syed Ali Shahbaz a6eed6ffcc
Enhancement/webhooks redesign (#1005) 2021-10-20 18:23:15 +00:00
Alex Johansson 9e69029943
add e2e testing on webhooks and booking happy-path (#936) 2021-10-18 22:07:06 +01:00
Omar López c2c37b701e
Zomars/fixes trpc typo (#957) 2021-10-14 19:22:01 +00:00
Mihai C a711670a70
fix prisma error on event-type update (#950)
* fix prisma error on event-type update

* fix hidden event-type update
2021-10-14 14:40:24 +01:00
Alex Johansson ec6b897191
integration page follow ups (#912)
### Internals

- Replace `lodash.*` packages with plain `lodash` & replace `lodash.*` imports with `lodash/` - should have no impact on bundle size and opens up for us to use all of lodash
- Update `viewer.me` to cherry-pick what we actually need on that query to avoid leaking extra context info
- Update `getIntegrations` to never include `.key`-property to avoid leaking 

### Visual

- Update calendars so `primary` is displayed last
- Update connected calendars so they are in ascending order in which you connected them
2021-10-13 13:35:25 +02:00
Alex Johansson c3dc18643e
`/integrations` facelift (#858) 2021-10-12 11:35:44 +02:00
Mihai C f27b0b3cad
fix: availability creation and expand/collapse settings (#882)
* fix: availability creation and expand/collapse settings

* additional fixes

* Update pages/api/availability/eventtype.ts

Co-authored-by: Alex Johansson <alexander@n1s.se>

* update branch

* fix: more fixes

Co-authored-by: Alex Johansson <alexander@n1s.se>
Co-authored-by: Bailey Pumfleet <pumfleet@hey.com>
Co-authored-by: Mihai Colceriu <colceriumi@gmail.com>
2021-10-12 08:17:25 +00:00
Alex van Andel 683713e73f
Fixes event type deletion (#906) 2021-10-11 20:56:03 +01:00
Alex van Andel 014b74be8c
Fixes custom-inputs clearing on save (#890) 2021-10-09 15:48:26 +01:00
Lola adee3fd211
Daily video calls (#542)
* ⬆️ Bump tailwindcss from 2.2.14 to 2.2.15

Bumps [tailwindcss](https://github.com/tailwindlabs/tailwindcss) from 2.2.14 to 2.2.15.
- [Release notes](https://github.com/tailwindlabs/tailwindcss/releases)
- [Changelog](https://github.com/tailwindlabs/tailwindcss/blob/master/CHANGELOG.md)
- [Commits](https://github.com/tailwindlabs/tailwindcss/compare/v2.2.14...v2.2.15)

---
updated-dependencies:
- dependency-name: tailwindcss
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>

* updating cal will provide a zoom meeting url

* updating cal will provide a zoom meeting url

* modifying how daily emails send

* modifying how daily emails send

* daily table

* migration updates

* daily table

* rebasing updates

* updating Daily references to a new table

* updating internal notes

* merge updates, adding Daily references to book/events.ts

* updated video email templates to remove Daily specific references

* updating the events.ts and refactoring in the event manager

* removing the package-lock

* changing calendso video powered by Daily.co to cal video powered by Daily.co

* updating some of the internal Daily notes

* added a modal for when the call/ link is invalid

* removing handle errors raw from the Daily video client

* prettier formatting fixes

* Added the Daily location to calendar events and updated Cal video references to Daily.co video

* updating references to create in event manager to check for Daily video

* fixing spacing on the cancel booking modal and adding Daily references in the event manager

* formatting fixes

* updating the readme file

* adding a daily interface in the event manager

* adding daily to the location labels

* added a note to cal event parser

* resolving yarn merge conflicts

* updating dailyReturn to DailyReturnType

* removing prettier auto and refactoring integrations: daily in the event manager

* removing changes to estlintrc.json

* updating read me formatting

* indent space for Daily ReadMe section

* resolving the merge conflicts in the yarn file

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Lola-Ojabowale <lola.ojabowale@gmail.com>
2021-10-07 17:12:39 +01:00
Omar López 58de920951
Refactors custom input form & dialog (#853) 2021-10-07 15:43:20 +00:00
Omar López 30f97117e8
Revert "Revert "Feature/cal 274 add webhooks (#628)" (#854)" (#876)
This reverts commit 6868474c92.

Co-authored-by: Bailey Pumfleet <pumfleet@hey.com>
2021-10-07 15:14:47 +00:00
Anton Podviaznikov c62e1a0eeb
Add more typescript types (#867) 2021-10-07 09:47:33 +01:00
Omar López 95b49a5995
Several type fixes (#855)
* Several type fixes

* Update ee/lib/stripe/client.ts

Co-authored-by: Alex Johansson <alexander@n1s.se>

* Typo

* Refactors createPaymentLink

* Simplify calendarClietn type

Co-authored-by: Alex Johansson <alexander@n1s.se>
Co-authored-by: Peer Richelsen <peeroke@gmail.com>
Co-authored-by: Alex van Andel <me@alexvanandel.com>
2021-10-05 16:46:48 -06:00
Omar López 6868474c92
Revert "Feature/cal 274 add webhooks (#628)" (#854)
This reverts commit 4c07faefe7.
2021-10-05 02:30:00 +01:00
Syed Ali Shahbaz 4c07faefe7
Feature/cal 274 add webhooks (#628)
* added prisma models and migration, minor webhook init --WIP

* --WIP

* --WIP

* added radix-checkbox and other webhook additions --WIP

* added API connections and other modifications --WIP

* --WIP

* replaced checkbox with toggle --WIP

* updated to use Dialog instead of modal --WIP

* fixed API and other small fixes -WIP

* created a dummy hook for test --WIP

* replaced static hook with dynamic hooks

* yarn lock conflict quickfix

* added cancel event hook and other minor additions --WIP

* minor improvements --WIP

* added more add-webhook flow items--WIP

* updated migration to have alter table for eventType

* many ui/ux fixes, logic fixes and action fixes --WIP

* bugfix for incorrect webhook filtering

* some more fixes, edit webhook --WIP

* removed redundant checkbox

* more bugfixes and edit-webhook flow --WIP

* more build and lint fixes

* --WIP

* more fixes and added toast notif --WIP

* --updated iconButton

* clean-up

* fixed enabled check in edit webhook

* another fix

* fixed edit webhook bug

* added await to payload lambda

* wrapped payload call in promise

* fixed cancel/uid CTA alignment

* --requested changes --removed eventType relationship

* Adds missing migration

* Fixes missing daysjs plugin and type fixes

* Adds failsafe for webhooks

* Adds missing dayjs utc plugins

* Fixed schema and migrations

* Updates webhooks query

Co-authored-by: Peer Richelsen <peeroke@gmail.com>
Co-authored-by: kodiakhq[bot] <49736102+kodiakhq[bot]@users.noreply.github.com>
Co-authored-by: Omar López <zomars@me.com>
2021-10-04 17:40:52 -06:00
Alex Johansson 60298f6eeb
resize image before storing (#831)
* resize image fn

* wip

* simplify transform

* comment

* fix

* rm log

* allow pass-through for non-base-64

Co-authored-by: Alex van Andel <me@alexvanandel.com>
2021-09-30 21:37:29 +01:00
Alex Johansson e684824c79
`yarn lint --fix` (#812) 2021-09-28 20:12:48 +01:00
Malte Delfs 3b71c86b1e
prevent cancellation of past events (#568)
Co-authored-by: Alex van Andel <me@alexvanandel.com>
Co-authored-by: Bailey Pumfleet <pumfleet@hey.com>
Co-authored-by: Peer_Rich <peeroke@gmail.com>
2021-09-28 18:23:50 +01:00
Alex Johansson a4fbe7b2b4
downgrade users when trial ends (#767)
* wip

* wip

* wip

* wtf

* should be all the logic

* comment

* fix receiver name

* safeguard a bit more

* downgrade users cron job

Co-authored-by: kodiakhq[bot] <49736102+kodiakhq[bot]@users.noreply.github.com>
2021-09-28 14:00:19 +01:00
Peer Richelsen 58dde562a3
switching to stripes customer portal (#772) 2021-09-27 23:57:23 +01:00
Alex Johansson 34300650e4
add tRPC (#614)
* add trpc

* trpc specific

* fix deps

* lint fix

* upgrade prisma

* nativeTypes

* nope, not needed

* fix app propviders

* Revert "upgrade prisma"

This reverts commit e6f2d2542a.

* rev

* up trpc

* simplify

* wip - bookings page with trpc

* bookings using trpc

* fix `Shell` props

* call it viewerRouter instead

* cleanuop

* ssg helper

* fix lint

* fix types

* skip

* add `useRedirectToLoginIfUnauthenticated`

* exhaustive-deps

* fix callbackUrl

* rewrite `/availability` using trpc

Co-authored-by: kodiakhq[bot] <49736102+kodiakhq[bot]@users.noreply.github.com>
2021-09-27 14:47:55 +00:00
Omar López 7ab49acebe
Fixes eventype form (#777)
* Type fixes

* Uses all integrations and session fixes on getting started page

* eventtype form fixes

* Update pages/event-types/[type].tsx

Co-authored-by: kodiakhq[bot] <49736102+kodiakhq[bot]@users.noreply.github.com>
2021-09-26 21:49:16 +00:00
Omar López 420daec147
CAL-473 Fixes client-side routing for authed pages (#763) 2021-09-24 11:16:46 +01:00