Class: QgsRelationReferenceFieldFormatter

class qgis.core.QgsRelationReferenceFieldFormatter

Bases: QgsFieldFormatter

Default constructor of field formatter for a relation reference field.

QgsRelationReferenceFieldFormatter(QgsRelationReferenceFieldFormatter)

Field formatter for a relation reference field. A value relation field formatter looks up the values from features on another layer.

Methods

id

rtype

str

representValue

param layer

sortValue

param layer

id(self) → str
Return type

str

representValue(self, layer: QgsVectorLayer, fieldIndex: int, config: Dict[str, Any], cache: Any, value: Any) → str
Parameters
  • layer (QgsVectorLayer) –

  • fieldIndex (int) –

  • config (Dict[str) –

  • cache (Any) –

  • value (Any) –

Return type

str

sortValue(self, layer: QgsVectorLayer, fieldIndex: int, config: Dict[str, Any], cache: Any, value: Any) → Any
Parameters
  • layer (QgsVectorLayer) –

  • fieldIndex (int) –

  • config (Dict[str) –

  • cache (Any) –

  • value (Any) –

Return type

Any