Skip to content
Snippets Groups Projects
Verified Commit 8fd499c6 authored by Volker Schukai's avatar Volker Schukai :alien:
Browse files

chore: commit save point

parent 0710fe40
No related branches found
No related tags found
No related merge requests found
Showing
with 110 additions and 60 deletions
......@@ -10,6 +10,10 @@ const exitCodeCatchAll = 1
const defaultOverviewTemplate = `
---
block-headings: true
---
{{ if .HasChangelog }}
## Changelog
......@@ -103,7 +107,7 @@ Last Update: null
Items:
- ID: null
Name: null
# what is it, a image, font, legal information, access data, texts, decisions, ...
# what is it, a image, font, legal information, access data, texts, decisions, etc.
Type: null
# does this belong to a group
Group: null
......@@ -184,21 +188,20 @@ Privacy:
{{ end }}
{{ if .Privacy }}
#### Privacy
{{ range .Privacy }}
**{{ .Purpose }} ({{ .ID }})**
{{ .Description }}
{{ if .Purposes }}**{{ .Purposes }}** {{ end }}**({{ .ID }})**
| | |
|--|--|
| Category | {{ .Category }} |
{{ if .Description }} {{ .Description }}
{{ end }}
| | |
|-----------------------|----------------------------|
| Category | {{ .Category }} |
| Data Retention Period | {{ .DataRetentionPeriod }} |
| Legal Basis | {{ .LegalBasis }} |
| Transfers | {{ .Transfers }} |
| Legal Basis | {{ .LegalBasis }} |
| Transfers | {{ .Transfers }} |
{{ end }}
{{ end }}
......
......@@ -40,12 +40,23 @@ func splitYamlParts(content []byte) (error, contentRequirement) {
text += before
a, b, found := strings.Cut(remaining, "...")
a, b, found := strings.Cut(remaining, "\n...")
if !found {
a, b, found = strings.Cut(remaining, "---")
a, b, found = strings.Cut(remaining, "\n---")
if !found {
return errors.New("the file does not contain a definition block"), contentRequirement{}
a, b, found = strings.Cut(remaining, "...")
if !found {
a, b, found = strings.Cut(remaining, "---")
if !found {
return errors.New("the file does not contain a definition block"), contentRequirement{}
}
}
}
}
......@@ -65,10 +76,32 @@ func splitYamlParts(content []byte) (error, contentRequirement) {
return err, contentRequirement{}
}
tempItem := []Item{}
for i, _ := range data.Items {
if data.Items[i].ID == "" {
continue
}
data.Items[i].ID = data.ID + "-" + data.Items[i].ID
tempItem = append(tempItem, data.Items[i])
}
data.Items = tempItem
p := []Privacy{}
for i, _ := range data.Privacy {
if data.Privacy[i].ID == "" {
continue
}
data.Privacy[i].ID = data.ID + "-" + data.Privacy[i].ID
p = append(p, data.Privacy[i])
}
data.Privacy = p
req := contentRequirement{}
req.data = data
......
......@@ -55,7 +55,7 @@ Last Update: null
Items:
- ID: null
Name: null
# what is it, a image, font, legal information, access data, texts, decisions, ...
# what is it, a image, font, legal information, access data, texts, decisions, etc.
Type: null
# does this belong to a group
Group: null
......@@ -117,6 +117,7 @@ Privacy:
...
### {{ .Title }} - {{ .ID }}
#### Subheading
......@@ -130,33 +131,46 @@ Privacy:
| ID | Name | Delivery until | Provided on |
|--------------------|--------------|----------------------:|-----------------------------------------:|
{{ range .Items
}}| {{ .ID }} | {{ .Name }} | {{ .DeliveryUntil.Format "02.Jan" }} | {{ .ProvidedOn.Format "02.Jan" }} |
{{ range .Items
}}| {{ .ID }} | {{ .Name }} | {{ .DeliveryUntil.Format "02.Jan" }} | {{ .ProvidedOn.Format "02.Jan" }} |
{{ end }}
{{ end }}
{{ if .Privacy }}
#### Privacy
{{ range .Privacy }}
**{{ .Purpose }} ({{ .ID }})**
{{ .Description }}
{{ if .Purposes }}**{{ .Purposes }}** {{ end }}**({{ .ID }})**
| | |
|--|--|
| Category | {{ .Category }} |
{{ if .Description }} {{ .Description }}
{{ end }}
| | |
|-----------------------|----------------------------|
| Category | {{ .Category }} |
| Data Retention Period | {{ .DataRetentionPeriod }} |
| Legal Basis | {{ .LegalBasis }} |
| Transfers | {{ .Transfers }} |
| Legal Basis | {{ .LegalBasis }} |
| Transfers | {{ .Transfers }} |
{{ end }}
{{ end }}
## Level 2
test
### Level 3
test
#### Level 4
test
##### Level 5
test
......@@ -55,7 +55,7 @@ Last Update: null
Items:
- ID: null
Name: null
# what is it, a image, font, legal information, access data, texts, decisions, ...
# what is it, a image, font, legal information, access data, texts, decisions, etc.
Type: null
# does this belong to a group
Group: null
......@@ -141,7 +141,7 @@ Privacy:
#### Privacy
{{ range .Privacy }}
**{{ .Purpose }} ({{ .ID }})**
**{{ .Purposes }} ({{ .ID }})**
{{ .Description }}
......
......@@ -53,9 +53,9 @@ Last Update: null
# the individual items as a list
Items:
- ID: null
- ID: XXX
Name: null
# what is it, a image, font, legal information, access data, texts, decisions, ...
# what is it, a image, font, legal information, access data, texts, decisions, etc.
Type: null
# does this belong to a group
Group: null
......@@ -141,7 +141,7 @@ Privacy:
#### Privacy
{{ range .Privacy }}
**{{ .Purpose }} ({{ .ID }})**
**{{ .Purposes }} ({{ .ID }})**
{{ .Description }}
......
......@@ -55,7 +55,7 @@ Last Update: null
Items:
- ID: null
Name: null
# what is it, a image, font, legal information, access data, texts, decisions, ...
# what is it, a image, font, legal information, access data, texts, decisions, etc.
Type: null
# does this belong to a group
Group: null
......@@ -141,7 +141,7 @@ Privacy:
#### Privacy
{{ range .Privacy }}
**{{ .Purpose }} ({{ .ID }})**
**{{ .Purposes }} ({{ .ID }})**
{{ .Description }}
......
......@@ -55,7 +55,7 @@ Last Update: null
Items:
- ID: null
Name: null
# what is it, a image, font, legal information, access data, texts, decisions, ...
# what is it, a image, font, legal information, access data, texts, decisions, etc.
Type: null
# does this belong to a group
Group: null
......@@ -141,7 +141,7 @@ Privacy:
#### Privacy
{{ range .Privacy }}
**{{ .Purpose }} ({{ .ID }})**
**{{ .Purposes }} ({{ .ID }})**
{{ .Description }}
......
......@@ -55,7 +55,7 @@ Last Update: null
Items:
- ID: null
Name: null
# what is it, a image, font, legal information, access data, texts, decisions, ...
# what is it, a image, font, legal information, access data, texts, decisions, etc.
Type: null
# does this belong to a group
Group: null
......@@ -141,7 +141,7 @@ Privacy:
#### Privacy
{{ range .Privacy }}
**{{ .Purpose }} ({{ .ID }})**
**{{ .Purposes }} ({{ .ID }})**
{{ .Description }}
......
......@@ -55,7 +55,7 @@ Last Update: null
Items:
- ID: null
Name: null
# what is it, a image, font, legal information, access data, texts, decisions, ...
# what is it, a image, font, legal information, access data, texts, decisions, etc.
Type: null
# does this belong to a group
Group: null
......@@ -141,7 +141,7 @@ Privacy:
#### Privacy
{{ range .Privacy }}
**{{ .Purpose }} ({{ .ID }})**
**{{ .Purposes }} ({{ .ID }})**
{{ .Description }}
......
......@@ -55,7 +55,7 @@ Last Update: null
Items:
- ID: null
Name: null
# what is it, a image, font, legal information, access data, texts, decisions, ...
# what is it, a image, font, legal information, access data, texts, decisions, etc.
Type: null
# does this belong to a group
Group: null
......@@ -141,7 +141,7 @@ Privacy:
#### Privacy
{{ range .Privacy }}
**{{ .Purpose }} ({{ .ID }})**
**{{ .Purposes }} ({{ .ID }})**
{{ .Description }}
......
......@@ -55,7 +55,7 @@ Last Update: null
Items:
- ID: null
Name: null
# what is it, a image, font, legal information, access data, texts, decisions, ...
# what is it, a image, font, legal information, access data, texts, decisions, etc.
Type: null
# does this belong to a group
Group: null
......@@ -141,7 +141,7 @@ Privacy:
#### Privacy
{{ range .Privacy }}
**{{ .Purpose }} ({{ .ID }})**
**{{ .Purposes }} ({{ .ID }})**
{{ .Description }}
......
......@@ -55,7 +55,7 @@ Last Update: null
Items:
- ID: null
Name: null
# what is it, a image, font, legal information, access data, texts, decisions, ...
# what is it, a image, font, legal information, access data, texts, decisions, etc.
Type: null
# does this belong to a group
Group: null
......@@ -141,7 +141,7 @@ Privacy:
#### Privacy
{{ range .Privacy }}
**{{ .Purpose }} ({{ .ID }})**
**{{ .Purposes }} ({{ .ID }})**
{{ .Description }}
......
......@@ -55,7 +55,7 @@ Last Update: null
Items:
- ID: null
Name: null
# what is it, a image, font, legal information, access data, texts, decisions, ...
# what is it, a image, font, legal information, access data, texts, decisions, etc.
Type: null
# does this belong to a group
Group: null
......@@ -141,7 +141,7 @@ Privacy:
#### Privacy
{{ range .Privacy }}
**{{ .Purpose }} ({{ .ID }})**
**{{ .Purposes }} ({{ .ID }})**
{{ .Description }}
......
......@@ -55,7 +55,7 @@ Last Update: null
Items:
- ID: null
Name: null
# what is it, a image, font, legal information, access data, texts, decisions, ...
# what is it, a image, font, legal information, access data, texts, decisions, etc.
Type: null
# does this belong to a group
Group: null
......@@ -141,7 +141,7 @@ Privacy:
#### Privacy
{{ range .Privacy }}
**{{ .Purpose }} ({{ .ID }})**
**{{ .Purposes }} ({{ .ID }})**
{{ .Description }}
......
......@@ -55,7 +55,7 @@ Last Update: null
Items:
- ID: null
Name: null
# what is it, a image, font, legal information, access data, texts, decisions, ...
# what is it, a image, font, legal information, access data, texts, decisions, etc.
Type: null
# does this belong to a group
Group: null
......@@ -141,7 +141,7 @@ Privacy:
#### Privacy
{{ range .Privacy }}
**{{ .Purpose }} ({{ .ID }})**
**{{ .Purposes }} ({{ .ID }})**
{{ .Description }}
......
......@@ -55,7 +55,7 @@ Last Update: null
Items:
- ID: null
Name: null
# what is it, a image, font, legal information, access data, texts, decisions, ...
# what is it, a image, font, legal information, access data, texts, decisions, etc.
Type: null
# does this belong to a group
Group: null
......@@ -141,7 +141,7 @@ Privacy:
#### Privacy
{{ range .Privacy }}
**{{ .Purpose }} ({{ .ID }})**
**{{ .Purposes }} ({{ .ID }})**
{{ .Description }}
......
......@@ -55,7 +55,7 @@ Last Update: null
Items:
- ID: null
Name: null
# what is it, a image, font, legal information, access data, texts, decisions, ...
# what is it, a image, font, legal information, access data, texts, decisions, etc.
Type: null
# does this belong to a group
Group: null
......@@ -141,7 +141,7 @@ Privacy:
#### Privacy
{{ range .Privacy }}
**{{ .Purpose }} ({{ .ID }})**
**{{ .Purposes }} ({{ .ID }})**
{{ .Description }}
......
......@@ -55,7 +55,7 @@ Last Update: null
Items:
- ID: null
Name: null
# what is it, a image, font, legal information, access data, texts, decisions, ...
# what is it, a image, font, legal information, access data, texts, decisions, etc.
Type: null
# does this belong to a group
Group: null
......@@ -141,7 +141,7 @@ Privacy:
#### Privacy
{{ range .Privacy }}
**{{ .Purpose }} ({{ .ID }})**
**{{ .Purposes }} ({{ .ID }})**
{{ .Description }}
......
......@@ -55,7 +55,7 @@ Last Update: null
Items:
- ID: null
Name: null
# what is it, a image, font, legal information, access data, texts, decisions, ...
# what is it, a image, font, legal information, access data, texts, decisions, etc.
Type: null
# does this belong to a group
Group: null
......@@ -141,7 +141,7 @@ Privacy:
#### Privacy
{{ range .Privacy }}
**{{ .Purpose }} ({{ .ID }})**
**{{ .Purposes }} ({{ .ID }})**
{{ .Description }}
......
......@@ -55,7 +55,7 @@ Last Update: null
Items:
- ID: null
Name: null
# what is it, a image, font, legal information, access data, texts, decisions, ...
# what is it, a image, font, legal information, access data, texts, decisions, etc.
Type: null
# does this belong to a group
Group: null
......@@ -141,7 +141,7 @@ Privacy:
#### Privacy
{{ range .Privacy }}
**{{ .Purpose }} ({{ .ID }})**
**{{ .Purposes }} ({{ .ID }})**
{{ .Description }}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment