Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
Walter Felipe
submeta
Commits
590ed5ea
Commit
590ed5ea
authored
Jul 26, 2022
by
GuilhermeGz
Browse files
Alteração na atualização de endereço
parent
8a05eb02
Changes
2
Show whitespace changes
Inline
Side-by-side
app/Http/Controllers/TrabalhoController.php
View file @
590ed5ea
...
@@ -887,7 +887,6 @@ class TrabalhoController extends Controller
...
@@ -887,7 +887,6 @@ class TrabalhoController extends Controller
if
(
$request
->
has
(
'marcado'
))
{
if
(
$request
->
has
(
'marcado'
))
{
foreach
(
$request
->
marcado
as
$key
=>
$part
)
{
foreach
(
$request
->
marcado
as
$key
=>
$part
)
{
$part
=
intval
(
$part
);
$part
=
intval
(
$part
);
$passwordTemporario
=
Str
::
random
(
8
);
$passwordTemporario
=
Str
::
random
(
8
);
$data
[
'name'
]
=
$request
->
name
[
$part
];
$data
[
'name'
]
=
$request
->
name
[
$part
];
$data
[
'email'
]
=
$request
->
email
[
$part
];
$data
[
'email'
]
=
$request
->
email
[
$part
];
...
@@ -946,8 +945,13 @@ class TrabalhoController extends Controller
...
@@ -946,8 +945,13 @@ class TrabalhoController extends Controller
}
else
{
}
else
{
// $user = $participante->user;
// $user = $participante->user;
$user
->
update
(
$data
);
$user
->
update
(
$data
);
if
(
$user
->
endereco
==
null
){
$endereco
=
Endereco
::
create
(
$data
);
$endereco
->
user
()
->
save
(
$user
);
}
else
{
$endereco
=
$user
->
endereco
;
$endereco
=
$user
->
endereco
;
$endereco
->
update
(
$data
);
$endereco
->
update
(
$data
);
}
$participante
=
$user
->
participantes
->
where
(
'trabalho_id'
,
$trabalho
->
id
)
->
where
(
'id'
,
$request
->
participante_id
[
$part
])
->
first
();
$participante
=
$user
->
participantes
->
where
(
'trabalho_id'
,
$trabalho
->
id
)
->
where
(
'id'
,
$request
->
participante_id
[
$part
])
->
first
();
// dd($participante);
// dd($participante);
if
(
$participante
==
null
)
{
if
(
$participante
==
null
)
{
...
...
resources/views/projeto/editaFormulario/participantes.blade.php
View file @
590ed5ea
...
@@ -321,8 +321,7 @@
...
@@ -321,8 +321,7 @@
<select
name=
"ordem_prioridade[]"
class=
"form-control"
>
<select
name=
"ordem_prioridade[]"
class=
"form-control"
>
<option
value=
""
selected
>
-- ORDEM --
</option>
<option
value=
""
selected
>
-- ORDEM --
</option>
@for($j = 1; $j
<
=
$
edital-
>
numParticipantes; $j++)
@for($j = 1; $j
<
=
$
edital-
>
numParticipantes; $j++)
<option
@
if
(
old
('
total_periodos
')[$
i
]
??
$
participante-
>
ordem_prioridade == $j ) selected @endif value="{{ $j }}">{{ $j }}
</option>
<option
@
if
(
old
('
total_periodos
')[$
i
]
??
($
participante-
>
ordem_prioridade ?? '') == $j ) selected @endif value="{{ $j }}">{{ $j }}
</option>
@endfor
@endfor
</select>
</select>
@error('ordem_prioridade.'.$i)
@error('ordem_prioridade.'.$i)
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment