@@ -102,14 +102,14 @@ discard block |
||
| 102 | 102 | |
| 103 | 103 | public function labels($feature) |
| 104 | 104 | { |
| 105 | - return $this->{$feature}->map(function ($obj) { |
|
| 105 | + return $this->{$feature}->map(function($obj) { |
|
| 106 | 106 | return $obj->labels; |
| 107 | 107 | })->flatten(1)->unique('id'); |
| 108 | 108 | } |
| 109 | 109 | |
| 110 | 110 | public function productBacklogs($product_backlog_id = null) |
| 111 | 111 | { |
| 112 | - return $this->organizations->map(function ($organization) use ($product_backlog_id) { |
|
| 112 | + return $this->organizations->map(function($organization) use ($product_backlog_id) { |
|
| 113 | 113 | $obj = $organization->productBacklog() |
| 114 | 114 | ->with('sprints') |
| 115 | 115 | ->with('favorite') |
@@ -154,7 +154,7 @@ discard block |
||
| 154 | 154 | |
| 155 | 155 | public function team() |
| 156 | 156 | { |
| 157 | - return $this->organizations->map(function ($obj) { |
|
| 157 | + return $this->organizations->map(function($obj) { |
|
| 158 | 158 | return $obj->users; |
| 159 | 159 | })->flatten(1)->unique('id'); |
| 160 | 160 | //->where('id', '!=', Auth::user()->id); |
@@ -162,7 +162,7 @@ discard block |
||
| 162 | 162 | |
| 163 | 163 | public function activities() |
| 164 | 164 | { |
| 165 | - return $this->team()->map(function ($obj) { |
|
| 165 | + return $this->team()->map(function($obj) { |
|
| 166 | 166 | return $obj->statuses; |
| 167 | 167 | })->flatten(1)->sortByDesc('id')->take(6); |
| 168 | 168 | } |
@@ -22,7 +22,7 @@ |
||
| 22 | 22 | /* |
| 23 | 23 | * Authenticate the user's personal channel... |
| 24 | 24 | */ |
| 25 | - Broadcast::channel('App.User.*', function ($user, $userId) { |
|
| 25 | + Broadcast::channel('App.User.*', function($user, $userId) { |
|
| 26 | 26 | return (int) $user->id === (int) $userId; |
| 27 | 27 | }); |
| 28 | 28 | } |
@@ -49,7 +49,7 @@ discard block |
||
| 49 | 49 | Route::group([ |
| 50 | 50 | 'middleware' => 'web', |
| 51 | 51 | 'namespace' => $this->namespace, |
| 52 | - ], function ($router) { |
|
| 52 | + ], function($router) { |
|
| 53 | 53 | require base_path('routes/web.php'); |
| 54 | 54 | }); |
| 55 | 55 | } |
@@ -65,7 +65,7 @@ discard block |
||
| 65 | 65 | 'middleware' => 'api', |
| 66 | 66 | 'namespace' => $this->namespace, |
| 67 | 67 | 'prefix' => 'api', |
| 68 | - ], function ($router) { |
|
| 68 | + ], function($router) { |
|
| 69 | 69 | require base_path('routes/api.php'); |
| 70 | 70 | }); |
| 71 | 71 | } |
@@ -52,7 +52,7 @@ discard block |
||
| 52 | 52 | * |
| 53 | 53 | * @param \Illuminate\Http\Request $request |
| 54 | 54 | * |
| 55 | - * @return \Illuminate\Http\Response |
|
| 55 | + * @return \Illuminate\Http\RedirectResponse |
|
| 56 | 56 | */ |
| 57 | 57 | public function store(Request $request) |
| 58 | 58 | { |
@@ -65,7 +65,6 @@ discard block |
||
| 65 | 65 | /** |
| 66 | 66 | * Display the specified resource. |
| 67 | 67 | * |
| 68 | - * @param int $id |
|
| 69 | 68 | * |
| 70 | 69 | * @return \Illuminate\Http\Response |
| 71 | 70 | */ |
@@ -82,7 +81,6 @@ discard block |
||
| 82 | 81 | /** |
| 83 | 82 | * Show the form for editing the specified resource. |
| 84 | 83 | * |
| 85 | - * @param int $id |
|
| 86 | 84 | * |
| 87 | 85 | * @return \Illuminate\Http\Response |
| 88 | 86 | */ |
@@ -105,9 +103,8 @@ discard block |
||
| 105 | 103 | * Update the specified resource in storage. |
| 106 | 104 | * |
| 107 | 105 | * @param \Illuminate\Http\Request $request |
| 108 | - * @param int $id |
|
| 109 | 106 | * |
| 110 | - * @return \Illuminate\Http\Response |
|
| 107 | + * @return \Illuminate\Http\RedirectResponse |
|
| 111 | 108 | */ |
| 112 | 109 | public function update(Request $request, $slug) |
| 113 | 110 | { |
@@ -13,6 +13,6 @@ |
||
| 13 | 13 | | |
| 14 | 14 | */ |
| 15 | 15 | |
| 16 | -Route::get('/user', function (Request $request) { |
|
| 16 | +Route::get('/user', function(Request $request) { |
|
| 17 | 17 | return $request->user(); |
| 18 | 18 | })->middleware('auth:api'); |
@@ -10,7 +10,7 @@ discard block |
||
| 10 | 10 | | to using a Closure or controller method. Build something great! |
| 11 | 11 | | |
| 12 | 12 | */ |
| 13 | -Route::get('/', function () { |
|
| 13 | +Route::get('/', function() { |
|
| 14 | 14 | return redirect()->route('auth.login'); |
| 15 | 15 | })->name('home'); |
| 16 | 16 | |
@@ -18,7 +18,7 @@ discard block |
||
| 18 | 18 | Route::get('/profile/{username}', 'UserController@show')->name('user.profile'); |
| 19 | 19 | |
| 20 | 20 | Route::get('/logout', 'Auth\AuthController@logout')->name('auth.logout'); |
| 21 | -Route::group(['prefix' => 'auth', 'middleware' => ['guest']], function () { |
|
| 21 | +Route::group(['prefix' => 'auth', 'middleware' => ['guest']], function() { |
|
| 22 | 22 | Route::get('/register', 'Auth\AuthController@register')->name('auth.register'); |
| 23 | 23 | Route::get('/login', 'Auth\AuthController@login')->name('auth.login'); |
| 24 | 24 | Route::get('/dologin', 'Auth\AuthController@dologin')->name('auth.dologin'); |
@@ -26,7 +26,7 @@ discard block |
||
| 26 | 26 | Route::get('/github/callback', 'Auth\AuthController@handleProviderCallback'); |
| 27 | 27 | }); |
| 28 | 28 | |
| 29 | -Route::group(['prefix' => 'product-backlogs'], function () { |
|
| 29 | +Route::group(['prefix' => 'product-backlogs'], function() { |
|
| 30 | 30 | Route::get('/list/{mode?}', 'ProductBacklogController@index')->name('product_backlogs.index'); |
| 31 | 31 | Route::get('/show/{slug}', 'ProductBacklogController@show')->name('product_backlogs.show'); |
| 32 | 32 | Route::get('/create', 'ProductBacklogController@create')->name('product_backlogs.create'); |
@@ -35,7 +35,7 @@ discard block |
||
| 35 | 35 | Route::post('/update/{slug}', 'ProductBacklogController@update')->name('product_backlogs.update'); |
| 36 | 36 | }); |
| 37 | 37 | |
| 38 | -Route::group(['prefix' => 'sprints', 'middleware' => ['sprint.expired', 'global.activities']], function () { |
|
| 38 | +Route::group(['prefix' => 'sprints', 'middleware' => ['sprint.expired', 'global.activities']], function() { |
|
| 39 | 39 | Route::get('/planning/{slug}/issues', 'IssueController@index')->name('issues.index'); |
| 40 | 40 | Route::get('/list/{mode?}/{slug_product_backlog?}', 'SprintController@index')->name('sprints.index'); |
| 41 | 41 | Route::get('/show/{slug}', 'SprintController@show')->name('sprints.show'); |
@@ -46,7 +46,7 @@ discard block |
||
| 46 | 46 | Route::delete('/destroy', 'SprintController@destroy')->name('sprints.delete'); |
| 47 | 47 | }); |
| 48 | 48 | |
| 49 | -Route::group(['prefix' => 'user-stories'], function () { |
|
| 49 | +Route::group(['prefix' => 'user-stories'], function() { |
|
| 50 | 50 | Route::get('/list/{mode?}/{slug_product_backlog?}', 'SprintController@index')->name('user_stories.index'); |
| 51 | 51 | Route::get('/show/{slug}', 'UserStoryController@show')->name('user_stories.show'); |
| 52 | 52 | Route::get('/create/{slug_product_backlog?}', 'UserStoryController@create')->name('user_stories.create'); |
@@ -55,7 +55,7 @@ discard block |
||
| 55 | 55 | Route::post('/update/{slug}', 'UserStoryController@update')->name('user_stories.update'); |
| 56 | 56 | }); |
| 57 | 57 | |
| 58 | -Route::group(['prefix' => 'issues', 'middleware' => ['issue']], function () { |
|
| 58 | +Route::group(['prefix' => 'issues', 'middleware' => ['issue']], function() { |
|
| 59 | 59 | Route::get('/show/{slug}', 'IssueController@show')->name('issues.show'); |
| 60 | 60 | Route::get('/create/{slug_sprint?}/{slug_user_story?}', 'IssueController@create')->name('issues.create'); |
| 61 | 61 | Route::post('/store', 'IssueController@store')->name('issues.store'); |
@@ -65,47 +65,47 @@ discard block |
||
| 65 | 65 | Route::get('/status-update/{slug}/{status}', 'IssueController@statusUpdate')->name('issues.status.update'); |
| 66 | 66 | }); |
| 67 | 67 | |
| 68 | -Route::group(['prefix' => 'user-issue'], function () { |
|
| 68 | +Route::group(['prefix' => 'user-issue'], function() { |
|
| 69 | 69 | Route::get('/list/{username}/{slug_type?}/{mode?}', 'UserIssueController@index')->name('user_issue.index'); |
| 70 | 70 | Route::post('/update/{slug}', 'UserIssueController@update')->name('user_issue.update'); |
| 71 | 71 | }); |
| 72 | 72 | |
| 73 | -Route::group(['prefix' => 'issue-types'], function () { |
|
| 73 | +Route::group(['prefix' => 'issue-types'], function() { |
|
| 74 | 74 | Route::get('/sprint/{slug_sprint}/{slug_type?}', 'IssueTypeController@index')->name('issue_types.index'); |
| 75 | 75 | }); |
| 76 | 76 | |
| 77 | -Route::group(['prefix' => 'commits'], function () { |
|
| 77 | +Route::group(['prefix' => 'commits'], function() { |
|
| 78 | 78 | Route::get('/show/{sha}', 'CommitController@show')->name('commits.show'); |
| 79 | 79 | }); |
| 80 | 80 | |
| 81 | -Route::group(['prefix' => 'notes'], function () { |
|
| 81 | +Route::group(['prefix' => 'notes'], function() { |
|
| 82 | 82 | Route::get('/--------', 'NoteController@store')->name('notes.show'); |
| 83 | 83 | Route::post('/store', 'NoteController@store')->name('notes.store'); |
| 84 | 84 | Route::get('/update/{slug}', 'NoteController@update')->name('notes.update'); |
| 85 | 85 | Route::get('/destroy/{id}', 'NoteController@destroy')->name('notes.destroy'); |
| 86 | 86 | }); |
| 87 | 87 | |
| 88 | -Route::group(['prefix' => 'comments'], function () { |
|
| 88 | +Route::group(['prefix' => 'comments'], function() { |
|
| 89 | 89 | Route::get('/--------', 'CommentController@store')->name('comments.show'); |
| 90 | 90 | Route::post('/store', 'CommentController@store')->name('comments.store'); |
| 91 | 91 | Route::get('/destroy/{id}', 'CommentController@destroy')->name('comments.destroy'); |
| 92 | 92 | }); |
| 93 | 93 | |
| 94 | -Route::group(['prefix' => 'labels'], function () { |
|
| 94 | +Route::group(['prefix' => 'labels'], function() { |
|
| 95 | 95 | Route::get('/{model}/{slug_label?}', 'LabelController@index')->name('labels.index'); |
| 96 | 96 | Route::post('/store', 'LabelController@store')->name('labels.store'); |
| 97 | 97 | }); |
| 98 | 98 | |
| 99 | -Route::group(['prefix' => 'favorites'], function () { |
|
| 99 | +Route::group(['prefix' => 'favorites'], function() { |
|
| 100 | 100 | Route::get('/store/{type}/{id}', 'FavoriteController@store')->name('favorites.store'); |
| 101 | 101 | Route::get('/destroy/{type}/{id}', 'FavoriteController@destroy')->name('favorites.destroy'); |
| 102 | 102 | }); |
| 103 | 103 | |
| 104 | -Route::group(['prefix' => 'attachments'], function () { |
|
| 104 | +Route::group(['prefix' => 'attachments'], function() { |
|
| 105 | 105 | Route::get('/--------', 'AttachmentController@store')->name('attachments.show'); |
| 106 | 106 | Route::post('/store', 'AttachmentController@store')->name('attachments.store'); |
| 107 | 107 | }); |
| 108 | 108 | |
| 109 | -Route::group(['prefix' => 'teams'], function () { |
|
| 109 | +Route::group(['prefix' => 'teams'], function() { |
|
| 110 | 110 | Route::get('/members', 'TeamController@index')->name('team.index'); |
| 111 | 111 | }); |
@@ -13,6 +13,6 @@ |
||
| 13 | 13 | | |
| 14 | 14 | */ |
| 15 | 15 | |
| 16 | -Artisan::command('inspire', function () { |
|
| 16 | +Artisan::command('inspire', function() { |
|
| 17 | 17 | $this->comment(Inspiring::quote()); |
| 18 | 18 | })->describe('Display an inspiring quote'); |
@@ -11,7 +11,7 @@ |
||
| 11 | 11 | | |
| 12 | 12 | */ |
| 13 | 13 | |
| 14 | -$factory->define(GitScrum\User::class, function (Faker\Generator $faker) { |
|
| 14 | +$factory->define(GitScrum\User::class, function(Faker\Generator $faker) { |
|
| 15 | 15 | static $password; |
| 16 | 16 | |
| 17 | 17 | return [ |
@@ -10,7 +10,7 @@ |
||
| 10 | 10 | */ |
| 11 | 11 | public function up() |
| 12 | 12 | { |
| 13 | - Schema::create('favorites', function (Blueprint $table) { |
|
| 13 | + Schema::create('favorites', function(Blueprint $table) { |
|
| 14 | 14 | $table->increments('id'); |
| 15 | 15 | $table->string('favoriteable_type', 45)->nullable(); |
| 16 | 16 | $table->integer('favoriteable_id')->unsigned()->nullable(); |