@@ -29,7 +29,7 @@ |
||
29 | 29 | 'middleware' => ['app.hasSetting', 'guest'], |
30 | 30 | 'setting' => 'app_name', |
31 | 31 | 'as' => 'signup.', |
32 | - ], function ($router) { |
|
32 | + ], function($router) { |
|
33 | 33 | $router->get('signup/invite/{code}', [ |
34 | 34 | 'as' => 'invite', |
35 | 35 | 'uses' => 'SignupController@getSignup', |
@@ -3,8 +3,6 @@ |
||
3 | 3 | namespace Gitamin\Http\Controllers\Projects; |
4 | 4 | |
5 | 5 | use Illuminate\Http\Request; |
6 | - |
|
7 | -use Gitamin\Http\Requests; |
|
8 | 6 | use Gitamin\Http\Controllers\Controller; |
9 | 7 | |
10 | 8 | class ProjectController extends Controller |
@@ -3,8 +3,6 @@ |
||
3 | 3 | namespace Gitamin\Http\Controllers\Projects; |
4 | 4 | |
5 | 5 | use Illuminate\Http\Request; |
6 | - |
|
7 | -use Gitamin\Http\Requests; |
|
8 | 6 | use Gitamin\Http\Controllers\Controller; |
9 | 7 | |
10 | 8 | class ProjectController extends Controller |
@@ -11,22 +11,9 @@ |
||
11 | 11 | |
12 | 12 | namespace Gitamin\Http\Controllers\Dashboard; |
13 | 13 | |
14 | -use AltThree\Validator\ValidationException; |
|
15 | -use Gitamin\Commands\Project\AddProjectCommand; |
|
16 | -use Gitamin\Commands\Project\RemoveProjectCommand; |
|
17 | -use Gitamin\Commands\Project\UpdateProjectCommand; |
|
18 | -use Gitamin\Commands\ProjectNamespace\AddProjectNamespaceCommand; |
|
19 | -use Gitamin\Commands\ProjectNamespace\RemoveProjectNamespaceCommand; |
|
20 | -use Gitamin\Commands\ProjectNamespace\UpdateProjectNamespaceCommand; |
|
21 | 14 | use Gitamin\Http\Controllers\Controller; |
22 | -use Gitamin\Models\Project; |
|
23 | 15 | use Gitamin\Models\Group; |
24 | -use Gitamin\Models\Tag; |
|
25 | -use GrahamCampbell\Binput\Facades\Binput; |
|
26 | -use Illuminate\Foundation\Bus\DispatchesJobs; |
|
27 | -use Illuminate\Support\Facades\Redirect; |
|
28 | 16 | use Illuminate\Support\Facades\View; |
29 | -use Symfony\Component\HttpKernel\Exception\BadRequestHttpException; |
|
30 | 17 | |
31 | 18 | class GroupsController extends Controller |
32 | 19 | { |
@@ -52,12 +52,12 @@ |
||
52 | 52 | 'setting' => 'app_name', |
53 | 53 | 'as' => 'groups.', |
54 | 54 | ], function ($router) { |
55 | - $router->get('{namespace}', [ |
|
55 | + $router->get('{namespace}', [ |
|
56 | 56 | 'as' => 'group_show', |
57 | 57 | 'uses' => 'GroupsController@show', |
58 | 58 | ])->where('namespace', '[a-zA-z.0-9_\-]+'); |
59 | 59 | |
60 | - $router->get('{namespace}/edit', [ |
|
60 | + $router->get('{namespace}/edit', [ |
|
61 | 61 | 'as' => 'group_edit', |
62 | 62 | 'uses' => 'GroupsController@edit', |
63 | 63 | ])->where('namespace', '[a-zA-z.0-9_\-]+'); |
@@ -32,7 +32,7 @@ discard block |
||
32 | 32 | 'setting' => 'app_name', |
33 | 33 | 'prefix' => 'projects', |
34 | 34 | 'as' => 'projects.', |
35 | - ], function ($router) { |
|
35 | + ], function($router) { |
|
36 | 36 | $router->get('/', [ |
37 | 37 | 'as' => 'index', |
38 | 38 | 'uses' => 'ProjectsController@index', |
@@ -54,7 +54,7 @@ discard block |
||
54 | 54 | 'middleware' => ['app.hasSetting'], |
55 | 55 | 'setting' => 'app_name', |
56 | 56 | 'as' => 'projects.', |
57 | - ], function ($router) { |
|
57 | + ], function($router) { |
|
58 | 58 | $router->get('{namespace}/{project}', [ |
59 | 59 | 'as' => 'project_show', |
60 | 60 | 'uses' => 'ProjectsController@show', |
@@ -55,12 +55,12 @@ |
||
55 | 55 | 'setting' => 'app_name', |
56 | 56 | 'as' => 'projects.', |
57 | 57 | ], function ($router) { |
58 | - $router->get('{namespace}/{project}', [ |
|
58 | + $router->get('{namespace}/{project}', [ |
|
59 | 59 | 'as' => 'project_show', |
60 | 60 | 'uses' => 'ProjectsController@show', |
61 | 61 | ])->where('namespace', '[a-zA-z.0-9_\-]+')->where('project', '[a-zA-z.0-9_\-]+'); |
62 | 62 | |
63 | - $router->get('{namespace}/{project}/edit', [ |
|
63 | + $router->get('{namespace}/{project}/edit', [ |
|
64 | 64 | 'as' => 'project_edit', |
65 | 65 | 'uses' => 'ProjectsController@edit', |
66 | 66 | ])->where('namespace', '[a-zA-z.0-9_\-]+')->where('project', '[a-zA-z.0-9_\-]+'); |
@@ -32,7 +32,7 @@ discard block |
||
32 | 32 | 'setting' => 'app_name', |
33 | 33 | 'prefix' => 'projects', |
34 | 34 | 'as' => 'projects.', |
35 | - ], function ($router) { |
|
35 | + ], function($router) { |
|
36 | 36 | $router->get('/', [ |
37 | 37 | 'as' => 'index', |
38 | 38 | 'uses' => 'ProjectsController@index', |
@@ -54,7 +54,7 @@ discard block |
||
54 | 54 | 'middleware' => ['app.hasSetting'], |
55 | 55 | 'setting' => 'app_name', |
56 | 56 | 'as' => 'projects.', |
57 | - ], function ($router) { |
|
57 | + ], function($router) { |
|
58 | 58 | $router->get('{namespace}/{project}', [ |
59 | 59 | 'as' => 'project_show', |
60 | 60 | 'uses' => 'ProjectsController@show', |
@@ -30,7 +30,7 @@ |
||
30 | 30 | event(new ProjectTeamWasRemovedEvent($team)); |
31 | 31 | |
32 | 32 | // Remove the namespace id from all project. |
33 | - $group->projects->map(function ($project) { |
|
33 | + $group->projects->map(function($project) { |
|
34 | 34 | $project->update(['namespace_id' => 0]); |
35 | 35 | }); |
36 | 36 |
@@ -13,18 +13,14 @@ |
||
13 | 13 | |
14 | 14 | use AltThree\Validator\ValidationException; |
15 | 15 | use Gitamin\Commands\ProjectNamespace\AddProjectNamespaceCommand; |
16 | -use Gitamin\Commands\ProjectNamespace\RemoveProjectNamespaceCommand; |
|
17 | 16 | use Gitamin\Commands\ProjectNamespace\UpdateProjectNamespaceCommand; |
18 | -use Gitamin\Models\Project; |
|
19 | 17 | use Gitamin\Models\ProjectNamespace; |
20 | 18 | use Gitamin\Models\Group; |
21 | -use Gitamin\Models\Tag; |
|
22 | 19 | use Gitamin\Http\Controllers\Controller; |
23 | 20 | use GrahamCampbell\Binput\Facades\Binput; |
24 | 21 | use Illuminate\Support\Facades\Redirect; |
25 | 22 | use Illuminate\Support\Facades\Auth; |
26 | 23 | use Illuminate\Support\Facades\View; |
27 | -use Symfony\Component\HttpKernel\Exception\BadRequestHttpException; |
|
28 | 24 | |
29 | 25 | class GroupsController extends Controller |
30 | 26 | { |
@@ -84,11 +84,11 @@ |
||
84 | 84 | ->withSubMenu($this->subMenu); |
85 | 85 | } |
86 | 86 | |
87 | - /** |
|
88 | - * Shows the group view. |
|
89 | - * |
|
90 | - * @return \Illuminate\View\View |
|
91 | - */ |
|
87 | + /** |
|
88 | + * Shows the group view. |
|
89 | + * |
|
90 | + * @return \Illuminate\View\View |
|
91 | + */ |
|
92 | 92 | public function show($namespace) |
93 | 93 | { |
94 | 94 | $group = Group::where('path', '=', $namespace)->first(); |
@@ -30,7 +30,7 @@ discard block |
||
30 | 30 | $router->group([ |
31 | 31 | 'middleware' => ['app.hasSetting'], |
32 | 32 | 'setting' => 'app_name', |
33 | - ], function ($router) { |
|
33 | + ], function($router) { |
|
34 | 34 | $router->get('/', [ |
35 | 35 | 'as' => 'index', |
36 | 36 | 'uses' => 'ExploreController@index', |
@@ -39,7 +39,7 @@ discard block |
||
39 | 39 | }); |
40 | 40 | |
41 | 41 | //Install Area |
42 | - $router->group(['middleware' => ['app.isInstalled', 'localize']], function ($router) { |
|
42 | + $router->group(['middleware' => ['app.isInstalled', 'localize']], function($router) { |
|
43 | 43 | $router->controller('install', 'InstallController'); |
44 | 44 | }); |
45 | 45 | |
@@ -49,7 +49,7 @@ discard block |
||
49 | 49 | 'setting' => 'app_name', |
50 | 50 | 'prefix' => 'explore', |
51 | 51 | 'as' => 'explore.', |
52 | - ], function ($router) { |
|
52 | + ], function($router) { |
|
53 | 53 | $router->get('/', [ |
54 | 54 | 'as' => 'index', |
55 | 55 | 'uses' => 'ExploreController@index', |
@@ -66,7 +66,7 @@ discard block |
||
66 | 66 | $router->group([ |
67 | 67 | 'middleware' => 'app.hasSetting', |
68 | 68 | 'setting' => 'app_name', |
69 | - ], function ($router) { |
|
69 | + ], function($router) { |
|
70 | 70 | $router->get('/atom/{namespace?}', [ |
71 | 71 | 'as' => 'feed.atom', |
72 | 72 | 'uses' => 'FeedController@atomAction', |