mirror of
https://github.com/alextselegidis/easyappointments.git
synced 2024-11-10 10:02:33 +03:00
More formatting changes
This commit is contained in:
parent
b2d2a5a1ce
commit
7c082689ea
7 changed files with 22 additions and 22 deletions
|
@ -284,16 +284,16 @@ body legend {
|
|||
width: auto;
|
||||
}
|
||||
|
||||
.form-sub-button img{
|
||||
.form-sub-button img {
|
||||
margin-top: -.25rem;
|
||||
}
|
||||
|
||||
.hidden{
|
||||
.hidden {
|
||||
visibility: hidden;
|
||||
height: 0;
|
||||
}
|
||||
|
||||
.hide-toggle div{
|
||||
.hide-toggle div {
|
||||
display: flex;
|
||||
}
|
||||
|
||||
|
@ -444,7 +444,7 @@ body legend {
|
|||
#calendar .fc-event {
|
||||
border: 1px solid #4790CA;
|
||||
background-color: #4790CA;
|
||||
min-height: 12px;
|
||||
min-height: 12px;
|
||||
}
|
||||
|
||||
#existing-customers-list {
|
||||
|
|
|
@ -235,7 +235,7 @@ window.BackendCalendarAppointmentsModal = window.BackendCalendarAppointmentsModa
|
|||
|
||||
var key = $(this).val().toLowerCase();
|
||||
|
||||
filterExistingCustomersTimeout = setTimeout(function() {
|
||||
filterExistingCustomersTimeout = setTimeout(function () {
|
||||
var $list = $('#existing-customers-list');
|
||||
|
||||
var url = GlobalVariables.baseUrl + '/index.php/backend_api/ajax_filter_customers';
|
||||
|
@ -291,7 +291,7 @@ window.BackendCalendarAppointmentsModal = window.BackendCalendarAppointmentsModa
|
|||
}
|
||||
});
|
||||
})
|
||||
.always(function() {
|
||||
.always(function () {
|
||||
$('#loading').css('visibility', '');
|
||||
});
|
||||
}, 1000);
|
||||
|
|
|
@ -1413,7 +1413,7 @@ window.BackendCalendarDefaultView = window.BackendCalendarDefaultView || {};
|
|||
height: getCalendarHeight(),
|
||||
editable: true,
|
||||
firstDay: firstWeekdayNumber,
|
||||
slotDuration: '00:15:00',
|
||||
slotDuration: '00:15:00',
|
||||
snapDuration: '00:15:00',
|
||||
slotLabelInterval: '01:00',
|
||||
timeFormat: timeFormat,
|
||||
|
|
|
@ -224,8 +224,8 @@ window.BackendSettings = window.BackendSettings || {};
|
|||
* @argument isVisible a boolean which is true if the button should display 'visible' and false when the button should display 'hidden'
|
||||
*
|
||||
*/
|
||||
function setShowToggleValue($element, isVisible){
|
||||
if (getShowToggleValue($element) !== isVisible){
|
||||
function setShowToggleValue($element, isVisible) {
|
||||
if (getShowToggleValue($element) !== isVisible) {
|
||||
$element.find("div").toggleClass("hidden");
|
||||
}
|
||||
}
|
||||
|
@ -237,7 +237,7 @@ window.BackendSettings = window.BackendSettings || {};
|
|||
*
|
||||
* @return the state of the button. True for visible, false for hidden.
|
||||
*/
|
||||
function getShowToggleValue($element){
|
||||
function getShowToggleValue($element) {
|
||||
var visiblePartArray = $element.find(".hide-toggle-visible");
|
||||
return !visiblePartArray.hasClass("hidden");
|
||||
}
|
||||
|
@ -248,7 +248,7 @@ window.BackendSettings = window.BackendSettings || {};
|
|||
* make sure that our phone number is visible when it is required.
|
||||
*/
|
||||
$('#show-phone-number').on('click', function () {
|
||||
if (!getShowToggleValue($(this))){//if button is set to hidden
|
||||
if (!getShowToggleValue($(this))) {//if button is set to hidden
|
||||
$('#require-phone-number').prop('checked', false);
|
||||
}
|
||||
});
|
||||
|
@ -259,7 +259,7 @@ window.BackendSettings = window.BackendSettings || {};
|
|||
* make sure that our phone number is visible when it is required.
|
||||
*/
|
||||
$('#require-phone-number').on('click', function () {
|
||||
if ($(this).prop('checked')){
|
||||
if ($(this).prop('checked')) {
|
||||
setShowToggleValue($('#show-phone-number'), true);
|
||||
}
|
||||
});
|
||||
|
@ -287,7 +287,7 @@ window.BackendSettings = window.BackendSettings || {};
|
|||
|
||||
$.post(url, data)
|
||||
.done(function (response) {
|
||||
if (response === 'false') {
|
||||
if (response.is_valid === 'false') {
|
||||
$input.closest('.form-group').addClass('has-error');
|
||||
Backend.displayNotification(EALang.username_already_exists);
|
||||
$input.attr('already-exists', 'true');
|
||||
|
|
|
@ -32,7 +32,7 @@
|
|||
if (!this.validate()) {
|
||||
return; // Validation failed, do not proceed.
|
||||
}
|
||||
|
||||
|
||||
var url = GlobalVariables.baseUrl + '/index.php/backend_api/ajax_save_settings';
|
||||
|
||||
var data = {
|
||||
|
@ -80,12 +80,12 @@
|
|||
var visiblePartArray = $element.find(".hide-toggle-visible");
|
||||
var invisiblePartArray = $element.find(".hide-toggle-hidden");
|
||||
if (!(visiblePartArray.length === 0 || invisiblePartArray.length === 0)) {
|
||||
if (visiblePartArray.hasClass("hidden")){//our button is currently invisible
|
||||
if (visiblePartArray.hasClass("hidden")) {//our button is currently invisible
|
||||
return '0';//invisible
|
||||
}else{//our button is currently visible
|
||||
} else {//our button is currently visible
|
||||
return '1';//visible
|
||||
}
|
||||
}else{
|
||||
} else {
|
||||
return '0';//invisible
|
||||
}
|
||||
}
|
||||
|
|
|
@ -69,14 +69,14 @@ window.FrontendBookApi = window.FrontendBookApi || {};
|
|||
|
||||
$.post(url, data)
|
||||
.done(function (response) {
|
||||
// The response contains the available hours for the selected provider and
|
||||
// service. Fill the available hours div with response data.
|
||||
// The response contains the available hours for the selected provider and service. Fill the available
|
||||
// hours div with response data.
|
||||
if (response.length > 0) {
|
||||
var providerId = $('#select-provider').val();
|
||||
|
||||
if (providerId === 'any-provider') {
|
||||
for (var availableProvider of GlobalVariables.availableProviders) {
|
||||
if (availableProvider.services.indexOf(serviceId) !== -1) {
|
||||
if (availableProvider.services.indexOf(Number(serviceId)) !== -1) {
|
||||
providerId = availableProvider.id; // Use first available provider.
|
||||
break;
|
||||
}
|
||||
|
@ -99,7 +99,7 @@ window.FrontendBookApi = window.FrontendBookApi || {};
|
|||
var availableHourMoment = moment
|
||||
.tz(selectedDate + ' ' + availableHour + ':00', providerTimezone)
|
||||
.tz(selectedTimezone);
|
||||
|
||||
|
||||
if (availableHourMoment.format('YYYY-MM-DD') !== selectedDate) {
|
||||
return; // Due to the selected timezone the available hour belongs to another date.
|
||||
}
|
||||
|
|
|
@ -8,7 +8,7 @@
|
|||
* @link http://easyappointments.org
|
||||
* @since v1.4.0
|
||||
* ---------------------------------------------------------------------------- */
|
||||
|
||||
|
||||
$(function () {
|
||||
'use strict';
|
||||
|
||||
|
|
Loading…
Reference in a new issue