Project

General

Profile

Actions

New Function #188

closed

[API] PG 결제 컨펌 - 보완 처리

Added by Deca Park 10 months ago. Updated 10 months ago.

Status:
Closed
Priority:
Normal
Assignee:
Start date:
11/27/2023
Due date:
% Done:

0%

Estimated time:
Spent time:

Description

1.문제점 (Issue)

1) 앱에서 이미 처리된 주문결제를 다시 PG 결제 컨펌 호출 (백버튼 클릭)
  - [API] POST /api/pay_confirm (PG 결제 컨펌)
  - 이 경우 다음과 같은 에러 발생
    [PG confirm API] fail - paymentKey: gpMwnkjKyO6BYq7GWPVv4wK7RN4xNX8NE5vbo1d4JlALRXxz, orderId: 231127142350XBUB, error code: ALREADY_PROCESSED_PAYMENT, error message: 이미 처리된 결제 입니다.
  - 현재 API 로직에서 PG 결제 컨펌 에러 발생시 주문결제 데이터 삭제 처리

2.To-do

  1) [API] POST /api/pay_confirm (PG 결제 컨펌)

     a) OrderController.payConfirm()

       a-1) As-is
          - if pgPaymentService.processPayConfirm fails (return error), delete order data

       a-2) To-be
         [Logic]
         when 
processPayConfirm fails
            - if pgErrorCode = 'ALREADY_PROCESSED_PAYMENT', SKIP delete order
           - else
                + if st_order_payment.payment_status = 'PS01' (결제대기), delete order as current
                + else. SKIP delete order

Actions #1

Updated by Deca Park 10 months ago

  • Description updated (diff)
Actions #2

Updated by bryant bryant 10 months ago

  • Status changed from New to Resolved
  • Assignee changed from bryant bryant to Deca Park
Actions #3

Updated by Deca Park 10 months ago

  • Status changed from Resolved to Closed
Actions

Also available in: Atom PDF