mirror of
https://github.com/qgis/QGIS.git
synced 2025-03-02 00:02:12 -05:00
fix #6253
This commit is contained in:
parent
206e488420
commit
078f5b846c
@ -600,15 +600,16 @@ bool QgsAttributeEditor::retrieveValue( QWidget *widget, QgsVectorLayer *vl, int
|
||||
if ( editType == QgsVectorLayer::ValueRelation )
|
||||
{
|
||||
text = '{';
|
||||
for ( int i = 0; i < lw->count(); i++ )
|
||||
for ( int i = 0, n = 0; i < lw->count(); i++ )
|
||||
{
|
||||
if ( lw->item( i )->checkState() == Qt::Checked )
|
||||
{
|
||||
if ( i > 0 )
|
||||
if ( n > 0 )
|
||||
{
|
||||
text.append( ',' );
|
||||
}
|
||||
text.append( lw->item( i )->data( Qt::UserRole ).toString() );
|
||||
n++;
|
||||
}
|
||||
}
|
||||
text.append( '}' );
|
||||
|
Loading…
x
Reference in New Issue
Block a user