|
1
|
|
|
<?php |
|
2
|
|
|
|
|
3
|
|
|
/** |
|
4
|
|
|
* This file is part of the Spryker Commerce OS. |
|
5
|
|
|
* For full license information, please view the LICENSE file that was distributed with this source code. |
|
6
|
|
|
*/ |
|
7
|
|
|
|
|
8
|
|
|
declare(strict_types = 1); |
|
9
|
|
|
|
|
10
|
|
|
namespace Pyz\Zed\ChartGui; |
|
11
|
|
|
|
|
12
|
|
|
use Pyz\Zed\ExampleChart\Plugin\ExampleChartPlugin; |
|
13
|
|
|
use Spryker\Zed\ChartGui\ChartGuiDependencyProvider as SprykerChartGuiDependencyProvider; |
|
14
|
|
|
use Spryker\Zed\ChartGui\Communication\Plugin\Twig\Chart\BarChartTwigPlugin; |
|
15
|
|
|
use Spryker\Zed\ChartGui\Communication\Plugin\Twig\Chart\ChartTwigPlugin; |
|
16
|
|
|
use Spryker\Zed\ChartGui\Communication\Plugin\Twig\Chart\LineChartTwigPlugin; |
|
17
|
|
|
use Spryker\Zed\ChartGui\Communication\Plugin\Twig\Chart\PieChartTwigPlugin; |
|
18
|
|
|
use Spryker\Zed\SalesStatistics\Communication\Plugin\CountOrderChartPlugin; |
|
19
|
|
|
use Spryker\Zed\SalesStatistics\Communication\Plugin\StatusOrderChartPlugin; |
|
20
|
|
|
use Spryker\Zed\SalesStatistics\Communication\Plugin\TopOrdersChartPlugin; |
|
21
|
|
|
|
|
22
|
|
|
class ChartGuiDependencyProvider extends SprykerChartGuiDependencyProvider |
|
23
|
|
|
{ |
|
24
|
|
|
/** |
|
25
|
|
|
* @return array<\Spryker\Shared\Chart\Dependency\Plugin\ChartPluginInterface> |
|
26
|
|
|
*/ |
|
27
|
|
|
protected function getChartPlugins(): array |
|
28
|
|
|
{ |
|
29
|
|
|
return [ |
|
30
|
|
|
new CountOrderChartPlugin(), |
|
31
|
|
|
new StatusOrderChartPlugin(), |
|
32
|
|
|
new TopOrdersChartPlugin(), |
|
33
|
|
|
new ExampleChartPlugin(), |
|
34
|
|
|
]; |
|
35
|
|
|
} |
|
36
|
|
|
|
|
37
|
|
|
/** |
|
38
|
|
|
* @return array<\Spryker\Shared\Chart\Dependency\Plugin\TwigChartFunctionPluginInterface> |
|
39
|
|
|
*/ |
|
40
|
|
|
protected function getTwigChartFunctionPlugins(): array |
|
41
|
|
|
{ |
|
42
|
|
|
return [ |
|
43
|
|
|
new BarChartTwigPlugin(), |
|
44
|
|
|
new ChartTwigPlugin(), |
|
45
|
|
|
new LineChartTwigPlugin(), |
|
46
|
|
|
new PieChartTwigPlugin(), |
|
47
|
|
|
]; |
|
48
|
|
|
} |
|
49
|
|
|
} |
|
50
|
|
|
|