upgraded apexchart package

This commit is contained in:
Denis Duliçi
2022-06-16 17:57:43 +03:00
parent c06822f8fa
commit 93be1cc132
6 changed files with 44 additions and 45 deletions

View File

@ -2,7 +2,7 @@
namespace App\Abstracts;
use Akaunting\Apexcharts\Charts as Apexcharts;
use Akaunting\Apexcharts\Chart;
use App\Events\Report\DataLoaded;
use App\Events\Report\DataLoading;
use App\Events\Report\FilterApplying;
@ -14,7 +14,6 @@ use App\Exports\Common\Reports as Export;
use App\Models\Common\Report as Model;
use App\Models\Document\Document;
use App\Models\Setting\Category;
use App\Traits\Charts;
use App\Traits\DateTime;
use App\Traits\SearchString;
use App\Traits\Translations;
@ -24,7 +23,7 @@ use Illuminate\Support\Str;
abstract class Report
{
use Charts, DateTime, SearchString, Translations;
use DateTime, SearchString, Translations;
public $model;
@ -176,7 +175,7 @@ abstract class Report
public function getBarChart($table_key)
{
$chart = new Apexcharts();
$chart = new Chart();
if (empty($this->chart)) {
return $chart;
@ -194,7 +193,7 @@ abstract class Report
public function getDonutChart($table_key)
{
$chart = new Apexcharts();
$chart = new Chart();
if (empty($this->chart)) {
return $chart;

View File

@ -2,7 +2,7 @@
namespace App\Traits;
use Akaunting\Apexcharts\Charts as Apexcharts;
use Akaunting\Apexcharts\Chart;
trait Charts
{
@ -54,7 +54,7 @@ trait Charts
$labels[$id] = $this->donut['labels'][$id];
}
$chart = new Apexcharts();
$chart = new Chart();
$chart->setType('donut')
->setWidth($width)
@ -75,7 +75,7 @@ trait Charts
public function getBarChart($name, $width = '100%', $height = 160)
{
$chart = new Apexcharts();
$chart = new Chart();
$chart->setType('bar')
->setWidth($width)

View File

@ -2,7 +2,7 @@
namespace App\Widgets;
use Akaunting\Apexcharts\Charts as Apexcharts;
use Akaunting\Apexcharts\Chart;
use App\Abstracts\Widget;
use App\Models\Banking\Transaction;
use App\Traits\Currencies;
@ -55,7 +55,7 @@ class CashFlow extends Widget
],
];
$chart = new Apexcharts();
$chart = new Chart();
$chart->setType('line')
->setOptions($options)

View File

@ -6,7 +6,7 @@ use App\Abstracts\Widget;
use App\Utilities\Recurring;
use App\Models\Document\Document;
use App\Models\Banking\Transaction;
use Akaunting\Apexcharts\Charts as Apexcharts;
use Akaunting\Apexcharts\Chart;
use App\Traits\Currencies;
use App\Traits\DateTime;
use App\Utilities\Date;
@ -39,7 +39,7 @@ class ProfitLoss extends Widget
$colors = $this->getColors();
$chart = new Apexcharts();
$chart = new Chart();
$options = [
'legend' => [