/** * @param \watoki\reflect\Property $property * @return \watoki\qrator\form\Field */ public function getField(Property $property) { if (isset($this->fields[$property->name()])) { return $this->fields[$property->name()]; } return parent::getField($property); }
protected function assembleValueWithActions($entity, Property $property, $value) { if (is_object($value)) { $entityRepresenter = $this->registry->getEntityRepresenter($entity); $propertyRepresenter = $this->registry->getEntityRepresenter($value); return ['caption' => $propertyRepresenter->render($value), 'actions' => array_merge($this->assembleActions($propertyRepresenter->getActions($value)), $this->assembleActions($entityRepresenter->getPropertyActions($entity, $property->name(), $value)))]; } return ['caption' => $this->toString($value), 'actions' => null]; }
private function makePropertyParameter(Parameter $parameter, Property $property) { return new Parameter($parameter->getName() . '[' . $property->name() . ']', $property->type(), $property->isRequired()); }
/** * @param \watoki\reflect\Property $property * @return \watoki\qrator\form\Field */ protected function getField(Property $property) { return $this->getFieldForType($property->name(), $property->type()); }