From f41cbf148196f77b4ce0e2c912e14ee31dbf7837 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=C3=96zg=C3=BCr=20Kesim?= Date: Wed, 27 Dec 2023 13:20:30 +0100 Subject: [PATCH] init projects, no retrieval yet --- projects.go | 30 ++++++++++++++++++++++++++++++ 1 file changed, 30 insertions(+) diff --git a/projects.go b/projects.go index ab889f1..50ca2f0 100644 --- a/projects.go +++ b/projects.go @@ -1,5 +1,7 @@ package main +import "time" + /* This file is part of taler-dashboard Copyright (C) 2023 Özgür Kesim @@ -19,3 +21,31 @@ package main @author Özgür Kesim */ + +type Projects []Project + +type Project struct { + Id int + Name string + Description string + Status KeyVal + ViewState KeyVal `json:"view_state"` + Enabled bool + InheritGlobal bool `json:"inherit_global"` + AccessLevel KeyVal `json:"AccessLevel"` + Versions []Version + Categories []Category + // CustomFields []any `json:"custom_fields"` +} + +type Version struct { + KeyVal + Released bool + Obsolete bool + Timestamp time.Time +} + +type Category struct { + KeyVal + Project KeyVal +}