Merge pull request #1890 from marcoAntonioNina/BUG-12335

BUG-12335 Currency field in Report table with grid not storing... SOLVED
This commit is contained in:
julceslauhub
2013-07-12 13:14:41 -07:00

View File

@@ -810,16 +810,16 @@ class AdditionalTables extends BaseAdditionalTables
foreach ($gridData as $i => $gridRow) { foreach ($gridData as $i => $gridRow) {
eval('$obj = new ' . $className . '();'); eval('$obj = new ' . $className . '();');
//Parsing values //Parsing values
foreach ($gridRow as $i => $v) { foreach ($gridRow as $j => $v) {
foreach ($fieldTypes as $key => $fieldType) { foreach ($fieldTypes as $key => $fieldType) {
foreach ($fieldType as $name => $type) { foreach ($fieldType as $name => $type) {
if ( strtoupper ( $i) == $name) { if ( strtoupper ( $j) == $name) {
$v = validateType ($v, $type); $v = validateType ($v, $type);
unset($name); unset($name);
} }
} }
} }
$gridRow[$i] = $v === '' ? null : $v; $gridRow[$j] = $v === '' ? null : $v;
} }
$obj->fromArray(array_change_key_case($gridRow, CASE_UPPER), BasePeer::TYPE_FIELDNAME); $obj->fromArray(array_change_key_case($gridRow, CASE_UPPER), BasePeer::TYPE_FIELDNAME);
$obj->setAppUid($appUid); $obj->setAppUid($appUid);