Permalink
Browse files

BackwardsCompatibilityBreak - Changed the separator between the table…

… name and column name for related form inputs from . back to :: because PHP converts . to _ - this reverts changes in r264.
  • Loading branch information...
wbond committed Oct 9, 2008
1 parent e36e968 commit fc757f032822d45a3b3d27d8443648c725540851
Showing with 5 additions and 5 deletions.
  1. +5 −5 classes/fORMRelated.php
View
@@ -225,14 +225,14 @@ static public function determineRequestFilter($class, $related_class, $route)
$filter_table = $related_table;
$filter_table_with_route = $related_table . '{' . $route_name . '}';
$pk_field = $filter_table . '.' . $first_pk_column;
$pk_field_with_route = $filter_table_with_route . '.' . $first_pk_column;
$pk_field = $filter_table . '::' . $first_pk_column;
$pk_field_with_route = $filter_table_with_route . '::' . $first_pk_column;
if (!fRequest::check($pk_field) && fRequest::check($pk_field_with_route)) {
$filter_table = $filter_table_with_route;
}
return $filter_table . '.';
return $filter_table . '::';
}
@@ -309,7 +309,7 @@ static public function linkRecords($class, &$related_records, $related_class, $r
$relationship = fORMSchema::getRoute($table, $related_table, $route, 'many-to-many');
$field_table = $relationship['related_table'];
$field_column = '.' . $relationship['related_column'];
$field_column = '::' . $relationship['related_column'];
$field = $field_table . $field_column;
$field_with_route = $field_table . '{' . $route_name . '}' . $field_column;
@@ -322,7 +322,7 @@ static public function linkRecords($class, &$related_records, $related_class, $r
$record_set = fRecordSet::build(
$related_class,
array(
$field_with_route . '=' => fRequest::get($field, 'array', array())
str_replace('::', '.', $field_with_route) . '=' => fRequest::get($field, 'array', array())
)
);

0 comments on commit fc757f0

Please sign in to comment.