Value relation rework & more small updates - #4525
Conversation
…completer and null values
📦 Build Artifacts Ready
|
📦 Build Artifacts Ready
|
| /** | ||
| * Parses a QGIS value-relation wire value into a list of key strings. | ||
| * allowMulti=true → "{1,2,3}" becomes ["1","2","3"] | ||
| * allowMulti=false → "1" becomes ["1"] | ||
| * An empty or null input always returns an empty list. | ||
| */ | ||
| Q_INVOKABLE QStringList qgisFormatToArray( const QVariant &qgsValue ) const; | ||
|
|
||
| /** | ||
| * Formats a list of key strings into the QGIS wire value "{k1,k2,...}". | ||
| * allowMulti=true → "["1","2","3"]" becomes ["1","2","3"] | ||
| * allowMulti=true → "["1"]" becomes "1" | ||
| * allowMulti=false → "1" becomes "1" | ||
| * An empty list produces "". | ||
| */ | ||
| Q_INVOKABLE QString arrayToQgisFormat( const QStringList &keys ) const; |
There was a problem hiding this comment.
I still think these should be just static utility functions, not tied to the class
Coverage Report for CI Build 27942757134Warning No base build found for commit Coverage: 57.601%Details
Uncovered ChangesNo uncovered changes found. Coverage RegressionsRequires a base build to compare against. How to fix this → Coverage Stats
💛 - Coveralls |
📦 Build Artifacts Ready
|
Testing progress updateThe following tickets have been tested so far and the results with comments are summarized below.
Open issue:🟠 1. NULL entry not visible in the value map drop-down in MM App — the option added via Add NULL value in QGIS Desktop simply doesn't appear as a selectable choice in the mobile app - Is it correct behavior of application? 🔴 3. Clear button doesn't match the Figma design Screenshot:
|
Testing progress update
Screen_Recording_20260622_105537.mp4 |

Introduces a new way of handling value relation editors. Improves performance and stability.
Changes:
ValueRelationControllerthat performs lookups fromkeytovalue, handles hot reload (filter expression) and conversions from/to QGIS format, e. g."{1,2,3}"to[1,2,3]Todos:
distance(@geometry, @current_geometry) <= 0.000135Other updates:
MMDrawerHeaderandMMListMultiselectDrawermultiselect drawer to make their API easier to useResolves #4255
Resolves #4497
Resolves #4443
Resolves #3297
Resolves #3737
Resolves #4508
Resolves #4505
Resolves #2148 (<- the only limitation is VR fields with filter expression)
Resolves (? needs to be tested) #4504