diff --git a/assets/js/pages/booking.js b/assets/js/pages/booking.js index df4d5e26..a484a181 100644 --- a/assets/js/pages/booking.js +++ b/assets/js/pages/booking.js @@ -626,6 +626,7 @@ App.Pages.Booking = (function () { // Customer Details const firstName = App.Utils.String.escapeHtml($firstName.val()); const lastName = App.Utils.String.escapeHtml($lastName.val()); + const fullName = firstName + ' ' + lastName; const phoneNumber = App.Utils.String.escapeHtml($phoneNumber.val()); const email = App.Utils.String.escapeHtml($email.val()); const address = App.Utils.String.escapeHtml($address.val()); @@ -641,30 +642,30 @@ App.Pages.Booking = (function () { }), $('

', { 'html': [ - $('', { - 'text': lang('customer') + ': ' + firstName + ' ' + lastName - }), - $('
'), - $('', { + fullName ? $('', { + 'text': lang('customer') + ': ' + fullName + }) : null, + fullName ? $('
') : null, + phoneNumber ? $('', { 'text': lang('phone_number') + ': ' + phoneNumber - }), - $('
'), - $('', { + }) : null, + phoneNumber ? $('
') : null, + email ? $('', { 'text': lang('email') + ': ' + email - }), - $('
'), - $('', { - 'text': address ? lang('address') + ': ' + address : '' - }), - $('
'), - $('', { - 'text': city ? lang('city') + ': ' + city : '' - }), - $('
'), - $('', { - 'text': zipCode ? lang('zip_code') + ': ' + zipCode : '' - }), - $('
') + }) : null, + email ? $('
') : null, + address ? $('', { + 'text': lang('address') + ': ' + address + }) : null, + address ? $('
') : null, + city ? $('', { + 'text': lang('city') + ': ' + city, + }) : null, + city ? $('
') : null, + zipCode ? $('', { + 'text': lang('zip_code') + ': ' + zipCode + }) : null, + zipCode ? $('
') : null ] }) ]