@@ -71,10 +71,10 @@ discard block |
||
71 | 71 | * @param string $method |
72 | 72 | * @return string |
73 | 73 | */ |
74 | - function generateForm($entity,$method = 'post') |
|
74 | + function generateForm($entity, $method = 'post') |
|
75 | 75 | { |
76 | 76 | $html = '<form method="post" action="#"> |
77 | - <input type="hidden" name="__method" value="'.$method.'">'; |
|
77 | + <input type="hidden" name="__method" value="'.$method . '">'; |
|
78 | 78 | $html .= $this->getInputs($entity); |
79 | 79 | $html .= '</form>'; |
80 | 80 | return $html; |
@@ -86,7 +86,7 @@ discard block |
||
86 | 86 | */ |
87 | 87 | function getFillables($entity) |
88 | 88 | { |
89 | - if(!empty($entity->getFillable())) |
|
89 | + if (!empty($entity->getFillable())) |
|
90 | 90 | return $entity->getFillable(); |
91 | 91 | |
92 | 92 | $columns = \Schema::getColumnListing($entity->getTable()); |
@@ -107,7 +107,7 @@ discard block |
||
107 | 107 | */ |
108 | 108 | function getInputs($entity) |
109 | 109 | { |
110 | - if($this->inputs) |
|
110 | + if ($this->inputs) |
|
111 | 111 | return $this->inputs; |
112 | 112 | |
113 | 113 | return $this->generateInputs($entity); |
@@ -122,7 +122,7 @@ discard block |
||
122 | 122 | $html = ''; |
123 | 123 | foreach ($this->getFillables($entity) as $fillable) |
124 | 124 | { |
125 | - $column = DB::connection()->getDoctrineColumn($entity->getTable(),$fillable); |
|
125 | + $column = DB::connection()->getDoctrineColumn($entity->getTable(), $fillable); |
|
126 | 126 | |
127 | 127 | $html .= $this->generateFormInput($column); |
128 | 128 | } |
@@ -86,8 +86,9 @@ discard block |
||
86 | 86 | */ |
87 | 87 | function getFillables($entity) |
88 | 88 | { |
89 | - if(!empty($entity->getFillable())) |
|
90 | - return $entity->getFillable(); |
|
89 | + if(!empty($entity->getFillable())) { |
|
90 | + return $entity->getFillable(); |
|
91 | + } |
|
91 | 92 | |
92 | 93 | $columns = \Schema::getColumnListing($entity->getTable()); |
93 | 94 | |
@@ -107,8 +108,9 @@ discard block |
||
107 | 108 | */ |
108 | 109 | function getInputs($entity) |
109 | 110 | { |
110 | - if($this->inputs) |
|
111 | - return $this->inputs; |
|
111 | + if($this->inputs) { |
|
112 | + return $this->inputs; |
|
113 | + } |
|
112 | 114 | |
113 | 115 | return $this->generateInputs($entity); |
114 | 116 | } |