PHP code example of ashrafi / laravel-wallet

1. Go to this page and download the library: Download ashrafi/laravel-wallet library. Choose the download type require.

2. Extract the ZIP file and open the index.php.

3. Add this code to the index.php.
    
        
<?php
require_once('vendor/autoload.php');

/* Start to develop here. Best regards https://php-download.com/ */

    

ashrafi / laravel-wallet example snippets


composer 

php artisan vendor:publish --tag=wallet-manager-config

php artisan vendor:publish --tag=wallet-manager-seeder

(new CurrencySeeder())->run();
(new TransactionTypeSeeder())->run();

php artisan migrate
php artisan db:seed

    use Ashrafi\WalletManager\Models\Wallet;

    //YOUR CODES
    
    public function register(){
        //YOUR CODES
        //Bind other User class if you don't use \App\User class for authentication
        $this->app->bind(iUser::class, function(){
            return new {YourExtendedClass};
        });
        
        $this->app->extend(Wallet::class, function(){
            return new {YourExtendedClass};
        });

    }