From da425bf0ac24de9543616459a124f055900bd384 Mon Sep 17 00:00:00 2001 From: Made Baruna Date: Mon, 29 Mar 2021 05:25:08 +0800 Subject: [PATCH] Add wish tally submit --- .env.example | 2 +- src/components/WishCounterAddModal.svelte | 2 + src/components/WishCounterHowToModal.svelte | 25 ++++++++- src/components/WishImportModal.svelte | 43 ++++++++++++++- src/functions/wish.js | 10 +++- src/functions/wishTally.js | 61 +++++++++++++++++++++ src/locales/en.json | 8 +++ src/locales/id.json | 8 +++ src/routes/wish/_counter.svelte | 45 ++++++++++----- 9 files changed, 182 insertions(+), 22 deletions(-) create mode 100644 src/functions/wishTally.js diff --git a/.env.example b/.env.example index 367b6918..4b0fa8ab 100644 --- a/.env.example +++ b/.env.example @@ -1,3 +1,3 @@ GOOGLE_DRIVE_CLIENT_ID= GOOGLE_DRIVE_API_KEY= -CORS_HOST= \ No newline at end of file +API_HOST=http://localhost:3001 diff --git a/src/components/WishCounterAddModal.svelte b/src/components/WishCounterAddModal.svelte index a862c5f3..1ee98e52 100644 --- a/src/components/WishCounterAddModal.svelte +++ b/src/components/WishCounterAddModal.svelte @@ -49,6 +49,7 @@ id: name.id, time: dayjs(time).unix(), pity, + manualInput: true, }; addPullDetail(pull); @@ -60,6 +61,7 @@ id: name.id, time: dayjs(time).unix(), pity, + manualInput: true, }; editPullDetail(pull); diff --git a/src/components/WishCounterHowToModal.svelte b/src/components/WishCounterHowToModal.svelte index c3474a64..70a18ede 100644 --- a/src/components/WishCounterHowToModal.svelte +++ b/src/components/WishCounterHowToModal.svelte @@ -1,18 +1,20 @@