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

Feature: Show link to invoice on order page #9

Open
ndeet opened this issue Sep 11, 2022 · 1 comment
Open

Feature: Show link to invoice on order page #9

ndeet opened this issue Sep 11, 2022 · 1 comment

Comments

@ndeet
Copy link
Collaborator

ndeet commented Sep 11, 2022

Useful scenarios are for showing payment receipts on BTCPay end or if the invoice has not expired yet for the customer to return to the invoice page.

See https://chat.btcpayserver.org/btcpayserver/pl/1ywbjj9t1bd4tkn694at7p7kth

@ndeet
Copy link
Collaborator Author

ndeet commented Sep 11, 2022

needs more work but the right hook to place it on the order page

function kekeromod_order_details_after_customer_details($order) {
    $url = $order->get_meta('BTCPay_redirect');
    echo "<a href='$url'>$url</a>";
}

add_action('woocommerce_order_details_after_customer_details', 'kekeromod_order_details_after_customer_details', 10, 1);

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

No branches or pull requests

1 participant