/** * Upload Picture * @param UploadedFile $file * @param type $public_id * @return type */ public function uploadPic(UploadedFile $file, $public_id) { return $this->cloudinaryManager->upload($file, $public_id); }
public function buildView(FormView $view, FormInterface $form, array $options) { $view->vars['picture_url'] = $this->cloudinaryManager->getCloudinaryUrl(json_decode($form->getData()->pictureInformation, true), 'c_scale,w_550'); }