function ptHauskatalog() { this.url="/_gui/_TVB/hauskatalog/xHauskatalog.asp"; } ptHauskatalog.prototype.init = function() { var ort = gEL("hkOrt"); if(ort) this.ort = ort.value; var hk = gEL("hauskat"); if(hk) this.hk = hk.value; } ptHauskatalog.prototype.lvOrte_Click = function(recID) { this.ort = this.lvOrte.recID; this.checkLoad(); } ptHauskatalog.prototype.lvHauskat_Click = function(recID) { this.hk = this.lvHauskat.recID; this.updateOrte(); this.checkLoad(); } ptHauskatalog.prototype.lvMonate_Click = function(recID) { this.monat = recID; this.checkLoad(); } ptHauskatalog.prototype.checkLoad = function() { if(!this.ort||!this.hk) return; if(this.lvMonate && !this.monat) return; this.status("Häuserkatalog wird geladen .."); xmlhttp(this.url,this.getData(),this.doneLoad,"",this); } ptHauskatalog.prototype.status = function(tx) { this.setContent(web.sandclock + "  " + tx); } ptHauskatalog.prototype.setContent = function(tx) { gEL("divHK").innerHTML = tx; } ptHauskatalog.prototype.getData = function() { var dat = "web="+web.webname+"&ort="+getWert(this.ort)+"&hk="+getWert(this.hk); if(this.monat) dat+="&monat="+this.monat; return dat; } ptHauskatalog.prototype.doneLoad = function(ret) { if(check4Error("ptHauskatalog.doneLoad",ret)) return; this.setContent(ret); } ptHauskatalog.prototype.updateOrte = function() { data = this.getData() + "&cod=refresh"; xmlhttp(this.url,data,this.doneUpdate,"",this); } ptHauskatalog.prototype.doneUpdate = function(ret) { if(check4Error("ptHauskatalog.doneUpdate",ret)) return; var anz = ret.split(","); for(i=0;i < anz.length;i++) { with(this.lvOrte) { setValue(i,2,anz[i]); if(anz[i]==0) { var cod = false; }else{ var cod = true; } setActive(i,cod); } } }