Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

docs : author 추가 (이소민) #61

Merged
merged 2 commits into from
Mar 12, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,10 @@
import lombok.Builder;
import lombok.Getter;

/**
* author : 이소민
*/

@Getter
public class PaymentInfoDTO {
private String quotaInfo;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,9 @@
import lombok.Builder;
import lombok.Getter;

/**
* author : 이소민
*/
@Getter
public class OrderProduct {
private Long orderProductId;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,14 +15,15 @@
import java.util.List;
import java.util.stream.Collectors;

/**
* author : 이소민
*/
@Slf4j
@RequestMapping("/order")
@RestController
@RequiredArgsConstructor
public class OrderController {
private final OrderService orderService;
// todo memberinfo -> 주소 가져오기

// 주문 상품 여러개를 주문하는 경우
// xxx 예시: http://localhost:8080/member/order?products=%5B1%2C2%2C3%5D
// xxx: %5B 는 [ 를 의미
Expand Down
4 changes: 4 additions & 0 deletions src/main/java/com/hyundai/domain/orders/dto/OrderInfo.java
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,10 @@
import lombok.Getter;
import lombok.NoArgsConstructor;

/**
* author : 이소민
*/

@Getter
@NoArgsConstructor
public class OrderInfo {
Expand Down
4 changes: 4 additions & 0 deletions src/main/java/com/hyundai/domain/orders/dto/OrderSaveDTO.java
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,10 @@
import lombok.NoArgsConstructor;
import lombok.Setter;

/**
* author : 이소민
*/

@Getter
@Setter
@NoArgsConstructor
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,9 @@

import java.util.List;

/**
* author : 이소민
*/
@Getter
@Setter
@NoArgsConstructor
Expand Down
4 changes: 4 additions & 0 deletions src/main/java/com/hyundai/domain/orders/entity/Orders.java
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,10 @@

import java.time.LocalDateTime;

/**
* author : 이소민
*/

@Getter
@Setter
public class Orders {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,10 @@

import java.util.List;

/**
* author : 이소민
*/

@Service
@Transactional
@RequiredArgsConstructor
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,10 @@
import javax.annotation.PostConstruct;
import java.io.IOException;

/**
* author : 이소민
*/

@Slf4j
@RestController
@RequiredArgsConstructor
Expand All @@ -44,7 +48,6 @@ public void init() {
this.iamportClient = new IamportClient(apiKey, secretKey);
}

// todo 쿠폰, 포인트 추가
// 요청으로 받은 주문 상품들을 저장
@PostMapping("/payment")
public ResponseEntity<?> paymentComplete(@RequestBody OrdersRequestDTO ordersRequestDTO) throws IOException {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,9 @@
package com.hyundai.domain.payment.entity.enums;

/**
* author : 이소민
*/

public enum IamportApiURL {
GET_TOKEN_URL("https://api.iamport.kr/users/getToken"),
CANCEL_URL("https://api.iamport.kr/payments/cancel");
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,8 @@
package com.hyundai.domain.payment.entity.enums;

/**
* author : 이소민
*/
public enum PayStatus {
SUCCESS("결제완료"),
REFUND("환불완료"),
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,9 @@

import java.util.List;

/**
* author : 이소민
*/

@RequiredArgsConstructor
@Service
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,10 @@

import java.io.IOException;

/**
* author : 이소민
*/

public interface RefundService {
public void refundRequest(String access_token, String merchant_uid, String reason) throws IOException;
public String getToken(String apiKey, String secretKey) throws Exception;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,10 @@
import java.net.URL;
import java.util.Map;

/**
* author : 이소민
*/

@Transactional
@Slf4j
@RequiredArgsConstructor
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,9 @@
import java.io.IOException;
import java.util.List;

/**
* author : 이소민
*/

@Slf4j
@RestController
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,10 @@
import java.util.List;
import java.util.Map;

/**
* author : 이소민
*/

public class IngredientExpansion {
private static final Map<String, List<String>> ingredientExpansions = new HashMap<>();

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,10 @@
import lombok.NoArgsConstructor;
import lombok.Setter;

/**
* author : 이소민
*/

@Getter
@Setter
@NoArgsConstructor
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,9 @@

import java.util.List;

/**
* author : 이소민
*/
@Getter
@Setter
@NoArgsConstructor
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,10 @@
import java.util.List;
import java.util.stream.Collectors;

/**
* author : 이소민
*/

@Getter
@Setter
@NoArgsConstructor
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
package com.hyundai.domain.product.dto.response;

import lombok.Builder;
import lombok.Getter;
import lombok.*;

import java.util.List;

Expand All @@ -13,6 +12,9 @@
*/
@Getter
@Builder
@Setter
@NoArgsConstructor
@AllArgsConstructor
public class ProductWithCountResponseDTO {
private int total;
private List<ProductResponseDTO> productResponseDTOList;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,10 @@
import lombok.NoArgsConstructor;
import lombok.Setter;

/**
* author : 이소민
*/

@Getter
@Setter
@NoArgsConstructor
Expand Down
19 changes: 4 additions & 15 deletions src/main/java/com/hyundai/domain/product/entity/Product.java
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
package com.hyundai.domain.product.entity;

import com.hyundai.domain.product.dto.request.ProductRequestDTO;
import lombok.AllArgsConstructor;
import lombok.Getter;
import lombok.NoArgsConstructor;
Expand All @@ -10,6 +9,10 @@

import java.time.LocalDateTime;

/**
* author : 이소민
*/

@Getter
@Setter
@AllArgsConstructor
Expand All @@ -33,18 +36,4 @@ public class Product {
private LocalDateTime createdAt;
private LocalDateTime modifiedAt;
private LocalDateTime deletedAt;

/*public Product(ProductRequestDTO productRequestDTO) {
this.productName = productRequestDTO.getProductName();
this.productSubName = productRequestDTO.getProductSubName();
this.price = productRequestDTO.getPrice();
this.productType = productRequestDTO.getProductType();
this.stock = productRequestDTO.getStock();
this.discountRate = productRequestDTO.getDiscountRate();
this.amount = productRequestDTO.getAmount();
this.calorie = productRequestDTO.getCalorie();
this.storage = productRequestDTO.getProductStorage();
this.productDetail = productRequestDTO.getProductDetail();
this.thumbnailImageUrl = productRequestDTO.getThumbnailImageUrl();
}*/
}
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,11 @@

import java.util.*;


/**
* author : 이소민
*/

public interface ProductSearchRepository extends ElasticsearchRepository<Product, Long> {
default List<Product> search(SearchRequestDTO searchRequestDTO, ElasticsearchOperations elasticsearchOperations) {
BoolQueryBuilder boolQueryBuilder = QueryBuilders.boolQuery();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,10 @@
import java.io.IOException;
import java.util.List;

/**
* author : 이소민
*/

public interface ProductService {
ProductWithCountResponseDTO getProducts(ProductCriteria productCriteria, String memberId);
ProductResponseDTO getProductDetail(Long productId);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,10 @@

import static com.hyundai.domain.product.dto.response.ProductResponseDTO.listOf;

/**
* author : 이소민
*/

@Slf4j
@Service
@RequiredArgsConstructor
Expand All @@ -44,7 +48,7 @@ public class ProductServiceImpl implements ProductService{
@Transactional(readOnly = true)
// product나 product_like가 바뀌면 캐시 삭제 해줘야 함
// (product가 바뀌면 allEntries = true, product_like가 바뀌면 해당 key(memberId) 캐시 삭제)
// @Cacheable(cacheNames = "ProductResponseDTOs", key = "#memberId != null ? #memberId : 'anonymous'")
// @Cacheable(cacheNames = "ProductResponseDTOs", key = "#memberId != null ? #memberId : 'anonymous'")
public ProductWithCountResponseDTO getProducts(ProductCriteria productCriteria, String memberId) {
Map<String, Object> params = new HashMap<>();
params.put("memberId", memberId);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,9 @@
import java.nio.charset.StandardCharsets;
import java.util.List;

/**
* author : 이소민
*/

@RestController
@RequestMapping("/recommendation")
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,10 @@
import lombok.NoArgsConstructor;
import lombok.Setter;

/**
* author : 이소민
*/

@Getter
@Setter
@NoArgsConstructor
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,10 @@

import java.util.List;

/**
* author : 이소민
*/

@Getter
@Setter
@NoArgsConstructor
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,9 @@

import java.util.List;

/**
* author : 이소민
*/
public interface RecommendationService {
List<ProductResponseDTO> getRecommendWines(Long productId);

Expand Down
Loading
Loading