File tree Expand file tree Collapse file tree
lib/components/event-schedule-new Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -71,6 +71,7 @@ export const atprotoToCalendarFormat = (event: any) => {
7171
7272 return {
7373 id : event . id ,
74+ rkey : event . rkey ,
7475 name : event . title ,
7576 description : event . description ,
7677 location : event . location . name ,
@@ -104,6 +105,7 @@ export const apiResultToCalendarFormat = (atprotoEventsData: any) => {
104105 return atprotoToCalendarFormat ( {
105106 ...record ,
106107 id : event . id ,
108+ rkey : event . rkey ,
107109 isCoreEvent : event . is_core_event ,
108110 // showTimeOfDay: updatedAfterSep3,
109111 } ) ;
Original file line number Diff line number Diff line change @@ -199,7 +199,9 @@ const NewScheduleIndex = ({
199199 if ( eventParam && events . length > 0 ) {
200200 // Try to find event by id or name (converted to slug format)
201201 const targetEvent = events . find (
202- ( event ) => event . id . toString ( ) === eventParam . toString ( )
202+ ( event ) =>
203+ event . id . toString ( ) === eventParam . toString ( ) ||
204+ event . rkey . toString ( ) === eventParam . toLowerCase ( )
203205 ) ;
204206
205207 if ( targetEvent ) {
Original file line number Diff line number Diff line change 11export interface Event {
22 id : string ;
3+ rkey : string ;
34 name : string ;
45 isFairEvent ?: boolean ;
56 isCoreEvent ?: boolean ;
Original file line number Diff line number Diff line change @@ -248,10 +248,6 @@ const EventVoucher = ({
248248 const couponFetchedButNoCoupon =
249249 connected && couponFetchingComplete && ! coupon ;
250250
251- console . log ( coupon , "coupon" ) ;
252-
253- console . log ( connectionState , "connectionState" ) ;
254-
255251 const requestCoupon = useCallback ( async ( ) => {
256252 if ( connectionState !== ClientConnectionState . CONNECTED ) return ;
257253 if ( fetchingCoupon ) return ;
@@ -352,7 +348,7 @@ const EventVoucher = ({
352348 color = {
353349 connectionState === ClientConnectionState . CONNECTED
354350 ? "green-1"
355- : "blue -1"
351+ : "green -1"
356352 }
357353 onClick = { ( ) => {
358354 if ( connectionState === ClientConnectionState . DISCONNECTED ) {
@@ -430,7 +426,7 @@ const EventVoucher = ({
430426 </ div >
431427 ) }
432428
433- { connectedWithNoTicket && (
429+ { ! connectedWithTicket && ! couponFetchedButNoCoupon && (
434430 < >
435431 < div className = "text-sm font-semibold text-gray-600 mt-1" >
436432 You need a Devconnect ticket to attend this event.
You can’t perform that action at this time.
0 commit comments