Skip to content

Commit e80d11c

Browse files
authored
Merge pull request #30 from bavix/status-fix
global upgrade
2 parents e07a438 + bc882b7 commit e80d11c

33 files changed

+523
-362
lines changed

changelog.md

Lines changed: 13 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,16 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
66

77
## [Unreleased]
88

9+
## [2.3.0] - 2019-05-13
10+
### Added
11+
- Add support Themosis Framework
12+
13+
### Changed
14+
- In all the methods of translations have added the status of the transfer.
15+
16+
### Fixed
17+
- correction of errors during installation is not correct status.
18+
919
## [2.2.2] - 2019-05-12
1020
### Fixed
1121
- fixed fee counting. see issue #25
@@ -202,7 +212,8 @@ The operation is now executed in the transaction and updates the new `refund` fi
202212
- Exceptions: AmountInvalid, BalanceIsEmpty.
203213
- Models: Transfer, Transaction.
204214

205-
[Unreleased]: https://github.com/bavix/laravel-wallet/compare/2.2.2...HEAD
215+
[Unreleased]: https://github.com/bavix/laravel-wallet/compare/2.3.0...HEAD
216+
[2.3.0]: https://github.com/bavix/laravel-wallet/compare/2.2.2...2.3.0
206217
[2.2.2]: https://github.com/bavix/laravel-wallet/compare/2.2.1...2.2.2
207218
[2.2.1]: https://github.com/bavix/laravel-wallet/compare/2.2.0...2.2.1
208219
[2.2.0]: https://github.com/bavix/laravel-wallet/compare/2.1.0...2.2.0
@@ -217,3 +228,4 @@ The operation is now executed in the transaction and updates the new `refund` fi
217228
[1.1.1]: https://github.com/bavix/laravel-wallet/compare/1.1.0...1.1.1
218229
[1.1.0]: https://github.com/bavix/laravel-wallet/compare/1.0.0...1.1.0
219230
[1.0.0]: https://github.com/bavix/laravel-wallet/compare/0.0.1...1.0.0
231+
[0.0.1]: https://github.com/bavix/laravel-wallet/compare/d181a99e751c5138694580ca4361d5129baa26b3...0.0.1

composer.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -24,14 +24,14 @@
2424
],
2525
"require": {
2626
"php": "^7.1",
27-
"laravel/framework": "~5.5.0|~5.6.0|~5.7.0|~5.8.0",
27+
"illuminate/database": "~5.5.0|~5.6.0|~5.7.0|~5.8.0",
2828
"ramsey/uuid": "^3.0"
2929
},
3030
"require-dev": {
3131
"doctrine/dbal": "^2.8",
3232
"mockery/mockery": "^1.2",
3333
"orchestra/testbench": "^3.7",
34-
"phpunit/phpunit": "^7.4"
34+
"phpunit/phpunit": "^7.5"
3535
},
3636
"autoload": {
3737
"psr-4": {

database/migrations_v1/2018_11_06_222923_create_transactions_table.php

Lines changed: 12 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1,27 +1,19 @@
11
<?php
22

3-
use Illuminate\Support\Facades\Schema;
4-
use Illuminate\Database\Schema\Blueprint;
5-
use Illuminate\Database\Migrations\Migration;
63
use Bavix\Wallet\Models\Transaction;
4+
use Illuminate\Database\Migrations\Migration;
5+
use Illuminate\Database\Schema\Blueprint;
6+
use Illuminate\Support\Facades\Schema;
77

88
class CreateTransactionsTable extends Migration
99
{
1010

11-
/**
12-
* @return string
13-
*/
14-
protected function table(): string
15-
{
16-
return (new Transaction())->getTable();
17-
}
18-
1911
/**
2012
* @return void
2113
*/
2214
public function up(): void
2315
{
24-
Schema::create($this->table(), function(Blueprint $table) {
16+
Schema::create($this->table(), function (Blueprint $table) {
2517
$table->increments('id');
2618
$table->morphs('payable');
2719
$table->enum('type', ['deposit', 'withdraw'])->index();
@@ -37,6 +29,14 @@ public function up(): void
3729
});
3830
}
3931

32+
/**
33+
* @return string
34+
*/
35+
protected function table(): string
36+
{
37+
return (new Transaction())->getTable();
38+
}
39+
4040
/**
4141
* @return void
4242
*/

database/migrations_v1/2018_11_07_192923_create_transfers_table.php

Lines changed: 20 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -1,36 +1,20 @@
11
<?php
22

3-
use Illuminate\Support\Facades\Schema;
4-
use Illuminate\Database\Schema\Blueprint;
5-
use Illuminate\Database\Migrations\Migration;
63
use Bavix\Wallet\Models\Transaction;
74
use Bavix\Wallet\Models\Transfer;
5+
use Illuminate\Database\Migrations\Migration;
6+
use Illuminate\Database\Schema\Blueprint;
7+
use Illuminate\Support\Facades\Schema;
88

99
class CreateTransfersTable extends Migration
1010
{
1111

12-
/**
13-
* @return string
14-
*/
15-
protected function transactionTable(): string
16-
{
17-
return (new Transaction())->getTable();
18-
}
19-
20-
/**
21-
* @return string
22-
*/
23-
protected function table(): string
24-
{
25-
return (new Transfer())->getTable();
26-
}
27-
2812
/**
2913
* @return void
3014
*/
3115
public function up(): void
3216
{
33-
Schema::create($this->table(), function(Blueprint $table) {
17+
Schema::create($this->table(), function (Blueprint $table) {
3418
$table->increments('id');
3519
$table->morphs('from');
3620
$table->morphs('to');
@@ -51,6 +35,22 @@ public function up(): void
5135
});
5236
}
5337

38+
/**
39+
* @return string
40+
*/
41+
protected function table(): string
42+
{
43+
return (new Transfer())->getTable();
44+
}
45+
46+
/**
47+
* @return string
48+
*/
49+
protected function transactionTable(): string
50+
{
51+
return (new Transaction())->getTable();
52+
}
53+
5454
/**
5555
* @return void
5656
*/

database/migrations_v1/2018_11_07_202152_update_transfers_table.php

Lines changed: 14 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -1,29 +1,21 @@
11
<?php
22

3-
use Illuminate\Support\Facades\DB;
4-
use Illuminate\Support\Facades\Schema;
3+
use Bavix\Wallet\Models\Transfer;
4+
use Illuminate\Database\Migrations\Migration;
55
use Illuminate\Database\Schema\Blueprint;
66
use Illuminate\Database\SQLiteConnection;
7-
use Illuminate\Database\Migrations\Migration;
8-
use Bavix\Wallet\Models\Transfer;
7+
use Illuminate\Support\Facades\DB;
8+
use Illuminate\Support\Facades\Schema;
99

1010
class UpdateTransfersTable extends Migration
1111
{
1212

13-
/**
14-
* @return string
15-
*/
16-
protected function table(): string
17-
{
18-
return (new Transfer())->getTable();
19-
}
20-
2113
/**
2214
* @return void
2315
*/
2416
public function up(): void
2517
{
26-
Schema::table($this->table(), function(Blueprint $table) {
18+
Schema::table($this->table(), function (Blueprint $table) {
2719
$table->boolean('refund')
2820
->after('withdraw_id')
2921
->default(0);
@@ -34,12 +26,20 @@ public function up(): void
3426
});
3527
}
3628

29+
/**
30+
* @return string
31+
*/
32+
protected function table(): string
33+
{
34+
return (new Transfer())->getTable();
35+
}
36+
3737
/**
3838
* @return void
3939
*/
4040
public function down(): void
4141
{
42-
Schema::table($this->table(), function(Blueprint $table) {
42+
Schema::table($this->table(), function (Blueprint $table) {
4343
if (!(DB::connection() instanceof SQLiteConnection)) {
4444
$table->dropIndex('from_to_refund_ind');
4545
$table->dropIndex('from_refund_ind');

database/migrations_v2/2018_11_15_124230_create_wallets_table.php

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,12 @@
11
<?php
22

3-
use Illuminate\Support\Facades\Schema;
4-
use Illuminate\Database\Schema\Blueprint;
5-
use Illuminate\Database\Migrations\Migration;
63
use Bavix\Wallet\Models\Transaction;
74
use Bavix\Wallet\Models\Wallet;
8-
use Illuminate\Support\Facades\DB;
95
use Illuminate\Database\Eloquent\Collection;
6+
use Illuminate\Database\Migrations\Migration;
7+
use Illuminate\Database\Schema\Blueprint;
8+
use Illuminate\Support\Facades\DB;
9+
use Illuminate\Support\Facades\Schema;
1010

1111
class CreateWalletsTable extends Migration
1212
{
@@ -24,7 +24,7 @@ protected function table(): string
2424
*/
2525
public function up(): void
2626
{
27-
Schema::create($this->table(), function(Blueprint $table) {
27+
Schema::create($this->table(), function (Blueprint $table) {
2828
$table->increments('id');
2929
$table->morphs('holder');
3030
$table->string('name');

database/migrations_v2/2018_11_19_164609_update_transactions_table.php

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,11 @@
11
<?php
22

3-
use Illuminate\Support\Facades\DB;
4-
use Illuminate\Support\Facades\Schema;
5-
use Illuminate\Database\Schema\Blueprint;
6-
use Illuminate\Database\Migrations\Migration;
73
use Bavix\Wallet\Models\Transaction;
84
use Bavix\Wallet\Models\Wallet;
5+
use Illuminate\Database\Migrations\Migration;
6+
use Illuminate\Database\Schema\Blueprint;
7+
use Illuminate\Support\Facades\DB;
8+
use Illuminate\Support\Facades\Schema;
99

1010
class UpdateTransactionsTable extends Migration
1111
{
@@ -31,7 +31,7 @@ protected function walletTable(): string
3131
*/
3232
public function up(): void
3333
{
34-
Schema::table($this->table(), function(Blueprint $table) {
34+
Schema::table($this->table(), function (Blueprint $table) {
3535
$table->unsignedInteger('wallet_id')
3636
->nullable()
3737
->after('payable_id');

database/migrations_v2/2018_11_20_133759_add_fee_transfers_table.php

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,9 @@
11
<?php
22

3-
use Illuminate\Support\Facades\Schema;
4-
use Illuminate\Database\Schema\Blueprint;
5-
use Illuminate\Database\Migrations\Migration;
63
use Bavix\Wallet\Models\Transfer;
4+
use Illuminate\Database\Migrations\Migration;
5+
use Illuminate\Database\Schema\Blueprint;
6+
use Illuminate\Support\Facades\Schema;
77

88
class AddFeeTransfersTable extends Migration
99
{
@@ -21,7 +21,7 @@ protected function table(): string
2121
*/
2222
public function up(): void
2323
{
24-
Schema::table($this->table(), function(Blueprint $table) {
24+
Schema::table($this->table(), function (Blueprint $table) {
2525
$table->bigInteger('fee')
2626
->default(0)
2727
->after('withdraw_id');

database/migrations_v2/2018_11_22_131953_add_status_transfers_table.php

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,10 @@
11
<?php
22

3-
use Illuminate\Support\Facades\Schema;
4-
use Illuminate\Database\Schema\Blueprint;
3+
use Bavix\Wallet\Models\Transfer;
54
use Illuminate\Database\Migrations\Migration;
5+
use Illuminate\Database\Schema\Blueprint;
66
use Illuminate\Support\Facades\DB;
7-
use Bavix\Wallet\Models\Transfer;
7+
use Illuminate\Support\Facades\Schema;
88

99
class AddStatusTransfersTable extends Migration
1010
{
@@ -22,7 +22,7 @@ protected function table(): string
2222
*/
2323
public function up(): void
2424
{
25-
Schema::table($this->table(), function(Blueprint $table) {
25+
Schema::table($this->table(), function (Blueprint $table) {
2626
$enums = [
2727
Transfer::STATUS_PAID,
2828
Transfer::STATUS_REFUND,

database/migrations_v2/2018_11_22_133438_drop_refund_transfers_table.php

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,11 @@
11
<?php
22

3-
use Illuminate\Support\Facades\Schema;
4-
use Illuminate\Database\Schema\Blueprint;
3+
use Bavix\Wallet\Models\Transfer;
54
use Illuminate\Database\Migrations\Migration;
5+
use Illuminate\Database\Schema\Blueprint;
66
use Illuminate\Database\SQLiteConnection;
77
use Illuminate\Support\Facades\DB;
8-
use Bavix\Wallet\Models\Transfer;
8+
use Illuminate\Support\Facades\Schema;
99

1010
class DropRefundTransfersTable extends Migration
1111
{
@@ -23,7 +23,7 @@ protected function table(): string
2323
*/
2424
public function up(): void
2525
{
26-
Schema::table($this->table(), function(Blueprint $table) {
26+
Schema::table($this->table(), function (Blueprint $table) {
2727
if (!(DB::connection() instanceof SQLiteConnection)) {
2828
$table->dropIndex('from_to_refund_ind');
2929
$table->dropIndex('from_refund_ind');

0 commit comments

Comments
 (0)