function chkcost() { var paper_code =document.orderform.paper_code; memo1_change(); costchange(); } function costchange() { var kind_code =document.orderform.kind_code; var paper_code =document.orderform.paper_code; var color_code =document.orderform.color_code; var coating_code =document.orderform.coating_code; var size_code =document.orderform.size_code; var qty_code =document.orderform.qty_code; var price =document.orderform.pay; var subtitle = document.orderform.product_num.value; var frm = document.orderform; var print_code =document.orderform.print_code; document.orderform.cut1.value = "2"; if(print_code.value == 'Y'){ if(qty_code.value == 2){price.value = 9000*subtitle} else if(qty_code.value == 3){price.value = 13200*subtitle} else if(qty_code.value == 4){price.value = 17200*subtitle} else if(qty_code.value == 5){price.value = 21000*subtitle} else if(qty_code.value == 6){price.value = 24300*subtitle} else if(qty_code.value == 7){price.value = 27300*subtitle} else if(qty_code.value == 8){price.value = 30000*subtitle} else if(qty_code.value == 9){price.value = 32400*subtitle} else if(qty_code.value == 10){price.value = 34500*subtitle} else if(qty_code.value == 11){price.value = 36300*subtitle} else if(qty_code.value == 12){price.value = 37800*subtitle} else if(qty_code.value == 13){price.value = 39000*subtitle} else if(qty_code.value == 14){price.value = 40300*subtitle} else if(qty_code.value == 15){price.value = 41400*subtitle} else if(qty_code.value == 16){price.value = 42200*subtitle} else if(qty_code.value == 17){price.value = 43000*subtitle} else if(qty_code.value == 18){price.value = 43700*subtitle} else if(qty_code.value == 19){price.value = 44300*subtitle} else if(qty_code.value == 20){price.value = 44600*subtitle} else if(qty_code.value == 30){price.value = 63900*subtitle} else if(qty_code.value == 40){price.value = 81200*subtitle} else if(qty_code.value == 50){price.value = 96500*subtitle} else {price.value = 0} } else { if(qty_code.value == 2){price.value = 3000*subtitle} else if(qty_code.value == 3){price.value = 4500*subtitle} else if(qty_code.value == 4){price.value = 6000*subtitle} else if(qty_code.value == 5){price.value = 7500*subtitle} else if(qty_code.value == 6){price.value = 9000*subtitle} else if(qty_code.value == 7){price.value = 10500*subtitle} else if(qty_code.value == 8){price.value = 12000*subtitle} else if(qty_code.value == 9){price.value = 13500*subtitle} else if(qty_code.value == 10){price.value = 15000*subtitle} else if(qty_code.value == 11){price.value = 16500*subtitle} else if(qty_code.value == 12){price.value = 18000*subtitle} else if(qty_code.value == 13){price.value = 19500*subtitle} else if(qty_code.value == 14){price.value = 21000*subtitle} else if(qty_code.value == 15){price.value = 22500*subtitle} else if(qty_code.value == 16){price.value = 24000*subtitle} else if(qty_code.value == 17){price.value = 25500*subtitle} else if(qty_code.value == 18){price.value = 27000*subtitle} else if(qty_code.value == 19){price.value = 28500*subtitle} else if(qty_code.value == 20){price.value = 30000*subtitle} else if(qty_code.value == 30){price.value = 45000*subtitle} else if(qty_code.value == 40){price.value = 60000*subtitle} else if(qty_code.value == 50){price.value = 75000*subtitle} else {price.value = 0} } price01_change(); } function memo1_change() { var kind_code =document.orderform.kind_code; var paper_code =document.orderform.paper_code; var color_code =document.orderform.color_code; var size_code =document.orderform.size_code; var qty_code =document.orderform.qty_code; var price =document.orderform.pay; var subtitle = document.orderform.product_num; document.all.memo1.innerHTML = paper_code.options[paper_code.selectedIndex].innerText + " / " + color_code.options[color_code.selectedIndex].innerText + " / " + size_code.options[size_code.selectedIndex].innerText+" / "+ qty_code.options[qty_code.selectedIndex].innerText + " / " + subtitle.options[subtitle.selectedIndex].innerText; } function price01_change() { var frm = document.orderform; var qty_code =document.orderform.qty_code; var subtitle = document.orderform.product_num.value; var after_price_gui_price = 0; /* ÈÄ°¡°ø_±Íµµ¸® if(frm.after_gui.value!=""){ after_gui_cost(); } after_price_gui_price = eval(document.orderform.after_price_gui.value); ÈÄ°¡°ø_¹Ú if(frm.after_bak.value!=""){ after_bak_cost(); } ÈÄ°¡°øÃÑÇÕ total_after(); */ var price = frm.pay; var after_price = frm.after_total_price_plus.value; var price_01 = frm.price_01; price_01.value = Math.round(price.value); document.all.span_price.innerHTML = comma(Math.round(price.value)); document.all.break_pro_price_plus.innerHTML = comma(Math.round(price.value)); //Á¦Ç° ÃÑ¾× document.all.view_price.innerHTML = comma(Math.round(eval(price.value)+after_price_gui_price)); //Á¦Ç° ÃѾ×(»ó´Ü)20111226 Ãß°¡ document.all.span_total_estimate_prie.innerHTML = comma(Math.round(eval(price.value)+eval(after_price))); //Á¦Ç° + ÈÄ°¡°ø ÃÑ¾× //alert(frm.after_total_price.value); //ºÎ°¡¼¼ tax_price = (eval(price.value)+eval(after_price))/10 frm.tax_price.value = tax_price; document.all.span_tax_price.innerHTML = comma(tax_price); //°ßÀûÃÑ¾× estimate_price = eval(price.value)+eval(after_price)+eval(tax_price) frm.estimate_price_end.value = estimate_price; document.all.span_estimate_price_end.innerHTML = comma(estimate_price); //ÁÖ¹® ¹Ù·Î¹Ø¿¡ Á¦Ç°±Ý¾×, ºÎ°¡¼¼, °ßÀûÃÑ¾× # ±Ý¾× view_price display:none 2017-12-15 if ($("#span_total_estimate_prie_sub").length > 0){ var span_total_estimate_prie_val = $("#span_total_estimate_prie").text(); $("#span_total_estimate_prie_sub").text(span_total_estimate_prie_val); } if ($("#span_tax_price_sub").length > 0){ var span_tax_price_val = $("#span_tax_price").text(); $("#span_tax_price_sub").text(span_tax_price_val); } if ($("#span_estimate_price_end_sub").length > 0){ var span_estimate_price_end_val = $("#span_estimate_price_end").text(); $("#span_estimate_price_end_sub").text(span_estimate_price_end_val); } } function comma(x){ var txtNumber = '' + x; var rxSplit = new RegExp('([0-9])([0-9][0-9][0-9][,.])'); var arrNumber = txtNumber.split('.'); arrNumber[0] += '.'; do{ arrNumber[0] = arrNumber[0].replace(rxSplit, '$1,$2'); } while (rxSplit.test(arrNumber[0])); if (arrNumber.length > 1) { return arrNumber.join(''); }else{ return arrNumber[0].split('.')[0]; } }