function bannerFillSelectFromArray(selectCtrl, itemArray, val) { var i,j,k; // del items for (i=selectCtrl.options.length; i>=0; i--) { selectCtrl.options[i]=null; } if (val==0 ) return; if (itemArray!=null) { itemArray=itemArray[val]; // add new for (i=0; i0) { elements[i+1][0] = tipus[type][subtype][4][i][0]+" - "+ tipus[type][subtype][4][i][1]+" millió"; } else { elements[i+1][0] = tipus[type][subtype][4][i][0]+" és afelett"; } } bannerFillSelectFromArray(document.forms.form.guidePrice, new Array(null, elements), 1); document.getElementById('guideprice_list').style.display='none'; if (document.getElementById('guideprice_manual')!=null) { document.getElementById('guideprice_manual').style.display='none'; } switch (document.forms.form.priceType.value) { case 'list': document.getElementById('guideprice_list').style.display=''; break; case 'manual': if (document.getElementById('guideprice_manual')!=null) { document.getElementById('guideprice_manual').style.display=''; } else { document.getElementById('guideprice_list').style.display=''; } break; default: document.getElementById(defaulttype).style.display=''; break; } if (document.getElementById('priceStepSpan')!=null) { document.getElementById('priceStepSpan').innerHTML = tipus[type][subtype][3]; } } if (document.getElementById('guideprice_help').style.display!='none') { document.getElementById('guideprice_help').style.display='none'; } } function setPriceType(type) { switch (type) { case 'manual': document.getElementById('guideprice_list').style.display = 'none'; document.getElementById('guideprice_none').style.display = 'none'; document.getElementById('guideprice_manual').style.display = ''; document.forms.form.priceType.value = 'manual'; break; case 'list': document.getElementById('guideprice_none').style.display = 'none'; document.getElementById('guideprice_manual').style.display = 'none'; document.getElementById('guideprice_list').style.display = ''; document.forms.form.priceType.value = 'list'; break; } } function fillTerseg(id) { if (document.forms.form.addressArea == undefined) return; var pos; for (pos=0; pos=tersegek.length) return; bannerFillSelectFromArray(document.forms.form.addressArea, tersegek[pos], 1); document.forms.form.addressArea.selectedIndex=-1; } function dynamic_onchangeprices(offertype, subtypeid, choose) { var i; if (choose) offertype++; if (tipus[offertype]==null) return; for(i=0; i=tipus[offertype].length) return; my_onchangeprices(offertype, i); }