* @return string
*/
- public function render(?callable $callback )
+ public function render(?callable $callback=null)
{
return view(CubistBackpackServiceProvider::NAMESPACE . '::form.form', ['form' => $this, 'crud' => $this->crud])->render($callback);
}
return $field;
}
- public function getTranslations(?string $key, ?array $allowedLocales): array
+ public function getTranslations(?string $key = null, ?array $allowedLocales = null): array
{
if ($key !== null) {
// $measure_label = 'Get translation in ' . get_class($this);
public function getCasts(): array
{
$casts = [];
- $p= parent::getCasts();
+ $p = parent::getCasts();
foreach ($this->getFields() as $field) {
$name = $field->getAttribute('name');
if ($field->getAttribute('translatable') && $field->getAttribute('fake') && $p[$name] === 'array') {