Sfoglia il codice sorgente

매장단가관리 수정

juney 2 anni fa
parent
commit
9319127425

+ 1 - 1
bin/src/main/webapp/js/app/oper/ITP_OPER01010.js

@@ -277,7 +277,7 @@ let pageObj = {
277 277
 
278 278
 					$.each(rowDataPop, function(key, value) {
279 279
 						if(exists.indexOf(value.authNo) < 0) {
280
-							value['viewCd'] =  (pageObj.grid.mode === 'MODIFY') ? 'U' : "C";
280
+							value['viewCd'] =  "C";
281 281
 							$(OPER01010_DETAIL_GRID_ID).jqGrid('addRowData', value.authNo, value, 'last');
282 282
 						}
283 283
 					});

+ 1 - 1
bin/src/main/webapp/js/app/oper/ITP_OPER02010.js

@@ -272,7 +272,7 @@ let pageObj = {
272 272
 					$.each(rowDataPop, function(key, value) {
273 273
 						// console.log(JSON.stringify(value));
274 274
 						if(exists.indexOf(value.brandId) < 0) {
275
-							value['viewCd'] =  (pageObj.grid.mode === 'MODIFY') ? 'U' : "C";
275
+							value['viewCd'] =  "C";
276 276
 							$(OPER02010_DETAIL_GRID_ID).jqGrid('addRowData', value.brandId, value, 'last');
277 277
 						}
278 278
 					});

+ 6 - 6
src/main/webapp/app/oper/OPER03010.html

@@ -100,7 +100,7 @@
100 100
 											<label class="col-xs-2 itp_lb">비번 초기화</label>
101 101
 											<div class="col-xs-10 itp_ip">
102 102
 												<div class="col-xs-3 itp_in">
103
-													<input type="text" id="ITP_FORM_OPER03010_DETAIL_BSNS_REG_NO" data-check-required="empty,number" class="form-control itp_input" name="bsnsRegNo" value="">
103
+													<input type="password" id="ITP_FORM_OPER03010_DETAIL_PSWD" class="form-control itp_input" name="pswd" value="">
104 104
 												</div>
105 105
 												<div class="col-xs-2 itp_in" style="margin-left:5px;">
106 106
 													<button type="button" id="ITP_BTN_OPER03010_RESET_PW" class="btn btn-danger btn-sm PWC" style="margin: -1px 0px 0px 3px; display:block;">비밀번호 초기화</button>
@@ -146,7 +146,7 @@
146 146
 											<label class="col-xs-2 itp_lb">전화번호 *</label>
147 147
 											<div class="col-xs-4 itp_ip">
148 148
 												<div class="col-xs-7 itp_in">
149
-													<input type="tel" id="ITP_FORM_OPER03010_DETAIL_TEL_NO" data-check-required="empty" class="form-control itp_input" name="rprstTelNo" value="">
149
+													<input type="text" id="ITP_FORM_OPER03010_DETAIL_TEL_NO" data-check-required="empty" class="form-control itp_input" name="rprstTelNo" value="">
150 150
 												</div>
151 151
 											</div>
152 152
 											<label class="col-xs-2 itp_lb" style="border-top:none;">가맹점 로고</label>
@@ -159,7 +159,7 @@
159 159
 											<label class="col-xs-2 itp_lb">FAX *</label>
160 160
 											<div class="col-xs-4 itp_ip">
161 161
 												<div class="col-xs-7 itp_in">
162
-													<input type="number" id="ITP_FORM_OPER03010_DETAIL_FAX_NO" data-check-required="empty" class="form-control itp_input" name="rprstFaxNo" value="">
162
+													<input type="text" id="ITP_FORM_OPER03010_DETAIL_FAX_NO" data-check-required="empty" class="form-control itp_input" name="rprstFaxNo" value="">
163 163
 												</div>
164 164
 											</div>
165 165
 											<label class="col-xs-2 itp_lb"style="border-top:none;"></label>
@@ -224,13 +224,13 @@
224 224
 											<label class="col-xs-2 itp_lb">주소 *</label>
225 225
 											<div class="col-xs-10 itp_ip">
226 226
 												<div class="col-xs-1 itp_in">
227
-													<input type="text" id="ITP_FORM_OPER03010_DETAIL_ZIPNO" data-check-required="empty" class="form-control itp_input" name="zipNo" value="" maxlength="6" readonly placeholder="우편번호">
227
+													<input type="text" id="ITP_FORM_OPER03010_DETAIL_ZIPNO" data-check-required="empty" data-alert-required="ONLYCHK" class="form-control itp_input" name="zipNo" value="" maxlength="6" readonly placeholder="우편번호">
228 228
 												</div>
229 229
 												<div class="col-xs-1 itp_in">
230 230
 													<button type="button" id="ITP_FORM_OPER03010_DETAIL_ADRES_SCH" class="btn btn-primary btn-sm SHOW" style="margin: -1px 0px 0px 3px;">&nbsp;&nbsp;주소검색&nbsp;&nbsp;</button>
231 231
 												</div>
232 232
 												<div class="col-xs-4 itp_in" style="margin-right: 5px; margin-left:20px;">
233
-													<input type="text" id="ITP_FORM_OPER03010_DETAIL_ADRES" data-check-required="empty" class="form-control itp_input" name="addr1" value="" readonly placeholder="기본주소">
233
+													<input type="text" id="ITP_FORM_OPER03010_DETAIL_ADRES" data-check-required="empty" data-alert-required="ONLYCHK" class="form-control itp_input" name="addr1" value="" readonly placeholder="기본주소">
234 234
 												</div>
235 235
 												<div class="col-xs-4 itp_in">
236 236
 													<input type="text" id="ITP_FORM_OPER03010_DETAIL_ADRES_DTL" data-check-required="empty" class="form-control itp_input" name="addr2" value="" placeholder="상세주소">
@@ -294,7 +294,7 @@
294 294
 											</div>
295 295
 											<label class="col-xs-2 itp_lb">가맹점 KEY *<br>사용자 계정 추가-3자리</label>
296 296
 											<div class="col-xs-4 itp_ip">
297
-												<div class="col-xs-4 itp_in fnAfflShopKey"></div>
297
+												<div class="col-xs-4 itp_in fnAfflAbbr"></div>
298 298
 											</div>
299 299
 										</div>
300 300
 										<div class="form-group">

+ 93 - 52
src/main/webapp/app/oper/OPER03011.html

@@ -2,17 +2,52 @@
2 2
 	<div class="itp_cont">
3 3
 		<article class="itp_detail">
4 4
 			<div class="itp_det_head fix">
5
-				<h2 class="pull-left itp_det_tit"><i class="glyphicon glyphicon-chevron-right"></i> <strong>가맹점정보</strong></h2>
5
+				<h2 class="pull-left itp_det_tit"><i class="glyphicon glyphicon-chevron-right"></i> <strong>가맹점관리</strong></h2>
6 6
 				<div class="pull-right itp_cicon">
7
-					<button type="button" id="ITP_BTN_OPER03011_SRH" class="btn btn-success btn-sm SEB" style="display: inline-block;"><i class="glyphicon "></i>&nbsp;&nbsp;조회&nbsp;&nbsp;</button>
8 7
 					<button type="button" id="ITP_BTN_OPER03011_MODIFY" class="btn btn-success btn-sm UPB" style="display: inline-block;"><i class="glyphicon "></i>&nbsp;&nbsp;수정&nbsp;&nbsp;</button>
9
-					<button type="button" id="ITP_BTN_OPER03011_NEWREG" class="btn btn-primary btn-sm NEB" style="display: inline-block;"><i class="glyphicon "></i>&nbsp;&nbsp;신규등록&nbsp;&nbsp;</button>
10
-					<button type="button" id="ITP_BTN_OPER03011_DELETE" class="btn btn-danger btn-sm DEB"><i class="glyphicon "></i>&nbsp;&nbsp;삭제&nbsp;&nbsp;</button>
11 8
 					<button type="button" id="ITP_BTN_OPER03011_SAVE" class="btn btn-success btn-sm SAB"><i class="glyphicon "></i>&nbsp;&nbsp;저장&nbsp;&nbsp;</button>
12
-					<button type="button" id="ITP_BTN_OPER03011_CANCELLIST" class="btn btn-warning btn-sm PRB"><i class="glyphicon "></i>&nbsp;&nbsp;취소/목록&nbsp;&nbsp;</button>
13
-				</div>				
9
+					<button type="button" id="ITP_BTN_OPER03011_CANCELLIST" class="btn btn-warning btn-sm PRB"><i class="glyphicon "></i>&nbsp;&nbsp;취소&nbsp;&nbsp;</button>
10
+				</div>
14 11
 			</div>
15 12
 			<div class="itp_det_in">
13
+				<div id="ITP_AJAX_OPER03011_LIST_CONTAINER">
14
+					<div class="itp_lg_form itp_type1 fix">
15
+						<div class="itp_srh_border fix">
16
+							<div class="col-xs-12">
17
+								<form id="ITP_FORM_OPER03011_SEARCH" class="form-horizontal">
18
+									<div class="form-group">
19
+										<div class="col-xs-2 itp_ip itp_noMar">
20
+											<select id="ITP_FORM_OPER03011_SERVICE_" class="form-control itp_input" name="">
21
+												<option value="">가입일자</option>
22
+											</select>
23
+										</div>
24
+										<div class="col-xs-3 itp_ip itp_noMar">
25
+											<div class="input-daterange input-group date">
26
+												<input type="text" id="ITP_FORM_OPER03011_SEARCH_FROM_DT" class="form-control itp_input" name="fromDt" value="" readonly>
27
+												<span class="input-group-addon itp_date_to">~</span>
28
+												<input type="text" id="ITP_FORM_OPER03011_SEARCH_TO_DT" class="form-control itp_input" name="toDt" value="" readonly>
29
+											</div>
30
+										</div>
31
+										<div class="col-xs-4 itp_ip itp_noMar">
32
+											<input type="text" id="ITP_FORM_OPER03011_SEARCH_AFFL_SHOP_NM" class="form-control itp_input" name="safflShopNm" placeholder="가맹점 명" />
33
+										</div>
34
+										<div class="col-xs-2 itp_ip itp_noMar">
35
+											<select id="ITP_FORM_OPER03011_SEARCH_ST_CD" data-select-code="ST_CD" class="form-control itp_input" name="sstCd"></select>
36
+										</div>
37
+									</div>
38
+								</form>
39
+							</div>
40
+						</div>
41
+					</div>
42
+					<div class="itp_table fix">
43
+						<div id="ITP_OPER03011_jqGrid_list" class="itp_tb_list itp_gType1" data-total-cnt="${totalCnt}">
44
+							<div id="ITP_OPER03011_jqGridView" class="itp_views fix"></div>
45
+							<table id="ITP_OPER03011_jqGrid"></table>
46
+							<div id="ITP_OPER03011_jqGridPager"></div>
47
+							<div id="ITP_OPER03011_jqGridEmpty" class="itp_no_data"></div>
48
+						</div>
49
+					</div>
50
+				</div>
16 51
 				<div id="ITP_AJAX_OPER03011_DETAIL_CONTAINER">
17 52
 					<div class="itp_form itp_type1 fix">
18 53
 						<div class="col-xs-12">
@@ -21,7 +56,7 @@
21 56
 								<input type="hidden" id="ITP_FORM_OPER03011_DETAIL_AFFL_SHOP_ID" class="form-control itp_input" name="afflShopId">
22 57
 								<input type="hidden" id="ITP_FORM_OPER03011_DETAIL_CMPY_LOCATION" name="cmpyLocation" value="">
23 58
 								<input type="hidden" id="ITP_FORM_OPER03011_DETAIL_FILE_NO" name="fileNo" value="">
24
-					
59
+
25 60
 								<section class="itp_form_sec">
26 61
 									<h4 class="itp_form_tit">가맹점정보</h4>
27 62
 									<div class="itp_form_in">
@@ -33,7 +68,7 @@
33 68
 											<label class="col-xs-2 itp_lb">상태(*)</label>
34 69
 											<div class="col-xs-4 itp_ip">
35 70
 												<div class="col-xs-6 itp_in">
36
-													<select id="ITP_FORM_OPER03011_DETAIL_ST_CD" data-select-code="ST_CD" class="form-control itp_input" name="stCd"></select>
71
+													<select id="ITP_FORM_OPER03011_DETAIL_ST_CD" data-select-code="ST_CD" data-check-required="empty" class="form-control itp_input" name="stCd"></select>
37 72
 												</div>
38 73
 											</div>
39 74
 										</div>
@@ -41,14 +76,14 @@
41 76
 											<label class="col-xs-2 itp_lb">가맹점 명 *</label>
42 77
 											<div class="col-xs-4 itp_ip">
43 78
 												<div class="col-xs-7 itp_in">
44
-													<input type="text" id="ITP_FORM_OPER03011_DETAIL_AFFL_SHOP_NM" class="form-control itp_input" name="afflShopNm" value="">
79
+													<input type="text" id="ITP_FORM_OPER03011_DETAIL_AFFL_SHOP_NM" data-check-required="empty" class="form-control itp_input" name="afflShopNm" value="">
45 80
 												</div>
46 81
 											</div>
47 82
 											<label class="col-xs-2 itp_lb">가맹점 KEY *<br>사용자 계정 추가-3자리</label>
48 83
 											<div class="col-xs-4 itp_ip">
49 84
 												<div class="col-xs-4 itp_in">
50 85
 													<div class="input-group">
51
-														<input type="text" id="ITP_FORM_OPER03011_DETAIL_AFFL_SHOP_KEY" class="form-control itp_input" name="afflAbbr" value="" maxlength="3" readonly>
86
+														<input type="text" id="ITP_FORM_OPER03011_DETAIL_AFFL_SHOP_KEY" data-check-required="empty" class="form-control itp_input" name="afflAbbr" value="" maxlength="3" readonly>
52 87
 														<span class="input-group-btn">
53 88
 															<button id="ITP_BTN_OPER03011_DETAIL_AFFL_SHOP_KEY" class="btn btn-default btn-sm itp_btn SHOW" type="button" disabled><i class="glyphicon glyphicon-ok"></i></button>
54 89
 														</span>
@@ -56,20 +91,29 @@
56 91
 												</div>
57 92
 											</div>
58 93
 										</div>
59
-										<!--<div class="form-group">
60
-											<label class="col-xs-2 itp_lb">비밀번호</label>
61
-											<div class="col-xs-4 itp_ip">
62
-												<div class="col-xs-7 itp_in">
94
+									</div>
95
+									<div class="itp_form_in">
96
+										<div class="form-group">
97
+											<label class="col-xs-2 itp_lb">비번 초기화</label>
98
+											<div class="col-xs-10 itp_ip">
99
+												<div class="col-xs-3 itp_in">
63 100
 													<input type="password" id="ITP_FORM_OPER03011_DETAIL_PSWD" class="form-control itp_input" name="pswd" value="">
64 101
 												</div>
65
-												<button type="button" id="ITP_BTN_OPER01010_DETAIL_RESET_PW" class="btn btn-danger btn-sm PWC" style="margin: -1px 0px 0px 3px;">비밀번호 초기화</button>
102
+												<div class="col-xs-2 itp_in" style="margin-left:5px;">
103
+													<button type="button" id="ITP_BTN_OPER03011_RESET_PW" class="btn btn-danger btn-sm SHOW" style="margin: -1px 0px 0px 3px; display:block;">비밀번호 초기화</button>
104
+												</div>
105
+												<div class="col-xs-5 itp_in" style="margin-top:5px;">
106
+													<div>(가맹점 사업자등록번호로 초기화 함 (숫자만))</div>
107
+												</div>
66 108
 											</div>
67
-										</div>-->
109
+										</div>
110
+									</div>
111
+									<div class="itp_form_in">
68 112
 										<div class="form-group">
69 113
 											<label class="col-xs-2 itp_lb">사업자번호 *</label>
70 114
 											<div class="col-xs-4 itp_ip">
71
-												<div class="col-xs-6 itp_in">
72
-													<input type="text" id="ITP_FORM_OPER03011_DETAIL_BSNS_REG_NO" class="form-control itp_input" name="bsnsRegNo" value="">
115
+												<div class="col-xs-7 itp_in">
116
+													<input type="text" id="ITP_FORM_OPER03011_DETAIL_BSNS_REG_NO" data-check-required="empty,number" class="form-control itp_input" name="bsnsRegNo" value="">
73 117
 												</div>
74 118
 											</div>
75 119
 											<label class="col-xs-2 itp_lb">법인번호</label>
@@ -77,6 +121,9 @@
77 121
 												<div class="col-xs-6 itp_in">
78 122
 													<input type="text" id="ITP_FORM_OPER03011_DETAIL_CORP_REG_NO" class="form-control itp_input" name="corpRegNo" value="">
79 123
 												</div>
124
+												<div class="col-xs-3 itp_in">
125
+
126
+												</div>
80 127
 											</div>
81 128
 										</div>
82 129
 										<div class="form-group">
@@ -89,38 +136,32 @@
89 136
 											</div>
90 137
 											<label class="col-xs-2 itp_lb"></label>
91 138
 											<div class="col-xs-4 itp_in">
92
-												<img src="/oqpo-view/images/naver.png" alt="로고 샘플" id="ITP_FORM_OPER03011_DETAIL_ "style="border:none; top:12px; left:12px; height:100px; width:125px; position:absolute;" class="form-control itp_input" name="" >
139
+												<img src="/oqpo-view/images/naver.png" alt="로고 샘플" id="ITP_FORM_OPER03011_DETAIL_ "style="border:none; top:12px; left:12px; height:70px; width:85px; position:absolute;" class="form-control itp_input" name="" >
93 140
 											</div>
94 141
 										</div>
95 142
 										<div class="form-group">
96 143
 											<label class="col-xs-2 itp_lb">전화번호 *</label>
97 144
 											<div class="col-xs-4 itp_ip">
98 145
 												<div class="col-xs-7 itp_in">
99
-													<input type="text" id="ITP_FORM_OPER03011_DETAIL_TEL_NO" class="form-control itp_input" name="rprstTelNo" value="">
146
+													<input type="tel" id="ITP_FORM_OPER03011_DETAIL_TEL_NO" data-check-required="empty" class="form-control itp_input" name="rprstTelNo" value="">
100 147
 												</div>
101 148
 											</div>
102 149
 											<label class="col-xs-2 itp_lb" style="border-top:none;">가맹점 로고</label>
103 150
 											<div class="col-xs-4 itp_ip"style="border-top:none;">
104 151
 												<div class="col-xs-5 itp_in">
105 152
 												</div>
106
-												<div class="col-xs-7 itp_in">
107
-													<input type="text" id="ITP_FORM_OPER03011_DETAIL_FILE_PATH" class="form-control itp_input" name="filePath" value="">
108
-												</div>
109 153
 											</div>
110 154
 										</div>
111 155
 										<div class="form-group">
112 156
 											<label class="col-xs-2 itp_lb">FAX *</label>
113 157
 											<div class="col-xs-4 itp_ip">
114 158
 												<div class="col-xs-7 itp_in">
115
-													<input type="text" id="ITP_FORM_OPER03011_DETAIL_FAX_NO" class="form-control itp_input" name="rprstFaxNo" value="">
159
+													<input type="text" id="ITP_FORM_OPER03011_DETAIL_FAX_NO" data-check-required="empty" class="form-control itp_input" name="rprstFaxNo" value="">
116 160
 												</div>
117 161
 											</div>
118 162
 											<label class="col-xs-2 itp_lb"style="border-top:none;"></label>
119 163
 											<div class="col-xs-4 itp_ip"style="border-top:none;">
120
-												<div class="col-xs-7 itp_in">
121
-													<label class="col-xs-12"></label>
122
-												</div>
123
-												<div class="col-xs-5 itp_in">
164
+												<div class="col-xs-12 itp_in colspan">
124 165
 													<div class="fileupload-wrapper">
125 166
 														<!-- data-show-yn: 파일업로드를 할 수 있는 권한이 있는지 없는지.. -->
126 167
 														<div id="ITP_OPER03011_DETAIL_UPLOAD" data-show-yn="Y"></div>
@@ -132,7 +173,7 @@
132 173
 											<label class="col-xs-2 itp_lb">이메일 *</label>
133 174
 											<div class="col-xs-4 itp_ip">
134 175
 												<div class="col-xs-7 itp_in">
135
-													<input type="text" id="ITP_FORM_OPER03011_DETAIL_EMAL_ADDR" class="form-control itp_input" name="rprstEmai" value="">
176
+													<input type="text" id="ITP_FORM_OPER03011_DETAIL_EMAL_ADDR" data-check-required="empty" class="form-control itp_input" name="rprstEmai" value="">
136 177
 												</div>
137 178
 											</div>
138 179
 											<label class="col-xs-2 itp_lb">업태</label>
@@ -146,7 +187,7 @@
146 187
 											<label class="col-xs-2 itp_lb">대표자명 *</label>
147 188
 											<div class="col-xs-4 itp_ip">
148 189
 												<div class="col-xs-7 itp_in">
149
-													<input type="text" id="ITP_FORM_OPER03011_DETAIL_OWNER_NM" class="form-control itp_input" name="ownerNm" value="">
190
+													<input type="text" id="ITP_FORM_OPER03011_DETAIL_OWNER_NM" data-check-required="empty" class="form-control itp_input" name="ownerNm" value="">
150 191
 												</div>
151 192
 											</div>
152 193
 											<label class="col-xs-2 itp_lb">업종</label>
@@ -160,19 +201,19 @@
160 201
 											<label class="col-xs-2 itp_lb">대표자연락처 *</label>
161 202
 											<div class="col-xs-4 itp_ip">
162 203
 												<div class="col-xs-7 itp_in">
163
-													<input type="text" id="ITP_FORM_OPER03011_DETAIL_OWNER_TEL_NO" class="form-control itp_input" name="ownerTelNo" value="">
204
+													<input type="text" id="ITP_FORM_OPER03011_DETAIL_OWNER_TEL_NO" data-check-required="empty" class="form-control itp_input" name="ownerTelNo" value="">
164 205
 												</div>
165 206
 											</div>
166 207
 											<label class="col-xs-2 itp_lb">계약기간 *</label>
167 208
 											<div class="col-xs-4 itp_ip">
168 209
 												<div class="col-xs-10 itp_in">
169 210
 													<div class="input-daterange input-group date">
170
-														<input type="text" id="ITP_FORM_OPER03011_SEARCH_JOIN_STT_DT" class="form-control itp_input" name="joinSttDt" value="" readonly>
211
+														<input type="text" id="ITP_FORM_OPER03011_SEARCH_JOIN_STT_DT" data-check-required="empty" class="form-control itp_input" name="joinSttDt" value="" readonly>
171 212
 														<span class="input-group-addon itp_date_to">~</span>
172
-														<input type="text" id="ITP_FORM_OPER03011_SEARCH_JOIN_END_DT" class="form-control itp_input" name="joinEndDt" value="" readonly>
173
-													</div>												
213
+														<input type="text" id="ITP_FORM_OPER03011_SEARCH_JOIN_END_DT" data-check-required="empty" class="form-control itp_input" name="joinEndDt" value="" readonly>
214
+													</div>
174 215
 												</div>
175
-											</div>											
216
+											</div>
176 217
 										</div>
177 218
 									</div>
178 219
 									<div class="itp_form_in">
@@ -180,39 +221,39 @@
180 221
 											<label class="col-xs-2 itp_lb">주소 *</label>
181 222
 											<div class="col-xs-10 itp_ip">
182 223
 												<div class="col-xs-1 itp_in">
183
-													<input type="text" id="ITP_FORM_OPER03011_DETAIL_ZIPNO" class="form-control itp_input" name="zipNo" value="" maxlength="6" readonly placeholder="우편번호">													
224
+													<input type="text" id="ITP_FORM_OPER03011_DETAIL_ZIPNO" data-check-required="empty" data-alert-required="ONLYCHK" class="form-control itp_input" name="zipNo" value="" maxlength="6" readonly placeholder="우편번호">
184 225
 												</div>
185 226
 												<div class="col-xs-1 itp_in">
186 227
 													<button type="button" id="ITP_FORM_OPER03011_DETAIL_ADRES_SCH" class="btn btn-primary btn-sm SHOW" style="margin: -1px 0px 0px 3px;">&nbsp;&nbsp;주소검색&nbsp;&nbsp;</button>
187 228
 												</div>
188 229
 												<div class="col-xs-4 itp_in" style="margin-right: 5px; margin-left:20px;">
189
-													<input type="text" id="ITP_FORM_OPER03011_DETAIL_ADRES" class="form-control itp_input" name="loadAddr" value="" readonly placeholder="기본주소">
230
+													<input type="text" id="ITP_FORM_OPER03011_DETAIL_ADRES" data-check-required="empty" data-alert-required="ONLYCHK" class="form-control itp_input" name="addr1" value="" readonly placeholder="기본주소">
190 231
 												</div>
191 232
 												<div class="col-xs-4 itp_in">
192
-													<input type="text" id="ITP_FORM_OPER03011_DETAIL_ADRES_DTL" class="form-control itp_input" name="dtlAddr" value="" placeholder="상세주소">
233
+													<input type="text" id="ITP_FORM_OPER03011_DETAIL_ADRES_DTL" data-check-required="empty" class="form-control itp_input" name="addr2" value="" placeholder="상세주소">
193 234
 												</div>
194
-												
235
+
195 236
 												<!-- 주소 맵 -->
196 237
 												<input type="hidden" id="ITP_FORM_OPER03011_DETAIL_LOTS_ADDRESS" value="" />
197 238
 												<input type="hidden" id="ITP_FORM_OPER03011_DETAIL_STREET_ADDRESS" value="" />
198
-												<input type="hidden" name="cmpyLat" id="ITP_FORM_OPER03011_DETAIL_LAT" value="" />
199
-												<input type="hidden" name="cmpyLng" id="ITP_FORM_OPER03011_DETAIL_LNG" value="" />
239
+												<input type="hidden" name="latX" id="ITP_FORM_OPER03011_DETAIL_LAT" value="" />
240
+												<input type="hidden" name="latY" id="ITP_FORM_OPER03011_DETAIL_LNG" value="" />
200 241
 												<input type="hidden" id="ITP_FORM_OPER03011_DETAIL_HJ_DONG" value="" />
201 242
 												<input type="hidden" id="ITP_FORM_OPER03011_DETAIL_BJ_DONG" value="" />
202
-												<div id="ITP_FORM_OPER03011_DETAIL_MAP" style="width:700px; height:400px;"></div>
243
+												<div id="ITP_FORM_OPER03011_DETAIL_MAP" style="margin-top:30px; width:700px; height:400px;"></div>
203 244
 											</div>
204 245
 										</div>
205 246
 									</div>
206
-								</section>								
247
+								</section>
207 248
 							</form>
208 249
 						</div>
209
-					</div>	
250
+					</div>
210 251
 					<div class="itp_table fix">
211 252
 						<div class="itp_table_head fix">
212 253
 							<h4 class="itp_table_tit">* 영업담당자정보</h4>
213 254
 							<div class="pull-right itp_cicon">
214 255
 								<button type="button" id="ITP_BTN_OPER03011_DETAIL_ADDROW" class="btn btn-primary btn-sm ARB" style="display: inline-block;"><i class="glyphicon"></i>&nbsp;&nbsp;추가&nbsp;&nbsp;</button>
215
-								<button type="button" id="ITP_BTN_OPER03011_DETAIL_DELROW" class="btn btn-danger btn-sm DRB"><i class="glyphicon"></i>&nbsp;&nbsp;삭제&nbsp;&nbsp;</button>									
256
+								<button type="button" id="ITP_BTN_OPER03011_DETAIL_DELROW" class="btn btn-danger btn-sm DRB"><i class="glyphicon"></i>&nbsp;&nbsp;삭제&nbsp;&nbsp;</button>
216 257
 							</div>
217 258
 						</div>
218 259
 						<div id="ITP_OPER03011_DETAIL_jqGrid_list" class="itp_tb_list">
@@ -221,7 +262,7 @@
221 262
 							<div id="ITP_OPER03011_DETAIL_jqGridPager"></div>
222 263
 							<div id="ITP_OPER03011_DETAIL_jqGridEmpty" class="itp_no_data"></div>
223 264
 						</div>
224
-					</div>				
265
+					</div>
225 266
 				</div>
226 267
 				<div id="ITP_AJAX_OPER03011_VIEW_CONTAINER">
227 268
 					<div class="itp_form itp_type1 fix">
@@ -229,7 +270,7 @@
229 270
 							<form id="ITP_FORM_OPER03011_VIEW" class="form-horizontal">
230 271
 								<input type="hidden" id="ITP_FORM_OPER03011_VIEW_VIEW_CD" name="viewCd" value="R">
231 272
 								<input type="hidden" id="ITP_FORM_OPER03011_VIEW_AFFL_SHOP_ID" name="afflShopId" value="">
232
-					
273
+
233 274
 								<section class="itp_form_sec">
234 275
 									<h4 class="itp_form_tit">가맹점정보</h4>
235 276
 									<div class="itp_form_in">
@@ -250,7 +291,7 @@
250 291
 											</div>
251 292
 											<label class="col-xs-2 itp_lb">가맹점 KEY *<br>사용자 계정 추가-3자리</label>
252 293
 											<div class="col-xs-4 itp_ip">
253
-												<div class="col-xs-4 itp_in fnAfflShopkey"></div>
294
+												<div class="col-xs-4 itp_in fnAfflAbbr"></div>
254 295
 											</div>
255 296
 										</div>
256 297
 										<div class="form-group">
@@ -326,9 +367,9 @@
326 367
 												<div class="col-xs-2 itp_in fnJoinSttDt"></div>
327 368
 												<div class="col-xs-1">~</div>
328 369
 												<div class="col-xs-2 itp_in fnJoinEndDt"></div>
329
-											</div>											
370
+											</div>
330 371
 										</div>
331
-									</div>									
372
+									</div>
332 373
 									<div class="itp_form_in">
333 374
 										<div class="form-group">
334 375
 											<label class="col-xs-2 itp_lb">주소 *</label>
@@ -344,7 +385,7 @@
344 385
 											</div>
345 386
 										</div>
346 387
 									</div>
347
-								</section>								
388
+								</section>
348 389
 							</form>
349 390
 						</div>
350 391
 					</div>
@@ -360,5 +401,5 @@
360 401
 			</div>
361 402
 		</article>
362 403
 	</div>
363
-	<div id="ITP_TAP_JS"></div>	
404
+	<div id="ITP_TAP_JS"></div>
364 405
 </section>

+ 45 - 0
src/main/webapp/app/popup/biz/BIZPOP_BRAND_STORE.html

@@ -0,0 +1,45 @@
1
+<div id="ITP_BIZPOP_BRAND_STORE" class="modal itp_modal">
2
+	<div class="modal-dialog">
3
+		<div class="modal-content">
4
+			<form id="ITP_FORM_BIZPOP_BRAND_STORE">
5
+				<input type="hidden" name="brandId" id="ITP_FORM_BIZPOP_BRAND_ID" />
6
+				<div class="modal-header">
7
+					<button type="button" class="close" data-dismiss="modal" aria-hidden="true">&times;</button>
8
+					<h5 class="modal-title">가맹점 검색</h5>
9
+				</div>
10
+				<div class="modal-body">
11
+					<div class="itp_form fix">
12
+						<div class="col-xs-12 itp_form_inline">
13
+							<div class="form-horizontal fix">
14
+								<div class="col-xs-9 itp_ip itp_pr">
15
+									<input type="text" name="afflShopNm" id="ITP_FORM_BIZPOP_BRAND_STORE_NM" class="form-control itp_input" placeholder="매장명">
16
+								</div>
17
+								<!--<div class="col-xs-4 itp_ip itp_noMar">
18
+									<select id="ITP_FORM_BIZPOP_BRAND_STORE_CMPY_TYPE_CD" class="form-control itp_input" name="scmpyTypeCd"></select>
19
+								</div>-->
20
+								<div class="pull-right itp_cicon">
21
+									<button type="button" class="btn btn-success btn-sm" id="ITP_BIZPOP_BRAND_STORE_BTN_SEARCH" style="display: inline-block;"><i class="glyphicon glyphicon-search"></i> 조회</button>
22
+									<button type="button" class="btn btn-primary btn-sm" id="ITP_BIZPOP_BRAND_STORE_BTN_SELECT"><i class="glyphicon glyphicon-ok"></i> 선택</button>
23
+								</div>
24
+							</div>
25
+						</div>
26
+					</div>
27
+					<!--<div class="itp_form fix">
28
+						<div class="pull-right itp_cicon">
29
+							<button type="button" class="btn btn-success btn-sm" id="ITP_BIZPOP_BRAND_STORE_BTN_SEARCH" style="display: inline-block;"><i class="glyphicon glyphicon-search"></i> 조회</button>
30
+							<button type="button" class="btn btn-primary btn-sm" id="ITP_BIZPOP_BRAND_STORE_BTN_SELECT"><i class="glyphicon glyphicon-ok"></i> 선택</button>
31
+						</div>
32
+					</div>-->
33
+					<div id="ITP_BIZPOP_BRAND_STORE_jqGrid_list" class="itp_tb_list" data-total-cnt="">
34
+						<div id="ITP_BIZPOP_BRAND_STORE_jqGridView" class="itp_views fix"></div>
35
+						<table id="ITP_BIZPOP_BRAND_STORE_jqGrid"></table>
36
+						<div id="ITP_BIZPOP_BRAND_STORE_jqGridPager"></div>
37
+						<div id="ITP_BIZPOP_BRAND_STORE_jqGridEmpty" class="itp_no_data"></div>
38
+					</div>
39
+				</div>
40
+			</form>
41
+		</div>
42
+	</div>
43
+
44
+	<div id="ITP_POPUP_JS"></div>
45
+</div>

+ 14 - 12
src/main/webapp/app/stinfo/STINFO06010.html

@@ -44,25 +44,27 @@
44 44
 				       <div class="itp_srh_border fix">
45 45
 				          <div class="col-xs-12">
46 46
 				          <form id="ITP_FORM_STINFO06010_DETAIL" class="form-horizontal">
47
-							  <input type="hidden" id="ITP_FORM_STINFO06010_DETAIL_AFFL_SHOP_ID" name="afflShopId" value="">
48 47
 							  <input type="hidden" id="ITP_FORM_STINFO06010_DETAIL_BRAND_ID" name="brandId" value="">
49 48
 							  <input type="hidden" id="ITP_FORM_STINFO06010_DETAIL_STORE_ID" name="storeId" value="">
49
+							  <input type="hidden" id="ITP_FORM_STINFO06010_DETAIL_VIEW_CD" name="viewCd" value="R">
50 50
 				             <div class="form-group">
51 51
 				                <div class="col-xs-3 itp_ip itp_noMar">
52
-				                	<input type="text" id="ITP_FORM_STINFO06010_DETAIL_STORE_NM" class="form-control itp_input" name="sstoreNm" placeholder="매장명" />
52
+				                	<input type="text" id="ITP_FORM_STINFO06010_DETAIL_STORE_NM" data-check-required="empty" class="form-control itp_input" name="storeNm" placeholder="매장명" disabled />
53 53
 				                </div>
54 54
 				                <div class="col-xs-2 itp_ip itp_noMar" style="width:10%;">
55
-									<button type="button" id="ITP_BTN_STINFO06010_DETAIL_SRH" class="btn btn-success btn-sm SEB" style="display: inline-block;"><i class="glyphicon glyphicon-search"></i></button>
56
-									<button type="button" id="ITP_BTN_STINFO06010_DETAIL_MODIFY" class="btn btn-primary btn-sm UPB" style="display: inline-block;"><i class="glyphicon glyphicon-erase"></i></button>
57
-				                </div>
58
-				                <label class="col-xs-1 itp_ip itp_noMar" style="top:6px;">계약기간</label>
59
-				                <div class="col-xs-3 itp_ip itp_noMar">
60
-									<div class="input-daterange input-group date">
61
-									   <input type="text" id="ITP_FORM_STINFO06010_DETAIL_FROM_DT" class="form-control itp_input" name="fromDt" value="" readonly>
62
-									   <span class="input-group-addon itp_date_to">~</span>
63
-									   <input type="text" id="ITP_FORM_STINFO06010_DETAIL_TO_DT" class="form-control itp_input" name="toDt" value="" readonly>
64
-									</div>
55
+									<button type="button" id="ITP_BTN_STINFO06010_DETAIL_SEARCH_STORE" class="btn btn-success btn-sm SHOW" style="display: inline-block;"><i class="glyphicon glyphicon-search"></i></button>
56
+									<button type="button" id="ITP_BTN_STINFO06010_DETAIL_DELETE_STORE" class="btn btn-primary btn-sm SHOW" style="display: inline-block;"><i class="glyphicon glyphicon-erase"></i></button>
65 57
 				                </div>
58
+								 <div class="contDt">
59
+									 <label class="col-xs-1 itp_ip itp_noMar" style="top:6px;">계약기간</label>
60
+									 <div class="col-xs-3 itp_ip itp_noMar">
61
+										 <div class="input-daterange input-group date">
62
+											 <input type="text" id="ITP_FORM_STINFO06010_DETAIL_FROM_DT" data-check-required="empty" class="form-control itp_input" name="contSttDt" value="" readonly>
63
+											 <span class="input-group-addon itp_date_to">~</span>
64
+											 <input type="text" id="ITP_FORM_STINFO06010_DETAIL_TO_DT" data-check-required="empty" class="form-control itp_input" name="contEndDt" value="" readonly>
65
+										 </div>
66
+									 </div>
67
+								 </div>
66 68
 				             </div>
67 69
 				          </form>
68 70
 				          </div>

+ 18 - 0
src/main/webapp/js/app/config.js

@@ -2965,4 +2965,22 @@ var itp_fn_set_timeout = {
2965 2965
 			}
2966 2966
 		});
2967 2967
 	}
2968
+};
2969
+
2970
+var itp_fn_is_valid = (formId) => {
2971
+	var isValid = false;
2972
+	$(formId).find('input, select, checkbox, textarea').each(function(k) {
2973
+		if($(this).data('check-required')) {
2974
+			var arry = $(this).data('check-required').split(',');
2975
+			var alertMsg = $(this).data('alert-required');
2976
+			isValid = itp_fn_form_validate(formId, '#' + $(this).attr('id'), arry, undefined, alertMsg);
2977
+			if(!isValid) {
2978
+				if(alertMsg && alertMsg.length > 0) {
2979
+					itp_fn_modal_alert($(this).data('alert-msg'));
2980
+				}
2981
+				return false;
2982
+			}
2983
+		}
2984
+	});
2985
+	return isValid;
2968 2986
 };

+ 2 - 1
src/main/webapp/js/app/locales/locale-ko.js

@@ -283,7 +283,8 @@ const ITP_MSG_LOCALE = (function() {
283 283
 				"excpReply": "답변 제외로 처리됩니다.",
284 284
 				"regReply": "답변을 등록 할까요?",
285 285
 				"needReple": "답변 내용을 입력해주세요.",
286
-				"excelWarn": "엑셀이 다 받아질 때까지 기다려 주세요."
286
+				"excelWarn": "엑셀이 다 받아질 때까지 기다려 주세요.",
287
+				"emptyAddr": "주소 검색을 통해 회사 주소를 입력하세요."
287 288
 			},
288 289
 			"grid": {
289 290
 				"noData": "등록된 게시물이 없습니다.",

+ 1 - 1
src/main/webapp/js/app/oper/ITP_OPER01010.js

@@ -277,7 +277,7 @@ let pageObj = {
277 277
 
278 278
 					$.each(rowDataPop, function(key, value) {
279 279
 						if(exists.indexOf(value.authNo) < 0) {
280
-							value['viewCd'] =  (pageObj.grid.mode === 'MODIFY') ? 'U' : "C";
280
+							value['viewCd'] =  "C";
281 281
 							$(OPER01010_DETAIL_GRID_ID).jqGrid('addRowData', value.authNo, value, 'last');
282 282
 						}
283 283
 					});

+ 1 - 1
src/main/webapp/js/app/oper/ITP_OPER02010.js

@@ -272,7 +272,7 @@ let pageObj = {
272 272
 					$.each(rowDataPop, function(key, value) {
273 273
 						// console.log(JSON.stringify(value));
274 274
 						if(exists.indexOf(value.brandId) < 0) {
275
-							value['viewCd'] =  (pageObj.grid.mode === 'MODIFY') ? 'U' : "C";
275
+							value['viewCd'] =  "C";
276 276
 							$(OPER02010_DETAIL_GRID_ID).jqGrid('addRowData', value.brandId, value, 'last');
277 277
 						}
278 278
 					});

+ 3 - 3
src/main/webapp/js/app/oper/ITP_OPER03010.js

@@ -288,11 +288,11 @@ let pageObj = {
288 288
 
289 289
 					$.each(rowDataPop, function(key, value) {
290 290
 						if(exists.indexOf(value.saleMgrId) < 0) {
291
-							value['viewCd'] =  (pageObj.grid.mode === 'MODIFY') ? 'U' : "C";
291
+							value['viewCd'] =  "C";
292 292
 							$(OPER03010_DETAIL_GRID_ID).jqGrid('addRowData', value.saleMgrId, value, 'last');
293 293
 						}
294 294
 					});
295
-					$(this.mode === 'VIEW' ? OPER03010_VIEW_GRID_EMPTY : OPER03010_DETAIL_GRID_EMPTY).hide();
295
+					$(OPER03010_DETAIL_GRID_EMPTY).hide();
296 296
 				};
297 297
 				fn_call_popup('biz', 'BIZPOP_APPL_SALES_USER_SCH', '#ITP_ASIDE', popFn, null, 'S');
298 298
 			},
@@ -455,7 +455,7 @@ let viewObj = {
455 455
 
456 456
 		$('#ITP_FORM_OPER03010_VIEW .fnAfflShopId').text(result.afflShopId);
457 457
 		$('#ITP_FORM_OPER03010_VIEW .fnAfflShopNm').text(result.afflShopNm);
458
-		$('#ITP_FORM_OPER03010_VIEW .fnAfflShopKey').text(result.afflAbbr);
458
+		$('#ITP_FORM_OPER03010_VIEW .fnAfflAbbr').text(result.afflAbbr);
459 459
 		$('#ITP_FORM_OPER03010_VIEW .fnStCd').text(result.stNm);
460 460
 		$('#ITP_FORM_OPER03010_VIEW .fnCorpTypeNm').text(result.authTypeNm);
461 461
 		$('#ITP_FORM_OPER03010_VIEW .fnBsnsRegNo').text(result.bsnsRegNo);

+ 82 - 170
src/main/webapp/js/app/oper/ITP_OPER03011.js

@@ -13,11 +13,18 @@ require(['config'], function() {
13 13
  --------------------------------------------------------
14 14
  * const gridColModel = {}	: 화면 Grid Object			*
15 15
  * let pageObj = {}			: 화면공통 Object			*
16
+ * let listObj = {}			: 목록화면 Object			*
16 17
  * let viewObj = {}			: 상세화면 Object			*
17 18
  * let modifyObj = {}		: 수정화면 Object			*
19
+ * let createObj = {}		: 신규화면 Object			*
18 20
  *******************************************************/
19 21
 
20 22
 /*화면 변수*/
23
+const OPER03011_GRID_ID = '#ITP_OPER03011_jqGrid';
24
+const OPER03011_GRID_LIST = '#ITP_OPER03011_jqGrid_list';
25
+const OPER03011_GRID_PAGER = '#ITP_OPER03011_jqGridPager';
26
+const OPER03011_GRID_EMPTY = '#ITP_OPER03011_jqGridEmpty';
27
+
21 28
 const OPER03011_VIEW_GRID_ID = '#ITP_OPER03011_VIEW_jqGrid';
22 29
 const OPER03011_VIEW_GRID_LIST = '#ITP_OPER03011_VIEW_jqGrid_list';
23 30
 const OPER03011_VIEW_GRID_PAGER = '#ITP_OPER03011_VIEW_jqGridPager';
@@ -32,7 +39,9 @@ let ITP_FORM_OPER03011_DETAIL_IS_DUPLICATE = false;
32 39
 let ITP_FORM_OPER03011_DETAIL_IS_WRITING = false;
33 40
 
34 41
 /*API URL*/
42
+let API_DETAIL_GRID_LIST = '/api/affl/detail-grid-list';
35 43
 let API_DETAIL_INFO = '/api/affl/info-affl';
44
+let COMPANY_INFO_COMPANY = '/api/affl/info-affl';
36 45
 let API_DETAIL_SAVE = '/api/affl/save-affi';
37 46
 let API_CHECK_DUPLICATE = '/api/affl/check-duplicate';
38 47
 let API_INTI_USERPW = '/api/user/inti-userpw';
@@ -40,6 +49,12 @@ let API_INTI_USERPW = '/api/user/inti-userpw';
40 49
 /*화면 Grid ColModel*/
41 50
 const gridColModel = {
42 51
 	detail: [
52
+		{
53
+			index: 'VIEW_CD', name: 'viewCd',
54
+			label: ITP_MSG_LOCALE.label.viewCd,
55
+			width: '10', fixed: false, align: 'center',
56
+			sortable: false, hidden: true
57
+		},
43 58
 		{
44 59
 			index: 'SALE_MGR_ID', name: 'saleMgrId',
45 60
 			label: '영업담당자ID',
@@ -92,12 +107,14 @@ let pageObj = {
92 107
 	init: function () {
93 108
 		this.ui.init();
94 109
 		this.event.init();
110
+		this.fileUpload();
95 111
 	},
96 112
 	itp_OPER03011_param: {},
97 113
 	itp_OPER03011_search: false,
98 114
 	ui: {
99 115
 		init: function () {
100 116
 			this.view();
117
+			this.grid();
101 118
 			this.ready();
102 119
 		},
103 120
 		view: function() {
@@ -110,6 +127,11 @@ let pageObj = {
110 127
 					fn_make_select(CODE_LIST, $(this).data('select-code'), $(this).attr('id'));
111 128
 				}
112 129
 			});
130
+
131
+			// 조회일자 지정
132
+			$('#ITP_TAB_OPER03011 .input-group.date').datepicker(ITP_DATE_LANGUAGE);
133
+		},
134
+		grid: function() {
113 135
 		},
114 136
 		ready: function() {
115 137
 			viewObj.init();
@@ -128,6 +150,7 @@ let pageObj = {
128 150
 						case 'ITP_BTN_OPER03011_MODIFY'					: modifyObj.button.modify();	break;	// 수정 버튼
129 151
 						case 'ITP_BTN_OPER03011_CANCELLIST'				: modifyObj.button.cancel(); 	break;	// 취소/목록 버튼
130 152
 						case 'ITP_BTN_OPER03011_SAVE'					: modifyObj.button.save(); 		break;	// 저장 버튼
153
+						case 'ITP_BTN_OPER03011_DETAIL_AFFL_SHOP_KEY'	: modifyObj.button.duplicate();	break;	// 중복체크
131 154
 						case 'ITP_BTN_OPER03011_RESET_PW'				: modifyObj.button.resetPass();	break;	// 상세:비밀번호 초기화
132 155
 						case 'ITP_FORM_OPER03011_DETAIL_ADRES_SCH'		: modifyObj.button.address();	break;	// 신규등록 주소 찾기
133 156
 						case 'ITP_BTN_OPER03011_DETAIL_ADDROW'			: pageObj.grid.button.addRow();	break;	// 신규등록 영업담당자 행 추가
@@ -158,19 +181,22 @@ let pageObj = {
158 181
 		$('.itp_det_head').find('button[id^="ITP_BTN_OPER03011_"]').each(function(i) {
159 182
 			$(this).hide();
160 183
 		});
161
-		$('div[id$="_CONTAINER"]').each(function(i) {
162
-			if($(this).attr('id').startsWith('ITP_AJAX_OPER03011')) {
163
-				$(this).hide();
164
-			}
184
+		$('#ITP_TAB_OPER03011').find('div[id$="_CONTAINER"]').each(function(i) {
185
+			$(this).hide();
165 186
 		});
166
-		if(mode == 'MODIFY') { // 수정
167
-			fn_show_btn_auth_array(['#ITP_BTN_OPER03011_CANCELLIST', '#ITP_BTN_OPER03011_SAVE', '#ITP_BTN_OPER03011_RESET_PW']);
187
+		if(mode === 'MODIFY') { // 수정
168 188
 			$('#ITP_AJAX_OPER03011_DETAIL_CONTAINER').show();
189
+			fn_show_btn_auth_array(['#ITP_BTN_OPER03011_CANCELLIST', '#ITP_BTN_OPER03011_SAVE', '#ITP_BTN_OPER03011_RESET_PW']);
190
+
191
+			// $('#ITP_FORM_OPER03011_DETAIL_AFFL_SHOP_NM').prop('readonly', true);
169 192
 			$('#ITP_FORM_OPER03011_DETAIL_AFFL_SHOP_KEY').prop('readonly', true);
170 193
 			$('#ITP_BTN_OPER03011_DETAIL_AFFL_SHOP_KEY').prop('disabled', true);
171
-		} else if(mode == 'VIEW') { // 보기
172
-			fn_show_btn_auth_array(['#ITP_BTN_OPER03011_MODIFY', '#ITP_BTN_OPER03011_CANCELLIST']);
194
+
195
+			$('input[id=ITP_FORM_OPER03011_DETAIL_ADRES]').data('alert-msg', ITP_MSG_LOCALE.message.form.emptyAddr);
196
+			$('input[id=ITP_FORM_OPER03011_DETAIL_ADRES_DTL]').data('alert-msg', ITP_MSG_LOCALE.message.form.emptyAddr);
197
+		} else if(mode === 'VIEW') { // 보기
173 198
 			$('#ITP_AJAX_OPER03011_VIEW_CONTAINER').show();
199
+			fn_show_btn_auth_array(['#ITP_BTN_OPER03011_MODIFY']);
174 200
 		}
175 201
 	},
176 202
 	grid: {
@@ -196,10 +222,8 @@ let pageObj = {
196 222
 
197 223
 					$.each(rowDataPop, function(key, value) {
198 224
 						if(exists.indexOf(value.saleMgrId) < 0) {
225
+							value['viewCd'] =  "C";
199 226
 							$(OPER03011_DETAIL_GRID_ID).jqGrid('addRowData', value.saleMgrId, value, 'last');
200
-							var rids = $(OPER01010_DETAIL_GRID_ID).jqGrid('getDataIDs');
201
-							var last_row_id = rids[rids.length - 1];
202
-							$(OPER01010_DETAIL_GRID_ID).jqGrid('setCell', last_row_id, 'viewCd', 'C');
203 227
 						}
204 228
 					});
205 229
 					$(OPER03011_DETAIL_GRID_EMPTY).hide();
@@ -221,7 +245,6 @@ let pageObj = {
221 245
 					$(_this.mode === 'VIEW' ? OPER03011_VIEW_GRID_LIST : OPER03011_DETAIL_GRID_LIST).find('.ui-jqgrid .ui-jqgrid-bdiv').css('overflow-x', 'hidden');
222 246
 					if(data.records === 0) {
223 247
 						_this.clearData();
224
-						console.log(ITP_MSG_LOCALE.message.grid.noData);
225 248
 						var gridEmpty = (this.mode === 'VIEW') ? OPER03011_VIEW_GRID_EMPTY : OPER03011_DETAIL_GRID_EMPTY;
226 249
 						$(gridEmpty).html(ITP_MSG_LOCALE.message.grid.noData);
227 250
 						$(gridEmpty).show();
@@ -248,11 +271,8 @@ let viewObj = {
248 271
 		this.load();
249 272
 	},
250 273
 	load: function() {
251
-		const afflShopIdVal = fn_make_user_info.get('afflShopId');
252
-		const key = {afflShopId: afflShopIdVal, viewCd: 'R'};
253
-		// const key = {afflShopId: 'FRCMP02', viewCd: 'R'};
254
-		var param = $.param(key);
255
-		fn_ajax_call(API_DETAIL_INFO, param, this.callback, 'GET');
274
+		const key = {afflShopId: fn_make_user_info.get('afflShopId'), viewCd: 'R'};
275
+		fn_ajax_call(API_DETAIL_INFO,  $.param(key), this.callback, 'GET');
256 276
 	},
257 277
 	callback: function (result) {
258 278
 		console.log(result);
@@ -261,10 +281,10 @@ let viewObj = {
261 281
 
262 282
 		$('#ITP_FORM_OPER03011_VIEW .fnAfflShopId').text(result.afflShopId);
263 283
 		$('#ITP_FORM_OPER03011_VIEW .fnAfflShopNm').text(result.afflShopNm);
264
-		$('#ITP_FORM_OPER03010_VIEW .fnAfflShopKey').text(result.afflAbbr);
284
+		$('#ITP_FORM_OPER03011_VIEW .fnAfflAbbr').text(result.afflAbbr);
265 285
 		$('#ITP_FORM_OPER03011_VIEW .fnStCd').text(result.stNm);
266
-		$('#ITP_FORM_OPER03011_VIEW .fnCorpTypeNm').text(result.corpTypeNm);
267
-		$('#ITP_FORM_OPER03011_VIEW .fnBsnsRegNo').text(result.corpRegNo);
286
+		$('#ITP_FORM_OPER03011_VIEW .fnCorpTypeNm').text(result.authTypeNm);
287
+		$('#ITP_FORM_OPER03011_VIEW .fnBsnsRegNo').text(result.bsnsRegNo);
268 288
 		$('#ITP_FORM_OPER03011_VIEW .fnCorpRegNo').text(result.corpRegNo);
269 289
 		$('#ITP_FORM_OPER03011_VIEW .fnTelNo').text(result.ownerTelNo);
270 290
 		$('#ITP_FORM_OPER03011_VIEW .fnFaxNo').text(result.rprstFaxNo);
@@ -279,72 +299,11 @@ let viewObj = {
279 299
 		$('#ITP_FORM_OPER03011_VIEW .fnLoadAddr').text(result.addr1);
280 300
 		$('#ITP_FORM_OPER03011_VIEW .fnDtlAddr').text(result.addr2);
281 301
 
282
-		$('#ITP_FORM_OPER03011_VIEW .fnAddDt').text(result.regDt);
283
-		$('#ITP_FORM_OPER03011_VIEW .fnChgDt').text(result.chgDt);
284
-
285 302
 		let locate = result.addr1 + ' ' + result.addr2;
286 303
 		kakaoMap.init('ITP_FORM_OPER03011_VIEW', locate);
287 304
 
288 305
 		// 영업담당자정보  리스트 조회
289 306
 		pageObj.grid.init('VIEW', result.saleList);
290
-	},
291
-	grid: {
292
-		init: function() {
293
-			this.unload();
294
-			this.load();
295
-		},
296
-		load : function() {
297
-			let param = $('#ITP_FORM_OPER03011_VIEW').serializeObject();
298
-			param.gridSize = $.jgrid.defaults.rowNum;
299
-			param.pagingYn = false; // 페이징안함
300
-
301
-			var option = {
302
-				gridId: OPER03011_VIEW_GRID_ID,
303
-				colModel: gridColModel.detail,
304
-				param: JSON.stringify(param),
305
-				url: DOMAIN + USER_USERAUTH_GRID_LIST,
306
-				pager: OPER03011_VIEW_GRID_PAGER,
307
-				loadComplete: function(data) {
308
-					itp_fn_grid_load_complete(data, OPER03011_VIEW_GRID_ID, true, undefined, 'OPER03011_VIEW');
309
-				},
310
-				onPaging: function(action) {
311
-					var pagingFn = {
312
-						callBack: function(args) {
313
-							$(args).trigger('reloadGrid');
314
-						}
315
-					};
316
-					if (itp_fn_check_grid_is_writing(OPER03011_VIEW_GRID_ID)) {
317
-						itp_fn_modal_confirm(ITP_MSG_LOCALE.message.ajax.cancelData, pagingFn, OPER03011_VIEW_GRID_ID);
318
-						return 'stop';
319
-					} else {
320
-						itp_fn_grid_paging(OPER03011_VIEW_GRID_ID, action, param);
321
-					}
322
-				},
323
-				onSortCol: function(index, columnIndex, sortOrder) {
324
-					var sortingFn = {
325
-						callBack: function(args) {
326
-							$(args).trigger('reloadGrid');
327
-						}
328
-					};
329
-					if (itp_fn_check_grid_is_writing(OPER03011_VIEW_GRID_ID)) {
330
-						itp_fn_modal_confirm(ITP_MSG_LOCALE.message.ajax.cancelData, sortingFn, OPER03011_VIEW_GRID_ID);
331
-						return 'stop';
332
-					} else {
333
-						itp_fn_grid_sorting(OPER03011_VIEW_GRID_ID, index, sortOrder);
334
-					}
335
-				}
336
-			};
337
-			itp_fn_grid_make_remote(option);
338
-		},
339
-		clearData : function() {
340
-			$(OPER03011_VIEW_GRID_ID).jqGrid('clearGridData', true);
341
-			$(OPER03011_VIEW_GRID_LIST).find('.ui-jqgrid-bdiv').css('min-height', '100px');
342
-			$(OPER03011_VIEW_GRID_EMPTY).html(ITP_MSG_LOCALE.message.grid.noData);
343
-			$(OPER03011_VIEW_GRID_EMPTY).show();
344
-		},
345
-		unload : function() {
346
-			$.jgrid.gridUnload(OPER03011_VIEW_GRID_ID);
347
-		}
348 307
 	}
349 308
 };
350 309
 
@@ -353,10 +312,24 @@ let modifyObj = {
353 312
 	button: {
354 313
 		modify: function (param) {
355 314
 			itp_fn_form_clear_validate(null, '#ITP_FORM_OPER03011_DETAIL');
356
-			const afflShopIdVal = $('#ITP_FORM_OPER03011_VIEW_AFFL_SHOP_ID').val();
357
-			const key = {afflShopId: afflShopIdVal, viewCd: 'R'};
358
-			var param = $.param(key);
359
-			modifyObj.load(param);
315
+			const key = {afflShopId: fn_make_user_info.get('afflShopId'), viewCd: 'R'};
316
+			modifyObj.load($.param(key));
317
+		},
318
+		duplicate: function() {
319
+			const formId = '#ITP_FORM_OPER03011_DETAIL';
320
+			itp_fn_form_clear_validate(null, formId);
321
+			if (itp_fn_form_validate(formId, formId + '_AFFL_SHOP_KEY', ['empty'], undefined)) {
322
+				var dupFn = function(result) {
323
+					if (result.code === 'N') {
324
+						ITP_FORM_OPER03011_DETAIL_IS_DUPLICATE = false;
325
+					} else {
326
+						ITP_FORM_OPER03011_DETAIL_IS_DUPLICATE = true;
327
+					}
328
+				};
329
+				const key = {'afflAbbr':  $(formId + '_AFFL_SHOP_KEY').val()};
330
+				const param = $.param(key);
331
+				fn_ajax_call(API_CHECK_DUPLICATE, param, dupFn, 'GET');
332
+			}
360 333
 		},
361 334
 		resetPass: function() {
362 335
 			var resetPwFn = {
@@ -377,37 +350,31 @@ let modifyObj = {
377 350
 		save: function() {
378 351
 			const formId = '#ITP_FORM_OPER03011_DETAIL';
379 352
 			itp_fn_form_clear_validate(null, formId);
380
-			var vali_cmpyCd = itp_fn_form_validate(formId, formId + '_CMPY_CD', ['empty'], undefined);
381
-			var vali_cmpyStatCd = itp_fn_form_validate(formId, formId + '_CMPY_STAT_CD', ['empty'], undefined);
382
-			var vali_cmpyTypeCd = itp_fn_form_validate(formId, formId + '_CMPY_TYPE_CD', ['empty'], undefined);
383
-			var vali_cmpyNm = itp_fn_form_validate(formId, formId + '_CMPY_NM', ['empty'], undefined);
384
-			var vali_bossNm = itp_fn_form_validate(formId, formId + '_BOSS_NM', ['empty'], undefined);
385
-			var vali_mainTel = itp_fn_form_validate(formId, formId + '_MAIN_TEL', ['empty'], undefined);
386
-			var vali_mainEmail = itp_fn_form_validate(formId, formId + 'MAIN_EMAIL', ['empty'], undefined);
387 353
 
388
-			if (vali_cmpyCd && vali_cmpyStatCd && vali_cmpyTypeCd && vali_cmpyNm && vali_bossNm && vali_mainTel && vali_mainEmail) {
354
+			// if (vali_cmpyCd && vali_cmpyStatCd && vali_cmpyTypeCd && vali_cmpyNm && vali_bossNm && vali_mainTel && vali_mainEmail) {
355
+			if (itp_fn_is_valid(formId)) {
389 356
 
390
-				if($('#ITP_FORM_OPER03011_DETAIL_CMPY_ZIPNO').val() == '' || $('#ITP_FORM_OPER03011_DETAIL_CMPY_ADRES').val() == '') {
357
+				if($('#ITP_FORM_OPER03011_DETAIL_CMPY_ZIPNO').val() === '' || $('#ITP_FORM_OPER03011_DETAIL_CMPY_ADRES').val() === '') {
391 358
 					itp_fn_modal_alert('주소 검색을 통해 회사 주소를 입력하세요.');
392 359
 					return;
393 360
 				}
394 361
 
395 362
 				if (ITP_FORM_OPER03011_DETAIL_IS_DUPLICATE) {
396
-					itp_fn_modal_duplicate('회사코드 중복체크를 해주세요.', formId + '_CMPY_CD');
363
+					itp_fn_modal_duplicate('회사코드 중복체크를 해주세요.', formId + '_AFFL_SHOP_ID');
397 364
 				} else {
398 365
 					let gridInsertData = [];
399 366
 					let gridUpdateData = [];
400 367
 					let gridDeleteData = [];
401 368
 					const rowData = $(OPER03011_DETAIL_GRID_ID).getRowData();
402
-					const keyValue = $(formId + '_CMPY_CD').val();
369
+					const keyValue = $(formId + '_AFFL_SHOP_ID').val();
403 370
 					$.each(rowData, function(key, value) {
404
-						if (value.viewCd != 'R') {
405
-							value.userId = keyValue;
406
-							if (value.viewCd == 'C') {
371
+						if (value.viewCd !== 'R') {
372
+							value.afflShopId = keyValue;
373
+							if (value.viewCd === 'C') {
407 374
 								gridInsertData.push(value);
408
-							} else if (value.viewCd == 'U') {
375
+							} else if (value.viewCd === 'U') {
409 376
 								gridUpdateData.push(value);
410
-							} else if (value.viewCd == 'D') {
377
+							} else if (value.viewCd === 'D') {
411 378
 								gridDeleteData.push(value);
412 379
 							}
413 380
 						}
@@ -417,9 +384,10 @@ let modifyObj = {
417 384
 					param.gridInsertData = gridInsertData;
418 385
 					param.gridUpdateData = gridUpdateData;
419 386
 					param.gridDeleteData = gridDeleteData;
387
+					console.log(JSON.stringify(param));
420 388
 					var searhFn = function() {
421 389
 						ITP_FORM_OPER03011_DETAIL_IS_WRITING = false;
422
-						listObj.grid.search();
390
+						viewObj.init();
423 391
 					};
424 392
 					fn_ajax_call(API_DETAIL_SAVE, JSON.stringify(param), searhFn, 'POST');
425 393
 				}
@@ -430,19 +398,21 @@ let modifyObj = {
430 398
 		fn_ajax_call(API_DETAIL_INFO, param, this.callback, 'GET');
431 399
 	},
432 400
 	callback: function (result) {
433
-		// console.log(result);
401
+		console.log(result);
434 402
 		pageObj.switchScreen('MODIFY');
435 403
 		$('#ITP_FORM_OPER03011_DETAIL #ITP_FORM_OPER03011_DETAIL_VIEW_CD').val('U');
436 404
 
437 405
 		$('#ITP_FORM_OPER03011_DETAIL #ITP_FORM_OPER03011_DETAIL_AFFL_SHOP_ID').val(result.afflShopId);
438 406
 		$('#ITP_FORM_OPER03011_DETAIL .fnAfflShopId').text(result.afflShopId);
439
-		$('#ITP_FORM_OPER03011_DETAIL .fnAfflShopNm').text(result.afflShopNm);
440
-		$('#ITP_FORM_OPER03011_DETAIL #ITP_FORM_OPER03011_DETAIL_ST_CD').val(result.stNm);
441
-		// $('#ITP_FORM_OPER03011_DETAIL #fnCmpyTypeCd').text(result.corpType);
442
-		$('#ITP_FORM_OPER03011_DETAIL #ITP_FORM_OPER03011_DETAIL_BSNS_REG_NO').val(result.corpRegNo);
407
+		$('#ITP_FORM_OPER03011_DETAIL #ITP_FORM_OPER03011_DETAIL_AFFL_SHOP_NM').val(result.afflShopNm);
408
+		$('#ITP_FORM_OPER03011_DETAIL #ITP_FORM_OPER03011_DETAIL_AFFL_SHOP_KEY').val(result.afflAbbr);
409
+		$('#ITP_FORM_OPER03011_DETAIL #ITP_FORM_OPER03011_DETAIL_ST_CD').val(result.stCd);
410
+		$('#ITP_FORM_OPER03011_DETAIL #ITP_FORM_OPER03011_DETAIL_AUTH_TYPE').val(result.authType);
411
+		$('#ITP_FORM_OPER03011_DETAIL #ITP_FORM_OPER03011_DETAIL_CORP_TYPE').val(result.corpType);
412
+		$('#ITP_FORM_OPER03011_DETAIL #ITP_FORM_OPER03011_DETAIL_BSNS_REG_NO').val(result.bsnsRegNo);
443 413
 		$('#ITP_FORM_OPER03011_DETAIL #ITP_FORM_OPER03011_DETAIL_CORP_REG_NO').val(result.corpRegNo);
444
-		$('#ITP_FORM_OPER03011_DETAIL #ITP_FORM_STINFO01010_DETAIL_TEL_NO').val(result.ownerTelNo);
445
-		$('#ITP_FORM_OPER03011_DETAIL #ITP_FORM_STINFO01010_DETAIL_FAX_NO').val(result.rprstFaxNo);
414
+		$('#ITP_FORM_OPER03011_DETAIL #ITP_FORM_OPER03011_DETAIL_TEL_NO').val(result.ownerTelNo);
415
+		$('#ITP_FORM_OPER03011_DETAIL #ITP_FORM_OPER03011_DETAIL_FAX_NO').val(result.rprstFaxNo);
446 416
 		$('#ITP_FORM_OPER03011_DETAIL #ITP_FORM_OPER03011_DETAIL_EMAL_ADDR').val(result.rprstEmai);
447 417
 		$('#ITP_FORM_OPER03011_DETAIL #ITP_FORM_OPER03011_DETAIL_BSNS_CNDT').val(result.bsnsCndt);
448 418
 		$('#ITP_FORM_OPER03011_DETAIL #ITP_FORM_OPER03011_DETAIL_OWNER_NM').val(result.ownerNm);
@@ -451,8 +421,8 @@ let modifyObj = {
451 421
 		$('#ITP_FORM_OPER03011_DETAIL #ITP_FORM_OPER03011_SEARCH_JOIN_STT_DT').val(result.joinSttDt);
452 422
 		$('#ITP_FORM_OPER03011_DETAIL #ITP_FORM_OPER03011_SEARCH_JOIN_END_DT').val(result.joinEndDt);
453 423
 		$('#ITP_FORM_OPER03011_DETAIL #ITP_FORM_OPER03011_DETAIL_ZIPNO').val(result.zipNo);
454
-		$('#ITP_FORM_OPER03011_DETAIL #ITP_FORM_OPER03011_DETAIL_LOAD_ADDR').val(result.addr1);
455
-		$('#ITP_FORM_OPER03011_DETAIL #ITP_FORM_OPER03011_DETAIL_DTL_ADDR').val(result.addr2);
424
+		$('#ITP_FORM_OPER03011_DETAIL #ITP_FORM_OPER03011_DETAIL_ADRES').val(result.addr1);
425
+		$('#ITP_FORM_OPER03011_DETAIL #ITP_FORM_OPER03011_DETAIL_ADRES_DTL').val(result.addr2);
456 426
 
457 427
 		$('#ITP_FORM_OPER03011_DETAIL .fnAddDt').text(result.regDt);
458 428
 		$('#ITP_FORM_OPER03011_DETAIL .fnChgDt').text(result.chgDt);
@@ -461,64 +431,6 @@ let modifyObj = {
461 431
 
462 432
 		// 권한정보 리스트 조회
463 433
 		pageObj.grid.init('MODIFY', result.saleList);
464
-	},
465
-	grid: {
466
-		init: function() {
467
-			this.unload();
468
-			this.load();
469
-		},
470
-		load : function() {
471
-			let param = $('#ITP_FORM_OPER03011_DETAIL').serializeObject();
472
-			param.gridSize = $.jgrid.defaults.rowNum;
473
-			param.pagingYn = false; // 페이지안함
474
-
475
-			var option = {
476
-				gridId: OPER03011_DETAIL_GRID_ID,
477
-				colModel: gridColModel.detail,
478
-				param: JSON.stringify(param),
479
-				url: DOMAIN + USER_USERAUTH_GRID_LIST,
480
-				pager: OPER03011_DETAIL_GRID_PAGER,
481
-				multiselect: true,
482
-				loadComplete: function(data) {
483
-					itp_fn_grid_load_complete(data, OPER03011_DETAIL_GRID_ID, true, undefined, 'OPER03011_DETAIL');
484
-				},
485
-				onPaging: function(action) {
486
-					var pagingFn = {
487
-						callBack: function(args) {
488
-							$(args).trigger('reloadGrid');
489
-						}
490
-					};
491
-					if (itp_fn_check_grid_is_writing(OPER03011_DETAIL_GRID_ID)) {
492
-						itp_fn_modal_confirm(ITP_MSG_LOCALE.message.ajax.cancelData, pagingFn, OPER03011_DETAIL_GRID_ID);
493
-						return 'stop';
494
-					} else {
495
-						itp_fn_grid_paging(OPER03011_DETAIL_GRID_ID, action, param);
496
-					}
497
-				},
498
-				onSortCol: function(index, columnIndex, sortOrder) {
499
-					var sortingFn = {
500
-						callBack: function(args) {
501
-							$(args).trigger('reloadGrid');
502
-						}
503
-					};
504
-					if (itp_fn_check_grid_is_writing(OPER03011_DETAIL_GRID_ID)) {
505
-						itp_fn_modal_confirm(ITP_MSG_LOCALE.message.ajax.cancelData, sortingFn, OPER03011_DETAIL_GRID_ID);
506
-						return 'stop';
507
-					} else {
508
-						itp_fn_grid_sorting(OPER03011_DETAIL_GRID_ID, index, sortOrder);
509
-					}
510
-				}
511
-			};
512
-			itp_fn_grid_make_remote(option);
513
-		},
514
-		clearData : function() {
515
-			$(OPER03011_DETAIL_GRID_ID).jqGrid('clearGridData', true);
516
-			$(OPER03011_DETAIL_GRID_LIST).find('.ui-jqgrid-bdiv').css('min-height', '100px');
517
-			$(OPER03011_DETAIL_GRID_EMPTY).html(ITP_MSG_LOCALE.message.grid.noData);
518
-			$(OPER03011_DETAIL_GRID_EMPTY).show();
519
-		},
520
-		unload : function() {
521
-			$.jgrid.gridUnload(OPER03011_DETAIL_GRID_ID);
522
-		}
523 434
 	}
524 435
 };
436
+

+ 131 - 0
src/main/webapp/js/app/popup/biz/ITP_BIZPOP_BRAND_STORE.js

@@ -0,0 +1,131 @@
1
+require(['config'], function() {
2
+	require([
3
+		'jquery'
4
+	], function($) {
5
+
6
+	});
7
+});
8
+
9
+let API_POP_GRID_LIST = '/api/store/pop-grid-list';
10
+
11
+function itp_fn_BIZPOP_BRAND_STORE(parentPopFn, args, returnType) {
12
+	
13
+	let itp_BIZPOP_BRAND_STORE_param = {};
14
+	let itp_BIZPOP_BRAND_STORE_search = false;
15
+
16
+	const THIS_FORM_ID = '#ITP_FORM_BIZPOP_BRAND_STORE';
17
+	const THIS_GIRD_ID = '#ITP_BIZPOP_BRAND_STORE_jqGrid';
18
+	const THIS_GIRD_PAGER = '#ITP_BIZPOP_BRAND_STORE_jqGridPager';
19
+
20
+	$('#ITP_FORM_BIZPOP_BRAND_ID').val(fn_make_user_info.get('brandId'));
21
+	if(args) {
22
+		$('#ITP_FORM_BIZPOP_BRAND_STORE_NM').val(args.storeNm);
23
+	}
24
+	
25
+	$('#ITP_BIZPOP_BRAND_STORE').one('shown.bs.modal', function(e) {
26
+		itp_fn_jqgrid_resize(THIS_GIRD_ID, '#ITP_BIZPOP_BRAND_STORE_jqGrid_list', '');
27
+		itp_fn_fire_window_resize();
28
+	}).one('hidden.bs.modal', function(e) {
29
+		$('#ITP_BIZPOP_BRAND_STORE').remove();
30
+	}).modal('show');
31
+
32
+	$('#ITP_BIZPOP_BRAND_STORE_BTN_SEARCH').on('click', function() {
33
+		itp_BIZPOP_BRAND_STORE_search = true;
34
+		let param = $(THIS_FORM_ID).serializeObject();
35
+		param.gridSize = 10;
36
+		param.gridPage = $.jgrid.defaults.page;
37
+		$(THIS_GIRD_ID).setGridParam({'postData': JSON.stringify(param)}).trigger('reloadGrid');
38
+	});
39
+	
40
+	$('#ITP_BIZPOP_BRAND_STORE_BTN_SELECT').on('click', function() {		
41
+		const rowKey = $(THIS_GIRD_ID).getGridParam('selrow');
42
+	    if (!rowKey) {
43
+	    	return;
44
+	    }
45
+
46
+		var list = [];
47
+	    var selectedIds = $(THIS_GIRD_ID).getGridParam('selarrrow');
48
+
49
+		if(selectedIds.length > 1) { // 1개만 선택
50
+			return;
51
+		} 
52
+		
53
+	    for (var i=selectedIds.length-1; i>=0; i--) {
54
+			list.push($(THIS_GIRD_ID).jqGrid('getRowData', selectedIds[i]));	
55
+		}
56
+		parentPopFn(list);
57
+		$('#ITP_BIZPOP_BRAND_STORE').modal('hide'); // 팝업닫기
58
+	});
59
+
60
+	$('#ITP_BIZPOP_BRAND_STORE_jqGridEmpty').on('click', function() {
61
+		itp_fn_BIZPOP_BRAND_STORE_empty.back();
62
+		itp_BIZPOP_BRAND_STORE_param.gridSize = 10;
63
+		$(THIS_GIRD_ID).setGridParam({'postData': JSON.stringify(itp_BIZPOP_BRAND_STORE_param)}).trigger('reloadGrid');
64
+	});
65
+
66
+	var itp_fn_BIZPOP_BRAND_STORE_empty = {
67
+		push: function() {
68
+			let param = $(THIS_FORM_ID).serializeObject();
69
+			itp_BIZPOP_BRAND_STORE_param = param;
70
+		},
71
+		back: function() {
72
+			$(THIS_FORM_ID + '_NM').val(itp_BIZPOP_BRAND_STORE_param.storeNm);
73
+		}
74
+	};
75
+
76
+	itp_fn_BIZPOP_BRAND_STORE_empty.push();
77
+	let param = $('#ITP_FORM_BIZPOP_BRAND_STORE').serializeObject();
78
+	param.gridSize = 10;
79
+
80
+	$(THIS_GIRD_ID).jqGrid({
81
+		colModel: [
82
+			{
83
+				index: 'BRAND_ID', name: 'brandId',
84
+				label: '브랜드ID', //
85
+				width: '10', fixed: false, align: 'center',
86
+				sortable: false, hidden: true
87
+			},
88
+			{
89
+				index: 'BRAND_NM', name: 'brandNm',
90
+				label: '브랜드명', //
91
+				width: '20', fixed: false, align: 'center',
92
+				sortable: false, hidden: false
93
+			},
94
+			{
95
+				index: 'STORE_ID', name: 'storeId',
96
+				label: '매장ID', //
97
+				width: '0', fixed: false, align: 'center',
98
+				sortable: false, hidden: true
99
+			},
100
+			{
101
+				index: 'STORE_NM', name: 'storeNm',
102
+				label: '매장명', //
103
+				width: '20', fixed: false, align: 'center',
104
+				sortable: false, hidden: false
105
+			},
106
+			{
107
+				index: 'STORE_ST_NM', name: 'storeStNm',
108
+				label: '상태', //
109
+				width: '20', fixed: false, align: 'center',
110
+				sortable: false, hidden: false
111
+			}
112
+		],
113
+		loadBeforeSend: function(jqXHR) {
114
+		    jqXHR.setRequestHeader('X-AUTH-TOKEN', CONN_KEY);
115
+		},
116
+		postData: JSON.stringify(param),
117
+		url: DOMAIN + API_POP_GRID_LIST,
118
+		pager: THIS_GIRD_PAGER,
119
+		multiselect: true,
120
+		loadComplete: function(data) {
121
+			console.log(data);
122
+			itp_fn_grid_load_complete(data, THIS_GIRD_ID, true, undefined, 'BIZPOP_BRAND_STORE', itp_BIZPOP_BRAND_STORE_search, itp_fn_BIZPOP_BRAND_STORE_empty, true, data.gridRecords, false);
123
+	    },
124
+	    loadError: function(jqXHR, textStatus, errorThrown) {
125
+	    	itp_fn_grid_load_error(jqXHR, textStatus, errorThrown);
126
+	    },
127
+	    onPaging: function(action) {
128
+	    	itp_fn_grid_paging(THIS_GIRD_ID, action, param);
129
+	    }
130
+	}).navGrid(THIS_GIRD_PAGER, ITP_GRID_NAV_DEFAULTS.navGrid);
131
+};

+ 196 - 68
src/main/webapp/js/app/stinfo/ITP_STINFO06010.js

@@ -38,6 +38,7 @@ let ITP_COMMON_CD_UNIT_TARGET_CD = fn_make_common_cd_list(CODE_LIST, 'UNIT_TARGE
38 38
 /*API URL*/
39 39
 let API_DETAIL_GRID_LIST 	= '/api/itemunit/store-unit-grid-list';		// 목록
40 40
 let API_DETAIL_INFO 		= '/api/itemunit/info-storeitemunit';		// 상세
41
+let API_DETAIL_NEW	 		= '/api/itemunit/new-info-storeitemunit';	// 신규
41 42
 let API_DETAIL_SAVE 		= '/api/itemunit/save-store-itemunit';		// 저장
42 43
 
43 44
 /*화면 Grid ColModel*/
@@ -99,6 +100,18 @@ const gridColModel = {
99 100
 			width: '10', fixed: false, align: 'center',
100 101
 			sortable: false, hidden: true
101 102
 		},
103
+		{
104
+			index: 'BRAND_UNIT_UNQ_NO', name: 'brandUnitUnqNo',
105
+			label: ITP_MSG_LOCALE.label.brandId, //브랜드ID
106
+			width: '10', fixed: false, align: 'center',
107
+			sortable: false, hidden: true
108
+		},
109
+		{
110
+			index: 'STORE_UNIT_UNQ_NO', name: 'storeUnitUnqNo',
111
+			label: ITP_MSG_LOCALE.label.storeId, //브랜드ID
112
+			width: '10', fixed: false, align: 'center',
113
+			sortable: false, hidden: true
114
+		},
102 115
 		{
103 116
 			index: 'ITEM_ID', name: 'itemId',
104 117
 			label: ITP_MSG_LOCALE.label.itemId, //품목번호
@@ -216,58 +229,63 @@ let pageObj = {
216 229
 				var id = $(this).attr('id');
217 230
 				$(this).on('click', function() {
218 231
 					switch (id) {
219
-						case 'ITP_BTN_STINFO06010_SRH'				: (this.screenMode === 'List') ? listObj.button.search() : modifyObj.search();		break;	// 조회 버튼 클릭
220 232
 						case 'ITP_BTN_STINFO06010_NEWREG'			: listObj.button.create(); 		break;	// 신규등록 버튼
221 233
 						case 'ITP_BTN_STINFO06010_CANCELLIST'		: listObj.grid.search(); 		break;	// 취소/목록 버튼
222
-						case 'ITP_BTN_STINFO06010_SAVE'				: modifyObj.button.save(); 		break;	// 저장 버튼
234
+						case 'ITP_BTN_STINFO06010_SAVE'				: createObj.button.save(); 		break;	// 저장 버튼
223 235
 					}
224 236
 				});
225 237
 			});
226 238
 
239
+			$('body').on('click', function(e) {
240
+				var gridId = STINFO06010_DETAIL_GRID_ID.replace('#', '');
241
+				itp_fn_grid_reset_selection(e, STINFO06010_GRID_LAST_ROW_ID, gridId, 'STINFO06010');
242
+			});
243
+
227 244
 		}
228 245
 	},
229 246
 	switchScreen: function(mode) {
247
+		this.screenMode = mode;
230 248
 		$('.itp_det_head').find('button[id^="ITP_BTN_STINFO06010_"]').each(function(i) {
231 249
 			$(this).hide();
232 250
 		});
233 251
 		$('#ITP_TAB_STINFO06010').find('div[id$="_CONTAINER"]').each(function(i) {
234 252
 			$(this).hide();
235 253
 		});
254
+		if(mode == 'ADD') {
255
+			$('#ITP_FORM_STINFO06010_DETAIL .contDt').show();
256
+		} else {
257
+			$('#ITP_FORM_STINFO06010_DETAIL .contDt').hide();
258
+		}
236 259
 		if(mode == 'LIST') { // 목록
237 260
 			$('#ITP_AJAX_STINFO06010_LIST_CONTAINER').show();
238
-			fn_show_btn_auth_array(['#ITP_BTN_STINFO06010_SRH', '#ITP_BTN_STINFO06010_NEWREG']);
261
+			if(fn_make_user_info.get('authTpCd') === '50') {
262
+				fn_show_btn_auth_array(['#ITP_BTN_STINFO06010_SRH']);
263
+			} else {
264
+				fn_show_btn_auth_array(['#ITP_BTN_STINFO06010_SRH', '#ITP_BTN_STINFO06010_NEWREG']);
265
+			}
239 266
 		} else if(mode == 'ADD') { // 등록
267
+			itp_fn_form_clear_validate(null, '#ITP_FORM_STINFO07010_DETAIL');
268
+
240 269
 			$('#ITP_AJAX_STINFO06010_DETAIL_CONTAINER').show();
241
-			fn_show_btn_auth_array(['#ITP_BTN_STINFO06010_CANCELLIST', '#ITP_BTN_STINFO06010_SAVE']);
242 270
 
243
-			$('#ITP_FORM_STINFO06010_DETAIL').find('input, textarea, select, checkbox').each(function(i, elem) {
244
-				$(this).attr('id') === 'ITP_FORM_STINFO06010_DETAIL_VIEW_CD' ? $(this).val('C') : $(this).val('');
245
-				if(elem.type === 'select') {
246
-					$(this).val('').prop('selected', true);
247
-				}
248
-			});
271
+			fn_show_btn_auth_array(['#ITP_BTN_STINFO06010_CANCELLIST', '#ITP_BTN_STINFO06010_SAVE']);
249 272
 
273
+			$('#ITP_BTN_STINFO06010_DETAIL_SEARCH_STORE').removeAttr('disabled');
274
+			$('#ITP_BTN_STINFO06010_DETAIL_DELETE_STORE').removeAttr('disabled');
250 275
 			// 가맹점 정보 설정
251
-			$('#ITP_FORM_STINFO06010_DETAIL_AFFL_SHOP_ID').val(fn_make_user_info.get('afflShopId'));
252 276
 			$('#ITP_FORM_STINFO06010_DETAIL_BRAND_ID').val(fn_make_user_info.get('brandId'));
253
-			$('#ITP_FORM_STINFO06010_DETAIL_STORE_ID').val(fn_make_user_info.get('storeId'));
254
-
255
-			$('#ITP_FORM_STINFO06010_DETAIL_STORE_ID').removeAttr('readonly');
256
-			$('#ITP_FORM_STINFO06010_DETAIL_DUP').removeAttr('disabled');
257
-
258
-			$('#ITP_FORM_STINFO06010_DETAIL .fnStoreNm').text('(자동부여)');
259 277
 		} else if(mode == 'MODIFY') { // 수정
260 278
 			$('#ITP_AJAX_STINFO06010_DETAIL_CONTAINER').show();
261
-			fn_show_btn_auth_array(['#ITP_BTN_STINFO06010_CANCELLIST', '#ITP_BTN_STINFO06010_SAVE', '#ITP_BTN_STINFO06010_RESET_PW']);
279
+			if(fn_make_user_info.get('authTpCd') === '50') {
280
+				fn_show_btn_auth_array(['#ITP_BTN_STINFO06010_CANCELLIST']);
281
+			} else {
282
+				fn_show_btn_auth_array(['#ITP_BTN_STINFO06010_CANCELLIST', '#ITP_BTN_STINFO06010_SAVE']);
283
+			}
284
+			$('#ITP_BTN_STINFO06010_DETAIL_SEARCH_STORE').attr('disabled', true);
285
+			$('#ITP_BTN_STINFO06010_DETAIL_DELETE_STORE').attr('disabled', true);
262 286
 
263 287
 			// 가맹점 정보 설정
264
-			$('#ITP_FORM_STINFO06010_DETAIL_AFFL_SHOP_ID').val(fn_make_user_info.get('afflShopId'));
265 288
 			$('#ITP_FORM_STINFO06010_DETAIL_BRAND_ID').val(fn_make_user_info.get('brandId'));
266
-			$('#ITP_FORM_STINFO06010_DETAIL_STORE_ID').val(fn_make_user_info.get('storeId'));
267
-
268
-			if(fn_make_user_info.get('authTpCd') === '50') {
269
-				$('#ITP_FORM_STINFO06010_DETAIL_STORE_NM').val(fn_make_user_info.get('storeNm'));
270
-			}
271 289
 		} else if(mode == 'VIEW') { // 보기
272 290
 			$('#ITP_AJAX_STINFO06010_VIEW_CONTAINER').show();
273 291
 			fn_show_btn_auth_array(['#ITP_BTN_STINFO06010_MODIFY', '#ITP_BTN_STINFO06010_CANCELLIST']);
@@ -291,9 +309,7 @@ let listObj = {
291 309
 			$(STINFO06010_GRID_ID).setGridParam({'postData': JSON.stringify(param)}).trigger('reloadGrid');
292 310
 		},
293 311
 		create: function() {
294
-			if(!fn_make_user_info.isEmpty()) {
295
-				modifyObj.init();
296
-			}
312
+			createObj.init();
297 313
 		}
298 314
 	},
299 315
 	empty: {
@@ -340,10 +356,13 @@ let listObj = {
340 356
 				onCellSelect: function(rowId, cellIdx, cellValue) {
341 357
 					var cm = $(this).jqGrid('getGridParam', 'colModel');
342 358
 					var colNm = cm[cellIdx].name;
343
-					if (colNm == 'contSttDt') {
359
+					if (colNm === 'contSttDt') {
344 360
 						const storeId = $(this).jqGrid('getCell', rowId, 'storeId');
361
+						const storeNm = $(this).jqGrid('getCell', rowId, 'storeNm');
345 362
 						const contSttDt = $(this).jqGrid('getCell', rowId, 'contSttDt');
346 363
 						const contEndDt = $(this).jqGrid('getCell', rowId, 'contEndDt');
364
+						$('#ITP_FORM_STINFO06010_DETAIL_STORE_ID').val(storeId);
365
+						$('#ITP_FORM_STINFO06010_DETAIL_STORE_NM').val(storeNm);
347 366
 						const key = {brandId:fn_make_user_info.get('brandId'), storeId: storeId, contSttDt: contSttDt, contEndDt: contEndDt, viewCd: 'R'};
348 367
 						var param = $.param(key);
349 368
 						modifyObj.init(param);
@@ -378,11 +397,8 @@ let listObj = {
378 397
 /*수정화면 Object*/
379 398
 let modifyObj = {
380 399
 	init: function (param) {
381
-		console.log(param);
382 400
 		pageObj.switchScreen('MODIFY');
383
-		if(!param) {
384
-			param = $('#ITP_FORM_STINFO06010_DETAIL').serializeObject();
385
-		}
401
+		// var param = $.param($('#ITP_FORM_STINFO06010_DETAIL').serializeObject());
386 402
 		this.grid.init(param);
387 403
 	},
388 404
 	itp_STINFO06010_search: false,
@@ -394,31 +410,6 @@ let modifyObj = {
394 410
 		$(STINFO06010_DETAIL_GRID_ID).setGridParam({'postData': JSON.stringify(param)}).trigger('reloadGrid');
395 411
 	},
396 412
 	button: {
397
-		save: function() {
398
-			itp_fn_grid_save_rows(STINFO06010_DETAIL_GRID_ID);
399
-
400
-			var rows = $(STINFO06010_DETAIL_GRID_ID).getRowData();
401
-			let param = {};
402
-			var gridInsertData = [];
403
-			var gridUpdateData = [];
404
-			$.each(rows, function (key, value) {
405
-				if(value.viewCd === 'C') {
406
-					gridInsertData.push(value);
407
-				} else if(value.viewCd === 'U') {
408
-					gridUpdateData.push(value);
409
-				}
410
-			});
411
-			param['viewCd'] = 'U';
412
-			param['brandId'] = fn_make_user_info.get('brandId');
413
-			param['storeId'] = fn_make_user_info.get('storeId');
414
-			param['gridInsertData'] = gridInsertData;
415
-			param['gridUpdateData'] = gridUpdateData;
416
-			console.log(JSON.stringify(param));
417
-			var searhFn = function() {
418
-				listObj.grid.search();
419
-			};
420
-			fn_ajax_call(API_DETAIL_SAVE, JSON.stringify(param), searhFn, 'POST');
421
-		}
422 413
 	},
423 414
 	empty: {
424 415
 		init: function() {
@@ -445,7 +436,10 @@ let modifyObj = {
445 436
 			this.unload();
446 437
 			this.load(param);
447 438
 		},
439
+		prevRowId: null,
448 440
 		load: function(param) {
441
+			var _this = this;
442
+			console.log(param);
449 443
 			var option = {
450 444
 				gridId: STINFO06010_DETAIL_GRID_ID,
451 445
 				colModel: gridColModel.detail,
@@ -454,20 +448,121 @@ let modifyObj = {
454 448
 				url: DOMAIN + API_DETAIL_INFO,
455 449
 				loadComplete: function(data) {
456 450
 					console.log(data);
451
+					createObj.rows = data.gridRows;
457 452
 					itp_fn_grid_load_complete(data, STINFO06010_DETAIL_GRID_ID, false, 'number', 'STINFO06010', modifyObj.itp_STINFO06010_search, modifyObj.empty, true, data.gridRecords, true);
458 453
 				},
459
-				// onCelSelect: function(rowId, cellIdx, cellValue) {
460
-				// 	STINFO06010_GRID_LAST_ROW_ID = itp_fn_set_data_editable(rowId, cellIdx, STINFO06010_GRID_LAST_ROW_ID, STINFO06010_DETAIL_GRID_ID, ['itemId']);
461
-				// },
462
-				ondblClickRow : function (rowid, iRow, iCol) {
463
-					console.log('rowId ===> ' + rowid);
464
-					STINFO06010_GRID_LAST_ROW_ID = itp_fn_set_data_editable(rowid, iRow, STINFO06010_GRID_LAST_ROW_ID, STINFO06010_DETAIL_GRID_ID, ['itemId']);
465
-					$('#' + rowid + "_stddQty").blur(function(){
466
-						$(STINFO06010_DETAIL_GRID_ID).jqGrid('saveRow', rowid, true, 'clientArray');
467
-						if($(STINFO06010_DETAIL_GRID_ID).jqGrid('getRowData', rowid, 'viewCd') !== 'C') {
468
-							$(STINFO06010_DETAIL_GRID_ID).jqGrid('setRowData', rowid, {viewCd: 'U'});
454
+				onCellSelect: function(rowid, cellIdx, cellValue) {
455
+					if(fn_make_user_info.get('authTpCd') !== '50') {
456
+						STINFO06010_GRID_LAST_ROW_ID = itp_fn_set_data_editable(rowid, cellIdx, STINFO06010_GRID_LAST_ROW_ID, STINFO06010_DETAIL_GRID_ID, ['actionId']);
457
+					}
458
+				},
459
+				onPaging: function(action) {
460
+					itp_fn_grid_paging(STINFO06010_GRID_ID, action, param);
461
+				}
462
+			};
463
+			itp_fn_grid_make_remote(option);
464
+		},
465
+		clearData : function() {
466
+			$(STINFO06010_DETAIL_GRID_ID).jqGrid('clearGridData', true);
467
+			$(STINFO06010_DETAIL_GRID_LIST).find('.ui-jqgrid-bdiv').css('min-height', '100px');
468
+			$(STINFO06010_DETAIL_GRID_EMPTY).html(ITP_MSG_LOCALE.message.grid.noData);
469
+			$(STINFO06010_DETAIL_GRID_EMPTY).show();
470
+		},
471
+		unload : function() {
472
+			$.jgrid.gridUnload(STINFO06010_DETAIL_GRID_ID);
473
+		}
474
+	}
475
+};
476
+
477
+/*신규화면 Object*/
478
+let createObj = {
479
+	init: function () {
480
+		pageObj.switchScreen('ADD');
481
+		var param = $.param($('#ITP_FORM_STINFO06010_DETAIL').serializeObject());
482
+		this.grid.init(param);
483
+		this.button.init();
484
+	},
485
+	button: {
486
+		init: function() {
487
+			// 가맹점 조회 버튼 클릭
488
+			$('#ITP_BTN_STINFO06010_DETAIL_SEARCH_STORE').on('click', function() {
489
+				createObj.popup();
490
+			});
491
+			// 가맹점 텍스트 삭제 버튼 클릭
492
+			$('#ITP_BTN_STINFO06010_DETAIL_DELETE_STORE').on('click', function() {
493
+				$('#ITP_FORM_STINFO06010_DETAIL_BRAND_ID').val('');
494
+				$('#ITP_FORM_STINFO06010_DETAIL_STORE_ID').val('');
495
+				$('#ITP_FORM_STINFO06010_DETAIL_STORE_NM').val('');
496
+			});
497
+		},
498
+		cancel: function() {
499
+			listObj.grid.search();
500
+		},
501
+		save: function() {
502
+			const formId = '#ITP_FORM_STINFO06010_DETAIL';
503
+			var isValid = true;
504
+			if(pageObj.screenMode === 'ADD') {
505
+				isValid = itp_fn_is_valid(formId)
506
+			}
507
+			if (isValid) {
508
+				itp_fn_grid_save_rows(STINFO06010_DETAIL_GRID_ID);
509
+
510
+				var rows = $(STINFO06010_DETAIL_GRID_ID).getRowData();
511
+				let param = {};
512
+				// var gridInsertData = [];
513
+				var gridUpdateData = [];
514
+				var changeRows = createObj.changeRows(rows);
515
+				$.each(changeRows, function (index, item) {
516
+					if(pageObj.screenMode === 'ADD') {
517
+						item['contSttDt'] = $('#ITP_FORM_STINFO06010_DETAIL_FROM_DT').val();
518
+						item['contEndDt'] = $('#ITP_FORM_STINFO06010_DETAIL_TO_DT').val();
519
+						gridUpdateData.push(item);
520
+					} else {
521
+						if(item.viewCd === 'C' || item.viewCd === 'U') {
522
+							// 	gridInsertData.push(item);
523
+							// } else if(item.viewCd === 'U') {
524
+							gridUpdateData.push(item);
469 525
 						}
470
-					});
526
+					}
527
+				});
528
+				param['viewCd'] = 'U';
529
+				param['brandId'] = fn_make_user_info.get('brandId');
530
+				param['storeId'] = $('#ITP_FORM_STINFO06010_DETAIL_STORE_ID').val();
531
+				// param['gridInsertData'] = gridInsertData;
532
+				param['gridUpdateData'] = gridUpdateData;
533
+				console.log(JSON.stringify(param));
534
+				var searhFn = function() {
535
+					listObj.grid.search();
536
+				};
537
+				fn_ajax_call(API_DETAIL_SAVE, JSON.stringify(param), searhFn, 'POST');
538
+			}
539
+		}
540
+	},
541
+	grid: {
542
+		init: function (param) {
543
+			// 데이터 없을때
544
+			listObj.empty.push();
545
+			this.unload();
546
+			this.load(param);
547
+		},
548
+		rows: [],
549
+		prevRowId: null,
550
+		load: function(param) {
551
+			var _this = this;
552
+			console.log(param);
553
+			var option = {
554
+				gridId: STINFO06010_DETAIL_GRID_ID,
555
+				colModel: gridColModel.detail,
556
+				mtype: 'GET',
557
+				param: param,
558
+				url: DOMAIN + API_DETAIL_NEW,
559
+				loadComplete: function(data) {
560
+					console.log(data);
561
+					createObj.rows = data.gridRows;
562
+					itp_fn_grid_load_complete(data, STINFO06010_DETAIL_GRID_ID, false, 'number', 'STINFO06010', modifyObj.itp_STINFO06010_search, modifyObj.empty, true, data.gridRecords, true);
563
+				},
564
+				onCellSelect: function(rowid, cellIdx, cellValue) {
565
+					STINFO06010_GRID_LAST_ROW_ID = itp_fn_set_data_editable(rowid, cellIdx, STINFO06010_GRID_LAST_ROW_ID, STINFO06010_DETAIL_GRID_ID, ['actionId']);
471 566
 				},
472 567
 				onPaging: function(action) {
473 568
 					itp_fn_grid_paging(STINFO06010_GRID_ID, action, param);
@@ -484,5 +579,38 @@ let modifyObj = {
484 579
 		unload : function() {
485 580
 			$.jgrid.gridUnload(STINFO06010_DETAIL_GRID_ID);
486 581
 		}
582
+	},
583
+	popup: function() {
584
+		var popFn = function(rowDataPop) {
585
+			console.log(rowDataPop);
586
+			if(rowDataPop && rowDataPop.length > 0) {
587
+				$('#ITP_FORM_STINFO06010_DETAIL_BRAND_ID').val(rowDataPop[0].brandId);
588
+				$('#ITP_FORM_STINFO06010_DETAIL_STORE_ID').val(rowDataPop[0].storeId);
589
+				$('#ITP_FORM_STINFO06010_DETAIL_STORE_NM').val(rowDataPop[0].storeNm);
590
+			}
591
+		};
592
+		fn_call_popup('biz', 'BIZPOP_BRAND_STORE', '#ITP_ASIDE', popFn, null, 'S');
593
+	},
594
+	rows: [],
595
+	changeRows: function(gridRows) {
596
+		var modifyRows = [];
597
+		var chkColumns = ['unit', 'stddQty', 'curr', 'unitAmt', 'unitTargetCd'];
598
+		$.each(this.rows, function(index, item) {
599
+			var row = gridRows[index];
600
+			if(row.viewCd === 'C') {
601
+				modifyRows.push(item);
602
+			} else {
603
+				if(row.itemId === item.itemId) {
604
+					$.each(chkColumns, function(index, column) {
605
+						if(row[column].toString() !== item[column].toString()) {
606
+							row.viewCd = 'U';
607
+							modifyRows.push(row);
608
+							return false;
609
+						}
610
+					});
611
+				}
612
+			}
613
+		});
614
+		return modifyRows;
487 615
 	}
488 616
 };

+ 2 - 1
src/main/webapp/js/app/system/ITP_SYSTEM03010.js

@@ -70,7 +70,7 @@ require(['config'], function() {
70 70
 				param.gridInsertData = gridInsertData;
71 71
 				param.gridUpdateData = gridUpdateData;
72 72
 				param.gridDeleteData = gridDeleteData;
73
-				//console.log(JSON.stringify(param)); return;
73
+				console.log(param); return;
74 74
 				var searhFn = function() {
75 75
 					var keyword = {keyword: $('#ITP_KEYWORD_SYSTEM03010_INPUT').val()};
76 76
 					var param = $('#ITP_SYSTEM03010_ADV_SRH_FORM').serialize() + '&' + $.param(keyword);
@@ -266,6 +266,7 @@ var itp_fn_SYSTEM03010_detail_grid = {
266 266
 				SYSTEM03010_GRID_LAST_ROW_ID = itp_fn_set_data_editable(rowId, cellIdx, SYSTEM03010_GRID_LAST_ROW_ID, SYSTEM03010_GRID_ID, ['actionId']);
267 267
 		   	},
268 268
 			loadComplete: function(data) {
269
+				console.log(data);
269 270
 				itp_fn_grid_load_complete(data, SYSTEM03010_GRID_ID, false, undefined, 'SYSTEM03010');
270 271
 		    },
271 272
 		    loadError: function(jqXHR, textStatus, errorThrown) {

+ 8 - 1
src/main/webapp/mobile/js/app/main.js

@@ -48,9 +48,16 @@ var itp_fn_mobile_MAIN_MENU = {
48 48
 	},
49 49
 	topMenuMake: function() {
50 50
 		var _this = this;
51
+		var topMenuCnt = 0;
51 52
 		$.each(AUTH_MENU_LIST, function(key, value) {
52 53
 			if(value.topMenuNo === 200) {
53
-				var menuDIV = 	'<div class="manage col_4">' +
54
+				topMenuCnt++;
55
+			}
56
+		});
57
+		console.log(topMenuCnt);
58
+		$.each(AUTH_MENU_LIST, function(key, value) {
59
+			if(value.topMenuNo === 200) {
60
+				var menuDIV = 	'<div class="manage col_' + topMenuCnt + '">' +
54 61
 								'	<button data-top-menu="' + value.menuNo + '">' + value.menuNm + '</button>' +
55 62
 								'</div>';
56 63
 				$('.manage_btn_bar').append(menuDIV);