mirror of
https://github.com/GCMatters/hermes.git
synced 2026-02-04 13:40:13 +01:00
feat: image support
also translated some strings back into english
This commit is contained in:
@@ -1,11 +1,12 @@
|
||||
import { getEvent, getMyAccount, unhideElementById } from './generalUseHelpers.js';
|
||||
import { getEvent, getMyAccount, unhideElementById } from './generalUseHelpers.js';
|
||||
|
||||
async function createEvent() {
|
||||
// Pobieranie danych z formularza
|
||||
const title = (document.getElementById('title') as HTMLInputElement).value;
|
||||
const location = (document.getElementById('location') as HTMLInputElement).value;
|
||||
const description = (document.getElementById('description') as HTMLTextAreaElement).value;
|
||||
const eventDateRaw = (document.getElementById('eventDate') as HTMLInputElement).value;
|
||||
const title = (document.getElementById('title') as HTMLInputElement).value;
|
||||
const location = (document.getElementById('location') as HTMLInputElement).value;
|
||||
const description = (document.getElementById('description') as HTMLTextAreaElement).value;
|
||||
const imageURL = (document.getElementById('imageURL') as HTMLInputElement).value;
|
||||
const eventDateRaw = (document.getElementById('eventDate') as HTMLInputElement).value;
|
||||
|
||||
// Walidacja prostych pól
|
||||
if (!title || !location || !eventDateRaw) {
|
||||
@@ -19,6 +20,7 @@ async function createEvent() {
|
||||
title,
|
||||
location,
|
||||
description,
|
||||
imageURL,
|
||||
eventDate,
|
||||
};
|
||||
|
||||
@@ -62,4 +64,4 @@ document.addEventListener("DOMContentLoaded", async () => {
|
||||
createEvent();
|
||||
});
|
||||
}
|
||||
});
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user