|
@@ -29,7 +29,7 @@ let ITP_FORM_ORDMNG03010_DETAIL_IS_WRITING = false;
|
29
|
29
|
|
30
|
30
|
/*API URL*/
|
31
|
31
|
let API_DELI_GRID_LIST = '/api/pomng/inoutmng/spply-deli-grid-list';// 목록
|
32
|
|
-let API_INFO_INV = '/api/pomng/inoutmng/info-inv'; // 상세
|
|
32
|
+let API_INFO_INV = '/api/pomng/inoutmng/init-spply-inv'; // 상세
|
33
|
33
|
let API_SAVE_SPPLY_INV = '/api/pomng/inoutmng/save-spply-inv';// 저장
|
34
|
34
|
let API_ITEM_CLASS_LEVEL= '/api/item/class-level-list'; //품목분류 level 검색
|
35
|
35
|
|
|
@@ -37,10 +37,16 @@ let API_ITEM_CLASS_LEVEL= '/api/item/class-level-list'; //품목분류 level
|
37
|
37
|
const gridColModel = {
|
38
|
38
|
list: [
|
39
|
39
|
|
|
40
|
+ {
|
|
41
|
+ index: 'Brand_ID', name: 'brandId',
|
|
42
|
+ label: ITP_MSG_LOCALE.label.brandId, //브랜드
|
|
43
|
+ width: '18', fixed: false, align: 'center',
|
|
44
|
+ sortable: false, hidden: true
|
|
45
|
+ },
|
40
|
46
|
{
|
41
|
47
|
index: 'Brand_Nm', name: 'brandNm',
|
42
|
48
|
label: ITP_MSG_LOCALE.label.brandNm, //브랜드
|
43
|
|
- width: '10', fixed: false, align: 'center',
|
|
49
|
+ width: '20', fixed: false, align: 'center',
|
44
|
50
|
sortable: false, hidden: false
|
45
|
51
|
},
|
46
|
52
|
{
|
|
@@ -51,25 +57,31 @@ const gridColModel = {
|
51
|
57
|
},
|
52
|
58
|
{
|
53
|
59
|
index: 'ITEM_ST_CD', name: 'dlvStCd',
|
54
|
|
- label: ITP_MSG_LOCALE.label.dlvStCd, //납품서상태
|
55
|
|
- width: '6', fixed: false, align: 'center',
|
|
60
|
+ label: '납품상태', //납품서상태
|
|
61
|
+ width: '12', fixed: false, align: 'center',
|
56
|
62
|
sortable: false, hidden: false
|
57
|
63
|
},
|
58
|
64
|
{
|
59
|
|
- index: 'poBsnsRegno', name: 'podrRegDt',
|
60
|
|
- label: ITP_MSG_LOCALE.label.podrRegDt, //수주일자
|
61
|
|
- width: '10', fixed: false, align: 'center',
|
|
65
|
+ index: 'PODR_REG_DT', name: 'podrRegDt',
|
|
66
|
+ label: '수주일자', //수주일자
|
|
67
|
+ width: '14', fixed: false, align: 'center',
|
62
|
68
|
sortable: false, hidden: false
|
63
|
69
|
},
|
64
|
70
|
{
|
65
|
71
|
index: 'PCH_ITEM_YN', name: 'dlvReqDt',
|
66
|
72
|
label: ITP_MSG_LOCALE.label.dlvReqDt, //납품요청일
|
67
|
|
- width: '10', fixed: false, align: 'center',
|
|
73
|
+ width: '14', fixed: false, align: 'center',
|
68
|
74
|
sortable: false, hidden: false
|
69
|
75
|
},
|
70
|
76
|
{
|
71
|
77
|
index: 'PCH_ITEM_YN', name: 'dlvSchDt',
|
72
|
78
|
label: ITP_MSG_LOCALE.label.dlvSchDt, //납품예정일
|
|
79
|
+ width: '14', fixed: false, align: 'center',
|
|
80
|
+ sortable: false, hidden: false
|
|
81
|
+ },
|
|
82
|
+ {
|
|
83
|
+ index: 'PCH_ITEM_YN', name: 'dlvCmpltDt',
|
|
84
|
+ label: ITP_MSG_LOCALE.label.dlvCmpltDt, //납품완료일
|
73
|
85
|
width: '10', fixed: false, align: 'center',
|
74
|
86
|
sortable: false, hidden: false
|
75
|
87
|
},
|
|
@@ -86,7 +98,7 @@ const gridColModel = {
|
86
|
98
|
sortable: false, hidden: false
|
87
|
99
|
},
|
88
|
100
|
{
|
89
|
|
- index: 'UNIT', name: 'podrQty',
|
|
101
|
+ index: 'PODR_QTY', name: 'podrQty',
|
90
|
102
|
label: ITP_MSG_LOCALE.label.podrQty, //수주수량
|
91
|
103
|
width: '6', fixed: false, align: 'center',
|
92
|
104
|
sortable: false, hidden: false
|
|
@@ -97,12 +109,24 @@ const gridColModel = {
|
97
|
109
|
width: '6', fixed: false, align: 'center',
|
98
|
110
|
sortable: false, hidden: false
|
99
|
111
|
},
|
|
112
|
+ {
|
|
113
|
+ index: 'UNIT', name: 'unit',
|
|
114
|
+ label: ITP_MSG_LOCALE.label.unit, //납품수량
|
|
115
|
+ width: '6', fixed: false, align: 'center',
|
|
116
|
+ sortable: false, hidden: false
|
|
117
|
+ },
|
100
|
118
|
{
|
101
|
119
|
index: 'PCH_ITEM_YN', name: 'unitAmt',
|
102
|
120
|
label: ITP_MSG_LOCALE.label.unitAmt, //납품금액
|
103
|
121
|
width: '6', fixed: false, align: 'center',
|
104
|
122
|
sortable: false, hidden: false
|
105
|
123
|
},
|
|
124
|
+ {
|
|
125
|
+ index: 'SALE_ITEM_YN', name: 'whsNm',
|
|
126
|
+ label: ITP_MSG_LOCALE.label.whsNm, //납품장소
|
|
127
|
+ width: '6', fixed: false, align: 'center',
|
|
128
|
+ sortable: false, hidden: false
|
|
129
|
+ },
|
106
|
130
|
{
|
107
|
131
|
index: 'PCH_ITEM_YN', name: 'dlvMgrNm',
|
108
|
132
|
label: ITP_MSG_LOCALE.label.dlvMgrNm, //납품담당자
|
|
@@ -158,6 +182,7 @@ let pageObj = {
|
158
|
182
|
this.ui.init();
|
159
|
183
|
this.event.init();
|
160
|
184
|
this.fileUpload();
|
|
185
|
+ this.action();
|
161
|
186
|
},
|
162
|
187
|
ui: {
|
163
|
188
|
init: function () {
|
|
@@ -186,6 +211,62 @@ let pageObj = {
|
186
|
211
|
ready: function() {
|
187
|
212
|
listObj.init();
|
188
|
213
|
}
|
|
214
|
+ },
|
|
215
|
+ action: function () {
|
|
216
|
+ var _this = this;
|
|
217
|
+ // 검색 납품장소
|
|
218
|
+ $('#ITP_FORM_ORDMNG03010_SSEARCH_SWHS_NM').on('click', function() {
|
|
219
|
+ _this.popup('SW');
|
|
220
|
+ });
|
|
221
|
+ // 검색 납품장소 텍스트 삭제 버튼 클릭
|
|
222
|
+ $('#ITP_FORM_ORDMNG03010_SDELETE_SWHS_NM').on('click', function() {
|
|
223
|
+ $('#ITP_FORM_ORDMNG03010_SEARCH_SWHS_NM').val('');
|
|
224
|
+ $('#ITP_FORM_ORDMNG03010_SEARCH_SWHS_ID').val('');
|
|
225
|
+
|
|
226
|
+ });
|
|
227
|
+ },
|
|
228
|
+ popup: function (arg) {
|
|
229
|
+ var popFn ;
|
|
230
|
+ // 팝업
|
|
231
|
+ if (arg == "SW") {
|
|
232
|
+ popFn = this.callback.searWhs;
|
|
233
|
+ }
|
|
234
|
+
|
|
235
|
+ const key = {brandId:fn_make_user_info.get('brandId'),storeId:fn_make_user_info.get('storeId')};
|
|
236
|
+ if (arg == "SW" ) {
|
|
237
|
+ fn_call_popup('biz', 'BIZPOP_WHS_LOCATION', '#ITP_ASIDE', popFn, key, 'S');
|
|
238
|
+ }
|
|
239
|
+
|
|
240
|
+
|
|
241
|
+ },
|
|
242
|
+ callback: {
|
|
243
|
+ searWhs: function(rowDataPop) {
|
|
244
|
+ if(rowDataPop) {
|
|
245
|
+ $('#ITP_FORM_ORDMNG03010_SEARCH_SWHS_NM').val(rowDataPop.whsNm);
|
|
246
|
+ $('#ITP_FORM_ORDMNG03010_SEARCH_SWHS_ID').val(rowDataPop.whsId);
|
|
247
|
+ }
|
|
248
|
+
|
|
249
|
+ },
|
|
250
|
+ searNWhs: function(rowDataPop) {
|
|
251
|
+ if(rowDataPop) {
|
|
252
|
+ $('#ITP_FORM_ORDMNG03010_NDETAIL_WHS_NM').val(rowDataPop.whsNm + " - " + rowDataPop.locationNm);
|
|
253
|
+ $('#ITP_FORM_ORDMNG03010_NDETAIL_WHS_ID').val(rowDataPop.whsId);
|
|
254
|
+ $('#ITP_FORM_ORDMNG03010_NDETAIL_LOCATION').val(rowDataPop.location);
|
|
255
|
+ }
|
|
256
|
+ },
|
|
257
|
+ poRej: function(rowDataPop) {
|
|
258
|
+ if(rowDataPop) {
|
|
259
|
+ console.log(rowDataPop);
|
|
260
|
+
|
|
261
|
+ if (rowDataPop.retVal == "Y") {
|
|
262
|
+ modifyObj.button.rejectSave(rowDataPop);
|
|
263
|
+ }
|
|
264
|
+
|
|
265
|
+
|
|
266
|
+ }
|
|
267
|
+ }
|
|
268
|
+
|
|
269
|
+
|
189
|
270
|
},
|
190
|
271
|
event: {
|
191
|
272
|
init: function () {
|
|
@@ -239,7 +320,8 @@ let pageObj = {
|
239
|
320
|
});
|
240
|
321
|
if(mode == 'LIST') { // 목록
|
241
|
322
|
$('#ITP_FORM_ORDMNG03010_SEARCH_SPPLY_ID').val(fn_make_user_info.get('userId'));
|
242
|
|
- $('#ITP_AJAX_ORDMNG03010_LIST_CONTAINER').show();
|
|
323
|
+ $('#ITP_FORM_ORDMNG03010_SEARCH_BRAND_ID').val(fn_make_user_info.get('brandId')); $('#ITP_AJAX_ORDMNG03010_LIST_CONTAINER').show();
|
|
324
|
+ $('#ITP_FORM_ORDMNG03010_SDELETE_SWHS_NM').show();
|
243
|
325
|
fn_show_btn_auth_array(['#ITP_BTN_ORDMNG03010_SRH', '#ITP_BTN_ORDMNG03010_POPUP']);
|
244
|
326
|
} else if(mode == 'ADD') { // 등록
|
245
|
327
|
$('#ITP_AJAX_ORDMNG03010_DETAIL_CONTAINER').show();
|