Merge branch 'dev' into deploy-dev-admin
This commit is contained in:
@@ -48,8 +48,8 @@ public class AdminCreateValidator implements Validator {
|
|||||||
if (vo.getName() == null || vo.getName().isBlank()) {
|
if (vo.getName() == null || vo.getName().isBlank()) {
|
||||||
errors.rejectValue("name", "error.name", "이름을 입력해주세요.");
|
errors.rejectValue("name", "error.name", "이름을 입력해주세요.");
|
||||||
}
|
}
|
||||||
if (vo.getName().length() > 4) {
|
if (vo.getName().length() > 10) {
|
||||||
errors.rejectValue("name", "error.name", "이름은 4자리까지 입력가능합니다.");
|
errors.rejectValue("name", "error.name", "이름은 10자까지 입력가능합니다.");
|
||||||
}
|
}
|
||||||
if (vo.getPhone1() == null || vo.getPhone1().isBlank()) {
|
if (vo.getPhone1() == null || vo.getPhone1().isBlank()) {
|
||||||
errors.rejectValue("phone1", "error.phone1", "전화번호 앞자리를 입력해주세요.");
|
errors.rejectValue("phone1", "error.phone1", "전화번호 앞자리를 입력해주세요.");
|
||||||
|
|||||||
@@ -34,8 +34,8 @@ public class AdminUpdateValidator implements Validator {
|
|||||||
if (vo.getName() == null || vo.getName().isBlank()) {
|
if (vo.getName() == null || vo.getName().isBlank()) {
|
||||||
errors.rejectValue("name", "error.name", "이름을 입력해주세요.");
|
errors.rejectValue("name", "error.name", "이름을 입력해주세요.");
|
||||||
}
|
}
|
||||||
if (vo.getName().length() > 4) {
|
if (vo.getName().length() > 10) {
|
||||||
errors.rejectValue("name", "error.name", "이름은 4자리까지 입력가능합니다.");
|
errors.rejectValue("name", "error.name", "이름은 10자까지 입력가능합니다.");
|
||||||
}
|
}
|
||||||
if (vo.getPhone1() == null || vo.getPhone1().isBlank()) {
|
if (vo.getPhone1() == null || vo.getPhone1().isBlank()) {
|
||||||
errors.rejectValue("phone1", "error.phone1", "전화번호 앞자리를 입력해주세요.");
|
errors.rejectValue("phone1", "error.phone1", "전화번호 앞자리를 입력해주세요.");
|
||||||
|
|||||||
@@ -115,4 +115,5 @@ public class ResearcherDao implements ResearcherPortOut {
|
|||||||
}
|
}
|
||||||
return i;
|
return i;
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -17,6 +17,7 @@ import java.util.Objects;
|
|||||||
@RequiredArgsConstructor
|
@RequiredArgsConstructor
|
||||||
@RequestMapping(path = "/api/researcher")
|
@RequestMapping(path = "/api/researcher")
|
||||||
class ResearcherApiController {
|
class ResearcherApiController {
|
||||||
|
|
||||||
private final ResearcherPortIn researcherPortIn;
|
private final ResearcherPortIn researcherPortIn;
|
||||||
|
|
||||||
@GetMapping(path = "/list")
|
@GetMapping(path = "/list")
|
||||||
@@ -63,4 +64,5 @@ class ResearcherApiController {
|
|||||||
ResponseEntity<?> updateMappingHousehold(@RequestBody MappingHouseholdListReqVO reqVO ) {
|
ResponseEntity<?> updateMappingHousehold(@RequestBody MappingHouseholdListReqVO reqVO ) {
|
||||||
return ResponseEntity.status(HttpStatus.OK).body(researcherPortIn.updateMappingHousehold(reqVO));
|
return ResponseEntity.status(HttpStatus.OK).body(researcherPortIn.updateMappingHousehold(reqVO));
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
@@ -7,6 +7,7 @@ import org.springframework.data.domain.Page;
|
|||||||
import java.util.List;
|
import java.util.List;
|
||||||
|
|
||||||
public interface ResearcherPortIn {
|
public interface ResearcherPortIn {
|
||||||
|
|
||||||
Page<ResearchersDto> list(ResearchersListReqVO reqVO);
|
Page<ResearchersDto> list(ResearchersListReqVO reqVO);
|
||||||
ResearchersDto detail(Integer adminSeq);
|
ResearchersDto detail(Integer adminSeq);
|
||||||
Page<ResearchersMappingHouseholdDto> mappingHouseholdList(ResearchersDetailReqVO reqVO);
|
Page<ResearchersMappingHouseholdDto> mappingHouseholdList(ResearchersDetailReqVO reqVO);
|
||||||
@@ -17,4 +18,5 @@ public interface ResearcherPortIn {
|
|||||||
Integer visitHouseholdDelete(List<Integer> selectIds);
|
Integer visitHouseholdDelete(List<Integer> selectIds);
|
||||||
Page<GetPopupHouseholds> searchMappingHousehold(HouseholdSearchReqVO reqVO);
|
Page<GetPopupHouseholds> searchMappingHousehold(HouseholdSearchReqVO reqVO);
|
||||||
Integer updateMappingHousehold(MappingHouseholdListReqVO reqVO);
|
Integer updateMappingHousehold(MappingHouseholdListReqVO reqVO);
|
||||||
|
|
||||||
}
|
}
|
||||||
@@ -64,9 +64,9 @@ app:
|
|||||||
permit: 5
|
permit: 5
|
||||||
session:
|
session:
|
||||||
validity:
|
validity:
|
||||||
# 세션 유효기간(초) - 1시간 (3600초)
|
# 세션 유효기간(초) - 무한정으로 수정,,,
|
||||||
period:
|
period:
|
||||||
seconds: 3600
|
seconds: -1
|
||||||
maximum:
|
maximum:
|
||||||
# 최대 세션 갯수 (1일 경우 중복 로그인 불가)
|
# 최대 세션 갯수 (1일 경우 중복 로그인 불가)
|
||||||
num: 1
|
num: 1
|
||||||
|
|||||||
@@ -19,6 +19,9 @@
|
|||||||
left join household h ON h.seq = rhh.household_seq AND h.is_panel IS true and h.is_deleted = false
|
left join household h ON h.seq = rhh.household_seq AND h.is_panel IS true and h.is_deleted = false
|
||||||
where
|
where
|
||||||
ahr.role_id = 'ROLE_RESEARCHER'
|
ahr.role_id = 'ROLE_RESEARCHER'
|
||||||
|
<if test="searchField == '' and searchValue != null and searchValue != ''">
|
||||||
|
and ( a.name LIKE CONCAT('%', #{searchValue}, '%') or a.phone LIKE CONCAT('%', #{searchValue}, '%') )
|
||||||
|
</if>
|
||||||
<if test="searchField == 'name' and searchValue != null and searchValue != ''">
|
<if test="searchField == 'name' and searchValue != null and searchValue != ''">
|
||||||
and a.name LIKE CONCAT('%', #{searchValue}, '%')
|
and a.name LIKE CONCAT('%', #{searchValue}, '%')
|
||||||
</if>
|
</if>
|
||||||
|
|||||||
@@ -79,7 +79,7 @@
|
|||||||
<div class="input-field">
|
<div class="input-field">
|
||||||
<input id="name" type="text" name="name"
|
<input id="name" type="text" name="name"
|
||||||
th:classappend="${#fields.hasErrors('name')} ? 'is-invalid'"
|
th:classappend="${#fields.hasErrors('name')} ? 'is-invalid'"
|
||||||
th:field="*{name}"/>
|
th:field="*{name}" maxlength="10"/>
|
||||||
<div class="invalid-feedback fw-bold"
|
<div class="invalid-feedback fw-bold"
|
||||||
th:if="${#fields.hasErrors('name')}">
|
th:if="${#fields.hasErrors('name')}">
|
||||||
에러 메세지
|
에러 메세지
|
||||||
@@ -97,12 +97,12 @@
|
|||||||
</div>
|
</div>
|
||||||
<div class="component-input">
|
<div class="component-input">
|
||||||
<div class="input-field">
|
<div class="input-field">
|
||||||
<input type="number" id="phone1" name="phone1" placeholder="" th:field="*{phone1}">
|
<input type="number" id="phone1" name="phone1" placeholder="" th:field="*{phone1}" maxlength="4">
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="component-input">
|
<div class="component-input">
|
||||||
<div class="input-field">
|
<div class="input-field">
|
||||||
<input type="number" id="phone2" name="phone2" placeholder="" th:field="*{phone2}">
|
<input type="number" id="phone2" name="phone2" placeholder="" th:field="*{phone2}" maxlength="4">
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|||||||
@@ -165,7 +165,6 @@
|
|||||||
f.searchDisabled.value = '';
|
f.searchDisabled.value = '';
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
function goUpdate(adminId) {
|
function goUpdate(adminId) {
|
||||||
location.href = '/settings/admins/update/' + adminId; // 쿼리 파라미터 없이 이동
|
location.href = '/settings/admins/update/' + adminId; // 쿼리 파라미터 없이 이동
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -71,7 +71,7 @@
|
|||||||
<div class="input-field">
|
<div class="input-field">
|
||||||
<input id="name" type="text" name="name"
|
<input id="name" type="text" name="name"
|
||||||
th:classappend="${#fields.hasErrors('name')} ? 'is-invalid'"
|
th:classappend="${#fields.hasErrors('name')} ? 'is-invalid'"
|
||||||
th:field="*{name}"/>
|
th:field="*{name}" maxlength="10" />
|
||||||
<div class="invalid-feedback fw-bold"
|
<div class="invalid-feedback fw-bold"
|
||||||
th:if="${#fields.hasErrors('name')}">
|
th:if="${#fields.hasErrors('name')}">
|
||||||
에러 메세지
|
에러 메세지
|
||||||
@@ -89,7 +89,7 @@
|
|||||||
</div>
|
</div>
|
||||||
<div class="component-input">
|
<div class="component-input">
|
||||||
<div class="input-field">
|
<div class="input-field">
|
||||||
<input type="number" id="phone1" name="phone1" placeholder=""
|
<input type="number" id="phone1" name="phone1" placeholder="" maxlength="4"
|
||||||
th:value="${bindingVO.phone1 != null ? bindingVO.phone1 : ''}">
|
th:value="${bindingVO.phone1 != null ? bindingVO.phone1 : ''}">
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
@@ -99,7 +99,7 @@
|
|||||||
</div>
|
</div>
|
||||||
<div class="component-input">
|
<div class="component-input">
|
||||||
<div class="input-field">
|
<div class="input-field">
|
||||||
<input type="number" id="phone2" name="phone2" placeholder=""
|
<input type="number" id="phone2" name="phone2" placeholder="" maxlength="4"
|
||||||
th:value="${bindingVO.phone2 != null ? bindingVO.phone2 : ''}">
|
th:value="${bindingVO.phone2 != null ? bindingVO.phone2 : ''}">
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|||||||
@@ -25,7 +25,7 @@
|
|||||||
</div>
|
</div>
|
||||||
<div class="component-input">
|
<div class="component-input">
|
||||||
<div class="input-field">
|
<div class="input-field">
|
||||||
<input type="text" id="temp_input_0001" th:field="*{searchValue}" placeholder="검색어를 입력하세요.">
|
<input type="text" id="temp_input_0001" th:field="*{searchValue}" placeholder="검색어를 입력하세요." onkeypress="if(event.key === 'Enter') goSearch();">
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
@@ -181,6 +181,8 @@
|
|||||||
f.searchValue.value = '';
|
f.searchValue.value = '';
|
||||||
f.searchArea.value = '';
|
f.searchArea.value = '';
|
||||||
f.searchAccountDisabled.value = '';
|
f.searchAccountDisabled.value = '';
|
||||||
|
f.method = 'GET';
|
||||||
|
f.submit();
|
||||||
}
|
}
|
||||||
// 상세페이지 이동
|
// 상세페이지 이동
|
||||||
function goDetail(seq) {
|
function goDetail(seq) {
|
||||||
|
|||||||
@@ -101,7 +101,9 @@ public class FrontSecurityConfig {
|
|||||||
.clearAuthentication(true)
|
.clearAuthentication(true)
|
||||||
.logoutRequestMatcher(new AntPathRequestMatcher("/logout")))
|
.logoutRequestMatcher(new AntPathRequestMatcher("/logout")))
|
||||||
.sessionManagement(
|
.sessionManagement(
|
||||||
session -> session.maximumSessions(maxSessionNum).maxSessionsPreventsLogin(false))
|
session -> session.maximumSessions(maxSessionNum).maxSessionsPreventsLogin(false).expiredUrl("/login"))
|
||||||
|
.sessionManagement(
|
||||||
|
session -> session.invalidSessionUrl("/login"))
|
||||||
.oauth2Login(
|
.oauth2Login(
|
||||||
config ->
|
config ->
|
||||||
config
|
config
|
||||||
|
|||||||
Reference in New Issue
Block a user