Closed lehuygiang28 closed 4 months ago
The latest updates on your projects. Learn more about Vercel for Git ↗︎
Name | Status | Preview | Comments | Updated (UTC) |
---|---|---|---|---|
vnpay | ✅ Ready (Inspect) | Visit Preview | 💬 Add feedback | May 21, 2024 11:05am |
The updates encompass several documentation and TypeScript files, introducing new functionalities and enhancing existing ones. Key changes include the addition of QueryDr
and QueryDrResponse
interfaces, new constants, and functions, as well as modifications to logging and error handling. Documentation has been updated to reflect these changes, providing clearer guidance and examples for users.
File(s) | Change Summary |
---|---|
docs/docs/examples.md |
Updated sidebar_position value from 7 to 8 . |
docs/docs/installation.md |
Changed section heading to "Khởi tạo đối tượng {#init-vnpay}". |
docs/docs/query-dr.md |
Introduced documentation for the queryDr API, including QueryDr and QueryDrResponse interfaces and examples. |
src/constants/response-map.constant.ts |
Added WRONG_CHECKSUM_KEY constant and updated various response maps with translations for it. |
src/types/common.type.ts |
Extended ResultVerified type to include transaction status, verification status, and error message. |
src/types/index.ts |
Added QueryDrResponse to exports in query-dr.type . |
src/types/query-dr.type.ts |
Enhanced QueryDr type and added new types: QueryDrResponse , QueryDrResponseLogger , and QueryDrResponseOptions . |
src/utils/common.ts |
Introduced getDateInGMT7 function for converting dates to GMT+7 timezone. |
src/vnpay.ts |
Enhanced queryDr method in VNPay class with added options, improved error handling, and updated response processing. |
Thank you for using CodeRabbit. We offer it for free to the OSS community and would appreciate your support in helping us grow. If you find it useful, would you consider giving us a shout-out on your favorite social media?
Pull Request Description
queryDr
method:queryDr
no longer throw an Error when checksum failed, useisVerified
from return object insteadqueryDr
queryDr
Type of Change
Please check the type of change your PR introduces:
Does this introduce a breaking change?
If yes, please describe the impact and migration path for existing applications:
isVerified
from return object instead of catch Error forqueryDr
methodSummary by CodeRabbit
Documentation
queryDr
API, detailing its usage and properties.New Features
WRONG_CHECKSUM_KEY
constant for error handling.getDateInGMT7
function for date conversion to GMT+7 timezone.Enhancements
queryDr
method.ResultVerified
type with additional fields and documentation.Bug Fixes
QueryDrResponseFromVNPay
for better compatibility.