Permalink
Browse files

FIX: Ticket #7592 GridFieldDataColumns: Wrong documentation for getFi…

…eldCasting Moved documentation to the appropriate function, added note about the two parameter callback function.
  • Loading branch information...
1 parent 8548014 commit 20696958df3adf0843d405873684275d548b39c4 @jakr jakr committed with chillu Jul 4, 2012
Showing with 6 additions and 5 deletions.
  1. +6 −5 forms/gridfield/GridFieldDataColumns.php
@@ -83,18 +83,19 @@ public function setFieldCasting($casting) {
}
/**
- * Specify custom formatting for fields, e.g. to render a link instead of pure text.
- * Caution: Make sure to escape special php-characters like in a normal php-statement.
- * Example: "myFieldName" => '<a href=\"custom-admin/$ID\">$ID</a>'.
- * Alternatively, pass a anonymous function, which takes one parameter: The list item.
- *
* @return array
*/
public function getFieldCasting() {
return $this->fieldCasting;
}
/**
+ * Specify custom formatting for fields, e.g. to render a link instead of pure text.
+ * Caution: Make sure to escape special php-characters like in a normal php-statement.
+ * Example: "myFieldName" => '<a href=\"custom-admin/$ID\">$ID</a>'.
+ * Alternatively, pass a anonymous function, which takes two parameters:
+ * The value returned by Convert::raw2xml and the original list item.
+ *
* @param array $formatting
*/
public function setFieldFormatting($formatting) {

0 comments on commit 2069695

Please sign in to comment.