You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
there is a hint at the support of expressions for Default values in forms:
"For editing, it’s possible to use expressions for constraints, default value, group visibility".
but in the advanced forms documentation there are no examples for default values
just visibility by expression, constraints and filters for value relations, that as a fact all seems to work, but defaults does not.
So I'm left guessing if expressions for defaults are really supported or not.
Versions
QGIS Server and Desktop 3.28, LMWC latest 3.6
Check Lizmap plugin
I have done the step just before in the Lizmap QGIS desktop plugin before opening this ticket. Otherwise, my ticket is not considered valid and might get closed.
QGIS server version, only if the section above doesn't mention the QGIS Server version
3.28
Operating system
Ubuntu 22.04, desktop and server
Browsers
Firefox, Chrome
Browsers version
Latest
Relevant log output
No response
The text was updated successfully, but these errors were encountered:
@Gustry yes sorry for that, but many questions on the list go unanswered (see my previous one about how to extend ckeditor in the landing page) that one person can get frustrated and tries to use as many channels possible to try get feedback.
Please answer as well what was your context (new feature or existing feature), your expression, geometry needed etc.
My use case, the one that triggered the question is:
draw a point > fill the table with X and Y values
fill a field with a numeric values and have another field be automatically filled with a (text) class that depends on that number.
As asked in the list I would like to understand if achieving full support for defaults based on expression is "just" hard to implement or impossible for some reason. Thanks!
I mainly put the link to the mailing list for users finding this ticket to have more info (or search engines).
It was less than 24 hours on the ML ;-)
draw a point > fill the table with X and Y values
For some use cases, such as this one, it's possible to use use PG triggers (yes it's more complicated to set up, but it's a workaround which is working very well)
What is the question?
In this doc page:
https://docs.lizmap.com/current/en/publish/configuration/expression.html
there is a hint at the support of expressions for Default values in forms:
"For editing, it’s possible to use expressions for constraints, default value, group visibility".
but in the advanced forms documentation there are no examples for default values
https://docs.lizmap.com/current/en/publish/configuration/layer.html#advanced-form
just visibility by expression, constraints and filters for value relations, that as a fact all seems to work, but defaults does not.
So I'm left guessing if expressions for defaults are really supported or not.
Versions
QGIS Server and Desktop 3.28, LMWC latest 3.6
Check Lizmap plugin
QGIS server version, only if the section above doesn't mention the QGIS Server version
3.28
Operating system
Ubuntu 22.04, desktop and server
Browsers
Firefox, Chrome
Browsers version
Latest
Relevant log output
No response
The text was updated successfully, but these errors were encountered: