
Merge branch 'front-end' of http://210.180.118.83/yjryu/senior_care_system into front-end
@514bbd8917dac036f89276ccb463ba2e8771d1f6
--- client/views/component/Modal_Guardian.jsx
+++ client/views/component/Modal_Guardian.jsx
... | ... | @@ -4,6 +4,18 @@ |
4 | 4 |
|
5 | 5 |
export default function Modal_Guardian({ open, close, guardianManagementCallback, seniorId, guardianBySenior }) { |
6 | 6 |
|
7 |
+ const relationshipList = [ |
|
8 |
+ '자녀', |
|
9 |
+ '손자녀', |
|
10 |
+ '배우자', |
|
11 |
+ '사위', |
|
12 |
+ '며느리', |
|
13 |
+ '형제', |
|
14 |
+ '자매', |
|
15 |
+ '남매', |
|
16 |
+ '친척' |
|
17 |
+ ]; |
|
18 |
+ |
|
7 | 19 |
const guardianInit = { |
8 | 20 |
'user_id': '', |
9 | 21 |
'user_name': '', |
... | ... | @@ -14,8 +26,8 @@ |
14 | 26 |
'user_address': '', |
15 | 27 |
'user_email': '', |
16 | 28 |
'authority': 'ROLE_GUARDIAN', |
17 |
- 'agency_id': '', |
|
18 |
- 'government_id': '', |
|
29 |
+ 'agency_id': null, |
|
30 |
+ 'government_id': null, |
|
19 | 31 |
|
20 | 32 |
'senior_id': seniorId, |
21 | 33 |
'senior_relationship': '자녀', |
... | ... | @@ -82,6 +94,10 @@ |
82 | 94 |
const guardianInsert = () => { |
83 | 95 |
if (guardianInsertValidation() == false) { |
84 | 96 |
return; |
97 |
+ } |
|
98 |
+ |
|
99 |
+ if (guardian['senior_relationship'] == '기타') { |
|
100 |
+ guardian['senior_relationship'] = guardian['senior_relationship_etc']; |
|
85 | 101 |
} |
86 | 102 |
|
87 | 103 |
fetch("/user/guardianInsert.json", { |
... | ... | @@ -246,18 +262,12 @@ |
246 | 262 |
<td colSpan={3}> |
247 | 263 |
<select onChange={(e) => {guardianValueChange('senior_relationship', e.target.value)}} |
248 | 264 |
ref={el => guardianRef.current['senior_relationship'] = el}> |
249 |
- <option>자녀</option> |
|
250 |
- <option>손자녀</option> |
|
251 |
- <option>배우자</option> |
|
252 |
- <option>사위</option> |
|
253 |
- <option>며느리</option> |
|
254 |
- <option>형제</option> |
|
255 |
- <option>자매</option> |
|
256 |
- <option>남매</option> |
|
257 |
- <option>친척</option> |
|
258 |
- <option selected={guardian['senior_relationship'].indexOf('기타') > -1}>기타</option> |
|
265 |
+ {relationshipList.map((relationship, idx) => { return ( |
|
266 |
+ <option key={idx}>{relationship}</option> |
|
267 |
+ )})} |
|
268 |
+ <option value="기타" selected={guardian['senior_relationship'] == '기타' || relationshipList.indexOf(guardian['senior_relationship']) == -1}>기타</option> |
|
259 | 269 |
</select> |
260 |
- {guardian['senior_relationship'].indexOf('기타') > -1 ? ( |
|
270 |
+ {guardian['senior_relationship'] == '기타' || relationshipList.indexOf(guardian['senior_relationship']) == -1 ? ( |
|
261 | 271 |
<input type="text" |
262 | 272 |
value={guardian['senior_relationship_etc']} |
263 | 273 |
onChange={(e) => {guardianValueChange('senior_relationship_etc', e.target.value)}} |
--- client/views/pages/senior_management/SeniorSelectOne.jsx
+++ client/views/pages/senior_management/SeniorSelectOne.jsx
... | ... | @@ -218,6 +218,7 @@ |
218 | 218 |
<th>이름</th> |
219 | 219 |
<th>관계</th> |
220 | 220 |
<th>연락처</th> |
221 |
+ <th>생년월일</th> |
|
221 | 222 |
<th>주소</th> |
222 | 223 |
<th>관리</th> |
223 | 224 |
<th>가입승인</th> |
... | ... | @@ -230,6 +231,7 @@ |
230 | 231 |
<td>{item['user_name']}</td> |
231 | 232 |
<td>{item['senior_relationship']}</td> |
232 | 233 |
<td>{item['user_phonenumber']}</td> |
234 |
+ <td>{item['user_birth']}</td> |
|
233 | 235 |
<td>{item['user_address']}</td> |
234 | 236 |
<td> |
235 | 237 |
{item['is_accept'] ? "승인완료" : |
Add a comment
Delete comment
Once you delete this comment, you won't be able to recover it. Are you sure you want to delete this comment?