[Qgis-user] Custom form checkbox widget

Bernhard Ströbl bernhard.stroebl at jena.de
Wed Jan 13 06:10:34 PST 2016


Hi Ross,

if you are using PostgreSQL as data store, you might want to give my 
plugin DataDrivenInputMask [1] a try. This should make custom forms 
unnecessary.

Bernhard

[1] http://plugins.qgis.org/plugins/DataDrivenInputMask/

Am 13.01.2016 um 15:01 schrieb McDonaldR:
> Hi List
>
> I have a table in PostGIS with a Boolean field which allows for
> TRUE/FALSE, t/f, true/false, y/n, yes/no, on/off, 1/0 values.
>
> I have a custom form in QGIS for that table and the edit widget for that
> field is set to checkbox.  In the checkbox widget settings there are two
> options for
>
> ·Representation for checked state:
>
> ·Representation for unchecked state:
>
> The custom form only shows the correct value in the pop-up form if the
> values above are set to ‘t’ and ‘f’ respectively.  If I set them to any
> of the other options the checkbox in the form is always blank even
> though the value in the field in the table is populated with TRUE or FALSE.
>
> So, the question is whether this is a Qt or QGIS enforced behaviour?
>
> If it is, and the only options for checked/unchecked state are t/f, then
> shouldn’t they be set by default?
>
> I am using QGIS 2.12.2 on Win 7 32bit with PostgresSQL 9.2.14 and
> PostGIS 2.1.8.
>
> Thanks in advance
>
> Ross
>
> *Ross McDonald *|**GIS Data Coordinator | Resources Department, IT
> Division | Angus Council, Angus House, Orchardbank Business Park,
> Forfar, DD8 1AT
>
> T: *01307 476419* | F: 01307 476401 | E: mcdonaldr at angus.gov.uk
> <mailto:mcdonaldr at angus.gov.uk> **
>
> This message is strictly confidential. If you have received this in
> error, please inform the sender and remove it from your system. If
> received in error you may not copy, print, forward or use it or any
> attachment in any way. This message is not capable of creating a legal
> contract or a binding representation and does not represent the views of
> Angus Council. Emails may be monitored for security and network
> management reasons.Messages containing inappropriate content may be
> intercepted. Angus Council does not accept any liability for any harm
> that may be caused to the recipient system or data on it by this message
> or any attachment.
>
>
>
> __________ Information from ESET Mail Security, version of virus
> signature database 12862 (20160113) __________
>
> The message was checked by ESET Mail Security.
> http://www.eset.com
>
>
> _______________________________________________
> Qgis-user mailing list
> Qgis-user at lists.osgeo.org
> List info: http://lists.osgeo.org/mailman/listinfo/qgis-user
> Unsubscribe: http://lists.osgeo.org/mailman/listinfo/qgis-user
>



__________ Information from ESET Mail Security, version of virus signature database 12862 (20160113) __________

The message was checked by ESET Mail Security.
http://www.eset.com





More information about the Qgis-user mailing list