Commit d150f8a6 authored by Jonathan H. Wage's avatar Jonathan H. Wage

Fixing issue with 4 spaces being hardcoded and not replaced with the configured amount of spaces

parent d6565667
...@@ -98,7 +98,7 @@ class EntityGenerator ...@@ -98,7 +98,7 @@ class EntityGenerator
*/ */
public function <methodName>() public function <methodName>()
{ {
return $this-><fieldName>; <spaces>return $this-><fieldName>;
}'; }';
private static $_setMethodTemplate = private static $_setMethodTemplate =
...@@ -109,7 +109,7 @@ public function <methodName>() ...@@ -109,7 +109,7 @@ public function <methodName>()
*/ */
public function <methodName>(<methodTypeHint>$<variableName>) public function <methodName>(<methodTypeHint>$<variableName>)
{ {
$this-><fieldName> = $<variableName>; <spaces>$this-><fieldName> = $<variableName>;
}'; }';
private static $_addMethodTemplate = private static $_addMethodTemplate =
...@@ -120,7 +120,7 @@ public function <methodName>(<methodTypeHint>$<variableName>) ...@@ -120,7 +120,7 @@ public function <methodName>(<methodTypeHint>$<variableName>)
*/ */
public function <methodName>(<methodTypeHint>$<variableName>) public function <methodName>(<methodTypeHint>$<variableName>)
{ {
$this-><fieldName>[] = $<variableName>; <spaces>$this-><fieldName>[] = $<variableName>;
}'; }';
private static $_lifecycleCallbackMethodTemplate = private static $_lifecycleCallbackMethodTemplate =
...@@ -129,7 +129,7 @@ public function <methodName>(<methodTypeHint>$<variableName>) ...@@ -129,7 +129,7 @@ public function <methodName>(<methodTypeHint>$<variableName>)
*/ */
public function <methodName>() public function <methodName>()
{ {
// Add your code here <spaces>// Add your code here
}'; }';
/** /**
...@@ -192,7 +192,8 @@ public function <methodName>() ...@@ -192,7 +192,8 @@ public function <methodName>()
'<use>', '<use>',
'<entityAnnotation>', '<entityAnnotation>',
'<entityClassName>', '<entityClassName>',
'<entityBody>' '<entityBody>',
'<spaces>'
); );
$replacements = array( $replacements = array(
...@@ -200,7 +201,8 @@ public function <methodName>() ...@@ -200,7 +201,8 @@ public function <methodName>()
$this->_generateEntityUse($metadata), $this->_generateEntityUse($metadata),
$this->_generateEntityDocBlock($metadata), $this->_generateEntityDocBlock($metadata),
$this->_generateEntityClassName($metadata), $this->_generateEntityClassName($metadata),
$this->_generateEntityBody($metadata) $this->_generateEntityBody($metadata),
$this->_spaces
); );
return str_replace($placeHolders, $replacements, self::$_classTemplate); return str_replace($placeHolders, $replacements, self::$_classTemplate);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment