mirror of
https://github.com/silverstripe/silverstripe-framework
synced 2024-10-22 14:05:37 +02:00
14 lines
387 B
PHP
14 lines
387 B
PHP
|
<?php
|
||
|
|
||
|
/**
|
||
|
* Extends {@see GridFieldDetailForm}
|
||
|
*/
|
||
|
class VersionedGridFieldDetailForm extends Extension {
|
||
|
public function updateItemRequestClass(&$class, $gridField, $record, $requestHandler) {
|
||
|
// Conditionally use a versioned item handler
|
||
|
if($record && $record->has_extension('Versioned')) {
|
||
|
$class = 'VersionedGridFieldItemRequest';
|
||
|
}
|
||
|
}
|
||
|
}
|