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
8f72edc3
Commit
8f72edc3
authored
Mar 17, 2023
by
haojie
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
转账记录表
parent
f767583d
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
22 additions
and
4 deletions
+22
-4
app/Admin/Controllers/TransferRecordController.php
+20
-4
app/Admin/routes.php
+2
-0
No files found.
app/Admin/Controllers/TransferRecordController.php
View file @
8f72edc3
...
@@ -18,18 +18,34 @@ class TransferRecordController extends AdminController
...
@@ -18,18 +18,34 @@ class TransferRecordController extends AdminController
protected
function
grid
()
protected
function
grid
()
{
{
return
Grid
::
make
(
new
TransferRecord
(),
function
(
Grid
$grid
)
{
return
Grid
::
make
(
new
TransferRecord
(),
function
(
Grid
$grid
)
{
// 新增按钮-禁用
$grid
->
disableCreateButton
();
// 行操作--禁用
$grid
->
disableActions
();
// 行选择器
$grid
->
disableRowSelector
();
$grid
->
column
(
'id'
)
->
sortable
();
$grid
->
column
(
'id'
)
->
sortable
();
$grid
->
column
(
'to'
);
$grid
->
column
(
'to'
);
$grid
->
column
(
'price'
);
$grid
->
column
(
'price'
);
$grid
->
column
(
'hash'
);
$grid
->
column
(
'hash'
);
$grid
->
column
(
'status'
);
$grid
->
column
(
'status'
)
->
using
([
1
=>
'转账成功'
,
2
=>
'转账失败'
])
->
label
([
'default'
=>
'primary'
,
// 设置默认颜色,不设置则默认为 default
1
=>
'primary'
,
2
=>
'danger'
,
]);
$grid
->
column
(
'type'
)
->
using
([
1
=>
'开奖'
,
2
=>
'退款'
])
->
label
([
'default'
=>
'primary'
,
// 设置默认颜色,不设置则默认为 default
1
=>
'primary'
,
2
=>
'danger'
,
]);
$grid
->
column
(
'blind_box_id'
);
$grid
->
column
(
'blind_box_id'
);
$grid
->
column
(
'created_at'
);
$grid
->
column
(
'created_at'
);
$grid
->
column
(
'updated_at'
)
->
sortable
();
$grid
->
column
(
'updated_at'
)
->
sortable
();
$grid
->
filter
(
function
(
Grid\Filter
$filter
)
{
$grid
->
filter
(
function
(
Grid\Filter
$filter
)
{
$filter
->
equal
(
'id'
);
$filter
->
equal
(
'id'
);
$filter
->
equal
(
'to'
);
$filter
->
equal
(
'hash'
);
});
});
});
});
}
}
...
@@ -69,7 +85,7 @@ protected function form()
...
@@ -69,7 +85,7 @@ protected function form()
$form
->
text
(
'hash'
);
$form
->
text
(
'hash'
);
$form
->
text
(
'status'
);
$form
->
text
(
'status'
);
$form
->
text
(
'blind_box_id'
);
$form
->
text
(
'blind_box_id'
);
$form
->
display
(
'created_at'
);
$form
->
display
(
'created_at'
);
$form
->
display
(
'updated_at'
);
$form
->
display
(
'updated_at'
);
});
});
...
...
app/Admin/routes.php
View file @
8f72edc3
...
@@ -16,4 +16,6 @@
...
@@ -16,4 +16,6 @@
$router
->
resource
(
'/blindBoxSetting/setting'
,
'BlindBoxListController'
);
$router
->
resource
(
'/blindBoxSetting/setting'
,
'BlindBoxListController'
);
$router
->
resource
(
'/blindBoxSetting/record'
,
'BlindBoxRecordController'
);
$router
->
resource
(
'/blindBoxSetting/record'
,
'BlindBoxRecordController'
);
$router
->
resource
(
'/setAddress'
,
'SetAddressController'
);
$router
->
resource
(
'/setAddress'
,
'SetAddressController'
);
# 转账记录
$router
->
resource
(
'/transferRecord'
,
'TransferRecordController'
);
});
});
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