Skip to content

Commit

Permalink
Merge pull request #242 from prgrms-web-devcourse-final-project/feature/
Browse files Browse the repository at this point in the history
#234-AI-prompt-추가

Feature/#234 ai prompt 추가
  • Loading branch information
Dom1046 authored Dec 26, 2024
2 parents cef2434 + 41408a8 commit 44f9e89
Show file tree
Hide file tree
Showing 6 changed files with 11 additions and 8 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@ public interface MemberRepository extends JpaRepository<Member, Long> {
"AND (:createAt IS NULL OR m.createdAt >= :createAt)")
Page<MemberGetResponseOnlyMember> memberListByUserId(
@Param("isActive") Boolean isActive,
@Param("userId") String userId,
@Param("userId") UserId userId,
@Param("createAt") LocalDateTime createAt,
Pageable pageable);

Expand All @@ -81,7 +81,7 @@ Page<MemberGetResponseOnlyMember> memberListByUserId(
" AND (:createAt IS NULL OR m.createdAt >= :createAt) ")
Page<MemberGetResponseOnlyMember> memberListByEmail(
@Param("isActive") Boolean isActive,
@Param("email") String email,
@Param("email") Email email,
@Param("createAt") LocalDateTime createAt,
Pageable pageable);

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ public Page<MemberGetResponseOnlyMember> getMemberListByUserId(
Boolean isActive = memberGetRequestByUserId.getIsActive();
String userId = memberGetRequestByUserId.getUserId();

return memberRepository.memberListByUserId(isActive, userId, createAt, pageable);
return memberRepository.memberListByUserId(isActive, new UserId(userId), createAt, pageable);
} catch (Exception e) {
log.error("회원리스트 조회에 실패하였습니다. {}", e.getMessage());
throw new MallangsCustomException(ErrorCode.FAILURE_REQUEST);
Expand All @@ -77,7 +77,7 @@ public Page<MemberGetResponseOnlyMember> getMemberListByEmail(
Boolean isActive = memberGetRequestByEmail.getIsActive();
String email = memberGetRequestByEmail.getEmail();

return memberRepository.memberListByEmail(isActive, email, createAt, pageable);
return memberRepository.memberListByEmail(isActive, new Email(email), createAt, pageable);
} catch (Exception e) {
log.error("회원리스트 조회에 실패하였습니다. {}", e.getMessage());
throw new MallangsCustomException(ErrorCode.FAILURE_REQUEST);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -82,6 +82,7 @@ public SecurityFilterChain defaultSecurityFilterChain(HttpSecurity http) throws
.csrf(AbstractHttpConfigurer::disable)
.formLogin(AbstractHttpConfigurer::disable)
.httpBasic(AbstractHttpConfigurer::disable);

// // oauth2
// http
// .oauth2Login((oauth2) -> oauth2
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@
import com.mallangs.domain.article.entity.CaseStatus;
import com.mallangs.domain.article.entity.LostArticle;
import com.mallangs.domain.article.entity.MapVisibility;
import com.mallangs.domain.board.entity.BoardStatus;
import com.mallangs.domain.member.entity.Member;
import com.mallangs.domain.member.entity.embadded.Email;
import com.mallangs.domain.member.entity.embadded.Nickname;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -193,6 +193,7 @@
// assertThat(draftResult.getContent()).hasSize(1);
// }
//

//// @Test
//// @DisplayName("관리자용 - 카테고리와 제목으로 게시글 검색")
//// void searchForAdmin() {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -48,17 +48,17 @@ public class ChatRoomRepositoryTests {
public void 모든데이터값넣기() {
// Member 저장
Member member = memberRepository.save(Member.builder()
.userId(new UserId("TestUserId"))
.userId(new UserId("TtUser11"))
.nickname(new Nickname("TestNickname"))
.email(new Email("Test@eamil.com"))
.email(new Email("Tasdt@eami1s1l.com"))
.password(new Password("1234aA!!", passwordEncoder))
.hasPet(true)
.build());

Member member2 = memberRepository.save(Member.builder()
.userId(new UserId("TestAdminId"))
.userId(new UserId("Te1dmnI1d"))
.nickname(new Nickname("TestNickname2"))
.email(new Email("Test2@eamil.com"))
.email(new Email("Tes2@eami1l.com"))
.password(new Password("1234aA!!", passwordEncoder))
.memberRole(MemberRole.ROLE_ADMIN)
.hasPet(false)
Expand Down

0 comments on commit 44f9e89

Please sign in to comment.