Skip to content

Comments

Add the PaymentId and Receipt fields to the Transaction under the Order.#324

Merged
oliver006 merged 2 commits intobold-commerce:masterfrom
Min65535:master
May 16, 2025
Merged

Add the PaymentId and Receipt fields to the Transaction under the Order.#324
oliver006 merged 2 commits intobold-commerce:masterfrom
Min65535:master

Conversation

@Min65535
Copy link

Add the PaymentId and Receipt fields to the Transaction under the Order.

Copy link
Collaborator

@oliver006 oliver006 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for the PR!
Got one question about the receipt field.

Test bool `json:"test,omitempty"`
Authorization string `json:"authorization,omitempty"`
PaymentId string `json:"payment_id,omitempty"`
Receipt map[string]interface{} `json:"receipt,omitempty"`
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can we do better than map[string]interface{} and be more specific?
What do the docs say about receipt?

Copy link
Author

@Min65535 Min65535 May 16, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can we do better than map[string]interface{} and be more specific? What do the docs say about receipt?

image
This is the screenshoot from REST Admin API. REST Admin API
The display of the receiptJson type after clicking is shown in the screenshot below.

image
This is the screenshoot from GraphQL Admin API. GraphQL Admin API

image
image
These are the transactions of my different test orders.

Considering this document and test results, map[string]interface{} seems to be the better option.

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ahhhh, interesting, thanks for explaining, this makes sense.

Copy link
Collaborator

@oliver006 oliver006 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for the PR!

@oliver006 oliver006 merged commit 3e34eaa into bold-commerce:master May 16, 2025
3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants