@dssp/project 0.0.2
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.
- package/CHANGELOG.md +8 -0
- package/assets/images/hatiolab-logo.png +0 -0
- package/assets/images/o-mark.png +0 -0
- package/assets/images/x-mark.png +0 -0
- package/client/bootstrap.ts +0 -0
- package/client/index.ts +0 -0
- package/client/pages/checklist/checklist-importer.ts +96 -0
- package/client/pages/checklist/checklist-list-page.ts +355 -0
- package/client/pages/lib/waether.ts +159 -0
- package/client/pages/project/ox-progress-circle.ts +133 -0
- package/client/pages/project/project-create-popup.ts +148 -0
- package/client/pages/project/project-detail.ts +618 -0
- package/client/pages/project/project-list.ts +354 -0
- package/client/pages/project/project-plan-management.ts +437 -0
- package/client/pages/project/project-schedule-list.ts +280 -0
- package/client/pages/project/project-schedule.ts +248 -0
- package/client/pages/project/project-setting-list.ts +298 -0
- package/client/pages/project/project-update.ts +797 -0
- package/client/pages/resource/resource-importer.ts +96 -0
- package/client/pages/resource/resource-list-page.ts +355 -0
- package/client/pages/task/task-importer.ts +96 -0
- package/client/pages/task/task-list-page.ts +355 -0
- package/client/route.ts +39 -0
- package/client/tsconfig.json +11 -0
- package/dist-client/bootstrap.d.ts +0 -0
- package/dist-client/bootstrap.js +2 -0
- package/dist-client/bootstrap.js.map +1 -0
- package/dist-client/index.d.ts +0 -0
- package/dist-client/index.js +2 -0
- package/dist-client/index.js.map +1 -0
- package/dist-client/pages/checklist/checklist-importer.d.ts +9 -0
- package/dist-client/pages/checklist/checklist-importer.js +100 -0
- package/dist-client/pages/checklist/checklist-importer.js.map +1 -0
- package/dist-client/pages/checklist/checklist-list-page.d.ts +62 -0
- package/dist-client/pages/checklist/checklist-list-page.js +331 -0
- package/dist-client/pages/checklist/checklist-list-page.js.map +1 -0
- package/dist-client/pages/lib/waether.d.ts +6 -0
- package/dist-client/pages/lib/waether.js +152 -0
- package/dist-client/pages/lib/waether.js.map +1 -0
- package/dist-client/pages/project/ox-progress-circle.d.ts +41 -0
- package/dist-client/pages/project/ox-progress-circle.js +182 -0
- package/dist-client/pages/project/ox-progress-circle.js.map +1 -0
- package/dist-client/pages/project/project-create-popup.d.ts +14 -0
- package/dist-client/pages/project/project-create-popup.js +153 -0
- package/dist-client/pages/project/project-create-popup.js.map +1 -0
- package/dist-client/pages/project/project-detail.d.ts +35 -0
- package/dist-client/pages/project/project-detail.js +617 -0
- package/dist-client/pages/project/project-detail.js.map +1 -0
- package/dist-client/pages/project/project-list.d.ts +88 -0
- package/dist-client/pages/project/project-list.js +303 -0
- package/dist-client/pages/project/project-list.js.map +1 -0
- package/dist-client/pages/project/project-plan-management.d.ts +27 -0
- package/dist-client/pages/project/project-plan-management.js +438 -0
- package/dist-client/pages/project/project-plan-management.js.map +1 -0
- package/dist-client/pages/project/project-schedule-list.d.ts +18 -0
- package/dist-client/pages/project/project-schedule-list.js +292 -0
- package/dist-client/pages/project/project-schedule-list.js.map +1 -0
- package/dist-client/pages/project/project-schedule.d.ts +23 -0
- package/dist-client/pages/project/project-schedule.js +256 -0
- package/dist-client/pages/project/project-schedule.js.map +1 -0
- package/dist-client/pages/project/project-setting-list.d.ts +23 -0
- package/dist-client/pages/project/project-setting-list.js +307 -0
- package/dist-client/pages/project/project-setting-list.js.map +1 -0
- package/dist-client/pages/project/project-update.d.ts +24 -0
- package/dist-client/pages/project/project-update.js +797 -0
- package/dist-client/pages/project/project-update.js.map +1 -0
- package/dist-client/pages/resource/resource-importer.d.ts +9 -0
- package/dist-client/pages/resource/resource-importer.js +100 -0
- package/dist-client/pages/resource/resource-importer.js.map +1 -0
- package/dist-client/pages/resource/resource-list-page.d.ts +62 -0
- package/dist-client/pages/resource/resource-list-page.js +331 -0
- package/dist-client/pages/resource/resource-list-page.js.map +1 -0
- package/dist-client/pages/task/task-importer.d.ts +9 -0
- package/dist-client/pages/task/task-importer.js +100 -0
- package/dist-client/pages/task/task-importer.js.map +1 -0
- package/dist-client/pages/task/task-list-page.d.ts +62 -0
- package/dist-client/pages/task/task-list-page.js +331 -0
- package/dist-client/pages/task/task-list-page.js.map +1 -0
- package/dist-client/route.d.ts +1 -0
- package/dist-client/route.js +32 -0
- package/dist-client/route.js.map +1 -0
- package/dist-client/tsconfig.tsbuildinfo +1 -0
- package/dist-server/controllers/index.js +1 -0
- package/dist-server/controllers/index.js.map +1 -0
- package/dist-server/controllers/project-to-excel.js +30 -0
- package/dist-server/controllers/project-to-excel.js.map +1 -0
- package/dist-server/index.js +6 -0
- package/dist-server/index.js.map +1 -0
- package/dist-server/middlewares/index.js +8 -0
- package/dist-server/middlewares/index.js.map +1 -0
- package/dist-server/routes.js +105 -0
- package/dist-server/routes.js.map +1 -0
- package/dist-server/service/check-item/check-item-mutation.js +129 -0
- package/dist-server/service/check-item/check-item-mutation.js.map +1 -0
- package/dist-server/service/check-item/check-item-query.js +86 -0
- package/dist-server/service/check-item/check-item-query.js.map +1 -0
- package/dist-server/service/check-item/check-item-type.js +69 -0
- package/dist-server/service/check-item/check-item-type.js.map +1 -0
- package/dist-server/service/check-item/check-item.js +84 -0
- package/dist-server/service/check-item/check-item.js.map +1 -0
- package/dist-server/service/check-item/index.js +9 -0
- package/dist-server/service/check-item/index.js.map +1 -0
- package/dist-server/service/checklist/checklist-mutation.js +129 -0
- package/dist-server/service/checklist/checklist-mutation.js.map +1 -0
- package/dist-server/service/checklist/checklist-query.js +86 -0
- package/dist-server/service/checklist/checklist-query.js.map +1 -0
- package/dist-server/service/checklist/checklist-type.js +69 -0
- package/dist-server/service/checklist/checklist-type.js.map +1 -0
- package/dist-server/service/checklist/checklist.js +120 -0
- package/dist-server/service/checklist/checklist.js.map +1 -0
- package/dist-server/service/checklist/index.js +9 -0
- package/dist-server/service/checklist/index.js.map +1 -0
- package/dist-server/service/index.js +36 -0
- package/dist-server/service/index.js.map +1 -0
- package/dist-server/service/project/index.js +11 -0
- package/dist-server/service/project/index.js.map +1 -0
- package/dist-server/service/project/project-mutation.js +190 -0
- package/dist-server/service/project/project-mutation.js.map +1 -0
- package/dist-server/service/project/project-query.js +143 -0
- package/dist-server/service/project/project-query.js.map +1 -0
- package/dist-server/service/project/project-type.js +106 -0
- package/dist-server/service/project/project-type.js.map +1 -0
- package/dist-server/service/project/project.js +146 -0
- package/dist-server/service/project/project.js.map +1 -0
- package/dist-server/service/resource/index.js +9 -0
- package/dist-server/service/resource/index.js.map +1 -0
- package/dist-server/service/resource/resource-mutation.js +129 -0
- package/dist-server/service/resource/resource-mutation.js.map +1 -0
- package/dist-server/service/resource/resource-query.js +86 -0
- package/dist-server/service/resource/resource-query.js.map +1 -0
- package/dist-server/service/resource/resource-type.js +69 -0
- package/dist-server/service/resource/resource-type.js.map +1 -0
- package/dist-server/service/resource/resource.js +62 -0
- package/dist-server/service/resource/resource.js.map +1 -0
- package/dist-server/service/task/index.js +9 -0
- package/dist-server/service/task/index.js.map +1 -0
- package/dist-server/service/task/task-mutation.js +129 -0
- package/dist-server/service/task/task-mutation.js.map +1 -0
- package/dist-server/service/task/task-query.js +86 -0
- package/dist-server/service/task/task-query.js.map +1 -0
- package/dist-server/service/task/task-type.js +69 -0
- package/dist-server/service/task/task-type.js.map +1 -0
- package/dist-server/service/task/task.js +106 -0
- package/dist-server/service/task/task.js.map +1 -0
- package/dist-server/tsconfig.tsbuildinfo +1 -0
- package/helps/management/alarm.md +160 -0
- package/helps/management/alter-video.md +160 -0
- package/helps/management/cctv.md +160 -0
- package/helps/management/device.md +160 -0
- package/helps/management/parking.md +160 -0
- package/helps/management/site.md +160 -0
- package/helps/management/sun-pnl.md +160 -0
- package/helps/project/checklist.md +160 -0
- package/helps/project/project.md +160 -0
- package/helps/project/resource.md +160 -0
- package/helps/project/task.md +160 -0
- package/package.json +38 -0
- package/server/controllers/index.ts +0 -0
- package/server/controllers/project-to-excel.ts +40 -0
- package/server/index.ts +3 -0
- package/server/middlewares/index.ts +3 -0
- package/server/routes.ts +108 -0
- package/server/service/check-item/check-item-mutation.ts +142 -0
- package/server/service/check-item/check-item-query.ts +56 -0
- package/server/service/check-item/check-item-type.ts +49 -0
- package/server/service/check-item/check-item.ts +74 -0
- package/server/service/check-item/index.ts +6 -0
- package/server/service/checklist/checklist-mutation.ts +142 -0
- package/server/service/checklist/checklist-query.ts +56 -0
- package/server/service/checklist/checklist-type.ts +49 -0
- package/server/service/checklist/checklist.ts +105 -0
- package/server/service/checklist/index.ts +6 -0
- package/server/service/index.ts +35 -0
- package/server/service/project/index.ts +8 -0
- package/server/service/project/project-mutation.ts +201 -0
- package/server/service/project/project-query.ts +103 -0
- package/server/service/project/project-type.ts +71 -0
- package/server/service/project/project.ts +131 -0
- package/server/service/resource/index.ts +6 -0
- package/server/service/resource/resource-mutation.ts +139 -0
- package/server/service/resource/resource-query.ts +56 -0
- package/server/service/resource/resource-type.ts +49 -0
- package/server/service/resource/resource.ts +56 -0
- package/server/service/task/index.ts +6 -0
- package/server/service/task/task-mutation.ts +136 -0
- package/server/service/task/task-query.ts +56 -0
- package/server/service/task/task-type.ts +49 -0
- package/server/service/task/task.ts +97 -0
- package/server/tsconfig.json +10 -0
- package/things-factory.config.js +20 -0
- package/translations/en.json +1 -0
- package/translations/ja.json +1 -0
- package/translations/ko.json +9 -0
- package/translations/ms.json +1 -0
- package/translations/zh.json +1 -0
|
@@ -0,0 +1,248 @@
|
|
|
1
|
+
import { PageView } from '@operato/shell'
|
|
2
|
+
import { PageLifecycle } from '@operato/shell/dist/src/app/pages/page-view'
|
|
3
|
+
import { css, html } from 'lit'
|
|
4
|
+
import { customElement, state } from 'lit/decorators.js'
|
|
5
|
+
import { ScopedElementsMixin } from '@open-wc/scoped-elements'
|
|
6
|
+
import { client } from '@operato/graphql'
|
|
7
|
+
import { notify } from '@operato/layout'
|
|
8
|
+
|
|
9
|
+
import gql from 'graphql-tag'
|
|
10
|
+
import { Building, Project } from './project-list'
|
|
11
|
+
import '@material/web/button/elevated-button.js'
|
|
12
|
+
import '@material/web/textfield/outlined-text-field.js'
|
|
13
|
+
import '@material/web/button/filled-button.js'
|
|
14
|
+
import '@material/web/button/outlined-button.js'
|
|
15
|
+
|
|
16
|
+
@customElement('project-schedule')
|
|
17
|
+
export class ProjectSchedule extends ScopedElementsMixin(PageView) {
|
|
18
|
+
static styles = [
|
|
19
|
+
css`
|
|
20
|
+
:host {
|
|
21
|
+
display: grid;
|
|
22
|
+
grid-template-rows: 75px auto;
|
|
23
|
+
color: #4e5055;
|
|
24
|
+
|
|
25
|
+
width: 100%;
|
|
26
|
+
background-color: #f7f7f7;
|
|
27
|
+
overflow-y: auto;
|
|
28
|
+
|
|
29
|
+
--grid-record-emphasized-background-color: red;
|
|
30
|
+
--grid-record-emphasized-color: yellow;
|
|
31
|
+
}
|
|
32
|
+
|
|
33
|
+
*[bold] {
|
|
34
|
+
font-weight: bold;
|
|
35
|
+
}
|
|
36
|
+
|
|
37
|
+
div[header] {
|
|
38
|
+
display: flex;
|
|
39
|
+
margin: 0px 20px;
|
|
40
|
+
|
|
41
|
+
h2 {
|
|
42
|
+
flex: 0.5;
|
|
43
|
+
color: #3f71a0;
|
|
44
|
+
}
|
|
45
|
+
|
|
46
|
+
div[button-container] {
|
|
47
|
+
display: flex;
|
|
48
|
+
align-items: center;
|
|
49
|
+
justify-content: end;
|
|
50
|
+
flex: 0.5;
|
|
51
|
+
|
|
52
|
+
md-elevated-button {
|
|
53
|
+
margin: 0px 3px;
|
|
54
|
+
|
|
55
|
+
--md-elevated-button-container-height: 35px;
|
|
56
|
+
--md-elevated-button-label-text-size: 16px;
|
|
57
|
+
--md-elevated-button-container-color: #0595e5;
|
|
58
|
+
|
|
59
|
+
--md-elevated-button-label-text-color: #fff;
|
|
60
|
+
--md-elevated-button-hover-label-text-color: #fff;
|
|
61
|
+
--md-elevated-button-pressed-label-text-color: #fff;
|
|
62
|
+
--md-elevated-button-focus-label-text-color: #fff;
|
|
63
|
+
--md-elevated-button-icon-color: #fff;
|
|
64
|
+
--md-elevated-button-hover-icon-color: #fff;
|
|
65
|
+
--md-elevated-button-pressed-icon-color: #fff;
|
|
66
|
+
--md-elevated-button-focus-icon-color: #fff;
|
|
67
|
+
}
|
|
68
|
+
}
|
|
69
|
+
}
|
|
70
|
+
|
|
71
|
+
div[body] {
|
|
72
|
+
display: flex;
|
|
73
|
+
flex-direction: column;
|
|
74
|
+
margin: 0px 25px 25px 25px;
|
|
75
|
+
gap: 15px;
|
|
76
|
+
|
|
77
|
+
h3 {
|
|
78
|
+
color: #2e79be;
|
|
79
|
+
font-size: 18px;
|
|
80
|
+
margin: 0px;
|
|
81
|
+
}
|
|
82
|
+
|
|
83
|
+
& > div {
|
|
84
|
+
display: flex;
|
|
85
|
+
border-radius: 5px;
|
|
86
|
+
}
|
|
87
|
+
|
|
88
|
+
div[chart-container] {
|
|
89
|
+
flex: 1;
|
|
90
|
+
flex-direction: column;
|
|
91
|
+
border: 1px solid #cccccc80;
|
|
92
|
+
|
|
93
|
+
div[chart] {
|
|
94
|
+
flex: 0.7;
|
|
95
|
+
background: #03a9f44d;
|
|
96
|
+
}
|
|
97
|
+
|
|
98
|
+
div[table] {
|
|
99
|
+
flex: 0.3;
|
|
100
|
+
background: #8fd170b8;
|
|
101
|
+
}
|
|
102
|
+
}
|
|
103
|
+
|
|
104
|
+
div[select-container] {
|
|
105
|
+
gap: 15px;
|
|
106
|
+
|
|
107
|
+
div[date] {
|
|
108
|
+
display: flex;
|
|
109
|
+
align-items: center;
|
|
110
|
+
justify-content: space-between;
|
|
111
|
+
background-color: #2ea4df1a;
|
|
112
|
+
border: 1px solid #2ea4df33;
|
|
113
|
+
border-radius: 5px;
|
|
114
|
+
gap: 12px;
|
|
115
|
+
padding: 12px 36px 12px 15px;
|
|
116
|
+
|
|
117
|
+
span[name] {
|
|
118
|
+
font-size: 16px;
|
|
119
|
+
font-weight: bold;
|
|
120
|
+
}
|
|
121
|
+
}
|
|
122
|
+
|
|
123
|
+
div[button] {
|
|
124
|
+
flex: 1;
|
|
125
|
+
border-radius: 5px;
|
|
126
|
+
border: 1px solid #cccccc80;
|
|
127
|
+
background-color: #fff;
|
|
128
|
+
}
|
|
129
|
+
}
|
|
130
|
+
}
|
|
131
|
+
`
|
|
132
|
+
]
|
|
133
|
+
|
|
134
|
+
get context() {
|
|
135
|
+
return {
|
|
136
|
+
title: '공정표'
|
|
137
|
+
}
|
|
138
|
+
}
|
|
139
|
+
|
|
140
|
+
private defaultProject = {
|
|
141
|
+
name: '',
|
|
142
|
+
buildingComplex: {
|
|
143
|
+
address: '',
|
|
144
|
+
area: 0,
|
|
145
|
+
constructionCompany: '',
|
|
146
|
+
clientCompany: '',
|
|
147
|
+
supervisoryCompany: '',
|
|
148
|
+
designCompany: '',
|
|
149
|
+
constructionType: '',
|
|
150
|
+
buildings: []
|
|
151
|
+
}
|
|
152
|
+
}
|
|
153
|
+
@state() projectId: string = ''
|
|
154
|
+
@state() project: Project = { ...this.defaultProject }
|
|
155
|
+
@state() selectedBuildingIdx: number = 0
|
|
156
|
+
|
|
157
|
+
render() {
|
|
158
|
+
return html`
|
|
159
|
+
<div header>
|
|
160
|
+
<h2>${this.project.name}</h2>
|
|
161
|
+
<div button-container>
|
|
162
|
+
<md-elevated-button href=${`project-update/${this.project.id}`}>
|
|
163
|
+
<md-icon slot="icon">assignment</md-icon>프로젝트 정보 수정
|
|
164
|
+
</md-elevated-button>
|
|
165
|
+
<md-elevated-button href=${`project-plan-management/${this.project.id}`}>
|
|
166
|
+
<md-icon slot="icon">description</md-icon>도면 관리
|
|
167
|
+
</md-elevated-button>
|
|
168
|
+
<md-elevated-button href=${`project-task-update/${this.project.id}`}>
|
|
169
|
+
<md-icon slot="icon">event_note</md-icon>공정표 관리
|
|
170
|
+
</md-elevated-button>
|
|
171
|
+
</div>
|
|
172
|
+
</div>
|
|
173
|
+
|
|
174
|
+
<div body>
|
|
175
|
+
<div chart-container>
|
|
176
|
+
<div chart>
|
|
177
|
+
<table></table>
|
|
178
|
+
</div>
|
|
179
|
+
<div table>
|
|
180
|
+
<table></table>
|
|
181
|
+
</div>
|
|
182
|
+
</div>
|
|
183
|
+
<div select-container>
|
|
184
|
+
<div date>
|
|
185
|
+
<span name>기간선택</span>
|
|
186
|
+
<div>
|
|
187
|
+
<input type="date" name="startDate" project .value=${this.project.startDate || ''} max="9999-12-31" />
|
|
188
|
+
~
|
|
189
|
+
<input type="date" name="startDate" project .value=${this.project.endDate || ''} max="9999-12-31" />
|
|
190
|
+
</div>
|
|
191
|
+
</div>
|
|
192
|
+
<div button></div>
|
|
193
|
+
</div>
|
|
194
|
+
</div>
|
|
195
|
+
`
|
|
196
|
+
}
|
|
197
|
+
|
|
198
|
+
async pageInitialized(lifecycle: PageLifecycle) {}
|
|
199
|
+
|
|
200
|
+
async pageUpdated(changes: any, lifecycle: PageLifecycle) {
|
|
201
|
+
if (this.active) {
|
|
202
|
+
this.projectId = lifecycle.resourceId || ''
|
|
203
|
+
await this.initProject(this.projectId)
|
|
204
|
+
}
|
|
205
|
+
}
|
|
206
|
+
|
|
207
|
+
async initProject(projectId: string = '') {
|
|
208
|
+
const response = await client.query({
|
|
209
|
+
query: gql`
|
|
210
|
+
query Project($id: String!) {
|
|
211
|
+
project(id: $id) {
|
|
212
|
+
id
|
|
213
|
+
name
|
|
214
|
+
buildingComplex {
|
|
215
|
+
id
|
|
216
|
+
planXScale
|
|
217
|
+
planYScale
|
|
218
|
+
buildings {
|
|
219
|
+
id
|
|
220
|
+
name
|
|
221
|
+
drawing {
|
|
222
|
+
id
|
|
223
|
+
name
|
|
224
|
+
}
|
|
225
|
+
buildingLevels {
|
|
226
|
+
id
|
|
227
|
+
floor
|
|
228
|
+
mainDrawing {
|
|
229
|
+
id
|
|
230
|
+
name
|
|
231
|
+
}
|
|
232
|
+
}
|
|
233
|
+
}
|
|
234
|
+
}
|
|
235
|
+
}
|
|
236
|
+
}
|
|
237
|
+
`,
|
|
238
|
+
variables: {
|
|
239
|
+
id: projectId
|
|
240
|
+
}
|
|
241
|
+
})
|
|
242
|
+
|
|
243
|
+
this.project = response.data?.project
|
|
244
|
+
this.selectedBuildingIdx = 0
|
|
245
|
+
|
|
246
|
+
console.log('init project : ', this.project)
|
|
247
|
+
}
|
|
248
|
+
}
|
|
@@ -0,0 +1,298 @@
|
|
|
1
|
+
import { PageView } from '@operato/shell'
|
|
2
|
+
import { css, html } from 'lit'
|
|
3
|
+
import { customElement, state } from 'lit/decorators.js'
|
|
4
|
+
import { ScopedElementsMixin } from '@open-wc/scoped-elements'
|
|
5
|
+
import { client } from '@operato/graphql'
|
|
6
|
+
import { openPopup } from '@operato/layout'
|
|
7
|
+
import '@material/web/button/elevated-button.js'
|
|
8
|
+
import '@material/web/button/outlined-button.js'
|
|
9
|
+
import '@material/web/progress/linear-progress.js'
|
|
10
|
+
import '@material/web/textfield/filled-text-field.js'
|
|
11
|
+
|
|
12
|
+
import gql from 'graphql-tag'
|
|
13
|
+
import './project-create-popup'
|
|
14
|
+
import { Project } from './project-list'
|
|
15
|
+
|
|
16
|
+
@customElement('project-setting-list')
|
|
17
|
+
export class ProjectSettingList extends ScopedElementsMixin(PageView) {
|
|
18
|
+
static styles = [
|
|
19
|
+
css`
|
|
20
|
+
:host {
|
|
21
|
+
display: flex;
|
|
22
|
+
flex-direction: column;
|
|
23
|
+
overflow-y: auto;
|
|
24
|
+
|
|
25
|
+
width: 100%;
|
|
26
|
+
height: 100%;
|
|
27
|
+
background-color: #f7f7f7;
|
|
28
|
+
|
|
29
|
+
--grid-record-emphasized-background-color: red;
|
|
30
|
+
--grid-record-emphasized-color: yellow;
|
|
31
|
+
}
|
|
32
|
+
|
|
33
|
+
div[header] {
|
|
34
|
+
display: flex;
|
|
35
|
+
height: 100px;
|
|
36
|
+
align-items: center;
|
|
37
|
+
background-color: #2ea4df1a;
|
|
38
|
+
border: 1px solid #2ea4df33;
|
|
39
|
+
margin: 15px 23px;
|
|
40
|
+
font-size: 18px;
|
|
41
|
+
padding: 7px;
|
|
42
|
+
border-radius: 5px;
|
|
43
|
+
|
|
44
|
+
md-filled-text-field[type='search'] {
|
|
45
|
+
margin-left: 5px;
|
|
46
|
+
margin-right: 26px;
|
|
47
|
+
|
|
48
|
+
--md-filled-text-field-container-shape: 0px;
|
|
49
|
+
--md-filled-text-field-container-color: transparent;
|
|
50
|
+
--md-filled-text-field-label-text-color: #999999;
|
|
51
|
+
--md-filled-text-field-input-text-color: #4e5055;
|
|
52
|
+
}
|
|
53
|
+
|
|
54
|
+
md-elevated-button[add-project] {
|
|
55
|
+
font-weight: bold;
|
|
56
|
+
font-size: 16px;
|
|
57
|
+
margin-left: 17px;
|
|
58
|
+
padding: 13px 20px;
|
|
59
|
+
|
|
60
|
+
--md-elevated-button-container-color: #24be7b;
|
|
61
|
+
--md-elevated-button-label-text-color: #ffffff;
|
|
62
|
+
--md-elevated-button-hover-label-text-color: #fff;
|
|
63
|
+
--md-elevated-button-pressed-label-text-color: #fff;
|
|
64
|
+
--md-elevated-button-focus-label-text-color: #fff;
|
|
65
|
+
--md-elevated-button-icon-color: #fff;
|
|
66
|
+
--md-elevated-button-hover-icon-color: #fff;
|
|
67
|
+
--md-elevated-button-pressed-icon-color: #fff;
|
|
68
|
+
--md-elevated-button-focus-icon-color: #fff;
|
|
69
|
+
|
|
70
|
+
--md-elevated-button-container-shape: 7px;
|
|
71
|
+
}
|
|
72
|
+
}
|
|
73
|
+
|
|
74
|
+
div[body] {
|
|
75
|
+
div[project-container] {
|
|
76
|
+
display: flex;
|
|
77
|
+
flex-direction: row;
|
|
78
|
+
min-height: 140px;
|
|
79
|
+
margin: 17px 23px;
|
|
80
|
+
background-color: #ffffff;
|
|
81
|
+
border: 1px solid #cccccc80;
|
|
82
|
+
border-radius: 5px;
|
|
83
|
+
|
|
84
|
+
img[project-img] {
|
|
85
|
+
width: 285px;
|
|
86
|
+
background-color: #cccccc80;
|
|
87
|
+
}
|
|
88
|
+
|
|
89
|
+
span[project-info] {
|
|
90
|
+
flex: 0.45;
|
|
91
|
+
padding: 6px 15px;
|
|
92
|
+
font-size: 16px;
|
|
93
|
+
|
|
94
|
+
white-space: nowrap;
|
|
95
|
+
overflow: hidden;
|
|
96
|
+
text-overflow: ellipsis;
|
|
97
|
+
|
|
98
|
+
div[name] {
|
|
99
|
+
color: #2e79be;
|
|
100
|
+
font-weight: bold;
|
|
101
|
+
font-size: 19px;
|
|
102
|
+
margin-bottom: 2px;
|
|
103
|
+
}
|
|
104
|
+
}
|
|
105
|
+
|
|
106
|
+
span[project-state] {
|
|
107
|
+
flex: 0.55;
|
|
108
|
+
padding: 10px 20px;
|
|
109
|
+
min-width: 350px;
|
|
110
|
+
|
|
111
|
+
& > div {
|
|
112
|
+
margin-bottom: 13px;
|
|
113
|
+
}
|
|
114
|
+
|
|
115
|
+
div[progress] {
|
|
116
|
+
position: relative;
|
|
117
|
+
|
|
118
|
+
md-linear-progress {
|
|
119
|
+
--md-linear-progress-track-height: 18px;
|
|
120
|
+
--md-linear-progress-active-indicator-height: 18px;
|
|
121
|
+
--md-linear-progress-track-shape: 5px;
|
|
122
|
+
--md-linear-progress-active-indicator-color: #0595e51a;
|
|
123
|
+
--md-linear-progress-track-color: #0595e533;
|
|
124
|
+
}
|
|
125
|
+
|
|
126
|
+
span {
|
|
127
|
+
position: absolute;
|
|
128
|
+
top: 0;
|
|
129
|
+
left: 12px;
|
|
130
|
+
font-size: 12px;
|
|
131
|
+
font-weight: bold;
|
|
132
|
+
color: #2e79be;
|
|
133
|
+
|
|
134
|
+
&:last-child {
|
|
135
|
+
left: unset;
|
|
136
|
+
right: 12px;
|
|
137
|
+
}
|
|
138
|
+
}
|
|
139
|
+
}
|
|
140
|
+
|
|
141
|
+
div[filled] div {
|
|
142
|
+
margin-right: 18px;
|
|
143
|
+
display: inline-block;
|
|
144
|
+
}
|
|
145
|
+
|
|
146
|
+
strong[filled] {
|
|
147
|
+
color: #1bb401;
|
|
148
|
+
}
|
|
149
|
+
strong[not-filled] {
|
|
150
|
+
color: #ff4444;
|
|
151
|
+
}
|
|
152
|
+
|
|
153
|
+
md-outlined-button {
|
|
154
|
+
min-height: 33px;
|
|
155
|
+
padding: 0px 13px;
|
|
156
|
+
margin-right: 2px;
|
|
157
|
+
box-shadow: 1px 1px 1px #0000001a;
|
|
158
|
+
--md-outlined-button-label-text-color: #586878;
|
|
159
|
+
--md-outlined-button-label-text-weight: bold;
|
|
160
|
+
}
|
|
161
|
+
}
|
|
162
|
+
}
|
|
163
|
+
}
|
|
164
|
+
`
|
|
165
|
+
]
|
|
166
|
+
|
|
167
|
+
get context() {
|
|
168
|
+
return {
|
|
169
|
+
title: '셋팅'
|
|
170
|
+
}
|
|
171
|
+
}
|
|
172
|
+
|
|
173
|
+
@state() private projectName: string = ''
|
|
174
|
+
@state() private projectList: Project[] = []
|
|
175
|
+
@state() private projectCount: number = 0
|
|
176
|
+
|
|
177
|
+
render() {
|
|
178
|
+
return html`
|
|
179
|
+
<div header>
|
|
180
|
+
<label>프로젝트 이름</label>
|
|
181
|
+
<md-filled-text-field
|
|
182
|
+
name="projectName"
|
|
183
|
+
type="search"
|
|
184
|
+
label="프로젝트 이름"
|
|
185
|
+
.value=${this.projectName}
|
|
186
|
+
@input=${this._onInputChange}
|
|
187
|
+
@keypress=${this._onKeypress}
|
|
188
|
+
>
|
|
189
|
+
<md-icon slot="leading-icon">search</md-icon>
|
|
190
|
+
</md-filled-text-field>
|
|
191
|
+
|
|
192
|
+
<strong>총 ${this.projectCount}개</strong>
|
|
193
|
+
<md-elevated-button add-project @click=${this._openCreateProjectPopup}>+ 신규 프로젝트 추가</md-elevated-button>
|
|
194
|
+
</div>
|
|
195
|
+
|
|
196
|
+
<div body>
|
|
197
|
+
${this.projectList?.map((project: Project) => {
|
|
198
|
+
const filledText = html`<strong filled>등록완료</strong>`
|
|
199
|
+
const nonFilledText = html`<strong not-filled>미등록</strong>`
|
|
200
|
+
|
|
201
|
+
const projectFilledState = project.buildingComplex.address ? filledText : nonFilledText
|
|
202
|
+
const supervisoryFilledState = true ? filledText : nonFilledText
|
|
203
|
+
const taskFilledState = false ? filledText : nonFilledText
|
|
204
|
+
|
|
205
|
+
return html`
|
|
206
|
+
<div project-container>
|
|
207
|
+
<img project-img src=${project.mainPhoto?.fullpath || ''} />
|
|
208
|
+
|
|
209
|
+
<span project-info>
|
|
210
|
+
<div name>${project.name}</div>
|
|
211
|
+
<div content>${project.buildingComplex.address}</div>
|
|
212
|
+
<div content>면적: ${project.buildingComplex.area}㎡</div>
|
|
213
|
+
<div content>착공~준공: ${project.startDate}~${project.endDate}</div>
|
|
214
|
+
<div content>발주처: <strong>${project.buildingComplex.clientCompany}</strong></div>
|
|
215
|
+
</span>
|
|
216
|
+
|
|
217
|
+
<span project-state>
|
|
218
|
+
<div progress>
|
|
219
|
+
<md-linear-progress buffer="100" max="100" value=${project.totalProgress || 0}> </md-linear-progress>
|
|
220
|
+
<span>${project.totalProgress == 100 ? '완료' : '진행중'}</span>
|
|
221
|
+
<span>${project.totalProgress || 0}%</span>
|
|
222
|
+
</div>
|
|
223
|
+
<div filled>
|
|
224
|
+
<div>프로젝트 정보 ${projectFilledState}</div>
|
|
225
|
+
<div>시공감리 자료 ${supervisoryFilledState}</div>
|
|
226
|
+
<div>공정표 ${taskFilledState}</div>
|
|
227
|
+
</div>
|
|
228
|
+
<div>
|
|
229
|
+
<md-outlined-button href="project-update/${project.id}">프로젝트 정보 수정</md-outlined-button>
|
|
230
|
+
<md-outlined-button href="project-plan-management/${project.id}">도면 관리</md-outlined-button>
|
|
231
|
+
<md-outlined-button href="project-task-management/${project.id}">공정표 관리</md-outlined-button>
|
|
232
|
+
</div>
|
|
233
|
+
</span>
|
|
234
|
+
</div>
|
|
235
|
+
`
|
|
236
|
+
})}
|
|
237
|
+
</div>
|
|
238
|
+
`
|
|
239
|
+
}
|
|
240
|
+
|
|
241
|
+
async pageInitialized(lifecycle: any) {
|
|
242
|
+
this.getProjectList()
|
|
243
|
+
}
|
|
244
|
+
|
|
245
|
+
async getProjectList() {
|
|
246
|
+
const response = await client.query({
|
|
247
|
+
query: gql`
|
|
248
|
+
query Projects($projectName: String!) {
|
|
249
|
+
projects(projectName: $projectName) {
|
|
250
|
+
items {
|
|
251
|
+
id
|
|
252
|
+
name
|
|
253
|
+
mainPhoto {
|
|
254
|
+
fullpath
|
|
255
|
+
}
|
|
256
|
+
startDate
|
|
257
|
+
endDate
|
|
258
|
+
totalProgress
|
|
259
|
+
buildingComplex {
|
|
260
|
+
address
|
|
261
|
+
area
|
|
262
|
+
clientCompany
|
|
263
|
+
}
|
|
264
|
+
}
|
|
265
|
+
total
|
|
266
|
+
}
|
|
267
|
+
}
|
|
268
|
+
`,
|
|
269
|
+
variables: {
|
|
270
|
+
projectName: this.projectName || ''
|
|
271
|
+
}
|
|
272
|
+
})
|
|
273
|
+
|
|
274
|
+
this.projectList = response.data.projects?.items || []
|
|
275
|
+
this.projectCount = response.data.projects?.total || 0
|
|
276
|
+
}
|
|
277
|
+
|
|
278
|
+
private _openCreateProjectPopup() {
|
|
279
|
+
openPopup(html`<project-create-popup .refreshFn=${this.getProjectList.bind(this)}></project-create-popup>`, {
|
|
280
|
+
backdrop: true,
|
|
281
|
+
size: 'small',
|
|
282
|
+
title: '신규 프로젝트 생성'
|
|
283
|
+
})
|
|
284
|
+
}
|
|
285
|
+
|
|
286
|
+
// Input 요소의 값이 변경될 때 호출되는 콜백 함수
|
|
287
|
+
private _onInputChange(event: InputEvent) {
|
|
288
|
+
const target = event.target as HTMLInputElement
|
|
289
|
+
this[target.name] = target.value
|
|
290
|
+
}
|
|
291
|
+
|
|
292
|
+
// 검색창에서 엔터입력시 검색
|
|
293
|
+
private _onKeypress(event: KeyboardEvent) {
|
|
294
|
+
if (event.code === 'Enter') {
|
|
295
|
+
this.getProjectList()
|
|
296
|
+
}
|
|
297
|
+
}
|
|
298
|
+
}
|