MINOR Class documentation for GridFieldDeleteAction

This commit is contained in:
Sean Harvey 2012-03-23 10:50:17 +13:00
parent 4da42f2baf
commit ff4c82039d

View File

@ -1,11 +1,20 @@
<?php
/**
* This class is an GridField Component that add Delete action for Objects in the GridField.
* See {@link GridFieldRemoveButton} for detaching an item from the current relationship instead.
* This class is an GridField component that adds a delete action for objects in a {@link GridField}.
*
* This will also supports unlinking a relation instead of deleting the object. Use the {@link $removeRelation}
* property set in the constructor.
*
* <code>
* $action = new GridFieldDeleteAction(); // delete objects permanently
* $action = new GridFieldDeleteAction(true); // removes the relation to object, instead of deleting
* </code>
*
* @package sapphire
* @subpackage gridfield
*/
class GridFieldDeleteAction implements GridField_ColumnProvider, GridField_ActionProvider {
/**
* If this is set to true, this actionprovider will remove the object from the list, instead of
* deleting. In the case of a has one, has many or many many list it will uncouple the item from
@ -125,4 +134,4 @@ class GridFieldDeleteAction implements GridField_ColumnProvider, GridField_Actio
$gridField->getList()->remove($item);
}
}
}
}