// JavaScript Document function ReCount(fid, cid, forsale, ch_limit, promt) { plus = eval(fid + '.' + cid); if (ch_limit == 1) { if ((forsale - plus.value) > 0) { plus.value = plus.value*1+1; } else { alert(promt); } } else { plus.value = plus.value*1+1; } } function TestCount(fid, cid, forsale, ch_limit, promt) { plus = eval(fid + '.' + cid); if (ch_limit == 1) { if (plus.value > 0) { if ((forsale - plus.value) < 0) { alert(promt); plus.value = ''; } } } } var dialogWindow = null; var theField = null; function ShowDialog(form,theInput,language) { theField = eval( "document." + form + "." + theInput ); //theField.value = ""; theDate = theField.value; i=theDate.indexOf("."); theDate=theDate.slice(i+1); i=theDate.indexOf("."); theMonth=1*theDate.slice(0,i) - 1; theYear=theDate.slice(i+1,i+5); dialogWindow=window.open("calendar.php?month="+theMonth+"&year="+theYear+"&language="+language,"Kalendář", "dependent=yes,menubar=no,location=no,resizable=no,width=350,height=350,toolbar=no,screenX=100,screeny=100" ); } function Transfer( theValue ) { if( theField != null ) theField.value = theValue; } function HideDialog() { if( dialogWindow != null ) { if (typeof(dialogWindow.document) == "object") dialogWindow.close() } } function RowClick(rec_id) { old_rec_id = order_form.rec.value; order_form.rec.value = rec_id; row = document.getElementById("r" + rec_id); row.className = 'selected'; row = document.getElementById("r" + old_rec_id); SetRegularClass(row, old_rec_id) } function SetHover(rec_id) { old_rec_id = order_form.rec.value; if (rec_id != old_rec_id) { row = document.getElementById("r" + rec_id); row.className = 'hot'; } } function UnsetHover(rec_id) { old_rec_id = order_form.rec.value; if (rec_id != old_rec_id) { row = document.getElementById("r" + rec_id); SetRegularClass(row, rec_id); } } function SetHoverSimple(rec_id) { row = document.getElementById("r" + rec_id); row.className = 'hot'; } function UnsetHoverSimple(rec_id) { row = document.getElementById("r" + rec_id); SetRegularClass(row, rec_id); } function SetRegularClass(row, rec_id) { if (rec_id%2) { row.className = 'blue'; } else { row.className = 'green'; } }