forked from mirrors/easyappointments
Merge pull request #660 from yrammos/hide-zero-price
Hide service price in modal views if equal to zero.
This commit is contained in:
commit
2e9d8c963e
1 changed files with 4 additions and 4 deletions
|
@ -501,11 +501,11 @@ window.FrontendBook = window.FrontendBook || {};
|
||||||
}
|
}
|
||||||
|
|
||||||
var selServiceId = $('#select-service').val();
|
var selServiceId = $('#select-service').val();
|
||||||
var servicePrice;
|
var servicePrice = '';
|
||||||
var serviceCurrency;
|
var serviceCurrency = '';
|
||||||
|
|
||||||
$.each(GlobalVariables.availableServices, function (index, service) {
|
$.each(GlobalVariables.availableServices, function (index, service) {
|
||||||
if (service.id == selServiceId) {
|
if (service.id == selServiceId && service.price != '' && service.price != null && service.price != '0.00' && service.price != '0,00') {
|
||||||
servicePrice = '<br>' + service.price;
|
servicePrice = '<br>' + service.price;
|
||||||
serviceCurrency = service.currency;
|
serviceCurrency = service.currency;
|
||||||
return false; // break loop
|
return false; // break loop
|
||||||
|
@ -680,7 +680,7 @@ window.FrontendBook = window.FrontendBook || {};
|
||||||
html += '[' + EALang.duration + ' ' + service.duration + ' ' + EALang.minutes + ']';
|
html += '[' + EALang.duration + ' ' + service.duration + ' ' + EALang.minutes + ']';
|
||||||
}
|
}
|
||||||
|
|
||||||
if (service.price != '' && service.price != null) {
|
if (service.price != '' && service.price != null && service.price != '0.00' && service.price != '0,00') {
|
||||||
html += '[' + EALang.price + ' ' + service.price + ' ' + service.currency + ']';
|
html += '[' + EALang.price + ' ' + service.price + ' ' + service.currency + ']';
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue