finance-pay/app/common/enum/MenuEnum.php

60 lines
1.8 KiB
PHP
Raw Permalink Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

<?php
// +----------------------------------------------------------------------
// | likeadmin快速开发前后端分离管理后台PHP版
// +----------------------------------------------------------------------
// | 欢迎阅读学习系统程序代码,建议反馈是我们前进的动力
// | 开源版本可自由商用可去除界面版权logo
// | gitee下载https://gitee.com/likeshop_gitee/likeadmin
// | github下载https://github.com/likeshop-github/likeadmin
// | 访问官网https://www.likeadmin.cn
// | likeadmin团队 版权所有 拥有最终解释权
// +----------------------------------------------------------------------
// | author: likeadminTeam
// +----------------------------------------------------------------------
namespace app\common\enum;
class MenuEnum
{
//商城页面
const SHOP_PAGE = [
[
'index' => 1,
'name' => '首页',
'path' => '/pages/index/index',
'params' => [],
'type' => 'shop',
],
];
//菜单类型
const NAVIGATION_HOME = 1;//首页导航
const NAVIGATION_PERSONAL = 2;//个人中心
//链接类型
const LINK_SHOP = 1;//商城页面
const LINK_CATEGORY = 2;//分类页面
const LINK_CUSTOM = 3;//自定义链接
/**
* @notes 链接类型
* @param bool $value
* @return string|string[]
* @author ljj
* @date 2022/2/14 12:14 下午
*/
public static function getLinkDesc($value = true)
{
$data = [
self::LINK_SHOP => '商城页面',
self::LINK_CATEGORY => '分类页面',
self::LINK_CUSTOM => '自定义链接'
];
if ($value === true) {
return $data;
}
return $data[$value];
}
}