refactor: update MainForm layout and payment method selection; localize submit button text

This commit is contained in:
2026-01-21 16:15:52 +01:00
parent 308b21ae6c
commit 9445f5d417
4 changed files with 156 additions and 77 deletions
+10 -6
View File
@@ -15,14 +15,18 @@ interface FormData {
}
export const submitFormData = async (data: FormData, username: string) => {
console.log(data);
try {
const response = await fetch(`http://localhost:8004/default/new-entry?username=${username}`, {
method: "POST",
headers: {
"Content-Type": "application/json",
const response = await fetch(
`http://localhost:8004/default/new-entry?username=${username}`,
{
method: "POST",
headers: {
"Content-Type": "application/json",
},
body: JSON.stringify(data),
},
body: JSON.stringify(data),
});
);
if (!response.ok) {
const errorText = await response.text();