Project

General

Profile

Actions

개선(improvement) #2645

closed

VCC cancel while new VCC setting under different Bank issue.

Added by Tracy Tran 3 months ago. Updated about 2 months ago.

Status:
완료성공(Resolve)
Priority:
높음(High)
Assignee:
Target version:
Start date:
12/17/2025
Due date:
12/17/2025
% Done:

100%

Estimated time:
Part:
Build env.:
Prod

Description

Case: K25120711507H01
Old setting is VCC under Hana card. VCC issued under prepaid Hana.
New setting is VCC under Citi card. VCC issued under Citi card.
Account team cancelled old VCC which is belong Hana Card while the new setting has been setup.
Causing unable to cancel VCC due to different issue bank.

==> Please check and improve this case by allowing cancel old vcc eventhough the new setting (different bank issue) is active.


Files


Related issues

Related to VOC - VOC support #2637: [Error] VCC status완료성공(Resolve)Tom Dong12/16/202512/16/2025

Actions
Actions #1

Updated by Tracy Tran 3 months ago

Actions #2

Updated by Tom Dong 3 months ago

Branch created: `develop-vn/tom/improvement-2645-vcc-cancel-while-new-vcc-setting-under-different-bank-issue`

Repository: oh-api
Workspace: ohmyhotel
Bitbucket URL: https://bitbucket.org/ohmyhotel/oh-api/branch/develop-vn/tom/improvement-2645-vcc-cancel-while-new-vcc-setting-under-different-bank-issue

Actions #3

Updated by Tom Dong 3 months ago

  1. Implementation Summary

Commit: `b760fb8236` - implement 2645 cancel vcc diff bank

  1. Problem
    When VCC was created under Bank A (Hana) but booking setting was later changed to Bank B (Citi), account team could not cancel the old VCC because the system was using Bank B's configuration instead of Bank A's.
  1. Solution
    Modified the VCC cancel flow to use the original VCC_TYPE_CODE from the payment record (when the VCC was created), not the current booking's VCC type setting.
  1. Files Changed (4 files, +287 lines)

1. VCCMapper.java (+5 lines)
- Added 4 new query method declarations:
- `getTemplateItemPaymentSeq()` - Get booking item with VCC type from payment record
- `getVendorPaymentConditionVccType()` - Get vendor payment condition by specific VCC type
- `getVendorPaymentVCCByVccType()` - Get VCC configuration ignoring date conditions (for historical VCC)
- `getCountryInfoByVccTypeCode()` - Get country info for specific VCC type

2. VCCService.java (+189 lines)
- Added `getVendorPaymentForCancel(bookingItemCode, paymentSeq)`:
- Retrieves VCC_TYPE_CODE from PM_PAYMENT_INFO (original VCC type when issued)
- Uses that VCC type to get correct bank configuration for cancel
- Handles fallback if payment VCC type is blank
- Added `diffVccTypeCodeYn()` helper method

3. PaymentVccService.java (+6/-2 lines)
- Modified to call `vccService.getVendorPaymentForCancel()` when paymentSeq is provided
- Falls back to original `getVendorPaymentCondition()` for other operations

4. VCCMapper.xml (+87 lines)
- Added 4 new SQL queries:
- `getTemplateItemPaymentSeq` - JOIN BK_BOOKING_HOTEL_ITEM with PM_PAYMENT_INFO to get VCC type from payment
- `getVendorPaymentConditionVccType` - Query with specific VCC type, ignores date condition for cancel
- `getVendorPaymentVCCByVccType` - Get VCC config by type without date restrictions
- `getCountryInfoByVccTypeCode` - Get country info from BS_DETAIL_CODE by VCC type

  1. Key Logic
    ```
    Old flow: Cancel VCC → Use current booking's VCC_TYPE_CODE → Fail if different bank
    New flow: Cancel VCC → Get VCC_TYPE_CODE from PM_PAYMENT_INFO → Use original bank config → Success
    ```

---
Branch: `develop-vn/tom/improvement-2645-vcc-cancel-while-new-vcc-setting-under-different-bank-issue`

Actions #4

Updated by Tom Dong 3 months ago

  • Due date set to 12/17/2025
  • Start date set to 12/17/2025
  • % Done changed from 0 to 100
Actions #5

Updated by Tom Dong 3 months ago

  • Status changed from 신규(New) to 완료(Done)
Actions #6

Updated by Tom Dong 3 months ago

  • Status changed from 완료(Done) to QA test
  • Assignee changed from Tom Dong to Tracy Tran
  • Build env. set to Staging
Actions #7

Updated by Tracy Tran 3 months ago

Checked on staging, cancelled VCC under diferent bank or curent setting ==> ok

Checked in Payment In/Out field, there is an error message display. Please check if this VCC has been cancelled ok or not.

Actions #8

Updated by Tom Dong 3 months ago

Đã check VCC - Error message đó là do test từ trước nên có, không ảnh hưởng đến hoạt động hiện tại.

Actions #9

Updated by Tom Dong 3 months ago

  • File Screenshot 2025-12-17 103430.png added
Actions #10

Updated by Tom Dong 3 months ago

  • File deleted (Screenshot 2025-12-17 103430.png)
Actions #12

Updated by Tom Dong 3 months ago

  • Status changed from 피드백(Feedback) to QA test
  • Assignee changed from Tom Dong to Tracy Tran
Actions #13

Updated by Tracy Tran 3 months ago

  • Status changed from QA test to 완료(Done)
  • Assignee changed from Tracy Tran to Tom Dong

If there is no prblem, please update this case on PROD as done testing on staging.

Actions #14

Updated by ziniy Kang 2 months ago

  • Status changed from 완료(Done) to 확인(Confirmed)
Actions #15

Updated by ziniy Kang 2 months ago

  • Status changed from 확인(Confirmed) to QA test
  • Assignee changed from Tom Dong to Tracy Truong
  • Build env. changed from Staging to Prod
Actions #16

Updated by Tracy Tran about 2 months ago

Tested on PROD
Booking K25120411677H01

And booking K25121511238H01

Actions

Also available in: Atom PDF

Add picture from clipboard (Maximum size: 50 MB)