定制 emadshirzad/iranian-bank-list-laravel 二次开发

按需修改功能、优化性能、对接业务系统,提供一站式技术支持

邮箱:yvsm@zunyunkeji.com | QQ:316430983 | 微信:yvsm316

emadshirzad/iranian-bank-list-laravel

最新稳定版本:v1.0.1

Composer 安装命令:

composer require emadshirzad/iranian-bank-list-laravel

包简介

list all banks into laravel

README 文档

README

A comprehensive Laravel package for Iranian banking operations including bank identification, IBAN validation, and card number verification.

Features

  • Complete list of Iranian banks with details
  • IBAN validation using mod-97 algorithm
  • Iranian card number validation using Luhn algorithm
  • Bank identification by IBAN, card number, or name
  • FilamentPHP integration support
  • Easy-to-use facade and model interfaces

Installation

  1. Install the package via Composer:

    composer require emadshirzad/iranian-bank-list-laravel
  2. Publish the configuration file:

    php artisan vendor:publish --tag=iranian-bank-config
  3. Run the migration to create the banks table:

    php artisan migrate
  4. Seed the database with bank data:

    php artisan db:seed --class=IranianBankSeeder

Usage

Getting All Banks

use EmadShirzad\IranianBank\Facades\IranianBank;

// Using facade
$banks = IranianBank::getBanks();

// Or using model directly
use App\Models\IranianBank;
$banks = IranianBank::all();

Bank Identification

Get bank details by IBAN:

use EmadShirzad\IranianBank\Facades\IranianBank;

$bank = IranianBank::getBankByIban('IR123456789012345678901234567890');
// Returns bank details or null if not found

Get bank details by card number:

use EmadShirzad\IranianBank\Facades\IranianBank;

$bank = IranianBank::getBankByCardNumber('6037991234567890');
// Returns bank details or null if not found

Find bank by name:

use EmadShirzad\IranianBank\Facades\IranianBank;

$bank = IranianBank::findByName('melli');
// Returns bank details or null if not found

Advanced Search Methods

Find bank by full card number using regex:

use EmadShirzad\IranianBank\Facades\IranianBank;

$bank = IranianBank::findByCardNumber('6037991234567890');
// Returns bank details or null if not found

Find bank by full IBAN using regex:

use EmadShirzad\IranianBank\Facades\IranianBank;

$bank = IranianBank::findByIban('IR123456789012345678901234567890');
// Returns bank details or null if not found

Validation Methods

Validate IBAN:

use EmadShirzad\IranianBank\Facades\IranianBank;

$isValid = IranianBank::validateIban('IR123456789012345678901234567890');
// Returns true or false

Validate Iranian card number using Luhn algorithm:

use EmadShirzad\IranianBank\Facades\IranianBank;

$isValid = IranianBank::validateIranianCard('6037991234567890');
// Returns true or false

Validate IBAN checksum using mod-97 algorithm:

use EmadShirzad\IranianBank\Facades\IranianBank;

$isValid = IranianBank::validateChecksum('IR123456789012345678901234567890');
// Returns true or false

FilamentPHP Integration

If you're using FilamentPHP, you can easily create an admin interface for the bank data:

  1. Create a Filament resource:

    php artisan make:filament-resource IranianBank
  2. Update the resource file at app/Filament/Resources/IranianBankResource.php using the package methods.

  3. Example implementation can be found in the FilamentResource example file.

The FilamentPHP integration provides a clean admin interface for managing Iranian bank data:

Filament Interface

Documentation

For detailed FilamentPHP usage, refer to the official FilamentPHP documentation.

Requirements

  • PHP >= 8.0
  • Laravel >= 9.0

License

This package is open-sourced software licensed under the MIT License.

Contributing

We welcome contributions! Please follow these steps:

  1. Fork the repository
  2. Create a feature branch (git checkout -b feature/amazing-feature)
  3. Commit your changes (git commit -m 'Add some amazing feature')
  4. Push to the branch (git push origin feature/amazing-feature)
  5. Open a Pull Request

Support

If you encounter any issues or have questions, please open an issue on GitHub.

Author

Emad Shirzad

Made with ❤️ for the Laravel community

统计信息

  • 总下载量: 5
  • 月度下载量: 0
  • 日度下载量: 0
  • 收藏数: 2
  • 点击次数: 0
  • 依赖项目数: 0
  • 推荐数: 0

GitHub 信息

  • Stars: 2
  • Watchers: 0
  • Forks: 1
  • 开发语言: PHP

其他信息

  • 授权协议: MIT
  • 更新时间: 2025-06-02