A route generation method and system

By dragging and dropping to configure routing components on the canvas of a low-code platform, the routing hierarchy and routing table are automatically generated, solving the inconvenience caused by manually binding routes in existing technologies and achieving efficient and simple routing page construction.

CN114707086BActive Publication Date: 2025-10-24HANGZHOU WEIMING XINKE TECH CO LTD +1
View PDF 1 Cites 0 Cited by

Patent Information

Application Number
CN202210241723.5
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2022-03-11
Publication Date
2025-10-24
Estimated Expiration
2042-03-11

AI Technical Summary

Technical Problem

Existing low-code platforms require manual binding when generating page routes, which prevents nested routes and makes project building inconvenient.

Method used

On the canvas of the low-code platform, multiple route pages can be set up by dragging and dropping, the properties of the route components can be obtained and configured, the binding relationship between the route components and the pages can be generated, and the description information of all pages can be traversed to automatically generate the route hierarchy and route table.

Benefits of technology

No need to manually set up routes; simply drag and drop to configure route components to efficiently generate route pages, simplifying the project setup process and reducing time consumption.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN114707086B_ABST
    Figure CN114707086B_ABST
Patent Text Reader

Abstract

The embodiment of the application discloses a route generation method and system, the method comprises: setting a plurality of route pages on a canvas of a low-code platform, route components in each route page are added by a dragging manner, the added route components have parent-child or sibling route relationships with the route components in the route pages; obtaining default attributes of the added route components and configuring added route attributes; binding the added route components and the route pages where the route components are located, so that description information of the route components is written into description information of the route pages; the description information of the route components comprises the default attributes of the route components and the added route attributes; traversing the description information of all the route pages in the canvas, generating route hierarchical relationships between the route pages, and summarizing all the route hierarchical relationships to generate a route table. The route is not manually set, the route components are directly dragged to configure the route, and the route page is built, which is efficient and simple.
Need to check novelty before this filing date? Find Prior Art

Description

TECHNICAL FIELD

[0001] Embodiments of the present application relate to the technical field of communication, in particular to a route generation method and system. BACKGROUND

[0002] A low-code development platform (LCDP) is a development platform that can quickly generate an application without coding (0 code) or through a small amount of code. The method of developing an application through visualization (referring to a visual programming language) enables developers with different experience levels to create web pages and mobile applications through a graphical interface using drag-and-drop components and model-driven logic.

[0003] With the expansion of enterprise digitization and informatization, the low-code market is growing rapidly. Information systems developed based on low-code platforms, especially front-end business systems, are increasing. Due to the good model abstraction capability of low-code systems, the front end can obtain more underlying and rich metadata information. Currently, low-code platforms on the market can customize pages to build systems through rich component styles and drag-and-drop capabilities.

[0004] However, the generation of page routes in LCDP is a difficulty. The traditional route generation method is to create a route through a visual page at the initial stage of page creation and bind it to the page. Users must bind the route for each page, and this method cannot implement nested routes. The route creation method of the traditional low-code platform requires manual binding of the route for each page, and cannot implement nested routes and other logic. This brings some inconvenience to project construction. SUMMARY

[0005] To this end, embodiments of the present application provide a route generation method and system that do not require manual route setting, but directly drag and drop a route component to build a route page, which is efficient and simple.

[0006] To achieve the above purpose, embodiments of the present application provide the following technical solutions:

[0007] According to a first aspect of embodiments of the present application, a route generation method is provided, the method comprising:

[0008] setting a plurality of route pages on a canvas of a low-code platform, adding route components in each route page through a drag-and-drop manner, and the added route components having a parent-child or sibling route relationship with the route components in the route page;

[0009] obtaining default attributes of the added route components and configuring added route attributes;

[0010] The added route component and the route page where the route component is located are bound, so that description information of the route component is written into description information of the route page; the description information of the route component includes default attributes of the route component and added route attributes;

[0011] The description information of all route pages in the canvas is traversed to generate a route hierarchical relationship between the route pages, and all route hierarchical relationships are summarized to generate a route table.

[0012] Optionally, the default attributes of the route component include a route name, parent-child route identifiers, and a file reference path, and the file reference path is used to bind a page description information file of route component display content.

[0013] Optionally, the traversing of the description information of all route pages in the canvas to generate a route hierarchical relationship between the route pages includes:

[0014] The description information of all route pages in the canvas is traversed to determine whether the description information includes description information of a route component;

[0015] If the description information includes the description information of the route component, it is determined whether the description information of the route component has parent-child route identifiers, if not, the description information of the route component is added to a root-level route, and if so, the description information of the route component is added to a hierarchical level corresponding to a parent route; a hierarchical route relationship between the route pages is obtained.

[0016] Optionally, the added route attributes include a Promptmessage attribute for secondary confirmation of leaving a route, a Redirect attribute for redirecting a route, a uselocation attribute for listening to route changes, a render attribute for rendering route content, and a sensitive attribute for distinguishing route cases.

[0017] Optionally, the method further includes:

[0018] Reading description information of a route component in a page description file of a route page;

[0019] When the added route attributes are read, a corresponding attribute component in a plug-in is used to implement each added route attribute, so as to complete rendering of the route page.

[0020] According to a second aspect of an embodiment of the present application, a route generation system is provided, and the system includes:

[0021] A page setting module is configured to set a plurality of route pages on a canvas of a low-code platform, and route components in each route page are added by a dragging manner, and the added route components and the route components in the route pages have parent-child or sibling route relationships;

[0022] The route attribute configuration module is configured to obtain the default attribute of the added route component and configure the added route attribute.

[0023] The page binding module is configured to bind the added route component and the route page where the route component is located, so that the description information of the route component is written into the description information of the route page. The description information of the route component includes the default attribute of the route component and the added route attribute.

[0024] The route table generation module is configured to traverse the description information of all route pages in the canvas, generate the route hierarchical relationship between route pages, and generate a route table by summarizing all route hierarchical relationships.

[0025] Optionally, the default attribute of the route component includes a route name, a parent-child route identifier, and a file reference path, and the file reference path is used to bind the page description information file of the route component display content.

[0026] Optionally, the route table generation module is specifically configured to:

[0027] traverse the description information of all route pages in the canvas, and determine whether the description information of the route component is included;

[0028] if the description information of the route component is included, determine whether the description information of the route component has a parent-child route identifier, if not, add the description information of the route component to the root route, and if yes, add the description information of the route component to the corresponding parent route level, to obtain the hierarchical route relationship between route pages.

[0029] According to a third aspect of the embodiments of the present application, an electronic device is provided, which includes a memory, a processor, and a computer program stored in the memory and executable on the processor. The processor executes the computer program to implement the method of the first aspect.

[0030] According to a fourth aspect of the embodiments of the present application, a computer readable storage medium is provided, which stores computer readable instructions executable by a processor to implement the method of the first aspect.

[0031] In summary, the embodiment of the present application provides a route generation method and system. A plurality of route pages are set on a canvas of a low-code platform, and route components in each route page are added by dragging. The added route components have parent-child or sibling route relationships with the route components in the route page. Default attributes of the added route components are obtained, and added route attributes are configured. The added route components and the route page where the route components are located are bound, so that description information of the route components is written into description information of the route page. The description information of the route components includes the default attributes of the route components and the added route attributes. Description information of all route pages in the canvas is traversed to generate route hierarchical relationships between the route pages, and a route table is generated by summarizing all the route hierarchical relationships. The route is not manually set, and the route page is built by directly dragging and configuring the route components, which is efficient and simple. BRIEF DESCRIPTION OF DRAWINGS

[0032] In order to more clearly illustrate the embodiments of the present application or the technical solutions in the prior art, the drawings needed to be used in the following embodiment or prior art description will be briefly introduced. Obviously, the drawings in the following description are only exemplary, and for those skilled in the art, other drawings can be obtained from the provided drawings without creative labor.

[0033] The structures, proportions, sizes, etc. shown in the specification are only used to cooperate with the content disclosed in the specification, to be understood and read by those skilled in the art, and are not used to limit the conditions that the present application can be implemented, so they do not have technical significance. Any modification of structure, change of proportion relationship or adjustment of size, without affecting the effect and purpose that the present application can produce, should still fall within the scope of the technical content disclosed by the present application.

[0034] Figure 1 A route generation method flowchart is provided for the embodiment of the present application;

[0035] Figure 2 A route generation system block diagram is provided for the embodiment of the present application;

[0036] Figure 3 A structure schematic diagram of an electronic device provided by the embodiment of the present application is shown;

[0037] Figure 4 A schematic diagram of a computer readable storage medium provided by the embodiment of the present application is shown. DETAILED DESCRIPTION

[0038] The following embodiments of the application are illustrated by way of example only and thus are not intended to be limiting of the scope of the application. As appreciated, the disclosure provides numerous specific details for its processes, equipment, and techniques as examples of the application. However, various specific implementation details disclosed herein are not to be interpreted as limiting the scope of the application but merely as describing the currently understood best implementation of the application. Many modifications, substitutions, and variations from those embodiments disclosed in this application will occur to readers who are skilled in the art, however, it is understood that within the scope of the appended claims, the application can be practiced otherwise than as specifically described.

[0039] Figure 1 A route generation method provided by an embodiment of the application is shown, and the method comprises the following steps:

[0040] Step 101: setting a plurality of route pages on a canvas of a low-code platform, and adding route components in each route page by dragging, wherein the added route components have parent-child or sibling route relationships with the route components in the route page;

[0041] Step 102: obtaining default attributes of the added route components and configuring added route attributes;

[0042] Step 103: binding the added route components and the route pages where the route components are located, so that description information of the route components is written into description information of the route pages; the description information of the route components comprises the default attributes of the route components and the added route attributes;

[0043] Step 104: traversing the description information of all the route pages in the canvas, generating route hierarchical relationships between the route pages, and summarizing all the route hierarchical relationships to generate a route table.

[0044] In a possible implementation, the default attributes of the route components comprise a route name, a parent-child route identifier, and a file reference path, and the file reference path is used to bind page description information files of route component display contents.

[0045] In a possible implementation, in step 104, the traversing of the description information of all the route pages in the canvas to generate the route hierarchical relationships between the route pages comprises:

[0046] traversing the description information of all the route pages in the canvas to determine whether the description information comprises route component description information; if yes, determining whether the route component description information has a parent-child route identifier; if not, adding the route component description information to a root-level route; if yes, adding the route component description information to a hierarchical level corresponding to a parent route; and obtaining the hierarchical route relationships between the route pages.

[0047] In a possible implementation, the added routing attributes include a prompt message attribute for secondary confirmation of leaving routing, a redirect attribute for redirecting routing, a use location attribute for monitoring routing changes, a render attribute for rendering routing content, and a sensitive attribute for distinguishing routing case.

[0048] In a possible implementation, the method further includes: reading description information of the routing component in a page description file of the routing page; and when reading the routing added attribute, implementing each routing added attribute using a corresponding attribute component in the plug-in to complete rendering of the routing page.

[0049] It can be seen that the routing generation method provided by the embodiments of the present application can reduce the time for building a project, and does not need to pay attention to the sibling relationship or parent-child relationship of the routing. All routing relationships are uniformly generated by the method through recursion and traversal.

[0050] The routing generation method provided by the embodiments of the present application is described in detail below.

[0051] In a first aspect, the routing component is configured.

[0052] The routing component can be freely placed on the canvas for use. When a routing component is used in a page, if the routing component is dragged to the lower layer of another routing component and becomes the child of the other routing component, the two routing components are determined to be nested routing. If the routing component is dragged to the same level of another routing component, the two routing components are determined to be sibling routing.

[0053] The routing component can be configured with the following functions, including but not limited to routing path path, monitoring routing changes use location, secondary confirmation prompt message for leaving routing, redirecting routing Redirect, rendering routing content render, and distinguishing routing case sensitive.

[0054] Routing path path: when routing is jumped, the corresponding routing can be found according to the path;

[0055] Monitoring routing changes use location: the change of the current URL can be monitored, and a configuration execution function can be used to perform corresponding operations when the URL is changed;

[0056] Secondary confirmation prompt message for leaving routing: when leaving the current routing, it is confirmed whether to leave the current routing;

[0057] Rendering route content: Rendering the content under the route; you can configure render to render the content under the current route with the highest priority. Render is used to describe all the content displayed under the route.

[0058] Importpath is the path to the file describing the content to be displayed under this route. If both render and importpath are configured, the render content will be generated first, and the content configured under importpath will not be generated.

[0059] The case sensitivity of the route can be configured as true / false: true means that the case of the matching current route path can be distinguished, false does not distinguish.

[0060] Secondly, bind the routing component to the routing page.

[0061] When a routing component is used in a page, it will be bound to the page that uses it, so that the description of the page to be rendered under the routing component can be found. When a routing component description is added to a routing page, the routing component description will be directly written to the description of the page that uses it. This is equivalent to using a routing component in a page, and the description of the routing component will be added to the description of the page to indicate that the routing component has been added to the page.

[0062] The routing component description information includes the routing component name (attribute name componentname, value routeComponent), the route name (attribute name routename), the parent route (attribute name parentroute) used to bind the parent-child relationship, the reference path of the description information file of the content to be displayed by the routing component (importpath, the page description information can be found through the reference path), etc.

[0063] The page description is associated with the page by referencing the path. The current route's path is generated by default based on the parent and child routes and can be modified. The current route's path is generated by default as follows: the path of the parent route or page + the current route name. When a route jumps, the path is used to find the corresponding route.

[0064] The third aspect is to generate a routing table.

[0065] When the page is constructed and saved, the routing generation method in the page description information management class PM will traverse all the page description information in the page description information management class PM and read the description information of each page.

[0066] If the page information includes the description information of the routing component, it is determined whether the parent routing is included in the routing information to determine which routing level the description information of the routing component is added to. If there is no parent routing, it is considered a complete page, and it is added to the root level routing;

[0067] If there is a parent routing, the page is only a child page (sub-routing) of another page, and it is added to the corresponding parent PM routing level, and the hierarchical relationship between the two pages (routing) needs to be described.

[0068] Finally, a complete routing table is generated to save the correspondence between each page and the routing, and to describe the routing hierarchical relationship. A project is composed of multiple pages, a project has a routing table, a routing table includes multiple paths, each path corresponds to a page, and each page has the routing relationship of the page.

[0069] In a fourth aspect, a page description file is generated.

[0070] When the routing component is placed on the page, a page description information is added by default in the page description information management class PM (used to manage the description information of the page, including the addition, deletion, modification and query of the page description information), which is the page description information of the routing component. The page description information includes the content to be included in the entire page.

[0071] In a fifth aspect, a scheme for implementing the characteristics of the routing component during page rendering.

[0072] When rendering the routing, the parser reads the page description file. When the routing component is read, it directly enters the routing component.

[0073] When the Promptmessage attribute is read, it is first determined whether the Promptmessage attribute is configured. If yes, the Prompt component provided by react-router-dom is used to implement Promptmessage, the Prompt component is wrapped outside the routing component, and Promptmessage is passed to the message (prompt information before routing jump) of the Prompt component, so as to realize interception.

[0074] When the Redirect attribute is read, it is determined whether the routing needs to be redirected. If the attribute is configured, the Redirect component in react-router-dom is instantiated, the routing that needs to be redirected is passed to the Redirect component, and then the routing component generates a state for controlling the routing and a global method. The state for controlling the routing is used to control whether the routing needs to jump to the redirected routing, and the global method is used to enable other pages and components to control the state to realize the redirection of the routing. The global method is a method that can be used anywhere in the project.

[0075] When the uselocation attribute is read, the uselocation in react-route-dom is instantiated, and the location change is listened to, and the corresponding operation is performed once the change occurs.

[0076] The above three attributes are read every time the route is rendered, and other attributes can also be set, and if the corresponding attribute is set, the corresponding function is assigned.

[0077] To sum up, the embodiment of the application provides a route generation method, which comprises the following steps: setting a plurality of route pages on a canvas of a low-code platform, adding route components in each route page by meansing dragging, the added route components and the route components in the route page have a parent-child or sibling route relationship; obtaining default attributes of the added route components and configuring added route attributes; binding the added route components and the route page where the route components are located, so that the description information of the route components is written into the description information of the route page; the description information of the route components comprises the default attributes of the route components and the added route attributes; traversing the description information of all the route pages in the canvas, generating a route hierarchical relationship between the route pages, and summarizing all the route hierarchical relationships to generate a route table. Without manually setting the route, the route components are directly dragged to configure the route page, which is efficient and simple.

[0078] Based on the same technical concept, the embodiment of the application also provides a route generation system, as shown in Figure 2 The system comprises:

[0079] A page setting module 201 is configured to set a plurality of route pages on a canvas of a low-code platform, add route components in each route page by means of dragging, and add route components and route components in the route page have a parent-child or sibling route relationship.

[0080] A page setting module 202 is configured to obtain default attributes of the added route components and configure added route attributes.

[0081] A page binding module 203 is configured to bind the added route components and the route page where the route components are located, so that the description information of the route components is written into the description information of the route page; the description information of the route components comprises the default attributes of the route components and the added route attributes.

[0082] A route table generation module 204 is configured to traverse the description information of all the route pages in the canvas, generate a route hierarchical relationship between the route pages, and summarize all the route hierarchical relationships to generate a route table.

[0083] In a possible implementation, the default attribute of the routing component includes a routing name, a parent-child routing identifier, and a file reference path, and the file reference path is used to bind a page description information file of the routing component.

[0084] In a possible implementation, the routing table generation module 204 is specifically configured to:

[0085] traversing description information of all routing pages in the canvas, judging whether the description information of the routing component is included; if the description information of the routing component is included, judging whether the description information of the routing component has a parent-child routing identifier; if not, adding the description information of the routing component to a root routing; if yes, adding the description information of the routing component to a corresponding parent routing level; and obtaining a hierarchical routing relationship between routing pages.

[0086] The application embodiment further provides an electronic device corresponding to the method provided in the foregoing embodiments. Please refer to Figure 3 which shows a schematic diagram of an electronic device provided by some embodiments of the application. The electronic device 20 can include a processor 200, a memory 201, a bus 202, and a communication interface 203, wherein the processor 200, the communication interface 203, and the memory 201 are connected through the bus 202; the memory 201 stores a computer program that can run on the processor 200, and the processor 200 executes the computer program to perform the method provided in any of the foregoing embodiments of the application.

[0087] The memory 201 can include a high-speed random access memory (RAM) and can also include a non-volatile memory such as at least one disk memory. The communication connection between the system network element and at least one other network element is realized through at least one physical port 203 (which can be wired or wireless), and the Internet, a wide area network, a local network, a metropolitan area network, etc. can be used.

[0088] The bus 202 can be an ISA bus, a PCI bus, or an EISA bus, etc. The bus can be divided into an address bus, a data bus, a control bus, etc. The memory 201 is used to store a program, and the processor 200 executes the program after receiving an execution instruction. The method disclosed in any of the foregoing embodiments of the application can be applied to the processor 200 or implemented by the processor 200.

[0089] The processor 200 can be an integrated circuit chip having a signal processing capability. In the implementation process, each step of the above method can be completed by the integrated logic circuit or the instruction in the form of software in the processor 200. The processor 200 described above can be a general processor, including a central processing unit (CPU), a network processor (NP), etc.; can also be a digital signal processor (DSP), an application specific integrated circuit (ASIC), a ready programmable gate array (FPGA) or other programmable logic device, a discrete gate or transistor logic device, a discrete hardware component. Each method, step and logic block diagram disclosed in the embodiments of the present application can be implemented or executed. The general processor can be a microprocessor or the processor can also be any conventional processor. The steps of the method disclosed in combination with the embodiments of the present application can be directly embodied as a hardware code processor for execution, or a combination of hardware and software modules in the code processor for execution. The software module can be located in a random access memory, a flash memory, a read only memory, a programmable read only memory or an electrically erasable programmable memory, a register, etc. The storage medium in the art. The storage medium is located in the memory 201, and the processor 200 reads the information in the memory 201, and combines the hardware to complete the steps of the above method.

[0090] The electronic device provided by the embodiments of the present application and the method provided by the embodiments of the present application have the same beneficial effects as the method they adopt, run or implement.

[0091] The embodiments of the present application also provide a computer readable storage medium corresponding to the method provided by the preceding embodiments. Please refer to Figure 4 The computer readable storage medium shown is an optical disc 30, and a computer program (i.e. program product) is stored on the optical disc 30. When the computer program is run by a processor, the method provided by any of the preceding embodiments is executed.

[0092] It should be noted that examples of the computer readable storage medium can also include, but are not limited to, a phase change memory (PRAM), a static random access memory (SRAM), a dynamic random access memory (DRAM), other types of random access memory (RAM), a read only memory (ROM), an electrically erasable programmable read only memory (EEPROM), a flash memory or other optical, magnetic storage medium, which will not be described one by one here.

[0093] The computer readable storage medium provided by the above embodiments of the present application and the method provided by the embodiments of the present application have the same beneficial effects as the method adopted, run or implemented by the application program stored therein.

[0094] It is noted that

[0095] The algorithms and displays presented herein are not inherently related to any particular computer, virtual apparatus, or other apparatus. Various general purpose systems can be used with programs in accordance with the teachings herein, or it can prove convenient to construct more specialized apparatus to perform the required method steps. The required structure for a variety of these systems will be apparent from the description above. In addition, the present application is not described with reference to any particular programming language. It will be appreciated that a variety of programming languages can be used to implement the teachings of the application as described herein, and any references below to specific languages are provided for disclosure of enablement only.

[0096] In the description provided herein, numerous specific details are set forth. However, it is understood that embodiments of the application can be practiced without these specific details. In some instances, well-known methods, structures and techniques have not been described in detail in order not to obscure the understanding of this description.

[0097] Similarly, it is to be understood that the mechanical details of the application that have been set forth above in the context of a few illustrative embodiments are for purposes of example only and that various modifications, changes and adaptations will be apparent to those skilled in the art. It is the following claims, including any amendments thereto, that define the scope of the application.

[0098] Those skilled in the art will appreciate that the modules in the apparatuses in the embodiments can be adapted and placed in one or more apparatuses other than the embodiments. The modules or units or components in the embodiments can be combined into one module or unit or component, and further can be divided into more sub-modules or sub-units or sub-components. Any combination of all the features disclosed in the specification (including the accompanying claims, abstract and drawings), and any method or apparatus so disclosed, can be used in any combination, except that at least some of such features and / or processes or units are mutually exclusive, unless explicitly stated otherwise. Each feature disclosed in the description (including the accompanying claims, abstract and drawings) can be replaced by alternative features serving the same, equivalent or similar purpose, unless explicitly stated otherwise.

[0099] Furthermore, those skilled in the art will appreciate that although some embodiments described herein include certain features included in other embodiments but not other features, combinations of features from different embodiments are intended to be within the scope of this application and to form different embodiments. For example, in the claims below, any of the claimed embodiments may be used in any combination.

[0100] The various component embodiments of the present application can be implemented in hardware, or implemented in a software module running on one or more processors, or implemented in a combination thereof. Those skilled in the art will appreciate that a microprocessor or digital signal processor (DSP) can be used in practice to implement some or all of the functions of some or all of the components in the creation device of the virtual machine according to an embodiment of the present application. The application can also be implemented as a part or all of the equipment or device program (for example, computer program and computer program product) for performing the method described herein. Such a program realizing the present application can be stored on a computer-readable medium, or can have the form of one or more signals. Such a signal can be downloaded from an Internet website, or provided on a carrier signal, or provided in any other form.

[0101] It should be noted that the above embodiments illustrate rather than limit the present application, and that those skilled in the art may devise alternative embodiments without departing from the scope of the appended claims. In the claims, any reference signs placed between brackets should not be construed as limiting the claims. The word "comprising" does not exclude the presence of elements or steps not listed in the claims. The word "a" or "an" preceding an element does not exclude the presence of a plurality of such elements. The present application may be implemented by means of hardware comprising several different elements and by means of suitably programmed computers. In a unit claim enumerating several means, several of these means may be embodied by the same item of hardware. The use of the words first, second, and third etc. does not indicate any order. These words may be interpreted as names.

[0102] The above description is merely a preferred embodiment of the present application, but the scope of protection of the present application is not limited thereto. Any changes or substitutions that can be easily conceived by a person skilled in the art within the technical scope disclosed in this application should be included in the scope of protection of the present application. Therefore, the scope of protection of the present application should be based on the scope of protection of the claims.

Claims

1. A route generation method characterized by, The method comprises: setting a plurality of routing pages on a canvas of a low-code platform, routing components in each routing page being added by means of dragging, the added routing components having a parent-child or sibling routing relationship with the routing components in the routing page; obtaining default attributes of the added routing components and configuring added routing attributes; the added routing attributes comprising a Promptmessage attribute for secondary confirmation of leaving a routing, a Redirect attribute for redirecting a routing, a uselocation attribute for listening to a routing change, a render attribute for rendering routing content, and a sensitive attribute for distinguishing routing cases; binding the added routing components and the routing page in which the routing components are located, so that description information of the routing components is written into description information of the routing page; the description information of the routing components comprising default attributes of the routing components and the added routing attributes; traversing the description information of all the routing pages in the canvas to generate a routing hierarchical relationship between the routing pages, and aggregating all the routing hierarchical relationships to generate a routing table.

2. The method of claim 1, wherein, The default attributes of the routing components comprise a routing name, a parent-child routing identifier, and a file reference path, the file reference path being used to bind page description information files of the routing components for displaying content.

3. The method of claim 1, wherein, The traversing the description information of all the routing pages in the canvas to generate the routing hierarchical relationship between the routing pages comprises: traversing the description information of all the routing pages in the canvas to determine whether the description information of the routing components is included; if the description information of the routing components is included, determining whether the description information of the routing components has a parent-child routing identifier, if not, adding the description information of the routing components to a root-level routing, and if so, adding the description information of the routing components to a hierarchical level corresponding to a parent routing; and obtaining the hierarchical routing relationship between the routing pages.

4. The method of claim 1, wherein, The method further comprises: reading description information of the routing components in a page description file of the routing page; when reading the routing added attributes, using corresponding attribute components in a plug-in to implement each routing added attribute, so as to complete rendering of the routing page.

5. A route generation system characterized by comprising: The system comprises: a page setting module configured to set a plurality of routing pages on a canvas of a low-code platform, routing components in each routing page being added by means of dragging, the added routing components having a parent-child or sibling routing relationship with the routing components in the routing page; a routing attribute configuration module configured to obtain default attributes of the added routing components and configure added routing attributes; the added routing attributes comprising a Promptmessage attribute for secondary confirmation of leaving a routing, a Redirect attribute for redirecting a routing, a uselocation attribute for listening to a routing change, a render attribute for rendering routing content, and a sensitive attribute for distinguishing routing cases; a page binding module configured to bind the added routing components and the routing page in which the routing components are located, so that description information of the routing components is written into description information of the routing page; the description information of the routing components comprising default attributes of the routing components and the added routing attributes; and The route table generating module is configured to traverse the description information of all the route pages in the canvas, generate the route hierarchical relationship among the route pages, and generate the route table by summarizing all the route hierarchical relationships.

6. The system of claim 5, wherein, The default attributes of the route component include a route name, parent-child route identifiers, and a file reference path, which is used to bind a page description information file of the route component.

7. The system of claim 5, wherein, The route table generating module is specifically configured to: traverse the description information of all the route pages in the canvas, and determine whether the description information includes the description information of the route component; if yes, determine whether the description information of the route component has the parent-child route identifiers, and if not, add the description information of the route component to a root-level route; if yes, add the description information of the route component to a corresponding parent-level route; obtain the hierarchical route relationship among the route pages.

8. An electronic device comprising: A memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor executes the computer program to implement the method of any one of claims 1-4.

9. A computer-readable storage medium, characterized in that, A computer readable medium having stored thereon computer readable instructions executable by a processor to implement the method of any one of claims 1-4.

Citation Information

Patent Citations

  • Visual system prototype design method and system capable of generating codes and storage medium

    CN112527288A