createBase($orderShop); $orderPayment->setMeanPayment($meanPayment); $orderPayment->setAmount($amount); $orderPayment->setPaidAt(new \DateTime()); $orderPayment->setEditable($editable); return $orderPayment; } public function createBase($orderShop){ $class = OrderPaymentContainer::getEntityFqcn(); $orderPayment = new $class; $orderPayment->setOrderShop($orderShop); return $orderPayment; } }