grade colors sharing works fine ahh

This commit is contained in:
Kima
2023-09-27 23:02:28 +02:00
parent 14ce4c82fb
commit 64fb22de74
4 changed files with 11 additions and 9 deletions

View File

@@ -40,8 +40,8 @@ class FilcAPI {
static const allThemes = "$themeGet/all";
static const themeByID = "$themeGet/";
static const gradeColorsShare = "$baseUrl/v2/shared/theme/add";
static const gradeColorsGet = "$baseUrl/v2/shared/theme/get";
static const gradeColorsShare = "$baseUrl/v2/shared/grade-colors/add";
static const gradeColorsGet = "$baseUrl/v2/shared/grade-colors/get";
static const allGradeColors = "$gradeColorsGet/all";
static const gradeColorsByID = "$gradeColorsGet/";
@@ -214,6 +214,9 @@ class FilcAPI {
theme.json['panels_color'] = theme.panelsColor.value.toString();
theme.json['accent_color'] = theme.accentColor.value.toString();
// set linked grade colors
theme.json['grade_colors_id'] = theme.gradeColors.id;
http.Response res = await http.post(
Uri.parse(themeShare),
body: theme.json,