|
|
@@ -3820,12 +3820,16 @@ function updateProductTotalMessage(billingcycle) {
|
|
|
switch(billingcycle) {
|
|
|
case 'monthly':
|
|
|
console.log(billingcycle);
|
|
|
- days = daysIntoYear(new Date(now.getFullYear(), now.getMonth() + 1, 0)) - daysIntoYear(new Date(now.getFullYear(), now.getMonth(), now.getDate()));
|
|
|
- console.log(days);
|
|
|
+ billingDay = daysIntoYear(new Date(now.getFullYear(), now.getMonth() + 1, 0));
|
|
|
+ orderDay = daysIntoYear(new Date(now.getFullYear(), now.getMonth(), now.getDate()));
|
|
|
+ console.log(billingDay - orderDay);
|
|
|
jQuery('#producttotalmessage').html('Monatlich');
|
|
|
break;
|
|
|
case 'quarterly':
|
|
|
console.log(billingcycle);
|
|
|
+ if (now.getMonth() < 4) {
|
|
|
+ console.log("1st quarter");
|
|
|
+ }
|
|
|
jQuery('#producttotalmessage').html('4teljährlich');
|
|
|
break;
|
|
|
case 'semiannually':
|
|
|
@@ -3834,8 +3838,9 @@ function updateProductTotalMessage(billingcycle) {
|
|
|
break;
|
|
|
case 'annually':
|
|
|
console.log(billingcycle);
|
|
|
- days = daysIntoYear(new Date(now.getFullYear(), 11, 31)) - daysIntoYear(new Date(now.getFullYear(), now.getMonth(), now.getDate()));
|
|
|
- console.log(days);
|
|
|
+ billingDay = daysIntoYear(new Date(now.getFullYear(), 11, 31));
|
|
|
+ orderDay = daysIntoYear(new Date(now.getFullYear(), now.getMonth(), now.getDate()));
|
|
|
+ console.log(billingDay - orderDay);
|
|
|
jQuery('#producttotalmessage').html('Jährlich');
|
|
|
break;
|
|
|
}
|