Skip to content

Commit

Permalink
Merge pull request #37298 from alexbruy/split-vector
Browse files Browse the repository at this point in the history
use attribute value in the output file name for Split vector layer algorithm (fix #37296)
  • Loading branch information
alexbruy committed Aug 3, 2020
2 parents 8ed274b + f465efe commit c1e9142
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/analysis/processing/qgsalgorithmsplitvectorlayer.cpp
Expand Up @@ -119,7 +119,7 @@ QVariantMap QgsSplitVectorLayerAlgorithm::processAlgorithm( const QVariantMap &p
if ( feedback->isCanceled() )
break;

QString fileName = QStringLiteral( "%1_%2.%3" ).arg( baseName ).arg( current ).arg( outputFormat );
QString fileName = QStringLiteral( "%1_%2.%3" ).arg( baseName ).arg( ( *it ).toString() ).arg( outputFormat );
feedback->pushInfo( QObject::tr( "Creating layer: %1" ).arg( fileName ) );

sink.reset( QgsProcessingUtils::createFeatureSink( fileName, context, fields, geometryType, crs ) );
Expand Down

0 comments on commit c1e9142

Please sign in to comment.