Completed
Push — master ( 2f9ece...c4baa4 )
by Sherif
05:12 queued 45s
created
src/Modules/Core/Database/Migrations/2016_01_24_123631_initialize.php 1 patch
Indentation   +61 added lines, -61 removed lines patch added patch discarded remove patch
@@ -12,71 +12,71 @@
 block discarded – undo
12 12
 	 */
13 13
 	public function up()
14 14
 	{
15
-        /**
16
-         * Delete previous permissions.
17
-         */
15
+		/**
16
+		 * Delete previous permissions.
17
+		 */
18 18
 		DB::table('permissions')->whereIn('model', ['settings'])->delete();
19 19
 
20 20
 		/**
21
-         * Insert the permissions related to this module.
22
-         */
23
-        DB::table('permissions')->insert(
24
-        	[
25
-        		/**
26
-        		 * Users model permissions.
27
-        		 */
28
-	        	[
29
-	        	'name'       => 'save',
30
-	        	'model'      => 'settings',
31
-	        	'created_at' => \DB::raw('NOW()'),
32
-	        	'updated_at' => \DB::raw('NOW()')
33
-	        	],
34
-	        	[
35
-	        	'name'       => 'find',
36
-	        	'model'      => 'settings',
37
-	        	'created_at' => \DB::raw('NOW()'),
38
-	        	'updated_at' => \DB::raw('NOW()')
39
-	        	],
40
-	        	[
41
-	        	'name'       => 'search',
42
-	        	'model'      => 'settings',
43
-	        	'created_at' => \DB::raw('NOW()'),
44
-	        	'updated_at' => \DB::raw('NOW()')
45
-	        	],
46
-	        	[
47
-	        	'name'       => 'list',
48
-	        	'model'      => 'settings',
49
-	        	'created_at' => \DB::raw('NOW()'),
50
-	        	'updated_at' => \DB::raw('NOW()')
51
-	        	],
52
-	        	[
53
-	        	'name'       => 'findby',
54
-	        	'model'      => 'settings',
55
-	        	'created_at' => \DB::raw('NOW()'),
56
-	        	'updated_at' => \DB::raw('NOW()')
57
-	        	],
58
-	        	[
59
-	        	'name'       => 'first',
60
-	        	'model'      => 'settings',
61
-	        	'created_at' => \DB::raw('NOW()'),
62
-	        	'updated_at' => \DB::raw('NOW()')
63
-	        	],
64
-	        	[
65
-	        	'name'       => 'paginate',
66
-	        	'model'      => 'settings',
67
-	        	'created_at' => \DB::raw('NOW()'),
68
-	        	'updated_at' => \DB::raw('NOW()')
69
-	        	],
70
-	        	[
71
-	        	'name'       => 'paginateby',
72
-	        	'model'      => 'settings',
73
-	        	'created_at' => \DB::raw('NOW()'),
74
-	        	'updated_at' => \DB::raw('NOW()')
75
-	        	]
76
-        	]
77
-        );
21
+		 * Insert the permissions related to this module.
22
+		 */
23
+		DB::table('permissions')->insert(
24
+			[
25
+				/**
26
+				 * Users model permissions.
27
+				 */
28
+				[
29
+				'name'       => 'save',
30
+				'model'      => 'settings',
31
+				'created_at' => \DB::raw('NOW()'),
32
+				'updated_at' => \DB::raw('NOW()')
33
+				],
34
+				[
35
+				'name'       => 'find',
36
+				'model'      => 'settings',
37
+				'created_at' => \DB::raw('NOW()'),
38
+				'updated_at' => \DB::raw('NOW()')
39
+				],
40
+				[
41
+				'name'       => 'search',
42
+				'model'      => 'settings',
43
+				'created_at' => \DB::raw('NOW()'),
44
+				'updated_at' => \DB::raw('NOW()')
45
+				],
46
+				[
47
+				'name'       => 'list',
48
+				'model'      => 'settings',
49
+				'created_at' => \DB::raw('NOW()'),
50
+				'updated_at' => \DB::raw('NOW()')
51
+				],
52
+				[
53
+				'name'       => 'findby',
54
+				'model'      => 'settings',
55
+				'created_at' => \DB::raw('NOW()'),
56
+				'updated_at' => \DB::raw('NOW()')
57
+				],
58
+				[
59
+				'name'       => 'first',
60
+				'model'      => 'settings',
61
+				'created_at' => \DB::raw('NOW()'),
62
+				'updated_at' => \DB::raw('NOW()')
63
+				],
64
+				[
65
+				'name'       => 'paginate',
66
+				'model'      => 'settings',
67
+				'created_at' => \DB::raw('NOW()'),
68
+				'updated_at' => \DB::raw('NOW()')
69
+				],
70
+				[
71
+				'name'       => 'paginateby',
72
+				'model'      => 'settings',
73
+				'created_at' => \DB::raw('NOW()'),
74
+				'updated_at' => \DB::raw('NOW()')
75
+				]
76
+			]
77
+		);
78 78
 
79
-        /**
79
+		/**
80 80
 		 * Assign the permissions to the admin group.
81 81
 		 */
82 82
 		$permissionIds = DB::table('permissions')->whereIn('model', ['settings'])->select('id')->lists('id');
Please login to merge, or discard this patch.
src/Modules/Core/AbstractRepositories/AbstractRepositoryContainer.php 1 patch
Indentation   +29 added lines, -29 removed lines patch added patch discarded remove patch
@@ -4,35 +4,35 @@
 block discarded – undo
4 4
 
5 5
 abstract class AbstractRepositoryContainer implements RepositoryContainerInterface
6 6
 {
7
-    /**
8
-     * Construct the repository class name based on
9
-     * the method name called, search in the 
10
-     * given namespaces for the class and 
11
-     * return an instance.
12
-     * 
13
-     * @param  string $name the called method name
14
-     * @param  array  $arguments the method arguments
15
-     * @return object
16
-     */
7
+	/**
8
+	 * Construct the repository class name based on
9
+	 * the method name called, search in the 
10
+	 * given namespaces for the class and 
11
+	 * return an instance.
12
+	 * 
13
+	 * @param  string $name the called method name
14
+	 * @param  array  $arguments the method arguments
15
+	 * @return object
16
+	 */
17 17
 	public function __call($name, $arguments)
18
-    {
19
-        dd(\Request::header());
20
-    	foreach ($this->getRepoNameSpace() as $repoNameSpace) 
21
-    	{
22
-    		$class = rtrim($repoNameSpace, '\\') . '\\' . ucfirst(str_singular($name)) . 'Repository';
23
-    		if (class_exists($class)) 
24
-    		{
25
-        		return \App::make($class);
26
-    		}
27
-    	}
28
-    }
18
+	{
19
+		dd(\Request::header());
20
+		foreach ($this->getRepoNameSpace() as $repoNameSpace) 
21
+		{
22
+			$class = rtrim($repoNameSpace, '\\') . '\\' . ucfirst(str_singular($name)) . 'Repository';
23
+			if (class_exists($class)) 
24
+			{
25
+				return \App::make($class);
26
+			}
27
+		}
28
+	}
29 29
 
30
-     /**
31
-     * Abstract methods that return the necessary 
32
-     * information (repositories namespaces)
33
-     * needed to preform the previous actions.
34
-     * 
35
-     * @return array
36
-     */
37
-    abstract protected function getRepoNameSpace();
30
+	 /**
31
+	  * Abstract methods that return the necessary 
32
+	  * information (repositories namespaces)
33
+	  * needed to preform the previous actions.
34
+	  * 
35
+	  * @return array
36
+	  */
37
+	abstract protected function getRepoNameSpace();
38 38
 }
39 39
\ No newline at end of file
Please login to merge, or discard this patch.