|
|
|
|
@ -43,7 +43,13 @@ const prices = {
|
|
|
|
|
vps: {
|
|
|
|
|
storage: storage_price.map(x => x * 1.1297),
|
|
|
|
|
cpu: [6.146, 7.687, 9.218, 10.749],
|
|
|
|
|
ram: [1.646, 2.057, 2.468, 2.879]
|
|
|
|
|
ram: [1.646, 2.057, 2.468, 2.879],
|
|
|
|
|
options: {
|
|
|
|
|
ip4: {
|
|
|
|
|
basePrice: 4.393,
|
|
|
|
|
factor: 1.097
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
@ -210,7 +216,7 @@ $('#vps_stockage_source')
|
|
|
|
|
$('#vps_cpu_source')
|
|
|
|
|
.slider({
|
|
|
|
|
showThumbTooltip: true,
|
|
|
|
|
restrictedLabels: [0, 1, 2, 4, 8, 16, 32, 48, 64],
|
|
|
|
|
restrictedLabels: [0, 1, 2, 4, 6, 8, 12, 16, 24, 32, 48, 64],
|
|
|
|
|
min: 0,
|
|
|
|
|
max: 64,
|
|
|
|
|
step: 1,
|
|
|
|
|
@ -225,7 +231,7 @@ $('#vps_cpu_source')
|
|
|
|
|
$('#vps_ram_source')
|
|
|
|
|
.slider({
|
|
|
|
|
showThumbTooltip: true,
|
|
|
|
|
restrictedLabels: [0, 1, 2, 4, 6, 8, 12, 16, 24, 32, 48, 64, 96, 128],
|
|
|
|
|
restrictedLabels: [0, 1, 2, 4, 8, 12, 16, 24, 32, 48, 64, 96, 128],
|
|
|
|
|
min: 0,
|
|
|
|
|
max: 128,
|
|
|
|
|
step: 1,
|
|
|
|
|
@ -250,6 +256,7 @@ function updatePrice() {
|
|
|
|
|
const vpsPriceStorage = $('#vps_stockage_source').slider('get value');
|
|
|
|
|
const vpsPriceCpu = $('#vps_cpu_source').slider('get value');
|
|
|
|
|
const vpsPriceRam = $('#vps_ram_source').slider('get value');
|
|
|
|
|
const cbVpsIp4 = $('.ui.toggle.checkbox.vps_opt_ip4').checkbox('is checked');
|
|
|
|
|
|
|
|
|
|
const cbNcLxc = $('.ui.toggle.checkbox.nc_opt_lxc').checkbox('is checked');
|
|
|
|
|
const cbNcDedicated = $('.ui.toggle.checkbox.nc_opt_decicated').checkbox('is checked');
|
|
|
|
|
@ -311,6 +318,7 @@ function updatePrice() {
|
|
|
|
|
let vpsPrice = vpsPriceStorage * prices.vps.storage[i]
|
|
|
|
|
+ vpsPriceCpu * prices.vps.cpu[i]
|
|
|
|
|
+ vpsPriceRam * prices.vps.ram[i];
|
|
|
|
|
if (cbVpsIp4) vpsPrice = (vpsPrice + prices.vps.options.ip4.basePrice) * prices.vps.options.ip4.factor;
|
|
|
|
|
|
|
|
|
|
let totalPrice = ncPrice + whPrice + mailPrice + vpsPrice;
|
|
|
|
|
|
|
|
|
|
|