Okay
  Public Ticket #2627571
conversion tracking
Closed

Comments

  • Devin started the conversation

    I want to set up google and adroll conversion tracking. So that when the "finish" button is clicked in the Amelia interface its registered as a conversion. I don't know how to attach an event to a button within the plugin code. 

    Is there a better way to achieve this? Can you please tell me how to set this up correctly?

  • [deleted] replied

    Hello,

    Unfortunately we don't have hooks (action and filters) at the moment. What we have is a few JS hooks that is triggered depends on the view:

    window.beforeAddToCalendarLoaded()
    window.beforeBookingLoaded()
    window.beforeSearchLoaded()
    window.beforeSearchFiltered()
    window.afterSearchFiltered()
    window.beforeConfirmedBooking()
    window.beforeCatalogLoaded()
    window.afterSelectCatalogCategory(object_category)
    window.beforeCatalogCategoryLoaded(object_category)
    window.beforeCatalogServiceLoaded(object_category, object_service)
    window.afterSearchActivateService(object_appointment, object_serviceActive)
    window.afterSearchGoToSecondStep(object_appointment, object_serviceActive)
    window.afterBookingSelectDateAndTime(object_appointment, object_serviceId, object_providerId, object_locationId)
    window.afterBookingSelectService(object_appointment, object_serviceId, object_providerId, object_locationId)
    window.beforeConfirmBookingLoaded(object_appointment, object_service, object_provider, object_location)
    window.afterConfirmBooking(object_appointment, object_service, object_provider, object_location)

    JS files are modified (minimized) in public version of plugin (in our development environment is accessible), but unfortunately I can not send you our source code because that is the policy of our company.

    All those files that have extension .vue are compressed and minimized in JS files that is very hard and not recommended modifying. So in order to add some other features you can unminify the js and customize it.

  • Devin replied

    can I access these hooks from a script I run on the page?

  • [deleted] replied

    Hi Devin,

    Yes, that's correct. You can implement hooks on the page your are running.

  •   Devin replied privately
  • [deleted] replied

    Hello Devin,

    I am afraid this is a custom work which is not covered by the support for the plugin. Something like this requires a certain level of coding skills.

    You can take a look at this ticket: https://tmsplugins.ticksy.com/ticket/2278713/ It's related to Google Analytics and Redirections, but it's worthwhile to check.