Commit df04ed06 authored by Marc Egger's avatar Marc Egger
Browse files

Refs #12588 add release notes for slug migration. Migrate Documentation pageAlias >> pageSlug

parent ed796363
Pipeline #5450 passed with stages
in 3 minutes and 10 seconds
......@@ -300,8 +300,20 @@ Error Messages & Exceptions
* plus an Errorhandler which throws exceptions
* Exceptions inside of an API call delivers the error code and msg as JSON to the client.
* Typo3 suppress E_NOTICE (e.g. undefined index). To catch E_NOTICE in QFQ, it will be temporaly enabled in QfqCongroller.php.
* Typo3 suppress E_NOTICE (e.g. undefined index). To catch E_NOTICE in QFQ, it will be temporally enabled in QfqCongroller.php.
System Messages to Developer
============================
To show a system message to the developer when he is logged in to the backend use the following pattern:
```
QuickFormQuery::$systemMessages[] = 'A message to the developer'
```
* The message is rendered above every QFQ report.
* The message is only rendered if a user is logged in the Typo3 backend.
* The message is wrapped in <div class="alert alert-warning">
Stores
======
......
......@@ -144,7 +144,7 @@ Note: If you do not use/have the Ggroup table, then remove the "# Filters" block
FROM Ggroup AS gr
INNER JOIN MailLog AS ml ON ml.grId = gr.id
GROUP BY gr.id
head = <form onchange='this.submit();' class='form-inline'><input type='hidden' name='id' value='{{pageAlias:T0}}'>
head = <form onchange='this.submit();' class='form-inline'><input type='hidden' name='id' value='{{pageSlug:T0}}'>
Filter By Group: <select name='grId' class='form-control'><option value=''></option>
rbeg = <option value=
rend = </option>
......@@ -214,9 +214,9 @@ Display QFQ log files in realtime. Put the following code in a QFQ page content
head = <p>
tail = </p>
20.sql = SELECT CONCAT('p:{{pageAlias:T}}&logfile=sql.log|t:sql.log|b:', IF('{{logfile:R}}'='sql.log','primary','')) AS _page, ' '
, CONCAT('p:{{pageAlias:T}}&logfile=qfq.log|t:qfq.log|b:', IF('{{logfile:R}}'='qfq.log','primary','')) AS _page, ' '
, CONCAT('p:{{pageAlias:T}}&logfile=mail.log|t:mail.log|b:', IF('{{logfile:R}}'='mail.log','primary','')) AS _page
20.sql = SELECT CONCAT('p:{{pageSlug:T}}?logfile=sql.log|t:sql.log|b:', IF('{{logfile:R}}'='sql.log','primary','')) AS _page, ' '
, CONCAT('p:{{pageSlug:T}}?logfile=qfq.log|t:qfq.log|b:', IF('{{logfile:R}}'='qfq.log','primary','')) AS _page, ' '
, CONCAT('p:{{pageSlug:T}}?logfile=mail.log|t:mail.log|b:', IF('{{logfile:R}}'='mail.log','primary','')) AS _page
}
# Show selected log file.
......@@ -247,7 +247,7 @@ Check the Form Submit Log page to see what have been submitted. Put the followin
# Filters
10 {
sql = SELECT ''
shead = <form onchange='this.submit()' class='form-inline'><input type='hidden' name='id' value='{{pageAlias:T0}}'>
shead = <form onchange='this.submit()' class='form-inline'><input type='hidden' name='id' value='{{pageSlug:T0}}'>
stail = </form>
# Dropdown: Form
......
......@@ -210,7 +210,7 @@ Form Settings
+-------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------+
|Forward Mode | 'auto | close | no | url | url-skip-history | url-sip | url-sip-skip-history' (Default: auto): See :ref:`form-forward`. |
+-------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------+
|Forward (Mode) Page | a) URL / Typo3 page id/alias or b) Forward Mode (via '{{...}}') or combination of a) & b). See :ref:`form-forward`. |
|Forward (Mode) Page | a) URL / Typo3 page slug or b) Forward Mode (via '{{...}}') or combination of a) & b). See :ref:`form-forward`. |
+-------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------+
|labelAlign | Label align (default/left/center/right)/ Default: 'default' (defined by Config). _`form-label-align` |
+-------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------+
......@@ -353,7 +353,7 @@ Format: [<url>] or [<mode>|<url>]
* `http://www.example.com/index.html?a=123#bottom`
* `website.html?a=123#bottom`
* `?id=<T3 Alias pageid>&a=123#bottom, ?id=<T3 page id>&a=123#bottom`
* `<T3 page slug>&a=123#bottom, ?id=<T3 page id>&a=123#bottom`
* `{{SELECT ...}}`
* `<mode>|<url>`
......@@ -641,7 +641,7 @@ Usage example
*Readonly*
Code: ``SELECT 'p:{{pageAlias}}&form=person&r=1&formModeGlobal=readonly|s|t:View|s|b' AS _link``
Code: ``SELECT 'p:{{pageSlug}}?form=person&r=1&formModeGlobal=readonly|s|t:View|s|b' AS _link``
* The form is called with SIP parameter ``formModeGlobal=readonly`` or ``form.parameter.mode=readonly``.
* The user can't change any data.
......@@ -650,7 +650,7 @@ Code: ``SELECT 'p:{{pageAlias}}&form=person&r=1&formModeGlobal=readonly|s|t:View
Code (somewhere): ``SELECT 'requiredoff' AS '_=formModeGlobal'``
Code: ``SELECT 'p:{{pageAlias}}&form=person&r=1|s|t:View|s|b' AS _link``
Code: ``SELECT 'p:{{pageSlug}}?form=person&r=1|s|t:View|s|b' AS _link``
* The STORE_USER variable is set `formModeGlobal=readonly`.
* All forms will be shown in readonly mode - fast option to give a user access to the website, without the possibility to
......@@ -658,7 +658,7 @@ Code: ``SELECT 'p:{{pageAlias}}&form=person&r=1|s|t:View|s|b' AS _link``
*Draft Mode 1*
Code: ``SELECT 'p:{{pageAlias}}&form=person&r=1&formModeGlobal=readquiredOff|s|t:View|s|b' AS _link``
Code: ``SELECT 'p:{{pageSlug}}?form=person&r=1&formModeGlobal=readquiredOff|s|t:View|s|b' AS _link``
* A form has one or more FormElement with 'fe.type=required'.
* Opening the form with `formModeGlobal=requiredOff` will allow the user to save the form, even if not all
......@@ -668,7 +668,7 @@ Code: ``SELECT 'p:{{pageAlias}}&form=person&r=1&formModeGlobal=readquiredOff|s|t
*Draft Mode 2*
Code: ``SELECT 'p:{{pageAlias}}&form=person&r=1&formModeGlobal=readquiredOff|s|t:View|s|b' AS _link``
Code: ``SELECT 'p:{{pageSlug}}?form=person&r=1&formModeGlobal=readquiredOff|s|t:View|s|b' AS _link``
* A form has one or more FormElement with 'fe.type=required'.
* Calling the form with `formModeGlobal=requiredOff` will allow the user to save the form, even if not all
......@@ -1859,7 +1859,7 @@ will be rendered inside the form as a HTML table.
* *FormElement.parameter*
* *form* = `<form name>` - Target form, e.g. *form=person*
* *page* = `<T3 page alias or id>` - Target page with detail form. If none specified, use the current page.
* *page* = `<T3 slug>` - Target page with detail form. If none specified, use the current page.
* *extraDeleteForm*: Optional. The per row delete Button will reference the form specified here (for deleting) instead of the default (*form*).
* *detail* = `<string>` - Mapping of values from
......@@ -2536,7 +2536,7 @@ Example: A slave record (e.g. an address of a person) has to be assigned to a ma
``person.id=address.pId``. Just give the `pId` in the link who calls the address form. The following creates a 'new'
button for an address for all persons, and the pId will be automatically saved in the address table: ::
SELECT CONCAT('p:{{pageAlias:T}}&form=address&r=0&pId=', p.id) AS _pagen FROM Person AS p
SELECT CONCAT('p:{{pageSlug:T}}?form=address&r=0&pId=', p.id) AS _pagen FROM Person AS p
Remember: it's a good practice to specify such parameter in Form.permitNew and/or Form.permitEdit. It's only a check for
the webmaster, not to forgot a parameter in a SIP url.
......@@ -3033,7 +3033,7 @@ in 'detail' or 'list' mode. Create a single QFQ tt-content record on a fresh pag
form = {{form:SE}}
10.sql = SELECT p.name, CONCAT('p:{{pageAlias:T}}&form=Person&r=', p.id) AS _pagee FROM Person AS p
10.sql = SELECT p.name, CONCAT('p:{{pageSlug:T}}?form=Person&r=', p.id) AS _pagee FROM Person AS p
10.rend = <br>
* If the page is called without any parameter, a list of persons is shown.
......@@ -3104,12 +3104,12 @@ QFQ content record::
# Creates a small form that redirects back to this page
10 {
sql = SELECT '_'
head = <form action='#' method='get'><input type='hidden' name='id' value='{{pageAlias:T}}'>Search: <input type='text' name='search' value='{{search:CE:all}}'><input type='submit' value='Submit'></form>
head = <form action='#' method='get'><input type='hidden' name='id' value='{{pageSlug:T}}'>Search: <input type='text' name='search' value='{{search:CE:all}}'><input type='submit' value='Submit'></form>
}
# SQL statement will find and list all the relevant forms - be careful not to open a cross site scripting door: the parameter 'search' needs to be sanitized.
20 {
sql = SELECT CONCAT('p:{{pageAlias:T}}&form=form&r=', f.id) AS _pagee, f.id, f.name, f.title
sql = SELECT CONCAT('p:{{pageSlug:T}}?form=form&r=', f.id) AS _pagee, f.id, f.name, f.title
FROM Form AS f
WHERE f.name LIKE '%{{search:CE:alnumx}}%'
head = <table class='table'>
......@@ -3602,7 +3602,7 @@ Installation:
* Insert a link/button 'Copy form from ExtForm' to open the import/merge form. A good place is the list of all forms (see :ref:`form-editor`).
E.g.: ::
10.head = {{'b|p:id={{pageAlias:T}}&form=copyFormFromExt|t:Copy form from ExtForm' AS _link }} ...
10.head = {{'b|p:{{pageSlug:T}}?form=copyFormFromExt|t:Copy form from ExtForm' AS _link }} ...
If there are several T3/QFQ instances and if forms should be imported frequently/easily, set up a one shot
'import Forms from db xyz' like: ::
......
......@@ -149,13 +149,13 @@ Note the '-' in '{{text:RE::-}}', this will prevent that QFQ escapes any charact
tail = {{text:RE::-}}
}
TypeAhead list with T3 page alias names - use of the T3 DB
TypeAhead list with T3 page slug names - use of the T3 DB
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
To define a typeahead list of T3 page alias names::
To define a typeahead list of T3 page slug names::
FE.type = text
FE.parameter.typeAheadSql = SELECT p.alias FROM {{dbNameT3:Y}}.Pages AS p WHERE p.deleted=0 AND p.alias!='' AND p.alias LIKE ? ORDER BY p.alias LIMIT 20
FE.parameter.typeAheadSql = SELECT p.slug FROM {{dbNameT3:Y}}.Pages AS p WHERE p.deleted=0 AND p.slug!='' AND p.slug LIKE ? ORDER BY p.slug LIMIT 20
FE.parameter.typeAheadMinLength = 1
.. _setFeUserPassword:
......
......@@ -273,7 +273,7 @@ FormEditor
Setup a *report* to manage all *forms*:
* Create a Typo3 page.
* Set the 'URL Alias' to `form` (recommended) or the individual defined value in parameter `editFormPage` (configuration_).
* Set the 'URL slug' to `/form` (recommended) or the individual defined value in parameter `editFormPage` (configuration_).
* Insert a content record of type *qfq*.
* In the bodytext insert the following code (see explanation of code: :ref:`reportAsFile`)::
......@@ -290,6 +290,7 @@ Installation: Check List
* `<T3 installation>/fileadmin/protected/qfqProject/log/...` is the default place for QFQ log files.
* Protect the directory `<T3 installation>/fileadmin` in Apache to not execute PHP Scripts - malicious uploads won't be executed.
* Correctly set the QFQ extension setting "base url" in the typo3 backend.
* Setup a log rotation rule for `sqlLog`.
* Check that `sqlLogMode` is set to `modify` on productive sites. With `none` you have no chance to find out who changed
which data and `all` really logs a mass of data.
......@@ -515,7 +516,7 @@ Extension Manager: QFQ Configuration
+-----------------------------------+-------------------------------------------------------+----------------------------------------------------------------------------+
| enterAsSubmit | enterAsSubmit = 1 | 0: off, 1: Pressing *enter* in a form means *save* and *close*. |
+-----------------------------------+-------------------------------------------------------+----------------------------------------------------------------------------+
| editFormPage | form | T3 Pagealias to edit a form. |
| editFormPage | form | T3 page slug to edit a form. |
+-----------------------------------+-------------------------------------------------------+----------------------------------------------------------------------------+
| formDataPatternError | please check pattern error | Customizable error message used in validator.js. 'pattern' violation. |
+-----------------------------------+-------------------------------------------------------+----------------------------------------------------------------------------+
......@@ -684,8 +685,8 @@ To get the name and current period: ::
Typically, it's necessary to offer a 'previous' / 'next' link. In this example, the STORE SIP holds the new periodId: ::
SELECT CONCAT('p:{{pageAlias:T}}&periodId=', {{periodId:SY0}}-1, '|Next') AS _page, ' ', name, ' ',
CONCAT('p:{{pageAlias:T}}&periodId=', {{periodId:SY0}}+1, '|Next') AS _page FROM Period AS s WHERE s.id={{periodId:SY0}}
SELECT CONCAT('p:{{pageSlug:T}}?periodId=', {{periodId:SY0}}-1, '|Next') AS _page, ' ', name, ' ',
CONCAT('p:{{pageSlug:T}}?periodId=', {{periodId:SY0}}+1, '|Next') AS _page FROM Period AS s WHERE s.id={{periodId:SY0}}
Take care for minimum and maximum indexes (do not render the links if out of range).
......
......@@ -38,7 +38,7 @@
Release
=======
Version 21.x.x
Version 21.x.x vvvvvvvvvvvvvvvvv THERE ARE ALREADY RELEASE NOTES FOR THE NEXT VERSION, SEE BELOW!
--------------
Date: <date>
......@@ -52,6 +52,53 @@ Features
Bug Fixes
^^^^^^^^^
Version 21.x.x <<<<<<<<<<<<<<<<<<<<<< NEXT VERSION
--------------
Date: <date>
Notes
^^^^^
* Typo3 v9 uses url paths instead of page ids for urls. e.g. "/home" instead of "home/index.php?id=home"
* The Typo3 pages do not have the alias property anymore.
* QFQ used to generate links of the form "index.php?id=home&...". Those don't work anymore.
* QFQ now generates qfq links using the page slug. e.g. "p:/some/page?foo=bar" AS _link generates a link with url "https://mydomain.com/some/page?foo=bar".
* A page slug always starts with a slash "/" and QFQ expects that slash to be there.
* Every existing QFQ link has to be adjusted to the new format using slugs instead of page id or alias.
* QFQ shows an automatic detection and migration dialog to help with fixing all broken links.
* After the migration dialog has been deactivated it can be reactivated by setting the variable FORCE_RUN_PAGE_SLUG_MIGRATION_CHECK to true in filedamin/protected/qfqProject/conf/qfq.json
* For the new links to work properly the base Url has to be configured in the QFQ Typo3 settings.
* Please follow these practices:
* Use {{pageSlug:T}} instead of {{pageAlias:T}} or {{pageId:T}} in the _link columns. E.g. "p:{{pageSlug}}?foo=bar" AS link .
* Note: "&" after alias should be replaced by "?" after slug in _link p: value.
* Use {{baseUrlLang:Y}}/{{pageSlug:T}} instead of {{pageAlias:T}} or {{pageId:T}} in hardcoded <a> tags. E.g. href="{{baseUrlLang:Y}}/{{pageSlug:T}}?foo=bar" .
* Replace hardcoded aliases in QFQ code with the slugs of the pages. E.g. "p:/some/page?foo=bar" AS _link
* Hint: Typo3 replaces "_" with "-" when converting an alias to a slug during the Typo3 version 9 upgrade.
* Replace the "U:" token with "p:" for all sepecial columns except _paged. I.e. "U: ... &id=[alias]& ... " becomes "p:[slug]? ... ".
Features
^^^^^^^^
* {{pageSlug:T}} holds the slug of the current page. (Typo3 v9 and up)
* The "p:.." token now takes page slugs instead of alias everywhere. (Typo3 v9 and up)
* provide dialog for the developer to migrate from page alias to page slug. (Typo3 v9 and up)
Bug Fixes
^^^^^^^^^
Deprecated
^^^^^^^^^^
* The usage of {{pageAlias:T}} will produce an exception. (Typo3 v9 and up)
Version 21.6.0
--------------
......
......@@ -264,7 +264,7 @@ and then displays the files in a nice table with links to the files. ::
10.10.sql = SELECT id, path_scan FROM FileTracker
WHERE assigned_to = '{{user:R}}'
10.10.twig = <h2>{{ store.record.user }}</h2>
<table class="table table-hover tablesorter" id="{{pageAlias:T}}-twig">
<table class="table table-hover tablesorter" id="{{pageSlug:T}}-twig">
<thead><tr><th>ID</th><th>File</th></tr></thead>
<tbody>
{% for row in result %}
......@@ -940,22 +940,22 @@ The colum name is composed of the string *page* and a trailing character to spec
+---------------+-----------------------------------------------+-------------------------------------+----------------------------------------------+
| column name | Purpose |default value of question parameter | Mandatory parameters |
+===============+===============================================+=====================================+==============================================+
|_page |Internal link without a grafic |empty |p:<pageId/pageAlias>[&param] |
|_page |Internal link without a grafic |empty |p:<pageSlug>[?param] |
+---------------+-----------------------------------------------+-------------------------------------+----------------------------------------------+
|_pagec |Internal link without a grafic, with question |*Please confirm!* |p:<pageId/pageAlias>[&param] |
|_pagec |Internal link without a grafic, with question |*Please confirm!* |p:<pageSlug>[?param] |
+---------------+-----------------------------------------------+-------------------------------------+----------------------------------------------+
|_paged |Internal link with delete icon (trash) |*Delete record ?* | | U:form=<formname>&r=<record id> *or* |
| | | | | U:table=<tablename>&r=<record id> |
+---------------+-----------------------------------------------+-------------------------------------+----------------------------------------------+
|_pagee |Internal link with edit icon (pencil) |empty |p:<pageId/pageAlias>[&param] |
|_pagee |Internal link with edit icon (pencil) |empty |p:<pageSlug>[?param] |
+---------------+-----------------------------------------------+-------------------------------------+----------------------------------------------+
|_pageh |Internal link with help icon (question mark) |empty |p:<pageId/pageAlias>[&param] |
|_pageh |Internal link with help icon (question mark) |empty |p:<pageSlug>[?param] |
+---------------+-----------------------------------------------+-------------------------------------+----------------------------------------------+
|_pagei |Internal link with information icon (i) |empty |p:<pageId/pageAlias>[&param] |
|_pagei |Internal link with information icon (i) |empty |p:<pageSlug>[?param] |
+---------------+-----------------------------------------------+-------------------------------------+----------------------------------------------+
|_pagen |Internal link with new icon (sheet) |empty |p:<pageId/pageAlias>[&param] |
|_pagen |Internal link with new icon (sheet) |empty |p:<pageSlug>[?param] |
+---------------+-----------------------------------------------+-------------------------------------+----------------------------------------------+
|_pages |Internal link with show icon (magnifier) |empty |p:<pageId/pageAlias>[&param] |
|_pages |Internal link with show icon (magnifier) |empty |p:<pageSlug>[?param] |
+---------------+-----------------------------------------------+-------------------------------------+----------------------------------------------+
......@@ -966,7 +966,7 @@ The colum name is composed of the string *page* and a trailing character to spec
+--------------+-------------------------------------------------------------------------------------------------+----------------------------------------------------------+---------------------------------------------------------------+
| Parameter | Description | Default value |Example |
+==============+=================================================================================================+==========================================================+===============================================================+
|<page> |TYPO3 page id or page alias. |The current page: *{{pageId}}* |45 application application&N_param1=1045 |
|<page> |TYPO3 page slug. |The current page: *{{pageSlug}}* |45 application application&N_param1=1045 |
+--------------+-------------------------------------------------------------------------------------------------+----------------------------------------------------------+---------------------------------------------------------------+
|<text> |Text, wrapped by the link. If there is an icon, text will be displayed to the right of it. |empty string | |
+--------------+-------------------------------------------------------------------------------------------------+----------------------------------------------------------+---------------------------------------------------------------+
......@@ -1040,7 +1040,7 @@ Columns: _Page[X]
::
"[<page id|alias>[&param=value&...]] | [text] | [tooltip] | [question parameter] | [class] | [target] | [render mode]" as _Pagee.
"[<page slug>[?param=value&...]] | [text] | [tooltip] | [question parameter] | [class] | [target] | [render mode]" as _Pagee.
.. _column_ppaged:
......@@ -2030,7 +2030,7 @@ Example tt-content record for the function::
100 {
sql = SELECT p.firstName AS _firstName
, NOW() AS now
, CONCAT('p:{{pageAlias:T}}&form=person&r=', p.id ) AS '_pagee|_hide|myLink'
, CONCAT('p:{{pageSlug:T}}?form=person&r=', p.id ) AS '_pagee|_hide|myLink'
FROM Person AS p
WHERE p.id={{pId:R}}
}
......@@ -2339,7 +2339,7 @@ Best practice:
page.10.value = access forbidden
[global]
#. Create a T3 `body` page (e.g. page alias: 'letterbody') with some content. Example static HTML content: ::
#. Create a T3 `body` page (e.g. page slug: '/letterbody') with some content. Example static HTML content: ::
<div class="letter-receiver">
<p>Address</p>
......@@ -2369,7 +2369,7 @@ Best practice:
</div>
</div>
#. Create a T3 letter-`header` page (e.g. page alias: 'letterheader') , with only the header information: ::
#. Create a T3 letter-`header` page (e.g. page slug: '/letterheader') , with only the header information: ::
<header>
<img src="fileadmin/logo.png" class="letter-logo">
......@@ -2902,7 +2902,7 @@ To turn any table into a sortable table:
Custom settings will be saved per table automatically in the browser local storage. To distinguish different table
settings, define an uniq HTML id per table.
Example: `<table class="tablesorter" id="{{pageAlias:T}}-person">` - the `{{pageAlias:T}}` makes it easy to keep the
Example: `<table class="tablesorter" id="{{pageSlug:T}}-person">` - the `{{pageSlug:T}}` makes it easy to keep the
overview over given name on the site.
......@@ -2921,7 +2921,7 @@ The *tablesorter* options:
* `<uniqueName>` should be a name which is at least unique inside the typo3 content element. Example::
<table {{ 'allperson' AS _tablesorter-view-saver }} class="tablesorter tablesorter-filter tablesorter-column-selector" id="{{pageAlias:T}}-demo"> ... </table>
<table {{ 'allperson' AS _tablesorter-view-saver }} class="tablesorter tablesorter-filter tablesorter-column-selector" id="{{pageSlug:T}}-demo"> ... </table>
* 'Views' can be saved as:
......@@ -3000,7 +3000,7 @@ Example::
10 {
sql = SELECT id, CONCAT('form&form=person&r=', id) AS _Pagee, lastName, title FROM Person
head = <table class="table tablesorter tablesorter-filter tablesorter-pager tablesorter-column-selector" id="{{pageAlias:T}}-ts1">
head = <table class="table tablesorter tablesorter-filter tablesorter-pager tablesorter-column-selector" id="{{pageSlug:T}}-ts1">
<thead><tr><th>Id</th><th class="filter-false sorter-false">Edit</th>
<th>Name</th><th class="filter-select" data-placeholder="Select a title">Title</th>
</tr></thead><tbody>
......@@ -3420,7 +3420,7 @@ A nice feature is to show a list with last changed records. The following will s
FormElement) forms::
10 {
sql = SELECT CONCAT('p:{{pageAlias:T}}&form=form&r=', f.id, '|t:', f.name,'|o:', GREATEST(MAX(fe.modified), f.modified)) AS _page
sql = SELECT CONCAT('p:{{pageSlug:T}}?form=form&r=', f.id, '|t:', f.name,'|o:', GREATEST(MAX(fe.modified), f.modified)) AS _page
FROM Form AS f
LEFT JOIN FormElement AS fe
ON fe.formId = f.id
......@@ -3495,12 +3495,12 @@ A page will be called with several SIP variables, but not at all at the same tim
10.sql = SELECT '{{order:USE:::sum}}' AS '_=order', '{{step:USE:::5}}' AS _step, '{{direction:USE:::ASC}}' AS _direction
# Different links
20.sql = SELECT 'p:{{pageAlias:T}}&order=count|t:Order by count|b|s' AS _link,
'p:{{pageAlias:T}}&order=sum|t:Order by sum|b|s' AS _link,
'p:{{pageAlias:T}}&step=10|t:Step=10|b|s' AS _link,
'p:{{pageAlias:T}}&step=50|t:Step=50|b|s' AS _link,
'p:{{pageAlias:T}}&direction=ASC|t:Order by up|b|s' AS _link,
'p:{{pageAlias:T}}&direction=DESC|t:Order by down|b|s' AS _link
20.sql = SELECT 'p:{{pageSlug:T}}?order=count|t:Order by count|b|s' AS _link,
'p:{{pageSlug:T}}?order=sum|t:Order by sum|b|s' AS _link,
'p:{{pageSlug:T}}?step=10|t:Step=10|b|s' AS _link,
'p:{{pageSlug:T}}?step=50|t:Step=50|b|s' AS _link,
'p:{{pageSlug:T}}?direction=ASC|t:Order by up|b|s' AS _link,
'p:{{pageSlug:T}}?direction=DESC|t:Order by down|b|s' AS _link
30.sql = SELECT * FROM Items ORDER BY {{order:U}} {{direction:U}} LIMIT {{step:U}}
......@@ -3515,8 +3515,8 @@ All places with `{{feUser:T}}` has to be replaced by `{{feUser:UT}}`::
10.sql = SELECT '{{feUser:UT}}' AS '_=feUser'
# Offer switching feUser
20.sql = SELECT 'p:{{pageAlias:T}}&feUser=account1|t:Become "account1"|b|s' AS _link,
'p:{{pageAlias:T}}&feUser={{feUser:T}}|t:Back to own identity|b|s' AS _link,
20.sql = SELECT 'p:{{pageSlug:T}}?feUser=account1|t:Become "account1"|b|s' AS _link,
'p:{{pageSlug:T}}?feUser={{feUser:T}}|t:Back to own identity|b|s' AS _link,
Semester switch (remember last choice)
......@@ -3530,9 +3530,9 @@ last used (STORE_USER) or (first time call during browser session) takes the def
# Semester switch
10 {
sql = SELECT '{{semId:SUY}}' AS '_=semId'
, CONCAT('p:{{pageAlias:T}}&semId=', sp.id, '|t:', QBAR(sp.name), '|s|b|G:glyphicon-chevron-left') AS _link
, CONCAT('p:{{pageSlug:T}}?semId=', sp.id, '|t:', QBAR(sp.name), '|s|b|G:glyphicon-chevron-left') AS _link
, ' <button class="btn disabled ', IF({{semId:Y0}}=sc.id, 'btn-success', 'btn-default'), '">',sc.name, '</button> '
, CONCAT('p:{{pageAlias:T}}&semId=', sn.id, '|t:', QBAR(sn.name), '|s|b|G:glyphicon-chevron-right|R') AS _link
, CONCAT('p:{{pageSlug:T}}?semId=', sn.id, '|t:', QBAR(sn.name), '|s|b|G:glyphicon-chevron-right|R') AS _link
FROM Semester AS sc
LEFT JOIN semester AS sp
......
......@@ -226,7 +226,9 @@ Store: *TYPO3* (Bodytext) - T
+-------------------------+-------------------------------------------------------------------+----------+
| pageId | Record id of current Typo3 page | see note |
+-------------------------+-------------------------------------------------------------------+----------+
| pageAlias | Alias of current Typo3 page. If empty, take pageId. | see note |
| pageAlias (DEPRECATED) | Alias of current Typo3 page. If empty, take pageId. | see note |
+-------------------------+-------------------------------------------------------------------+----------+
| pageSlug | Slug of current Typo3 page. | see note |
+-------------------------+-------------------------------------------------------------------+----------+
| pageTitle | Title of current Typo3 page | see note |
+-------------------------+-------------------------------------------------------------------+----------+
......
......@@ -90,7 +90,7 @@ to edit `AutoCron` jobs::
10 {
# Table header.
sql = SELECT CONCAT('p:{{pageAlias:T}}&form=cron') AS _pagen, 'id', 'Next run','Frequency','Comment'
sql = SELECT CONCAT('p:{{pageSlug:T}}?form=cron') AS _pagen, 'id', 'Next run','Frequency','Comment'
, 'Last run','In progress', 'Status', 'Auto generated'
head = <table class='table table-hover qfq-table-50'>
tail = </table>
......@@ -109,7 +109,7 @@ to edit `AutoCron` jobs::
, IF(c.inProgress!=0 AND DATE_ADD(c.inProgress, INTERVAL 10 MINUTE)<NOW(),'title="inProgress > 10mins"'
, IF(c.lastStatus LIKE 'Error%','title="Status: Error"',''))
, '>')
, '<td>', CONCAT('p:{{pageAlias:T}}&form=cron&r=', c.id) AS _pagee, '</td><td>'
, '<td>', CONCAT('p:{{pageSlug:T}}?form=cron&r=', c.id) AS _pagee, '</td><td>'
, c.id, '</td><td>'
, IF( c.nextrun=0,"", DATE_FORMAT(c.nextrun, "%d.%m.%y %H:%i:%s")), '</td><td>'
, c.frequency, '</td><td>'
......
......@@ -234,7 +234,7 @@ Form 'passwordReset'::
"showButton": "save",
"multiMode": "none",
"forwardMode": "url-sip-skip-history",
"forwardPage": "?id={{pageAlias:T}}&action=confirmation",
"forwardPage": "{{pageSlug:T}}?action=confirmation",
"labelAlign": "default",
"parameter": "submitButtonText = Send password reset email",
"deleted": "no",
......@@ -346,7 +346,7 @@ Form 'passwordSet'::
"showButton": "save",
"multiMode": "none",
"forwardMode": "url-sip-skip-history",
"forwardPage": "?{{pageAlias:T}}&action=thanks",
"forwardPage": "{{pageSlug:T}}?action=thanks",
"parameter": "submitButtonText='Set password'",
"FormElement_ff": [
{
......@@ -372,4 +372,4 @@ Form 'passwordSet'::
"parameter": "slaveId={{SELECT fe.uid FROM {{dbNameT3:Y}}.fe_users AS fe WHERE fe.username='{{email:RE}}' AND fe.username!='' AND fe.deleted=0 LIMIT 1}}\r\n\r\n# Create FE User. Please update values of `pid`, `usergroup` to your setup.\r\nsqlInsert = {{INSERT INTO {{dbNameT3:Y}}.fe_users ( `pid`, `usergroup`, `username`, `email`, `name`, `password`,`crdate`) VALUES ( 5 , 1 , '{{email:RE}}', '{{email:RE}}', '{{lastName:RE}}, {{firstName:RE}}', '{{myValue:FE:all:p}}', UNIX_TIMESTAMP() ) }}\r\n\r\nsqlUpdate = {{UPDATE {{dbNameT3:Y}}.fe_users SET password='{{myValue:FE:all:p}}' WHERE uid={{slaveId:V0}} }}\r\n\r\nsqlAfter={{UPDATE Person SET authExpire=0 WHERE id={{id:R}} }}"
}
]
}
\ No newline at end of file
}
......@@ -669,13 +669,14 @@ class DatabaseUpdate {
. 'Usages of page alias found. The Typo3 feature "page alias" has been replaced by the "page slug" feature and can no longer be used in links with "?id=[alias]".'
. '<h2>SOLUTION</h2>'
. "<ul>"
. '<li>The special column _link now treats the "p:" parameter value as a page slug.</li>'
. '<li>Use {{pageSlug:T}} instead of {{pageAlias:T}} or {{pageId:T}} in the _link columns.</li>'
. '<li>Use {{baseUrlLang:Y}}/{{pageSlug:T}} instead of {{pageAlias:T}} or {{pageId:T}} in hardcoded ' . htmlentities("<a>") . ' tags.</li>'
. '<li>Replace hardcoded aliases in QFQ code with the slugs of the pages.</li>'
. '<li>Replace "U: ... &id=[alias]& ... " with "p:[slug]? ... " for all sepecial columns except _paged.</li>'
. '<li>The special colums such as "_link" now treat the "p:" parameter value as a page slug.</li>'
. '<li>Use {{pageSlug:T}} instead of {{pageAlias:T}} or {{pageId:T}} in the _link columns. E.g. "p:{{pageSlug}}?foo=bar" AS link .</li>'
. '<li>Use {{baseUrlLang:Y}}/{{pageSlug:T}} instead of {{pageAlias:T}} or {{pageId:T}} in hardcoded ' . htmlentities("<a>") . ' tags. E.g. href="{{baseUrlLang:Y}}/{{pageSlug:T}}?foo=bar".</li>'
. '<li>Replace hardcoded aliases in QFQ code with the slugs of the pages. E.g. "p:/some/page?foo=bar" AS _link.</li>'
. '<li>Replace "U: ... &id=[alias]& ... " with "p:[slug]? ... " for all sepecial columns except _paged. I.e. "U: ... &id=[alias]& ... " becomes "p:[slug]? ... ". </li>'
. '<li>Hint: Typo3 replaces "_" with "-" when converting an alias to a slug during the Typo3 version 9 upgrade.</li>'
. '<li>Hint: A page slug always starts with a slash "/" and QFQ expects the slash to be there.</li>'
. '<li>Note: After the page slug comes a "?" not a "&". E.g. "p:/some/page?foo=bar" AS _link. </li>'
. "</ul>"
. '<h2>AUTO SUGGESTIONS</h2>'
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment