fix: refresh YooKassa webapp payments

This commit is contained in:
3252a8
2026-05-24 18:47:37 +03:00
parent d1b9990bac
commit 235ee25d9f
8 changed files with 308 additions and 8 deletions
+8
View File
@@ -767,6 +767,14 @@ export async function mockApi(path, options = {}, context = {}) {
payment_id: 10001,
};
}
if (/^\/payments\/\d+$/.test(path) && String(options.method || "GET").toUpperCase() === "GET") {
return {
ok: true,
payment_id: Number(path.split("/").pop()),
status: "pending_yookassa",
paid: false,
};
}
if (path === "/tariffs/change" && String(options.method || "").toUpperCase() === "POST") {
return { ok: true, tariff_key: "business" };
}