Skip to content

RHApp Release - Beta Improvements#779

Merged
gunbux merged 5 commits into
develfrom
rhapp-release/beta-improvements
Jan 28, 2023
Merged

RHApp Release - Beta Improvements#779
gunbux merged 5 commits into
develfrom
rhapp-release/beta-improvements

Conversation

@marcus-ong-qy

@marcus-ong-qy marcus-ong-qy commented Jan 28, 2023

Copy link
Copy Markdown
Contributor

Updates to Frontend code based on beta feedbacks

  1. Changed Booking Form Placeholder Text
    image

  2. Fixed Scroll bug
    Time Selectors and Displays will now scroll to the current time, and, if the date selected is not today, scrolls to the default time (currently set at 1800)
    image
    image

  3. Updated Conflict Bookings popup messages
    Clearer messages, and distinct modals for single- and recurring booking conflicts

Single Booking conflict:
image

Recurring Booking conflict:
image

  1. Fixed Recurring Booking exclusive end date
  • I made sure the code compiles on my machine
  • I made sure there are no unnecessary changes in** the code
  • I made sure the title of the PR reflects the core meaning of the issue you are solving
  • I made sure the commit message(s) contain a description and answer the question "Why do those changes fix that particular issue?" or "Why are those changes really necessary as improvements?"

@vercel

vercel Bot commented Jan 28, 2023

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated
rhapp ✅ Ready (Inspect) Visit Preview 💬 Add your feedback Jan 28, 2023 at 3:19AM (UTC)

@gunbux gunbux left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lgtm!

@gunbux gunbux merged commit ba329b9 into devel Jan 28, 2023
@gunbux gunbux deleted the rhapp-release/beta-improvements branch January 28, 2023 13:55
gunbux added a commit that referenced this pull request Jan 30, 2023
* removed conflict headers

* removed unused export replace prop with param in BookingSection

* Fixed code based on comments

* simplified dailyViewatesRow code

* refactored facilities code

* removed hacky use of useParams in selecting weekly recurrence end date; created new SelectRecurringDatePage instead

* clear unused vars

* fixed index html urls

* fixed date row cannot click

* fixed selecting recurring end date affects calender clickedDate value

* Hacky fix to overnight bookings

* changed all string jsx args from ={''} to =""

* capitalised 'Lato'

* converted all jsx elements with no children self closing

* changed profilePictureUrl to profilePicSignedUrl

* changed profilePictureUrl to profilePicSignedUrl

* fixed edit profile page not showing user pic

* Add docs, update gitignore

* fix spread issue on react hook form require

* added sample docs to some pages and components

* updated sample docs

* Added documentations

* Add docs for action file comments

* Update docs for component

* Update doc for page

* add in SelectRecurringDatePage page description

* Update BookingBlock description

* removed some unused store variables

* added docs for hourblocks component

* added docs for checkForDurationError, setViewFacilityMode, fetchAllCCAS, setIsLoading, setBlockOutIsOpen, setIsJCRC

* added docs for viewfacility / viewconflict routes

* remove space...

* removed more unused store variables

* added bug comment

* Update frontend/src/components/FacilityBooking/CurrentTimeLine.tsx

Added Props back

Co-authored-by: Marcus Ong <75428027+marcus-ong-qy@users.noreply.github.com>

* Update frontend/src/store/facilityBooking/action.ts

Corrected documentation for fetchSelectedFacility

Co-authored-by: Marcus Ong <75428027+marcus-ong-qy@users.noreply.github.com>

* added code example for CurrentTimeLine documentation

* fixed eslint error

* specified return variable name for facilityBooking/action.ts

Co-authored-by: Marcus Ong <75428027+marcus-ong-qy@users.noreply.github.com>

* specified return variable name for isJCRC in facilityBooking/action.ts

Co-authored-by: Marcus Ong <75428027+marcus-ong-qy@users.noreply.github.com>

* context for hourblocks

Co-authored-by: Marcus Ong <75428027+marcus-ong-qy@users.noreply.github.com>

* Update frontend/src/store/facilityBooking/action.ts

Co-authored-by: Marcus Ong <75428027+marcus-ong-qy@users.noreply.github.com>

* Update frontend/src/store/facilityBooking/action.ts

Co-authored-by: Marcus Ong <75428027+marcus-ong-qy@users.noreply.github.com>

* Update frontend/src/store/facilityBooking/action.ts

Co-authored-by: Marcus Ong <75428027+marcus-ong-qy@users.noreply.github.com>

* Update frontend/src/store/facilityBooking/action.ts

Co-authored-by: Marcus Ong <75428027+marcus-ong-qy@users.noreply.github.com>

* clarified description

* Update .gitignore

* Updated documentation for gymkeywith

* Updated documentation for GymStatus

* Finished documentation

* Removed empty remarks and launch.json file

* changed profilePictureUrl to profilePicSignedUrl

* fixed edit profile page not showing user pic

* Fixed documentation according to feedback

TODO: Figure out whether avatar is a url or base64 string

* Updated type of url of avatar

* Fixed lint errors

* Updated documentation

* Update frontend/src/components/Gym/GymKeyWith.tsx

Co-authored-by: Marcus Ong <75428027+marcus-ong-qy@users.noreply.github.com>

* Update frontend/src/components/Gym/GymStatus.tsx

Co-authored-by: Marcus Ong <75428027+marcus-ong-qy@users.noreply.github.com>

* Update frontend/src/components/Gym/GymStatusTab.tsx

Co-authored-by: Marcus Ong <75428027+marcus-ong-qy@users.noreply.github.com>

* Update frontend/src/store/facilityBooking/action.ts

Co-authored-by: Marcus Ong <75428027+marcus-ong-qy@users.noreply.github.com>

* Update frontend/src/store/facilityBooking/action.ts

Co-authored-by: Marcus Ong <75428027+marcus-ong-qy@users.noreply.github.com>

* Update frontend/src/components/FacilityBooking/CurrentTimeLine.tsx

Co-authored-by: Marcus Ong <75428027+marcus-ong-qy@users.noreply.github.com>

* Update frontend/src/components/FacilityBooking/CurrentTimeLine.tsx

Co-authored-by: Marcus Ong <75428027+marcus-ong-qy@users.noreply.github.com>

* Update frontend/src/store/facilityBooking/action.ts

Co-authored-by: Marcus Ong <75428027+marcus-ong-qy@users.noreply.github.com>

* Update frontend/src/store/facilityBooking/action.ts

Co-authored-by: Marcus Ong <75428027+marcus-ong-qy@users.noreply.github.com>

* Update frontend/src/store/facilityBooking/action.ts

Co-authored-by: Marcus Ong <75428027+marcus-ong-qy@users.noreply.github.com>

* Update frontend/src/store/facilityBooking/action.ts

Co-authored-by: Marcus Ong <75428027+marcus-ong-qy@users.noreply.github.com>

* Update frontend/src/store/facilityBooking/action.ts

Co-authored-by: Marcus Ong <75428027+marcus-ong-qy@users.noreply.github.com>

* Update frontend/src/components/Gym/GymConfirmationModal.tsx

Co-authored-by: Marcus Ong <75428027+marcus-ong-qy@users.noreply.github.com>

* Update frontend/src/store/gym/action.ts

Co-authored-by: Marcus Ong <75428027+marcus-ong-qy@users.noreply.github.com>

* Update frontend/src/store/gym/action.ts

Co-authored-by: Marcus Ong <75428027+marcus-ong-qy@users.noreply.github.com>

* Update frontend/src/components/Gym/GymConfirmationModal.tsx

Co-authored-by: Marcus Ong <75428027+marcus-ong-qy@users.noreply.github.com>

* Update frontend/src/components/Gym/GymConfirmationModal.tsx

Co-authored-by: Marcus Ong <75428027+marcus-ong-qy@users.noreply.github.com>

* Update frontend/src/components/Gym/GymHistory.tsx

Co-authored-by: Marcus Ong <75428027+marcus-ong-qy@users.noreply.github.com>

* Updated gym comments

* changed profilePictureUrl to profilePicSignedUrl

* fixed edit profile page not showing user pic

* Updated gym comments

* Removed extra line in GymHistory

* Facilities revamp documentation (tim's part)

* added docs for more action.ts functions

* completed documentation for some components and routes

* Update frontend/src/components/FacilityBooking/CurrentTimeLine.tsx

* Update frontend/src/components/Gym/GymKeyWith.tsx

Co-authored-by: Marcus Ong <75428027+marcus-ong-qy@users.noreply.github.com>

* Update frontend/src/components/Gym/GymStatusTab.tsx

Co-authored-by: Marcus Ong <75428027+marcus-ong-qy@users.noreply.github.com>

* Update frontend/src/components/Gym/GymStatusTab.tsx

Co-authored-by: Marcus Ong <75428027+marcus-ong-qy@users.noreply.github.com>

* Update frontend/src/store/gym/action.ts

Co-authored-by: Marcus Ong <75428027+marcus-ong-qy@users.noreply.github.com>

* Update frontend/src/components/Gym/GymStatus.tsx

Co-authored-by: Marcus Ong <75428027+marcus-ong-qy@users.noreply.github.com>

* fixed eslint errors

* Update frontend/src/store/facilityBooking/action.ts

Co-authored-by: Marcus Ong <75428027+marcus-ong-qy@users.noreply.github.com>

* Update frontend/src/components/FacilityBooking/ViewBlock.tsx

Co-authored-by: Marcus Ong <75428027+marcus-ong-qy@users.noreply.github.com>

* Update frontend/src/store/facilityBooking/action.ts

Co-authored-by: Marcus Ong <75428027+marcus-ong-qy@users.noreply.github.com>

* Update frontend/src/routes/FacilityBooking/EditBooking/index.tsx

Co-authored-by: Marcus Ong <75428027+marcus-ong-qy@users.noreply.github.com>

* Update frontend/src/routes/FacilityBooking/EditBooking/index.tsx

Co-authored-by: Marcus Ong <75428027+marcus-ong-qy@users.noreply.github.com>

* Update frontend/src/store/facilityBooking/action.ts

Co-authored-by: Marcus Ong <75428027+marcus-ong-qy@users.noreply.github.com>

* Update frontend/src/store/facilityBooking/action.ts

Co-authored-by: Marcus Ong <75428027+marcus-ong-qy@users.noreply.github.com>

* Update frontend/src/store/facilityBooking/action.ts

Co-authored-by: Marcus Ong <75428027+marcus-ong-qy@users.noreply.github.com>

* Update frontend/src/routes/FacilityBooking/ViewFacility/index.tsx

* Update frontend/src/store/facilityBooking/action.ts

* Update frontend/src/store/facilityBooking/action.ts

* Update frontend/src/components/Gym/GymHistory.tsx

* Code cleanup (#677)

* converted == to ===

* converted ={' '} to =" "

* removed ={true} redundancy

* made all empty tags self closing

* remove ===true ===false redundancy

* Gym Documentation (#710)

* Update Gym Docs

* Update frontend/src/store/gym/action.ts

* Update Gym Docs

Co-authored-by: Marcus Ong <75428027+marcus-ong-qy@users.noreply.github.com>

* resolved

* Update frontend/src/store/facilityBooking/action.ts

* Update frontend/src/store/facilityBooking/action.ts

* Update frontend/src/store/facilityBooking/action.ts

* fixed prettier error

* fix: user_CCA endpoint

* added docs to button

* renamed routes and fixed conflict modal view conflict redirect error

* updated docs to reflect url path changes of last commit

* redirects user immediately after creating a booking, and shows conflict modal if conflict

* fixed bug where timing before current time can be selected for booking

* fixed weekly recurring booking

* Added customizable elements to the height and font size of the button

* fixed weekly recurring booking

* Added react-toastify notification

* [WIP] Added new home page

* deleted yarn.lock

* Update frontend/src/components/Button.tsx

* Update frontend/src/components/Button.tsx

* added booking successful popup after users made a booking, added delay before booking status changes back to initial

* changed the package json back to original

* [WIP] Created new front page

* Created New Front Page

* Reordered imports

* removed comment

* added line-height as prop

* centered on desktop and removed unused code

* edited according to comments

* remove ridiculous trailing spaces in button text argument

* minor code cleanup

* undo change to endpoint.ts

* undo change to endpoint.ts

* minor cleanups

* changed facils booking landing page, reordered directories

* update docs

* removed redundant facilityId param in ClickableDateContainer and other parent components

* cleaned up Calendar redux store, to be removed completely

* removed Calendar redux store

* abstracted and restructured Calendar component to be more modular

* removed redundant selectedFacilityId param

* abstracted clickedDate from clickableDateContainer; Calender is now truly stateless

* created aux function isSameDate

* docs and cleanup of calendar code

* abstraction and improvement of my bookings and calendar container css

* edit page titles

* modularised BookingTimeSelector

* modularised BookingTimeSelector

* implemented SearchBookingTime page

* abstracted FacilitiesList

* removed unused common functions

* fix back navigation issues from booking page

* implemented get available facilities within requested timeframe (not yet tested)

* updated search results page and api call to handle no facilities available during given time

* created enum for SearchMode

* forgot to dispatch resetTimeSelectorSelection

* allow backnavigation from reselecting booking time back to create booking page by using optional url param

* renamed a few folders and paths

* [BE] Facilities booking revamp (#737)

* Implement /available endpoint

* Implement check_bookings_within_time()

* Refine /available endpoint

Co-authored-by: theng <theng@pop-os.localdomain>

* implemented unsuccessful booking popup

* changed based on comments

* tested getFacilityListWithinTime with backend updated api function

* updated unixToFullDateTime function

* sort facilities alphabetically

* fixed ui of facilities list

* abstracted REVAMP_GREEN

* fixed timeline not refreshed when selecting search time

* implemented login auth for private routes (#756)

* implemented login auth for private routes

* added doc for PublicRoute as well

* renamed routes

* final code cleanup

* final cleanup

* Dockerize backend (#741)

* Added dockerignore files

* Add initial docker deployments

* Updated docker compose

* Update docker configs

* Update docker files

* Update docker configs

* Added deploy scripts

* Minor fixes

* Added CORS middleware

* Add supporting infra

* Update infra

* Update infra and add announcer bot

Co-authored-by: RHDevs <raffleshalldevs@gmail.com>

* Cleanup files

* removed unused codes

* renamed REVAMP_GREEN to PRIMARY_GREEN

* - Cleaned up error messages (#767)

- Removed warnings
- Improved tree shaking

* Update endpoints (#768)

* Revamp facilities/final debugs (#774)

* prevent overflow of facility day view title

* used useEffect to check if facility name string is 0, and get facility name if necessary

* abolished react-hook-form and use redux to hold all form values instead

* changed redirect from select time

* abstracted bookingCard and refactored time string

* abstracted booking form, fixed edit booking form default values and redirect

* fixed edit booking time reselection

* fixed edit booking api

* fixed reselect edit booking current time blocked off for reselection

* convert to URLSearchParams for api url parsing

* fixed booking form no reset

* added docs, minor code changes

* fixed prettier issue

* add docs, fixed clickedDate not set

* fixed TODOs in action.ts, and mobile responsiveness for view bookings

* fixed top nav bar overflow

* set default date on calendar pages to today

* deleted unused calendar css file

* fix case when user cancels reselection of time

* removed facility day view unnecessary padding

* fix booking alert code merge error

* code cleanup and route var names renaming

* fixed some TODOs

* removed unnecessary console log

* [WIP] Revamp facilities final redisign (sic) (#777)

* added new svg assets

* created round icon button

* implemented new design on facility booking landing page

* implemented new design on search by time booking results page

* final cleanups

* changed booking formcca placeholder text

* fixed scroll bug

* enable disable default autoscroll when selecting time

* improved conflict popup messages, different popup types for single- and recurring booking conflicts

* RHApp Release - Beta Improvements (#779)

* changed booking formcca placeholder text

* fixed scroll bug

* enable disable default autoscroll when selecting time

* improved conflict popup messages, different popup types for single- and recurring booking conflicts

* fixed recurring booking exclusive end date

* fixed view conflict page keeps loading

* Bump version number

* Changed version number

---------

Co-authored-by: Marcus Ong <75428027+marcus-ong-qy@users.noreply.github.com>
Co-authored-by: Magmanat <princemjp@gmail.com>
Co-authored-by: Marcus Ong <marcus.ong.qy@gmail.com>
Co-authored-by: joeng03 <yinjoeng2003@gmail.com>
Co-authored-by: Xin Yee <63994179+xinyee20@users.noreply.github.com>
Co-authored-by: joshualeejunyi <joshua.lee.99@hotmail.com>
Co-authored-by: joeng03 <51855281+joeng03@users.noreply.github.com>
Co-authored-by: Joshua Lee <33726740+joshualeejunyi@users.noreply.github.com>
Co-authored-by: Zhu Yuechen <zhuyuechen@gmail.com>
Co-authored-by: Kieron Seven Lee <40373653+Cikguseven@users.noreply.github.com>
Co-authored-by: Zhu Yuechen <64315146+yuechen2001@users.noreply.github.com>
Co-authored-by: Timothy Leow <you@example.com>
Co-authored-by: Timothy Leow <64006665+swoglord@users.noreply.github.com>
Co-authored-by: gabyang <gabrielyang@berkeley.edu>
Co-authored-by: Vina Tan <88601826+vinatsx@users.noreply.github.com>
Co-authored-by: LWS49 <e0970244@u.nus.edu>
Co-authored-by: Li Yuan <e0985877@u.nus.edu>
Co-authored-by: antonTan96 <e0960491@u.nus.edu>
Co-authored-by: JCSnap <e0970167@u.nus.edu>
Co-authored-by: Anton <111056306+antonTan96@users.noreply.github.com>
Co-authored-by: ttheng3810 <81245678+ttheng3810@users.noreply.github.com>
Co-authored-by: theng <theng@pop-os.localdomain>
Co-authored-by: RHDevs <raffleshalldevs@gmail.com>
@cjunxiang

Copy link
Copy Markdown
Contributor

good to split PRs more, into indiv fixes.

rationale: if one thing spoils the whole app, can just roll back one indiv PR.

Comment on lines 30 to 38
handleCreateNewBooking(
booking?.facilityID,
booking?.eventName,
booking?.startTime ?? null,
booking?.endTime ?? null,
booking?.endDate !== 0,
booking?.endDate,
booking?.ccaID,
booking?.description,

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

no context comment:
isit easier to pass the whole booking object and do the truefalse checks in the action?

@gunbux gunbux Jan 30, 2023

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

good to split PRs more, into indiv fixes.

rationale: if one thing spoils the whole app, can just roll back one indiv PR.

re to this: yes, from the earlier releases, resolving merge conflicts from a chain of 200 commits is not very fun and has a lot of errors as well

no context comment: isit easier to pass the whole booking object and do the truefalse checks in the action?

it probably is @marcus-ong-qy

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants