mirror of
https://github.com/retailcrm/NelmioApiDocBundle.git
synced 2025-02-02 15:51:48 +03:00
Display form type childs description and title properly
This commit is contained in:
parent
bf77277f2f
commit
7858afec09
@ -124,7 +124,14 @@ final class FormModelDescriber implements ModelDescriberInterface, ModelRegistry
|
||||
null,
|
||||
$config->getOptions()
|
||||
);
|
||||
$property->ref = $this->modelRegistry->register($model);
|
||||
|
||||
$ref = $this->modelRegistry->register($model);
|
||||
// We need to use allOf for description and title to be displayed
|
||||
if ($config->hasOption('documentation') && !empty($config->getOption('documentation'))) {
|
||||
$property->allOf = [new OA\Schema(['ref' => $ref])];
|
||||
} else {
|
||||
$property->ref = $ref;
|
||||
}
|
||||
|
||||
return;
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user