Project @ iMath: Issueshttps://project.math.uzh.ch/https://project.math.uzh.ch/favicon.ico?16668783892024-03-20T23:59:51ZProject @ iMath
Redmine QFQ - Bug #18184 (New): _link combination of g:_blank and q:.. not workinghttps://project.math.uzh.ch/issues/181842024-03-20T23:59:51ZEnis Nuredini
<p>Wird das special column name _link in Verbindung mit g:_blank und q:... verwendet dann wird nach Klick darauf nicht in einem neuem Tab geöffnet sondern im aktuellen. Das Attribut target wird auf den Button korrekt gesetzt. Es scheint etwas mit dem Handling beim Bestätigen des Alerts zu tun.</p> QFQ - Bug #18163 (New): Form: reload current record after use of sqlBefore/sqlAfter and before Fo...https://project.math.uzh.ch/issues/181632024-03-17T15:40:12ZCarsten Rosecarsten.rose@math.uzh.ch
<p>Scheinbar wird der primary Record nicht neu geladen, falls dieser mit sqlBefore/sqlAfter in einem Native FE nochmal angepasst wurde. Erst nach Page Reload wird der aktuelle Wert gezeigt.</p>
<p>Wird die gleiche Query in einem Action FE gefeuert stimmen die angezeigten Werte direkt nach dem Save, der akuelle Record wird nochmal neu geladen bevor er angezeigt wird.</p>
<p>Aufgefallen ist bei der Erfassung einer getrennten Zeitangabe im Form `myVorlesungPruefungNotiz`.</p>
<p><img src="https://project.math.uzh.ch/attachments/download/9519/clipboard-202403171638-kglq1.png" alt="" /></p>
<p><img src="https://project.math.uzh.ch/attachments/download/9520/clipboard-202403171639-tlp2t.png" alt="" /></p> QFQ - Feature #18162 (New): Form / Select List: save outdated key/value even it no longer exist i...https://project.math.uzh.ch/issues/181622024-03-17T14:56:05ZCarsten Rosecarsten.rose@math.uzh.ch
<p>Szenario:</p>
<ul>
<li>Fuer eine Masterarbeit wird ein Betreuer eingetragen. </li>
<li>Die Liste der potentiellen Betreuer veraendert sich. Z.B. koennte eine Person von frueher heute nicht mehr den Status 'Betreuer' haben.</li>
<li>Wird eine solche MA aufgerufen wird nicht mehr der urspruengliche Betreuer angezeigt und beim erneuten Speichern gibt es ein Problem.</li>
</ul>
<p>Vorschlag:</p>
<ul>
<li><code>FE.parameter.sqlGetItemSaved = {{SELECT p.id, p.name FROM Person AS p WHERE p.id={{pId:R}}</code></li>
<li>Wird die ItemList gebaut, wird überprüft ob die gespeicherte Id (oder Value falls es keine ID gibt) noch existiert.</li>
<li>Ja: all done, no further action</li>
<li>Nein:
<ul>
<li>Evaluate <code>FE.parameter.sqlGetItemSaved</code></li>
<li>Fuege Key/Value an der richtigen Stelle (Sortierung) ein.</li>
<li>Falls moeglich stelle den Eintrag 'kursiv' dar ('muted' waere schlecht, denn das suggeriert das der Eintrag nicht ausgewaehlt werden koennte).</li>
</ul></li>
</ul>
<ul>
<li>Die Situation koennte auftreten bei: SELECT, CHEKBOX, RADIO</li>
</ul> QFQ - Bug #18155 (New): Form escapeTypeDefault btn-group not workinghttps://project.math.uzh.ch/issues/181552024-03-15T11:03:10ZEnis Nuredini
<p>Die Auswahl eines escapeTypeDefault im Form Editor macht keinen Unterschied. Es verändert sich nichts.</p> QFQ - Bug #18154 (New): Form autofocus not workinghttps://project.math.uzh.ch/issues/181542024-03-15T11:01:48ZEnis Nuredini
<p>Autofocus funktioniert im Formular schon seit längerem nicht mehr. Obwohl das Attribut richtig gesetzt wird beim jeweiligem Element ist der Effekt nicht aktiv im Frontend.</p>
<p>Wir konnten beobachten dass beim erstmaligem Laden der Autofocus für 1sek. erschienen und danach verschwunden ist. Folgende Reloads zeigten diesen gar nicht mehr an.</p> QFQ - Feature #18085 (New): FE Input Email Adressbook: a) Typeahead, b) check valid and markhttps://project.math.uzh.ch/issues/180852024-03-06T09:07:34ZCarsten Rosecarsten.rose@math.uzh.ch
<a name="Request"></a>
<h2 >Request<a href="#Request" class="wiki-anchor">¶</a></h2>
<ul>
<li>Im IK Tool werden beim Antrag Email-Adressen von weiteren verantwortlichen Personen erfasst.</li>
<li>Es kommt regelmaessig vor das die Adressen einen Typo enthalten.</li>
<li>Ziel
<ul>
<li>Bei der Eingabe TypeAhead vom UZH Adressebook anbieten.</li>
<li>Bei 'Focus Lost' Emailadressen pruefen und markieren ok/fail.</li>
</ul></li>
</ul>
<a name="Vorschlag"></a>
<h2 >Vorschlag<a href="#Vorschlag" class="wiki-anchor">¶</a></h2>
<ul>
<li>Wird erkannt dass die Email Adresse eine <code>uzh.ch</code> Adresse ist, kann ein LDAP Lookup gemacht werden um zu ueberpruefen ob die Adresse im UZH AD vorhanden ist.</li>
<li>Ist die Adresse bekannt, wird sie gruen, sonst gelb (Tooltip: Address not found in UZH adress book).</li>
<li>Non uzh.ch Adressen werden so nicht geprueft.</li>
<li>Option 'internal check': es koennen Tabellen, Spalten spezifiziert werden (Tool intern),ob die Adresse bereits benutzt wurde. Falls gefunden wird sie ebenfalls gruen.</li>
<li>Der Check gegen das Adressbuch muss erst gemacht werden bei Focus Lost.</li>
<li>Der Check sollte vom Server gestartet werden: Zugriff auf den AD ist beschraenkt (Firewall, Credentials)</li>
<li>Wir brauchen einen neuen API Call der SIP protected ist.</li>
<li>Beim Laden des Forms ist der Check vermutlich nicht so wichtig, kann erstmal weggelassen werden.</li>
<li>Die Credentials sollten in der zentrallen QFQ config Datei sein (wie UZH webpass)</li>
<li>Die LDAP Abfrage sollte zentral in der QFQ Extension Config konfigurierbar sein, pro FE kann das Setting uberschrieben werden.</li>
<li>Option: mehrere Emailadressen in einem FE-Input Elemente erfassen (space, komma separiert) und individuell pruefen & markieren.</li>
</ul>
<p>EmailAdressbookVerify=<br />EmailAdressbookTypeahead=</p>
<a name="Check"></a>
<h2 >Check<a href="#Check" class="wiki-anchor">¶</a></h2>
<p>Beispiel via Commandline:</p>
<pre>
$ ldapsearch -LLL -x -H "ldap://iduzhz2dc01.d.uzh.ch ldap://iduzhz2dc02.d.uzh.ch" -b "DC=d,DC=uzh,DC=ch" -D "srv-math-sync@d.uzh.ch" -W "proxyAddresses=smtp:carsten.rose@math.uzh.ch" proxyAddresses
Enter LDAP Password:
dn: CN=Rose Carsten (crose),OU=Users,OU=Users UZH,DC=d,DC=uzh,DC=ch
proxyAddresses: smtp:crose@access.uzh.ch
proxyAddresses: X500:/o=ExchangeLabs/ou=Exchange Administrative Group (FYDIBOH
F23SPDLT)/cn=Recipients/cn=d99ada2cb78c406ea039453c26f86dab-Rose Carste
proxyAddresses: smtp:caro@math.uzh.ch
proxyAddresses: smtp:m200143@access.uzh.ch
proxyAddresses: smtp:carsten.rose@uzh.ch
proxyAddresses: smtp:crose@uzh.mail.onmicrosoft.com
proxyAddresses: SMTP:carsten.rose@math.uzh.ch
# refldap://DomainDnsZones.d.uzh.ch/DC=DomainDnsZones,DC=d,DC=uzh,DC=ch
# refldap://ForestDnsZones.d.uzh.ch/DC=ForestDnsZones,DC=d,DC=uzh,DC=ch
# refldap://d.uzh.ch/CN=Configuration,DC=d,DC=uzh,DC=ch
</pre>
<ul>
<li>Bei der Abfrage koennen mehrere LDAP Server angegeben werden.</li>
<li>Liefert die Abfrage min. einen Treffer zurueck, ist die Adresse ok.</li>
<li>Die obige Abfrage geht auf 'proxyAddresses', da dort scheinbar auch die weiteren Adressen angegeben sind.
<ul>
<li>Bei 'proxyAddresses' muss ein 'smtp:' vorangestellt werden fuer einen 100% match</li>
</ul></li>
</ul> QFQ - Support #18057 (New): {{sqlLog:Y}} returns empty string when not configuredhttps://project.math.uzh.ch/issues/180572024-03-05T07:31:43ZElias Villiger
<p>When the QFQ config for <code>sqlLog</code> (or <code>qfqLog</code>, <code>mailLog</code>) is empty, the default log directory (<code>fileadmin/protected/qfqProject/log/sql.log</code>) is used.</p>
<p>When retrieving <code>{{sqlLog:Y}}</code> from the System Store, this returns an empty string (corresponding to the config value).</p>
<p>Expected behavior: When there's no specific log path configured, I would expect it to return the default/actual path to the log file.</p>
<p>Example use case: <a class="external" href="https://docs.qfq.io/en/master/Report.html#monitor">https://docs.qfq.io/en/master/Report.html#monitor</a></p> QFQ - Feature #18042 (New): Download dynamic ZIP: missing meaningful default save as filenamehttps://project.math.uzh.ch/issues/180422024-03-02T15:41:52ZCarsten Rosecarsten.rose@math.uzh.ch
<p>Mit `<abbr title="'d|F:', p.pathFileName, '|s:1|M:zip'">CONCAT</abbr> AS _link` wurde ein ZIP zum Download angeboten und hatte als Dateinamen 'qfq.temp.RcGnwV'</p>
<p>Bug: es sollte mindestens '.zip' am Ende stehen. Am besten 'data.zip' oder 'data_<timestamp>.zip'</p> QFQ - Feature #18040 (New): Checkbox Custom-Listehttps://project.math.uzh.ch/issues/180402024-03-02T12:00:47ZCarsten Rosecarsten.rose@math.uzh.ch
<p>Ziel: Checkbox Listen zum abarbeiten - eigenstaendig erweiterbar</p>
<p>Beispiel aus Redmine:</p>
<p><img src="https://project.math.uzh.ch/attachments/download/9382/clipboard-202403021239-n2k4h.png" alt="" /></p>
<p>Wichtig: die Reihenfolge kann via Drag'n'Drop geaendert werden. Check welchen Code wir schon haben (Subrecord, Benj).</p>
<p><code>FormElement.parameter.itemList</code> ist bereits genau die Checkbox-Liste</p>
<ul>
<li>static</li>
<li>Values werden Komma-separiert im String abgelegt. Bei Komma im Value haben wir vermutlich ein Problem.</li>
</ul>
<a name="Moegliche-Umsetzung"></a>
<h2 >Moegliche Umsetzung<a href="#Moegliche-Umsetzung" class="wiki-anchor">¶</a></h2>
<ul>
<li><code>FormElement.parameter.checkBoxType = static|custom</code>
<ul>
<li><code>static</code> ist das bisherige und der default.</li>
<li><code>custom</code> ist dieses Ticket.</li>
</ul></li>
</ul>
<a name="Itemliste-und-Status-pro-Item"></a>
<h3 >Itemliste und Status pro Item<a href="#Itemliste-und-Status-pro-Item" class="wiki-anchor">¶</a></h3>
<ul>
<li>Soll der User die Moeglichkeit haben selber Items zu erfassen muessen diese irgendwo gespeichert werden.</li>
<li>Der Status eines jeden Items muss gespeichert werden.</li>
<li>Sections waeren nett.</li>
<li>Drag'n'Drop muss nicht in 1.0 sein, ist aber definitiv gefordert.</li>
</ul>
<p>Vorschlag: Labels und Values (inkl. 'sections') in einem JSON struct</p>
<ul>
<li>Das JSON wird genau in der Spalte des FE gespeichert (muss also ein String sein).</li>
<li>Wird das JSON zu gross zum speichern (Bsp varchar 128), gibt es bereits im Client eine Fehlermeldung damit der User nicht viele Items anlegt und dann enttaeuscht ist das sie nicht gespeichert werden koennen.</li>
<li>Ein 'Template' kann also einfach angeboten werden, in dem das JSON in FE.value steht.</li>
<li>Nach Moeglichkeit sollte das JSON so gesepichert werden das wir es mit den MariaDB JSON Funktionen verwenden koennen.</li>
</ul> QFQ - Feature #18037 (New): Auto BPMN Update: QFQ/rclonehttps://project.math.uzh.ch/issues/180372024-03-02T09:37:05ZCarsten Rosecarsten.rose@math.uzh.ch
<p>Ziel: BPMN Workflows verbinden mit Ticketsystem, ist ein Ticket / Milestones abgearbeitet wird das im BPMN visuell markiert.</p>
<p>Moegliches Konzept:</p>
<ul>
<li>BPMN ist im Switchdrive</li>
<li>QFQ bekommt via 'rclone' Nextclod, OwnCloud, Dropbox, OneDrive, GDrive Support und kann so auf Dateien zugreifen.</li>
<li>In QFQ ist die PathFilename-Referenz auf das BPMN hinterlegt</li>
<li>Es gibt eine API (Redmine, QFQ Notez) um den Status von Tickets abzufragen.</li>
<li>QFQ ruft (on request, periodically) ein Skript auf welches:
<ul>
<li>Fuer jedes im BPMN referenzierte Ticket den Status via API abruft.</li>
<li>Den Status visuell im BPMN eintraegt (z.B. Hintergrundfarbe des Elements setzen)</li>
<li>Dadurch dass das File via rclone im Sync gehalten wird, haben sofort alle User das aktuelle File.</li>
</ul></li>
</ul> QFQ - Bug #17998 (New): Curly braces: a) save as html-entity, b) stored procedure to convert to h...https://project.math.uzh.ch/issues/179982024-02-26T12:53:24ZCarsten Rosecarsten.rose@math.uzh.ch
<ul>
<li>In Forkred #17995 kam es bei der Anzeige eines Formulars zu einem Problem das <code>}}</code> als Variable interpretiert wurde.</li>
<li>Das ist ein schweres Problem und sollte versucht werden zentral zu vermeiden.</li>
</ul> QFQ - Feature #17958 (New): Screenshare via QFQ / jitsi or ms-teamshttps://project.math.uzh.ch/issues/179582024-02-20T15:00:41ZCarsten Rosecarsten.rose@math.uzh.ch
<p>Auf der post.ch Seite wird ein Screenshare fuer Support angeboten:</p>
<p><img src="https://project.math.uzh.ch/attachments/download/9290/clipboard-202402201547-6x5e3.png" alt="" /></p>
<p>Idee:</p>
<ul>
<li>Wir bieten das gleiche an via jitsi.</li>
<li>Koennte interessant sein fuer alle Tools, wenn die User Probleme mit einem Antrag haben.</li>
<li>Es geht nicht darum um 24/7 erreichbar zu sein, sondern dem User eine Moeglichkeit zu geben zu einem vereinbarten Zeitpunkt eine Verbindung herzustellen, ohne das eine Jitsi URL abgesprochen werden muss.</li>
<li>Ggfs. ist es auch via Teams moeglich.</li>
</ul> QFQ - Bug #17957 (New): Keyword tail causes problems when {{ SELECT ... }} is usedhttps://project.math.uzh.ch/issues/179572024-02-20T13:56:37ZJan Haller
<pre><code class="sql syntaxhl"><span class="o">#</span> <span class="n">Beispiel</span> <span class="mi">1</span><span class="p">:</span> <span class="n">Keine</span> <span class="n">Verschachtelung</span>
<span class="o">#</span> <span class="n">tail</span> <span class="n">wird</span> <span class="n">ersetzt</span> <span class="n">durch</span> <span class="mi">1</span>
<span class="o">#</span> <span class="n">Funktioniert</span> <span class="n">wie</span> <span class="n">erwartet</span>
<span class="mi">10</span> <span class="err">{</span>
<span class="k">sql</span> <span class="o">=</span> <span class="k">SELECT</span> <span class="mi">1</span>
<span class="n">head</span> <span class="o">=</span> <span class="o"><</span><span class="n">p</span><span class="o">></span><span class="p">...</span><span class="o"></</span><span class="n">p</span><span class="o">></span>
<span class="n">tail</span> <span class="o">=</span> <span class="err">{{</span> <span class="k">SELECT</span> <span class="mi">1</span> <span class="err">}}</span>
<span class="err">}</span>
<span class="o">#</span> <span class="n">Beispiel</span> <span class="mi">2</span><span class="p">:</span> <span class="n">Verschachtelung</span>
<span class="o">#</span> <span class="n">tail</span> <span class="n">wird</span> <span class="n">ersetzt</span> <span class="n">durch</span> <span class="mi">1</span>
<span class="o">#</span> <span class="n">Es</span> <span class="n">gibt</span> <span class="n">jedoch</span> <span class="n">eine</span> <span class="n">Fehlermeldung</span> <span class="n">auf</span> <span class="k">level</span> <span class="mi">20</span><span class="p">.</span><span class="mi">30</span>
<span class="mi">20</span> <span class="err">{</span>
<span class="k">sql</span> <span class="o">=</span> <span class="k">SELECT</span> <span class="mi">1</span>
<span class="n">head</span> <span class="o">=</span> <span class="o"><</span><span class="n">p</span><span class="o">></span><span class="p">...</span><span class="o"></</span><span class="n">p</span><span class="o">></span>
<span class="n">tail</span> <span class="o">=</span> <span class="err">{{</span> <span class="k">SELECT</span> <span class="mi">1</span> <span class="err">}}</span>
<span class="mi">30</span> <span class="err">{</span>
<span class="k">sql</span> <span class="o">=</span> <span class="k">SELECT</span> <span class="mi">2</span>
<span class="n">head</span> <span class="o">=</span> <span class="o"><</span><span class="n">p</span><span class="o">></span><span class="p">...</span><span class="o"></</span><span class="n">p</span><span class="o">></span>
<span class="err">}</span>
<span class="err">}</span>
<span class="o">#</span> <span class="n">Beispiel</span> <span class="mi">3</span><span class="p">:</span> <span class="n">Verschachtelung</span> <span class="n">liefert</span> <span class="n">keine</span> <span class="n">Records</span>
<span class="o">#</span> <span class="n">tail</span> <span class="n">wird</span> <span class="n">ersetzt</span> <span class="n">durch</span> <span class="mi">1</span>
<span class="o">#</span> <span class="n">Funktioniert</span> <span class="n">wie</span> <span class="n">erwartet</span>
<span class="mi">40</span> <span class="err">{</span>
<span class="k">sql</span> <span class="o">=</span> <span class="k">SELECT</span> <span class="mi">1</span>
<span class="n">shead</span> <span class="o">=</span> <span class="o"><</span><span class="n">p</span><span class="o">></span><span class="p">...</span><span class="o"></</span><span class="n">p</span><span class="o">></span>
<span class="n">stail</span> <span class="o">=</span> <span class="err">{{</span> <span class="k">SELECT</span> <span class="mi">1</span> <span class="err">}}</span>
<span class="mi">50</span> <span class="err">{</span>
<span class="k">sql</span> <span class="o">=</span> <span class="k">SELECT</span> <span class="mi">2</span> <span class="k">FROM</span> <span class="n">DUAL</span> <span class="k">WHERE</span> <span class="mi">1</span> <span class="o">=</span> <span class="mi">0</span>
<span class="n">head</span> <span class="o">=</span> <span class="o"><</span><span class="n">p</span><span class="o">></span><span class="p">...</span><span class="o"></</span><span class="n">p</span><span class="o">></span>
<span class="err">}</span>
<span class="err">}</span>
</code></pre>
<p>In jedem Beispiel würde <em>head = {{ SELECT 1 }}</em> funktionieren.</p>
<p>Anbei Screenshots von Beispiel 2 und 3:<br />Beispiel 2:<br /><img src="https://project.math.uzh.ch/attachments/download/9287/clipboard-202402201455-bkckr.png" alt="" /></p>
<p>Bonus:<br /><img src="https://project.math.uzh.ch/attachments/download/9288/clipboard-202402201519-84tfr.png" alt="" /></p>
<p><img src="https://project.math.uzh.ch/attachments/download/9289/clipboard-202402201522-uwvjh.png" alt="" /></p>
<p>Beispiel 3:<br /><img src="https://project.math.uzh.ch/attachments/download/9286/clipboard-202402201449-zmkmm.png" alt="" /></p> QFQ - Feature #17858 (New): Check if QFQ is compatible with Typo3 V12https://project.math.uzh.ch/issues/178582024-02-11T18:35:34ZCarsten Rosecarsten.rose@math.uzh.ch
<ul>
<li>Wenn wir von isg_ldap_sso weg kommen (wird ersetzt durch oidc) gibt es keinen Grund mehr V12 noch nicht anzuschauen.</li>
<li>MNF ist noch auf V9 - Migration koennte ggfs. direkt auf V12 erfolgen.</li>
</ul> QFQ - Feature #17829 (New): QFQ Add/Remove classes in parameterhttps://project.math.uzh.ch/issues/178292024-02-06T13:25:19ZEnis Nuredini
<p>Über das Parameter Feld sollten Klassen hinzufügbar oder entfernbar sein.</p> QFQ - Bug #17778 (New): Upload Filepond Dynamic Update - first load hiddenhttps://project.math.uzh.ch/issues/177782024-01-31T15:39:49ZEnis Nuredini
<p>Ausgangssituation:<br />Ein Upload FormElement (Version Filepond) wird beim ersten Aufruf als hidden geladen und danach via Dynamic Update auf show gesetzt, bzw. eingeblendet.</p>
<p>Resultat: Filepond Objekt ist noch nicht initialisiert.</p>
<p>Ursache: Filepond kann nur initialisiert werden wenn das Upload Input Element sichtbar im DOM angezeigt wird. Beim Wechsel von Pills wurde schon eine Lösung dafür implementiert. Beim Einblenden von neuen Upload Elementen via Dynamic Update fehlt eine solche Lösung für die Initialisierung von Filepond. In solchen Fällen kann uploadType = v1 als Übergang verwendet werden.</p> QFQ - Feature #17670 (New): WeasyPrint (instead of wkhtml) for PDF with header/footer/toc/...https://project.math.uzh.ch/issues/176702024-01-21T11:03:47ZCarsten Rosecarsten.rose@math.uzh.ch
<p>Unter <a class="external" href="https://wkhtmltopdf.org/status.html">https://wkhtmltopdf.org/status.html</a> weist wkhtml eindringlich daraufhin das wenn wkhtml fuer nicht vertrauenswuerde HTML content verwendet wird, der Server uebernommen werden kann.</p>
<p>Das ist bei uns zwar nicht der Fall, aber weasyprint sollte einen Blick wert sein.</p>
<p>Das Hauptproblem bei wkthml ist, das sobald eine Datei (js, css, png, jpg,...) nicht geladen werden kann, es sofort einen Abbruch gibt, aber keinen Hinweis auf die Ursache.</p>
<ul>
<li><a class="external" href="https://weasyprint.org/">https://weasyprint.org/</a></li>
<li><a class="external" href="https://github.com/Kozea/WeasyPrint/">https://github.com/Kozea/WeasyPrint/</a></li>
</ul> QFQ - Bug #17668 (New): TypAhead: checks 'value', but should check 'key'https://project.math.uzh.ch/issues/176682024-01-19T20:19:07ZCarsten Rosecarsten.rose@math.uzh.ch
<p>QFQ 23.6.2</p>
<p><img src="https://project.math.uzh.ch/attachments/download/9061/clipboard-202401192117-qlllp.png" alt="" /></p>
<p>Beim laden des Forms (wenn ein User selektiert ist mit special char im Namen wie `Faske, Ida Synnøve`) gibt es im Client gleich ein 'invalid char'. Speichern wird entsprechend auch abgelehnt.</p>
<ul>
<li>checkType=auto setzt vermutlich 'alnumx' Pattern</li>
<li>Der Pattern Check prueft vermutlich den Value, es sollte eigentlich der Key getestet werden</li>
</ul>
<ul>
<li>Funktioniert nicht, sollte es aber: Encode=specialchar, checkType=auto</li>
<li>Funktioniert, aber unnoetig kompliziert: Encode=none, checkType=allbut</li>
</ul> QFQ - Feature #17659 (New): MultiForm im Formhttps://project.math.uzh.ch/issues/176592024-01-19T14:06:24ZCarsten Rosecarsten.rose@math.uzh.ch
<p>In dem folgenden Form sollen Rollen (jeweils einzelne Records) auf eine auszuwaehlende Person gelegt werden.</p>
<p><img src="https://project.math.uzh.ch/attachments/download/9053/clipboard-202401191458-rmo2s.png" alt="" /></p>
<p>Problem: es kann immer nur eine Rolle zugeordnet werden - gut waere wenn mehrere auf einmal moeglich waeren.</p>
<p>Der Use-Case kommt oefter vor, vermutlich waere ein 80/20 Loesung sehr hilfreich - Flexibilitaet von Multiform ist vielleicht nicht wichtig, einfach das es checkbox / radio / input / select gibt.</p>
<p>Im Prinzip laeuft es auf ein MultiForm im Form hinaus: das koennte moeglich sein.</p>
<p>V2.0: Den Sonderfall, es sollen Zeilen geloescht oder neue hinzugefuegt werden, koennte mit JS geloest werden.</p>
<p>Check ob das einfach DynamikUpdate aware ist.</p> QFQ - Bug #17656 (New): Browser: regexp Pattern Match broken/error inhttps://project.math.uzh.ch/issues/176562024-01-19T13:30:07ZCarsten Rosecarsten.rose@math.uzh.ch
<p>QFQ 23.6.4</p>
<p>Auf der Forkred Seite im Passwort Reset Form gibt es in der Console die folgende Fehlermeldung</p>
<p><img src="https://project.math.uzh.ch/attachments/download/9048/clipboard-202401191424-dqr2g.png" alt="" /></p>
<p>Die Fehler Meldung zu der Regexp habe ich bei QFQ in JS Konsole schon häufiger gesehen - wird vermutlich allgmeines Problem sein, nicht formspezifisch.</p> QFQ - Feature #17618 (New): Doc/Report: change all examples 'remove numbers'https://project.math.uzh.ch/issues/176182024-01-16T13:41:27ZCarsten Rosecarsten.rose@math.uzh.chQFQ - Feature #17577 (New): QFQ Doc: local render / Sphinx & MkDochttps://project.math.uzh.ch/issues/175772024-01-13T13:39:29ZCarsten Rosecarsten.rose@math.uzh.ch
<p>Es waere gut wenn man die QFQ Doc lokale rendern koennte um schneller zu sehen wie etwas aussieht.</p>
<ul>
<li>Um schnell etwas auszuprobieren sind a) Commmits auf 'Develop' und b) warten bis RTD fertig ist, einfach zu unpraktisch.</li>
<li>RTD rendert nur auf Branch Master & Develop - d.h. niemand ausser CR kann schauen wie die Doku aussieht.</li>
</ul>
<ul>
<li><a class="external" href="https://me-readthedocs.readthedocs.io/en/latest/custom_installs/local_rtd_vm.html">https://me-readthedocs.readthedocs.io/en/latest/custom_installs/local_rtd_vm.html</a></li>
<li><a class="external" href="https://me-readthedocs.readthedocs.io/en/latest/guides/tools.html">https://me-readthedocs.readthedocs.io/en/latest/guides/tools.html</a></li>
<li><a class="external" href="https://training.nih-cfde.org/en/latest/General-Tools/Web-Development/mkdocs/">https://training.nih-cfde.org/en/latest/General-Tools/Web-Development/mkdocs/</a></li>
</ul> QFQ - Feature #17544 (New): QFQ Installation Wizard / Defaultshttps://project.math.uzh.ch/issues/175442024-01-09T12:19:59ZCarsten Rosecarsten.rose@math.uzh.ch
<p>Im Meeting mit Philipp, Enis, Benj und Carsten wurden besprochen das wir einen Installation Wizard benoetigen.</p>
<ul>
<li>Kontrolle das die BaseURL stimmt (falls nicht ok, bitte im Installtool setzen).</li>
<li>Frage ob Tabellen angelegt werden sollen:
<ul>
<li>Period</li>
<li>Category (ex Ggroup) - Weiterer Vorschlag: Grp (in dem Fall kann 'gr' als Prefix weiter verwendet werden). implement mit Ticket <a class="issue tracker-2 status-2 priority-3 priority-high3" title="Feature: Per Form: note, tag, reminder date, done flag (In Progress)" href="https://project.math.uzh.ch/issues/17412">#17412</a> </li>
<li>Glue (ex GroupMember) implement mit Ticket <a class="issue tracker-2 status-2 priority-3 priority-high3" title="Feature: Per Form: note, tag, reminder date, done flag (In Progress)" href="https://project.math.uzh.ch/issues/17412">#17412</a></li>
<li>Upload. implement mit Ticket #filepond</li>
<li>Translation</li>
<li>Chat implement mit Ticket #chat</li>
<li>Note</li>
<li>NoteItem ( fuer form NoteItem Ticket <a class="issue tracker-2 status-2 priority-3 priority-high3" title="Feature: Per Form: note, tag, reminder date, done flag (In Progress)" href="https://project.math.uzh.ch/issues/17412">#17412</a>)</li>
<li>Person</li>
<li>Account</li>
<li>Address</li>
<li>PersonRole</li>
<li>Role</li>
</ul></li>
</ul>
<ul>
<li>BestPractice Doku & Seite / ttcontent anlegen (Auswahl als welches Child Element)
<ul>
<li>Settings (based on Grp/Glue) via.</li>
<li>Person / Adresse / Account / Rolle</li>
<li>FormEditor</li>
<li>Beispiel Chat</li>
</ul></li>
</ul>
<p><img src="https://project.math.uzh.ch/attachments/download/8961/clipboard-202401091319-wrmqh.png" alt="" /></p>
<p>switchdrive/qfq/DB/QFQ_Best_Practice_Tables.drawio</p>
<ul>
<li>Der Wizard soll bei der ersten Installation automatisch aufgehen.</li>
<li>Der Wizard soll auch spaeter noch gestartet werden koennen.</li>
<li>Im Wizard angeben wie man ihn spaeter erneut starten kann.</li>
<li>Aufruf koennte via einem HTML/PHP Form gemacht werden, das nur startet wenn ein BE User eingeloggt ist: BE Cookie mit der T3 BE User Tabelle vergleichen).</li>
</ul> QFQ - Feature #17481 (New): BS modal windowhttps://project.math.uzh.ch/issues/174812023-12-15T13:53:28ZJan Haller
<p>It is often useful to present the user with a modal window (e.g. containing additional information). The following example is based on Bootstrap (<a href="https://getbootstrap.com/docs/3.4/javascript/#modals" class="external">BS Modal</a>)</p>
<p><img src="https://project.math.uzh.ch/attachments/download/8916/clipboard-202312151436-hwvg1.png" alt="" /></p>
<pre><code class="html syntaxhl"><span class="nt"><div</span> <span class="na">class=</span><span class="s">"modal fade"</span> <span class="na">id=</span><span class="s">"myModal"</span> <span class="na">tabindex=</span><span class="s">"-1"</span> <span class="na">role=</span><span class="s">"dialog"</span> <span class="na">aria-labelledby=</span><span class="s">"detailsModalLabel"</span> <span class="na">aria-hidden=</span><span class="s">"true"</span><span class="nt">></span>
<span class="nt"><div</span> <span class="na">class=</span><span class="s">"modal-dialog"</span> <span class="na">role=</span><span class="s">"document"</span><span class="nt">></span>
<span class="nt"><div</span> <span class="na">class=</span><span class="s">"modal-content"</span><span class="nt">></span>
<span class="nt"><div</span> <span class="na">class=</span><span class="s">"modal-header"</span><span class="nt">></span>
<span class="nt"><h5</span> <span class="na">class=</span><span class="s">"modal-title"</span> <span class="na">id=</span><span class="s">"detailsModalLabel"</span><span class="nt">></span>{{pubFormText:RE}}<span class="nt"></h5></span>
<span class="nt"></div></span>
<span class="nt"><div</span> <span class="na">class=</span><span class="s">"modal-body"</span><span class="nt">></span>
{{r_countPublications:RE:all}} Publikationen eingetragen <span class="nt"><br><br></span>
({{r_countPublications:R0}} - {{r_countPublicationsNotInEdit:R0}}) Publikationen müssen noch überprüft/angepasst werden. Editiere Publikation und prüfe den unteren Abschnitt, falls ok dann speichern.
<span class="nt"></div></span>
<span class="nt"><div</span> <span class="na">class=</span><span class="s">"modal-footer"</span><span class="nt">></span>
<span class="nt"><button</span> <span class="na">type=</span><span class="s">"button"</span> <span class="na">class=</span><span class="s">"btn btn-secondary"</span> <span class="na">data-dismiss=</span><span class="s">"modal"</span><span class="nt">></span>Close<span class="nt"></button></span>
<span class="nt"></div></span>
<span class="nt"></div></span>
<span class="nt"></div></span>
<span class="nt"></div></span>
<span class="nt"><a</span> <span class="na">id=</span><span class="s">"myModalTrigger"</span> <span class="na">data-toggle=</span><span class="s">"modal"</span> <span class="na">data-target=</span><span class="s">"#myModal"</span><span class="nt">></span>Open Modal<span class="nt"></a></span>
</code></pre>
<p>It would be nice to include this functionality into QFQ somehow without having to copy/paste this block of code every time.</p> QFQ - Feature #17442 (New): Rearrange form buttonshttps://project.math.uzh.ch/issues/174422023-12-07T12:53:28ZKrzysztof Putyra
<a name="Overview-of-the-problem"></a>
<h1 >Overview of the problem<a href="#Overview-of-the-problem" class="wiki-anchor">¶</a></h1>
The current arrangement <code>[save][close] [delete] [new]</code> is flawed: it makes people afraid to click "close", because the impression is that the button deletes data. This is caused by how our brain processes this information:
<ul>
<li>the two buttons are next to each other with icons suggesting opposite actions</li>
<li>opposite <em>action</em> to "safe" is "delete" ("don't safe" is <em>no action</em>)</li>
<li>close button is normally the last one in a group, so our brain does not expect it at the current position</li>
</ul>
<p>Moreover, because [save] and [close] are next to each other and [delete] is separated, the brain ignores [delete] when looking at [close] and tries to make connection only with [save]. This could be improved by placing [delete] between [safe] and [close]</p>
<a name="An-alternate-arrangement"></a>
<h1 >An alternate arrangement<a href="#An-alternate-arrangement" class="wiki-anchor">¶</a></h1>
<p><code>[safe] [new][delete] [close]</code></p>
<ul>
<li>[close] is the last button</li>
<li>[delete] does not touch [safe], which prevents accidental clicks</li>
<li>[delete] is between [safe] and [close] to prevent the brain making a connection between these two buttons</li>
<li>choosing for [safe] an icon related to [delete] instead of a tick may improve the situation as well</li>
</ul> QFQ - Feature #17439 (New): Novu Open Source Notification Managementhttps://project.math.uzh.ch/issues/174392023-12-07T07:37:09ZCarsten Rosecarsten.rose@math.uzh.ch
<p><a class="external" href="https://www.heise.de/ratgeber/Novu-Open-Source-Notification-Management-fuer-Web-Apps-9543007.html?wt_mc=intern.red.plus.newsticker.7-tage-news.teaser.teaser">https://www.heise.de/ratgeber/Novu-Open-Source-Notification-Management-fuer-Web-Apps-9543007.html?wt_mc=intern.red.plus.newsticker.7-tage-news.teaser.teaser</a></p>
<p>Koennte eingesetzt werden fuer</p>
<ul>
<li>Dashboard</li>
<li>Am I-MATH gibt es viele T3 Instanzen - damit koennten Notifications unterschiedlicher Tools gebuendelt werden.</li>
<li>Notez: falls wir eine App machen </li>
<li>Wuerde sich das als Chat-Server eignen?</li>
</ul> QFQ - Feature #17411 (New): extraButtonCopyToClipboardhttps://project.math.uzh.ch/issues/174112023-12-05T21:21:40ZCarsten Rosecarsten.rose@math.uzh.ch
<p>Mitunter ist es gewuenscht den Inhalt eines Input Elements in das Clipboard zu kopieren.</p>
<p>Fuer Report habe das schon <a class="external" href="https://docs.qfq.io/en/master/Report.html#copy-to-clipboard">https://docs.qfq.io/en/master/Report.html#copy-to-clipboard</a></p>
<p>Vergleichbar mit extraButtonLock,extraButtonPassword, extraButtonInfo.</p>
<p>Es waere gut wenn immer der aktuelle Inhalt des FormElements genommen wird, auch wenn der Record nicht nicht gespeichert wurde.</p>
<p>Der Button waere auch sinnvoll fuer FormElement.type=editor (TinyMCE / CodeMirror)</p>
<p>Erste Anwendung: u.a. in den Settings gibt es oft 'reference' Spalten - deren Inhalt kopiert man haeufiger in die Zwischenablage ...</p> QFQ - Bug #17361 (New): Annotate FE doesnt initialize/showhttps://project.math.uzh.ch/issues/173612023-11-27T16:59:16ZEnis Nuredini
<p>The annotate form-element doesn't get initialized. Defined formId variable which is used for initialization is undefined. Somehow the form id handlings have been changed.</p>
<p>Could be an issue for other elements too.</p> QFQ - Feature #17359 (New): Form: new record - skip historyhttps://project.math.uzh.ch/issues/173592023-11-26T10:06:56ZCarsten Rosecarsten.rose@math.uzh.ch
<p>Werden mehrere Records nacheinander neu angelegt (='New'), moechte man in der Regel, sobald der der letzte Record angelegt wurde, mit 'Close' zum Parent Record zurueck.</p>
<p>Aktuell ist es so implmementiert, das man zum zuvor neu angelegten Record zuruck springt.</p>
<p><img src="https://project.math.uzh.ch/attachments/download/8786/clipboard-202311261104-eua7z.png" alt="" /></p> QFQ - Feature #17236 (New): Form.parameter: sqlLoghttps://project.math.uzh.ch/issues/172362023-11-03T17:19:18ZEnis Nuredini
<p>Bitte Parameter sqlLog für Form einführen. Siehe Report/Configuration.</p>
<p>Wird benötigt für Geolean Import Finances damit das reguläre Sql.log nicht so gross wird.</p> QFQ - Feature #16988 (In Progress): Bild zuschneiden / Image Manipulationhttps://project.math.uzh.ch/issues/169882023-10-03T11:22:44ZCarsten Rosecarsten.rose@math.uzh.ch
<p>Wir brauchen an unterschiedlichen Stellen die Moeglichkeit das ein Bild direkt im QFQ zugeschnitten werden kann.</p>
<p>Use Case:</p>
<ul>
<li>Carousel News (I-MATH/MY, JES)</li>
<li>MY Photowand</li>
<li>MY Student Exercise Upload </li>
<li>(Exam Upload)</li>
<li>MNF Heidi</li>
<li>...</li>
</ul>
<p>Details:</p>
<ul>
<li>Direkt im Upload Dialog</li>
<li>Explizit fuer bereits vorhandenes Bild</li>
<li>Option: Maske (fixem Aspekt Ratio) kann eingeblendet und verschoben / gezoomt werden.</li>
<li>Option: das Originalbild bleibt erhalten (Gleicher Pfad, Dateiname plus Extension 'original')</li>
<li>Option: Button restore Orginal.</li>
<li><a class="external" href="https://docs.qfq.io/en/master/Form.html#type-imagecut">https://docs.qfq.io/en/master/Form.html#type-imagecut</a></li>
</ul>
<p>10 Best Image Croppers In jQuery And Vanilla JavaScript (2024 Update) - <a class="external" href="https://www.jqueryscript.net/blog/best-image-croppers.html">https://www.jqueryscript.net/blog/best-image-croppers.html</a></p>
<ul>
<li><a class="external" href="https://fengyuanchen.github.io/cropperjs/">https://fengyuanchen.github.io/cropperjs/</a>, MIT, 12.5k Stars, 2023</li>
<li><a class="external" href="https://jamesooi.design/Croppr.js/">https://jamesooi.design/Croppr.js/</a>, MIT, 386 Stars, 2018, Aspect Ratio</li>
</ul> QFQ - Feature #16113 (New): Report, Subrecord: action on multiple elementshttps://project.math.uzh.ch/issues/161132023-04-26T15:11:17ZCarsten Rosecarsten.rose@math.uzh.ch
Alternativer Titel: <strong>HTML table row multi select action</strong>
<ul>
<li>Records können auf Report und Formebene (Subrecord) selektiert und zusammen "bearbeitet" werden (Action wird auf alle selektierten Records angewendet).</li>
<li>Actions sind über Dropdown abrufbar</li>
<li>1 Action = 1 <em>Function</em>
<ul>
<li><em>Anmerkung CR:</em> das mit 'Functions' (weil wir so viele brauchen pro Menu) muessen wir trennen von qfqFunctions - denn 'Functions' stehen ja im aktuellen tt-content wuerden nicht gefunden werden wenn sie in einem anderen Record stehen. Aus meiner Sicht aber genau so sinnvoll! Ein tt-content Record entspricht einer Klasse.</li>
</ul></li>
</ul>
<p><img src="https://project.math.uzh.ch/attachments/download/7783/clipboard-202304261709-sosbw.png" alt="" /></p>
<p><img src="clipboard-202304261709-w1hfg.png" alt="" /></p> QFQ - Feature #15362 (Some day maybe): Add button to text inputs in Form (Element) Editor to swit...https://project.math.uzh.ch/issues/153622023-01-12T11:48:36ZJan Haller
<p>Neben bestimmten Textinputs (z.B. Title) im Form (Element) Editor soll ein Button eingebaut werden, der das Umschalten des entprechenden Inputfelds von type=input zu type=editor (und zurück) ermöglicht. Für SQL Abfragen steht dann die entsprechende Syntax zur Verfügung.</p> QFQ - Feature #14504 (New): Form / Input Element: restore previous contenthttps://project.math.uzh.ch/issues/145042022-07-12T09:23:40ZCarsten Rosecarsten.rose@math.uzh.ch
<p>Es waere gut wenn fuer Textfelder die Moeglichkeit bestehen wuerde alten (nicht gespeicherten) Content wieder herzustellen.</p>
<p>Szenario: User nutzt nur einen Tab, hat in einem Formularelement etwas eingegeben und moechte nun die Seite verlassen, kann aber noch nicht speichern weil noch nicht alles eingegeben ist. QFQ warnt den User, das Informationen verloren gehen, der User muss das als das kleinere Uebel akzeptieren und verliert dann seinen Content</p>
<p>Loesung 1: server based</p>
<ul>
<li>Der Infodialog, der den User warnt, bekommt eine dritte Option 'Restore content later'.</li>
<li>Alle Dirty FormElemente (STORE_BEFORE?) werden serverseitig gespeichert: feUser, SIP (Form, Record, extra Argumente). </li>
<li>Wird das Form mit der SIP und dem User wieder geoeffnet, erkennt QFQ das es temp Values gibt, laedt den Record wie gewoehnlich, und bietet dann an das die alte Werte wieder restauriert werden.</li>
</ul>
<p>Loesung 2: Browser Local Store</p>
<ul>
<li>Jedes Formulare wird bei jedem(!) change im Local Store gespeichert.</li>
<li>Wird ein Form mit 'save', 'close', 'browser tab close' geschlossen, wird der Eintrag im Local Store geloescht.</li>
<li>Wird ein Form geoeffnet und gibt es dazu einen Eintrag im Local Store, wird angeboten diesen zu laden.</li>
<li>Damit wuerden auch Browser-Crashes wieder hergestellt.</li>
</ul> QFQ - Feature #12156 (New): Form: Optional disable 'leave page'https://project.math.uzh.ch/issues/121562021-03-16T13:31:32ZCarsten Rosecarsten.rose@math.uzh.ch
<p>Mitunter ist es wuenschenswert ein From zu verlassen (z.B. weil man einen Link klickt) und dann soll keine Abfrage "Unsaved changes... "kommen falls das Form Dirty ist.</p>
<p>Parameter:</p>
<p>messageFormDirty = 0|1|<text></p>
<p>Default:1</p>
<p>Mit der Option <text> wird es neu moeglich die Message sprachabhaengig zu setzen.</p> QFQ - Feature #12135 (New): Subrecord: Notizhttps://project.math.uzh.ch/issues/121352021-03-12T16:10:44ZElias Villiger
<p>Aktuell wird bei einem subrecords mit FE.note = test die Notiz ("test") unterhalb der Subrecord-Tabelle angezeigt.</p>
<p>Würde es Sinn machen, die Notiz bei den Subrecords direkt im Anschluss an das Label zu verschieben? (siehe Screenshot)</p> QFQ - Feature #12039 (New): Missing htmlSpecialChar() in pre processing on form submithttps://project.math.uzh.ch/issues/120392021-02-17T23:09:35ZCarsten Rosecarsten.rose@math.uzh.ch
<p>Wird auf Formularelemente mittels '{{notiz:F:allbut}}' zugegriffen, sind dies VERMUTLICH nicht htmlSpecialChar kodiert.</p>
<ul>
<li>Check ob dem so ist.</li>
</ul>
<p>Damit waere das folgende einem potentiellen SQL Inject Angriff ausgeliefert (notiz="1' OR 1")<br /><pre>
sqlValidate = {{!SELECT n.notiz FROM notiz AS n WHERE n.gr_id={{gr_id:RS0}} AND n.category=0 AND n.file_typ="Uebung" AND n.notiz='{{notiz:F:allbut}}' AND n.id !=
{{id:R0}} }}
</pre></p>
<ul>
<li>Abhilfe koennte eine neue Escape Klasse sein, die bei Default beim STORE_FORM htmlSpecialChar() anwendet.</li>
<li>Achtung: was passeirt wenn nicht mit single sondern mit double quotes im SQL Statement gearbeitet wird?</li>
<li>In der QFQ Doc bei den Bestpractices angeben das immer mit single quotes gearbeitet werden soll.</li>
</ul> QFQ - Feature #12038 (New): a) STORE_VAR: filenameOnlyStripUniq, b) SP: QSTRIPUNIQ()https://project.math.uzh.ch/issues/120382021-02-17T22:48:09ZCarsten Rosecarsten.rose@math.uzh.ch
<p>Regelmaessig sollen Dateien hochgeladen werden, bei denen es keinen Konflikt geben darf wenn bereits eine Datei mit dem Namen existiert.</p>
<p>Ein gute Loesung ist die ID des aktuellen Records an den Anfang der Datei zu setzen. Bsp.: aus `test.pdf` wird dann `1234.test.pdf`</p>
<p>Via SQL ist es aufwendig den String zu parsen:</p>
<ul>
<li>Cut Path, so dass nur noch der Filename uebrig ist.</li>
<li>Dann z.B. vom Anfang bis zum ersten Punkt alles abschneiden.</li>
</ul>
<p>Wunsch:</p>
<p>a) Im STORE_VAR eine neue Variable `filenameOnlyStripUniq` einfuehren die geanu das macht.<br />b) Eine neue Stored Procedure <abbr title="">QSTRIPUNIQ</abbr>() anlegen die genau das macht (kann in Report verwednet werden)</p> QFQ - Feature #11716 (New): Form an beliebiger Stelle im Report anzeigenhttps://project.math.uzh.ch/issues/117162020-12-09T08:47:08ZPhilipp Gröbelbauer
<p>Forms sollen nicht nur zu oberst im Report angezeigt werden können</p> QFQ - Bug #11715 (New): acceptZeroAsRequired and requiredOffButMark do not coincidehttps://project.math.uzh.ch/issues/117152020-12-08T11:13:30ZSimon Grüning
<p>A 0 is marked as accepted by requiredOffButMark in the front-end, but not by acceptZeroAsRequired=0 in the allRequiredGiven:V variable.</p>
<p>To reproduce, a required enum list:</p>
<pre>
emptyItemAtStart
itemList='0:0,1:1,2:2,3:3,4:4,5:5,6:6'
acceptZeroAsRequired=0
</pre> QFQ - Feature #11534 (New): Report: Action on selected rows - Table batchprocessing featurehttps://project.math.uzh.ch/issues/115342020-11-17T11:06:12ZSimon Grüning
<p>See attached picture. A feature to add an additional column of check-boxes at the beginning of a table, and the ability to have buttons ex. "with selected: move all to bla". So batch processing of table rows / records.</p>
<p>Implementation idea: via javascript? Buttons passing list of id's (or respective sip's) of records and action onto backend.</p> QFQ - Bug #11522 (New): Aus/Einblenden von Reiternhttps://project.math.uzh.ch/issues/115222020-11-13T13:58:13ZChristoph Fuchs
<p>Ist beim Laden eines Formulars ein Reiter ausgeblendet und wird dieser abhängig von einem Feld dynamisch eingeblendet, so sind alle Felder dieses Reiters unsichtbar.</p>
<p>QFQ Version 20.4.0</p> QFQ - Bug #11195 (New): Dynamic Update: Note not updated if new text is empty (v20.4)https://project.math.uzh.ch/issues/111952020-09-25T09:14:05ZNicola Chiapolini
<p>We had a dynamic updated note-Element with value</p>
<p><code>#!report<br />10.sql = SELECT notes FROM rooms WHERE building = '{{building:FSRD:alnumx}}' AND room = '{{room:FSRD:alnumx}}'<br />10.twig = {{ result.0.notes }}<br /></code></p>
<p>The note-Element is not updated, if the notes is empty or the query does not return a row.<br />The following code works:</p>
<p><code>#!report<br />10.sql = SELECT notes, RAND() AS dummy FROM rooms WHERE building = '{{building:FSRD:alnumx}}' AND room = '{{room:FSRD:alnumx}}'<br />10.twig = <span>{{ result.0.notes }}</span><br /></code></p>
<p>(Since we only update via T3 Extension store, we are still running 20.4 so this might be fixed by now.)</p> QFQ - Bug #10890 (New): AutoCron hangshttps://project.math.uzh.ch/issues/108902020-07-20T11:56:03ZChristoph Fuchs
<p>Wenn in der Tabelle "Cron" ein Wert in >0 "inProgess" definiert ist, werden für deisen Record keine Mails mehr versandt.<br />Selbst ein Neustart ändert nichts daran. Der Tooltip "inProgress > 10mins" sollte vielleicht mit einem Vermerk versehen werden.</p>
<p>Noch schöner wäre, wenn "inProgress > 10mins" automatich einen neuen Button zu Anzeige brächte, mit dem "inProgess" auf 0 zurückgesetzt werden könnte.<br />Viele Grüsse<br />c</p> QFQ - Feature #10874 (New): Erstellen eines Foreign Keys in der Tabelle "FormElement"https://project.math.uzh.ch/issues/108742020-07-13T08:11:32ZChristoph Fuchs
<p>Wenn die "FormElement"-Tabelle angepasst wird:<br /> ALTER TABLE xyz.FormElement<br /> ADD CONSTRAINT FK_FormElement_formId FOREIGN KEY (formId)<br /> REFERENCES xyz.Form (id) ON DELETE CASCADE ON UPDATE CASCADE;<br />kann der Primärschlüssel der "Form"-Tabelle manuell angepasst werden und die "FormElement" Tabelle wird automatisch nachgeführt.<br />Ist auch datenbanktechnisch korrekt.</p> QFQ - Feature #10763 (New): form accessed and submitted despite logout?https://project.math.uzh.ch/issues/107632020-06-16T09:43:02ZNicola Chiapolini
<p>Wir hatten ein Problem in der DB, das ich auf folgende (annonymisierte) Log-Zeilen zurückführen konnte:</p>
<p><code><br />[2020.06.15 17:58:16 +0200][89.206.112.13][FE:aaaaaa,Page:8,tt:43,form:phd_reg-graduation][INSERT INTO `phd_graduation` ( `shortname`, `student_id`, `name`, `firstname`, `salutation`, `birthday`, `mail_uzh`, `mail_private`, `nationality`, `subject_of_study`, `title_of_thesis`, `colloquium_start`, `disputation_start` ) VALUES ( 'aaaaaa', '12-345-678', 'Muster', 'Pauline', 'Frau', '1991-02-02', 'pauline.muster@uzh.ch', 'muster@example.com', 'FR', '50646022', 'A Thesis Title', '2020-08-04 13:00', '2020-08-04 13:00' )]<br />[2020.06.15 17:58:16 +0200][89.206.112.13][FE:aaaaaa,Page:8,tt:43,form:phd_reg-graduation][ID: 492 - affected rows: 1]<br />[2020.06.15 17:58:16 +0200][89.206.112.13][FE:aaaaaa,Page:8,tt:43,form:phd_reg-graduation][UPDATE `phd_graduation` SET `pdf_of_thesis` = 'studentadmin/phd/thesis/aaaaaa-thesis.pdf' WHERE id = '492']<br />[2020.06.15 17:58:16 +0200][89.206.112.13][FE:aaaaaa,Page:8,tt:43,form:phd_reg-graduation][Affected rows: 1]<br />[2020.06.15 17:58:16 +0200][89.206.112.13][FE:aaaaaa,Page:8,tt:43,form:phd_reg-graduation][UPDATE phd_graduation SET title_hash=MD5(title_of_thesis) WHERE shortname='aaaaaa']<br />[2020.06.15 17:58:16 +0200][89.206.112.13][FE:aaaaaa,Page:8,tt:43,form:phd_reg-graduation][Affected rows: 1]<br />[2020.06.15 17:58:16 +0200][89.206.112.13][FE:aaaaaa,Page:8,tt:43,form:phd_reg-graduation][UPDATE phd_graduation SET reg_done=NULL WHERE reg_done="0000-00-00 00:00:00"]<br />[2020.06.15 17:58:16 +0200][89.206.112.13][FE:aaaaaa,Page:8,tt:43,form:phd_reg-graduation][Affected rows: 0]<br />[2020.06.15 17:59:04 +0200][89.206.112.13][form:phd_reg-graduation][INSERT INTO `Dirty` (`sip`, `tableName`, `recordId`, `expire`, `recordHashMd5`, `tabUniqId`, `feUser`, `qfqUserSessionCookie`, `dirtyMode`, `remoteAddress`, `created`) VALUES ( '5ee79a9c90289','phd_graduation','492','2020-06-15 18:14:03','dfb854d090d8febd3b6d2e976c1c5f88','1593618907666','','6ba6k9hj4je4lgf2puhnmrsddh','exclusive','89.206.112.13','20200615175904' )]<br />[2020.06.15 17:59:04 +0200][89.206.112.13][form:phd_reg-graduation][ID: 20386 - affected rows: 1]<br />[2020.06.15 17:59:12 +0200][89.206.112.13][Page:8,tt:43,form:phd_reg-graduation][DELETE FROM `Dirty` WHERE `id`='20386' LIMIT 1]<br />[2020.06.15 17:59:12 +0200][89.206.112.13][Page:8,tt:43,form:phd_reg-graduation][Affected rows: 1]<br />[2020.06.15 17:59:12 +0200][89.206.112.13][Page:8,tt:43,form:phd_reg-graduation][INSERT INTO `FormSubmitLog` (`formData`, `sipData`, `clientIp`, `feUser`, `userAgent`, `formId`, `recordId`, `pageId`, `sessionId`, `created`)VALUES ('{"email":"","username":"","password":"","recordHashMd5":"dfb854d090d8febd3b6d2e976c1c5f88","reg_done-492":"2020-06-15 17:58:20","mail_private-492":"muster@example.com","title_of_thesis-492":"<p>A Thesis Title<\/p>","pdf_of_thesis-492":"5ee79a9c8ebcf","colloquium_start-492":"2020-08-04 13:00","disputation_start-492":"2020-08-04 13:00","_sipForTypo3Vars":"5ee79a9c90172"}', '{"birthday":"1991-02-02","firstname":"Pauline","form":"phd_reg-graduation","mail_uzh":"pauline.muster@uzh.ch","name":"Muster","nationality":"FR","r":"492","salutation":"Frau","shortname":"aaaaaa","student_id":"12-345-678","subject_of_study":"50646067","s":"5ee79a9c90289","urlparam":"birthday=1991-02-02&firstname=Pauline&form=phd_reg-graduation&mail_uzh=pauline.muster@uzh.ch&name=Muster&nationality=FR&r=492&salutation=Frau&shortname=aaaaaa&student_id=12-345-678&subject_of_study=50646067"}', '89.206.112.13', '', 'Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_4) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/81.0.4044.129 Safari/537.36', '1000', '492', '8', '6ba6k9hj4je4lgf2puhnmrsddh', NOW())]<br />[2020.06.15 17:59:12 +0200][89.206.112.13][Page:8,tt:43,form:phd_reg-graduation][ID: 42051 - affected rows: 1]<br />[2020.06.15 17:59:12 +0200][89.206.112.13][Page:8,tt:43,form:phd_reg-graduation][UPDATE `phd_graduation` SET `shortname` = 'aaaaaa', `student_id` = '12-345-678', `name` = 'Muster', `firstname` = 'Pauline', `salutation` = 'Frau', `birthday` = '1991-02-02', `mail_uzh` = 'pauline.muster@uzh.ch', `mail_private` = 'muster@example.com', `nationality` = 'FR', `subject_of_study` = '50646067', `title_of_thesis` = 'A Thesis Title', `reg_done` = '2020-06-15 17:58:20', `colloquium_start` = '2020-08-04 13:00', `disputation_start` = '2020-08-04 13:00' WHERE id = '492']<br /></code></p>
<p>Für die zweite Hälfte des Logs fehlt der feUser - es scheint der User hat/wurde ausgeloggt. Das Problem damit ist, dass die SIP-Links für die Formulare nur mit Login sichtbar sind und das Formular deshalb davon ausgeht, dass der FE-User definiert ist. Natürlich ist es unser Fehler, dass wir das im Formular nicht abfangen. Allerdings bricht QFQ sowohl hier wie auch bei <a class="issue tracker-1 status-4 priority-2 priority-default" title="Bug: Formular trotz Timeout gespeichert (Feedback)" href="https://project.math.uzh.ch/issues/9898">#9898</a> das intuitive Verständnis von Login/Logout. Sicherer und User-freundlicher wäre es, wenn ein Logout sich sofort auf alle SIP und Formulare auswirkt. Konkret also.</p>
<p>Aufgefallen ist uns das ganze, weil in der letzten Zeile `subject_of_study` falsch ist (da das in einem Extra-Feld mit einem Query <code>... WHERE shortname='{{ feUser:TE }}'</code> gefüllt wird)</p> QFQ - Bug #10759 (New): emptyMeansNull - Feld falsch aktualisierthttps://project.math.uzh.ch/issues/107592020-06-15T14:42:08ZChristoph Fuchs
<p>Ein Feld, das als Parameter "emptyMeansNull=1" definiert hat,<br />erhält nach dem Speichern des Formaulars (ohne dass das Formular geschlossen wird) den Wert "False".<br />In der DB ist aber alles in Orndung, sprich NULL.</p> QFQ - Feature #10738 (Some day maybe): CORS headers for external API requestshttps://project.math.uzh.ch/issues/107382020-06-10T12:00:34ZMarc Egger
<p>Optionally allow setting the CORS headers inside a QFQ API Form such that the API may be called from a website hosted under a different domain.</p>
<p>Working example: <a class="external" href="https://stackoverflow.com/a/9866124">https://stackoverflow.com/a/9866124</a><br /><pre><code class="php syntaxhl"><span class="cd">/**
* An example CORS-compliant method. It will allow any GET, POST, or OPTIONS requests from any
* origin.
*
* In a production environment, you probably want to be more restrictive, but this gives you
* the general idea of what is involved. For the nitty-gritty low-down, read:
*
* - https://developer.mozilla.org/en/HTTP_access_control
* - http://www.w3.org/TR/cors/
*
*/</span>
<span class="k">function</span> <span class="n">cors</span><span class="p">()</span> <span class="p">{</span>
<span class="c1">// Allow from any origin</span>
<span class="k">if</span> <span class="p">(</span><span class="k">isset</span><span class="p">(</span><span class="nv">$_SERVER</span><span class="p">[</span><span class="s1">'HTTP_ORIGIN'</span><span class="p">]))</span> <span class="p">{</span>
<span class="c1">// Decide if the origin in $_SERVER['HTTP_ORIGIN'] is one</span>
<span class="c1">// you want to allow, and if so:</span>
<span class="nb">header</span><span class="p">(</span><span class="s2">"Access-Control-Allow-Origin: </span><span class="si">{</span><span class="nv">$_SERVER</span><span class="p">[</span><span class="s1">'HTTP_ORIGIN'</span><span class="p">]</span><span class="si">}</span><span class="s2">"</span><span class="p">);</span>
<span class="nb">header</span><span class="p">(</span><span class="s1">'Access-Control-Allow-Credentials: true'</span><span class="p">);</span>
<span class="nb">header</span><span class="p">(</span><span class="s1">'Access-Control-Max-Age: 86400'</span><span class="p">);</span> <span class="c1">// cache for 1 day</span>
<span class="p">}</span>
<span class="c1">// Access-Control headers are received during OPTIONS requests</span>
<span class="k">if</span> <span class="p">(</span><span class="nv">$_SERVER</span><span class="p">[</span><span class="s1">'REQUEST_METHOD'</span><span class="p">]</span> <span class="o">==</span> <span class="s1">'OPTIONS'</span><span class="p">)</span> <span class="p">{</span>
<span class="k">if</span> <span class="p">(</span><span class="k">isset</span><span class="p">(</span><span class="nv">$_SERVER</span><span class="p">[</span><span class="s1">'HTTP_ACCESS_CONTROL_REQUEST_METHOD'</span><span class="p">]))</span>
<span class="c1">// may also be using PUT, PATCH, HEAD etc</span>
<span class="nb">header</span><span class="p">(</span><span class="s2">"Access-Control-Allow-Methods: GET, POST, OPTIONS"</span><span class="p">);</span>
<span class="k">if</span> <span class="p">(</span><span class="k">isset</span><span class="p">(</span><span class="nv">$_SERVER</span><span class="p">[</span><span class="s1">'HTTP_ACCESS_CONTROL_REQUEST_HEADERS'</span><span class="p">]))</span>
<span class="nb">header</span><span class="p">(</span><span class="s2">"Access-Control-Allow-Headers: </span><span class="si">{</span><span class="nv">$_SERVER</span><span class="p">[</span><span class="s1">'HTTP_ACCESS_CONTROL_REQUEST_HEADERS'</span><span class="p">]</span><span class="si">}</span><span class="s2">"</span><span class="p">);</span>
<span class="k">exit</span><span class="p">(</span><span class="mi">0</span><span class="p">);</span>
<span class="p">}</span>
<span class="k">echo</span> <span class="s2">"You have CORS!"</span><span class="p">;</span>
<span class="p">}</span>
</code></pre></p> QFQ - Feature #10384 (New): Parameter Exchange QFQ Instanceshttps://project.math.uzh.ch/issues/103842020-04-08T11:35:00ZCarsten Rosecarsten.rose@math.uzh.ch
<p>Bei <a class="external" href="http://www.math">www.math</a> und w3/my haben wir das Problem das wir gerne Parameter uebergeben wuerden</p>
<ul>
<li>Join video conference</li>
<li>access recording </li>
<li>NEWS: Preview einer neu angelegten News (MY) auf MATH anzeigen.</li>
</ul>
<p>- die Instanzen sind aber unanabhaengig von einander.</p>
Idee:
<ul>
<li>[registered sip] <a class="external" href="http://www.math">www.math</a> (QFQ) kann ueber eine API SIPs bei w3/math registrieren. Das koennte aehnlich sein wie persistente SIPs (eine spezielle Variante). Solche registered SIPs sind unpersoenlich.</li>
<li>[encoded sip] zwischen den instanzen werden public keys (shared secred) ausgetauscht. Damit werden die Parameter verschluesselt und uebergeben.</li>
</ul>
<p>Notes:</p>
<ul>
<li><a class="external" href="https://stackoverflow.com/questions/9262109/simplest-two-way-encryption-using-php">https://stackoverflow.com/questions/9262109/simplest-two-way-encryption-using-php</a>
* Comment von 'Hemerson Varela' >> libsodium</li>
</ul> QFQ - Feature #10345 (New): Templates - Patterns QFQ Stylehttps://project.math.uzh.ch/issues/103452020-04-02T21:10:52ZBenjamin Baerbenjamin.baer@math.uzh.ch
<p>Ein "Pattern" im Design ist eine Vorgabe wie etwas aussehen soll.</p>
<p>Nehmen wir mal als Beispiel das teachingtool:</p>
<pre><div class="item">
<div class="item-background"></div>
<a class="item-image" style="background-image: url('typo3conf/ext/qfq/Classes/Api/download.php?s=5e8651ff802ce')" href="?id=tool&amp;toolId=118"></a>
<div class="item-description">Hinweise für die Übertragung einer geplanten Multiple-Choice-Prüfung in ein alternatives digitales Format</div>
<span class="item-meta">1.4.2020 17:02 Uhr</span><a class="item-title" href="?id=tool&amp;toolId=118">MC-Prüfungen (Remote)</a>
<div class="item-tags">
Tags:
<a class="label label-primary" href="index.php?id=alltools&amp;tagId=104">Leistungsnachweise</a>
<a class="label label-primary" href="index.php?id=alltools&amp;tagId=126">Digitale Lehre</a>
</div>
</div></pre>
<p>Nun brauchen wir diesen Satz an mehreren Orten vom Teachingtool - und wenn man etwas am Grunddesign aendert, muss man an jeden Ort denken in dem es vorkommt.</p>
<p>Mit dingen wie _link machen wir es uns relativ einfach diese Dinge zu erstellen - ist in diesem Sinne bereits ein Pattern.</p>
<p>Nun, wandeln wir obigen Satz mal in ein Pattern um:<br /> <pre><div class="item">
<div class="item-background"></div>
<a class="item-image" style="background-image: url('{{backgroundImage:R}}')" href="{{toolLink:R}}"></a>
<div class="item-description">{{itemDescription:R}}</div>
<span class="item-meta">{{dateTime:R0}}</span><a class="item-title" href="{{toolLink:R}}">{{itemTitle:RE}}</a>
<div class="item-tags">
Tags:
{{@tagLoopStart}}<a class="label label-primary" href="{{itemTagLink:R}}">{{itemTagName:R0}}</a>{{@tagLoopEnd}}
</div>
</div></pre></p>
<p>Und dazu dann der SQL Aufruf:<br /><pre>10 {
sql = SELECT "blabla" AS _itemTitle, ....
pattern = item
20 {
sql = SELECT CONCAT('index.php?id=tag&tagId=", tag.id) AS _itemTagLink, tag.name AS _itemTagName ...
loop = tagLoop
}
}</pre></p>
<p>Die Designs selbst koennten dabei aehnlich wie System Variabeln definiert werden und seitenweit abgelegt sein. Oder besser wie Form direkt ueber eine Art editor im frontend erstellt (bzw. gleich als git datei - um die eigenen HTML Editoren verwenden zu koennen)</p>
<p>Pattern wird natuerlich hier immer quasi erst "renr" ausgefuehrt, da einzelne Teile aus subqueries kommen koennten (und mit loops sogar muessen). Neben Store :R koennte man auch die anderen Stores abfragen, vorallem Y und U.</p>