@dssp/supervision 1.0.0-alpha.24 → 1.0.0-alpha.26

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (70) hide show
  1. package/dist-client/graphql/building-inspection.js +28 -0
  2. package/dist-client/graphql/building-inspection.js.map +1 -1
  3. package/dist-client/pages/building-inspection/building-inspection-detail-checklist.d.ts +9 -0
  4. package/dist-client/pages/building-inspection/building-inspection-detail-checklist.js +114 -4
  5. package/dist-client/pages/building-inspection/building-inspection-detail-checklist.js.map +1 -1
  6. package/dist-client/pages/building-inspection/building-inspection-list.d.ts +6 -0
  7. package/dist-client/pages/building-inspection/building-inspection-list.js +47 -8
  8. package/dist-client/pages/building-inspection/building-inspection-list.js.map +1 -1
  9. package/dist-client/pages/building-inspection/component/image-preview-popup.d.ts +15 -0
  10. package/dist-client/pages/building-inspection/component/image-preview-popup.js +351 -0
  11. package/dist-client/pages/building-inspection/component/image-preview-popup.js.map +1 -0
  12. package/dist-client/pages/building-inspection/component/inspection-document/inspection-request-document.d.ts +20 -0
  13. package/dist-client/pages/building-inspection/component/inspection-document/inspection-request-document.js +436 -0
  14. package/dist-client/pages/building-inspection/component/inspection-document/inspection-request-document.js.map +1 -0
  15. package/dist-client/pages/building-inspection/component/inspection-document/inspection-result-notification.d.ts +27 -0
  16. package/dist-client/pages/building-inspection/component/inspection-document/inspection-result-notification.js +453 -0
  17. package/dist-client/pages/building-inspection/component/inspection-document/inspection-result-notification.js.map +1 -0
  18. package/dist-client/pages/building-inspection/component/inspection-document/name-list-upload-popup.d.ts +21 -0
  19. package/dist-client/pages/building-inspection/component/inspection-document/name-list-upload-popup.js +327 -0
  20. package/dist-client/pages/building-inspection/component/inspection-document/name-list-upload-popup.js.map +1 -0
  21. package/dist-client/pages/building-inspection/component/inspection-document/photo-album-popup.d.ts +27 -0
  22. package/dist-client/pages/building-inspection/component/inspection-document/photo-album-popup.js +401 -0
  23. package/dist-client/pages/building-inspection/component/inspection-document/photo-album-popup.js.map +1 -0
  24. package/dist-client/pages/building-inspection/component/photo-album-popup.d.ts +41 -0
  25. package/dist-client/pages/building-inspection/component/photo-album-popup.js +406 -0
  26. package/dist-client/pages/building-inspection/component/photo-album-popup.js.map +1 -0
  27. package/dist-client/pages/building-inspection/inspection-create-popup.js +17 -5
  28. package/dist-client/pages/building-inspection/inspection-create-popup.js.map +1 -1
  29. package/dist-client/pages/building-inspection-grid/building-inspection-grid-detail.d.ts +1 -0
  30. package/dist-client/pages/building-inspection-grid/building-inspection-grid-detail.js +47 -3
  31. package/dist-client/pages/building-inspection-grid/building-inspection-grid-detail.js.map +1 -1
  32. package/dist-client/pages/building-inspection-grid/component/grid-inspection-create-popup.js +8 -2
  33. package/dist-client/pages/building-inspection-grid/component/grid-inspection-create-popup.js.map +1 -1
  34. package/dist-client/pages/checklist/attachment-list-popup.d.ts +1 -0
  35. package/dist-client/pages/checklist/attachment-list-popup.js +244 -68
  36. package/dist-client/pages/checklist/attachment-list-popup.js.map +1 -1
  37. package/dist-client/pages/checklist/checklist-view.d.ts +5 -0
  38. package/dist-client/pages/checklist/checklist-view.js +64 -14
  39. package/dist-client/pages/checklist/checklist-view.js.map +1 -1
  40. package/dist-client/pages/checklist/file-preview-popup.js +0 -1
  41. package/dist-client/pages/checklist/file-preview-popup.js.map +1 -1
  42. package/dist-client/pages/checklist/inspection-tab-popup.js +3 -1
  43. package/dist-client/pages/checklist/inspection-tab-popup.js.map +1 -1
  44. package/dist-client/pages/checklist-template/checklist-template-list.js +1 -1
  45. package/dist-client/pages/checklist-template/checklist-template-list.js.map +1 -1
  46. package/dist-client/route.d.ts +1 -1
  47. package/dist-client/tsconfig.tsbuildinfo +1 -1
  48. package/dist-server/service/building-inspection/building-inspection-history.d.ts +1 -0
  49. package/dist-server/service/building-inspection/building-inspection-history.js +5 -0
  50. package/dist-server/service/building-inspection/building-inspection-history.js.map +1 -1
  51. package/dist-server/service/building-inspection/building-inspection-mutation.js +48 -21
  52. package/dist-server/service/building-inspection/building-inspection-mutation.js.map +1 -1
  53. package/dist-server/service/building-inspection/building-inspection-type.d.ts +6 -0
  54. package/dist-server/service/building-inspection/building-inspection-type.js +21 -0
  55. package/dist-server/service/building-inspection/building-inspection-type.js.map +1 -1
  56. package/dist-server/service/building-inspection/building-inspection.js +1 -1
  57. package/dist-server/service/building-inspection/building-inspection.js.map +1 -1
  58. package/dist-server/service/building-inspection/index.d.ts +1 -1
  59. package/dist-server/service/checklist/checklist-query.d.ts +6 -0
  60. package/dist-server/service/checklist/checklist-query.js +63 -0
  61. package/dist-server/service/checklist/checklist-query.js.map +1 -1
  62. package/dist-server/service/checklist/checklist.d.ts +20 -0
  63. package/dist-server/service/checklist/checklist.js +62 -1
  64. package/dist-server/service/checklist/checklist.js.map +1 -1
  65. package/dist-server/service/checklist-item/checklist-item-query.d.ts +1 -1
  66. package/dist-server/service/checklist-item/checklist-item-query.js +5 -3
  67. package/dist-server/service/checklist-item/checklist-item-query.js.map +1 -1
  68. package/dist-server/service/index.d.ts +1 -1
  69. package/dist-server/tsconfig.tsbuildinfo +1 -1
  70. package/package.json +2 -2
@@ -0,0 +1,436 @@
1
+ import { __decorate, __metadata } from "tslib";
2
+ import '@material/web/button/elevated-button.js';
3
+ import '@material/web/icon/icon.js';
4
+ import '@material/web/button/outlined-button.js';
5
+ import { css, html, LitElement } from 'lit';
6
+ import { customElement, property } from 'lit/decorators.js';
7
+ import { ScrollbarStyles } from '@operato/styles';
8
+ import './photo-album-popup';
9
+ export var InspectionMode;
10
+ (function (InspectionMode) {
11
+ InspectionMode["EDIT"] = "EDIT";
12
+ InspectionMode["VIEW"] = "VIEW";
13
+ })(InspectionMode || (InspectionMode = {}));
14
+ let InspectionRequestDocument = class InspectionRequestDocument extends LitElement {
15
+ constructor() {
16
+ super(...arguments);
17
+ this.checklist = {};
18
+ this.buildingInspection = {};
19
+ this.mode = InspectionMode.VIEW;
20
+ }
21
+ render() {
22
+ var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q, _r, _s, _t, _u, _v, _w, _x, _y;
23
+ const today = this._formatDate(new Date());
24
+ const requestDate = this._formatDate(new Date(this.buildingInspection.requestDate));
25
+ const attachmentCount = (_c = (_b = (_a = this.buildingInspection) === null || _a === void 0 ? void 0 : _a.checklist) === null || _b === void 0 ? void 0 : _b.checklistItems) === null || _c === void 0 ? void 0 : _c.reduce((acc, item) => {
26
+ return acc + item.checklistItemAttachmentCount;
27
+ }, 0);
28
+ return html `
29
+ <div class="document-container">
30
+ <div class="document-header">
31
+ <div class="document-title">검측요청서</div>
32
+ </div>
33
+
34
+ <div class="document-body">
35
+ <div class="date-section">${today}</div>
36
+
37
+ <div class="request-info">
38
+ <div class="recipient-section">
39
+ <div class="recipient-item">
40
+ <span class="recipient-label">문서 번호:</span>
41
+ <span>${((_d = this.checklist) === null || _d === void 0 ? void 0 : _d.inspectionRequestDocumentNo) || ''}</span>
42
+ </div>
43
+ <div class="recipient-item">
44
+ <span class="recipient-label">수신:</span>
45
+ <span>${(_h = (_g = (_f = (_e = this.buildingInspection) === null || _e === void 0 ? void 0 : _e.buildingLevel) === null || _f === void 0 ? void 0 : _f.building) === null || _g === void 0 ? void 0 : _g.buildingComplex) === null || _h === void 0 ? void 0 : _h.supervisoryCompany}</span>
46
+ </div>
47
+ </div>
48
+
49
+ <div style="margin: 15px 0;">다음과 같은 세부공종에 대하여 검측요청 하오니 검사 후 승인하여 주시 기 바랍니다.</div>
50
+
51
+ <table class="request-table">
52
+ <tr>
53
+ <th>위치 및 공종</th>
54
+ <td>${(((_j = this.checklist) === null || _j === void 0 ? void 0 : _j.location) || '') + ' - ' + (((_k = this.checklist) === null || _k === void 0 ? void 0 : _k.constructionType) || '')}</td>
55
+ </tr>
56
+ <tr>
57
+ <th>검측 부위</th>
58
+ <td>${((_m = (_l = this.checklist) === null || _l === void 0 ? void 0 : _l.inspectionParts) === null || _m === void 0 ? void 0 : _m.join(', ')) || ''}</td>
59
+ </tr>
60
+ <tr>
61
+ <th>검측 요구일시</th>
62
+ <td>${requestDate}</td>
63
+ </tr>
64
+ <tr>
65
+ <th>검측 사항</th>
66
+ <td>
67
+ ${this.mode === InspectionMode.EDIT
68
+ ? html `
69
+ <input
70
+ type="text"
71
+ name="memo"
72
+ class="inspection-memo-input"
73
+ .value=${((_o = this.buildingInspection) === null || _o === void 0 ? void 0 : _o.memo) || ''}
74
+ @input=${this._onInspectionMemoChange}
75
+ placeholder="검측사항을 입력하세요."
76
+ />
77
+ `
78
+ : html ` <div class="inspection-memo-text">${(_p = this.buildingInspection) === null || _p === void 0 ? void 0 : _p.memo}</div> `}
79
+ </td>
80
+ </tr>
81
+ </table>
82
+ </div>
83
+
84
+ <div class="document-footer">
85
+ <div class="attachment-section">
86
+ <div class="attachment-title">첨부 파일</div>
87
+ <div class="attachment-list">
88
+ <div class="attachment-item">시공자의 검측 체크리스트</div>
89
+ ${this.mode === InspectionMode.EDIT
90
+ ? html `
91
+ <div class="attachment-item upload">
92
+ 실명부
93
+ <md-outlined-button @click=${this._onNameListUpload.bind(this)}>
94
+ ${((_q = this.checklist) === null || _q === void 0 ? void 0 : _q.nameListAttachment) ? '다시 업로드' : '업로드'}
95
+ </md-outlined-button>
96
+ ${((_r = this.checklist) === null || _r === void 0 ? void 0 : _r.nameListAttachment) ? html `<span>(업로드 완료)</span>` : ''}
97
+ </div>
98
+ `
99
+ : ((_s = this.checklist) === null || _s === void 0 ? void 0 : _s.nameListAttachment)
100
+ ? html `<div class="attachment-item">실명부</div>`
101
+ : ''}
102
+ ${attachmentCount > 0 ? html `<div class="attachment-item">첨부 사진 ${attachmentCount}개</div>` : ''}
103
+ </div>
104
+ </div>
105
+
106
+ <div class="signature-section">
107
+ <div class="signature-box">
108
+ <div class="signature-title">공종별 시공 관리자</div>
109
+ <div class="signature-name">${(_u = (_t = this.checklist) === null || _t === void 0 ? void 0 : _t.taskConstructor) === null || _u === void 0 ? void 0 : _u.name}</div>
110
+ <div class="signature-container">
111
+ ${((_v = this.checklist) === null || _v === void 0 ? void 0 : _v.taskConstructorSignature)
112
+ ? html `<img class="signature-image" src="${this.checklist.taskConstructorSignature}" alt="서명" />`
113
+ : ''}
114
+ </div>
115
+ </div>
116
+ <div class="signature-box">
117
+ <div class="signature-title">총괄 시공 책임자</div>
118
+ <div class="signature-name">${(_x = (_w = this.checklist) === null || _w === void 0 ? void 0 : _w.overallConstructor) === null || _x === void 0 ? void 0 : _x.name}</div>
119
+ <div class="signature-container">
120
+ ${((_y = this.checklist) === null || _y === void 0 ? void 0 : _y.overallConstructorSignature)
121
+ ? html `<img class="signature-image" src="${this.checklist.overallConstructorSignature}" alt="서명" />`
122
+ : ''}
123
+ </div>
124
+ </div>
125
+ </div>
126
+ </div>
127
+ </div>
128
+ </div>
129
+
130
+ ${this.mode === InspectionMode.EDIT
131
+ ? html `
132
+ <div class="button-container">
133
+ <md-elevated-button @click=${this._onConfirm}> 확인 </md-elevated-button>
134
+ </div>
135
+ `
136
+ : ''}
137
+ `;
138
+ }
139
+ _formatDate(date) {
140
+ return `${date.getFullYear()}. ${String(date.getMonth() + 1).padStart(2, '0')}. ${String(date.getDate()).padStart(2, '0')}.`;
141
+ }
142
+ _onInspectionMemoChange(e) {
143
+ const target = e.target;
144
+ this.buildingInspection = Object.assign(Object.assign({}, this.buildingInspection), { memo: target.value });
145
+ // 부모 컴포넌트에 변경사항 전달
146
+ this.dispatchEvent(new CustomEvent('inspection-memo-change', {
147
+ detail: { memo: target.value },
148
+ bubbles: true
149
+ }));
150
+ }
151
+ // 실명부 업로드
152
+ _onNameListUpload() {
153
+ const input = document.createElement('input');
154
+ input.type = 'file';
155
+ input.accept = '.pdf,.doc,.docx,.jpg,.jpeg,.png';
156
+ input.onchange = (e) => {
157
+ const file = e.target.files[0];
158
+ if (file) {
159
+ // checklist에 파일과 업로드 플래그 저장
160
+ this.checklist = Object.assign(Object.assign({}, this.checklist), { nameListAttachment: file, isNameListAttachmentUploaded: true });
161
+ // 부모 컴포넌트에 변경사항 알림
162
+ this.dispatchEvent(new CustomEvent('name-list-file-selected', { detail: { file } }));
163
+ this.requestUpdate();
164
+ }
165
+ };
166
+ input.click();
167
+ }
168
+ // 확인 버튼
169
+ _onConfirm() {
170
+ this.dispatchEvent(new CustomEvent('popup-close', { bubbles: true }));
171
+ history.back();
172
+ }
173
+ };
174
+ InspectionRequestDocument.styles = [
175
+ ScrollbarStyles,
176
+ css `
177
+ :host {
178
+ display: block;
179
+ padding: 20px;
180
+ font-family: 'Noto Sans KR', sans-serif;
181
+ line-height: 1.4;
182
+ overflow-y: auto;
183
+ }
184
+
185
+ .document-container {
186
+ max-width: 800px;
187
+ margin: 0 auto;
188
+ background: white;
189
+ border: 2px solid #333;
190
+ }
191
+
192
+ .document-header {
193
+ text-align: center;
194
+ padding: 15px;
195
+ border-bottom: 1px solid #333;
196
+ }
197
+
198
+ .document-title {
199
+ font-size: 18px;
200
+ font-weight: bold;
201
+ margin-bottom: 10px;
202
+ }
203
+
204
+ .document-body {
205
+ padding: 20px;
206
+ }
207
+
208
+ .request-info {
209
+ margin-bottom: 20px;
210
+ }
211
+
212
+ .request-table {
213
+ width: 100%;
214
+ border-collapse: collapse;
215
+ margin-bottom: 20px;
216
+ }
217
+
218
+ .request-table th,
219
+ .request-table td {
220
+ border: 1px solid #333;
221
+ padding: 8px;
222
+ text-align: left;
223
+ }
224
+
225
+ .request-table th {
226
+ background-color: #f5f5f5;
227
+ font-weight: bold;
228
+ width: 120px;
229
+ }
230
+
231
+ .inspection-items {
232
+ margin: 20px 0;
233
+ }
234
+
235
+ .inspection-items textarea {
236
+ width: 100%;
237
+ min-height: 100px;
238
+ border: 1px solid #ddd;
239
+ padding: 10px;
240
+ font-family: inherit;
241
+ resize: vertical;
242
+ }
243
+
244
+ .signature-section {
245
+ display: flex;
246
+ flex-direction: column;
247
+ align-items: flex-end;
248
+ gap: 15px;
249
+ }
250
+
251
+ .signature-box {
252
+ display: flex;
253
+ align-items: center;
254
+ gap: 15px;
255
+ text-align: right;
256
+ }
257
+
258
+ .signature-title {
259
+ font-size: 14px;
260
+ font-weight: bold;
261
+ color: #333;
262
+ min-width: 120px;
263
+ }
264
+
265
+ .signature-name {
266
+ font-size: 14px;
267
+ color: #333;
268
+ }
269
+
270
+ .signature-container {
271
+ position: relative;
272
+ min-width: 100px;
273
+ min-height: 60px;
274
+ display: flex;
275
+ align-items: center;
276
+ justify-content: center;
277
+ }
278
+
279
+ .signature-container::after {
280
+ content: '(인)';
281
+ position: absolute;
282
+ bottom: 5px;
283
+ right: 5px;
284
+ font-size: 12px;
285
+ color: #333;
286
+ font-weight: bold;
287
+ z-index: 2;
288
+ }
289
+
290
+ .signature-image {
291
+ max-width: 140px;
292
+ max-height: 60px;
293
+ width: auto;
294
+ height: auto;
295
+ }
296
+
297
+ .attachment-section {
298
+ margin-top: 30px;
299
+ margin-bottom: 30px;
300
+ }
301
+
302
+ .attachment-title {
303
+ font-weight: bold;
304
+ font-size: 14px;
305
+ color: #333;
306
+ margin-bottom: 10px;
307
+ display: flex;
308
+ align-items: center;
309
+ gap: 8px;
310
+ }
311
+
312
+ .attachment-list {
313
+ margin-left: 30px;
314
+ }
315
+
316
+ .attachment-item {
317
+ margin-bottom: 5px;
318
+ color: #2196f3;
319
+ font-size: 14px;
320
+ line-height: 1.5;
321
+ }
322
+
323
+ .attachment-item.upload {
324
+ display: flex;
325
+ align-items: center;
326
+ gap: 10px;
327
+ }
328
+
329
+ .attachment-item.upload md-outlined-button {
330
+ --md-outlined-button-container-height: 24px;
331
+ --md-outlined-button-label-text-size: 12px;
332
+ --md-outlined-button-outline-color: #666;
333
+ --md-outlined-button-label-text-color: #666;
334
+ }
335
+
336
+ .attachment-item.upload span {
337
+ color: #666;
338
+ font-size: 12px;
339
+ }
340
+
341
+ .attachment-icon {
342
+ display: none;
343
+ }
344
+
345
+ .date-section {
346
+ text-align: right;
347
+ margin-bottom: 20px;
348
+ font-size: 14px;
349
+ }
350
+
351
+ .form-row {
352
+ display: flex;
353
+ align-items: flex-start;
354
+ margin-bottom: 10px;
355
+ }
356
+
357
+ .form-label {
358
+ font-weight: bold;
359
+ width: 100px;
360
+ margin-right: 10px;
361
+ }
362
+
363
+ .recipient-section {
364
+ margin-bottom: 30px;
365
+ }
366
+
367
+ .recipient-item {
368
+ display: flex;
369
+ margin-bottom: 5px;
370
+ }
371
+
372
+ .recipient-label {
373
+ font-weight: bold;
374
+ margin-right: 18px;
375
+ }
376
+
377
+ .inspection-memo-input {
378
+ width: 100%;
379
+ max-width: -webkit-fill-available;
380
+ height: 40px;
381
+ border: 1px solid #ddd;
382
+ padding: 10px;
383
+ font-size: 15px;
384
+ border-radius: 5px;
385
+ }
386
+
387
+ .inspection-memo-text {
388
+ padding: 10px;
389
+ font-size: 15px;
390
+ color: #495057;
391
+ border: 1px solid #e9ecef;
392
+ border-radius: 5px;
393
+ min-height: 20px;
394
+ }
395
+
396
+ .button-container {
397
+ display: flex;
398
+ justify-content: center;
399
+ margin-top: 20px;
400
+ padding: 15px 0;
401
+ border-top: 1px solid #ddd;
402
+ }
403
+
404
+ .button-container md-elevated-button {
405
+ background-color: #3498db;
406
+ color: white;
407
+ padding: 12px 30px;
408
+ font-size: 16px;
409
+ font-weight: bold;
410
+ border-radius: 8px;
411
+ }
412
+
413
+ .document-footer {
414
+ display: flex;
415
+ justify-content: space-between;
416
+ align-items: center;
417
+ }
418
+ `
419
+ ];
420
+ __decorate([
421
+ property({ type: Object }),
422
+ __metadata("design:type", Object)
423
+ ], InspectionRequestDocument.prototype, "checklist", void 0);
424
+ __decorate([
425
+ property({ type: Object }),
426
+ __metadata("design:type", Object)
427
+ ], InspectionRequestDocument.prototype, "buildingInspection", void 0);
428
+ __decorate([
429
+ property({ type: String }),
430
+ __metadata("design:type", String)
431
+ ], InspectionRequestDocument.prototype, "mode", void 0);
432
+ InspectionRequestDocument = __decorate([
433
+ customElement('inspection-request-document')
434
+ ], InspectionRequestDocument);
435
+ export { InspectionRequestDocument };
436
+ //# sourceMappingURL=inspection-request-document.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"inspection-request-document.js","sourceRoot":"","sources":["../../../../../client/pages/building-inspection/component/inspection-document/inspection-request-document.ts"],"names":[],"mappings":";AAAA,OAAO,yCAAyC,CAAA;AAChD,OAAO,4BAA4B,CAAA;AACnC,OAAO,yCAAyC,CAAA;AAEhD,OAAO,EAAE,GAAG,EAAE,IAAI,EAAE,UAAU,EAAE,MAAM,KAAK,CAAA;AAC3C,OAAO,EAAE,aAAa,EAAE,QAAQ,EAAE,MAAM,mBAAmB,CAAA;AAC3D,OAAO,EAAE,eAAe,EAAE,MAAM,iBAAiB,CAAA;AAIjD,OAAO,qBAAqB,CAAA;AAE5B,MAAM,CAAN,IAAY,cAGX;AAHD,WAAY,cAAc;IACxB,+BAAa,CAAA;IACb,+BAAa,CAAA;AACf,CAAC,EAHW,cAAc,KAAd,cAAc,QAGzB;AAGM,IAAM,yBAAyB,GAA/B,MAAM,yBAA0B,SAAQ,UAAU;IAAlD;;QAwPuB,cAAS,GAAQ,EAAE,CAAA;QACnB,uBAAkB,GAAQ,EAAE,CAAA;QAC5B,SAAI,GAAmB,cAAc,CAAC,IAAI,CAAA;IAsKxE,CAAC;IApKC,MAAM;;QACJ,MAAM,KAAK,GAAG,IAAI,CAAC,WAAW,CAAC,IAAI,IAAI,EAAE,CAAC,CAAA;QAC1C,MAAM,WAAW,GAAG,IAAI,CAAC,WAAW,CAAC,IAAI,IAAI,CAAC,IAAI,CAAC,kBAAkB,CAAC,WAAW,CAAC,CAAC,CAAA;QACnF,MAAM,eAAe,GAAG,MAAA,MAAA,MAAA,IAAI,CAAC,kBAAkB,0CAAE,SAAS,0CAAE,cAAc,0CAAE,MAAM,CAAC,CAAC,GAAG,EAAE,IAAI,EAAE,EAAE;YAC/F,OAAO,GAAG,GAAG,IAAI,CAAC,4BAA4B,CAAA;QAChD,CAAC,EAAE,CAAC,CAAC,CAAA;QAEL,OAAO,IAAI,CAAA;;;;;;;sCAOuB,KAA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;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;KAkPF;CACF,AArPY,CAqPZ;AAE2B;IAA3B,QAAQ,CAAC,EAAE,IAAI,EAAE,MAAM,EAAE,CAAC;;4DAAoB;AACnB;IAA3B,QAAQ,CAAC,EAAE,IAAI,EAAE,MAAM,EAAE,CAAC;;qEAA6B;AAC5B;IAA3B,QAAQ,CAAC,EAAE,IAAI,EAAE,MAAM,EAAE,CAAC;;uDAA2C;AA1P3D,yBAAyB;IADrC,aAAa,CAAC,6BAA6B,CAAC;GAChC,yBAAyB,CAgarC","sourcesContent":["import '@material/web/button/elevated-button.js'\nimport '@material/web/icon/icon.js'\nimport '@material/web/button/outlined-button.js'\n\nimport { css, html, LitElement } from 'lit'\nimport { customElement, property } from 'lit/decorators.js'\nimport { ScrollbarStyles } from '@operato/styles'\nimport { openPopup } from '@operato/layout'\nimport { client } from '@operato/graphql'\nimport gql from 'graphql-tag'\nimport './photo-album-popup'\n\nexport enum InspectionMode {\n EDIT = 'EDIT',\n VIEW = 'VIEW'\n}\n\n@customElement('inspection-request-document')\nexport class InspectionRequestDocument extends LitElement {\n static styles = [\n ScrollbarStyles,\n css`\n :host {\n display: block;\n padding: 20px;\n font-family: 'Noto Sans KR', sans-serif;\n line-height: 1.4;\n overflow-y: auto;\n }\n\n .document-container {\n max-width: 800px;\n margin: 0 auto;\n background: white;\n border: 2px solid #333;\n }\n\n .document-header {\n text-align: center;\n padding: 15px;\n border-bottom: 1px solid #333;\n }\n\n .document-title {\n font-size: 18px;\n font-weight: bold;\n margin-bottom: 10px;\n }\n\n .document-body {\n padding: 20px;\n }\n\n .request-info {\n margin-bottom: 20px;\n }\n\n .request-table {\n width: 100%;\n border-collapse: collapse;\n margin-bottom: 20px;\n }\n\n .request-table th,\n .request-table td {\n border: 1px solid #333;\n padding: 8px;\n text-align: left;\n }\n\n .request-table th {\n background-color: #f5f5f5;\n font-weight: bold;\n width: 120px;\n }\n\n .inspection-items {\n margin: 20px 0;\n }\n\n .inspection-items textarea {\n width: 100%;\n min-height: 100px;\n border: 1px solid #ddd;\n padding: 10px;\n font-family: inherit;\n resize: vertical;\n }\n\n .signature-section {\n display: flex;\n flex-direction: column;\n align-items: flex-end;\n gap: 15px;\n }\n\n .signature-box {\n display: flex;\n align-items: center;\n gap: 15px;\n text-align: right;\n }\n\n .signature-title {\n font-size: 14px;\n font-weight: bold;\n color: #333;\n min-width: 120px;\n }\n\n .signature-name {\n font-size: 14px;\n color: #333;\n }\n\n .signature-container {\n position: relative;\n min-width: 100px;\n min-height: 60px;\n display: flex;\n align-items: center;\n justify-content: center;\n }\n\n .signature-container::after {\n content: '(인)';\n position: absolute;\n bottom: 5px;\n right: 5px;\n font-size: 12px;\n color: #333;\n font-weight: bold;\n z-index: 2;\n }\n\n .signature-image {\n max-width: 140px;\n max-height: 60px;\n width: auto;\n height: auto;\n }\n\n .attachment-section {\n margin-top: 30px;\n margin-bottom: 30px;\n }\n\n .attachment-title {\n font-weight: bold;\n font-size: 14px;\n color: #333;\n margin-bottom: 10px;\n display: flex;\n align-items: center;\n gap: 8px;\n }\n\n .attachment-list {\n margin-left: 30px;\n }\n\n .attachment-item {\n margin-bottom: 5px;\n color: #2196f3;\n font-size: 14px;\n line-height: 1.5;\n }\n\n .attachment-item.upload {\n display: flex;\n align-items: center;\n gap: 10px;\n }\n\n .attachment-item.upload md-outlined-button {\n --md-outlined-button-container-height: 24px;\n --md-outlined-button-label-text-size: 12px;\n --md-outlined-button-outline-color: #666;\n --md-outlined-button-label-text-color: #666;\n }\n\n .attachment-item.upload span {\n color: #666;\n font-size: 12px;\n }\n\n .attachment-icon {\n display: none;\n }\n\n .date-section {\n text-align: right;\n margin-bottom: 20px;\n font-size: 14px;\n }\n\n .form-row {\n display: flex;\n align-items: flex-start;\n margin-bottom: 10px;\n }\n\n .form-label {\n font-weight: bold;\n width: 100px;\n margin-right: 10px;\n }\n\n .recipient-section {\n margin-bottom: 30px;\n }\n\n .recipient-item {\n display: flex;\n margin-bottom: 5px;\n }\n\n .recipient-label {\n font-weight: bold;\n margin-right: 18px;\n }\n\n .inspection-memo-input {\n width: 100%;\n max-width: -webkit-fill-available;\n height: 40px;\n border: 1px solid #ddd;\n padding: 10px;\n font-size: 15px;\n border-radius: 5px;\n }\n\n .inspection-memo-text {\n padding: 10px;\n font-size: 15px;\n color: #495057;\n border: 1px solid #e9ecef;\n border-radius: 5px;\n min-height: 20px;\n }\n\n .button-container {\n display: flex;\n justify-content: center;\n margin-top: 20px;\n padding: 15px 0;\n border-top: 1px solid #ddd;\n }\n\n .button-container md-elevated-button {\n background-color: #3498db;\n color: white;\n padding: 12px 30px;\n font-size: 16px;\n font-weight: bold;\n border-radius: 8px;\n }\n\n .document-footer {\n display: flex;\n justify-content: space-between;\n align-items: center;\n }\n `\n ]\n\n @property({ type: Object }) checklist: any = {}\n @property({ type: Object }) buildingInspection: any = {}\n @property({ type: String }) mode: InspectionMode = InspectionMode.VIEW\n\n render() {\n const today = this._formatDate(new Date())\n const requestDate = this._formatDate(new Date(this.buildingInspection.requestDate))\n const attachmentCount = this.buildingInspection?.checklist?.checklistItems?.reduce((acc, item) => {\n return acc + item.checklistItemAttachmentCount\n }, 0)\n\n return html`\n <div class=\"document-container\">\n <div class=\"document-header\">\n <div class=\"document-title\">검측요청서</div>\n </div>\n\n <div class=\"document-body\">\n <div class=\"date-section\">${today}</div>\n\n <div class=\"request-info\">\n <div class=\"recipient-section\">\n <div class=\"recipient-item\">\n <span class=\"recipient-label\">문서 번호:</span>\n <span>${this.checklist?.inspectionRequestDocumentNo || ''}</span>\n </div>\n <div class=\"recipient-item\">\n <span class=\"recipient-label\">수신:</span>\n <span>${this.buildingInspection?.buildingLevel?.building?.buildingComplex?.supervisoryCompany}</span>\n </div>\n </div>\n\n <div style=\"margin: 15px 0;\">다음과 같은 세부공종에 대하여 검측요청 하오니 검사 후 승인하여 주시 기 바랍니다.</div>\n\n <table class=\"request-table\">\n <tr>\n <th>위치 및 공종</th>\n <td>${(this.checklist?.location || '') + ' - ' + (this.checklist?.constructionType || '')}</td>\n </tr>\n <tr>\n <th>검측 부위</th>\n <td>${this.checklist?.inspectionParts?.join(', ') || ''}</td>\n </tr>\n <tr>\n <th>검측 요구일시</th>\n <td>${requestDate}</td>\n </tr>\n <tr>\n <th>검측 사항</th>\n <td>\n ${this.mode === InspectionMode.EDIT\n ? html`\n <input\n type=\"text\"\n name=\"memo\"\n class=\"inspection-memo-input\"\n .value=${this.buildingInspection?.memo || ''}\n @input=${this._onInspectionMemoChange}\n placeholder=\"검측사항을 입력하세요.\"\n />\n `\n : html` <div class=\"inspection-memo-text\">${this.buildingInspection?.memo}</div> `}\n </td>\n </tr>\n </table>\n </div>\n\n <div class=\"document-footer\">\n <div class=\"attachment-section\">\n <div class=\"attachment-title\">첨부 파일</div>\n <div class=\"attachment-list\">\n <div class=\"attachment-item\">시공자의 검측 체크리스트</div>\n ${this.mode === InspectionMode.EDIT\n ? html`\n <div class=\"attachment-item upload\">\n 실명부\n <md-outlined-button @click=${this._onNameListUpload.bind(this)}>\n ${this.checklist?.nameListAttachment ? '다시 업로드' : '업로드'}\n </md-outlined-button>\n ${this.checklist?.nameListAttachment ? html`<span>(업로드 완료)</span>` : ''}\n </div>\n `\n : this.checklist?.nameListAttachment\n ? html`<div class=\"attachment-item\">실명부</div>`\n : ''}\n ${attachmentCount > 0 ? html`<div class=\"attachment-item\">첨부 사진 ${attachmentCount}개</div>` : ''}\n </div>\n </div>\n\n <div class=\"signature-section\">\n <div class=\"signature-box\">\n <div class=\"signature-title\">공종별 시공 관리자</div>\n <div class=\"signature-name\">${this.checklist?.taskConstructor?.name}</div>\n <div class=\"signature-container\">\n ${this.checklist?.taskConstructorSignature\n ? html`<img class=\"signature-image\" src=\"${this.checklist.taskConstructorSignature}\" alt=\"서명\" />`\n : ''}\n </div>\n </div>\n <div class=\"signature-box\">\n <div class=\"signature-title\">총괄 시공 책임자</div>\n <div class=\"signature-name\">${this.checklist?.overallConstructor?.name}</div>\n <div class=\"signature-container\">\n ${this.checklist?.overallConstructorSignature\n ? html`<img class=\"signature-image\" src=\"${this.checklist.overallConstructorSignature}\" alt=\"서명\" />`\n : ''}\n </div>\n </div>\n </div>\n </div>\n </div>\n </div>\n\n ${this.mode === InspectionMode.EDIT\n ? html`\n <div class=\"button-container\">\n <md-elevated-button @click=${this._onConfirm}> 확인 </md-elevated-button>\n </div>\n `\n : ''}\n `\n }\n\n private _formatDate(date: Date): string {\n return `${date.getFullYear()}. ${String(date.getMonth() + 1).padStart(2, '0')}. ${String(date.getDate()).padStart(2, '0')}.`\n }\n\n private _onInspectionMemoChange(e: Event) {\n const target = e.target as HTMLInputElement\n this.buildingInspection = { ...this.buildingInspection, memo: target.value }\n\n // 부모 컴포넌트에 변경사항 전달\n this.dispatchEvent(\n new CustomEvent('inspection-memo-change', {\n detail: { memo: target.value },\n bubbles: true\n })\n )\n }\n\n // 실명부 업로드\n private _onNameListUpload() {\n const input = document.createElement('input')\n input.type = 'file'\n input.accept = '.pdf,.doc,.docx,.jpg,.jpeg,.png'\n input.onchange = (e: any) => {\n const file = e.target.files[0]\n if (file) {\n // checklist에 파일과 업로드 플래그 저장\n this.checklist = {\n ...this.checklist,\n nameListAttachment: file,\n isNameListAttachmentUploaded: true\n }\n\n // 부모 컴포넌트에 변경사항 알림\n this.dispatchEvent(new CustomEvent('name-list-file-selected', { detail: { file } }))\n this.requestUpdate()\n }\n }\n input.click()\n }\n\n // 확인 버튼\n private _onConfirm() {\n this.dispatchEvent(new CustomEvent('popup-close', { bubbles: true }))\n history.back()\n }\n}\n"]}
@@ -0,0 +1,27 @@
1
+ import '@material/web/button/elevated-button.js';
2
+ import '@material/web/icon/icon.js';
3
+ import '@material/web/radio/radio.js';
4
+ import '@material/web/textfield/outlined-text-field.js';
5
+ import { LitElement } from 'lit';
6
+ export declare enum InspectionResultStatus {
7
+ PASS = "PASS",// 합격
8
+ FAIL = "FAIL"
9
+ }
10
+ export declare enum InspectionResultType {
11
+ GENERAL = "GENERAL",// 일반
12
+ FOCUS = "FOCUS",// 중점
13
+ CONCEALED_WORK = "CONCEALED_WORK"
14
+ }
15
+ export declare class InspectionResultNotification extends LitElement {
16
+ static styles: import("lit").CSSResult[];
17
+ checklist: any;
18
+ buildingInspection: any;
19
+ project: any;
20
+ render(): import("lit-html").TemplateResult<1>;
21
+ private _formatDate;
22
+ private _getAttachmentCount;
23
+ private _getOverallResult;
24
+ private _onInspectionTypeChange;
25
+ private _onInstructionsChange;
26
+ private _onConfirm;
27
+ }