Skip to content

Commit

Permalink
Upload Video
Browse files Browse the repository at this point in the history
  • Loading branch information
orgimeno committed Nov 22, 2020
1 parent 3773d2e commit c245055
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 5 deletions.
2 changes: 1 addition & 1 deletion src/AppBundle/Controller/UserController.php
Original file line number Diff line number Diff line change
Expand Up @@ -151,7 +151,7 @@ public function editAction(Request $request){
&& $name != null
&& $surname != null){

$user->setCreateAt($createAt);
$user->setCreatedAt($createAt);
$user->setRole($role);
$user->setEmail($email);
$user->setName($name);
Expand Down
11 changes: 7 additions & 4 deletions src/AppBundle/Controller/VideoController.php
Original file line number Diff line number Diff line change
Expand Up @@ -171,16 +171,18 @@ public function editAction(Request $request, $id = null){
return $helpers->json($data);
}

/*
*
/**
* @param Request $request
* @param null $id
* @return mixed
*/
public function uploadAction(Request $request, $id = null){

$helpers = $this->get('app.helpers');
$hash = $request->get('authorization', null);
$authCheck = $helpers->authCheck($hash);

if($authCheck) {
if($authCheck){
$em = $this->getDoctrine()->getManager();
$identity = $helpers->authCheck($hash, true);

Expand All @@ -207,7 +209,8 @@ public function uploadAction(Request $request, $id = null){
$data = [
'status' => "success",
'code' => 200,
'msg' => "Video image uploaded"
'msg' => "Video image uploaded",
'file_name' => $file_name
];
}else{

Expand Down

0 comments on commit c245055

Please sign in to comment.