\app\store\serviceMenus

商家后台菜单业务 Class Menus

Summary

Methods
Properties
Constants
getInstance()
getMenus()
second()
$instance
No constants found
No protected methods found
No protected properties found
N/A
__construct()
__clone()
first()
third()
getMenusIndexUrls()
getAuthUrl()
$auth
N/A

Properties

$instance

$instance : self

Type

self — 存放实例

Methods

getInstance()

getInstance() : \app\store\service\Menus

公有化获取实例方法

Throws

\think\exception\DbException

Returns

\app\store\service\Menus

getMenus()

getMenus(  $routeUri,   $group) : array|mixed

后台菜单配置

Parameters

$routeUri
$group

Throws

\think\db\exception\DataNotFoundException
\think\db\exception\ModelNotFoundException
\think\exception\DbException

Returns

array|mixed

second()

second(array  $menus,   $routeUri) 

二级菜单

Parameters

array $menus
$routeUri

Throws

\think\db\exception\DataNotFoundException
\think\db\exception\ModelNotFoundException
\think\exception\DbException

__construct()

__construct() 

私有化构造方法 Menus constructor.

Throws

\think\exception\DbException

__clone()

__clone() 

私有化克隆方法

first()

first(  $menus,   $routeUri,   $group) 

一级菜单

Parameters

$menus
$routeUri
$group

Throws

\think\db\exception\DataNotFoundException
\think\db\exception\ModelNotFoundException
\think\exception\DbException

third()

third(array  $menus,   $routeUri,   $secondUris) 

三级菜单

Parameters

array $menus
$routeUri
$secondUris

Throws

\think\db\exception\DataNotFoundException
\think\db\exception\ModelNotFoundException
\think\exception\DbException

getMenusIndexUrls()

getMenusIndexUrls(array  $menus, integer  $level = 1) : array|null

获取指定菜单下的所有索引url

Parameters

array $menus
integer $level

Returns

array|null

getAuthUrl()

getAuthUrl(  $urls) : boolean

取出通过权限验证urk作为index

Parameters

$urls

Throws

\think\db\exception\DataNotFoundException
\think\db\exception\ModelNotFoundException
\think\exception\DbException

Returns

boolean