arreglo evidencias
This commit is contained in:
parent
554268cd14
commit
c421168a77
@ -26,7 +26,7 @@ public function create(Request $request)
|
||||
$id_user = auth()->user();
|
||||
if ($id_user->isCreadorPlan($request->id_plan) or $id_user->isAdmin()) {
|
||||
$plan = plan::find($request->id_plan);
|
||||
if ($plan->id_user == $id_user) {
|
||||
if ($plan->id_user == $id_user->id_plan) {
|
||||
$evidencia = new Evidencias();
|
||||
$evidencia->id_plan = $request->id_plan;
|
||||
$evidencia->codigo = $plan->codigo;
|
||||
@ -34,7 +34,7 @@ public function create(Request $request)
|
||||
error_log($request->denominacion);
|
||||
$path = $request->adjunto->store('evidencias');
|
||||
$evidencia->adjunto = $path;
|
||||
$evidencia->id_user = $id_user;
|
||||
$evidencia->id_user = $id_user->id_plan;
|
||||
$evidencia->save();
|
||||
return response([
|
||||
"status" => 1,
|
||||
|
Loading…
Reference in New Issue
Block a user