Passed
Push — 0.3.0 ( 0d73f1...9a02d7 )
by Anton
04:10
created
www/engine/System/Classes/Modules/Entitizer/Utils/Treeview.php 1 patch
Indentation   +8 added lines, -8 removed lines patch added patch discarded remove patch
@@ -12,7 +12,7 @@  discard block
 block discarded – undo
12 12
 
13 13
 			return (0 !== $parent_id) ? (("JOIN " . static::$table_relations . " rel ") .
14 14
 
15
-			       ("ON rel.ancestor = " . $parent_id . " AND rel.descendant = ent.id AND rel.depth >= 1")) :
15
+				   ("ON rel.ancestor = " . $parent_id . " AND rel.descendant = ent.id AND rel.depth >= 1")) :
16 16
 
17 17
 				   ("JOIN " . static::$table_relations . " rel ON rel.descendant = ent.id");
18 18
 		}
@@ -23,13 +23,13 @@  discard block
 block discarded – undo
23 23
 
24 24
 			return ("SELECT " . $this->getSelection() . ", COALESCE(par.ancestor, 0) as parent_id ") .
25 25
 
26
-			       ("FROM " . static::$table . " ent " . $this->getQueryJoin($parent_id) . " ") .
26
+				   ("FROM " . static::$table . " ent " . $this->getQueryJoin($parent_id) . " ") .
27 27
 
28
-			       ("LEFT JOIN " . static::$table_relations . " par ON par.descendant = ent.id AND par.depth = 1 ") .
28
+				   ("LEFT JOIN " . static::$table_relations . " par ON par.descendant = ent.id AND par.depth = 1 ") .
29 29
 
30
-			       (('' !== ($condition = $this->getCondition($config))) ? ("WHERE " . $condition . " ") : "") .
30
+				   (('' !== ($condition = $this->getCondition($config))) ? ("WHERE " . $condition . " ") : "") .
31 31
 
32
-			       ("GROUP BY ent.id ORDER BY MAX(rel.depth) ASC, " . $this->getOrderBy($order_by));
32
+				   ("GROUP BY ent.id ORDER BY MAX(rel.depth) ASC, " . $this->getOrderBy($order_by));
33 33
 		}
34 34
 
35 35
 		# Get count query
@@ -38,7 +38,7 @@  discard block
 block discarded – undo
38 38
 
39 39
 			return ("SELECT COUNT(DISTINCT ent.id) as count FROM " . static::$table . " ent ") .
40 40
 
41
-			       $this->getQueryJoin($parent_id);
41
+				   $this->getQueryJoin($parent_id);
42 42
 		}
43 43
 
44 44
 		# Get depth query
@@ -47,7 +47,7 @@  discard block
 block discarded – undo
47 47
 
48 48
 			$query = ("SELECT COUNT(DISTINCT rel.depth) as depth FROM " . static::$table . " ent ") .
49 49
 
50
-			         $this->getQueryJoin($parent_id);
50
+					 $this->getQueryJoin($parent_id);
51 51
 
52 52
 			# ------------------------
53 53
 
@@ -128,7 +128,7 @@  discard block
 block discarded – undo
128 128
 
129 129
 			$query = ("SELECT " . $this->getSelection() . " FROM " . static::$table . " ent ") .
130 130
 
131
-			         ("JOIN " . static::$table_relations . " rel ON rel.ancestor = ent.id ") .
131
+					 ("JOIN " . static::$table_relations . " rel ON rel.ancestor = ent.id ") .
132 132
 
133 133
 					 ("WHERE rel.descendant = " . $parent_id . " ORDER BY rel.depth DESC");
134 134
 
Please login to merge, or discard this patch.