<?php
 namespace App\Admin\Controller; use Illuminate\Routing\Controller; use ModStart\Admin\Layout\AdminPage; use ModStart\Admin\Widget\DashboardItemA; use ModStart\Admin\Widget\SecurityTooltipBox; use ModStart\Core\Dao\ModelUtil; use ModStart\Core\Util\ColorUtil; use ModStart\Layout\Row; use ModStart\Widget\Box; use ModStart\Widget\Chart\Line; use Module\AdminManager\Widget\CopyrightWidget; class IndexController extends Controller { public function index(AdminPage $page) { return $page->pageTitle(L('Dashboard')) ->row(new SecurityTooltipBox()) ->append(Box::make(new Row(function (Row $row) { $row->column(4, DashboardItemA::makeIconNumberTitle( 'iconfont icon-user', ModelUtil::count('member_user'), '用户', modstart_admin_url('member'), ColorUtil::randomColor() )); $row->column(4, DashboardItemA::makeIconNumberTitle( 'iconfont icon-fill222', ModelUtil::count('link'), '短链接', modstart_admin_url('link'), ColorUtil::randomColor() )); $row->column(4, DashboardItemA::makeIconNumberTitle( 'iconfont icon-book', ModelUtil::count('link_domain'), '短网址域名', modstart_admin_url('link_domain'), ColorUtil::randomColor() )); }), '基本概况', 'transparent')->style('margin-bottom:0rem;')) ->append(new CopyrightWidget()); } }