diff --git a/src/main/java/com/project/mock/init/MockDataInit.java b/src/main/java/com/project/mock/init/MockDataInit.java deleted file mode 100644 index f6bff92..0000000 --- a/src/main/java/com/project/mock/init/MockDataInit.java +++ /dev/null @@ -1,216 +0,0 @@ -package com.project.mock.init; - -import java.time.LocalDateTime; - -import jakarta.annotation.PostConstruct; - -import org.springframework.stereotype.Component; -import org.springframework.transaction.annotation.Transactional; - -import com.project.mock.infra.entity.MockMessage; -import com.project.mock.infra.repository.MockMessageRepository; - -import lombok.RequiredArgsConstructor; - -@Component -@RequiredArgsConstructor -public class MockDataInit { - - private final MockMessageRepository repository; - - @PostConstruct - @Transactional - public void init() { - // 데이터 중복 적재 방지 - if (repository.count() > 0) { - return; - } - - long subId = 1001L; - - // ========================================== - // 1. [EMAIL] 청구서 (스타일 포함 완벽 렌더링) - // ========================================== - String billHtml = - """ - - -
- -
-
-
-

휴대폰 요금 청구서

-

이메일 청구서

-
-
-
청구 번호
-
INV-2026-01-099
-
-
-
- -
-
-
-

고객 정보

-
-

고객명: 홍길동

-

연락처: 010-1234-5678

-

이메일: hong@test.com

-

요금제: 5G 시그니처

-
-
-
-

청구 정보

-
-

청구 날짜: 2026년 01월 22일

-

납기일: 2026년 01월 31일

-

결제 방법: 자동이체 (우리은행)

-
-
-
-
- -
-
-
-

청구 요약

-

이번 달 요금 상세 내역입니다

-
-
- 총 청구 금액 -
89,500원
-
-
-
- -
-

요금 상세 내역

-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
항목상세금액
기본 요금5G 시그니처 110GB75,000원
부가 서비스V 컬러링3,300원
할인선택약정 할인-18,750원
소액 결제구글 플레이스토어 (NC소프트)29,950원
-
-
- -
-
-
- 청구 상태 -
- - - 결제 완료 - -
-
-
- 결제 예정일 -
2026년 01월 25일
-
-
-
- -
-

추가 정보

-
-
-

유의사항

-
    -
  • 납기일 이후 결제 시 연체료가 발생할 수 있습니다
  • -
  • 문의사항은 고객센터(114)로 연락주세요
  • -
-
-
-
- -
-

이 청구서는 4eum 서비스를 통해 발송되었습니다. © 2026 4eum. All rights reserved.

-
-
- """; - - // 이메일 저장 - repository.save( - MockMessage.builder() - .subId(subId) - .type("EMAIL") - .sender("4eum 통신") - .receiver("hong@test.com") - .subject("[1월] 휴대폰 요금 청구서가 도착했습니다.") - .body(billHtml) - .receivedAt(LocalDateTime.now().minusHours(2)) - .build()); - - // ========================================== - // 2. [SMS] 인증번호 - // ========================================== - repository.save( - MockMessage.builder() - .subId(subId) - .type("SMS") - .sender("1544-0010") - .receiver("010-1234-5678") - .subject(null) - .body("[Web 발신] 데이터 사용량 50% 초과하였습니다.") - .receivedAt(LocalDateTime.now().minusMinutes(30)) - .build()); - - // ========================================== - // 3. [SMS] 광고 - // ========================================== - repository.save( - MockMessage.builder() - .subId(subId) - .type("SMS") - .sender("02-114") - .receiver("010-1234-5678") - .subject(null) - .body("[Web 발신] 갤럭시 S26 출시 사전예약!\n지금 예약하면 버즈 프로 증정.\n무료수신거부 080-123-4567") - .receivedAt(LocalDateTime.now().minusDays(1)) - .build()); - } -} diff --git a/src/main/resources/templates/email.html b/src/main/resources/templates/email.html index b4789c4..26ac025 100644 --- a/src/main/resources/templates/email.html +++ b/src/main/resources/templates/email.html @@ -61,7 +61,6 @@

청구 정보

청구 날짜: 2023년 11월 15일

납기일: 2023년 11월 30일

-

결제 방법: 신용카드 (KB국민카드)

@@ -92,16 +91,26 @@

요금 상세 내역

+ + + + 요금제 + - - 기본 요금 - 프리미엄 5G 100GB - - 65,000원 - + + 5G 스탠다드 + + + 3,300원 + + +