mirror of
https://github.com/alchemy-fr/Phraseanet.git
synced 2025-10-25 02:43:11 +00:00
Rename methods for more consistency
This commit is contained in:
@@ -69,7 +69,7 @@ class StoryTransformer extends TransformerAbstract
|
|||||||
|
|
||||||
public function includeMetadatas(StoryView $storyView)
|
public function includeMetadatas(StoryView $storyView)
|
||||||
{
|
{
|
||||||
return $this->item($storyView->getCaption(), $this->getCaptionTransformer());
|
return $this->item($storyView->getCaption(), $this->getCaptionDCFieldTransformer());
|
||||||
}
|
}
|
||||||
|
|
||||||
public function includeRecords(StoryView $storyView)
|
public function includeRecords(StoryView $storyView)
|
||||||
@@ -79,10 +79,13 @@ class StoryTransformer extends TransformerAbstract
|
|||||||
|
|
||||||
public function includeCaption(StoryView $storyView)
|
public function includeCaption(StoryView $storyView)
|
||||||
{
|
{
|
||||||
return $this->collection($storyView->getCaption()->getFields(), $this->getCaptionRecordTransformer());
|
return $this->collection($storyView->getCaption()->getFields(), $this->getCaptionFieldTransformer());
|
||||||
}
|
}
|
||||||
|
|
||||||
private function getCaptionRecordTransformer()
|
/**
|
||||||
|
* @return \Closure
|
||||||
|
*/
|
||||||
|
private function getCaptionFieldTransformer()
|
||||||
{
|
{
|
||||||
return function (\caption_field $captionField) {
|
return function (\caption_field $captionField) {
|
||||||
return [
|
return [
|
||||||
@@ -96,7 +99,7 @@ class StoryTransformer extends TransformerAbstract
|
|||||||
/**
|
/**
|
||||||
* @return \Closure
|
* @return \Closure
|
||||||
*/
|
*/
|
||||||
private function getCaptionTransformer()
|
private function getCaptionDCFieldTransformer()
|
||||||
{
|
{
|
||||||
/**
|
/**
|
||||||
* @param \caption_field[] $fields
|
* @param \caption_field[] $fields
|
||||||
|
|||||||
Reference in New Issue
Block a user