Block week day in calender(urgent)

hello, i want to implement a calender where i want to block certain days.

the user 1 selects days on which the shop is opened in the week(monday, tuesday, wednesday ) . (already implemented using option set) and multiple dropdown

now i want to make those day selectable (like all dates on Monday ( if user1 selects monday ) ,and other unselectable.
i looked up various sources didnt find any clue. any tips ?
calender
something like this

on the calendar element there are options for setting days of the week to block…which calendar element are you using?

1 Like

currently im using air Date/Time Picker but im free to choose if any other plugin provide this functionality to make the week unselectable which is not in the database.




this is futher details. im trying to use this disable monday option. for disabling the week days when it is not in available days.

i tried creating custom calender(which is shown in the image) it is also working well . it is made using repeating group. if this feature is not implementable in plugin and can be implemented in cutom calender . any guidance into that would be appreciable.

The field values needed to disable are yes/no values. In Bubble we can create dynamic expressions which evaluate to a yes or no and these can populate fields that require yes/no values.

If you put into a data field for a data type that is connected to something the calendar is for (so a shop or sports activity…whatever it is that has days available) the list of unavailable days, which will be a list of the option set you created, you can craft a dynamic expression for each day of the week to be something like ‘days unavailable list contains Monday’ and if the list contains Monday (again, the value from your option set) then the expression will evaluate to Yes and the Monday will be disabled in the date picker

1 Like

I think this solution worked before. Maybe check it out. You can choose the day block with respect to the user’s preferences if you want.

Yes im trying this Approach, the thing is , available days is stored as List of text in option set. now im using this operation in my airtime date picker disable monday field.

Parent group thing->available_days->doesn’t contain-> Arbitary Text → Monday

ik im doing it wrong, can you tell me how can i fix

i want to check if Monday is present in that List of Text ( available days ).

so if returned value is yes, then it enable monday
and if returned value is no, then it disable monday

i tried but didnt work , i know maybe i messed up implementing cause its little complex. a step by step article would be nice. i used html element and placed the text then how should i proceed.

Check the editor. It has example:

hey, thanks for the response! my functionality is working as expected. i used Air date/time picker plugin.

the only flaw right now im facing is when user clicks on book now ( the details are listed in pop up where i showed available days ) it works fine but when i close the pop up and click another cell book now button ( the pop up shows details of new list but calender is still showing previous one) .

i think this is problem of state ig cause when i refresh the page ( whichever cell i click first calender displays only that value for every list)

This topic was automatically closed after 70 days. New replies are no longer allowed.