Navigation Menu

Skip to content

Commit

Permalink
more bugfixing in wfs provider
Browse files Browse the repository at this point in the history
git-svn-id: http://svn.osgeo.org/qgis/trunk@7117 c8812cc2-4d05-0410-92ff-de0c093fc19c
  • Loading branch information
mhugent committed Jul 30, 2007
1 parent 2f3cee8 commit 1cb8bfc
Showing 1 changed file with 12 additions and 1 deletion.
13 changes: 12 additions & 1 deletion src/providers/wfs/qgswfsprovider.cpp
Expand Up @@ -752,14 +752,25 @@ int QgsWFSProvider::getFeaturesFromGML2(const QDomElement& wfsCollectionElement,
//the children are the attributes
currentAttributeChild = layerNameElem.firstChild();
int attr = 0;
bool numeric = false;

while(!currentAttributeChild.isNull())
{
currentAttributeElement = currentAttributeChild.toElement();

if(currentAttributeElement.localName() != "boundedBy")
{
currentAttributeElement.text().toDouble(&numeric);
if((currentAttributeElement.localName()) != geometryAttribute) //a normal attribute
{
f->addAttribute(attr++, QVariant(currentAttributeElement.text()));
if(numeric)
{
f->addAttribute(attr++, QVariant(currentAttributeElement.text().toDouble()));
}
else
{
f->addAttribute(attr++, QVariant(currentAttributeElement.text()));
}
}
else //a geometry attribute
{
Expand Down

0 comments on commit 1cb8bfc

Please sign in to comment.