arsoft-modules / keuangan
用于管理财务数据的模块,从日记账、财务账户管理到相关财务报告和分析
dev-main
2021-04-23 07:13 UTC
Requires
- awobaz/compoships: ^2.1
This package is auto-updated.
Last update: 2024-09-26 14:16:21 UTC
README
用于管理从日记账、财务账户到相关财务报告的财务数据包
配置
为了最优使用此包,请注意以下要点
-
表格需求
- dk_akun
- dk_akun_cashflow
- dk_akun_saldo
- dk_hierarki_dua
- dk_hierarki_satu
- dk_hierarki_subclass
- dk_jurnal
- dk_jurnal_detail
- dk_periode_keuangan
-
在Laravel中配置config/database.php
'connections' => [ ... 'mysql' => [ ... 'strict' => false, ... ], ],
安装
使用composer安装包
composer require arsoft-modules/keuangan
使用方法
日记账报告
use ArsoftModules\Keuangan\Keuangan; $arsKeuangan = new Keuangan(); $reportJournal = $arsKeuangan->reportJournal( 'MB0000001', '2021-04-01', '2021-04-30', 'general' ); if ($reportJournal->getStatus() !== 'success') { throw new Exception($reportJournal->getErrorMessage(), 1); } $reportJournal = $reportJournal->getData();
资产负债表报告
use ArsoftModules\Keuangan\Keuangan; $arsKeuangan = new Keuangan(); $reportBalanceSheet = $arsKeuangan->reportBalanceSheet( '2021-04-30', 'month' ); if ($reportBalanceSheet->getStatus() !== 'success') { throw new Exception($reportBalanceSheet->getErrorMessage(), 1); } $reportBalanceSheet = $reportBalanceSheet->getData();
损益表报告
use ArsoftModules\Keuangan\Keuangan; $arsKeuangan = new Keuangan(); $reportIncomeStatement = $arsKeuangan->reportIncomeStatement( '2020-07-30', 'month' ); if ($reportIncomeStatement->getStatus() !== 'success') { throw new Exception($reportIncomeStatement->getErrorMessage(), 1); } $reportIncomeStatement = $reportIncomeStatement->getData();
总账报告
use ArsoftModules\Keuangan\Keuangan; $arsKeuangan = new Keuangan(); $reportLedger = $arsKeuangan->reportLedger( 'MB0000001', 1, '2021-03-25' ); if ($reportLedger->getStatus() !== 'success') { throw new Exception($reportLedger->getErrorMessage(), 1); } $reportLedger = $reportLedger->getData();
资产与ETA分析
use ArsoftModules\Keuangan\Keuangan; $arsKeuangan = new Keuangan(); $reportAsetEta = $arsKeuangan->reportAsetEta( 'MB0000001', '2020-01', '2021-03', 'month' ); if ($reportAsetEta->getStatus() !== 'success') { throw new Exception($reportAsetEta->getErrorMessage(), 1); } $reportAsetEta = $reportAsetEta->getData();
现金流分析
use ArsoftModules\Keuangan\Keuangan; $arsKeuangan = new Keuangan(); $reportCashflow = $arsKeuangan->reportCashflow( 'MB0000001', '2020-01', '2020-12', 'month' ); if ($reportCashflow->getStatus() !== 'success') { throw new Exception($reportCashflow->getErrorMessage(), 1); } $reportCashflow = $reportCashflow->getData();
共同规模分析
use ArsoftModules\Keuangan\Keuangan; $arsKeuangan = new Keuangan(); $reportCommonSize = $arsKeuangan->reportCommonSize( 'MB0000001', '2021-01', '2021-04', 'month' ); if ($reportCommonSize->getStatus() !== 'success') { throw new Exception($reportCommonSize->getErrorMessage(), 1); } $reportCommonSize = $reportCommonSize->getData();
净利润与自由现金流分析
use ArsoftModules\Keuangan\Keuangan; $arsKeuangan = new Keuangan(); $reportNetProfitOcf = $arsKeuangan->reportNetProfitOcf( '2021-01', '2021-04', 'month' ); if ($reportNetProfitOcf->getStatus() !== 'success') { throw new Exception($reportNetProfitOcf->getErrorMessage(), 1); } $reportNetProfitOcf = $reportNetProfitOcf->getData();
流动性比率分析
use ArsoftModules\Keuangan\Keuangan; $arsKeuangan = new Keuangan(); $reportLiquidityRatio = $arsKeuangan->reportLiquidityRatio( 'MB0000001', '2021-01', '2021-04', 'month' ); if ($reportLiquidityRatio->getStatus() !== 'success') { throw new Exception($reportLiquidityRatio->getErrorMessage(), 1); } $reportLiquidityRatio = $reportLiquidityRatio->getData();
股东权益回报率分析
use ArsoftModules\Keuangan\Keuangan; $arsKeuangan = new Keuangan(); $reportReturnEquity = $arsKeuangan->reportReturnEquity( '2020' ); if ($reportReturnEquity->getStatus() !== 'success') { throw new Exception($reportReturnEquity->getErrorMessage(), 1); } $reportReturnEquity = $reportReturnEquity->getData();