민원상세조회 화면 차적조회 수정

main
이범준 10 months ago
parent 6da8482a46
commit f8d3456a5b

@ -863,7 +863,7 @@ $(document).ready(function(){
//차적조회 //차적조회
$("#vhrno--${pageName}").onEnterPress(function(){ $("#vhrno--${pageName}").onEnterPress(async function(){
var crdnYmd = $("#crdnYmd--${pageName}").val().replaceAll("-", ""); var crdnYmd = $("#crdnYmd--${pageName}").val().replaceAll("-", "");
var vhrnoEl = event.target; var vhrnoEl = event.target;
@ -891,83 +891,75 @@ $(document).ready(function(){
return; return;
} }
json.post({ var resp = await getVhclInfo($("#sggCd--${pageName}").val(), vhrno, crdnYmd);
url: wctx.url("/payer/vehicle.do"),
data: {
sggCd : $("#sggCd--${pageName}").val(),
vhrno : vhrno,
levy_stdde : crdnYmd
},
success:resp => {
if(!resp.found){
dialog.alert({
content : "차량 정보가 없습니다.",
init : function() {
setDialogZindex();
focusClose();
}
});
$("#rtpyrId--${pageName}").val(""); if(!resp.found){
$("#rtpyrNm--${pageName}").val(""); dialog.alert({
$("#rtpyrSeCd--${pageName}").val(""); content : "차량 정보가 없습니다.",
$("#rtpyrNo--${pageName}").val(""); init : function() {
$("#vin--${pageName}").val(""); setDialogZindex();
$("#vhclNm--${pageName}").val(""); focusClose();
$("#vhclColor--${pageName}").val("");
$("#useFuelCd--${pageName}").val("");
$("#ffnlgCarmdlCd--${pageName}").val("");
$("#zip--${pageName}").val("");
$("#addr--${pageName}").val("");
$("#dtlAddr--${pageName}").val("");
return;
} }
});
$("#rtpyrId--${pageName}").val(resp.rtpyrId); $("#rtpyrId--${pageName}").val("");
$("#rtpyrNm--${pageName}").val("");
var vehicle = resp.vehicle; $("#rtpyrSeCd--${pageName}").val("");
$("#rtpyrNo--${pageName}").val("");
$("#vin--${pageName}").val("");
$("#vhclNm--${pageName}").val("");
$("#vhclColor--${pageName}").val("");
$("#useFuelCd--${pageName}").val("");
$("#ffnlgCarmdlCd--${pageName}").val("");
$("#zip--${pageName}").val("");
$("#addr--${pageName}").val("");
$("#dtlAddr--${pageName}").val("");
return;
}
$("#rtpyrNm--${pageName}").val(vehicle.mber_nm); $("#rtpyrId--${pageName}").val(resp.rtpyrId);
var pyrSeCd = ""; var vehicle = resp.vehicle;
switch(vehicle.mber_se_code){
case "11" : pyrSeCd = "01"; break;
case "12" : pyrSeCd = "02"; break;
case "13" : pyrSeCd = "03"; break;
case "14" : pyrSeCd = "04"; break;
case "15" : pyrSeCd = "05"; break;
}
$("#rtpyrSeCd--${pageName}").val(pyrSeCd);
$("#rtpyrNo--${pageName}").val(vehicle.mber_se_no); $("#rtpyrNm--${pageName}").val(vehicle.mber_nm);
$("#vin--${pageName}").val(vehicle.vin); var pyrSeCd = "";
$("#vhclNm--${pageName}").val(vehicle.cnm); switch(vehicle.mber_se_code){
$("#vhclColor--${pageName}").val(vehicle.color_nm); case "11" : pyrSeCd = "01"; break;
$("#useFuelCd--${pageName}").val(vehicle.use_fuel_code); case "12" : pyrSeCd = "02"; break;
case "13" : pyrSeCd = "03"; break;
case "14" : pyrSeCd = "04"; break;
case "15" : pyrSeCd = "05"; break;
}
$("#rtpyrSeCd--${pageName}").val(pyrSeCd);
$("#rtpyrNo--${pageName}").val(vehicle.mber_se_no);
$("#vin--${pageName}").val(vehicle.vin);
$("#vhclNm--${pageName}").val(vehicle.cnm);
$("#vhclColor--${pageName}").val(vehicle.color_nm);
$("#useFuelCd--${pageName}").val(vehicle.use_fuel_code);
if(vehicle.vhcty_asort_code == "1"){ //승용
$("#ffnlgCarmdlCd--${pageName}").val("11");
} else if(vehicle.vhcty_asort_code == "2"){ //승합
$("#ffnlgCarmdlCd--${pageName}").val("12");
} else if(vehicle.vhcty_asort_code == "3"){ //화물
if(vehicle.mxmm_ldg <= 4000){
$("#ffnlgCarmdlCd--${pageName}").val("13");
} else {
$("#ffnlgCarmdlCd--${pageName}").val("14");
}
} else if(vehicle.vhcty_asort_code == "4"){ //특수
$("#ffnlgCarmdlCd--${pageName}").val("15");
} else {
$("#ffnlgCarmdlCd--${pageName}").val("");
}
if(vehicle.vhcty_asort_code == "1"){ //승용 $("#zip--${pageName}").val(vehicle.zip_code); //우편번호
$("#ffnlgCarmdlCd--${pageName}").val("11"); $("#addr--${pageName}").val(vehicle.road_nm_adres); //주소
} else if(vehicle.vhcty_asort_code == "2"){ //승합 $("#dtlAddr--${pageName}").val(vehicle.use_strnghld_adres_nm); //상세주소
$("#ffnlgCarmdlCd--${pageName}").val("12");
} else if(vehicle.vhcty_asort_code == "3"){ //화물
if(vehicle.mxmm_ldg <= 4000){
$("#ffnlgCarmdlCd--${pageName}").val("13");
} else {
$("#ffnlgCarmdlCd--${pageName}").val("14");
}
} else if(vehicle.vhcty_asort_code == "4"){ //특수
$("#ffnlgCarmdlCd--${pageName}").val("15");
} else {
$("#ffnlgCarmdlCd--${pageName}").val("");
}
$("#zip--${pageName}").val(vehicle.zip_code); //우편번호
$("#addr--${pageName}").val(vehicle.road_nm_adres); //주소
$("#dtlAddr--${pageName}").val(vehicle.use_strnghld_adres_nm); //상세주소
}
});
}); });

Loading…
Cancel
Save