From 839d535728a713071c16c2a877ab29b4908d5691 Mon Sep 17 00:00:00 2001 From: Hillel Coren Date: Wed, 31 Jan 2018 16:40:47 +0200 Subject: [PATCH] Working on proposals --- app/Http/Requests/CreateProposalCategoryRequest.php | 2 +- app/Http/Requests/CreateProposalRequest.php | 2 +- app/Http/Requests/CreateProposalSnippetRequest.php | 2 +- app/Http/Requests/CreateProposalTemplateRequest.php | 2 +- app/Http/Requests/EntityRequest.php | 1 + app/Http/Requests/UpdateProposalCategoryRequest.php | 2 +- app/Http/Requests/UpdateProposalRequest.php | 2 +- app/Http/Requests/UpdateProposalSnippetRequest.php | 2 +- app/Http/Requests/UpdateProposalTemplateRequest.php | 2 +- 9 files changed, 9 insertions(+), 8 deletions(-) diff --git a/app/Http/Requests/CreateProposalCategoryRequest.php b/app/Http/Requests/CreateProposalCategoryRequest.php index 859a1cf1c0..7b55b446e1 100644 --- a/app/Http/Requests/CreateProposalCategoryRequest.php +++ b/app/Http/Requests/CreateProposalCategoryRequest.php @@ -2,7 +2,7 @@ namespace App\Http\Requests; -class CreateProposalCategoryRequest extends ProjectRequest +class CreateProposalCategoryRequest extends ProposalCategoryRequest { /** * Determine if the user is authorized to make this request. diff --git a/app/Http/Requests/CreateProposalRequest.php b/app/Http/Requests/CreateProposalRequest.php index 7b19f610eb..70a20b632a 100644 --- a/app/Http/Requests/CreateProposalRequest.php +++ b/app/Http/Requests/CreateProposalRequest.php @@ -2,7 +2,7 @@ namespace App\Http\Requests; -class CreateProposalRequest extends ProjectRequest +class CreateProposalRequest extends ProposalRequest { /** * Determine if the user is authorized to make this request. diff --git a/app/Http/Requests/CreateProposalSnippetRequest.php b/app/Http/Requests/CreateProposalSnippetRequest.php index 1ef6baeea4..616cbb0130 100644 --- a/app/Http/Requests/CreateProposalSnippetRequest.php +++ b/app/Http/Requests/CreateProposalSnippetRequest.php @@ -2,7 +2,7 @@ namespace App\Http\Requests; -class CreateProposalSnippetRequest extends ProjectRequest +class CreateProposalSnippetRequest extends ProposalSnippetRequest { /** * Determine if the user is authorized to make this request. diff --git a/app/Http/Requests/CreateProposalTemplateRequest.php b/app/Http/Requests/CreateProposalTemplateRequest.php index f3d37d7462..8e8009709c 100644 --- a/app/Http/Requests/CreateProposalTemplateRequest.php +++ b/app/Http/Requests/CreateProposalTemplateRequest.php @@ -2,7 +2,7 @@ namespace App\Http\Requests; -class CreateProposalTemplateRequest extends ProjectRequest +class CreateProposalTemplateRequest extends ProposalTemplateRequest { /** * Determine if the user is authorized to make this request. diff --git a/app/Http/Requests/EntityRequest.php b/app/Http/Requests/EntityRequest.php index 37734f183d..92b3533dd8 100644 --- a/app/Http/Requests/EntityRequest.php +++ b/app/Http/Requests/EntityRequest.php @@ -35,6 +35,7 @@ class EntityRequest extends Request if (! $publicId) { $publicId = Input::get('public_id') ?: Input::get('id'); } + if (! $publicId) { return null; } diff --git a/app/Http/Requests/UpdateProposalCategoryRequest.php b/app/Http/Requests/UpdateProposalCategoryRequest.php index 47b862592b..f2590045d1 100644 --- a/app/Http/Requests/UpdateProposalCategoryRequest.php +++ b/app/Http/Requests/UpdateProposalCategoryRequest.php @@ -2,7 +2,7 @@ namespace App\Http\Requests; -class UpdateProposalCategoryRequest extends ProjectRequest +class UpdateProposalCategoryRequest extends ProposalCategoryRequest { /** * Determine if the user is authorized to make this request. diff --git a/app/Http/Requests/UpdateProposalRequest.php b/app/Http/Requests/UpdateProposalRequest.php index ea1801b8a4..be1e30895f 100644 --- a/app/Http/Requests/UpdateProposalRequest.php +++ b/app/Http/Requests/UpdateProposalRequest.php @@ -2,7 +2,7 @@ namespace App\Http\Requests; -class UpdateProposalRequest extends ProjectRequest +class UpdateProposalRequest extends ProposalRequest { /** * Determine if the user is authorized to make this request. diff --git a/app/Http/Requests/UpdateProposalSnippetRequest.php b/app/Http/Requests/UpdateProposalSnippetRequest.php index a2d4bba9af..5580db7c85 100644 --- a/app/Http/Requests/UpdateProposalSnippetRequest.php +++ b/app/Http/Requests/UpdateProposalSnippetRequest.php @@ -2,7 +2,7 @@ namespace App\Http\Requests; -class UpdateProposalSnippetRequest extends ProjectRequest +class UpdateProposalSnippetRequest extends ProposalSnippetRequest { /** * Determine if the user is authorized to make this request. diff --git a/app/Http/Requests/UpdateProposalTemplateRequest.php b/app/Http/Requests/UpdateProposalTemplateRequest.php index de4927a3ce..c7808b50d0 100644 --- a/app/Http/Requests/UpdateProposalTemplateRequest.php +++ b/app/Http/Requests/UpdateProposalTemplateRequest.php @@ -2,7 +2,7 @@ namespace App\Http\Requests; -class UpdateProposalTemplateRequest extends ProjectRequest +class UpdateProposalTemplateRequest extends ProposalTemplateRequest { /** * Determine if the user is authorized to make this request.