Permalink
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Browse files
Revert "[BUGFIX][QGIS Server] Joins was not reloaded if the layer is …
…in cache"
This reverts commit e0c281e.
- Loading branch information
Showing
with
2 additions
and
8 deletions.
-
+2
−8
src/server/qgsserverprojectparser.cpp
|
@@ -28,9 +28,6 @@ |
|
|
#include "qgseditorwidgetregistry.h" |
|
|
#include "qgslayertreegroup.h" |
|
|
|
|
|
#include "qgslogger.h" |
|
|
#include "qgsmessagelog.h" |
|
|
|
|
|
#include <QDomDocument> |
|
|
#include <QFileInfo> |
|
|
#include <QStringList> |
|
@@ -237,11 +234,8 @@ QgsMapLayer* QgsServerProjectParser::createLayerFromElement( const QDomElement& |
|
|
if ( !QgsMapLayerRegistry::instance()->mapLayer( id ) ) |
|
|
QgsMapLayerRegistry::instance()->addMapLayer( layer, false, false ); |
|
|
if ( layer->type() == QgsMapLayer::VectorLayer ) |
|
|
{ |
|
|
addValueRelationLayersForLayer( dynamic_cast<QgsVectorLayer *>( layer ) ); |
|
|
// Reload joins and expression fields |
|
|
layer->readLayerXML( const_cast<QDomElement&>( elem ) ); |
|
|
} |
|
|
|
|
|
return layer; |
|
|
} |
|
|
|
|
@@ -1541,7 +1535,7 @@ void QgsServerProjectParser::addJoinLayersForElement( const QDomElement& layerEl |
|
|
{ |
|
|
QString id = joinNodeList.at( i ).toElement().attribute( "joinLayerId" ); |
|
|
QgsMapLayer* layer = mapLayerFromLayerId( id ); |
|
|
if ( layer && !QgsMapLayerRegistry::instance()->mapLayer( id )) |
|
|
if ( layer ) |
|
|
{ |
|
|
QgsMapLayerRegistry::instance()->addMapLayer( layer, false, false ); |
|
|
} |
|
|