Method and system for managing menu permission by using routing tree wildcard characters
Through the routing tree wildcard management menu permissions, the complex menu configuration problem caused by dynamic parameters of RESTful style URL addresses is solved, efficient menu path management and permission verification is realized, flexible menu address rules are supported, and duplicate workload is reduced.
Patent Information
- Application Number
- CN202411306623.1
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-09-19
- Publication Date
- 2025-01-03
- Estimated Expiration
- 2044-09-19
AI Technical Summary
When managing RESTful-style URL addresses, dynamic parameters lead to complex menu configuration and permission allocation, and adding interface versions requires repeated updates to the background menu configuration and permissions, which violates industry standards.
The route tree wildcards are used to manage menu permissions, and by defining the RouteNode structure and TreeMeta structure, the menu URL path is divided to form a tree structure, and the wildcards are used to support flexible menu address rules, and user permissions are judged in permission verification.
It realizes efficient menu path and menu number relationship management, supports fast menu routing and search, reduces duplicate workload, and complies with the RESTful interface design principles.
Smart Images

Figure CN119248147A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of computer communication, and in particular to a method-level system for managing menu permissions using routing tree wildcards. Background Art
[0002] In the backend system, each function menu corresponds to a specific URL address, and users can only access it if the menu is authorized. For example, suppose there is an order deletion interface that follows the RESTful style, whose address is api.xxx.com / order / {orderid}, and uses the HTTP DELETE request method. This means that the {orderid} in the URL changes dynamically every time it is accessed, so it is obviously not practical to configure the deletion address of all orders on the menu. The traditional solution is not to use the RESTful style URL design, but to adopt a routing method such as api.xxx.com / order / del? id={orderid}. However, this method does not conform to the industry standard RESTful interface design principles. In addition, if the interface needs to include a version number, such as api.xxx.com / {version} / order, then each time a new interface version is added, the backend menu configuration and permission allocation need to be updated, which will bring repeated workload. Summary of the invention
[0003] To overcome the above problems, the purpose of the present invention is to provide a method for managing menu permissions using routing tree wildcards, which can support wildcards to manage the relationship between menu paths and associated menu numbers and support fast menu routing and search.
[0004] The present invention is implemented by the following scheme: a method for managing menu permissions using a routing tree wildcard, the method comprising the following steps:
[0005] Step S1, define a RouteNode structure to represent a routing tree node, including the following fields: Path is used for the path of the current node, Children is a dictionary set of child nodes, Data is an array of associated menu numbers, and define a TreeMeta structure, including a pointer Root pointing to the root node, which is used to store global routing tree data in memory;
[0006] Step S2, traverse all menu data in the database, split each menu path Url into an array array according to ' / ', loop each array element, traverse and create nodes starting from the root node Root;
[0007] Step S3, when the user accesses the menu, the system obtains the menu path Url, splits the Url into an array array by ' / ', recursively searches from the root node of the global routing tree layer by layer, matches the path Path of the routing tree node and the value of the path array element, and finds the menu number in the last element of the path;
[0008] Step S4, the system loops through the menu number set, reads the permission table to determine whether the user has permission for the menu number, succeeds if any of the menu numbers have permission, and returns failure if none of them have permission.
[0009] Furthermore, the loop of each array element in step S2, traversing and creating nodes starting from the root node Root is further as follows: if the node does not exist, a new node is created; if it already exists, it continues to move downward until the last part of the path is processed, and the menu number is appended to the Data array of the last routing node.
[0010] Furthermore, the menu number in the last element of the path found in step S3 is further: the path Path of the matching routing tree node and the value of the path array element. If there is a wildcard '*' or a child node of an element of the current menu interface address array in the Children collection of the current node, continue to search downward until the last element of the path is found, and the Data array of the node contains the menu number, indicating that the corresponding menu number set is successfully found; if there is no matching address and there is no child node with a wildcard '*', it means that no matching path is found and failure is returned.
[0011] A system for managing menu permissions using routing tree wildcards, the system comprising the definition module, the node creation module, the menu number search module and the permission verification module;
[0012] The definition module: defines a RouteNode structure to represent a routing tree node, including the following fields: Path is used for the path of the current node, Children is a dictionary set of child nodes, Data is an array of associated menu numbers, and defines a TreeMeta structure, including a pointer Root pointing to a root node, which is used to store global routing tree data in memory;
[0013] The node creation module: traverses all menu data in the database, splits each menu path Url into an array array according to ' / ', loops each array element, traverses and creates nodes starting from the root node Root;
[0014] The menu number search module: when the user accesses the menu, the system obtains the menu path Url, splits the Url into an array array by ' / ', recursively searches from the root node of the global routing tree layer by layer, matches the path Path of the routing tree node and the value of the path array element, and finds the menu number in the last element of the path;
[0015] The authority verification module: the system loops through the menu number set, reads the authority table to determine whether the user has the authority to the menu number, succeeds if any of the menu numbers has the authority, and returns failure if none of them has the authority.
[0016] Furthermore, the node creation module loops through each array element, traverses and creates nodes starting from the root node Root, and further: if the node does not exist, a new node is created; if it already exists, it continues to move downward until the last part of the path is processed, and the menu number is appended to the Data array of the last routing node.
[0017] Furthermore, the menu number in the last element of the path found in the menu number search module is further: the path Path of the matching routing tree node and the value of the path array element. If there is a wildcard '*' or a child node of an element of the current menu interface address array in the Children collection of the current node, continue to search downward until the last element of the path is found, and the Data array of the node contains the menu number, indicating that the corresponding menu number set is successfully found; if there is no matching address and there is no child node with the wildcard '*', it means that no matching path is found and failure is returned.
[0018] The beneficial effects of the present invention are as follows: the present invention organizes the path into a tree structure by segmenting the menu URL path, and the leaf node maintains the relationship between the menu path and the associated menu number. Efficient data search can be performed through the tree structure, and wildcards are supported to replace the menu path, thereby supporting more flexible menu address rules. BRIEF DESCRIPTION OF THE DRAWINGS
[0019] Figure 1 It is a schematic flow chart of the method of the present invention.
[0020] Figure 2 It is a system principle block diagram of the present invention. DETAILED DESCRIPTION
[0021] The present invention will be further described below in conjunction with the accompanying drawings.
[0022] See also Figure 1 As shown, a method for managing menu permissions using a routing tree wildcard of the present invention comprises the following steps:
[0023] Step S1, define a RouteNode structure to represent a routing tree node, including the following fields: Path is used for the path of the current node, Children is a dictionary set of child nodes, Data is an array of associated menu numbers, and define a TreeMeta structure, including a pointer Root pointing to the root node, which is used to store global routing tree data in memory;
[0024] Step S2, traverse all menu data in the database, split each menu path Url into an array array according to ' / ', loop each array element, traverse and create nodes starting from the root node Root;
[0025] Step S3, when the user accesses the menu, the system obtains the menu path Url, splits the Url into an array array by ' / ', recursively searches from the root node of the global routing tree layer by layer, matches the path Path of the routing tree node and the value of the path array element, and finds the menu number in the last element of the path;
[0026] Step S4, the system loops through the menu number set, reads the permission table to determine whether the user has permission for the menu number, succeeds if any of the menu numbers have permission, and returns failure if none of them have permission.
[0027] A method for managing menu permissions using routing tree wildcards.
[0028] 1. Define a RouteNode structure to represent the routing tree node, which contains the following fields: Path is used for the path of the current node, Children is a dictionary set of child nodes, Data is an array of associated menu numbers, and define a TreeMeta structure, which contains a pointer Root pointing to the root node, which is used to store global routing tree data in memory;
[0029] For example: 1. First, define a RouteNode structure to represent the routing tree node, which contains the following fields: Path is used for the path of the current node, Children is a dictionary collection of child nodes, and Data is an array of associated menu numbers.
[0030] / / RouteNode routing tree
[0031] type RouteNode struct{
[0032] Path string
[0033] Children map[string]*RouteNode
[0034] Data[]int / / Menu addresses can be repeated, so there may be multiple
[0035] }
[0036] Define another TreeMeta structure, which contains a pointer Root pointing to the root node RouteNode, which is used to store global routing tree data in memory.
[0037] type TreeMeta struct {
[0038] Root*RouteNode
[0039] }
[0040] 2. Traverse all menu data in the database, split each menu path Url into an array according to ' / ', loop each array element, traverse and create nodes starting from the root node Root;
[0041] Loop through each array element, starting from the root node Root, and traverse and create nodes further: if the node does not exist, create a new node; if it already exists, continue to move down until the last part of the path is processed, and append the menu number to the Data array of the last routing node.
[0042] For example: 2. Get all menu data from the database. For example, there are 3 menu data.
[0043] [{id:1,url:https: / / www.xxx.com / user},{id:2,url:https: / / www.xxx.com / user / *},
[0044] {id:3,url:https: / / www.bbb.com / user}].
[0045] Split the URL of the first menu into an array array by ' / ' to get [https: / / www.xxx.com,user], loop the array, define a current node pointer current to point to the root node Root, start judging from the root node Root, if current.Children is empty, initialize current.Children, and then judge
[0046] Does current.Children have the first element https: / / www.xxx.com? If not, add the address of the current element to current.Children, that is, current.Children[https: / / www.xxx.com]=
[0047] &RouteNode{Path:https: / / www.xxx.com}, and then point current to
[0048] current.Children[https: / / www.xxx.com]. Then determine whether there is a second element user in current.Children. If not, add current.Children[user]=&RouteNode{Path:
[0049] user}, if user is the last array element, then add the menu number to the data,
[0050] current.Children[user].Data=append(current.Children[user].Data,1).
[0051] Then loop the second menu https: / / www.xxx.com / user / * and convert it into an array
[0052] {https: / / www.xxx.com,user,api}, start searching from the root node. Since nodes already exist in the first two parts,
[0053] * is the last array element, then add the menu number to the data Data, current.Children[*].Data=
[0054] append(current.Children[*].Data,2). The third menu is also added to the routing tree according to the same rules.
[0055] The code is as follows:
[0056] / / InsertRoute inserts the route into the routing tree
[0057] func(rt*TreeMeta)InsertRoute(resource*en.Resource){
[0058] / / segmentation
[0059] path:=resource.Path
[0060] array:=URLToArray(path,true)
[0061] count:=len(array)
[0062] current:=rt.Rootfor i,part:=range array{
[0063] / / If the child nodes of the current node are empty, create a new child node mapping
[0064] if current.Children == nil {
[0065] current.Children=make(map[string]*RouteNode)
[0066] }
[0067] / / If the current part does not exist in the child node, create a new node
[0068] if_,exists:=current.Children[part];! exists{
[0069] current.Children[part]=&RouteNode{
[0070] Path:part,
[0071] }
[0072] }
[0073] / / If it is the last node, append menu data
[0074] if i == count - 1 {
[0075] if current.Children[part].Data==nil{
[0076] current.Children[part].Data=make([]int,0)
[0077] }
[0078] current.Children[part].Data=append(current.Children[part].Data,resource.ID)
[0079] }
[0080] / / Move to the child node corresponding to the current part
[0081] current=current.Children[part]
[0082] }
[0083] }
[0084] 3. When the user accesses the menu, the system obtains the menu path Url, splits the Url into an array by ' / ', recursively searches from the root node of the global routing tree layer by layer, matches the path Path of the routing tree node and the value of the path array element, and finds the menu number in the last element of the path;
[0085] The menu number in the last element of the found path is further: the path Path of the matching routing tree node and the value of the path array element. If there is a wildcard '*' or a child node of the element of the current menu interface address array in the Children collection of the current node, continue to search downward until the last element of the path is found, and the Data array of the node contains the menu number, indicating that the corresponding menu number set is successfully found; if there is no matching address and there is no child node with the wildcard '*', it means that no matching path is found and failure is returned.
[0086] For example: 3 When a user accesses the menu, if a user deletion operation is performed, the system obtains the accessed deletion interface Url, for example, the interface address is https: / / www.xxx.com / user / 1. Split the Url into an array array by ' / ' to obtain [https: / / www.xxx.com, user, 1], and recursively search from the root node of the global routing tree TreeMeta, obtain the array length len to obtain 3, define a temporary variable index = 0 to record the search level, and add 1 each time you go to the next level to search. First, check whether Root.Children contains the node of the first element https: / / www.xxx.com. If it does, continue to search whether the child node of https: / / www.xxx.com is user. If it does, continue to search whether the child node of user is 1. If the current routing tree does not have node 1, then search whether the child node of user is *. Since * exists and the current search level 3 is equal to the array length 3, the menu number set Data of the current node * is returned to obtain the menu number array [2].
[0087] The code is as follows:
[0088] / / FindRoutes finds all routes that match the given path
[0089] func(rt*TreeMeta)FindRoutes(path string)[]*en.Resource{
[0090] var result[]*en.Resource
[0091] / / segmentation
[0092] array:=URLToArray(path,true)
[0093] / / Define an internal recursive function to find matching routes starting from the specified node var find func(node*RouteNode,index int)
[0094] find=func(node*RouteNode,index int){
[0095] if node == nil {
[0096] return
[0097] }
[0098] if index>=len(array){
[0099] / / If the target level is reached, the data will be returned.
[0100] if node.Data!=nil{
[0101] result=append(result,node.Data...)
[0102] return
[0103] }
[0104] return
[0105] }
[0106] / / Get the path part corresponding to the current index
[0107] part:=array[index]
[0108] / / If the current node has a child node of this path part, continue to search downward if child, exists: = node.Children[part]; exists {
[0109] find(child,index+1)
[0110] }
[0111] / / If the current node has a wildcard (*) child node, continue to search downward if wildcardChild, exists: = node.Children["*"]; exists{ find(wildcardChild, index+1)
[0112] }
[0113] }
[0114] / / Start from the root node to find the matching path
[0115] find(rt.Root,0)
[0116] return result
[0117] }
[0118] 4. The system loops through the menu number set and reads the permission table to determine whether the user has permission for the menu number. If any of the menu numbers has permission, the system succeeds. If none of them has permission, the system returns failure.
[0119] For example: the system loops through menu number array [2], reads the permission table to determine whether the current user has permission for menu number array [2]. If yes, it returns success, otherwise it returns failure. If there are multiple menu numbers in the menu number set, success is returned if any one of them has permission.
[0120] See also Figure 2 As shown, the present invention also provides a system for managing menu permissions using routing tree wildcards, the system comprising the definition module, the node creation module, the menu number search module and the permission verification module;
[0121] The definition module: defines a RouteNode structure to represent a routing tree node, including the following fields: Path is used for the path of the current node, Children is a dictionary set of child nodes, Data is an array of associated menu numbers, and defines a TreeMeta structure, including a pointer Root pointing to a root node, which is used to store global routing tree data in memory;
[0122] For example: 1. First, define a RouteNode structure to represent the routing tree node, which contains the following fields: Path is used for the path of the current node, Children is a dictionary collection of child nodes, and Data is an array of associated menu numbers.
[0123] / / RouteNode routing tree
[0124] type RouteNode struct{
[0125] Path string
[0126] Children map[string]*RouteNode
[0127] Data[]int / / Menu addresses can be repeated, so there may be multiple
[0128] }
[0129] Define another TreeMeta structure, which contains a pointer Root pointing to the root node RouteNode, which is used to store global routing tree data in memory.
[0130] type TreeMeta struct {
[0131] Root*RouteNode
[0132] }
[0133] The node creation module: traverses all menu data in the database, splits each menu path Url into an array array according to ' / ', loops each array element, traverses and creates nodes starting from the root node Root;
[0134] Loop through each array element, starting from the root node Root, and traverse and create nodes further: if the node does not exist, create a new node; if it already exists, continue to move down until the last part of the path is processed, and append the menu number to the Data array of the last routing node.
[0135] For example: 2. Get all menu data from the database. For example, there are 3 menu data.
[0136] [{id:1,url:https: / / www.xxx.com / user},{id:2,url:https: / / www.xxx.com / user / *},
[0137] {id:3,url:https: / / www.bbb.com / user}].
[0138] Split the URL of the first menu into an array array by ' / ' to get [https: / / www.xxx.com,user], loop the array, define a current node pointer current to point to the root node Root, start judging from the root node Root, if current.Children is empty, initialize current.Children, and then judge
[0139] Does current.Children have the first element https: / / www.xxx.com? If not, add the address of the current element to current.Children, that is, current.Children[https: / / www.xxx.com]=
[0140] &RouteNode{Path:https: / / www.xxx.com}, and then point current to
[0141] current.Children[https: / / www.xxx.com]. Then determine whether there is a second element user in current.Children. If not, add current.Children[user]=&RouteNode{Path:
[0142] user}, if user is the last array element, then add the menu number to the data,
[0143] current.Children[user].Data=append(current.Children[user].Data,1).
[0144] Then loop the second menu https: / / www.xxx.com / user / * and convert it into an array
[0145] {https: / / www.xxx.com,user,api}, start searching from the root node. Since the first two parts already have nodes, * is the last array element, add the menu number to the data Data, current.Children[*].Data = append(current.Children[*].Data,2). The third menu is also added to the routing tree according to the same rule.
[0146] The code is as follows:
[0147] / / InsertRoute inserts the route into the routing tree
[0148] func(rt*TreeMeta)InsertRoute(resource*en.Resource){
[0149] / / segmentation
[0150] path:=resource.Path
[0151] array:=URLToArray(path,true)
[0152] count:=len(array)
[0153] current:=rt.Rootfor i,part:=range array{
[0154] / / If the child nodes of the current node are empty, create a new child node mapping
[0155] if current.Children == nil {
[0156] current.Children=make(map[string]*RouteNode)
[0157] }
[0158] / / If the current part does not exist in the child node, create a new node
[0159] if_,exists:=current.Children[part];! exists{
[0160] current.Children[part]=&RouteNode{
[0161] Path:part,
[0162] }
[0163] }
[0164] / / If it is the last node, append menu data
[0165] if i == count - 1 {
[0166] if current.Children[part].Data==nil{
[0167] current.Children[part].Data=make([]int,0)
[0168] }
[0169] current.Children[part].Data=append(current.Children[part].Data,
[0170] resource.ID)
[0171] }
[0172] / / Move to the child node corresponding to the current part
[0173] current=current.Children[part]
[0174] }
[0175] }
[0176] The menu number search module: when the user accesses the menu, the system obtains the menu path Url, splits the Url into an array array by ' / ', recursively searches from the root node of the global routing tree layer by layer, matches the path Path of the routing tree node and the value of the path array element, and finds the menu number in the last element of the path;
[0177] The menu number in the last element of the found path is further: the path Path of the matching routing tree node and the value of the path array element. If there is a wildcard '*' or a child node of the element of the current menu interface address array in the Children collection of the current node, continue to search downward until the last element of the path is found, and the Data array of the node contains the menu number, indicating that the corresponding menu number set is successfully found; if there is no matching address and there is no child node with the wildcard '*', it means that no matching path is found and failure is returned.
[0178] For example: 3 When a user accesses the menu, if a user deletion operation is performed, the system obtains the accessed deletion interface Url, for example, the interface address is https: / / www.xxx.com / user / 1. Split the Url into an array array by ' / ' to obtain [https: / / www.xxx.com, user, 1], and recursively search from the root node of the global routing tree TreeMeta, obtain the array length len to obtain 3, define a temporary variable index = 0 to record the search level, and add 1 each time you go to the next level to search. First, check whether Root.Children contains the node of the first element https: / / www.xxx.com. If it does, continue to search whether the child node of https: / / www.xxx.com is user. If it does, continue to search whether the child node of user is 1. If the current routing tree does not have node 1, then search whether the child node of user is *. Since * exists and the current search level 3 is equal to the array length 3, the menu number set Data of the current node * is returned to obtain the menu number array [2].
[0179] The code is as follows:
[0180] / / FindRoutes finds all routes that match the given path
[0181] func(rt*TreeMeta)FindRoutes(path string)[]*en.Resource{var result[]*en.Resource
[0182] / / segmentation
[0183] array:=URLToArray(path,true)
[0184] / / Define an internal recursive function to find matching routes starting from the specified node var find func(node*RouteNode,index int)
[0185] find=func(node*RouteNode,index int){
[0186] if node == nil {
[0187] return
[0188] }
[0189] if index>=len(array){
[0190] / / If the target level is reached, the data will be returned.
[0191] if node.Data!=nil{
[0192] result=append(result,node.Data...)
[0193] return
[0194] }
[0195] return
[0196] }
[0197] / / Get the path part corresponding to the current index
[0198] part:=array[index]
[0199] / / If the current node has a child node of this path part, continue to search downward
[0200] if child,exists:=node.Children[part];exists{
[0201] find(child,index+1)
[0202] }
[0203] / / If the current node has a wildcard (*) child node, continue to search downward
[0204] if wildcardChild,exists:=node.Children["*"];exists{
[0205] find(wildcardChild,index+1)
[0206] }
[0207] }
[0208] / / Start from the root node to find the matching path
[0209] find(rt.Root,0)
[0210] return result
[0211] }
[0212] The authority verification module: the system loops through the menu number set, reads the authority table to determine whether the user has the authority to the menu number, succeeds if any of the menu numbers has the authority, and returns failure if none of them has the authority.
[0213] For example: the system loops through menu number array [2], reads the permission table to determine whether the current user has permission for menu number array [2]. If yes, it returns success, otherwise it returns failure. If there are multiple menu numbers in the menu number set, success is returned if any one of them has permission.
[0214] The above description is only a preferred embodiment of the present invention. All equivalent changes and modifications made according to the scope of the patent application of the present invention should fall within the scope of the present invention.
Claims
1. A method for managing menu permissions using a routing tree wildcard, characterized in that: The method comprises the following steps: Step S1, define a RouteNode structure to represent a routing tree node, including the following fields: Path is used for the path of the current node, Children is a dictionary set of child nodes, Data is an array of associated menu numbers, and define a TreeMeta structure, including a pointer Root pointing to the root node, which is used to store global routing tree data in memory; Step S2, traverse all menu data in the database, split each menu path Url into an array array according to ' / ', loop each array element, traverse and create nodes starting from the root node Root; Step S3, when the user accesses the menu, the system obtains the menu path Url, splits the Url into an array array by ' / ', recursively searches from the root node of the global routing tree layer by layer, matches the path Path of the routing tree node and the value of the path array element, and finds the menu number in the last element of the path; Step S4, the system loops through the menu number set, reads the permission table to determine whether the user has permission for the menu number, succeeds if any of the menu numbers have permission, and returns failure if none of them have permission.
2. A method for managing menu permissions using routing tree wildcards according to claim 1, characterized in that: The loop of each array element in step S2, traversing and creating nodes starting from the root node Root, is further as follows: if the node does not exist, a new node is created; if it already exists, it continues to move downward until the last part of the path is processed, and the menu number is appended to the Data array of the last routing node.
3. A method for managing menu permissions using routing tree wildcards according to claim 1, characterized in that: The menu number in the last element of the path found in step S3 is further: the path Path of the routing tree node and the value of the path array element are matched. If there is a wildcard '*' or a child node of an element of the current menu interface address array in the Children collection of the current node, continue to search downward until the last element of the path is found, and the Data array of the node contains the menu number, indicating that the corresponding menu number set is successfully found; if there is no matching address and there is no child node with the wildcard '*', it means that no matching path is found and failure is returned.
4. A system for managing menu permissions using routing tree wildcards, characterized in that: The system includes the definition module, the node creation module, the menu number search module and the authority verification module; The definition module: defines a RouteNode structure to represent a routing tree node, including the following fields: Path is used for the path of the current node, Children is a dictionary set of child nodes, Data is an array of associated menu numbers, and defines a TreeMeta structure, including a pointer Root pointing to a root node, which is used to store global routing tree data in memory; The node creation module: traverses all menu data in the database, splits each menu path Url into an array array according to ' / ', loops each array element, traverses and creates nodes starting from the root node Root; The menu number search module: when the user accesses the menu, the system obtains the menu path Url, splits the Url into an array array by ' / ', recursively searches from the root node of the global routing tree layer by layer, matches the path Path of the routing tree node and the value of the path array element, and finds the menu number in the last element of the path; The authority verification module: the system loops through the menu number set, reads the authority table to determine whether the user has the authority to the menu number, succeeds if any of the menu numbers has the authority, and returns failure if none of them has the authority.
5. A system for managing menu permissions using routing tree wildcards according to claim 4, characterized in that: The node creation module loops through each array element, traverses and creates nodes starting from the root node Root, and further: if the node does not exist, a new node is created; if it already exists, it continues to move downward until the last part of the path is processed, and the menu number is appended to the Data array of the last routing node.
6. A system for managing menu permissions using routing tree wildcards according to claim 4, characterized in that: The menu number in the last element of the path found in the menu number search module is further: the path Path of the matching routing tree node and the value of the path array element, if there is a wildcard '*' or a child node of an element of the current menu interface address array in the Children collection of the current node, then continue to search downward until the last element of the path is found, and the Data array of the node contains the menu number, indicating that the corresponding menu number set is successfully found; if there is no matching address and there is no child node with the wildcard '*', it means that no matching path is found and failure is returned.
Citation Information
Patent Citations
Webpage dynamic menu generation method and device
CN106598591A
Menu query method and server
CN108090083A
Domain name matching method and device and prefix tree updating method and device
CN114791985A
Menu display method and device, equipment and medium
CN115408627A
Authority management method and device, equipment and storage medium
CN115577344A
