|
@@ -147,6 +147,7 @@ JS
|
|
|
$folderName = $folderModel->find($folder_id)->title;
|
|
|
return $folderName;
|
|
|
});
|
|
|
+ $grid->column('order');
|
|
|
$grid->column('enabled')->using(admin_trans_array(config('dictionary.enabled'))) ->label([
|
|
|
0 => 'danger',
|
|
|
1 => 'success',
|
|
@@ -196,7 +197,7 @@ JS
|
|
|
$grid->disableViewButton();
|
|
|
$grid->disablePerPages();
|
|
|
$grid->disableRefreshButton();
|
|
|
- $grid->model()->orderBy('order', 'asc')->orderBy('id', 'desc');
|
|
|
+ $grid->model()->orderBy('order', 'desc')->orderBy('id', 'desc');
|
|
|
//弹窗大小
|
|
|
$grid->setDialogFormDimensions('830px','670px');
|
|
|
});
|
|
@@ -276,6 +277,9 @@ JS
|
|
|
->saving(function ($input) {
|
|
|
return json_encode($input);
|
|
|
});
|
|
|
+ $form->number('order')
|
|
|
+ ->default(0)
|
|
|
+ ->rules('numeric');
|
|
|
$form->switch('enabled')->default(1);
|
|
|
|
|
|
})->tab(admin_trans_label('cover'), function (Form $form) {
|