1
0
Fork 0

调整设备信息查看

develop
vine_liutk 2023-05-11 11:38:46 +08:00
parent 7ffb4048b2
commit 96c4744bd7
1 changed files with 7 additions and 2 deletions

View File

@ -2,12 +2,11 @@
namespace App\Admin\Controllers;
use Slowlyo\OwlAdmin\Renderers\{Button, Form, Page, TableColumn, TextControl, Component, CRUDTable, Card, Video, DateRangeControl};
use Slowlyo\OwlAdmin\Renderers\{Button, Form, Page, TableColumn, TextControl, Json, Component, CRUDTable, Card, Video, DateRangeControl, Mapping};
use Slowlyo\OwlAdmin\Controllers\AdminController;
use App\Services\Admin\DeviceService;
use App\Models\Device;
use App\Models\Keyword;
use App\Admin\Components;
class DeviceController extends AdminController
{
@ -72,6 +71,12 @@ class DeviceController extends AdminController
TextControl::make()->static(true)->name('id')->label('ID'),
TextControl::make()->static(true)->name('name')->label('名称'),
TextControl::make()->static(true)->name('sn')->label('编号'),
TextControl::make()->static(true)->name('factory.name')->label('厂家'),
TextControl::make()->static(true)->name('model_sn')->label('型号'),
TextControl::make()->static(true)->name('type')->label('类型')->staticSchema(
Mapping::make()->map(Device::typeMap())),
TextControl::make()->static(true)->name('extends')->label('扩展信息')->staticSchema(
Json::make()),
TextControl::make()->static(true)->name('created_at')->label('创建时间'),
TextControl::make()->static(true)->name('updated_at')->label('更新时间')
]);