std::ostringstream sstream;
sstream << aValue;
std::string aParamValue = sstream.str();
- aContext.push_back(*it + "=" + aParamValue);
+ size_t aPos = aParamValue.find(".");
+ std::string aPnt = "";
+ if (aPos == std::string::npos)
+ aPnt = ".";
+ aContext.push_back(*it + "=" + aParamValue + aPnt);
}
// compare the list of parameters to store if changed
AttributeRefListPtr aParams = reflist(ARGUMENTS_ID());
{
QList<QStringList> aItemsList;
ResultParameterPtr aParam;
+ QList<FeaturePtr> aFeatures;
foreach(FeaturePtr aParameter, theFeatures) {
aParam = std::dynamic_pointer_cast<ModelAPI_ResultParameter>(aParameter->firstResult());
const std::set<std::shared_ptr<ModelAPI_Attribute>>& aRefs = aParam->data()->refsToMe();
QList<QStringList> aItems = featuresItems(aList);
aItemsList.append(aItems);
} else {
- QStringList aValNames;
- aValNames << aReferenced->data()->name().c_str();
-
- AttributeDoublePtr aDouble = std::dynamic_pointer_cast<ModelAPI_AttributeDouble>(aAttr);
- if (aDouble.get()) {
- aValNames << aDouble->text().c_str();
- aValNames << QString::number(aDouble->value());
- } else {
- AttributeIntegerPtr aInt = std::dynamic_pointer_cast<ModelAPI_AttributeInteger>(aAttr);
- if (aInt.get()) {
- aValNames << aInt->text().c_str();
- aValNames << QString::number(aInt->value());
+ if (!aFeatures.contains(aReferenced)) {
+ QStringList aValNames;
+ aValNames << aReferenced->data()->name().c_str();
+
+ AttributeDoublePtr aDouble = std::dynamic_pointer_cast<ModelAPI_AttributeDouble>(aAttr);
+ if (aDouble.get()) {
+ aValNames << aDouble->text().c_str();
+ aValNames << QString::number(aDouble->value());
+ } else {
+ AttributeIntegerPtr aInt = std::dynamic_pointer_cast<ModelAPI_AttributeInteger>(aAttr);
+ if (aInt.get()) {
+ aValNames << aInt->text().c_str();
+ aValNames << QString::number(aInt->value());
+ }
}
+ aItemsList.append(aValNames);
+ aFeatures.append(aReferenced);
}
- aItemsList.append(aValNames);
}
}
}