Note Form » History » Version 23
Zhoujie Li, 07.03.2024 11:01
1 | 1 | Zhoujie Li | h1. Note Form |
---|---|---|---|
2 | 2 | Zhoujie Li | |
3 | h3. Motivation |
||
4 | |||
5 | Das Note soll dazu dienen auf beliebige Formular einer Notiz aufzumachen. Und ganz einfach für sich selber oder für anderen als toDo zu tagen. |
||
6 | |||
7 | h3. Datenstruktur |
||
8 | |||
9 | 21 | Zhoujie Li | Table *NoteForm* (wird mit geliefert als default table) |
10 | 2 | Zhoujie Li | * id <int> |
11 | * pIdCreator <int> |
||
12 | 5 | Carsten Rose | * xId <int> Die ID des aktuellen Formulars, zu dem die Notiz gehört. |
13 | 22 | Zhoujie Li | * formId <int> |
14 | * tableName <varchar> |
||
15 | 2 | Zhoujie Li | * note <text> |
16 | 22 | Zhoujie Li | * access <enum ('private','set of group','all')> Bestimmt die Sichtbarkeit der Notiz (privat, gruppenbasiert oder öffentlich). |
17 | 1 | Zhoujie Li | * reminderDate <datetime> |
18 | 22 | Zhoujie Li | * isDone <enum('yes','no')> |
19 | * formName <varchar> |
||
20 | 1 | Zhoujie Li | |
21 | 21 | Zhoujie Li | Table *Ggroup* (wird *nicht* mit geliefert) |
22 | * id <int> |
||
23 | * grId <int> |
||
24 | * reference <varchar> "note_form_tag" (this is mendatory for tags) |
||
25 | * name <varchar> |
||
26 | |||
27 | Table *GroupMember* (wird *nicht* mit geliefert) |
||
28 | * id <int> |
||
29 | * grId <int> |
||
30 | * xId <int> |
||
31 | |||
32 | 2 | Zhoujie Li | h3. Interface |
33 | |||
34 | * Ein Notiz-Button zeigt die Anzahl vorhandener Notizen an. |
||
35 | * Ein Modal-Fenster listet alle zugehörigen Notizen auf, inklusive einer Scrollbar für lange Listen. |
||
36 | * Die Benutzeroberfläche reagiert dynamisch auf Änderungen, die über AJAX-Requests durchgeführt werden. |
||
37 | * Funktionen im Modal-Fenster: |
||
38 | ** Done-Button zum Markieren von Notizen als erledigt. |
||
39 | ** Frei erstellbare Tags für spätere Filterung im Dashboard. |
||
40 | ** Löschen-Button zum Entfernen von Notizen. |
||
41 | ** Bearbeitungsmöglichkeit für ausgewählte Notizen. |
||
42 | |||
43 | *Skizze* |
||
44 | |||
45 | 3 | Zhoujie Li | !clipboard-202401291353-oc8zv.png! |
46 | 9 | Zhoujie Li | |
47 | 18 | Zhoujie Li | |
48 | *Mock up* |
||
49 | |||
50 | !clipboard-202402211132-bwgkj.png! !clipboard-202402211133-v2kfe.png! |
||
51 | 16 | Zhoujie Li | |
52 | 1 | Zhoujie Li | h3. Funktionbeschreibung |
53 | 15 | Zhoujie Li | |
54 | 23 | Zhoujie Li | |
55 | 9 | Zhoujie Li | *Mögliche Funktion* |
56 | * Falls keine Reminder gesetz wird wird dieser nicht in dashboad angezeigt? |
||
57 | 21 | Zhoujie Li | * Es wäre gut falls die Daten nicht erfolgreich gespeichert werden, werden sie im lokalen Speicher (LocalStorage) gesichert, um Datenverlust zu vermeiden. |
58 | 9 | Zhoujie Li | |
59 | 23 | Zhoujie Li | h3. Dashboard |
60 | |||
61 | *Hier ist ein einfacher Dashboard "report" zur Übersicht, in dem man angelegte Notizen sehen kann, und es wird farblich angezeigt, falls sie noch nicht auf done gesetz ist.* |
||
62 | |||
63 | <pre> |
||
64 | # |
||
65 | # NoteForm Dashboard |
||
66 | # |
||
67 | |||
68 | form = '{{form:SE}}' |
||
69 | |||
70 | |||
71 | |||
72 | { |
||
73 | sql = SELECT p.id AS _currentPid |
||
74 | FROM Person AS p |
||
75 | WHERE p.account = '{{feUser:UTE}}' |
||
76 | |||
77 | } |
||
78 | |||
79 | |||
80 | { |
||
81 | sql = SELECT f.id AS _fId |
||
82 | , nf.xId AS _xId |
||
83 | , nf.formName AS _formName |
||
84 | , nf.formTitle AS _fTitle |
||
85 | FROM NoteForm AS nf, Form AS f |
||
86 | WHERE f.id = nf.formId |
||
87 | GROUP BY nf.xId |
||
88 | |||
89 | head = <table class="table"> |
||
90 | <th></th> |
||
91 | <th>Title</th> |
||
92 | <th>Form</th> |
||
93 | <th>Done</th> |
||
94 | |||
95 | tail = </table> |
||
96 | |||
97 | { |
||
98 | sql = SELECT COUNT(*) AS _noteNotDone |
||
99 | FROM NoteForm AS nf |
||
100 | WHERE nf.formId = '{{fId:R0}}' |
||
101 | AND nf.xId = '{{xId:R0}}' |
||
102 | AND nf.isDone = 'no' |
||
103 | AND nf.hasToolbar = 'yes' |
||
104 | GROUP BY formId |
||
105 | } |
||
106 | |||
107 | { |
||
108 | sql = SELECT CONCAT('p:{{pageSlug:T}}?form={{formName:RE}}&r=',nf.xId,'&formId=',nf.formId,'&xId={{xId:RE}}|s|b|E') AS '_link|_hide|editFormButton' |
||
109 | , CONCAT('p:{{pageSlug:T}}?form=noteForm&r=0&formId={{fId:R0}}&xId={{xId:R0}}&formName={{formName:RE}}&formTitle={{fTitle:RE}}&type=1 |s|G:glyphicon-paperclip|t:<span' |
||
110 | , IF('{{noteNotDone:R0}}' > 0 AND COUNT(nf.xId) != 0 ,' style="background-color:#f89406"; class="badge">',' class="badge">'),COUNT(nf.xId),'</span>|b|g:_blank') AS '_link|_hide|editNoteButton' |
||
111 | , IF(nf.hasToolbar = 'yes' AND nf.isDone = 'no', 'pending',IF(nf.hasToolbar = 'no','not important','DONE')) AS _isDone |
||
112 | FROM NoteForm AS nf, Form AS f |
||
113 | WHERE nf.formId = f.id |
||
114 | AND f.id = '{{fId:R0}}' |
||
115 | AND nf.xId = '{{xId:R0}}' |
||
116 | AND ((nf.access = 'all') |
||
117 | OR (nf.access = 'private' AND nf.pIdCreator = '{{currentPid:RE}}')) |
||
118 | GROUP BY f.id |
||
119 | |||
120 | { |
||
121 | sql = SELECT '' |
||
122 | |||
123 | head = <tr><td> <div class="button-group"> {{&editFormButton:RE::-}} {{&editNoteButton:RE::-}}</td> </div> |
||
124 | |||
125 | tail = </tr> |
||
126 | |||
127 | { |
||
128 | sql = SELECT '{{fTitle:RE}}' |
||
129 | , '{{formName:RE}}' |
||
130 | , '{{isDone:RE}}' |
||
131 | |||
132 | fbeg = <td> |
||
133 | fend = </td> |
||
134 | |||
135 | } |
||
136 | } |
||
137 | } |
||
138 | } |
||
139 | |||
140 | </pre> |
||
141 | 9 | Zhoujie Li | |
142 | h2. noteForm |
||
143 | |||
144 | 2 | Zhoujie Li | h3. Use-Cases |
145 | |||
146 | 13 | Zhoujie Li | *Topic: QFQ Branch newFeature* |
147 | 6 | Carsten Rose | |
148 | [1] CR: |
||
149 | ich schreibe hier ein Protokoll |
||
150 | ich schreibe hier ein Protokoll |
||
151 | ich schreibe hier ein Protokoll |
||
152 | ich schreibe hier ein Protokoll |
||
153 | ich schreibe hier ein Protokoll |
||
154 | ich schreibe hier ein Protokoll |
||
155 | TAG: 'project x', 'protokoll' |
||
156 | ACCESS: All |
||
157 | |||
158 | [2] CR: |
||
159 | ich mache mir hier eine notizt mit Reminder: bitte Fenster oeffnen |
||
160 | Reminder: +24h |
||
161 | ACCESS: All |
||
162 | |||
163 | [3] ZL: |
||
164 | Es wird kalt, Fenster bitte schliessen |
||
165 | ACCESS: All |
||
166 | |||
167 | [4] CR: Ruecksprache mit Institutsleitung (IL) |
||
168 | TAG: 'projekt x', 'IL', |
||
169 | GROUP: IT-IL, BB-ZL-CR |
||
170 | ACCESS: All|Private |
||
171 | Reminder: +24h |
||
172 | DONE: wird durch CR gesetzt wenn Aufgabe abgeschlossen ist |
||
173 | |||
174 | ---------------- |
||
175 | |||
176 | * 'ACCESS: All' |
||
177 | * Dashboard: nicht anzeigen |
||
178 | * Detailansicht: anzeigen |
||
179 | |||
180 | * 'ACCESS: All,<group>' (ich bin member of '<group>') |
||
181 | 1 | Zhoujie Li | * Dashboard: anzeigen |
182 | * Detailansicht: anzeigen |
||
183 | 6 | Carsten Rose | |
184 | * 'ACCESS: Private' |
||
185 | 1 | Zhoujie Li | * Dashboard: anzeigen wenn ich der Owner bin |
186 | 6 | Carsten Rose | * Detailansicht: anzeigen wenn ich der Owner bin |
187 | |||
188 | 1 | Zhoujie Li | ----------------- |
189 | |||
190 | *Roadmap* |
||
191 | |||
192 | 10 | Zhoujie Li | *V.1.0* |
193 | 1 | Zhoujie Li | * Notiz Form mit 'text', 'done' |
194 | 6 | Carsten Rose | * Speichern via regulaerem QFQ Save |
195 | * Bestehende Notizen im Form anzeigen |
||
196 | 20 | Zhoujie Li | * Notiz Form mit 'tags' |
197 | 6 | Carsten Rose | * Bestehende Notizen editieren / loeschen |
198 | 21 | Zhoujie Li | * Neue Browser fenster |
199 | 1 | Zhoujie Li | |
200 | 11 | Zhoujie Li | |
201 | 20 | Zhoujie Li | *V.1.1* |
202 | 10 | Zhoujie Li | * Typeahead nach 'tags' suchen |
203 | 20 | Zhoujie Li | * Dashboard |
204 | * Reminder Email |
||
205 | 11 | Zhoujie Li | |
206 | |||
207 | 20 | Zhoujie Li | *V.1.2* |
208 | 1 | Zhoujie Li | * floating divs |
209 | 11 | Zhoujie Li | * minimieren / resize |
210 | 20 | Zhoujie Li | * oder Modal |