Bug report #18521

Conditional formatting rules do not apply to relation reference widget comboboxes, when using a sort expression

Added by Andreas Neumann about 6 years ago. Updated about 6 years ago.

Status:Closed
Priority:Normal
Assignee:David Signer
Category:Edit widget
Affected QGIS version:3.1(master) Regression?:No
Operating System: Easy fix?:No
Pull Request or Patch supplied:No Resolution:
Crashes QGIS or corrupts data:No Copied to github as #:26409

Description

When using row level conditional format rules on a table that is also referenced in a relation reference widget, the same formatting applies in the combobox of the relation reference widget.

This works fine, unless one uses a custom expression for sorting the values. As soon as the sort expression is applied, the format rule is not applied anymore.

See attached screenshots. First two screenshots show the format rule. Screenshot 3 (a and b) shows that the format rule works if only a sort column is used, screenshot 4 (a and b) shows that the format rule fails when a sort expression is used.

If fixed, it should also be backported to version 3.0x

Thanks for having a look at this issue!

Screenshot1_qgis-relref-widget-format-rule-issue.png (95.2 KB) Andreas Neumann, 2018-03-23 09:17 AM

Screenshot2_qgis-relref-widget-format-rule-issue.png (102 KB) Andreas Neumann, 2018-03-23 09:32 AM

Screenshot3a_qgis-relref-widget-format-rule-issue.png (172 KB) Andreas Neumann, 2018-03-23 09:33 AM

Screenshot3b_qgis-relref-widget-format-rule-issue.png (34.7 KB) Andreas Neumann, 2018-03-23 09:33 AM

Screenshot4a_qgis-relref-widget-format-rule-issue.png (183 KB) Andreas Neumann, 2018-03-23 09:34 AM

Screenshot4b_qgis-relref-widget-format-rule-issue.png (77.7 KB) Andreas Neumann, 2018-03-23 09:34 AM

Associated revisions

Revision 4d984793
Added by David Signer about 6 years ago

Conditional formatting on relation reference widget

in case we have additional display expressions there does use the conditional formatting for the row
and in case there is only one fieldname used in the display expression it does use this as well

Fix: #18521

Revision 55e83809
Added by David Signer about 6 years ago

Conditional formatting on relation reference widget

in case we have additional display expressions there does use the conditional formatting for the row
and in case there is only one fieldname used in the display expression it does use this as well

Fix: #18521

History

#1 Updated by David Signer about 6 years ago

  • Assignee set to David Signer

#2 Updated by David Signer about 6 years ago

Am I right with the suppose that the order (sort) has no influence. It's only in case you have a Display Expression there not only containing one field. Correct?

#3 Updated by David Signer about 6 years ago

  • % Done changed from 0 to 100
  • Status changed from Open to Closed

Also available in: Atom PDF