Completed
Push — master ( 456045...7e51b9 )
by Sherif
04:39
created
src/Modules/Acl/AclGroup.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -3,7 +3,7 @@  discard block
 block discarded – undo
3 3
 use Illuminate\Database\Eloquent\Model;
4 4
 use Illuminate\Database\Eloquent\SoftDeletes;
5 5
 
6
-class AclGroup extends Model{
6
+class AclGroup extends Model {
7 7
 
8 8
     use SoftDeletes;
9 9
     protected $table    = 'groups';
@@ -29,12 +29,12 @@  discard block
 block discarded – undo
29 29
 
30 30
     public function users()
31 31
     {
32
-        return $this->belongsToMany('\App\Modules\Acl\AclUser','users_groups','group_id','user_id')->whereNull('users_groups.deleted_at')->withTimestamps();
32
+        return $this->belongsToMany('\App\Modules\Acl\AclUser', 'users_groups', 'group_id', 'user_id')->whereNull('users_groups.deleted_at')->withTimestamps();
33 33
     }
34 34
 
35 35
     public function permissions()
36 36
     {
37
-        return $this->belongsToMany('\App\Modules\Acl\AclPermission','groups_permissions','group_id','permission_id')->whereNull('groups_permissions.deleted_at')->withTimestamps();
37
+        return $this->belongsToMany('\App\Modules\Acl\AclPermission', 'groups_permissions', 'group_id', 'permission_id')->whereNull('groups_permissions.deleted_at')->withTimestamps();
38 38
     }
39 39
 
40 40
     public static function boot()
Please login to merge, or discard this patch.
src/Modules/Acl/Http/Controllers/GroupsController.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -13,14 +13,14 @@
 block discarded – undo
13 13
      * to preform actions like (add, edit ... etc).
14 14
      * @var string
15 15
      */
16
-    protected $model               = 'groups';
16
+    protected $model = 'groups';
17 17
 
18 18
     /**
19 19
      * The validations rules used by the base api controller
20 20
      * to check before add.
21 21
      * @var array
22 22
      */
23
-    protected $validationRules  = [
23
+    protected $validationRules = [
24 24
     'name' => 'required|string|max:100|unique:groups,name,{id}'
25 25
     ];
26 26
 
Please login to merge, or discard this patch.
src/Modules/Acl/Database/Migrations/2016_01_05_130506_permissions.php 1 patch
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -12,15 +12,15 @@
 block discarded – undo
12 12
 	 */
13 13
 	public function up()
14 14
 	{
15
-        Schema::create('permissions', function (Blueprint $table) {
15
+        Schema::create('permissions', function(Blueprint $table) {
16 16
             $table->increments('id');
17
-            $table->string('name',100);
18
-            $table->string('model',100);
17
+            $table->string('name', 100);
18
+            $table->string('model', 100);
19 19
             $table->softDeletes();
20 20
             $table->timestamps();
21 21
             $table->unique(array('name', 'model'));
22 22
         });
23
-        Schema::create('groups_permissions', function (Blueprint $table) {
23
+        Schema::create('groups_permissions', function(Blueprint $table) {
24 24
             $table->increments('id');
25 25
             $table->integer('group_id');
26 26
             $table->integer('permission_id');
Please login to merge, or discard this patch.
src/Modules/Acl/Database/Migrations/2015_12_22_145819_groups.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -12,14 +12,14 @@
 block discarded – undo
12 12
 	 */
13 13
 	public function up()
14 14
 	{
15
-		Schema::create('groups', function (Blueprint $table) {
15
+		Schema::create('groups', function(Blueprint $table) {
16 16
             $table->increments('id');
17
-            $table->string('name',100)->unique();
17
+            $table->string('name', 100)->unique();
18 18
             $table->softDeletes();
19 19
             $table->timestamps();
20 20
         });
21 21
         
22
-        Schema::create('users_groups', function (Blueprint $table) {
22
+        Schema::create('users_groups', function(Blueprint $table) {
23 23
             $table->increments('id');
24 24
             $table->integer('user_id');
25 25
             $table->integer('group_id');
Please login to merge, or discard this patch.
src/Modules/Acl/AclPermission.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -29,7 +29,7 @@
 block discarded – undo
29 29
     
30 30
     public function groups()
31 31
     {
32
-        return $this->belongsToMany('\App\Modules\Acl\AclGroup','groups_permissions','permission_id','group_id')->whereNull('groups_permissions.deleted_at')->withTimestamps();
32
+        return $this->belongsToMany('\App\Modules\Acl\AclGroup', 'groups_permissions', 'permission_id', 'group_id')->whereNull('groups_permissions.deleted_at')->withTimestamps();
33 33
     }
34 34
 
35 35
     public static function boot()
Please login to merge, or discard this patch.
src/Modules/Reporting/Database/Migrations/2016_01_19_112350_reports.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -12,10 +12,10 @@
 block discarded – undo
12 12
 	 */
13 13
 	public function up()
14 14
 	{
15
-		Schema::create('reports', function (Blueprint $table) {
15
+		Schema::create('reports', function(Blueprint $table) {
16 16
 			$table->increments('id');
17
-			$table->string('report_name',100);
18
-			$table->string('view_name',100);
17
+			$table->string('report_name', 100);
18
+			$table->string('view_name', 100);
19 19
 			$table->softDeletes();
20 20
 			$table->timestamps();
21 21
         });
Please login to merge, or discard this patch.
src/Modules/Reporting/Report.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -3,7 +3,7 @@  discard block
 block discarded – undo
3 3
 use Illuminate\Database\Eloquent\Model;
4 4
 use Illuminate\Database\Eloquent\SoftDeletes;
5 5
 
6
-class Report extends Model{
6
+class Report extends Model {
7 7
 
8 8
     use SoftDeletes;
9 9
 	protected $table    = 'reports';
@@ -11,7 +11,7 @@  discard block
 block discarded – undo
11 11
 	protected $hidden   = ['deleted_at'];
12 12
 	protected $guarded  = ['id'];
13 13
 	protected $fillable = ['report_name', 'view_name'];
14
-    public $searchable  = ['report_name', 'view_name'];
14
+    public $searchable = ['report_name', 'view_name'];
15 15
 
16 16
 	public function getCreatedAtAttribute($value)
17 17
     {
Please login to merge, or discard this patch.
src/Modules/Reporting/Providers/RouteServiceProvider.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -54,7 +54,7 @@  discard block
 block discarded – undo
54 54
         Route::group([
55 55
             'middleware' => 'web',
56 56
             'namespace'  => $this->namespace,
57
-        ], function ($router) {
57
+        ], function($router) {
58 58
             require module_path('reporting', 'Routes/web.php');
59 59
         });
60 60
     }
@@ -72,7 +72,7 @@  discard block
 block discarded – undo
72 72
             'middleware' => 'api',
73 73
             'namespace'  => $this->namespace,
74 74
             'prefix'     => 'api',
75
-        ], function ($router) {
75
+        ], function($router) {
76 76
             require module_path('reporting', 'Routes/api.php');
77 77
         });
78 78
     }
Please login to merge, or discard this patch.
src/Modules/Reporting/Database/Seeds/AssignRelationsSeeder.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -21,7 +21,7 @@
 block discarded – undo
21 21
         /**
22 22
          * Assign the permissions to the admin group.
23 23
          */
24
-        \DB::table('permissions')->orderBy('created_at', 'asc')->whereIn('model', ['reports'])->each(function ($permission) use ($adminGroupId) {
24
+        \DB::table('permissions')->orderBy('created_at', 'asc')->whereIn('model', ['reports'])->each(function($permission) use ($adminGroupId) {
25 25
         	\DB::table('groups_permissions')->insert(
26 26
 				[
27 27
 				'permission_id' => $permission->id,
Please login to merge, or discard this patch.