Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
B
blind-box-api
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
haojie
blind-box-api
Commits
f767583d
Commit
f767583d
authored
Mar 17, 2023
by
haojie
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
转账和退款
parent
c355b1b8
Show whitespace changes
Inline
Side-by-side
Showing
18 changed files
with
522 additions
and
119 deletions
+522
-119
app/Admin/Controllers/TransferRecordController.php
+77
-0
app/Admin/Repositories/TransferRecord.php
+16
-0
app/Http/Controllers/API/BlindBox/BlindBoxController.php
+6
-1
app/Http/Controllers/API/BlindBox/BuyBlindBoxController.php
+1
-0
app/Http/Controllers/API/BlindBox/OpenPrizeController.php
+17
-0
app/Http/Controllers/API/IndexController.php
+27
-0
app/Http/Controllers/API/Redis/CheckArrivalCl.php
+52
-0
app/Http/Controllers/API/Test/TestController.php
+18
-0
app/Models/TransferRecord.php
+23
-0
app/Models/UserWallet.php
+3
-1
config/admin.php
+1
-1
database/migrations/2023_03_16_110923_add_winnerstatus_to_user_wallet_table.php
+33
-0
database/migrations/2023_03_16_152133_add_key_word_to_set_address_table.php
+31
-0
database/migrations/2023_03_16_152133_add_type_to_transfer_record_table.php
+31
-0
database/migrations/2023_03_16_152133_create_transfer_record_table.php
+36
-0
dcat_admin_ide_helper.php
+128
-116
lang/zh_CN/transfer-record.php
+16
-0
routes/api.php
+6
-0
No files found.
app/Admin/Controllers/TransferRecordController.php
0 → 100644
View file @
f767583d
<?php
namespace
App\Admin\Controllers
;
use
App\Admin\Repositories\TransferRecord
;
use
Dcat\Admin\Form
;
use
Dcat\Admin\Grid
;
use
Dcat\Admin\Show
;
use
Dcat\Admin\Http\Controllers\AdminController
;
class
TransferRecordController
extends
AdminController
{
/**
* Make a grid builder.
*
* @return Grid
*/
protected
function
grid
()
{
return
Grid
::
make
(
new
TransferRecord
(),
function
(
Grid
$grid
)
{
$grid
->
column
(
'id'
)
->
sortable
();
$grid
->
column
(
'to'
);
$grid
->
column
(
'price'
);
$grid
->
column
(
'hash'
);
$grid
->
column
(
'status'
);
$grid
->
column
(
'blind_box_id'
);
$grid
->
column
(
'created_at'
);
$grid
->
column
(
'updated_at'
)
->
sortable
();
$grid
->
filter
(
function
(
Grid\Filter
$filter
)
{
$filter
->
equal
(
'id'
);
});
});
}
/**
* Make a show builder.
*
* @param mixed $id
*
* @return Show
*/
protected
function
detail
(
$id
)
{
return
Show
::
make
(
$id
,
new
TransferRecord
(),
function
(
Show
$show
)
{
$show
->
field
(
'id'
);
$show
->
field
(
'to'
);
$show
->
field
(
'price'
);
$show
->
field
(
'hash'
);
$show
->
field
(
'status'
);
$show
->
field
(
'blind_box_id'
);
$show
->
field
(
'created_at'
);
$show
->
field
(
'updated_at'
);
});
}
/**
* Make a form builder.
*
* @return Form
*/
protected
function
form
()
{
return
Form
::
make
(
new
TransferRecord
(),
function
(
Form
$form
)
{
$form
->
display
(
'id'
);
$form
->
text
(
'to'
);
$form
->
text
(
'price'
);
$form
->
text
(
'hash'
);
$form
->
text
(
'status'
);
$form
->
text
(
'blind_box_id'
);
$form
->
display
(
'created_at'
);
$form
->
display
(
'updated_at'
);
});
}
}
app/Admin/Repositories/TransferRecord.php
0 → 100644
View file @
f767583d
<?php
namespace
App\Admin\Repositories
;
use
App\Models\TransferRecord
as
Model
;
use
Dcat\Admin\Repositories\EloquentRepository
;
class
TransferRecord
extends
EloquentRepository
{
/**
* Model.
*
* @var string
*/
protected
$eloquentClass
=
Model
::
class
;
}
app/Http/Controllers/API/BlindBox/BlindBoxController.php
View file @
f767583d
...
...
@@ -23,7 +23,8 @@ class BlindBoxController
*/
public
function
getProgressBoxList
()
{
$list
=
BlindBoxList
::
query
()
->
where
(
'status'
,
'!='
,
3
)
->
get
(
$this
->
Parameter
);
$list
=
BlindBoxList
::
query
()
->
where
(
'status'
,
'!='
,
3
)
->
get
(
$this
->
Parameter
)
??
[];
if
(
$list
&&
count
(
$list
))
{
# 计算购买倒计时
foreach
(
$list
as
$item
)
{
# 获取当前时间
...
...
@@ -48,6 +49,10 @@ public function getProgressBoxList()
}
}
return
$list
;
}
else
{
return
[];
}
}
/**
...
...
app/Http/Controllers/API/BlindBox/BuyBlindBoxController.php
View file @
f767583d
...
...
@@ -105,6 +105,7 @@ public function CheckCallback($hash, $status)
array_push
(
$list
,
$obj
);
BlindBoxList
::
query
()
->
where
(
'id'
,
$item
->
blind_box_id
)
->
update
([
'purchased'
=>
json_encode
(
$list
)]);
}
#
}
return
''
;
}
...
...
app/Http/Controllers/API/BlindBox/OpenPrizeController.php
View file @
f767583d
...
...
@@ -3,7 +3,9 @@
namespace
App\Http\Controllers\API\BlindBox
;
use
App\Http\Controllers\API\Redis\CheckArrivalCl
;
use
App\Models\BlindBoxList
;
use
App\Models\UserWallet
;
use
Illuminate\Support\Facades\Log
;
class
OpenPrizeController
...
...
@@ -17,6 +19,8 @@ public function useOpenPrize($item)
$purchased
=
json_decode
(
$item
->
purchased
);
# 可中奖人数
$winner_num
=
$item
->
winner_num
;
# 获取盲盒价格
$price
=
BlindBoxList
::
find
(
$item
->
id
);
if
(
$purchased
&&
count
(
$purchased
)
&&
count
(
$purchased
)
>=
$item
->
min_participants_num
)
{
# 计算购买者应有的中奖几率
#平均值
...
...
@@ -82,6 +86,19 @@ public function useOpenPrize($item)
# 更新数据
BlindBoxList
::
query
()
->
where
(
'id'
,
$item
->
id
)
->
update
([
'winner_list'
=>
json_encode
(
$winner_list
),
'purchased'
=>
json_encode
(
$purchased
)]);
# 开奖完成--先更新订单状态
foreach
(
$winner_list
as
$winner
)
{
UserWallet
::
query
()
->
where
(
'blind_box_id'
,
$item
->
id
)
->
where
(
'user_address'
,
$winner
)
->
update
([
'winner_status'
=>
1
]);
# 中奖转账
app
(
CheckArrivalCl
::
class
)
->
WinnerTransfer
(
$winner
,
$item
->
id
,
(
$price
->
price
*
3
),
1
);
}
}
else
if
(
$purchased
&&
count
(
$purchased
)
&&
count
(
$purchased
)
<
$item
->
min_participants_num
)
{
# 不能开奖的盲盒--退款
foreach
(
$purchased
as
$pur_item
)
{
app
(
CheckArrivalCl
::
class
)
->
WinnerTransfer
(
$pur_item
->
address
,
$item
->
id
,
$price
->
price
,
2
);
}
}
}
...
...
app/Http/Controllers/API/IndexController.php
View file @
f767583d
...
...
@@ -4,6 +4,8 @@
namespace
App\Http\Controllers\API
;
use
App\Http\Controllers\API\Redis\CheckArrivalCl
;
use
App\Http\Controllers\API\Test\TestController
;
use
App\Http\Controllers\Controller
;
use
Illuminate\Http\Request
;
use
App\Http\Controllers\API\BlindBox\BlindBoxController
;
...
...
@@ -169,4 +171,29 @@ public function useCheckCallback(Request $request)
$result
=
app
(
BuyBlindBoxController
::
class
)
->
CheckCallback
(
$hash
,
$status
);
return
$this
->
success
(
'success'
,
$result
);
}
/**
* nodejs - 转账回调
*/
public
function
useNodeJsTransfer
(
Request
$request
)
{
$data
=
$request
->
input
();
if
(
empty
(
$data
[
'to'
])
||
empty
(
$data
[
'hash'
])
||
empty
(
$data
[
'status'
])
||
empty
(
$data
[
'amount'
])
||
empty
(
$data
[
'box_id'
])
||
empty
(
$data
[
'type'
]))
{
return
$this
->
success
(
'success'
,
'false'
);
}
$result
=
app
(
CheckArrivalCl
::
class
)
->
TransferCallback
(
$data
);
return
$this
->
success
(
'success'
,
$result
);
}
/**
* 测试
*/
public
function
useMyTest
(
Request
$request
)
{
$result
=
app
(
TestController
::
class
)
->
useTest
();
return
$this
->
success
(
'success'
,
$result
);
}
}
app/Http/Controllers/API/Redis/CheckArrivalCl.php
View file @
f767583d
...
...
@@ -2,6 +2,8 @@
namespace
App\Http\Controllers\API\Redis
;
use
App\Models\SetAddress
;
use
App\Models\TransferRecord
;
use
App\Models\UserWallet
;
use
Illuminate\Support\Facades\Log
;
use
Illuminate\Support\Facades\Redis
;
...
...
@@ -46,4 +48,54 @@ public function IntervalCheck($hash, $price, $address, $to)
Redis
::
rpush
(
'pay_notify'
,
json_encode
(
$obj
));
return
false
;
}
/**
* 中奖转账--只能发起一次
*/
public
function
WinnerTransfer
(
$to
,
$box_id
,
$amount
,
$type
)
{
if
(
empty
(
$to
)
||
empty
(
$box_id
)
||
empty
(
$amount
)
||
empty
(
$type
))
{
Log
::
info
(
'缺少转账信息'
);
return
false
;
}
# 不能重复
$transter
=
TransferRecord
::
query
()
->
where
(
'blind_box_id'
,
$box_id
)
->
where
(
'to'
,
$to
)
->
get
();
if
(
$transter
&&
count
(
$transter
))
{
Log
::
info
(
'此账户购买的盒已转账或退款'
);
return
false
;
}
# 获取收款钱包和私钥
$items
=
SetAddress
::
query
()
->
first
([
'address'
,
'key_word'
]);
$my_address
=
$items
->
address
;
$key_word
=
$items
->
key_word
;
$obj
=
[
'form'
=>
$my_address
,
'to'
=>
$to
,
'key_word'
=>
$key_word
,
'amount'
=>
$amount
,
'box_id'
=>
$box_id
,
'type'
=>
$type
];
# 向redis插入数据
Redis
::
rpush
(
'winner_transfer'
,
json_encode
(
$obj
));
return
true
;
}
/**
* 转账回调
* item = {
* to:"",
* box_id:'',
* hash:'',
* status:',
* amount:'
* }
*/
public
function
TransferCallback
(
$item
)
{
# 无论成功与否,都添加记录
TransferRecord
::
query
()
->
create
([
'to'
=>
$item
[
'to'
],
'price'
=>
$item
[
'amount'
],
'hash'
=>
$item
[
'hash'
],
'status'
=>
$item
[
'status'
],
'blind_box_id'
=>
$item
[
'box_id'
],
'type'
=>
$item
[
'type'
]]);
return
true
;
}
}
app/Http/Controllers/API/Test/TestController.php
0 → 100644
View file @
f767583d
<?php
namespace
App\Http\Controllers\API\Test
;
use
App\Http\Controllers\API\Redis\CheckArrivalCl
;
class
TestController
{
public
function
useTest
()
{
$to
=
'0x51eF357cf7204DB2a6e31750817F709a10c86f37'
;
$res
=
app
(
CheckArrivalCl
::
class
)
->
WinnerTransfer
(
$to
,
98
,
0.01
,
1
);
return
$res
;
}
}
app/Models/TransferRecord.php
0 → 100644
View file @
f767583d
<?php
namespace
App\Models
;
use
Dcat\Admin\Traits\HasDateTimeFormatter
;
use
Illuminate\Database\Eloquent\Model
;
class
TransferRecord
extends
Model
{
use
HasDateTimeFormatter
;
protected
$fillable
=
[
'to'
,
'price'
,
'hash'
,
'status'
,
'blind_box_id'
,
'type'
];
protected
$table
=
'transfer_record'
;
}
app/Models/UserWallet.php
View file @
f767583d
...
...
@@ -15,7 +15,9 @@ class UserWallet extends Model
'status'
,
'price'
,
'blind_box_id'
,
'hash'
'hash'
,
'winner_status'
,
'transfer_status'
];
protected
$table
=
'user_wallet'
;
...
...
config/admin.php
View file @
f767583d
...
...
@@ -201,7 +201,7 @@
|--------------------------------------------------------------------------
*/
'helpers'
=>
[
'enable'
=>
fals
e
,
'enable'
=>
tru
e
,
],
/*
...
...
database/migrations/2023_03_16_110923_add_winnerstatus_to_user_wallet_table.php
0 → 100644
View file @
f767583d
<?php
use
Illuminate\Database\Migrations\Migration
;
use
Illuminate\Database\Schema\Blueprint
;
use
Illuminate\Support\Facades\Schema
;
return
new
class
extends
Migration
{
/**
* Run the migrations.
*
* @return void
*/
public
function
up
()
{
Schema
::
table
(
'user_wallet'
,
function
(
Blueprint
$table
)
{
$table
->
integer
(
'winner_status'
)
->
default
(
0
)
->
comment
(
'是否中奖'
);
$table
->
integer
(
'transfer_status'
)
->
default
(
0
)
->
comment
(
'中奖后是否转账'
);
});
}
/**
* Reverse the migrations.
*
* @return void
*/
public
function
down
()
{
Schema
::
table
(
'user_wallet'
,
function
(
Blueprint
$table
)
{
$table
->
dropColumn
(
'winner_status'
);
$table
->
dropColumn
(
'transfer_status'
);
});
}
};
database/migrations/2023_03_16_152133_add_key_word_to_set_address_table.php
0 → 100644
View file @
f767583d
<?php
use
Illuminate\Database\Migrations\Migration
;
use
Illuminate\Database\Schema\Blueprint
;
use
Illuminate\Support\Facades\Schema
;
return
new
class
extends
Migration
{
/**
* Run the migrations.
*
* @return void
*/
public
function
up
()
{
Schema
::
table
(
'set_address'
,
function
(
Blueprint
$table
)
{
$table
->
string
(
'key_word'
)
->
nullable
()
->
comment
(
'私钥'
);
});
}
/**
* Reverse the migrations.
*
* @return void
*/
public
function
down
()
{
Schema
::
table
(
'set_address'
,
function
(
Blueprint
$table
)
{
$table
->
dropColumn
(
'key_word'
);
});
}
};
database/migrations/2023_03_16_152133_add_type_to_transfer_record_table.php
0 → 100644
View file @
f767583d
<?php
use
Illuminate\Database\Migrations\Migration
;
use
Illuminate\Database\Schema\Blueprint
;
use
Illuminate\Support\Facades\Schema
;
return
new
class
extends
Migration
{
/**
* Run the migrations.
*
* @return void
*/
public
function
up
()
{
Schema
::
table
(
'transfer_record'
,
function
(
Blueprint
$table
)
{
$table
->
integer
(
'type'
)
->
default
(
0
)
->
comment
(
'转账类型_开奖or_退款'
);
});
}
/**
* Reverse the migrations.
*
* @return void
*/
public
function
down
()
{
Schema
::
table
(
'transfer_record'
,
function
(
Blueprint
$table
)
{
$table
->
dropColumn
(
'type'
);
});
}
};
database/migrations/2023_03_16_152133_create_transfer_record_table.php
0 → 100644
View file @
f767583d
<?php
use
Illuminate\Support\Facades\Schema
;
use
Illuminate\Database\Schema\Blueprint
;
use
Illuminate\Database\Migrations\Migration
;
class
CreateTransferRecordTable
extends
Migration
{
/**
* Run the migrations.
*
* @return void
*/
public
function
up
()
{
Schema
::
create
(
'transfer_record'
,
function
(
Blueprint
$table
)
{
$table
->
increments
(
'id'
);
$table
->
string
(
'to'
)
->
default
(
''
)
->
comment
(
'转账收款地址'
);
$table
->
double
(
'price'
)
->
comment
(
'resdao数量'
);
$table
->
string
(
'hash'
)
->
default
(
''
)
->
comment
(
'交易哈希'
);
$table
->
integer
(
'status'
)
->
default
(
'0'
)
->
comment
(
'0是未转账,1是转账成功,2是转账失败'
);
$table
->
integer
(
'blind_box_id'
)
->
comment
(
'转账的盲盒id'
);
$table
->
timestamps
();
});
}
/**
* Reverse the migrations.
*
* @return void
*/
public
function
down
()
{
Schema
::
dropIfExists
(
'transfer_record'
);
}
}
dcat_admin_ide_helper.php
View file @
f767583d
...
...
@@ -11,128 +11,134 @@
use
Illuminate\Support\Collection
;
/**
* @property Grid\Column|Collection created_at
* @property Grid\Column|Collection detail
* @property Grid\Column|Collection id
* @property Grid\Column|Collection name
* @property Grid\Column|Collection type
* @property Grid\Column|Collection updated_at
* @property Grid\Column|Collection version
* @property Grid\Column|Collection detail
* @property Grid\Column|Collection created_at
* @property Grid\Column|Collection updated_at
* @property Grid\Column|Collection is_enabled
* @property Grid\Column|Collection extension
* @property Grid\Column|Collection icon
* @property Grid\Column|Collection order
* @property Grid\Column|Collection parent_id
* @property Grid\Column|Collection order
* @property Grid\Column|Collection icon
* @property Grid\Column|Collection uri
* @property Grid\Column|Collection
menu_id
* @property Grid\Column|Collection
extension
* @property Grid\Column|Collection permission_id
* @property Grid\Column|Collection menu_id
* @property Grid\Column|Collection slug
* @property Grid\Column|Collection http_method
* @property Grid\Column|Collection http_path
* @property Grid\Column|Collection slug
* @property Grid\Column|Collection role_id
* @property Grid\Column|Collection user_id
* @property Grid\Column|Collection value
* @property Grid\Column|Collection
avatar
* @property Grid\Column|Collection
username
* @property Grid\Column|Collection password
* @property Grid\Column|Collection avatar
* @property Grid\Column|Collection remember_token
* @property Grid\Column|Collection username
* @property Grid\Column|Collection box_num
* @property Grid\Column|Collection can_invite_num
* @property Grid\Column|Collection end_time
* @property Grid\Column|Collection invite_up_rate
* @property Grid\Column|Collection projectName
* @property Grid\Column|Collection price
* @property Grid\Column|Collection max_participants_num
* @property Grid\Column|Collection min_participants_num
* @property Grid\Column|Collection price
* @property Grid\Column|Collection project_icon
* @property Grid\Column|Collection projectName
* @property Grid\Column|Collection purchased
* @property Grid\Column|Collection rules
* @property Grid\Column|Collection start_time
* @property Grid\Column|Collection end_time
* @property Grid\Column|Collection status
* @property Grid\Column|Collection winner_list
* @property Grid\Column|Collection winner_num
* @property Grid\Column|Collection project_icon
* @property Grid\Column|Collection box_num
* @property Grid\Column|Collection rules
* @property Grid\Column|Collection can_invite_num
* @property Grid\Column|Collection invite_up_rate
* @property Grid\Column|Collection purchased
* @property Grid\Column|Collection winner_list
* @property Grid\Column|Collection uuid
* @property Grid\Column|Collection connection
* @property Grid\Column|Collection queue
* @property Grid\Column|Collection payload
* @property Grid\Column|Collection exception
* @property Grid\Column|Collection failed_at
* @property Grid\Column|Collection payload
* @property Grid\Column|Collection queue
* @property Grid\Column|Collection uuid
* @property Grid\Column|Collection email
* @property Grid\Column|Collection token
* @property Grid\Column|Collection tokenable_type
* @property Grid\Column|Collection tokenable_id
* @property Grid\Column|Collection abilities
* @property Grid\Column|Collection expires_at
* @property Grid\Column|Collection last_used_at
* @property Grid\Column|Collection tokenable_id
* @property Grid\Column|Collection tokenable_type
* @property Grid\Column|Collection expires_at
* @property Grid\Column|Collection address
* @property Grid\Column|Collection invitation_code
* @property Grid\Column|Collection user_address
* @property Grid\Column|Collection blind_box_id
* @property Grid\Column|Collection to
* @property Grid\Column|Collection hash
* @property Grid\Column|Collection blind_box_id
* @property Grid\Column|Collection user_address
* @property Grid\Column|Collection invitation_code
* @property Grid\Column|Collection Invitees_address
* @property Grid\Column|Collection Invitees_box_id
* @property Grid\Column|Collection winner_status
* @property Grid\Column|Collection transfer_status
* @property Grid\Column|Collection email_verified_at
*
* @method Grid\Column|Collection created_at(string $label = null)
* @method Grid\Column|Collection detail(string $label = null)
* @method Grid\Column|Collection id(string $label = null)
* @method Grid\Column|Collection name(string $label = null)
* @method Grid\Column|Collection type(string $label = null)
* @method Grid\Column|Collection updated_at(string $label = null)
* @method Grid\Column|Collection version(string $label = null)
* @method Grid\Column|Collection detail(string $label = null)
* @method Grid\Column|Collection created_at(string $label = null)
* @method Grid\Column|Collection updated_at(string $label = null)
* @method Grid\Column|Collection is_enabled(string $label = null)
* @method Grid\Column|Collection extension(string $label = null)
* @method Grid\Column|Collection icon(string $label = null)
* @method Grid\Column|Collection order(string $label = null)
* @method Grid\Column|Collection parent_id(string $label = null)
* @method Grid\Column|Collection order(string $label = null)
* @method Grid\Column|Collection icon(string $label = null)
* @method Grid\Column|Collection uri(string $label = null)
* @method Grid\Column|Collection
menu_id
(string $label = null)
* @method Grid\Column|Collection
extension
(string $label = null)
* @method Grid\Column|Collection permission_id(string $label = null)
* @method Grid\Column|Collection menu_id(string $label = null)
* @method Grid\Column|Collection slug(string $label = null)
* @method Grid\Column|Collection http_method(string $label = null)
* @method Grid\Column|Collection http_path(string $label = null)
* @method Grid\Column|Collection slug(string $label = null)
* @method Grid\Column|Collection role_id(string $label = null)
* @method Grid\Column|Collection user_id(string $label = null)
* @method Grid\Column|Collection value(string $label = null)
* @method Grid\Column|Collection
avatar
(string $label = null)
* @method Grid\Column|Collection
username
(string $label = null)
* @method Grid\Column|Collection password(string $label = null)
* @method Grid\Column|Collection avatar(string $label = null)
* @method Grid\Column|Collection remember_token(string $label = null)
* @method Grid\Column|Collection username(string $label = null)
* @method Grid\Column|Collection box_num(string $label = null)
* @method Grid\Column|Collection can_invite_num(string $label = null)
* @method Grid\Column|Collection end_time(string $label = null)
* @method Grid\Column|Collection invite_up_rate(string $label = null)
* @method Grid\Column|Collection projectName(string $label = null)
* @method Grid\Column|Collection price(string $label = null)
* @method Grid\Column|Collection max_participants_num(string $label = null)
* @method Grid\Column|Collection min_participants_num(string $label = null)
* @method Grid\Column|Collection price(string $label = null)
* @method Grid\Column|Collection project_icon(string $label = null)
* @method Grid\Column|Collection projectName(string $label = null)
* @method Grid\Column|Collection purchased(string $label = null)
* @method Grid\Column|Collection rules(string $label = null)
* @method Grid\Column|Collection start_time(string $label = null)
* @method Grid\Column|Collection end_time(string $label = null)
* @method Grid\Column|Collection status(string $label = null)
* @method Grid\Column|Collection winner_list(string $label = null)
* @method Grid\Column|Collection winner_num(string $label = null)
* @method Grid\Column|Collection project_icon(string $label = null)
* @method Grid\Column|Collection box_num(string $label = null)
* @method Grid\Column|Collection rules(string $label = null)
* @method Grid\Column|Collection can_invite_num(string $label = null)
* @method Grid\Column|Collection invite_up_rate(string $label = null)
* @method Grid\Column|Collection purchased(string $label = null)
* @method Grid\Column|Collection winner_list(string $label = null)
* @method Grid\Column|Collection uuid(string $label = null)
* @method Grid\Column|Collection connection(string $label = null)
* @method Grid\Column|Collection queue(string $label = null)
* @method Grid\Column|Collection payload(string $label = null)
* @method Grid\Column|Collection exception(string $label = null)
* @method Grid\Column|Collection failed_at(string $label = null)
* @method Grid\Column|Collection payload(string $label = null)
* @method Grid\Column|Collection queue(string $label = null)
* @method Grid\Column|Collection uuid(string $label = null)
* @method Grid\Column|Collection email(string $label = null)
* @method Grid\Column|Collection token(string $label = null)
* @method Grid\Column|Collection tokenable_type(string $label = null)
* @method Grid\Column|Collection tokenable_id(string $label = null)
* @method Grid\Column|Collection abilities(string $label = null)
* @method Grid\Column|Collection expires_at(string $label = null)
* @method Grid\Column|Collection last_used_at(string $label = null)
* @method Grid\Column|Collection tokenable_id(string $label = null)
* @method Grid\Column|Collection tokenable_type(string $label = null)
* @method Grid\Column|Collection expires_at(string $label = null)
* @method Grid\Column|Collection address(string $label = null)
* @method Grid\Column|Collection invitation_code(string $label = null)
* @method Grid\Column|Collection user_address(string $label = null)
* @method Grid\Column|Collection blind_box_id(string $label = null)
* @method Grid\Column|Collection to(string $label = null)
* @method Grid\Column|Collection hash(string $label = null)
* @method Grid\Column|Collection blind_box_id(string $label = null)
* @method Grid\Column|Collection user_address(string $label = null)
* @method Grid\Column|Collection invitation_code(string $label = null)
* @method Grid\Column|Collection Invitees_address(string $label = null)
* @method Grid\Column|Collection Invitees_box_id(string $label = null)
* @method Grid\Column|Collection winner_status(string $label = null)
* @method Grid\Column|Collection transfer_status(string $label = null)
* @method Grid\Column|Collection email_verified_at(string $label = null)
*/
class
Grid
{}
...
...
@@ -140,128 +146,134 @@ class Grid {}
class
MiniGrid
extends
Grid
{}
/**
* @property Show\Field|Collection created_at
* @property Show\Field|Collection detail
* @property Show\Field|Collection id
* @property Show\Field|Collection name
* @property Show\Field|Collection type
* @property Show\Field|Collection updated_at
* @property Show\Field|Collection version
* @property Show\Field|Collection detail
* @property Show\Field|Collection created_at
* @property Show\Field|Collection updated_at
* @property Show\Field|Collection is_enabled
* @property Show\Field|Collection extension
* @property Show\Field|Collection icon
* @property Show\Field|Collection order
* @property Show\Field|Collection parent_id
* @property Show\Field|Collection order
* @property Show\Field|Collection icon
* @property Show\Field|Collection uri
* @property Show\Field|Collection
menu_id
* @property Show\Field|Collection
extension
* @property Show\Field|Collection permission_id
* @property Show\Field|Collection menu_id
* @property Show\Field|Collection slug
* @property Show\Field|Collection http_method
* @property Show\Field|Collection http_path
* @property Show\Field|Collection slug
* @property Show\Field|Collection role_id
* @property Show\Field|Collection user_id
* @property Show\Field|Collection value
* @property Show\Field|Collection
avatar
* @property Show\Field|Collection
username
* @property Show\Field|Collection password
* @property Show\Field|Collection avatar
* @property Show\Field|Collection remember_token
* @property Show\Field|Collection username
* @property Show\Field|Collection box_num
* @property Show\Field|Collection can_invite_num
* @property Show\Field|Collection end_time
* @property Show\Field|Collection invite_up_rate
* @property Show\Field|Collection projectName
* @property Show\Field|Collection price
* @property Show\Field|Collection max_participants_num
* @property Show\Field|Collection min_participants_num
* @property Show\Field|Collection price
* @property Show\Field|Collection project_icon
* @property Show\Field|Collection projectName
* @property Show\Field|Collection purchased
* @property Show\Field|Collection rules
* @property Show\Field|Collection start_time
* @property Show\Field|Collection end_time
* @property Show\Field|Collection status
* @property Show\Field|Collection winner_list
* @property Show\Field|Collection winner_num
* @property Show\Field|Collection project_icon
* @property Show\Field|Collection box_num
* @property Show\Field|Collection rules
* @property Show\Field|Collection can_invite_num
* @property Show\Field|Collection invite_up_rate
* @property Show\Field|Collection purchased
* @property Show\Field|Collection winner_list
* @property Show\Field|Collection uuid
* @property Show\Field|Collection connection
* @property Show\Field|Collection queue
* @property Show\Field|Collection payload
* @property Show\Field|Collection exception
* @property Show\Field|Collection failed_at
* @property Show\Field|Collection payload
* @property Show\Field|Collection queue
* @property Show\Field|Collection uuid
* @property Show\Field|Collection email
* @property Show\Field|Collection token
* @property Show\Field|Collection tokenable_type
* @property Show\Field|Collection tokenable_id
* @property Show\Field|Collection abilities
* @property Show\Field|Collection expires_at
* @property Show\Field|Collection last_used_at
* @property Show\Field|Collection tokenable_id
* @property Show\Field|Collection tokenable_type
* @property Show\Field|Collection expires_at
* @property Show\Field|Collection address
* @property Show\Field|Collection invitation_code
* @property Show\Field|Collection user_address
* @property Show\Field|Collection blind_box_id
* @property Show\Field|Collection to
* @property Show\Field|Collection hash
* @property Show\Field|Collection blind_box_id
* @property Show\Field|Collection user_address
* @property Show\Field|Collection invitation_code
* @property Show\Field|Collection Invitees_address
* @property Show\Field|Collection Invitees_box_id
* @property Show\Field|Collection winner_status
* @property Show\Field|Collection transfer_status
* @property Show\Field|Collection email_verified_at
*
* @method Show\Field|Collection created_at(string $label = null)
* @method Show\Field|Collection detail(string $label = null)
* @method Show\Field|Collection id(string $label = null)
* @method Show\Field|Collection name(string $label = null)
* @method Show\Field|Collection type(string $label = null)
* @method Show\Field|Collection updated_at(string $label = null)
* @method Show\Field|Collection version(string $label = null)
* @method Show\Field|Collection detail(string $label = null)
* @method Show\Field|Collection created_at(string $label = null)
* @method Show\Field|Collection updated_at(string $label = null)
* @method Show\Field|Collection is_enabled(string $label = null)
* @method Show\Field|Collection extension(string $label = null)
* @method Show\Field|Collection icon(string $label = null)
* @method Show\Field|Collection order(string $label = null)
* @method Show\Field|Collection parent_id(string $label = null)
* @method Show\Field|Collection order(string $label = null)
* @method Show\Field|Collection icon(string $label = null)
* @method Show\Field|Collection uri(string $label = null)
* @method Show\Field|Collection
menu_id
(string $label = null)
* @method Show\Field|Collection
extension
(string $label = null)
* @method Show\Field|Collection permission_id(string $label = null)
* @method Show\Field|Collection menu_id(string $label = null)
* @method Show\Field|Collection slug(string $label = null)
* @method Show\Field|Collection http_method(string $label = null)
* @method Show\Field|Collection http_path(string $label = null)
* @method Show\Field|Collection slug(string $label = null)
* @method Show\Field|Collection role_id(string $label = null)
* @method Show\Field|Collection user_id(string $label = null)
* @method Show\Field|Collection value(string $label = null)
* @method Show\Field|Collection
avatar
(string $label = null)
* @method Show\Field|Collection
username
(string $label = null)
* @method Show\Field|Collection password(string $label = null)
* @method Show\Field|Collection avatar(string $label = null)
* @method Show\Field|Collection remember_token(string $label = null)
* @method Show\Field|Collection username(string $label = null)
* @method Show\Field|Collection box_num(string $label = null)
* @method Show\Field|Collection can_invite_num(string $label = null)
* @method Show\Field|Collection end_time(string $label = null)
* @method Show\Field|Collection invite_up_rate(string $label = null)
* @method Show\Field|Collection projectName(string $label = null)
* @method Show\Field|Collection price(string $label = null)
* @method Show\Field|Collection max_participants_num(string $label = null)
* @method Show\Field|Collection min_participants_num(string $label = null)
* @method Show\Field|Collection price(string $label = null)
* @method Show\Field|Collection project_icon(string $label = null)
* @method Show\Field|Collection projectName(string $label = null)
* @method Show\Field|Collection purchased(string $label = null)
* @method Show\Field|Collection rules(string $label = null)
* @method Show\Field|Collection start_time(string $label = null)
* @method Show\Field|Collection end_time(string $label = null)
* @method Show\Field|Collection status(string $label = null)
* @method Show\Field|Collection winner_list(string $label = null)
* @method Show\Field|Collection winner_num(string $label = null)
* @method Show\Field|Collection project_icon(string $label = null)
* @method Show\Field|Collection box_num(string $label = null)
* @method Show\Field|Collection rules(string $label = null)
* @method Show\Field|Collection can_invite_num(string $label = null)
* @method Show\Field|Collection invite_up_rate(string $label = null)
* @method Show\Field|Collection purchased(string $label = null)
* @method Show\Field|Collection winner_list(string $label = null)
* @method Show\Field|Collection uuid(string $label = null)
* @method Show\Field|Collection connection(string $label = null)
* @method Show\Field|Collection queue(string $label = null)
* @method Show\Field|Collection payload(string $label = null)
* @method Show\Field|Collection exception(string $label = null)
* @method Show\Field|Collection failed_at(string $label = null)
* @method Show\Field|Collection payload(string $label = null)
* @method Show\Field|Collection queue(string $label = null)
* @method Show\Field|Collection uuid(string $label = null)
* @method Show\Field|Collection email(string $label = null)
* @method Show\Field|Collection token(string $label = null)
* @method Show\Field|Collection tokenable_type(string $label = null)
* @method Show\Field|Collection tokenable_id(string $label = null)
* @method Show\Field|Collection abilities(string $label = null)
* @method Show\Field|Collection expires_at(string $label = null)
* @method Show\Field|Collection last_used_at(string $label = null)
* @method Show\Field|Collection tokenable_id(string $label = null)
* @method Show\Field|Collection tokenable_type(string $label = null)
* @method Show\Field|Collection expires_at(string $label = null)
* @method Show\Field|Collection address(string $label = null)
* @method Show\Field|Collection invitation_code(string $label = null)
* @method Show\Field|Collection user_address(string $label = null)
* @method Show\Field|Collection blind_box_id(string $label = null)
* @method Show\Field|Collection to(string $label = null)
* @method Show\Field|Collection hash(string $label = null)
* @method Show\Field|Collection blind_box_id(string $label = null)
* @method Show\Field|Collection user_address(string $label = null)
* @method Show\Field|Collection invitation_code(string $label = null)
* @method Show\Field|Collection Invitees_address(string $label = null)
* @method Show\Field|Collection Invitees_box_id(string $label = null)
* @method Show\Field|Collection winner_status(string $label = null)
* @method Show\Field|Collection transfer_status(string $label = null)
* @method Show\Field|Collection email_verified_at(string $label = null)
*/
class
Show
{}
...
...
lang/zh_CN/transfer-record.php
0 → 100644
View file @
f767583d
<?php
return
[
'labels'
=>
[
'TransferRecord'
=>
'TransferRecord'
,
'transfer-record'
=>
'TransferRecord'
,
],
'fields'
=>
[
'to'
=>
'收款地址'
,
'price'
=>
'转账数量'
,
'hash'
=>
'交易哈希'
,
'status'
=>
'转账状态'
,
'blind_box_id'
=>
'盲盒id'
,
],
'options'
=>
[
],
];
routes/api.php
View file @
f767583d
...
...
@@ -31,6 +31,8 @@
Route
::
post
(
'/BlindBox/buy/check'
,
'IndexController@usePayCheck'
);
# python检查回调
Route
::
post
(
'/BlindBox/buy/CheckCallback'
,
'IndexController@useCheckCallback'
);
# nodejs转账回调
Route
::
post
(
'/transfer/callback'
,
'IndexController@useNodeJsTransfer'
);
# 用户订单查询
Route
::
get
(
'/order'
,
'IndexController@useUserOrder'
);
# 获取收款地址
...
...
@@ -38,4 +40,8 @@
// ---------
# 获取用户信息
Route
::
get
(
'/user/info'
,
'IndexController@getUserInfo'
);
# 测试
# Route::get('/my/test', 'IndexController@useMyTest');
});
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment