Added index.php in js ajax urls (without mod rewrite)

This commit is contained in:
alextselegidis 2015-05-20 22:26:11 +02:00
parent 554e2b38e6
commit fd0a9177cd
10 changed files with 42 additions and 42 deletions

View file

@ -275,7 +275,7 @@ var BackendCalendar = {
* Trigger the synchronization algorithm. * Trigger the synchronization algorithm.
*/ */
$('#google-sync').click(function() { $('#google-sync').click(function() {
var getUrl = GlobalVariables.baseUrl + '/google/sync/' + $('#select-filter-item').val(); var getUrl = GlobalVariables.baseUrl + '/index.php/google/sync/' + $('#select-filter-item').val();
$.ajax({ $.ajax({
'type': 'GET', 'type': 'GET',
'url': getUrl, 'url': getUrl,
@ -405,7 +405,7 @@ var BackendCalendar = {
if (BackendCalendar.lastFocusedEventData.data.is_unavailable == false) { if (BackendCalendar.lastFocusedEventData.data.is_unavailable == false) {
var messageButtons = {}; var messageButtons = {};
messageButtons['OK'] = function() { messageButtons['OK'] = function() {
var postUrl = GlobalVariables.baseUrl + '/backend_api/ajax_delete_appointment'; var postUrl = GlobalVariables.baseUrl + '/index.php/backend_api/ajax_delete_appointment';
var postData = { var postData = {
'appointment_id' : BackendCalendar.lastFocusedEventData.data['id'], 'appointment_id' : BackendCalendar.lastFocusedEventData.data['id'],
@ -447,7 +447,7 @@ var BackendCalendar = {
$('#delete-reason').css('width', '353px'); $('#delete-reason').css('width', '353px');
} else { } else {
// Do not display confirmation promt. // Do not display confirmation promt.
var postUrl = GlobalVariables.baseUrl + '/backend_api/ajax_delete_unavailable'; var postUrl = GlobalVariables.baseUrl + '/index.php/backend_api/ajax_delete_unavailable';
var postData = { var postData = {
'unavailable_id' : BackendCalendar.lastFocusedEventData.data.id 'unavailable_id' : BackendCalendar.lastFocusedEventData.data.id
@ -683,10 +683,10 @@ var BackendCalendar = {
$('#enable-sync').click(function() { $('#enable-sync').click(function() {
if ($('#enable-sync').hasClass('enabled') === false) { if ($('#enable-sync').hasClass('enabled') === false) {
// :: ENABLE SYNCHRONIZATION FOR SELECTED PROVIDER // :: ENABLE SYNCHRONIZATION FOR SELECTED PROVIDER
var authUrl = GlobalVariables.baseUrl + '/google/oauth/' var authUrl = GlobalVariables.baseUrl + '/index.php/google/oauth/'
+ $('#select-filter-item').val(); + $('#select-filter-item').val();
var redirectUrl = GlobalVariables.baseUrl + '/google/oauth_callback'; var redirectUrl = GlobalVariables.baseUrl + '/index.php/google/oauth_callback';
var windowHandle = window.open(authUrl, 'Authorize Easy!Appointments', var windowHandle = window.open(authUrl, 'Authorize Easy!Appointments',
'width=800, height=600'); 'width=800, height=600');
@ -710,7 +710,7 @@ var BackendCalendar = {
// Display the calendar selection dialog. First we will get a list // Display the calendar selection dialog. First we will get a list
// of the available user's calendars and then we will display a selection // of the available user's calendars and then we will display a selection
// modal so the user can select the sync calendar. // modal so the user can select the sync calendar.
var postUrl = GlobalVariables.baseUrl + '/backend_api/ajax_get_google_calendars'; var postUrl = GlobalVariables.baseUrl + '/index.php/backend_api/ajax_get_google_calendars';
var postData = { var postData = {
'provider_id': $('#select-filter-item').val() 'provider_id': $('#select-filter-item').val()
}; };
@ -947,7 +947,7 @@ var BackendCalendar = {
* Event: Select Google Calendar "Click" * Event: Select Google Calendar "Click"
*/ */
$('#select-calendar').click(function() { $('#select-calendar').click(function() {
var postUrl = GlobalVariables.baseUrl + '/backend_api/ajax_select_google_calendar'; var postUrl = GlobalVariables.baseUrl + '/index.php/backend_api/ajax_select_google_calendar';
var postData = { var postData = {
'provider_id': $('#select-filter-item').val(), 'provider_id': $('#select-filter-item').val(),
'calendar_id': $('#google-calendar').val() 'calendar_id': $('#google-calendar').val()
@ -994,7 +994,7 @@ var BackendCalendar = {
* @param {type} endDate Visible end date of the calendar. * @param {type} endDate Visible end date of the calendar.
*/ */
refreshCalendarAppointments: function($calendar, recordId, filterType, startDate, endDate) { refreshCalendarAppointments: function($calendar, recordId, filterType, startDate, endDate) {
var postUrl = GlobalVariables.baseUrl + '/backend_api/ajax_get_calendar_appointments'; var postUrl = GlobalVariables.baseUrl + '/index.php/backend_api/ajax_get_calendar_appointments';
var postData = { var postData = {
'record_id': recordId, 'record_id': recordId,
'start_date': startDate.toString('yyyy-MM-dd'), 'start_date': startDate.toString('yyyy-MM-dd'),
@ -1261,7 +1261,7 @@ var BackendCalendar = {
* going to be executed on post failure. * going to be executed on post failure.
*/ */
saveAppointment: function(appointment, customer, successCallback, errorCallback) { saveAppointment: function(appointment, customer, successCallback, errorCallback) {
var postUrl = GlobalVariables.baseUrl + '/backend_api/ajax_save_appointment'; var postUrl = GlobalVariables.baseUrl + '/index.php/backend_api/ajax_save_appointment';
var postData = {}; var postData = {};
@ -1306,7 +1306,7 @@ var BackendCalendar = {
* @param {function} errorCallback The ajax failure callback function. * @param {function} errorCallback The ajax failure callback function.
*/ */
saveUnavailable: function(unavailable, successCallback, errorCallback) { saveUnavailable: function(unavailable, successCallback, errorCallback) {
var postUrl = GlobalVariables.baseUrl + '/backend_api/ajax_save_unavailable'; var postUrl = GlobalVariables.baseUrl + '/index.php/backend_api/ajax_save_unavailable';
var postData = { var postData = {
'unavailable': JSON.stringify(unavailable) 'unavailable': JSON.stringify(unavailable)
@ -1380,7 +1380,7 @@ var BackendCalendar = {
.add({ minutes: -minuteDelta }) .add({ minutes: -minuteDelta })
.toString('yyyy-MM-dd HH:mm:ss'); .toString('yyyy-MM-dd HH:mm:ss');
var postUrl = GlobalVariables.baseUrl + '/backend_api/ajax_save_appointment'; var postUrl = GlobalVariables.baseUrl + '/index.php/backend_api/ajax_save_appointment';
var postData = { 'appointment_data': JSON.stringify(appointment) }; var postData = { 'appointment_data': JSON.stringify(appointment) };
$.post(postUrl, postData, function(response) { $.post(postUrl, postData, function(response) {
@ -1433,7 +1433,7 @@ var BackendCalendar = {
.add({ minutes: -minuteDelta }) .add({ minutes: -minuteDelta })
.toString('yyyy-MM-dd HH:mm:ss'); .toString('yyyy-MM-dd HH:mm:ss');
var postUrl = GlobalVariables.baseUrl + '/backend_api/ajax_save_unavailable'; var postUrl = GlobalVariables.baseUrl + '/index.php/backend_api/ajax_save_unavailable';
var postData = { 'unavailable': JSON.stringify(unavailable) }; var postData = { 'unavailable': JSON.stringify(unavailable) };
$.post(postUrl, postData, function(response) { $.post(postUrl, postData, function(response) {
@ -1656,7 +1656,7 @@ var BackendCalendar = {
event.data['start_datetime'] = appointment['start_datetime']; event.data['start_datetime'] = appointment['start_datetime'];
event.data['end_datetime'] = appointment['end_datetime']; event.data['end_datetime'] = appointment['end_datetime'];
var postUrl = GlobalVariables.baseUrl + '/backend_api/ajax_save_appointment'; var postUrl = GlobalVariables.baseUrl + '/index.php/backend_api/ajax_save_appointment';
var postData = { 'appointment_data': JSON.stringify(appointment) }; var postData = { 'appointment_data': JSON.stringify(appointment) };
@ -1718,7 +1718,7 @@ var BackendCalendar = {
event.data['start_datetime'] = unavailable['start_datetime']; event.data['start_datetime'] = unavailable['start_datetime'];
event.data['end_datetime'] = unavailable['end_datetime']; event.data['end_datetime'] = unavailable['end_datetime'];
var postUrl = GlobalVariables.baseUrl + '/backend_api/ajax_save_unavailable'; var postUrl = GlobalVariables.baseUrl + '/index.php/backend_api/ajax_save_unavailable';
var postData = { 'unavailable': JSON.stringify(unavailable) }; var postData = { 'unavailable': JSON.stringify(unavailable) };
@ -1780,7 +1780,7 @@ var BackendCalendar = {
disableProviderSync: function(providerId) { disableProviderSync: function(providerId) {
// Make an ajax call to the server in order to disable the setting // Make an ajax call to the server in order to disable the setting
// from the database. // from the database.
var postUrl = GlobalVariables.baseUrl + 'backend_api/ajax_disable_provider_sync'; var postUrl = GlobalVariables.baseUrl + '/index.php/backend_api/ajax_disable_provider_sync';
var postData = { 'provider_id': providerId }; var postData = { 'provider_id': providerId };
$.post(postUrl, postData, function(response) { $.post(postUrl, postData, function(response) {

View file

@ -215,7 +215,7 @@ CustomersHelper.prototype.bindEventHandlers = function() {
* @param {object} customer Contains the customer data. * @param {object} customer Contains the customer data.
*/ */
CustomersHelper.prototype.save = function(customer) { CustomersHelper.prototype.save = function(customer) {
var postUrl = GlobalVariables.baseUrl + '/backend_api/ajax_save_customer'; var postUrl = GlobalVariables.baseUrl + '/index.php/index.php/backend_api/ajax_save_customer';
var postData = { 'customer': JSON.stringify(customer) }; var postData = { 'customer': JSON.stringify(customer) };
$.post(postUrl, postData, function(response) { $.post(postUrl, postData, function(response) {
@ -238,7 +238,7 @@ CustomersHelper.prototype.save = function(customer) {
* @param {numeric} id Record id to be deleted. * @param {numeric} id Record id to be deleted.
*/ */
CustomersHelper.prototype.delete = function(id) { CustomersHelper.prototype.delete = function(id) {
var postUrl = GlobalVariables.baseUrl + '/backend_api/ajax_delete_customer'; var postUrl = GlobalVariables.baseUrl + '/index.php/backend_api/ajax_delete_customer';
var postData = { 'customer_id': id }; var postData = { 'customer_id': id };
$.post(postUrl, postData, function(response) { $.post(postUrl, postData, function(response) {
@ -357,7 +357,7 @@ CustomersHelper.prototype.display = function(customer) {
CustomersHelper.prototype.filter = function(key, selectId, display) { CustomersHelper.prototype.filter = function(key, selectId, display) {
if (display == undefined) display = false; if (display == undefined) display = false;
var postUrl = GlobalVariables.baseUrl + '/backend_api/ajax_filter_customers'; var postUrl = GlobalVariables.baseUrl + '/index.php/backend_api/ajax_filter_customers';
var postData = { 'key': key }; var postData = { 'key': key };
$.post(postUrl, postData, function(response) { $.post(postUrl, postData, function(response) {

View file

@ -82,7 +82,7 @@ var BackendServices = {
* to the service categories db table. * to the service categories db table.
*/ */
updateAvailableCategories: function() { updateAvailableCategories: function() {
var postUrl = GlobalVariables.baseUrl + '/backend_api/ajax_filter_service_categories'; var postUrl = GlobalVariables.baseUrl + '/index.php/backend_api/ajax_filter_service_categories';
var postData = { 'key': '' }; var postData = { 'key': '' };
$.post(postUrl, postData, function(response) { $.post(postUrl, postData, function(response) {
@ -259,7 +259,7 @@ ServicesHelper.prototype.save = function(service) {
//console.log('Service data to save:', service); //console.log('Service data to save:', service);
//////////////////////////////////////////////// ////////////////////////////////////////////////
var postUrl = GlobalVariables.baseUrl + '/backend_api/ajax_save_service'; var postUrl = GlobalVariables.baseUrl + '/index.php/backend_api/ajax_save_service';
var postData = { 'service': JSON.stringify(service) }; var postData = { 'service': JSON.stringify(service) };
$.post(postUrl, postData, function(response) { $.post(postUrl, postData, function(response) {
@ -281,7 +281,7 @@ ServicesHelper.prototype.save = function(service) {
* @param {numeric} id Record id to be deleted. * @param {numeric} id Record id to be deleted.
*/ */
ServicesHelper.prototype.delete = function(id) { ServicesHelper.prototype.delete = function(id) {
var postUrl = GlobalVariables.baseUrl + '/backend_api/ajax_delete_service'; var postUrl = GlobalVariables.baseUrl + '/index.php/backend_api/ajax_delete_service';
var postData = { 'service_id': id }; var postData = { 'service_id': id };
$.post(postUrl, postData, function(response) { $.post(postUrl, postData, function(response) {
@ -374,7 +374,7 @@ ServicesHelper.prototype.display = function(service) {
ServicesHelper.prototype.filter = function(key, selectId, display) { ServicesHelper.prototype.filter = function(key, selectId, display) {
if (display == undefined) display = false; if (display == undefined) display = false;
var postUrl = GlobalVariables.baseUrl + '/backend_api/ajax_filter_services'; var postUrl = GlobalVariables.baseUrl + '/index.php/backend_api/ajax_filter_services';
var postData = { 'key': key }; var postData = { 'key': key };
$.post(postUrl, postData, function(response) { $.post(postUrl, postData, function(response) {
@ -594,7 +594,7 @@ CategoriesHelper.prototype.bindEventHandlers = function() {
* be displayed on the form. * be displayed on the form.
*/ */
CategoriesHelper.prototype.filter = function(key, selectId, display) { CategoriesHelper.prototype.filter = function(key, selectId, display) {
var postUrl = GlobalVariables.baseUrl + '/backend_api/ajax_filter_service_categories'; var postUrl = GlobalVariables.baseUrl + '/index.php/backend_api/ajax_filter_service_categories';
var postData = { 'key': key }; var postData = { 'key': key };
$.post(postUrl, postData, function(response) { $.post(postUrl, postData, function(response) {
@ -631,7 +631,7 @@ CategoriesHelper.prototype.filter = function(key, selectId, display) {
* @param {object} category Contains the category data. * @param {object} category Contains the category data.
*/ */
CategoriesHelper.prototype.save = function(category) { CategoriesHelper.prototype.save = function(category) {
var postUrl = GlobalVariables.baseUrl + '/backend_api/ajax_save_service_category'; var postUrl = GlobalVariables.baseUrl + '/index.php/backend_api/ajax_save_service_category';
var postData = { 'category': JSON.stringify(category) }; var postData = { 'category': JSON.stringify(category) };
$.post(postUrl, postData, function(response) { $.post(postUrl, postData, function(response) {
@ -655,7 +655,7 @@ CategoriesHelper.prototype.save = function(category) {
* @param {int} id Record id to be deleted. * @param {int} id Record id to be deleted.
*/ */
CategoriesHelper.prototype.delete = function(id) { CategoriesHelper.prototype.delete = function(id) {
var postUrl = GlobalVariables.baseUrl + '/backend_api/ajax_delete_service_category'; var postUrl = GlobalVariables.baseUrl + '/index.php/backend_api/ajax_delete_service_category';
var postData = { 'category_id': id }; var postData = { 'category_id': id };
$.post(postUrl, postData, function(response) { $.post(postUrl, postData, function(response) {

View file

@ -168,7 +168,7 @@ var BackendSettings = {
if ($input.prop('readonly') == true || $input.val() == '') return; if ($input.prop('readonly') == true || $input.val() == '') return;
var postUrl = GlobalVariables.baseUrl + '/backend_api/ajax_validate_username'; var postUrl = GlobalVariables.baseUrl + '/index.php/backend_api/ajax_validate_username';
var postData = { var postData = {
'username': $input.val(), 'username': $input.val(),
'user_id': $input.parents().eq(2).find('#user-id').val() 'user_id': $input.parents().eq(2).find('#user-id').val()
@ -205,7 +205,7 @@ var SystemSettings = function() {};
* @param {array} settings Contains the system settings data. * @param {array} settings Contains the system settings data.
*/ */
SystemSettings.prototype.save = function(settings) { SystemSettings.prototype.save = function(settings) {
var postUrl = GlobalVariables.baseUrl + 'backend_api/ajax_save_settings'; var postUrl = GlobalVariables.baseUrl + '/index.php/backend_api/ajax_save_settings';
var postData = { var postData = {
'settings': JSON.stringify(settings), 'settings': JSON.stringify(settings),
'type': BackendSettings.SETTINGS_SYSTEM 'type': BackendSettings.SETTINGS_SYSTEM
@ -346,7 +346,7 @@ UserSettings.prototype.save = function(settings) {
return; // Validation failed, do not procceed. return; // Validation failed, do not procceed.
} }
var postUrl = GlobalVariables.baseUrl + 'backend_api/ajax_save_settings'; var postUrl = GlobalVariables.baseUrl + '/index.php/backend_api/ajax_save_settings';
var postData = { var postData = {
'type': BackendSettings.SETTINGS_USER, 'type': BackendSettings.SETTINGS_USER,
'settings': JSON.stringify(settings) 'settings': JSON.stringify(settings)

View file

@ -100,7 +100,7 @@ var BackendUsers = {
BackendUsers.helper = new SecretariesHelper(); BackendUsers.helper = new SecretariesHelper();
// Update the list with the all the available providers. // Update the list with the all the available providers.
var postUrl = GlobalVariables.baseUrl + '/backend_api/ajax_filter_providers'; var postUrl = GlobalVariables.baseUrl + '/index.php/backend_api/ajax_filter_providers';
var postData = { 'key': '' }; var postData = { 'key': '' };
$.post(postUrl, postData, function(response) { $.post(postUrl, postData, function(response) {
////////////////////////////////////////////////////////// //////////////////////////////////////////////////////////
@ -141,7 +141,7 @@ var BackendUsers = {
return; return;
} }
var postUrl = GlobalVariables.baseUrl + '/backend_api/ajax_validate_username'; var postUrl = GlobalVariables.baseUrl + '/index.php/backend_api/ajax_validate_username';
var postData = { var postData = {
'username': $input.val(), 'username': $input.val(),
'user_id': $input.parents().eq(2).find('.record-id').val() 'user_id': $input.parents().eq(2).find('.record-id').val()

View file

@ -168,7 +168,7 @@ AdminsHelper.prototype.save = function(admin) {
//console.log('Admin data to save:', admin); //console.log('Admin data to save:', admin);
//////////////////////////////////////////// ////////////////////////////////////////////
var postUrl = GlobalVariables.baseUrl + '/backend_api/ajax_save_admin'; var postUrl = GlobalVariables.baseUrl + '/index.php/backend_api/ajax_save_admin';
var postData = { 'admin': JSON.stringify(admin) }; var postData = { 'admin': JSON.stringify(admin) };
$.post(postUrl, postData, function(response) { $.post(postUrl, postData, function(response) {
@ -189,7 +189,7 @@ AdminsHelper.prototype.save = function(admin) {
* @param {int} id Record id to be deleted. * @param {int} id Record id to be deleted.
*/ */
AdminsHelper.prototype.delete = function(id) { AdminsHelper.prototype.delete = function(id) {
var postUrl = GlobalVariables.baseUrl + '/backend_api/ajax_delete_admin'; var postUrl = GlobalVariables.baseUrl + '/index.php/backend_api/ajax_delete_admin';
var postData = { 'admin_id': id }; var postData = { 'admin_id': id };
$.post(postUrl, postData, function(response) { $.post(postUrl, postData, function(response) {
@ -317,7 +317,7 @@ AdminsHelper.prototype.display = function(admin) {
AdminsHelper.prototype.filter = function(key, selectId, display) { AdminsHelper.prototype.filter = function(key, selectId, display) {
if (display == undefined) display = false; if (display == undefined) display = false;
var postUrl = GlobalVariables.baseUrl + '/backend_api/ajax_filter_admins'; var postUrl = GlobalVariables.baseUrl + '/index.php/backend_api/ajax_filter_admins';
var postData = { 'key': key }; var postData = { 'key': key };
$.post(postUrl, postData, function(response) { $.post(postUrl, postData, function(response) {

View file

@ -219,7 +219,7 @@ ProvidersHelper.prototype.save = function(provider) {
//console.log('Provider data to save:', provider); //console.log('Provider data to save:', provider);
////////////////////////////////////////////////// //////////////////////////////////////////////////
var postUrl = GlobalVariables.baseUrl + '/backend_api/ajax_save_provider'; var postUrl = GlobalVariables.baseUrl + '/index.php/backend_api/ajax_save_provider';
var postData = { 'provider': JSON.stringify(provider) }; var postData = { 'provider': JSON.stringify(provider) };
$.post(postUrl, postData, function(response) { $.post(postUrl, postData, function(response) {
@ -240,7 +240,7 @@ ProvidersHelper.prototype.save = function(provider) {
* @param {numeric} id Record id to be deleted. * @param {numeric} id Record id to be deleted.
*/ */
ProvidersHelper.prototype.delete = function(id) { ProvidersHelper.prototype.delete = function(id) {
var postUrl = GlobalVariables.baseUrl + '/backend_api/ajax_delete_provider'; var postUrl = GlobalVariables.baseUrl + '/index.php/backend_api/ajax_delete_provider';
var postData = { 'provider_id': id }; var postData = { 'provider_id': id };
$.post(postUrl, postData, function(response) { $.post(postUrl, postData, function(response) {
@ -393,7 +393,7 @@ ProvidersHelper.prototype.display = function(provider) {
ProvidersHelper.prototype.filter = function(key, selectId, display) { ProvidersHelper.prototype.filter = function(key, selectId, display) {
if (display == undefined) display = false; if (display == undefined) display = false;
var postUrl = GlobalVariables.baseUrl + '/backend_api/ajax_filter_providers'; var postUrl = GlobalVariables.baseUrl + '/index.php/backend_api/ajax_filter_providers';
var postData = { 'key': key }; var postData = { 'key': key };
$.post(postUrl, postData, function(response) { $.post(postUrl, postData, function(response) {

View file

@ -179,7 +179,7 @@ SecretariesHelper.prototype.save = function(secretary) {
//console.log('Secretary data to save:', secretary); //console.log('Secretary data to save:', secretary);
//////////////////////////////////////////////////// ////////////////////////////////////////////////////
var postUrl = GlobalVariables.baseUrl + '/backend_api/ajax_save_secretary'; var postUrl = GlobalVariables.baseUrl + '/index.php/backend_api/ajax_save_secretary';
var postData = { 'secretary': JSON.stringify(secretary) }; var postData = { 'secretary': JSON.stringify(secretary) };
$.post(postUrl, postData, function(response) { $.post(postUrl, postData, function(response) {
@ -200,7 +200,7 @@ SecretariesHelper.prototype.save = function(secretary) {
* @param {int} id Record id to be deleted. * @param {int} id Record id to be deleted.
*/ */
SecretariesHelper.prototype.delete = function(id) { SecretariesHelper.prototype.delete = function(id) {
var postUrl = GlobalVariables.baseUrl + '/backend_api/ajax_delete_secretary'; var postUrl = GlobalVariables.baseUrl + '/index.php/backend_api/ajax_delete_secretary';
var postData = { 'secretary_id': id }; var postData = { 'secretary_id': id };
$.post(postUrl, postData, function(response) { $.post(postUrl, postData, function(response) {
@ -338,7 +338,7 @@ SecretariesHelper.prototype.display = function(secretary) {
SecretariesHelper.prototype.filter = function(key, selectId, display) { SecretariesHelper.prototype.filter = function(key, selectId, display) {
if (display == undefined) display = false; if (display == undefined) display = false;
var postUrl = GlobalVariables.baseUrl + '/backend_api/ajax_filter_secretaries'; var postUrl = GlobalVariables.baseUrl + '/index.php/backend_api/ajax_filter_secretaries';
var postData = { 'key': key }; var postData = { 'key': key };
$.post(postUrl, postData, function(response) { $.post(postUrl, postData, function(response) {

View file

@ -256,7 +256,7 @@ var FrontendBook = {
postData.exclude_appointment_id = GlobalVariables.appointmentData.id; postData.exclude_appointment_id = GlobalVariables.appointmentData.id;
} }
var postUrl = GlobalVariables.baseUrl + '/appointments/ajax_check_datetime_availability'; var postUrl = GlobalVariables.baseUrl + '/index.php/appointments/ajax_check_datetime_availability';
$.post(postUrl, postData, function(response) { $.post(postUrl, postData, function(response) {
//////////////////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////////////////
@ -318,7 +318,7 @@ var FrontendBook = {
}; };
// Make ajax post request and get the available hours. // Make ajax post request and get the available hours.
var ajaxurl = GlobalVariables.baseUrl + '/appointments/ajax_get_available_hours'; var ajaxurl = GlobalVariables.baseUrl + '/index.php/appointments/ajax_get_available_hours';
jQuery.post(ajaxurl, postData, function(response) { jQuery.post(ajaxurl, postData, function(response) {
/////////////////////////////////////////////////////////////// ///////////////////////////////////////////////////////////////
console.log('Get Available Hours JSON Response:', response); console.log('Get Available Hours JSON Response:', response);

View file

@ -305,7 +305,7 @@ var GeneralFunctions = {
$(document).on('click', 'li.language', function() { $(document).on('click', 'li.language', function() {
// Change language with ajax call and refresh page. // Change language with ajax call and refresh page.
var postUrl = GlobalVariables.baseUrl + '/backend_api/ajax_change_language'; var postUrl = GlobalVariables.baseUrl + '/index.php/backend_api/ajax_change_language';
var postData = { 'language': $(this).attr('data-language') }; var postData = { 'language': $(this).attr('data-language') };
$.post(postUrl, postData, function(response) { $.post(postUrl, postData, function(response) {
//////////////////////////////////////////////////// ////////////////////////////////////////////////////