From c9c80dce957a8c54bab794cc358cbc562d6b3f59 Mon Sep 17 00:00:00 2001 From: vega Date: Fri, 1 Sep 2023 20:46:23 +0300 Subject: [PATCH] Fixes DB issues. Removes use of beautiful charts. --- .gitignore | 4 ++++ app/dao/EmotionDao.scala | 2 +- conf/db/data/triggers.csv | 4 ++-- ui/src/app/app.module.ts | 4 +--- ui/src/app/dashboard/dashboard.component.html | 2 -- 5 files changed, 8 insertions(+), 8 deletions(-) diff --git a/.gitignore b/.gitignore index fd5060e..9e8eb7b 100644 --- a/.gitignore +++ b/.gitignore @@ -9,3 +9,7 @@ db_dump /public/styles.*.js /public/polyfills.*.js /.env +/ui/node_modules +/node_modules +package-lock.json +package.json diff --git a/app/dao/EmotionDao.scala b/app/dao/EmotionDao.scala index 9f47f06..6885a0d 100644 --- a/app/dao/EmotionDao.scala +++ b/app/dao/EmotionDao.scala @@ -40,7 +40,7 @@ class EmotionDao { } def delete(id: String)(implicit connection: Connection): Int = { - SQL("DELETE FROM emotions WHERE emotion_id = {id}").on(Symbol("id") -> id).executeUpdate() + SQL("DELETE FROM emotions WHERE emotion_id = {id}").on("id"-> id).executeUpdate() } def findById(id: String)(implicit connection: Connection): Option[Emotion] = { diff --git a/conf/db/data/triggers.csv b/conf/db/data/triggers.csv index 57454d2..6d18f30 100644 --- a/conf/db/data/triggers.csv +++ b/conf/db/data/triggers.csv @@ -32,5 +32,5 @@ trigger_id,trigger_name,trigger_parent_id,created_by_user,description,created 31,Travel_destinations,22,,Travel destinations,2023-03-31 07:13:18 32,Nature,22,,Nature,2023-03-31 07:13:18 33,Social_gatherings,22,,Social gatherings,2023-03-31 07:13:18 -34,Places_with_specific_memories,22,,Places with specific memories,2023-03-31 07:13:1 -35,Other,,,Other,2023-03-31 07:13:1 +34,Places_with_specific_memories,22,,Places with specific memories,2023-03-31 07:13:18 +35,Other,,,Other,2023-03-31 07:13:18 diff --git a/ui/src/app/app.module.ts b/ui/src/app/app.module.ts index bb1572b..100d78d 100644 --- a/ui/src/app/app.module.ts +++ b/ui/src/app/app.module.ts @@ -45,7 +45,6 @@ import {MatGridListModule} from "@angular/material/grid-list"; import {MatTooltipModule} from "@angular/material/tooltip"; import {MatTabsModule} from "@angular/material/tabs"; import {NgxChartsModule} from "@swimlane/ngx-charts"; -import { BeautifulChartsModule } from 'ngx-beautiful-charts'; import { CustomDatePickerComponent } from './custom-date-picker/custom-date-picker.component'; export const MAT_DATE_FNS_FORMATS = { @@ -104,8 +103,7 @@ export const MAT_DATE_FNS_FORMATS = { MatGridListModule, MatTooltipModule, MatTabsModule, - NgxChartsModule, - BeautifulChartsModule + NgxChartsModule ], providers: [{ provide: DateAdapter, useClass: DateFnsAdapter }, { diff --git a/ui/src/app/dashboard/dashboard.component.html b/ui/src/app/dashboard/dashboard.component.html index 81b8695..c8f6103 100644 --- a/ui/src/app/dashboard/dashboard.component.html +++ b/ui/src/app/dashboard/dashboard.component.html @@ -14,8 +14,6 @@

Loading Emotions Chart...

-