Commit 63165f9d by 杨树贤

界面优化

parent 8239ff01
...@@ -18,6 +18,13 @@ class InquiryController extends AdminController ...@@ -18,6 +18,13 @@ class InquiryController extends AdminController
protected function grid() protected function grid()
{ {
return Grid::make(new Inquiry(['user']), function (Grid $grid) { return Grid::make(new Inquiry(['user']), function (Grid $grid) {
$grid->showFilter();
$grid->filter(function($filter){
$filter->expand(true);
$filter->like('inquiry_sn');
});
$grid->column('inquiry_id')->sortable(); $grid->column('inquiry_id')->sortable();
$grid->column('user.email'); $grid->column('user.email');
$grid->column('inquiry_sn'); $grid->column('inquiry_sn');
...@@ -25,14 +32,14 @@ class InquiryController extends AdminController ...@@ -25,14 +32,14 @@ class InquiryController extends AdminController
-1 => 'danger', -1 => 'danger',
0 => 'primary', 0 => 'primary',
1 => 'success' 1 => 'success'
]); ])->sortable();
$grid->column('remark'); $grid->column('remark');
$grid->column('priority')->using(admin_trans('inquiry.options.priority'))->badge([ $grid->column('priority')->using(admin_trans('inquiry.options.priority'))->badge([
1 => 'primary', 1 => 'primary',
2 => 'success', 2 => 'success',
3 => 'danger' 3 => 'danger'
]);; ]);
$grid->column('user_types'); $grid->column('user_types')->using(admin_trans('inquiry.options.user_types'));
$grid->column('processing_time')->display(function ($time) { $grid->column('processing_time')->display(function ($time) {
return $time ? date('Y-m-d H:i:s', $time) : ''; return $time ? date('Y-m-d H:i:s', $time) : '';
}); });
......
...@@ -20,9 +20,9 @@ class AdminSetting extends Form implements LazyRenderable ...@@ -20,9 +20,9 @@ class AdminSetting extends Form implements LazyRenderable
'default' => 'Default', 'default' => 'Default',
'blue' => 'Blue', 'blue' => 'Blue',
'blue-light' => 'Blue Light', 'blue-light' => 'Blue Light',
'layui-green' => 'Layui Green', // 'layui-green' => 'Layui Green',
// 'blue-dark' => 'Blue Dark', // 'blue-dark' => 'Blue Dark',
'green' => 'Green', 'green' => 'Layui Green',
]; ];
protected $sidebarStyle = [ protected $sidebarStyle = [
......
...@@ -66,18 +66,22 @@ a.nav-link.active { ...@@ -66,18 +66,22 @@ a.nav-link.active {
background-color: $primaryColor!important; background-color: $primaryColor!important;
} }
body:not(.dark-mode) .table-collapse .custom-data-table tbody tr { body:not(.dark-mode).custom-data-table tbody tr {
height:30px !important; height:30px !important;
} }
body:not(.dark-mode) .table-collapse .custom-data-table tbody td { body:not(.dark-mode) .custom-data-table tbody td {
height:30px; height:30px;
} }
body.dark-mode .table-collapse table.custom-data-table.data-table tbody td { body.dark-mode .custom-data-table tbody td {
height:30px; height:30px;
} }
thead tr th{
background: #f2f2f2;
}
.form-group { .form-group {
margin-bottom:5px; margin-bottom:5px;
} }
...@@ -156,14 +160,15 @@ HTML ...@@ -156,14 +160,15 @@ HTML
Grid::resolving(function (Grid $grid) { Grid::resolving(function (Grid $grid) {
$grid->tableCollapse(true); $grid->tableCollapse(true);
// $grid->withBorder(); $grid->withBorder();
// $grid->disableViewButton(); // $grid->disableViewButton();
$grid->disableEditButton(); $grid->disableEditButton();
$grid->toolsWithOutline(false); $grid->toolsWithOutline(false);
$grid->paginate(20); $grid->paginate(15);
$grid->setDialogFormDimensions('80%', '90%'); $grid->setDialogFormDimensions('80%', '90%');
$grid->showQuickEditButton(); $grid->showQuickEditButton();
$grid->fixColumns(1); $grid->fixColumns(1);
$grid->addTableClass(['table-text-center']);
$grid->filter(function (Grid\Filter $filter) { $grid->filter(function (Grid\Filter $filter) {
$filter->panel(); $filter->panel();
}); });
......
This diff could not be displayed because it is too large.
This diff could not be displayed because it is too large.
...@@ -5,6 +5,7 @@ return [ ...@@ -5,6 +5,7 @@ return [
'inquiry' => 'Inquiry', 'inquiry' => 'Inquiry',
], ],
'fields' => [ 'fields' => [
'inquiry_id' => 'Id',
'sales_name' => 'Sales Name', 'sales_name' => 'Sales Name',
'inquiry_sn' => 'Inquiry Sn', 'inquiry_sn' => 'Inquiry Sn',
'status' => 'Status', 'status' => 'Status',
...@@ -14,6 +15,7 @@ return [ ...@@ -14,6 +15,7 @@ return [
'processing_time' => 'Processing Time', 'processing_time' => 'Processing Time',
'create_time' => 'Create Time', 'create_time' => 'Create Time',
'update_time' => 'update Time', 'update_time' => 'update Time',
'email' => 'email',
], ],
'options' => [ 'options' => [
'status' => [ 'status' => [
...@@ -25,6 +27,10 @@ return [ ...@@ -25,6 +27,10 @@ return [
0 => 'low', 0 => 'low',
1 => 'middle', 1 => 'middle',
2 => 'high' 2 => 'high'
],
'user_types' => [
1 => 'person',
2 => 'company'
] ]
], ],
]; ];
...@@ -5,6 +5,7 @@ return [ ...@@ -5,6 +5,7 @@ return [
'inquiry' => 'Inquiry', 'inquiry' => 'Inquiry',
], ],
'fields' => [ 'fields' => [
'inquiry_id' => 'Id',
'sales_id' => '业务员ID', 'sales_id' => '业务员ID',
'inquiry_sn' => '询价单号', 'inquiry_sn' => '询价单号',
'status' => '处理状态', 'status' => '处理状态',
...@@ -14,6 +15,9 @@ return [ ...@@ -14,6 +15,9 @@ return [
'processing_time' => '处理时间', 'processing_time' => '处理时间',
'create_time' => '添加时间', 'create_time' => '添加时间',
'update_time' => '修改时间', 'update_time' => '修改时间',
'user' =>[
'email' => '邮箱',
]
], ],
'options' => [ 'options' => [
'status' => [ 'status' => [
...@@ -25,6 +29,10 @@ return [ ...@@ -25,6 +29,10 @@ return [
0 => '低', 0 => '低',
1 => '中', 1 => '中',
2 => '高' 2 => '高'
],
'user_types' => [
1 => '个人',
2 => '公司'
] ]
], ],
]; ];
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment