46 lines
915 B
JavaScript
46 lines
915 B
JavaScript
var interval_id;
|
|
var charge_data = {};
|
|
var TPL = {};
|
|
|
|
function auktion(los_nr){
|
|
if(charge_data[los_nr]['auktionLaufzeit'] <= charge_data[los_nr]['auktionDauer']){
|
|
|
|
viewCanvasData(los_nr);
|
|
|
|
calcVkPreis(los_nr);
|
|
viewAktuelleAuktion(los_nr);
|
|
viewNaechsteAuktion(los_nr);
|
|
viewLetzteAuktion(los_nr);
|
|
|
|
charge_data[los_nr]['auktionLaufzeit']++;
|
|
}
|
|
};
|
|
|
|
function los(los_nr){
|
|
calcVkPreis(los_nr);
|
|
viewLetzteAuktion(los_nr);
|
|
viewNaechsteAuktion(los_nr);
|
|
viewAktuelleAuktion(los_nr);
|
|
|
|
|
|
interval_id = setInterval( function() {auktion(los_nr)}, 1000);
|
|
};
|
|
|
|
function charge(){
|
|
// if( Number(document.getElementById('los_nr').value) == -1){
|
|
// alert("neu");
|
|
neueCharge();
|
|
// }
|
|
// else{
|
|
// alert("gebr");
|
|
// los(document.getElementById('los_nr').value);
|
|
// }
|
|
|
|
};
|
|
|
|
$(document).ready(
|
|
function(){
|
|
TPL.engine = new TELIB.TemplateManager_cl();
|
|
charge();
|
|
}
|
|
); |