Merge branch 'first_dev' into 'deploy-dev-front'
[FO] 개인정보 view 오류 수정 See merge request korea-research/korea-research!91
This commit is contained in:
@@ -6,4 +6,18 @@ logging:
|
||||
path: ${user.home}/logs # 로그 파일 저장 경로 (사용자 홈 디렉토리 하위 logs 폴더)
|
||||
level:
|
||||
app:
|
||||
module: INFO # 애플리케이션 기본 패키지 로깅 레벨 (패키지 경로 변경 필요시 수정)
|
||||
module: INFO # 애플리케이션 기본 패키지 로깅 레벨 (패키지 경로 변경 필요시 수정)
|
||||
|
||||
|
||||
|
||||
# ==============================================
|
||||
# 서버 압축 설정
|
||||
# ==============================================
|
||||
server:
|
||||
servlet:
|
||||
session:
|
||||
cookie:
|
||||
domain: fhes.kric.com
|
||||
path: /
|
||||
http-only: true
|
||||
secure: true
|
||||
|
||||
@@ -5,7 +5,6 @@ spring:
|
||||
messages:
|
||||
basename: messages/exception,messages/validation,messages/uri,messages/operation
|
||||
encoding: UTF-8
|
||||
|
||||
# gzip compression 설정
|
||||
compression:
|
||||
enabled: true
|
||||
@@ -91,4 +90,12 @@ logging:
|
||||
hibernate:
|
||||
orm:
|
||||
jdbc:
|
||||
bind: trace # Hibernate SQL 파라미터 바인딩 로깅
|
||||
bind: trace # Hibernate SQL 파라미터 바인딩 로깅
|
||||
# ==============================================
|
||||
# 서버 압축 설정
|
||||
# ==============================================
|
||||
server:
|
||||
servlet:
|
||||
session:
|
||||
cookie:
|
||||
name: FRONT_SESSION
|
||||
@@ -11,7 +11,7 @@
|
||||
<include refid="app.module.core.usecase.daily.record.adapters.persistence.DailyRecordMapper.InnerJoinByDailyRecord"/>
|
||||
where ds.is_deleted = false
|
||||
<if test="id != null and id != '0'">
|
||||
and ds.id = ${id}
|
||||
and ds.id = #{id}
|
||||
</if>
|
||||
order by
|
||||
ds.id desc
|
||||
@@ -23,7 +23,7 @@
|
||||
<include refid="app.module.core.usecase.daily.record.adapters.persistence.DailyRecordMapper.InnerJoinByDailyRecord"/>
|
||||
where ds.is_deleted = false
|
||||
<if test="id != null and id != '0'">
|
||||
and ds.id = ${id}
|
||||
and ds.id = #{id}
|
||||
</if>
|
||||
</select>
|
||||
|
||||
|
||||
@@ -11,7 +11,7 @@
|
||||
<include refid="app.module.core.usecase.daily.record.adapters.persistence.DailyRecordMapper.InnerJoinByDailyRecord"/>
|
||||
where ds.is_deleted = false
|
||||
<if test="id != null and id != '0'">
|
||||
and ds.id = ${id}
|
||||
and ds.id = #{id}
|
||||
</if>
|
||||
order by
|
||||
ds.id desc
|
||||
@@ -23,7 +23,7 @@
|
||||
<include refid="app.module.core.usecase.daily.record.adapters.persistence.DailyRecordMapper.InnerJoinByDailyRecord"/>
|
||||
where ds.is_deleted = false
|
||||
<if test="id != null and id != '0'">
|
||||
and ds.id = ${id}
|
||||
and ds.id = #{id}
|
||||
</if>
|
||||
</select>
|
||||
|
||||
|
||||
@@ -11,7 +11,7 @@
|
||||
<include refid="app.module.core.usecase.daily.record.adapters.persistence.DailyRecordMapper.InnerJoinByDailyRecord"/>
|
||||
where ds.is_deleted = false
|
||||
<if test="id != null and id != '0'">
|
||||
and ds.id = ${id}
|
||||
and ds.id = #{id}
|
||||
</if>
|
||||
order by
|
||||
ds.id desc
|
||||
@@ -23,7 +23,7 @@
|
||||
<include refid="app.module.core.usecase.daily.record.adapters.persistence.DailyRecordMapper.InnerJoinByDailyRecord"/>
|
||||
where ds.is_deleted = false
|
||||
<if test="id != null and id != '0'">
|
||||
and ds.id = ${id}
|
||||
and ds.id = #{id}
|
||||
</if>
|
||||
</select>
|
||||
|
||||
|
||||
@@ -11,7 +11,7 @@
|
||||
<include refid="app.module.core.usecase.daily.record.adapters.persistence.DailyRecordMapper.InnerJoinByDailyRecord"/>
|
||||
where ds.is_deleted = false
|
||||
<if test="id != null and id != '0'">
|
||||
and ds.id = ${id}
|
||||
and ds.id = #{id}
|
||||
</if>
|
||||
order by
|
||||
ds.id desc
|
||||
@@ -23,7 +23,7 @@
|
||||
<include refid="app.module.core.usecase.daily.record.adapters.persistence.DailyRecordMapper.InnerJoinByDailyRecord"/>
|
||||
where ds.is_deleted = false
|
||||
<if test="id != null and id != '0'">
|
||||
and ds.id = ${id}
|
||||
and ds.id = #{id}
|
||||
</if>
|
||||
</select>
|
||||
|
||||
|
||||
@@ -10,7 +10,7 @@
|
||||
<include refid="app.module.core.usecase.daily.record.adapters.persistence.DailyRecordMapper.InnerJoinByDailyRecord"/>
|
||||
where ds.is_deleted = false
|
||||
<if test="id != null and id != '0'">
|
||||
and ds.id = ${id}
|
||||
and ds.id = #{id}
|
||||
</if>
|
||||
order by
|
||||
ds.id desc
|
||||
@@ -22,7 +22,7 @@
|
||||
<include refid="app.module.core.usecase.daily.record.adapters.persistence.DailyRecordMapper.InnerJoinByDailyRecord"/>
|
||||
where ds.is_deleted = false
|
||||
<if test="id != null and id != '0'">
|
||||
and ds.id = ${id}
|
||||
and ds.id = #{id}
|
||||
</if>
|
||||
</select>
|
||||
|
||||
|
||||
@@ -14,7 +14,7 @@
|
||||
<include refid="app.module.core.usecase.daily.record.adapters.persistence.DailyRecordMapper.InnerJoinByDailyRecord"/>
|
||||
where ds.is_deleted = false
|
||||
<if test="id != null and id != '0'">
|
||||
and ds.id = ${id}
|
||||
and ds.id = #{id}
|
||||
</if>
|
||||
order by
|
||||
ds.id desc
|
||||
@@ -26,7 +26,7 @@
|
||||
<include refid="app.module.core.usecase.daily.record.adapters.persistence.DailyRecordMapper.InnerJoinByDailyRecord"/>
|
||||
where ds.is_deleted = false
|
||||
<if test="id != null and id != '0'">
|
||||
and ds.id = ${id}
|
||||
and ds.id = #{id}
|
||||
</if>
|
||||
</select>
|
||||
|
||||
|
||||
@@ -22,7 +22,7 @@
|
||||
industry_middle_code,
|
||||
industry_sub_middle,
|
||||
industry_detail,
|
||||
employment_code,
|
||||
employment_type,
|
||||
is_panel,
|
||||
memo,
|
||||
drop_reason,
|
||||
|
||||
@@ -11,8 +11,8 @@
|
||||
owner_age = #{ownerAge},
|
||||
tel = #{tel},
|
||||
phone = #{phone},
|
||||
region_main_code = #{regionMainCode},
|
||||
region_sub_code = #{regionSubCode},
|
||||
region_detail_code = #{regionDetailCode},
|
||||
address = #{address},
|
||||
<include refid="common.fields.UpdateBaseSet" />
|
||||
WHERE seq = ${seq}
|
||||
|
||||
@@ -258,4 +258,93 @@ $(function() {
|
||||
$el.val($el.val().replace('.', ''));
|
||||
}
|
||||
})
|
||||
})
|
||||
})
|
||||
|
||||
/**
|
||||
* 공통코드 기반의 2단계 셀렉트박스(부모/자식) UI를 구성하는 함수
|
||||
*
|
||||
* @param {Object} codeList - 공통코드 리스트 객체
|
||||
* @param {string} parentSelector - 부모 셀렉트박스 셀렉터 (ex. '#regionSubCode')
|
||||
* @param {string} childSelector - 자식 셀렉트박스 셀렉터 (ex. '#regionDetailCode')
|
||||
* @param {string} selectedParentCode - 초기 선택할 부모 코드값 (ex. 'code.region.sub.31')
|
||||
* @param {string} selectedChildCode - 초기 선택할 자식 코드값 (ex. 'code.region.detail.9')
|
||||
*/
|
||||
kri.form.setSelectBoxUiCode = function({
|
||||
codeList,
|
||||
parentSelector,
|
||||
childSelector,
|
||||
selectedParentCode = '',
|
||||
selectedChildCode = ''
|
||||
}) {
|
||||
const $parent = $(parentSelector);
|
||||
const $child = $(childSelector);
|
||||
|
||||
if (!codeList?.nodes || !$parent.length || !$child.length) return;
|
||||
|
||||
const renderOptions = ($el, list, selected, inputSelector) => {
|
||||
let html = '';
|
||||
list.forEach(item => {
|
||||
const isCurrent = item.id === selected ? 'current' : '';
|
||||
html += `<li class="option ${isCurrent}" data-value="${item.id}">${item.codeText}</li>`;
|
||||
});
|
||||
$el.html(html);
|
||||
|
||||
// 항목 클릭 시 hidden input에 값 반영
|
||||
$el.find('li.option').off('click').on('click', function () {
|
||||
const value = $(this).data('value');
|
||||
const text = $(this).text();
|
||||
|
||||
// 표시 텍스트 업데이트
|
||||
$el.closest('.component-select').find('.select-txt').text(text);
|
||||
|
||||
// 선택 클래스 처리
|
||||
$el.find('li.option').removeClass('current');
|
||||
$(this).addClass('current');
|
||||
|
||||
// hidden input 값 반영
|
||||
$el.closest('.component-select').find('input[data-type="select"]').val(value).trigger('change');
|
||||
});
|
||||
};
|
||||
|
||||
let childSelectUI = null;
|
||||
const loadChildren = (parentId, selectedChild = '') => {
|
||||
if (!parentId) return;
|
||||
|
||||
const $childEl = document.querySelector(childSelector);
|
||||
if($childEl.ui){
|
||||
$childEl.ui.core.destroy();
|
||||
}
|
||||
|
||||
const parent = codeList.nodes.find(n => n.id === parentId);
|
||||
if (!parent?.nodes) return;
|
||||
|
||||
const $childList = $child.find('ul');
|
||||
renderOptions($childList, parent.nodes, selectedChild);
|
||||
|
||||
childSelectUI = etUI.components.SelectBox();
|
||||
childSelectUI.core.init($childEl, {})
|
||||
};
|
||||
|
||||
// 초기 렌더링
|
||||
const $parentList = $parent.find('ul');
|
||||
renderOptions($parentList, codeList.nodes, selectedParentCode);
|
||||
|
||||
const $parentEl = document.querySelector(parentSelector);
|
||||
const parentSelectUI = new etUI.components.SelectBox();
|
||||
parentSelectUI.core.init($parentEl, {});
|
||||
|
||||
if (selectedParentCode) {
|
||||
loadChildren(selectedParentCode, selectedChildCode);
|
||||
}
|
||||
|
||||
// 부모 셀렉션 변경 시 자식 재로드
|
||||
$parent.find('ul').on('click', 'li.option', function () {
|
||||
const newParentCode = $(this).data('value');
|
||||
loadChildren(newParentCode);
|
||||
});
|
||||
|
||||
return {
|
||||
getParentValue: () => parentSelectUI.getValue(),
|
||||
getChildValue: () => childSelectUI?.getValue() ?? ''
|
||||
};
|
||||
}
|
||||
@@ -27,7 +27,7 @@
|
||||
<meta name="_csrf_header" th:content="${_csrf.headerName}"/>
|
||||
<meta name="robots" content="noindex, nofollow">
|
||||
|
||||
<link rel="icon" th:href="@{/kri_appimg.png}" sizes="512x512">
|
||||
<link rel="icon" th:href="@{/static/assets/images/kri_appimg.png}" sizes="512x512">
|
||||
<!-- iOS 홈화면 -->
|
||||
<link rel="apple-touch-icon" th:href="@{/static/assets/images/kri_appimg.png}">
|
||||
<!-- PWA -->
|
||||
|
||||
@@ -48,7 +48,8 @@
|
||||
|
||||
<section class="info-bottom-area bg-white bg-lround">
|
||||
<ul class="btn-link-list">
|
||||
<li>
|
||||
<!--TODO 개인 정보 동의시 오픈 예정 -->
|
||||
<!-- <li>
|
||||
<a href="/info/user/password">
|
||||
<i class="ico-privacy ico-normal" aria-hidden="true"></i>
|
||||
<dl>
|
||||
@@ -56,7 +57,7 @@
|
||||
<dd>이름, 주소, 연락처를 수정할 수 있어요</dd>
|
||||
</dl>
|
||||
</a>
|
||||
</li>
|
||||
</li>-->
|
||||
<li>
|
||||
<a href="/info/monthly">
|
||||
<i class="ico-chart ico-normal" aria-hidden="true"></i>
|
||||
|
||||
@@ -48,7 +48,7 @@
|
||||
|
||||
<div id="tel1Id" class="component-select bottom-sheet"
|
||||
th:data-props-default="${userInfo.tel1}" data-props-type="bottomSheet">
|
||||
<input type="hidden" th:field="*{tel1}" data-type="select">
|
||||
<input type="hidden" name="tel1" th:field="*{tel1}" data-type="select">
|
||||
<button type="button" class="select-box">
|
||||
<span class="select-txt"></span>
|
||||
</button>
|
||||
@@ -130,15 +130,15 @@
|
||||
<div class="select-group">
|
||||
<div class="select-label">
|
||||
<p class="label-txt">
|
||||
도로명 주소
|
||||
주소
|
||||
<i class="ico-required-mark" role="img" aria-label="필수">*</i>
|
||||
</p>
|
||||
</div>
|
||||
|
||||
|
||||
<div id="regionMainCodeId" class="component-select bottom-sheet" data-props-default="지역 선택"
|
||||
<div id="regionSubCodeId" class="component-select bottom-sheet" data-props-default="지역 선택"
|
||||
data-props-type="bottomSheet">
|
||||
<input type="hidden" name="regionMainCode" data-type="select" th:value="${userInfo.regionMainCode}">
|
||||
<input type="hidden" name="regionSubCode" data-type="select" th:value="${userInfo.regionSubCode}">
|
||||
<button type="button" class="select-box">
|
||||
<span class="select-txt">선택</span>
|
||||
</button>
|
||||
@@ -152,12 +152,12 @@
|
||||
<div class="select-scroll">
|
||||
|
||||
<ul class="">
|
||||
<th:block th:each="item : ${regionMainList}">
|
||||
<li class="option" th:data-value="${item.id}"
|
||||
th:text="${item.codeText}"
|
||||
th:classappend="${item.id eq userInfo.regionMainCode ? 'current' : ''}">option1
|
||||
</li>
|
||||
</th:block>
|
||||
<!-- <th:block th:each="item : ${regionMainList}">-->
|
||||
<!-- <li class="option" th:data-value="${item.id}"-->
|
||||
<!-- th:text="${item.codeText}"-->
|
||||
<!-- th:classappend="${item.id eq userInfo.regionMainCode ? 'current' : ''}">option1-->
|
||||
<!-- </li>-->
|
||||
<!-- </th:block>-->
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
@@ -167,29 +167,29 @@
|
||||
|
||||
|
||||
<div class="select-group">
|
||||
<div id="regionSubCodeId" class="component-select bottom-sheet"
|
||||
data-props-default="세부지역 선택" data-props-type="bottomSheet">
|
||||
<input type="hidden" th:field="*{regionSubCode}" data-type="select">
|
||||
<div id="regionDetailCodeId" class="component-select bottom-sheet"
|
||||
data-props-default="세부 지역 선택" data-props-type="bottomSheet" data-init="false">
|
||||
<!-- <input type="hidden" name="regionDetailCode" data-type="select">-->
|
||||
<input type="hidden" name="regionDetailCode" th:field="*{regionDetailCode}" data-type="select">
|
||||
<button type="button" class="select-box">
|
||||
<span class="select-txt">선택</span>
|
||||
</button>
|
||||
<div class="select-options">
|
||||
<div class="select-header">
|
||||
<p>세부지역 선택</p>
|
||||
<p>세부 지역 선택</p>
|
||||
<button type="button" class="select-close">
|
||||
<span class="hide-txt">닫기</span>
|
||||
</button>
|
||||
</div>
|
||||
<div class="select-scroll">
|
||||
<ul class="">
|
||||
<th:block th:each="item : ${regionSubList}">
|
||||
<li class="option" th:data-value="${item.id}"
|
||||
th:text="${item.codeText}"
|
||||
th:classappend="${item.id eq userInfo.regionSubCode ? 'current' : ''}"
|
||||
>option1
|
||||
</li>
|
||||
</th:block>
|
||||
|
||||
<!-- <th:block th:each="item : ${regionSubList}">-->
|
||||
<!-- <li class="option" th:data-value="${item.id}"-->
|
||||
<!-- th:text="${item.codeText}"-->
|
||||
<!-- th:classappend="${item.id eq userInfo.regionSubCode ? 'current' : ''}"-->
|
||||
<!-- >option1-->
|
||||
<!-- </li>-->
|
||||
<!-- </th:block>-->
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
@@ -262,6 +262,21 @@
|
||||
|
||||
<section layout:fragment="script">
|
||||
<script th:inline="javascript">
|
||||
const regionList = [[${regionSubList}]];
|
||||
const selectedRegionSubCode = /*[[${userInfo.regionSubCode}]]*/ '';
|
||||
const selectedRegionDetailCode = /*[[${userInfo.regionDetailCode}]]*/ '';
|
||||
|
||||
$(document).ready(function () {
|
||||
// 지역, 세부지역 셀렉트박스 세팅
|
||||
ENV.select.regionSelect = kri.form.setSelectBoxUiCode({
|
||||
codeList: regionList,
|
||||
parentSelector: '#regionSubCodeId',
|
||||
childSelector: '#regionDetailCodeId',
|
||||
selectedParentCode: selectedRegionSubCode,
|
||||
selectedChildCode: selectedRegionDetailCode
|
||||
});
|
||||
});
|
||||
|
||||
let ENV = {
|
||||
httpUrl: {
|
||||
root: /*[[#{uri.front.info.user.path}]]*/'rootUrl',
|
||||
@@ -272,10 +287,9 @@
|
||||
confirmPopup: null
|
||||
},
|
||||
select:{
|
||||
select1:null,
|
||||
select2:null,
|
||||
select3:null,
|
||||
select4:null
|
||||
selectRegion: null,
|
||||
selectTel:null,
|
||||
selectPhone:null
|
||||
},
|
||||
submitted: false,
|
||||
};
|
||||
@@ -291,45 +305,25 @@
|
||||
ENV.initialOwnerName = document.querySelector('input[name="ownerName"]').value;
|
||||
},
|
||||
_bindUI() {
|
||||
|
||||
console.log("bind")
|
||||
ENV.module.confirmPopup = document.querySelector(".confirmPopup").ui;
|
||||
|
||||
const $select1 = document.querySelector('#regionMainCodeId');
|
||||
ENV.select.select1 = new etUI.components.SelectBox();
|
||||
ENV.select.select1.core.init($select1, {
|
||||
selectItemCallback({selectValue, dataValue}){
|
||||
|
||||
document.querySelector('#regionMainCode').value = dataValue;
|
||||
}
|
||||
});
|
||||
|
||||
const $select2 = document.querySelector('#regionSubCodeId');
|
||||
ENV.select.select2 = new etUI.components.SelectBox();
|
||||
ENV.select.select2.core.init($select2, {
|
||||
selectItemCallback({selectValue, dataValue}){
|
||||
document.querySelector('#regionSubCode').value = dataValue;
|
||||
}
|
||||
});
|
||||
|
||||
const $select3 = document.querySelector('#tel1Id');
|
||||
ENV.select.select3 = new etUI.components.SelectBox();
|
||||
ENV.select.select3.core.init($select3, {
|
||||
const $selectTel = document.querySelector('#tel1Id');
|
||||
ENV.select.selectTel = new etUI.components.SelectBox();
|
||||
ENV.select.selectTel.core.init($selectTel, {
|
||||
selectItemCallback({selectValue, dataValue}){
|
||||
document.querySelector('#tel1').value = dataValue;
|
||||
}
|
||||
});
|
||||
|
||||
|
||||
const $select4 = document.querySelector('#phone1Id');
|
||||
ENV.select.select4 = new etUI.components.SelectBox();
|
||||
ENV.select.select4.core.init($select4, {
|
||||
const $selectPhone = document.querySelector('#phone1Id');
|
||||
ENV.select.selectPhone = new etUI.components.SelectBox();
|
||||
ENV.select.selectPhone.core.init($selectPhone, {
|
||||
selectItemCallback({selectValue, dataValue}){
|
||||
document.querySelector('#phone1').value = dataValue;
|
||||
}
|
||||
});
|
||||
|
||||
|
||||
// selectboxInstance1.setValue($('input[name=regionMainCode]').val());
|
||||
},
|
||||
confirmPopup() {
|
||||
@@ -369,10 +363,10 @@
|
||||
// f.regionSubCode.value = regionSubCodeIdElement.value;
|
||||
// }
|
||||
|
||||
f.regionMainCode.value = ENV.select.select1.getValue();
|
||||
f.regionSubCode.value = ENV.select.select2.getValue();
|
||||
f.tel1.value = ENV.select.select3.getValue();
|
||||
f.phone1.value = ENV.select.select4.getValue();
|
||||
f.regionSubCode.value = ENV.select.regionSelect.getParentValue();
|
||||
f.regionDetailCode.value = ENV.select.regionSelect.getChildValue();
|
||||
f.tel1.value = ENV.select.selectTel.getValue();
|
||||
f.phone1.value = ENV.select.selectPhone.getValue();
|
||||
|
||||
|
||||
|
||||
@@ -389,7 +383,9 @@
|
||||
// 이름이 바뀐 경우만 팝업
|
||||
ENV.module.confirmPopup.open();
|
||||
} else {
|
||||
location.href = '/info';
|
||||
ajaxUtil._alert('개인정보 변경이 완료되었습니다.', null, () => {
|
||||
location.href = '/info';
|
||||
});
|
||||
}
|
||||
} else if (rstData.code === 'ERROR') {
|
||||
ajaxUtil._alert('잠시 뒤에 다시 시도해 주세요.', null);
|
||||
|
||||
@@ -89,7 +89,8 @@
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
<button type="button" class="btn btn-m btn-secondary btn-full button-modal01" data-testid="button-modal01">
|
||||
<button type="button" class="btn btn-m btn-secondary btn-full button-modal01" data-testid="button-modal01"
|
||||
th:if="${btnActive}">
|
||||
<i class="ico-add ico-small" aria-hidden="true"></i>
|
||||
<span class="btn-txt">추가 등록</span>
|
||||
</button>
|
||||
|
||||
@@ -87,7 +87,8 @@
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
<button type="button" class="btn btn-m btn-secondary btn-full button-modal01" data-testid="button-modal01">
|
||||
<button type="button" class="btn btn-m btn-secondary btn-full button-modal01" data-testid="button-modal01"
|
||||
th:if="${btnActive}">
|
||||
<i class="ico-add ico-small" aria-hidden="true"></i>
|
||||
<span class="btn-txt">추가 등록</span>
|
||||
</button>
|
||||
|
||||
@@ -87,7 +87,8 @@
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
<button type="button" class="btn btn-m btn-secondary btn-full button-modal01" data-testid="button-modal01">
|
||||
<button type="button" class="btn btn-m btn-secondary btn-full button-modal01" data-testid="button-modal01"
|
||||
th:if="${btnActive}">
|
||||
<i class="ico-add ico-small" aria-hidden="true"></i>
|
||||
<span class="btn-txt">추가 등록</span>
|
||||
</button>
|
||||
|
||||
@@ -7,9 +7,10 @@
|
||||
<div class="component-btns type-tab"
|
||||
th:if="not ${detail.updated}">
|
||||
<div class="btns-row">
|
||||
<button type="button" class="btn active">수기 등록</button>
|
||||
<!--/* TODO : 2차 오픈 */-->
|
||||
<!--<button type="button" class="btn">영수증 등록</button>-->
|
||||
<button type="button" class="btn active" onclick="modalControl.changeModal('self')">수기 등록</button>
|
||||
<th:block th:if="${@systemProperties['spring.profiles.active'] eq 'local'}">
|
||||
<button type="button" class="btn" onclick="modalControl.changeModal('ocr')">영수증 등록</button>
|
||||
</th:block>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@@ -17,187 +18,241 @@
|
||||
<form name="reqModalForm">
|
||||
<input type="hidden" name="inputType" th:value="${#strings.defaultString(detail.inputType, 'SELF')}">
|
||||
<input type="hidden" name="id" th:value="${detail.id}">
|
||||
<section class="form-group">
|
||||
<div class="segment-label">
|
||||
<p class="label-txt">
|
||||
외상판매 여부
|
||||
</p>
|
||||
</div>
|
||||
<div class="component-segment">
|
||||
<div class="component-radio">
|
||||
<label class="radio-inner">
|
||||
<input type="radio" name="credit" value="true" th:checked="${detail.credit}">
|
||||
<span class="radio-item">
|
||||
<span class="radio-txt">예</span>
|
||||
</span>
|
||||
</label>
|
||||
</div>
|
||||
<div class="component-radio">
|
||||
<label class="radio-inner">
|
||||
<input type="radio" name="credit" value="false" th:checked="not ${detail.credit}">
|
||||
<span class="radio-item">
|
||||
<span class="radio-txt">아니오</span>
|
||||
</span>
|
||||
</label>
|
||||
</div>
|
||||
</div>
|
||||
<div class="select-group">
|
||||
<div class="select-label">
|
||||
<!--/* 수기 등록 s */-->
|
||||
<div id="modelSelf">
|
||||
<section class="form-group">
|
||||
<div class="segment-label">
|
||||
<p class="label-txt">
|
||||
재배형태
|
||||
외상판매 여부
|
||||
</p>
|
||||
<span class="select-sub-txt">임산물 수입이 있는 경우, 등록해 주세요.</span>
|
||||
</div>
|
||||
<div id="cropCode" class="component-select bottom-sheet" data-props-default="재배형태를 선택해 주세요" data-props-type="bottomSheet">
|
||||
<input type="hidden" name="cropCode" th:value="${detail.cropCode}" data-type="select">
|
||||
<button type="button" class="select-box">
|
||||
<span class="select-txt"></span>
|
||||
</button>
|
||||
<div class="select-options">
|
||||
<div class="select-header">
|
||||
<p>재배형태</p>
|
||||
<button type="button" class="select-close">
|
||||
<span class="hide-txt">닫기</span>
|
||||
</button>
|
||||
</div>
|
||||
<div class="select-scroll">
|
||||
<ul class="">
|
||||
<li class="option"
|
||||
th:each="uiCode : ${recordCrop}"
|
||||
th:data-value="${uiCode.id}"
|
||||
th:text="${uiCode.codeText}"></li>
|
||||
</ul>
|
||||
<div class="component-segment">
|
||||
<div class="component-radio">
|
||||
<label class="radio-inner">
|
||||
<input type="radio" name="credit" value="true" th:checked="${detail.credit}">
|
||||
<span class="radio-item">
|
||||
<span class="radio-txt">예</span>
|
||||
</span>
|
||||
</label>
|
||||
</div>
|
||||
<div class="component-radio">
|
||||
<label class="radio-inner">
|
||||
<input type="radio" name="credit" value="false" th:checked="not ${detail.credit}">
|
||||
<span class="radio-item">
|
||||
<span class="radio-txt">아니오</span>
|
||||
</span>
|
||||
</label>
|
||||
</div>
|
||||
</div>
|
||||
<div class="select-group">
|
||||
<div class="select-label">
|
||||
<p class="label-txt">
|
||||
재배형태
|
||||
</p>
|
||||
<span class="select-sub-txt">임산물 수입이 있는 경우, 등록해 주세요.</span>
|
||||
</div>
|
||||
<div id="cropCode" class="component-select bottom-sheet" data-props-default="재배형태를 선택해 주세요" data-props-type="bottomSheet">
|
||||
<input type="hidden" name="cropCode" th:value="${detail.cropCode}" data-type="select">
|
||||
<button type="button" class="select-box">
|
||||
<span class="select-txt"></span>
|
||||
</button>
|
||||
<div class="select-options">
|
||||
<div class="select-header">
|
||||
<p>재배형태</p>
|
||||
<button type="button" class="select-close">
|
||||
<span class="hide-txt">닫기</span>
|
||||
</button>
|
||||
</div>
|
||||
<div class="select-scroll">
|
||||
<ul class="">
|
||||
<li class="option"
|
||||
th:each="uiCode : ${recordCrop}"
|
||||
th:data-value="${uiCode.id}"
|
||||
th:text="${uiCode.codeText}"></li>
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</section>
|
||||
</section>
|
||||
|
||||
<hr>
|
||||
<hr>
|
||||
|
||||
<section class="form-group">
|
||||
<div class="component-input">
|
||||
<div class="input-label">
|
||||
<label for="incomeKind" class="label-txt">
|
||||
수입의 종류<i class="ico-required-mark" role="img" aria-label="필수">*</i>
|
||||
</label>
|
||||
</div>
|
||||
<div class="input-field">
|
||||
<input type="text" id="incomeKind" name="incomeKind" th:value="${detail.incomeKind}" maxlength="30" placeholder="수입의 종류를 입력해 주세요">
|
||||
</div>
|
||||
</div>
|
||||
<div class="component-input">
|
||||
<div class="input-label">
|
||||
<label for="sourcePurpose" class="label-txt">
|
||||
수입원
|
||||
<i class="ico-required-mark" role="img" aria-label="필수">*</i>
|
||||
</label>
|
||||
</div>
|
||||
<div class="input-field">
|
||||
<input type="text" id="sourcePurpose" name="sourcePurpose" th:value="${detail.sourcePurpose}" maxlength="30" placeholder="수입원을 입력해 주세요">
|
||||
</div>
|
||||
</div>
|
||||
</section>
|
||||
|
||||
<hr>
|
||||
|
||||
<section class="form-group">
|
||||
<div class="component-input">
|
||||
<div class="input-label">
|
||||
<label for="quantity" class="label-txt">
|
||||
수량
|
||||
</label>
|
||||
</div>
|
||||
<div class="input-field">
|
||||
<input type="number" inputmode="decimal" pattern="[0-9]*" id="quantity" name="quantity" min="1" max="9999999999"
|
||||
th:value="${detail.quantity}" maxlength="10" placeholder="수량을 입력해 주세요">
|
||||
</div>
|
||||
<ul class="guide-info">
|
||||
<li>예 : 2, 2.5</li>
|
||||
</ul>
|
||||
</div>
|
||||
<div class="select-group">
|
||||
<div class="select-label">
|
||||
<p class="label-txt">
|
||||
단위
|
||||
</p>
|
||||
</div>
|
||||
<div id="unitCode" class="component-select bottom-sheet" data-props-default="단위를 선택해 주세요" data-props-type="bottomSheet">
|
||||
<input type="hidden" name="unitCode" data-type="select" th:value="${detail.unitCode}">
|
||||
<button type="button" class="select-box">
|
||||
<span class="select-txt"></span>
|
||||
</button>
|
||||
<div class="select-options">
|
||||
<div class="select-header">
|
||||
<p>단위</p>
|
||||
<button type="button" class="select-close">
|
||||
<span class="hide-txt">닫기</span>
|
||||
</button>
|
||||
</div>
|
||||
<div class="select-scroll">
|
||||
<ul class="">
|
||||
<li class="option" th:each="uiCode : ${recordUnit}"
|
||||
th:data-value="${uiCode.id}"
|
||||
th:text="${uiCode.codeText}"
|
||||
th:selected="${uiCode.id eq detail.unitCode ? 'current' : ''}"
|
||||
></li>
|
||||
</ul>
|
||||
</div>
|
||||
<section class="form-group">
|
||||
<div class="component-input">
|
||||
<div class="input-label">
|
||||
<label for="incomeKind" class="label-txt">
|
||||
수입의 종류<i class="ico-required-mark" role="img" aria-label="필수">*</i>
|
||||
</label>
|
||||
</div>
|
||||
</div>
|
||||
<div class="component-input" data-option="직접 입력">
|
||||
<div class="input-field">
|
||||
<input type="text" name="unitSelf" th:value="${detail.unitSelf}" maxlength="30" placeholder="단위를 입력해 주세요">
|
||||
<input type="text" id="incomeKind" name="incomeKind" th:value="${detail.incomeKind}" maxlength="30" placeholder="수입의 종류를 입력해 주세요">
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</section>
|
||||
|
||||
<hr>
|
||||
|
||||
<section class="form-group">
|
||||
<div class="component-input">
|
||||
<div class="input-label">
|
||||
<label for="price" class="label-txt">
|
||||
현금
|
||||
<i class="ico-required-mark" role="img" aria-label="필수">*</i>
|
||||
</label>
|
||||
<div class="component-input">
|
||||
<div class="input-label">
|
||||
<label for="sourcePurpose" class="label-txt">
|
||||
수입원
|
||||
<i class="ico-required-mark" role="img" aria-label="필수">*</i>
|
||||
</label>
|
||||
</div>
|
||||
<div class="input-field">
|
||||
<input type="text" id="sourcePurpose" name="sourcePurpose" th:value="${detail.sourcePurpose}" maxlength="30" placeholder="수입원을 입력해 주세요">
|
||||
</div>
|
||||
</div>
|
||||
<div class="input-field type-price">
|
||||
<input type="number" inputmode="numeric" pattern="[0-9]*" id="price" name="price" step="0" min="1" max="9999999999"
|
||||
th:value="${detail.price}" maxlength="10" placeholder="금액을 입력해 주세요">
|
||||
<span class="input-field-txt">원</span>
|
||||
</div>
|
||||
<ul class="guide-info">
|
||||
<li>예 : 30000</li>
|
||||
</ul>
|
||||
</div>
|
||||
</section>
|
||||
|
||||
<div class="component-input">
|
||||
<div class="input-label">
|
||||
<label for="estimatedValue" class="label-txt">
|
||||
현물평가액
|
||||
<i class="ico-required-mark" role="img" aria-label="필수">*</i>
|
||||
</label>
|
||||
</div>
|
||||
<div class="input-field type-price">
|
||||
<input type="number" inputmode="numeric" pattern="[0-9]*" id="estimatedValue" name="estimatedValue" step="0" min="1" max="9999999999"
|
||||
th:value="${detail.estimatedValue}" maxlength="10" placeholder="금액을 입력해 주세요">
|
||||
<span class="input-field-txt">원</span>
|
||||
</div>
|
||||
<ul class="guide-info">
|
||||
<li>예 : 30000</li>
|
||||
</ul>
|
||||
</div>
|
||||
</section>
|
||||
<hr>
|
||||
|
||||
<div class="component-btns">
|
||||
<div class="btns-row">
|
||||
<button type="button" class="btn btn-full btn-l btn-primary" onclick="modalControl.createVaild();">
|
||||
<span class="btn-txt">등록</span>
|
||||
</button>
|
||||
<section class="form-group">
|
||||
<div class="component-input">
|
||||
<div class="input-label">
|
||||
<label for="quantity" class="label-txt">
|
||||
수량
|
||||
</label>
|
||||
</div>
|
||||
<div class="input-field">
|
||||
<input type="number" inputmode="decimal" pattern="[0-9]*" id="quantity" name="quantity" min="1" max="9999999999"
|
||||
th:value="${detail.quantity}" maxlength="10" placeholder="수량을 입력해 주세요">
|
||||
</div>
|
||||
<ul class="guide-info">
|
||||
<li>예 : 2, 2.5</li>
|
||||
</ul>
|
||||
</div>
|
||||
<div class="select-group">
|
||||
<div class="select-label">
|
||||
<p class="label-txt">
|
||||
단위
|
||||
</p>
|
||||
</div>
|
||||
<div id="unitCode" class="component-select bottom-sheet" data-props-default="단위를 선택해 주세요" data-props-type="bottomSheet">
|
||||
<input type="hidden" name="unitCode" data-type="select" th:value="${detail.unitCode}">
|
||||
<button type="button" class="select-box">
|
||||
<span class="select-txt"></span>
|
||||
</button>
|
||||
<div class="select-options">
|
||||
<div class="select-header">
|
||||
<p>단위</p>
|
||||
<button type="button" class="select-close">
|
||||
<span class="hide-txt">닫기</span>
|
||||
</button>
|
||||
</div>
|
||||
<div class="select-scroll">
|
||||
<ul class="">
|
||||
<li class="option" th:each="uiCode : ${recordUnit}"
|
||||
th:data-value="${uiCode.id}"
|
||||
th:text="${uiCode.codeText}"
|
||||
th:selected="${uiCode.id eq detail.unitCode ? 'current' : ''}"
|
||||
></li>
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="component-input" data-option="직접 입력">
|
||||
<div class="input-field">
|
||||
<input type="text" name="unitSelf" th:value="${detail.unitSelf}" maxlength="30" placeholder="단위를 입력해 주세요">
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</section>
|
||||
|
||||
<hr>
|
||||
|
||||
<section class="form-group">
|
||||
<div class="component-input">
|
||||
<div class="input-label">
|
||||
<label for="price" class="label-txt">
|
||||
현금
|
||||
<i class="ico-required-mark" role="img" aria-label="필수">*</i>
|
||||
</label>
|
||||
</div>
|
||||
<div class="input-field type-price">
|
||||
<input type="number" inputmode="numeric" pattern="[0-9]*" id="price" name="price" step="0" min="1" max="9999999999"
|
||||
th:value="${detail.price}" maxlength="10" placeholder="금액을 입력해 주세요">
|
||||
<span class="input-field-txt">원</span>
|
||||
</div>
|
||||
<ul class="guide-info">
|
||||
<li>예 : 30000</li>
|
||||
</ul>
|
||||
</div>
|
||||
|
||||
<div class="component-input">
|
||||
<div class="input-label">
|
||||
<label for="estimatedValue" class="label-txt">
|
||||
현물평가액
|
||||
<i class="ico-required-mark" role="img" aria-label="필수">*</i>
|
||||
</label>
|
||||
</div>
|
||||
<div class="input-field type-price">
|
||||
<input type="number" inputmode="numeric" pattern="[0-9]*" id="estimatedValue" name="estimatedValue" step="0" min="1" max="9999999999"
|
||||
th:value="${detail.estimatedValue}" maxlength="10" placeholder="금액을 입력해 주세요">
|
||||
<span class="input-field-txt">원</span>
|
||||
</div>
|
||||
<ul class="guide-info">
|
||||
<li>예 : 30000</li>
|
||||
</ul>
|
||||
</div>
|
||||
</section>
|
||||
|
||||
<div class="component-btns">
|
||||
<div class="btns-row">
|
||||
<button type="button" class="btn btn-full btn-l btn-primary" onclick="modalControl.createVaild();">
|
||||
<span class="btn-txt">등록</span>
|
||||
</button>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<!--/* 수기 등록 e */-->
|
||||
<!--/* 영수증 등록 s */-->
|
||||
<div id="modelOcr" style="display: none;">
|
||||
<section class="form-group">
|
||||
<div class="segment-label">
|
||||
<p class="label-txt">
|
||||
영수증 첨부
|
||||
<i class="ico-required-mark" role="img" aria-label="필수">*</i>
|
||||
</p>
|
||||
</div>
|
||||
<div class="component-segment">
|
||||
<div class="component-file">
|
||||
<div class="file-list">
|
||||
<div class="file-item">
|
||||
<img class="profile-image-add" src="../../assets/images/acco/file_sample.png" alt="이미지샘플" />
|
||||
<button type="button" class="btn-delete"><span class="hide-txt">삭제</span></button>
|
||||
</div>
|
||||
<div class="file-item">
|
||||
<img class="profile-image-add" src="../../assets/images/acco/file_sample.png" alt="이미지샘플" />
|
||||
<button type="button" class="btn-delete"><span class="hide-txt">삭제</span></button>
|
||||
</div>
|
||||
<div class="file-item">
|
||||
<img class="profile-image-add" src="../../assets/images/acco/file_sample.png" alt="이미지샘플" />
|
||||
<button type="button" class="btn-delete"><span class="hide-txt">삭제</span></button>
|
||||
</div>
|
||||
</div>
|
||||
<button type="button" class="btn btn-m btn-link btn-full">
|
||||
<i class="ico-add ico-small" aria-hidden="true"></i>
|
||||
<span class="btn-txt">사진 첨부</span>
|
||||
</button>
|
||||
<ul class="guide-info">
|
||||
<li>영수증은 일일 최대 3개 등록하실 수 있습니다.</li>
|
||||
<li>
|
||||
최대 갯수 등록 후에는 수기 입력만 가능합니다. <br>
|
||||
(사진 1개당 5MB 이하)
|
||||
</li>
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
</section>
|
||||
|
||||
<div class="component-btns">
|
||||
<div class="btns-row">
|
||||
<!-- 버튼비활성 스타일 속성에 disabled 추가 -->
|
||||
<button type="button" class="btn btn-full btn-l btn-primary">
|
||||
<span class="btn-txt">등록</span>
|
||||
</button>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<!--/* 영수증 등록 e */-->
|
||||
</form>
|
||||
</div>
|
||||
</th:block>
|
||||
|
||||
@@ -239,6 +239,15 @@
|
||||
$input.val('').attr('disabled', true);
|
||||
$input.parent().parent().closest('.component-input').addClass('input-disabled');
|
||||
},
|
||||
changeModal(type) {
|
||||
if (type === 'self') {
|
||||
$('#modelSelf').show();
|
||||
$('#modelOcr').hide();
|
||||
} else {
|
||||
$('#modelSelf').hide();
|
||||
$('#modelOcr').show();
|
||||
}
|
||||
},
|
||||
createVaild() {
|
||||
modalControl.create();
|
||||
},
|
||||
|
||||
@@ -77,7 +77,8 @@
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
<button type="button" class="btn btn-m btn-secondary btn-full button-modal01" data-testid="button-modal01">
|
||||
<button type="button" class="btn btn-m btn-secondary btn-full button-modal01" data-testid="button-modal01"
|
||||
th:if="${btnActive}">
|
||||
<i class="ico-add ico-small" aria-hidden="true"></i>
|
||||
<span class="btn-txt">추가 등록</span>
|
||||
</button>
|
||||
|
||||
@@ -129,7 +129,8 @@
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
<button type="button" class="btn btn-m btn-secondary btn-full button-modal01" data-testid="button-modal01">
|
||||
<button type="button" class="btn btn-m btn-secondary btn-full button-modal01" data-testid="button-modal01"
|
||||
th:if="${btnActive}">
|
||||
<i class="ico-add ico-small" aria-hidden="true"></i>
|
||||
<span class="btn-txt">추가 등록</span>
|
||||
</button>
|
||||
|
||||
Reference in New Issue
Block a user