Two Google calendars for appointments? n

Is it possible to add another Google calendar?

I have two photography studios to rent, would be great to use separate calendars for them ...

  • Piotr

    Hi Dalvi ,

    Thnx, all good :slight_smile:

    Actually I don't know how to bite this. Please take a look here. It's a calendar I'm working on. It will be used to book photography studio by my clients.

    http://www.50hzphotography.ie/photostudio/

    This studio is based in location A. Also I have studio in location B (second one) so I wont to make very similar page with second calendar for studio B.

    Both studios I would like to use separate google calendars so I will keep it tidy. At the moment "studio rent duration time" is set as service so client can decide for how long he wont's to rent studio.

    Could you tell me how I should solve this to make it work? At the moment I can imagine that the best option would be to have twoo Google calendars, one for studio A and second fro studio B. I just don't wont events to overlap in one Google calendar.

  • Vaughan

    Hi @Piotr,

    In order to do this, you will need to use 2 seperate providers. Then create a second calendar in google the same way as previously, but each having it's own service account and key by creating a new project in the google developers console.

    Once done, you will need to download the keyfile and upload it to the same place as you did before.

    Make sure you select yes for Allow Service Providers for Google Calendar API Integration in the gcal settings.

    Then you should be able to add the new calendar settings by editing the profile of the second provider.

    Hope this helps.

  • Piotr

    Hi Vaughan,

    I just can't make it work.

    I have done everything like advised. There is second calendar assigned to second user with separate private key. It synchronize well, that's good. Problem is when I wont to display calendar just for one service provider.

    I'm using shortcode:

    [app_monthly_schedule worker="2" title="<h3>Studio availability for START</h3>" logged=""]

    But it shows all two calenders.

    Could you advise on it?

  • Patrick

    Hi there @Piotr

    I hope you don't mind me jumping in here.

    I just visited the page you linked to above, but only see one calendar there:
    http://www.50hzphotography.ie/photostudio/

    If you have one service provider assigned to only service "A'", and a second service provider assigned only to service "B", then either the worker or service parameter in the shortcodes should render only the appropriate calendar.

    If you would like us to log into your site to try to help you figure this out, please enable support access as described here:
    https://premium.wpmudev.org/manuals/wpmu-dev-dashboard-enabling-staff-login/

    Thanks!

  • Tyler Postle

    Hey Piotr,

    Hope you're doing well today!

    The access is expired again, very sorry to ask this, but do you mind re-granting it? I am subscribed to this thread and will jump back on it when I see you reply.

    As for the question, as others mentioned above, it looks like you already have 2 different service provider calendars - they are showing different available hours which leads me to believe there are 2 different service providers.

    Are you seeing that both calendars have both service providers? Sorry, just want to make sure I'm completely clear on the issue here. You have gcal all setup now correct? :slight_smile:

    Look forward to hearing back on this Piotr!

    Cheers,
    Tyler

  • Piotr

    Hi Tyler,

    Today Somebody who's name is Calvin Canas calvinrogercanas@gmail.com just before support access has expired has registered to my website as Admin ... Was is one of your support member?

    I have two photo studios. Every of them needs to have separate page with it's own google calendar connected to appointments. At the moment I have two different service providers, two google calendars and as far as I'm concern everything set as it should be however entry to first calendar can be seen also in second calendar ...

    Please test it to see problem. Calendars cant overlap, they need to show entry only from calendar signed to one studio, not both.

    Ps: I don't know what changes have been made by new user.

  • Tyler Postle

    Hey Piotr,

    Hope you're doing well today!

    Today Somebody who's name is Calvin Canas calvinrogercanas@gmail.com just before support access has expired has registered to my website as Admin ... Was is one of your support member?

    Yes he is support here, he asked me to take a look at this one for you actually :slight_smile: that admin account was only for testing purposes, he forgot to delete it after, I just deleted it now. Sorry about that!

    I have two photo studios. Every of them needs to have separate page with it's own google calendar connected to appointments. At the moment I have two different service providers, two google calendars and as far as I'm concern everything set as it should be however entry to first calendar can be seen also in second calendar ...

    It looks like Calvins account was one of your service providers, can you create a new one with your own credentials there, it doesn't have to be an admin :slight_smile:

    If both places do the same services and at the same times then they will look similar. Are you saying that when an appointment is booked on one calendar it blocked off the time on the other too?

    When you setup the new service provider, apply the same services then try it out again. Make sure that you change the worker ID to that of the new provider you made :slight_smile:

    I'm just catching up on this one, but it looks like you're good to setup the second provider yeah? If you need any help with that just let us know.

    Look forward to hearing back. We'll get this all sorted for you :slight_smile:

    Talk to you soon!

    Cheers,
    Tyler

  • Tyler Postle

    Hey Piotr,

    I only deleted the Calvin Canas user account. Was the account he made one you wanted to keep? Apologies, I was under the impression you didn't want that account :slight_frown:

    If you need a hand setting up another account with google integration I'm more than happy to do that. The credentials will still be in your google console where you setup the app.

    Let me know if you need any help with that.

    Cheers,
    Tyler

  • Tyler Postle

    Hey Piotr,

    I just spoke with Calvin on this and I didn't realize he temporarily replaced your 2nd service provider with the account he created. I've added back your other service provider now "Admin" and just checked, both your service providers have their gcal credentials filled in. Sorry for all the misunderstanding there :slight_smile:

    Can you check the 2 different scheduling pages now? They should be of each service provider. If it's not then can you give me an example of a time on one of them that is or isn't showing up that should be? That will give me something to work with so I know when it is working properly.

    Look forward to hearing back!

    Cheers,
    Tyler

  • Piotr

    Calendar on this page
    http://www.50hzphotography.ie/photostudio/
    is managed by user named "Peter". His id is "4"
    short code on the page
    [app_monthly_schedule worker="4" title="<h3>Studio availability for START</h3>" logged=""]
    This user just for now has administrator role. He has his own calendar, private key etc.

    Calendar on this page
    http://www.50hzphotography.ie/photography-studio-rental-dublin-prussia-st/
    is managed by user named "Lucas". His id is "5"
    short code on the page
    [app_monthly_schedule worker="5" title="<h3>Studio availability for START</h3>" logged=""]
    This user just for now has administrator role. He has his own calendar, private key etc.

    Those "workers" provide the same services which are "studio rent for 1h; studio rent for 1,5h; studio rent for 2.5h etc ... "

    I just have made an entry to calendar assigned to Peter. Studio is booked for 2.25.2015 10am - 11am. I have made this entry using google calendar. From user profile I have synchronized calendars.

    I also have made an entry to calendar assigned to Lucas. Studio is booked for 2.25.2015 4pm - 5pm
    I have made this entry using google calendar. From user profile I have synchronized calendars.

    Calendar managed by Peter is showing entries assigned to Peters and Lucas calendar. It should show entries assigned only to Peters calendar.

    The same is with calendar managed by Lucas which is showing entries assigned to Lucas and Peters calendar. It should show entries assigned only to Lucas calendar.

    I hope that the whole Idea of using calendars for my photography studios is clear to you. Calendars need to work separately but they don't. Entry made to one calendar is visible in on other. Other words appointment booked on one calendar it blocked off the time on the other.

  • Michael Bissett

    Hey @Piotr,

    Please accept my apologies if this wasn't resolved to your satisfaction, I realize that there were some pretty big delays here. :slight_frown:

    Not to worry though, I think I've found the cause of this issue here. I noticed that for the 1 hr & 1.5 hour services, you had a service capacity of "1". This would mean that if a timeslot was booked with one provider, it wouldn't be available to be booked on another provider's calendar (even though he was perfectly available to perform the service).

    I've removed that limit here, and it looks to be working properly on my end when I try booking, could you confirm that it's working as it should on your end please?

    Kind Regards,
    Michael

  • Piotr

    Hi Michael,

    Thnx for trying to help me with this. I'm really hoping we will finally menage it work. Those calendars supposed to help my business, so far, unnecessary, I just have spent weeks on it and money ...

    Please find attached screenshots. They explain everything. If somebody book studio on Gardiner st than those hours are blocked in calendar assigned to studio at prussia st ...

    I have no idea why those calendars overlap but obviously they should not. Those are separate studios and have nothing to do one with other regards to renting time ...

  • Tyler Postle

    Hey Piotr,

    Very sorry for my delay before :slight_frown: the forum subscription works fine, I just missed them. My apologies.

    Thanks for your detailed screenshots here. I see what you mean now and also see the problem, it is assigning Peter's gcal apps as "No service provider" instead of Peter. Also it seems to think you have a service provider named pETER, but I don't see that as a display name for any of the ones you have.

    Could you create a brand new user and assign that one as a service provider then use the gcal credentials from Peter for that one instead :slight_smile:

    Let us know if that does the trick here.

    Talk to you soon!

    Cheers,
    Tyler

  • Piotr

    It seems to work now .... What was the problem, why removing user and adding new one solved it?

    I have some problems with notifications. When somebody use paypal appointment still needs to be confirmed manually ... all my setting are ok however in papal I cant find anything related to IPN, it's not in profile - my settings ...

    Could you look on it pls? I think my settings are ok, probably I need to do something in paypal account.

    Thanks.

  • Ivan

    Hey there Piotr,

    Hope you are having great weekend so far!

    Just checked your settings and they seem fine to me.

    What I noticed is that you have one appointment, and it have zero price, therefore it haven't been processed through paypal.
    Also I can't see any transaction being done.
    And the notifications for paid appointments are send once the payment is processed with paypal.

    Can you run a test with an appointment that is paid through paypal?

    Thanks,
    Ivan

  • Tyler Postle

    Hey Piotr,

    Glad that we got the gcal issue there worked out. I believe the reason that worked was because it was trying to assign the appointment to a service provider that didn't exist, so when you re-set it up it assigned to the correct one :slight_smile:

    As for the PayPal issue, that does sound like an IPN issue. In your PayPal account can you go to:

    My Account > History > IPN History. Then if it's not turned on already, turn it on and paste in the IPN url from your Appointments+ payment settings (screenshot).

    If it already is turned on then check was the error code is for the transactions that have gone through then let us know :slight_smile:

    Look forward to hearing back!

    Cheers,
    Tyler

  • Michelle Shull

    Hi there Piotr! Hope you're well.

    To use IPN (instant payment notifications) in PayPal, you do in fact need a Premium or a Business account, a personal account won't have the correct permissions. To upgrade a personal account is fairly simple, however.

    Log in to PayPal and click the settings gear in the upper right corner. (There's a screenshot below with all this marked, too.) That will bring up your settings page. In the lower left corner, you'll see a link to upgrade to a business account. To use a business account, you'll need a legal business name.

    Hope this helps!

  • Piotr

    I have managed it to work. I had to switch to business paypal account to get an access to IPN.

    I have few more questions.

    1. I'm not getting client mobile number in confirmation email and in google cal entry. All what I get is:

    Dear Baxxter,

    We are pleased to confirm your booking for 50HZ.

    Here are the appointment details:
    Requested service: Studio Rent for 2h
    Date and time: March 5, 2015 3:00 pm

    Peter will assist you for this service.

    Kind regards,
    50HZ

    How to set appointments to give me client mobile number in confirmation email and google calendar entry?

    Please check my settings.

    2. In the google calendar title after making appointment I'm getting for example "Studio Rent for 2h Appointment". Is it possible to have instead of this "Studio Rent [CLIENT NAME] [CLIENT MOB NR]"

    3. In google calendar after making appointment in "Where" field I'm getting "Photography / 360 panoramas / Virtual tours" It's a tagline of my website. Map is showing totally wrong place. How to customize it so map is pointing to right place and "Where" field is showing address of studio (needs to be different for each calendar).

    4. In google calendar in field "created by" I'm getting "...@developer.gserviceaccount.com" How to customize it?

    5. In booking confirmation email I would like to let know client how much is he going to pay for service. How to set it up?

    Thank you.

  • Michelle Shull

    Hi Piotr, thanks for your additional questions.

    1. I'm not getting client mobile number in confirmation email and in google cal entry. All what I get is:

    Here's a tidbit from the Appointments settings page that will come in handy for you - it lists all the placeholder words you can use in the fields to enter the confirmation email text:

    For the above email subject and message contents, you can use the following placeholders which will be replaced by their real values: SITE_NAME, CLIENT, SERVICE, SERVICE_PROVIDER, DATE_TIME, PRICE, DEPOSIT, BALANCE, PHONE, NOTE, ADDRESS, CITY, EMAIL (Client's email), CANCEL (Adds a cancellation link to the email body)

    So, for example, if you want to add the client phone number to the confirmation email, you'd change the text (as in my screenshot below) to this:

    Dear CLIENT,

    We are pleased to confirm your appointment for SITE_NAME.

    Here are the appointment details:
    Requested service: SERVICE
    Date and time: DATE_TIME
    Your phone number: PHONE

    SERVICE_PROVIDER will assist you for this service.

    Kind regards,
    SITE_NAME

    Your next question:

    2. In the google calendar title after making appointment I'm getting for example "Studio Rent for 2h Appointment". Is it possible to have instead of this "Studio Rent [CLIENT NAME]"

    Yes! Check out the second screenshot below. You can use placeholder texts in these fields to alter what you see on the gCal title. :slight_smile:

    3. In google calendar after making appointment in "Where" field I'm getting "Photography / 360 panoramas / Virtual tours" It's a tagline of my website. Map is showing totally wrong place. How to customize it so map is pointing to right place and "Where" field is showing address of studio (needs to be different for each calendar).

    The location can be added on the Google Calendar settings page in Appointments plus, this should replace your site tagline if you add text there. Can you take me a screenshot of your map so I can see that issue more clearly? Thanks!

    4. In google calendar in field "created by" I'm getting "...@developer.gserviceaccount.com" How to customize it?

    Can you grab me a screenshot of this, as well? Thank you!

    5. In booking confirmation email I would like to let know client how much is he going to pay for service. How to set it up?

    This goes back to the first answer, you can add any of the placeholder texts I listed here to your confirmation email, for the cost of the appointment you'll use PRICE or DEPOSIT, if you have the user pay only a percentage upfront.

    Hope this helps!

  • Piotr

    Thnx Michelle,

    I have added details to the Google Calendar settings however it doesn't work ...

    Also I have added address details for service providers however those details doesn't show anywhere.

    what I'm trying to do is to let know clients whats an address of studio they just have booked. I would like to have this info in google calendar and confirmation email. I have two studios at two different addresses. Every studio has it's own calendar and service provider ...

    Please see attached.

  • Michelle Shull

    HI, Piotr!

    I logged into your site, and you don't have any locations listed under the locations tab, and you haven't entered any of the map or other details on the location page yet. You'll need to enter the details for both your locations here.

    Have you seen our tutorial on Appointments + on the blog? http://wpmu.org/build-an-amazing-appointments-website/
    And can I point you to the instructional videos? http://youtu.be/9aYhyBAWN4E?list=PLV1BcivFAIdvk-1xYU5nBHcwrbTY-WgWy

    I think these might actually help out a lot!

    Thanks for your questions!

  • Piotr

    All right, I have almost all I need :slight_smile:

    Looks like last question (hopefully). Is there a way to let know client while he is booking studio that he will be paying by paypal just a deposit instead of full price? At he moment my form doesn't indicate it enough. Clients are thinking that they will pay full price instead of deposit ...

    Probably additional field "deposit" and text "pay deposit" instead of "confirm" on paypal button will do the job. I know how to change text on button but how to add additional field with deposit in info section? Or maybe there is any other user friendly solution?

  • Michelle Shull

    Hey there, piotr!

    You need one more addon here, called Additional Fields. It will let you add an extra text box to get information from the users making appointments. You can customize the text to let users know they'll still need to pony up the rest of the money they owe. :slight_smile:

    You can also customize the text for your confirmation email, just use that deposit placeholder, along the lines of "You paid a deposit in the amount of DEPOSIT, the balance is due at appointment time."

    Would this help?

  • Michelle Shull

    Hi Piotr!

    You could do this with the confirmation email:

    Dear CLIENT,
    We are pleased to confirm your appointment for SITE_NAME.
    Here are the appointment details:
    Requested service: SERVICE
    Date and time: DATE_TIME
    Your phone number: PHONE
    SERVICE_PROVIDER will assist you for this service.
    The price of this service is PRICE.
    You've already paid DEPOSIT.
    This leaves a balance of BALANCE to be be paid at appointment time.

    CANCEL
    Kind regards,
    SITE_NAME

    That includes all the data you want, I believe. As long as you use the placeholder words(the ones in all caps), you can customize the text around them however you like.

    Sorry, I misspoke on the additional fields. You can also use those to show messages to your users without collecting more information from them, if that's what you prefer.

    Does this get it all cleared up for you Piotr?

    Have a great week!

  • Piotr

    I'm using it already in confirmation email. I would like to tell, relay clearly to my clients that they are going to pay some € in advance (not a full price) before they make booking. I would add this information in confirmation form on a website after choosing by client date and time ... Please see attached how I am doing it now. Better probably would be to add one more line below "price" named "deposit". Label "deposit" probably would have to use something like "DEPOSIT" placeholder if you know what I mean ...

    Any way thanks for your help.

  • Piotr

    Hi Michelle,

    Thank you for this.

    I'm having troubles with calendar synchronization. Events added to google calendar doesn't appear in calendar on my website. I have all together three users who manage google calendar. If they ad an event than it is not blocked out in calendar on my website. Please see attached. Why is that?

    Please take a look on 14.03 there is a mess. From 12.30 to 3pm studio was booked using calendar on website. From 3 to 5 studio was booked using google calendar. In google calendar everything looks fine, in calendar on website studio is booked from 12.30 to 3pm so that is ok and than from 4.30 to 5.30 I totally don't understand this. As far as I'm concern everything I have set correctly. In some places it works fine and in others doesn't ...

    On 12.03 studio was booked from 6 to 10pm using google calendar. On google calendar it looks fine, on calendar on website studio is booked from 2.30pm to 3.30pm. What the hell is that? :slight_smile: It doesn't make any sens ...

    On 11.03 studio was booked using google calendar from 7.30 to 9.30 pm. On website calendar shows that studio is booked from 6.30 to 8.30 ...

    Other days are a mess as well.

    I also still have a problem with location. When paypal payment is switched off that it works fine. When payment is switched on and in live mode than location doesn't show up in confirmation email.

  • Michael Bissett

    Hey @Piotr,

    Let's try to make this one the last issue for this particular thread, if there's any other questions, let's take them to a separate thread (to be honest, this one's pretty hard to follow, thanks to the length of it, as well as the various directions the requests have taken). :slight_smile:

    Events added to google calendar doesn't appear in calendar on my website.

    Bit confused about this one, since the latter part of your message seems to indicate otherwise? Could you clarify the situation please? :slight_smile:

    I have all together three users who manage google calendar.

    Three users managing a single calendar inside of Google Calendar, right?

    Oh, and regarding the issues with the different times for the appointments made on the 11, the 12th & the 14th of this month, have you checked to see that the timezone of the calendar in question, the WordPress timezone & the server timezone all match?

    Regarding this:

    I also still have a problem with location. When paypal payment is switched off that it works fine. When payment is switched on and in live mode than location doesn't show up in confirmation email.

    We'll want to take that to a separate thread, so we can tackle this last calendar question here better. :slight_smile:

    https://premium.wpmudev.org/forums/#question

    Please advise,
    Michael

  • Piotr

    Hi Michelle,

    No prob, if there will be any other questions than I will start new topic.

    Events added on google calendar doesn't appear on website calendar. It was ok before as I was synchronizing calendars manually using "Import and Update Events from GCal Now" on users profile page in wp admin panel ... I'm guessing that's a reason. I was doing this as I did not wonted to wait while testing. Now when it's live I have noticed an issue ...

    My hosting provider is located in Ireland. Google calendar is set to Ireland Dublin, wp to UTC. It should work I think.

    There is not only shift in starting time of event but also in duration. Please take a look on attached files and calendar on website - total mess ...

    When event is booked using calendar on website than It works fine. Problems are only when event is booked using google calendar.

    Three users are managing a single calendar inside of Google Calendar.

  • Michelle Shull

    Hey, piotr!

    Okay, let's double/triple check those time settings.
    1. Set Google calendar to UTC, even if Dublin is in that time zone.
    2. Log in to your hosting control panel (it's probably cPanel) and check your server time settings.

    I think the second one will be fine since everything is showing at the right time on your site calendar, and the mismatch is only on gCal, but let's check anyway, and cover our bases.

    Thanks, Piotr!

  • Piotr

    Hi Michelle,

    There is no UTC in google calendar, only GMT

    I'm hosting provider is blacknight. I don't have there any option regards to server time settings or any time settings ...

    I'm testing it and new entries to google calendar doesn't appear on website calendar at all. I'm just guessing, if I would do manual synchronization from wp user profile everything would kick in into place ... We can try it.

  • Piotr

    Yea, I'm naughty boy, I know :slight_smile:

    Heh, I have done manual synchronization for all users. No events form google calendar were sent to website calendar. I have also aided one more test event to google calendar. This one also wasn't sent to website calendar ... Only what have changed is that the some appointments previously made using website calendar (and paypal), which were deleted using Google calendar appeared in google calendar again.

    Always when I click "Export and Update Events to GCal Now " it's telling me "processing three appointments". I'm assuming that's fine, its exporting the same events ... ?

    I have disabled paypal and made two new appointments on 11th using website calendar. It works fine, all good.

    Looks like the only problem is with exporting events made using google calendar to website calendar. what's weird is actually that, that those events appear in wp appointments panel under "
    Reserved by GCal" but all of them are 1h long and don't appear in website calendar. also the service provider for them is pETER which doesn't exist anymore.

    Can it be a problem with "capacity" (please see attached)? However capacity was always the same and it worked before, maybe update has changed something?

  • Michelle Shull

    Piotr!

    Appointments is bound and determined to give you gray hair, isn't it? I think we're getting closer, and once we cross this hurdle, I think we'll be in the home stretch.

    One thing I just thought of I don't think we've taken into account - WordPress Cron. (insert foreboding music here.) WP Cron is not a real cron job, as it doesn't run on an actual schedule, it will only fire when you have traffic on the front end of your site. (You can trick it by visiting your site in a logged out browser, or in an incognito browser tab.) Even if you've got traffic, the most often the cron will fire is every ten minutes. SO, we may actually be on the right track here with our recent tweaks, we might just be waiting for that cron to fire.

    As for the pETER issue, like @Tyler Postle above, I can't find him in your user list. Was he ever a service provider? Maybe when you initially created your Google Calendar?

    Also, I'm not seeing any settings for the calendar on the Google Calendar tab in Appointments+ settings; i.e. the key file name, the service account address, or the calendar ID. These must have been entered at one time, however, if appointments made on the site are exporting to your gCal. Any insight there?

    Thanks, Piotr! We'll get this plugin in line yet. :slight_smile:

  • Piotr

    I don't mind having gray hairs, unless I will have any hairs :wink:

    I was visiting my site today and yesterday from different browsers while testing. Also I have some other traffic to my website and you were looking at it? anyway events added days ago (not 10 minutes) are still not synchronized ...

    pETER is a deleted service provider, I think he was one of first service providers. I have deleted him while solving other issues.

    I have two separate calendars.
    http://www.50hzphotography.ie/services/photography-studio-rental/
    http://www.50hzphotography.ie/services/photography-studio-rental-dublin-prussia-st/

    Every of them has different google calendar assigned and service provider, private key etc. Settings for google calendar are entered in wp user profiles.

  • Michelle Shull

    Hello, Piotr.

    I believe pETER is the issue here. If he was the service provider initially connected to your gCal, then Google is trying to send appointment information to an account that doesn't exist, so it's not showing on your site calendar.

    You're going to need to create a new calendar and attach it to a current service provider, and make sure it's one you won't be deleting. In case you anticipate a high turnover rate with your providers, I would create a user only you control to assign to the gCal, so you don't run into this issue again.

    This should get you squared away. Once Google can find the service provider it's been told to look for, you should see appointments transferring smoothly between gCal and your WordPress calendar.

    Thanks for your question, and have a great day.

Thank NAME, for their help.

Let NAME know exactly why they deserved these points.

Gift a custom amount of points.