quanwei
2025-11-03 ef5d748e3e3331bd20d4065c33e7867c2637d1db
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
<?php
 
namespace app\branch\controller;
 
use app\common\model\settings\Setting as SettingModel;
use app\branch\service\ShopService;
 
/**
 * 后台首页控制器
 */
class Index extends Controller
{
    /**
     * 后台首页
     */
    public function index()
    {
        $service = new ShopService($this->getBranchId());
        return $this->renderSuccess('', ['data' => $service->getHomeData()]);
    }
 
    /**
     * 登录数据
     */
    public function base()
    {
 
        $config = SettingModel::getSysConfig();
        $settings = [
            'branch_name' => $config['branch_name'],
            'branch_bg_img' => $config['branch_bg_img']
        ];
        return $this->renderSuccess('', compact('settings'));
    }
}