@@ -38,7 +38,7 @@ discard block |
||
38 | 38 | |
39 | 39 | /** |
40 | 40 | * [render description] |
41 | - * @return json |
|
41 | + * @return string |
|
42 | 42 | */ |
43 | 43 | public function render() |
44 | 44 | { |
@@ -106,7 +106,7 @@ discard block |
||
106 | 106 | /** |
107 | 107 | * [callFunc description] |
108 | 108 | * @param \Closure $closure |
109 | - * @param \EnergieProduction\Subsets\* $class |
|
109 | + * @param Subsets\Subset $class |
|
110 | 110 | */ |
111 | 111 | protected function callFunc(Closure $closure, $class) |
112 | 112 | { |
@@ -9,7 +9,7 @@ |
||
9 | 9 | /** |
10 | 10 | * [__construct description] |
11 | 11 | * @param \EnergieProduction\Chart\Rendered\Rendered $render |
12 | - * @return void |
|
12 | + * @return Rendered |
|
13 | 13 | */ |
14 | 14 | public function __construct(Rendered $render) |
15 | 15 | { |
@@ -11,18 +11,18 @@ |
||
11 | 11 | * @param \EnergieProduction\Chart\Rendered\Rendered $render |
12 | 12 | * @return void |
13 | 13 | */ |
14 | - public function __construct(Rendered $render) |
|
15 | - { |
|
16 | - $this->render = $render; |
|
17 | - } |
|
14 | + public function __construct(Rendered $render) |
|
15 | + { |
|
16 | + $this->render = $render; |
|
17 | + } |
|
18 | 18 | |
19 | 19 | /** |
20 | 20 | * [handle description] |
21 | 21 | * @param string $content |
22 | 22 | * @return array |
23 | 23 | */ |
24 | - public function handle($content) |
|
25 | - { |
|
26 | - return $this->render->handle($content); |
|
27 | - } |
|
24 | + public function handle($content) |
|
25 | + { |
|
26 | + return $this->render->handle($content); |
|
27 | + } |
|
28 | 28 | } |
@@ -9,7 +9,7 @@ |
||
9 | 9 | /** |
10 | 10 | * [__construct description] |
11 | 11 | * @param mixed $class |
12 | - * @return void |
|
12 | + * @return Rendered |
|
13 | 13 | */ |
14 | 14 | public function __construct($class) |
15 | 15 | { |
@@ -11,18 +11,18 @@ |
||
11 | 11 | * @param mixed $class |
12 | 12 | * @return void |
13 | 13 | */ |
14 | - public function __construct($class) |
|
15 | - { |
|
16 | - $this->class = $class; |
|
17 | - } |
|
14 | + public function __construct($class) |
|
15 | + { |
|
16 | + $this->class = $class; |
|
17 | + } |
|
18 | 18 | |
19 | 19 | /** |
20 | 20 | * [__construct description] |
21 | 21 | * @param string $content |
22 | 22 | * @return array |
23 | 23 | */ |
24 | - public function handle($content) |
|
25 | - { |
|
26 | - return [lcfirst(class_basename(get_class($this->class))) => $content]; |
|
27 | - } |
|
24 | + public function handle($content) |
|
25 | + { |
|
26 | + return [lcfirst(class_basename(get_class($this->class))) => $content]; |
|
27 | + } |
|
28 | 28 | } |
@@ -11,18 +11,18 @@ |
||
11 | 11 | * @param \EnergieProduction\Chart\Rendered\Rendered $render |
12 | 12 | * @return void |
13 | 13 | */ |
14 | - public function __construct(Rendered $render) |
|
15 | - { |
|
16 | - $this->render = $render; |
|
17 | - } |
|
14 | + public function __construct(Rendered $render) |
|
15 | + { |
|
16 | + $this->render = $render; |
|
17 | + } |
|
18 | 18 | |
19 | 19 | /** |
20 | 20 | * [handle description] |
21 | 21 | * @param mixed $content |
22 | 22 | * @return array |
23 | 23 | */ |
24 | - public function handle($content) |
|
25 | - { |
|
26 | - return $this->render->handle("#!!" . $content->render() . "!!#"); |
|
27 | - } |
|
24 | + public function handle($content) |
|
25 | + { |
|
26 | + return $this->render->handle("#!!" . $content->render() . "!!#"); |
|
27 | + } |
|
28 | 28 | } |
29 | 29 | \ No newline at end of file |
@@ -4,31 +4,31 @@ |
||
4 | 4 | |
5 | 5 | class Subset implements Rendered { |
6 | 6 | |
7 | - protected $render; |
|
7 | + protected $render; |
|
8 | 8 | |
9 | - /** |
|
10 | - * [__construct description] |
|
11 | - * @param \EnergieProduction\Chart\Rendered\Rendered $render |
|
12 | - * @return void |
|
13 | - */ |
|
14 | - public function __construct(Rendered $render) |
|
15 | - { |
|
16 | - $this->render = $render; |
|
17 | - } |
|
9 | + /** |
|
10 | + * [__construct description] |
|
11 | + * @param \EnergieProduction\Chart\Rendered\Rendered $render |
|
12 | + * @return void |
|
13 | + */ |
|
14 | + public function __construct(Rendered $render) |
|
15 | + { |
|
16 | + $this->render = $render; |
|
17 | + } |
|
18 | 18 | |
19 | - /** |
|
20 | - * [handle description] |
|
21 | - * @param \mixed $content |
|
22 | - * @return array |
|
23 | - */ |
|
24 | - public function handle($content) |
|
25 | - { |
|
26 | - $subset = lcfirst(class_basename(get_class($this->render->class))); |
|
19 | + /** |
|
20 | + * [handle description] |
|
21 | + * @param \mixed $content |
|
22 | + * @return array |
|
23 | + */ |
|
24 | + public function handle($content) |
|
25 | + { |
|
26 | + $subset = lcfirst(class_basename(get_class($this->render->class))); |
|
27 | 27 | |
28 | - if ($subset === 'series' && (! $this->render->class->cascade || starts_with($this->render->class->cascade, 'series.'))) { |
|
29 | - $content = [$content]; |
|
30 | - } |
|
28 | + if ($subset === 'series' && (! $this->render->class->cascade || starts_with($this->render->class->cascade, 'series.'))) { |
|
29 | + $content = [$content]; |
|
30 | + } |
|
31 | 31 | |
32 | - return $this->render->handle($content); |
|
33 | - } |
|
32 | + return $this->render->handle($content); |
|
33 | + } |
|
34 | 34 | } |
35 | 35 | \ No newline at end of file |
@@ -7,27 +7,27 @@ |
||
7 | 7 | |
8 | 8 | class ChartServiceProvider extends ServiceProvider{ |
9 | 9 | |
10 | - /** |
|
11 | - * Indicates if loading of the provider is deferred. |
|
12 | - * |
|
13 | - * @var bool |
|
14 | - */ |
|
15 | - protected $defer = false; |
|
16 | - |
|
17 | - public function boot() |
|
18 | - { |
|
19 | - // |
|
20 | - } |
|
21 | - |
|
22 | - public function register() |
|
23 | - { |
|
24 | - $this->app->bind('chart', function($app) { |
|
25 | - |
|
26 | - $collection = new Collection; |
|
27 | - |
|
28 | - return new Chart($collection); |
|
29 | - }); |
|
30 | - } |
|
10 | + /** |
|
11 | + * Indicates if loading of the provider is deferred. |
|
12 | + * |
|
13 | + * @var bool |
|
14 | + */ |
|
15 | + protected $defer = false; |
|
16 | + |
|
17 | + public function boot() |
|
18 | + { |
|
19 | + // |
|
20 | + } |
|
21 | + |
|
22 | + public function register() |
|
23 | + { |
|
24 | + $this->app->bind('chart', function($app) { |
|
25 | + |
|
26 | + $collection = new Collection; |
|
27 | + |
|
28 | + return new Chart($collection); |
|
29 | + }); |
|
30 | + } |
|
31 | 31 | } |
32 | 32 | |
33 | 33 |
@@ -10,10 +10,10 @@ discard block |
||
10 | 10 | protected $criteriaList; |
11 | 11 | public $cascade = null; |
12 | 12 | |
13 | - /** |
|
14 | - * [__construct description] |
|
15 | - * @return void |
|
16 | - */ |
|
13 | + /** |
|
14 | + * [__construct description] |
|
15 | + * @return void |
|
16 | + */ |
|
17 | 17 | public function __construct() |
18 | 18 | { |
19 | 19 | $this->criteriaList = collect(); |
@@ -46,10 +46,10 @@ discard block |
||
46 | 46 | return $render->handle($formatedSubset); |
47 | 47 | } |
48 | 48 | |
49 | - /** |
|
50 | - * [setCascade description] |
|
51 | - * @param string $cascade |
|
52 | - */ |
|
49 | + /** |
|
50 | + * [setCascade description] |
|
51 | + * @param string $cascade |
|
52 | + */ |
|
53 | 53 | public function setCascade($cascade) |
54 | 54 | { |
55 | 55 | $this->cascade = $cascade; |