Release v0.2.5
Version 0.2.5
Change Log
- PayPal
- Gateway changes
- Transaction changes
- Other changes
- Laravel 5.1
PayPal
I have developed and tested an external package that adds paypal gateways to Laravel Shop.
PayPal Gateway Package is now installed by default with Laravel Shop, providing PayPal out of the box.
Gateway Changes
The gateway design changed a bit to support gateways that require callbacks from providers. Laravel Shop now adds a route and controller to handle Callbacks and pass their result to the gateway.
Changes were made while developing in parallel the PayPal package.
Transaction Changes
token
field has been added to transactions model and table to add a security step in gateway callbacks.
Other Changes
Other changes where made to LaravelShop class, traits and models to support the new gateway design.
Laravel 5.1
The project is now aimed for Laravel 5.1 and uses PHP >= 5.5.9 to keep it updated with technology.
Migrate from v0.2.0
PHP >= 5.5.9
You can still use Laravel 5 as long as it is running in a PHP version >= 5.5.9. Lower PHP versions don't support this MyClass::class
, which is used in Laravel 5.1 and this package.
Transaction table
The token
field was added in this new release. Do the following to update the table:
php artisan make:migration alter_transactions_table
And modify the migration file like this:
classAlterTransactionsTable extends Migration
{
public function up()
{
Schema::table(config('shop.transaction_table'), function($table)
{
$table->string('token')->after('detail')->nullable();
$table->index(['order_id', 'token']);
});
}
public function down()
{
Schema::table(config('shop.transaction_table'), function($table)
{
$table->dropColumn('token');
});
}
}
Then run migration
php artisan migrate