N°931 Fix import TagSet failing with multiple code values (using CLI with no_localize=1)

This commit is contained in:
Pierre Goiffon
2018-10-05 09:18:23 +02:00
parent 33e8b6a64c
commit 8720ac2b08

View File

@@ -9626,7 +9626,7 @@ class AttributeTagSet extends AttributeSet
{
$sSepItem = MetaModel::GetConfig()->Get('tag_set_item_separator');
}
if ($bLocalizedValue && !empty($sProposedValue))
if (!empty($sProposedValue))
{
$oTagSet = new ormTagSet(MetaModel::GetAttributeOrigin($this->GetHostClass(), $this->GetCode()),
$this->GetCode(), $this->GetMaxItems());
@@ -9636,7 +9636,7 @@ class AttributeTagSet extends AttributeSet
{
if (!empty($sTagLabel))
{
$aCodes[] = $oTagSet->GetTagFromLabel($sTagLabel);
$aCodes[] = ($bLocalizedValue) ? $oTagSet->GetTagFromLabel($sTagLabel) : $sTagLabel;
}
}
$sProposedValue = implode(' ', $aCodes);