marseyes 2 år sedan
förälder
incheckning
9fdeb4d13b

+ 3 - 1
src/main/webapp/app/settmng/SETTMNG03010.html

@@ -82,6 +82,8 @@
82 82
 								<input type="hidden" id="ITP_FORM_SETTMNG03010_DETAIL_STORE_ID" name="storeId" value="">
83 83
 								<input type="hidden" id="ITP_FORM_SETTMNG03010_DETAIL_SPPLY_ID" name="spplyId" value="">
84 84
 								<input type="hidden" id="ITP_FORM_SETTMNG03010_DETAIL_STTL_MGNT_UNQ_NO" name="sttlMgntUnqNo" value="">
85
+								<input type="hidden" id="ITP_FORM_SETTMNG03010_DETAIL_ACCT_BAL" name="acctBal" value="">
86
+								<input type="hidden" id="ITP_FORM_SETTMNG03010_DETAIL_STTL_REQ_AMT" name="sttlReqAmt" value="">
85 87
 					
86 88
 								<section class="itp_form_sec">
87 89
 									<h4 class="itp_form_tit">정산 상세정보</h4>
@@ -139,7 +141,7 @@
139 141
 											</div>
140 142
 										</div>
141 143
 										<div class="form-group">
142
-											<label class="col-xs-2 itp_lb">수납여부(수납일자)</label>
144
+											<label class="col-xs-2 itp_lb">수납완료여부(수납완료일자)</label>
143 145
 											<div class="col-xs-4 itp_ip">
144 146
 												<div class="col-xs-8 itp_in fnRcptYnDate"></div>
145 147
 											</div>

+ 14 - 1
src/main/webapp/js/app/settmng/ITP_SETTMNG03010.js

@@ -501,7 +501,18 @@ let modifyObj = {
501 501
 					fn_ajax_call(STTL_STATE_STTL_END, JSON.stringify(param), searhFn, 'POST'); 	
502 502
 				}
503 503
 			};
504
-			itp_fn_modal_confirm('정산 확정하시겠습니까?', confirmFn, null);
504
+			var sttlReqAmt =  parseInt($('#ITP_FORM_SETTMNG03010_DETAIL_STTL_REQ_AMT').val());
505
+			var acctBal =  parseInt($('#ITP_FORM_SETTMNG03010_DETAIL_ACCT_BAL').val());
506
+			
507
+			if(acctBal > 0) {
508
+				if(acctBal >= sttlReqAmt) {
509
+					itp_fn_modal_confirm('계좌잔액에서 지급처리가 진행됩니다.\n정산 확정하시겠습니까?', confirmFn, null);						
510
+				} else {
511
+					itp_fn_modal_confirm('일부금액이 계좌잔액에서 지급처리가 진행됩니다.\n정산 확정하시겠습니까?', confirmFn, null);	
512
+				}					
513
+			} else {
514
+				itp_fn_modal_confirm('정산 확정하시겠습니까?', confirmFn, null);
515
+			}
505 516
 		}
506 517
 	}, 
507 518
 	load: function(param) {
@@ -513,6 +524,8 @@ let modifyObj = {
513 524
 		$('#ITP_FORM_SETTMNG03010_DETAIL_BRAND_ID').val(result.brandId);
514 525
 		$('#ITP_FORM_SETTMNG03010_DETAIL_STORE_ID').val(result.storeId);
515 526
 		$('#ITP_FORM_SETTMNG03010_DETAIL_STTL_MGNT_UNQ_NO').val(result.sttlMgntUnqNo);
527
+		$('#ITP_FORM_SETTMNG03010_DETAIL_ACCT_BAL').val(result.acctBal); // 계좌잔액
528
+		$('#ITP_FORM_SETTMNG03010_DETAIL_STTL_REQ_AMT').val(result.sttlReqAmt); // 정산요청금액
516 529
 		
517 530
 		$('#ITP_FORM_SETTMNG03010_DETAIL .fnBrandNm').text(result.brandNm);
518 531
 		$('#ITP_FORM_SETTMNG03010_DETAIL .fnStoreNm').text(result.storeNm);