felideo/cnab_php

此包最新版本(1.4.1)没有可用的许可证信息。

用于创建CNAB格式的发送文件和返回文件的项目

维护者

详细信息

github.com/felideo/CnabPHP

源代码

安装: 12

依赖: 0

建议者: 0

安全: 0

星星: 0

观察者: 2

分支: 201

1.4.1 2018-03-01 19:47 UTC

README

Join the chat at https://gitter.im/andersondanilo/CnabPHP

Build Status Latest Stable Version Latest Unstable Version Code Climate Test Coverage

用于创建CNAB格式的发送文件和返回文件的项目,通常用于银行中的银行汇票。

功能

  • 读取和生成CNAB 240和400格式的返回文件和发送文件

安装

Composer

如果您已经熟悉 Composer,请将以下依赖项添加到您的 composer.json 文件中的 "require" 指令

"andersondanilo/cnab_php": "1.3.*"

如何使用

读取返回文件

$cnabFactory = new Cnab\Factory();
$arquivo = $cnabFactory->createRetorno('AQUI VAI O CAMINHO DO ARQUIVO DE RETORNO, EX: RET1010.RET');
$detalhes = $arquivo->listDetalhes();
foreach($detalhes as $detalhe) {
    if($detalhe->getValorRecebido() > 0) {
        $nossoNumero   = $detalhe->getNossoNumero();
        $valorRecebido = $detalhe->getValorRecebido();
        $dataPagamento = $detalhe->getDataOcorrencia();
        $carteira      = $detalhe->getCarteira();
        // você já tem as informações, pode dar baixa no boleto aqui
    }
}

创建发送文件

请参考wiki: https://github.com/andersondanilo/CnabPHP/wiki/Criando-um-arquivo-de-remessa

如何贡献

您可以通过测试(单元测试或手动测试)或通过cnab_yaml项目(https://github.com/andersondanilo/cnab_yaml)(cnab_php使用)来适配其他银行的格式。 阅读wiki

该项目使用Waffle来管理新发送文件和返回文件实现的状态

Stories in Ready

许可证

此项目采用MIT许可证