<?php
/**
 * ------------------------ 
 *  版权所有  www.tecmz.com
 *  商业版本请购买正版授权使用
 * ------------------------
*/ namespace Module\Faka\Core; use Illuminate\Events\Dispatcher; use Illuminate\Support\ServiceProvider; use ModStart\Admin\Config\AdminMenu; use ModStart\Admin\Widget\DashboardItemA; use ModStart\Core\Dao\ModelUtil; use ModStart\Layout\Row; use Module\Faka\Listener\FakaPayListener; use Module\Faka\Provider\FakaHomePageProvider; use Module\Faka\Type\ProductStockStatus; use Module\Vendor\Admin\Widget\AdminWidgetDashboard; use Module\Vendor\Admin\Widget\AdminWidgetLink; use Module\Vendor\Provider\HomePage\HomePageProvider; class ModuleServiceProvider extends ServiceProvider { public function boot(Dispatcher $WNxvc) { goto g322N; oZJPz: HomePageProvider::register(FakaHomePageProvider::class); goto tj1ia; OGDjV: AdminWidgetDashboard::registerIcon(function (Row $prd0q) { $prd0q->column(3, DashboardItemA::makeIconNumberTitle('iconfont icon-individual', ModelUtil::count('faka_product_stock', array('status' => ProductStockStatus::NOT_USED)), '可用卡券', modstart_admin_url('faka/product_stock'))); $prd0q->column(3, DashboardItemA::makeIconNumberTitle('iconfont icon-individual', ModelUtil::count('faka_product_stock', array('status' => ProductStockStatus::USED)), '已发放卡券', modstart_admin_url('faka/product_stock'))); $prd0q->column(3, DashboardItemA::makeIconNumberTitle('iconfont icon-list', ModelUtil::count('faka_product_order', array()), '订单总数', modstart_admin_url('faka/product_order'))); }); goto H_0QY; g322N: $WNxvc->subscribe(FakaPayListener::class); goto oZJPz; H_0QY: AdminMenu::register(function () { return array(array('title' => '发卡管理', 'icon' => 'list', 'sort' => 150, 'children' => array(array('title' => '数据分析', 'url' => '\\Module\\Faka\\Admin\\Controller\\DashboardController@index'), array('title' => '商品分类', 'url' => '\\Module\\Faka\\Admin\\Controller\\ProductCategoryController@index'), array('title' => '商品管理', 'url' => '\\Module\\Faka\\Admin\\Controller\\ProductController@index'), array('title' => '商品卡券', 'url' => '\\Module\\Faka\\Admin\\Controller\\ProductStockController@index'), array('title' => '发卡处理', 'url' => '\\Module\\Faka\\Admin\\Controller\\ProductOrderProcessorController@index'), array('title' => '发卡设置', 'url' => '\\Module\\Faka\\Admin\\Controller\\ConfigController@setting'))), array('title' => '财务中心', 'icon' => 'cny', 'sort' => 200, 'children' => array(array('title' => '业务订单', 'sort' => 999999, 'children' => array(array('title' => '发卡订单', 'url' => '\\Module\\Faka\\Admin\\Controller\\ProductOrderController@index')))))); }); goto U1Uxo; tj1ia: AdminWidgetLink::register(function () { return AdminWidgetLink::build('发卡系统', array(array('发卡首页', modstart_web_url('faka')), array('订单查询', modstart_web_url('faka/query')))); }); goto OGDjV; U1Uxo: } public function register() { } }