[Qgis-developer] [Qgis-user] QGIS - value relation widget

Luca Lanteri mescal72 at gmail.com
Fri Oct 2 00:09:22 PDT 2015


Sadly, after further test I discover that the crashes remain, so I think it
is a qgis bug and not a problem in my code.
The problem happens when I put my custom form into a subform widget
(QgsRelationEditorWidget). If I add a new record in the subform and I move
to another record using the left column QGIS crashes. It seems to be a more
general problem because the crash appears also when I add some simple
control that modify the object in the form.

I can open a ticket and add some test data.
If it is a minor bug and it could be resolved easily I really offer a pizza
and a beer to resolve it.

All the best
Luca


2015-10-01 23:53 GMT+02:00 Luca Lanteri <mescal72 at gmail.com>:

> Hi,
>
> now I'm already using the python logic but my code is terrible and I have
> a lot of crash problem.
> Now that I using your example all is easier and seem to worsk fine.
>
> I owe you one beer.
> Many many tanks !
>
> Luca
>
>
> 2015-10-01 22:23 GMT+02:00 Blumentrath, Stefan <Stefan.Blumentrath at nina.no
> >:
>
>> Hi Luca,
>>
>>
>>
>> Sounds like a case for Python logic!
>>
>> General principles are explained here:
>>
>>
>> http://nathanw.net/2011/09/05/qgis-tips-custom-feature-forms-with-python-logic/
>>
>>
>>
>> Also nice, and probably exactly what you are looking for:
>>
>> http://medspx.fr/blog/Qgis/cascade_forms/
>>
>>
>>
>> Cheers
>>
>> Stefan
>>
>>
>>
>> *From:* qgis-user-bounces at lists.osgeo.org [mailto:
>> qgis-user-bounces at lists.osgeo.org] *On Behalf Of *Luca Lanteri
>> *Sent:* 1. oktober 2015 22:07
>> *To:* qgis-user <Qgis-user at lists.osgeo.org>
>> *Subject:* [Qgis-user] QGIS - value relation widget
>>
>>
>>
>> Hi to all,
>>
>> I need to build a form when the value of a combo are filtered basing on
>> the value of anoter combobox.
>> I have a first combo where I choose the region and a second with the
>> municipalities.
>> I need that the second combo shows only the municipalities of the choosed
>> region.
>> I tried to use use the widget "relationship value" with the a filter like
>> classe_munic = attribute($currentfeature, 'classe_munic') without any
>> success.
>>
>> Has anyone ever done something similar?
>> Thank in advance
>>
>>
>> Luca
>>
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/qgis-developer/attachments/20151002/d62a5795/attachment.html>


More information about the Qgis-developer mailing list