Skip to content
Snippets Groups Projects
Commit 1c63031e authored by Dominik Hebeler's avatar Dominik Hebeler
Browse files

handle storno events

parent 2d6799b2
No related branches found
No related tags found
No related merge requests found
Pipeline #9580 passed
...@@ -33,6 +33,17 @@ router.get("/event", (req, res) => { ...@@ -33,6 +33,17 @@ router.get("/event", (req, res) => {
payment_processor_data: req.query, payment_processor_data: req.query,
}) })
.then(async payment => redirect_url); .then(async payment => redirect_url);
} else if (req.query.function == "storno") {
return payment_reference
.createPayment({
price: price * -1,
converted_currency: req.query.currency,
converted_price: price,
payment_processor: Micropayment.NAME,
payment_processor_id: req.query.auth,
payment_processor_data: req.query,
})
.then(async payment => redirect_url);
} else { } else {
return redirect_url; return redirect_url;
} }
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment