SF Bug #3427748 - value id is ignored in select attribute

This commit is contained in:
Deon George 2012-09-05 20:02:14 +10:00
parent c4b6695beb
commit caf24e3662
2 changed files with 3 additions and 3 deletions

View File

@ -778,7 +778,7 @@ class Attribute {
case 'value':
if (is_array($value))
foreach ($value as $y) {
foreach ($value as $x => $y) {
if (! $this->haveMoreValues()) {
system_message(array(
'title'=>_('Automatically removed attribute values from template'),
@ -790,7 +790,7 @@ class Attribute {
break;
} else
$this->addValue($y);
$this->addValue($x,$y);
}
else

View File

@ -41,7 +41,7 @@ class SelectionAttribute extends Attribute {
if (DEBUG_ENABLED && (($fargs=func_get_args())||$fargs='NOARGS'))
debug_log('Entered (%%)',5,0,__FILE__,__LINE__,__METHOD__,$fargs);
$this->addOption($new_val,$new_val);
$this->addOption($new_val,$i);
}
public function getOptionCount() {