[BO] 공통코드 지역/세부지역, 업종대분류/업종중분류 - 계층형으로 일괄 변경
This commit is contained in:
@@ -141,24 +141,16 @@
|
||||
<th>지역<i class="ico-required-mark" role="img" aria-label="필수">*</i></th>
|
||||
<td>
|
||||
<div class="component-select">
|
||||
<select class="select-list" name="regionSubCode" required>
|
||||
<select class="select-list" name="regionSubCode" id="regionSubCode" required>
|
||||
<option value="">전체</option>
|
||||
<option th:each="item : ${regionSubList}"
|
||||
th:value="${item.id}"
|
||||
th:text="${item.codeValue + '. ' + item.codeText}"
|
||||
th:selected="${item.id == householdInfo.regionSubCode}">
|
||||
</select>
|
||||
</div>
|
||||
</td>
|
||||
<th>세부 지역<i class="ico-required-mark" role="img" aria-label="필수">*</i></th>
|
||||
<td>
|
||||
<div class="component-select">
|
||||
<select class="select-list" name="regionDetailCode" required>
|
||||
<select class="select-list" name="regionDetailCode" id="regionDetailCode" required>
|
||||
<option value="">전체</option>
|
||||
<option th:each="item : ${regionDetailList}"
|
||||
th:value="${item.id}"
|
||||
th:text="${item.codeValue + '. ' + item.codeText}"
|
||||
th:selected="${item.id == householdInfo.regionDetailCode}">
|
||||
</select>
|
||||
</div>
|
||||
</td>
|
||||
@@ -178,24 +170,16 @@
|
||||
<th>업종 대분류</th>
|
||||
<td>
|
||||
<div class="component-select">
|
||||
<select class="select-list" name="industryLargeCode">
|
||||
<option value="">전체</option>
|
||||
<option th:each="item : ${industryLargeList}"
|
||||
th:value="${item.id}"
|
||||
th:text="${item.codeValue + '. ' + item.codeText}"
|
||||
th:selected="${item.id == householdInfo.industryLargeCode}">
|
||||
<select class="select-list" name="industryLargeCode" id="industryLargeCode">
|
||||
<option value="">전체</option>>
|
||||
</select>
|
||||
</div>
|
||||
</td>
|
||||
<th>업종 중분류1</th>
|
||||
<td>
|
||||
<div class="component-select">
|
||||
<select class="select-list" name="industryMiddleCode">
|
||||
<select class="select-list" name="industryMiddleCode" id="industryMiddleCode">
|
||||
<option value="">전체</option>
|
||||
<option th:each="item : ${industryMiddleList}"
|
||||
th:value="${item.id}"
|
||||
th:text="${item.codeValue + '. ' + item.codeText}"
|
||||
th:selected="${item.id == householdInfo.industryMiddleCode}">
|
||||
</select>
|
||||
</div>
|
||||
</td>
|
||||
@@ -296,6 +280,36 @@
|
||||
</section>
|
||||
|
||||
<section layout:fragment="script">
|
||||
<script th:inline="javascript">
|
||||
const regionList = [[${regionSubList}]];
|
||||
const selectedRegionSubCode = /*[[${householdInfo.regionSubCode}]]*/ '';
|
||||
const selectedRegionDetailCode = /*[[${householdInfo.regionDetailCode}]]*/ '';
|
||||
|
||||
const industryLargeList = [[${industryLargeList}]];
|
||||
const selectedIndustryLargeCode = /*[[${householdInfo.industryLargeCode}]]*/ '';
|
||||
const selectedIndustryMiddleCode= /*[[${householdInfo.industryMiddleCode}]]*/ '';
|
||||
|
||||
$(document).ready(function () {
|
||||
// 지역, 세부지역 셀렉트박스 세팅
|
||||
setSelectBoxUiCode({
|
||||
codeList: regionList,
|
||||
parentSelector: '#regionSubCode',
|
||||
childSelector: '#regionDetailCode',
|
||||
selectedParentCode: selectedRegionSubCode,
|
||||
selectedChildCode: selectedRegionDetailCode
|
||||
});
|
||||
|
||||
// 업종 대분류, 중분류 셀렉트박스 세팅
|
||||
setSelectBoxUiCode({
|
||||
codeList: industryLargeList,
|
||||
parentSelector: '#industryLargeCode',
|
||||
childSelector: '#industryMiddleCode',
|
||||
selectedParentCode: selectedIndustryLargeCode,
|
||||
selectedChildCode: selectedIndustryMiddleCode
|
||||
});
|
||||
});
|
||||
</script>
|
||||
|
||||
<script th:inline="javascript">
|
||||
// 임가 수정
|
||||
const updateHousehold= () => {
|
||||
|
||||
Reference in New Issue
Block a user