Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
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
13e6248a
Commit
13e6248a
authored
2 years ago
by
unknown
Browse files
Options
Download
Email Patches
Plain Diff
Validação para ODS na submissão de propostas
parent
282795a6
master
carl-branch
dependabot/composer/symfony/http-kernel-4.4.50
dependabot/npm_and_yarn/decode-uri-component-0.2.2
dependabot/npm_and_yarn/express-4.18.2
dependabot/npm_and_yarn/json5-and-json5-2.2.3
dependabot/npm_and_yarn/loader-utils-and-webpack-cli-1.4.2
dependabot/npm_and_yarn/minimist-and-mkdirp-1.2.8
dependabot/npm_and_yarn/qs-and-express-6.11.0
excluir_projeto_submetido
updates_mar
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
app/Http/Requests/StoreTrabalho.php
+2
-0
app/Http/Requests/StoreTrabalho.php
resources/views/evento/formulario/projeto.blade.php
+3
-3
resources/views/evento/formulario/projeto.blade.php
with
5 additions
and
3 deletions
+5
-3
app/Http/Requests/StoreTrabalho.php
View file @
13e6248a
...
@@ -93,6 +93,8 @@ class StoreTrabalho extends FormRequest
...
@@ -93,6 +93,8 @@ class StoreTrabalho extends FormRequest
$rules
[
'area_id'
]
=
[
Rule
::
requiredIf
(
$evento
->
natureza_id
!=
3
),
'string'
];
$rules
[
'area_id'
]
=
[
Rule
::
requiredIf
(
$evento
->
natureza_id
!=
3
),
'string'
];
if
(
$evento
->
natureza_id
==
3
){
if
(
$evento
->
natureza_id
==
3
){
$rules
[
'area_tematica_id'
]
=
[
'required'
,
'string'
];
$rules
[
'area_tematica_id'
]
=
[
'required'
,
'string'
];
$rules
[
'ods'
]
=
[
'required'
];
}
}
$rules
[
'linkLattesEstudante'
]
=
[
'required'
,
'string'
];
$rules
[
'linkLattesEstudante'
]
=
[
'required'
,
'string'
];
...
...
This diff is collapsed.
Click to expand it.
resources/views/evento/formulario/projeto.blade.php
View file @
13e6248a
...
@@ -88,18 +88,18 @@
...
@@ -88,18 +88,18 @@
<div
class=
"row col-md-12"
>
<div
class=
"row col-md-12"
>
<div
class=
"form-group col-md-12"
>
<div
class=
"form-group col-md-12"
>
<label
for=
"ods"
class=
"col-form-label"
style=
"font-weight: bold"
>
{{ __('Objetivo de Densenvolvimento Sustentável') }}
<span
style=
"color: red; font-weight:bold"
>
*
</span></label><br>
<label
for=
"ods
_id
"
class=
"col-form-label"
style=
"font-weight: bold"
>
{{ __('Objetivo de Densenvolvimento Sustentável') }}
<span
style=
"color: red; font-weight:bold"
>
*
</span></label><br>
<div
class=
"row col-md-12"
>
<div
class=
"row col-md-12"
>
@foreach($ods as $od)
@foreach($ods as $od)
<div
class=
"col-md-6"
>
<div
class=
"col-md-6"
>
<input
type=
"checkbox"
name=
"ods[]"
id=
"ods{{$od->id}}"
value=
"{{$od->id}}"
>
<input
type=
"checkbox"
name=
"ods[]"
id=
"ods{{$od->id}}"
class=
"@error('ods_id') is-invalid @enderror"
value=
"{{$od->id}}"
@
if
(!
empty
(
old
('
ods
'))
&&
in_array
($
od-
>
id, old('ods'))) checked @endif
>
<label
class=
"form-check-label"
for=
"ods{{$od->id}}"
>
<label
class=
"form-check-label"
for=
"ods{{$od->id}}"
>
{{ $od->nome }}
{{ $od->nome }}
</label>
</label>
</div>
</div>
@endforeach
@endforeach
</div>
</div>
@error('ods
_id
')
@error('ods')
<span
class=
"invalid-feedback"
role=
"alert"
style=
"overflow: visible; display:block"
>
<span
class=
"invalid-feedback"
role=
"alert"
style=
"overflow: visible; display:block"
>
<strong>
{{ $message }}
</strong>
<strong>
{{ $message }}
</strong>
</span>
</span>
...
...
This diff is collapsed.
Click to expand it.
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
Menu
Projects
Groups
Snippets
Help