mirror of
https://github.com/qgis/QGIS.git
synced 2025-04-02 00:04:53 -04:00
fix projections selection when CRSes from multiple authorities are preselected
git-svn-id: http://svn.osgeo.org/qgis/trunk@13134 c8812cc2-4d05-0410-92ff-de0c093fc19c
This commit is contained in:
parent
81fa1e2f5c
commit
1d056de0e5
@ -251,10 +251,18 @@ QString QgsProjectionSelector::ogcWmsCrsFilterAsSqlExpression( QSet<QString> * c
|
||||
if ( authParts.isEmpty() )
|
||||
return sqlExpression;
|
||||
|
||||
foreach( QString auth_name, authParts.keys() )
|
||||
if( authParts.size() > 0 )
|
||||
{
|
||||
sqlExpression += QString( " AND (auth_name='%1' AND auth_id IN ('%2'))" )
|
||||
.arg( auth_name ).arg( authParts[auth_name].join( "','" ) );
|
||||
QString prefix = " AND (";
|
||||
foreach( QString auth_name, authParts.keys() )
|
||||
{
|
||||
sqlExpression += QString( "%1(auth_name='%2' AND auth_id IN ('%3'))" )
|
||||
.arg( prefix )
|
||||
.arg( auth_name )
|
||||
.arg( authParts[auth_name].join( "','" ) );
|
||||
prefix = " OR ";
|
||||
}
|
||||
sqlExpression += ")";
|
||||
}
|
||||
|
||||
QgsDebugMsg( "exiting with '" + sqlExpression + "'." );
|
||||
|
Loading…
x
Reference in New Issue
Block a user