diff --git a/app/Http/Controllers/AdministradorController.php b/app/Http/Controllers/AdministradorController.php index f8110e7c60f4a1eae3e4a6fea211dd3fab5c5c67..e71401604db03665ae868ff9689b9daf7e45b01f 100644 --- a/app/Http/Controllers/AdministradorController.php +++ b/app/Http/Controllers/AdministradorController.php @@ -10,6 +10,7 @@ use App\Avaliador; use App\AdministradorResponsavel; use App\Participante; use App\Proponente; +use App\Natureza; use Illuminate\Support\Facades\Hash; use App\Evento; @@ -20,8 +21,8 @@ class AdministradorController extends Controller return view('administrador.index'); } public function naturezas(){ - - return view('naturezas.index'); + $naturezas = Natureza::orderBy('nome')->get(); + return view('naturezas.index')->with(['naturezas' => $naturezas]); } public function usuarios(){ $users = User::orderBy('name')->get(); diff --git a/app/Http/Controllers/EventoController.php b/app/Http/Controllers/EventoController.php index 5be0ee7db192f4a58c1497e71b8d0dc778224368..b9a0f2a2a4f45833e7937f21c72e2aca3d966c6b 100644 --- a/app/Http/Controllers/EventoController.php +++ b/app/Http/Controllers/EventoController.php @@ -304,20 +304,20 @@ class EventoController extends Controller { $evento = Evento::find($id); - $areas = Area::where('eventoId', $id); + // $areas = Area::where('eventoId', $id); $atividades = Atividade::where('eventoId', $id); $comissao = ComissaoEvento::where('eventosId', $id); $revisores = Revisor::where('eventoId', $id); - $trabalhos = Trabalho::where('eventoId', $id); + $trabalhos = Trabalho::where('evento_id', $id); - if(isset($areas)){ - $areas->delete(); - } + // if(isset($areas)){ + // $areas->delete(); + // } if(isset($atividades)){ - $atividades->delete(); + $atividades->delete(); } if(isset($comissao)){ - $comissao->delete(); + $comissao->delete(); } if(isset($revisores)){ $revisores->delete(); diff --git a/app/Http/Controllers/NaturezaController.php b/app/Http/Controllers/NaturezaController.php new file mode 100644 index 0000000000000000000000000000000000000000..fbc1912e9e4585557a1b4a6a34faab4e19b5cd94 --- /dev/null +++ b/app/Http/Controllers/NaturezaController.php @@ -0,0 +1,104 @@ +validate([ + 'nome' => 'required' + ]); + + $natureza = new Natureza(); + $natureza->nome = $request->nome; + $natureza->save(); + + return redirect( route('admin.naturezas') )->with(['mensagem' => 'Natureza salva com sucesso']); + } + + /** + * Display the specified resource. + * + * @param int $id + * @return \Illuminate\Http\Response + */ + public function show($id) + { + // + } + + /** + * Show the form for editing the specified resource. + * + * @param int $id + * @return \Illuminate\Http\Response + */ + public function edit($id) + { + // + } + + /** + * Update the specified resource in storage. + * + * @param \Illuminate\Http\Request $request + * @param int $id + * @return \Illuminate\Http\Response + */ + public function update(Request $request, $id) + { + $validated = $request->validate([ + 'nomeEditavel' => 'required', + ]); + + $natureza = Natureza::find($id); + $natureza->nome = $request->nomeEditavel; + $natureza->update(); + + return redirect( route('admin.naturezas') )->with(['mensagem' => "Natureza editada com sucesso"]); + } + + /** + * Remove the specified resource from storage. + * + * @param int $id + * @return \Illuminate\Http\Response + */ + public function destroy($id) + { + $natureza = Natureza::find($id); + $natureza->delete(); + + return redirect( route('admin.naturezas') )->with(['mensagem' => "Natureza deletada com sucesso"]); + } +} diff --git a/app/Natureza.php b/app/Natureza.php new file mode 100644 index 0000000000000000000000000000000000000000..09487157d4e5da77a3a925b80344409919403d52 --- /dev/null +++ b/app/Natureza.php @@ -0,0 +1,10 @@ +=7.1.3", "symfony/polyfill-mbstring": "~1.0", "symfony/polyfill-php73": "^1.8", + "symfony/polyfill-php80": "^1.15", "symfony/service-contracts": "^1.1|^2" }, "conflict": { @@ -1903,29 +1904,29 @@ ], "description": "Symfony Console Component", "homepage": "https://symfony.com", - "time": "2020-03-30T11:41:10+00:00" + "time": "2020-05-30T20:06:45+00:00" }, { "name": "symfony/css-selector", - "version": "v5.0.8", + "version": "v5.1.0", "source": { "type": "git", "url": "https://github.com/symfony/css-selector.git", - "reference": "5f8d5271303dad260692ba73dfa21777d38e124e" + "reference": "e544e24472d4c97b2d11ade7caacd446727c6bf9" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/css-selector/zipball/5f8d5271303dad260692ba73dfa21777d38e124e", - "reference": "5f8d5271303dad260692ba73dfa21777d38e124e", + "url": "https://api.github.com/repos/symfony/css-selector/zipball/e544e24472d4c97b2d11ade7caacd446727c6bf9", + "reference": "e544e24472d4c97b2d11ade7caacd446727c6bf9", "shasum": "" }, "require": { - "php": "^7.2.5" + "php": ">=7.2.5" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "5.0-dev" + "dev-master": "5.1-dev" } }, "autoload": { @@ -1956,25 +1957,26 @@ ], "description": "Symfony CssSelector Component", "homepage": "https://symfony.com", - "time": "2020-03-27T16:56:45+00:00" + "time": "2020-05-20T17:43:50+00:00" }, { "name": "symfony/debug", - "version": "v4.4.8", + "version": "v4.4.9", "source": { "type": "git", "url": "https://github.com/symfony/debug.git", - "reference": "346636d2cae417992ecfd761979b2ab98b339a45" + "reference": "28f92d08bb6d1fddf8158e02c194ad43870007e6" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/debug/zipball/346636d2cae417992ecfd761979b2ab98b339a45", - "reference": "346636d2cae417992ecfd761979b2ab98b339a45", + "url": "https://api.github.com/repos/symfony/debug/zipball/28f92d08bb6d1fddf8158e02c194ad43870007e6", + "reference": "28f92d08bb6d1fddf8158e02c194ad43870007e6", "shasum": "" }, "require": { - "php": "^7.1.3", - "psr/log": "~1.0" + "php": ">=7.1.3", + "psr/log": "~1.0", + "symfony/polyfill-php80": "^1.15" }, "conflict": { "symfony/http-kernel": "<3.4" @@ -2012,26 +2014,27 @@ ], "description": "Symfony Debug Component", "homepage": "https://symfony.com", - "time": "2020-03-27T16:54:36+00:00" + "time": "2020-05-24T08:33:35+00:00" }, { "name": "symfony/error-handler", - "version": "v4.4.8", + "version": "v4.4.9", "source": { "type": "git", "url": "https://github.com/symfony/error-handler.git", - "reference": "7e9828fc98aa1cf27b422fe478a84f5b0abb7358" + "reference": "0df9a23c0f9eddbb6682479fee6fd58b88add75b" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/error-handler/zipball/7e9828fc98aa1cf27b422fe478a84f5b0abb7358", - "reference": "7e9828fc98aa1cf27b422fe478a84f5b0abb7358", + "url": "https://api.github.com/repos/symfony/error-handler/zipball/0df9a23c0f9eddbb6682479fee6fd58b88add75b", + "reference": "0df9a23c0f9eddbb6682479fee6fd58b88add75b", "shasum": "" }, "require": { - "php": "^7.1.3", + "php": ">=7.1.3", "psr/log": "~1.0", "symfony/debug": "^4.4.5", + "symfony/polyfill-php80": "^1.15", "symfony/var-dumper": "^4.4|^5.0" }, "require-dev": { @@ -2068,24 +2071,24 @@ ], "description": "Symfony ErrorHandler Component", "homepage": "https://symfony.com", - "time": "2020-03-30T14:07:33+00:00" + "time": "2020-05-28T10:39:14+00:00" }, { "name": "symfony/event-dispatcher", - "version": "v4.4.8", + "version": "v4.4.9", "source": { "type": "git", "url": "https://github.com/symfony/event-dispatcher.git", - "reference": "abc8e3618bfdb55e44c8c6a00abd333f831bbfed" + "reference": "a5370aaa7807c7a439b21386661ffccf3dff2866" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/event-dispatcher/zipball/abc8e3618bfdb55e44c8c6a00abd333f831bbfed", - "reference": "abc8e3618bfdb55e44c8c6a00abd333f831bbfed", + "url": "https://api.github.com/repos/symfony/event-dispatcher/zipball/a5370aaa7807c7a439b21386661ffccf3dff2866", + "reference": "a5370aaa7807c7a439b21386661ffccf3dff2866", "shasum": "" }, "require": { - "php": "^7.1.3", + "php": ">=7.1.3", "symfony/event-dispatcher-contracts": "^1.1" }, "conflict": { @@ -2138,7 +2141,7 @@ ], "description": "Symfony EventDispatcher Component", "homepage": "https://symfony.com", - "time": "2020-03-27T16:54:36+00:00" + "time": "2020-05-20T08:37:50+00:00" }, { "name": "symfony/event-dispatcher-contracts", @@ -2200,7 +2203,7 @@ }, { "name": "symfony/finder", - "version": "v4.4.8", + "version": "v4.4.9", "source": { "type": "git", "url": "https://github.com/symfony/finder.git", @@ -2249,20 +2252,20 @@ }, { "name": "symfony/http-foundation", - "version": "v4.4.8", + "version": "v4.4.9", "source": { "type": "git", "url": "https://github.com/symfony/http-foundation.git", - "reference": "ec5bd254c223786f5fa2bb49a1e705c1b8e7cee2" + "reference": "3adfbd7098c850b02d107330b7b9deacf2581578" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/http-foundation/zipball/ec5bd254c223786f5fa2bb49a1e705c1b8e7cee2", - "reference": "ec5bd254c223786f5fa2bb49a1e705c1b8e7cee2", + "url": "https://api.github.com/repos/symfony/http-foundation/zipball/3adfbd7098c850b02d107330b7b9deacf2581578", + "reference": "3adfbd7098c850b02d107330b7b9deacf2581578", "shasum": "" }, "require": { - "php": "^7.1.3", + "php": ">=7.1.3", "symfony/mime": "^4.3|^5.0", "symfony/polyfill-mbstring": "~1.1" }, @@ -2300,30 +2303,31 @@ ], "description": "Symfony HttpFoundation Component", "homepage": "https://symfony.com", - "time": "2020-04-18T20:40:08+00:00" + "time": "2020-05-23T09:11:46+00:00" }, { "name": "symfony/http-kernel", - "version": "v4.4.8", + "version": "v4.4.9", "source": { "type": "git", "url": "https://github.com/symfony/http-kernel.git", - "reference": "1799a6c01f0db5851f399151abdb5d6393fec277" + "reference": "54526b598d7fc86a67850488b194a88a79ab8467" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/http-kernel/zipball/1799a6c01f0db5851f399151abdb5d6393fec277", - "reference": "1799a6c01f0db5851f399151abdb5d6393fec277", + "url": "https://api.github.com/repos/symfony/http-kernel/zipball/54526b598d7fc86a67850488b194a88a79ab8467", + "reference": "54526b598d7fc86a67850488b194a88a79ab8467", "shasum": "" }, "require": { - "php": "^7.1.3", + "php": ">=7.1.3", "psr/log": "~1.0", "symfony/error-handler": "^4.4", "symfony/event-dispatcher": "^4.4", "symfony/http-foundation": "^4.4|^5.0", "symfony/polyfill-ctype": "^1.8", - "symfony/polyfill-php73": "^1.9" + "symfony/polyfill-php73": "^1.9", + "symfony/polyfill-php80": "^1.15" }, "conflict": { "symfony/browser-kit": "<4.3", @@ -2390,26 +2394,27 @@ ], "description": "Symfony HttpKernel Component", "homepage": "https://symfony.com", - "time": "2020-04-28T18:47:42+00:00" + "time": "2020-05-31T05:25:51+00:00" }, { "name": "symfony/mime", - "version": "v5.0.8", + "version": "v5.1.0", "source": { "type": "git", "url": "https://github.com/symfony/mime.git", - "reference": "5d6c81c39225a750f3f43bee15f03093fb9aaa0b" + "reference": "56261f89385f9d13cf843a5101ac72131190bc91" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/mime/zipball/5d6c81c39225a750f3f43bee15f03093fb9aaa0b", - "reference": "5d6c81c39225a750f3f43bee15f03093fb9aaa0b", + "url": "https://api.github.com/repos/symfony/mime/zipball/56261f89385f9d13cf843a5101ac72131190bc91", + "reference": "56261f89385f9d13cf843a5101ac72131190bc91", "shasum": "" }, "require": { - "php": "^7.2.5", + "php": ">=7.2.5", "symfony/polyfill-intl-idn": "^1.10", - "symfony/polyfill-mbstring": "^1.0" + "symfony/polyfill-mbstring": "^1.0", + "symfony/polyfill-php80": "^1.15" }, "conflict": { "symfony/mailer": "<4.4" @@ -2421,7 +2426,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-master": "5.0-dev" + "dev-master": "5.1-dev" } }, "autoload": { @@ -2452,7 +2457,7 @@ "mime", "mime-type" ], - "time": "2020-04-17T03:29:44+00:00" + "time": "2020-05-25T12:33:44+00:00" }, { "name": "symfony/polyfill-ctype", @@ -2805,18 +2810,80 @@ ], "time": "2020-05-12T16:47:27+00:00" }, + { + "name": "symfony/polyfill-php80", + "version": "v1.17.0", + "source": { + "type": "git", + "url": "https://github.com/symfony/polyfill-php80.git", + "reference": "5e30b2799bc1ad68f7feb62b60a73743589438dd" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/symfony/polyfill-php80/zipball/5e30b2799bc1ad68f7feb62b60a73743589438dd", + "reference": "5e30b2799bc1ad68f7feb62b60a73743589438dd", + "shasum": "" + }, + "require": { + "php": ">=7.0.8" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "1.17-dev" + } + }, + "autoload": { + "psr-4": { + "Symfony\\Polyfill\\Php80\\": "" + }, + "files": [ + "bootstrap.php" + ], + "classmap": [ + "Resources/stubs" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Ion Bazan", + "email": "ion.bazan@gmail.com" + }, + { + "name": "Nicolas Grekas", + "email": "p@tchwork.com" + }, + { + "name": "Symfony Community", + "homepage": "https://symfony.com/contributors" + } + ], + "description": "Symfony polyfill backporting some PHP 8.0+ features to lower PHP versions", + "homepage": "https://symfony.com", + "keywords": [ + "compatibility", + "polyfill", + "portable", + "shim" + ], + "time": "2020-05-12T16:47:27+00:00" + }, { "name": "symfony/process", - "version": "v4.4.8", + "version": "v4.4.9", "source": { "type": "git", "url": "https://github.com/symfony/process.git", - "reference": "4b6a9a4013baa65d409153cbb5a895bf093dc7f4" + "reference": "c714958428a85c86ab97e3a0c96db4c4f381b7f5" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/process/zipball/4b6a9a4013baa65d409153cbb5a895bf093dc7f4", - "reference": "4b6a9a4013baa65d409153cbb5a895bf093dc7f4", + "url": "https://api.github.com/repos/symfony/process/zipball/c714958428a85c86ab97e3a0c96db4c4f381b7f5", + "reference": "c714958428a85c86ab97e3a0c96db4c4f381b7f5", "shasum": "" }, "require": { @@ -2852,20 +2919,20 @@ ], "description": "Symfony Process Component", "homepage": "https://symfony.com", - "time": "2020-04-15T15:56:18+00:00" + "time": "2020-05-30T20:06:45+00:00" }, { "name": "symfony/routing", - "version": "v4.4.8", + "version": "v4.4.9", "source": { "type": "git", "url": "https://github.com/symfony/routing.git", - "reference": "67b4e1f99c050cbc310b8f3d0dbdc4b0212c052c" + "reference": "0f557911dde75c2a9652b8097bd7c9f54507f646" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/routing/zipball/67b4e1f99c050cbc310b8f3d0dbdc4b0212c052c", - "reference": "67b4e1f99c050cbc310b8f3d0dbdc4b0212c052c", + "url": "https://api.github.com/repos/symfony/routing/zipball/0f557911dde75c2a9652b8097bd7c9f54507f646", + "reference": "0f557911dde75c2a9652b8097bd7c9f54507f646", "shasum": "" }, "require": { @@ -2928,24 +2995,24 @@ "uri", "url" ], - "time": "2020-04-21T19:59:53+00:00" + "time": "2020-05-30T20:07:26+00:00" }, { "name": "symfony/service-contracts", - "version": "v2.0.1", + "version": "v2.1.2", "source": { "type": "git", "url": "https://github.com/symfony/service-contracts.git", - "reference": "144c5e51266b281231e947b51223ba14acf1a749" + "reference": "66a8f0957a3ca54e4f724e49028ab19d75a8918b" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/service-contracts/zipball/144c5e51266b281231e947b51223ba14acf1a749", - "reference": "144c5e51266b281231e947b51223ba14acf1a749", + "url": "https://api.github.com/repos/symfony/service-contracts/zipball/66a8f0957a3ca54e4f724e49028ab19d75a8918b", + "reference": "66a8f0957a3ca54e4f724e49028ab19d75a8918b", "shasum": "" }, "require": { - "php": "^7.2.5", + "php": ">=7.2.5", "psr/container": "^1.0" }, "suggest": { @@ -2954,7 +3021,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-master": "2.0-dev" + "dev-master": "2.1-dev" } }, "autoload": { @@ -2986,24 +3053,24 @@ "interoperability", "standards" ], - "time": "2019-11-18T17:27:11+00:00" + "time": "2020-05-20T17:43:50+00:00" }, { "name": "symfony/translation", - "version": "v4.4.8", + "version": "v4.4.9", "source": { "type": "git", "url": "https://github.com/symfony/translation.git", - "reference": "8272bbd2b7e220ef812eba2a2b30068a5c64b191" + "reference": "79d3ef9096a6a6047dbc69218b68c7b7f63193af" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/translation/zipball/8272bbd2b7e220ef812eba2a2b30068a5c64b191", - "reference": "8272bbd2b7e220ef812eba2a2b30068a5c64b191", + "url": "https://api.github.com/repos/symfony/translation/zipball/79d3ef9096a6a6047dbc69218b68c7b7f63193af", + "reference": "79d3ef9096a6a6047dbc69218b68c7b7f63193af", "shasum": "" }, "require": { - "php": "^7.1.3", + "php": ">=7.1.3", "symfony/polyfill-mbstring": "~1.0", "symfony/translation-contracts": "^1.1.6|^2" }, @@ -3062,24 +3129,24 @@ ], "description": "Symfony Translation Component", "homepage": "https://symfony.com", - "time": "2020-04-12T16:45:36+00:00" + "time": "2020-05-30T20:06:45+00:00" }, { "name": "symfony/translation-contracts", - "version": "v2.0.1", + "version": "v2.1.2", "source": { "type": "git", "url": "https://github.com/symfony/translation-contracts.git", - "reference": "8cc682ac458d75557203b2f2f14b0b92e1c744ed" + "reference": "e5ca07c8f817f865f618aa072c2fe8e0e637340e" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/translation-contracts/zipball/8cc682ac458d75557203b2f2f14b0b92e1c744ed", - "reference": "8cc682ac458d75557203b2f2f14b0b92e1c744ed", + "url": "https://api.github.com/repos/symfony/translation-contracts/zipball/e5ca07c8f817f865f618aa072c2fe8e0e637340e", + "reference": "e5ca07c8f817f865f618aa072c2fe8e0e637340e", "shasum": "" }, "require": { - "php": "^7.2.5" + "php": ">=7.2.5" }, "suggest": { "symfony/translation-implementation": "" @@ -3087,7 +3154,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-master": "2.0-dev" + "dev-master": "2.1-dev" } }, "autoload": { @@ -3119,26 +3186,27 @@ "interoperability", "standards" ], - "time": "2019-11-18T17:27:11+00:00" + "time": "2020-05-20T17:43:50+00:00" }, { "name": "symfony/var-dumper", - "version": "v4.4.8", + "version": "v4.4.9", "source": { "type": "git", "url": "https://github.com/symfony/var-dumper.git", - "reference": "c587e04ce5d1aa62d534a038f574d9a709e814cf" + "reference": "56b3aa5eab0ac6720dcd559fd1d590ce301594ac" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/var-dumper/zipball/c587e04ce5d1aa62d534a038f574d9a709e814cf", - "reference": "c587e04ce5d1aa62d534a038f574d9a709e814cf", + "url": "https://api.github.com/repos/symfony/var-dumper/zipball/56b3aa5eab0ac6720dcd559fd1d590ce301594ac", + "reference": "56b3aa5eab0ac6720dcd559fd1d590ce301594ac", "shasum": "" }, "require": { - "php": "^7.1.3", + "php": ">=7.1.3", "symfony/polyfill-mbstring": "~1.0", - "symfony/polyfill-php72": "~1.5" + "symfony/polyfill-php72": "~1.5", + "symfony/polyfill-php80": "^1.15" }, "conflict": { "phpunit/phpunit": "<4.8.35|<5.4.3,>=5.0", @@ -3195,7 +3263,7 @@ "debug", "dump" ], - "time": "2020-04-12T16:14:02+00:00" + "time": "2020-05-30T20:06:45+00:00" }, { "name": "tijsverkoyen/css-to-inline-styles", @@ -3313,20 +3381,20 @@ "packages-dev": [ { "name": "doctrine/instantiator", - "version": "1.3.0", + "version": "1.3.1", "source": { "type": "git", "url": "https://github.com/doctrine/instantiator.git", - "reference": "ae466f726242e637cebdd526a7d991b9433bacf1" + "reference": "f350df0268e904597e3bd9c4685c53e0e333feea" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/doctrine/instantiator/zipball/ae466f726242e637cebdd526a7d991b9433bacf1", - "reference": "ae466f726242e637cebdd526a7d991b9433bacf1", + "url": "https://api.github.com/repos/doctrine/instantiator/zipball/f350df0268e904597e3bd9c4685c53e0e333feea", + "reference": "f350df0268e904597e3bd9c4685c53e0e333feea", "shasum": "" }, "require": { - "php": "^7.1" + "php": "^7.1 || ^8.0" }, "require-dev": { "doctrine/coding-standard": "^6.0", @@ -3365,7 +3433,7 @@ "constructor", "instantiate" ], - "time": "2019-10-21T16:45:58+00:00" + "time": "2020-05-29T17:27:14+00:00" }, { "name": "facade/flare-client-php", diff --git a/database/migrations/2020_06_01_174832_create_naturezas_table.php b/database/migrations/2020_06_01_174832_create_naturezas_table.php new file mode 100644 index 0000000000000000000000000000000000000000..b33fffe499e7512dd29e024a0d2c7a47050ea811 --- /dev/null +++ b/database/migrations/2020_06_01_174832_create_naturezas_table.php @@ -0,0 +1,32 @@ +bigIncrements('id'); + $table->string('nome'); + $table->timestamps(); + }); + } + + /** + * Reverse the migrations. + * + * @return void + */ + public function down() + { + Schema::dropIfExists('naturezas'); + } +} diff --git a/database/seeds/DatabaseSeeder.php b/database/seeds/DatabaseSeeder.php index a75860a905508f0492bfd9072c47ce63f176fc30..d5d0b9788f0e52b4d87beb35b5d42f03c19d9221 100644 --- a/database/seeds/DatabaseSeeder.php +++ b/database/seeds/DatabaseSeeder.php @@ -22,6 +22,7 @@ class DatabaseSeeder extends Seeder $this->call(FuncaoParticipanteSeeder::class); $this->call(CoordenadorComissaoSeeder::class); $this->call(ParticipanteSeeder::class); + $this->call(NaturezaSeeder::class); // $this->call(UsersTableSeeder::class); diff --git a/database/seeds/NaturezaSeeder.php b/database/seeds/NaturezaSeeder.php new file mode 100644 index 0000000000000000000000000000000000000000..db7ffce819f28c060ac67a1d174b2b0b27eabdc6 --- /dev/null +++ b/database/seeds/NaturezaSeeder.php @@ -0,0 +1,26 @@ +insert([ + 'nome' => 'Ensino', + ]); + + DB::table('naturezas')->insert([ + 'nome' => 'Pesquisa', + ]); + + DB::table('naturezas')->insert([ + 'nome' => 'Extensão', + ]); + } +} diff --git a/resources/views/administrador/index.blade.php b/resources/views/administrador/index.blade.php index efc42073360a29af6e727f853f8542d06e87c9f9..17f67e4b97b5ef398d9e263560f199e7d7722b06 100644 --- a/resources/views/administrador/index.blade.php +++ b/resources/views/administrador/index.blade.php @@ -19,7 +19,7 @@
{{session('mensagem')}}
+Nome | +Data de criação | +Opção | +
---|---|---|
+ {{ $natureza->nome }} + | ++ {{$natureza->creat_at}} + | ++ | + +