Skip to content

Conversation

@awwama
Copy link

@awwama awwama commented Aug 24, 2021

This changes will help to visualization charts for auto aggregated data. Below is example of database structure.

image

And below is sample for data:
image

Sample of code:
(new LineChart()) ->title('Compare Incomes, Expeses and Deposit') ->model('\App\Models\Transaction') // Use Your Model Here ->series(array([ 'label' => 'Cash Deposit', 'filter' => [ 'key' => 'cash_deposit', // State Column for Count Calculation Here ], ],[ 'label' => 'Sum Incomes', 'filter' => [ 'key' => 'sum_incomes', // State Column for Count Calculation Here ], ],[ 'label' => 'Sum Expenses', 'filter' => [ 'key' => 'sum_expenses', // State Column for Count Calculation Here ], ])) ->width('full'),

And the result will be:
image

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant