[go: up one dir, main page]

CN111552895B - Parsing methods, systems, equipment and media for page routing in mini program applications - Google Patents

Parsing methods, systems, equipment and media for page routing in mini program applications Download PDF

Info

Publication number
CN111552895B
CN111552895B CN202010291847.5A CN202010291847A CN111552895B CN 111552895 B CN111552895 B CN 111552895B CN 202010291847 A CN202010291847 A CN 202010291847A CN 111552895 B CN111552895 B CN 111552895B
Authority
CN
China
Prior art keywords
page
route
target
page route
character string
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN202010291847.5A
Other languages
Chinese (zh)
Other versions
CN111552895A (en
Inventor
陈剑
于磊
崔广宇
李巍
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Ctrip Computer Technology Shanghai Co Ltd
Original Assignee
Ctrip Computer Technology Shanghai Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Ctrip Computer Technology Shanghai Co Ltd filed Critical Ctrip Computer Technology Shanghai Co Ltd
Priority to CN202010291847.5A priority Critical patent/CN111552895B/en
Publication of CN111552895A publication Critical patent/CN111552895A/en
Application granted granted Critical
Publication of CN111552895B publication Critical patent/CN111552895B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • GPHYSICS
    • G06COMPUTING OR CALCULATING; COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/90Details of database functions independent of the retrieved data types
    • G06F16/95Retrieval from the web
    • G06F16/955Retrieval from the web using information identifiers, e.g. uniform resource locators [URL]
    • YGENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
    • Y02TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
    • Y02DCLIMATE CHANGE MITIGATION TECHNOLOGIES IN INFORMATION AND COMMUNICATION TECHNOLOGIES [ICT], I.E. INFORMATION AND COMMUNICATION TECHNOLOGIES AIMING AT THE REDUCTION OF THEIR OWN ENERGY USE
    • Y02D10/00Energy efficient computing, e.g. low power processors, power management or thermal management

Landscapes

  • Engineering & Computer Science (AREA)
  • Databases & Information Systems (AREA)
  • Theoretical Computer Science (AREA)
  • Data Mining & Analysis (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Stored Programmes (AREA)

Abstract

The application discloses a method, a system, equipment and a medium for analyzing page route in applet application, wherein the method comprises the following steps: self-defining a page route to be configured; judging whether the to-be-configured page route exists in a configuration file library of the applet application, if not, converting the to-be-configured page route into a target page route, and if so, determining that the to-be-configured page route is a jumpable page route; the configuration file library stores a plurality of initial configured page routes, and the target page route corresponds to one initial configured page route. According to the method and the device, the page route to be configured is customized and converted into the target page route, and when a user needs to open the page route, whether the page route is matched with the configured page route of the configuration file library of the applet application or not can be successfully opened, so that the configuration requirement of the WeChat applet can be met, the page which the user hopes to acquire can be opened, and the user experience is further improved.

Description

Page route analysis method, system, equipment and medium in applet application
Technical Field
The present application relates to the field of communications technologies, and in particular, to a method, a system, an apparatus, and a medium for resolving a page route in an applet application.
Background
In the current society, weChat has gradually become a life style of people replacing traditional modes such as short messages, telephones and the like, and along with popularization of WeChat, more and more users use WeChat applet, which is a new open capability, and a developer can develop an applet rapidly. The applet can be conveniently acquired and propagated within the WeChat, while having an excellent use experience. But the page routes of the WeChat applet are all required to be statically configured in app.json (static configuration file in the WeChat applet), and do not support dynamic routes that are not configured in app.json. Therefore, when url (global resource locator) of a dynamic route that the user wants to acquire is not configured in app. Json, a page that the user wants to acquire cannot be opened, which greatly affects the user's use experience of the WeChat applet.
Disclosure of Invention
The application aims to overcome the defect that an unconfigured dynamic route in a WeChat applet cannot be opened in the prior art, and provides an automatic dynamic route analysis method, an automatic dynamic route analysis system, electronic equipment and a storable medium.
The application solves the technical problems by the following technical scheme:
the application provides an analysis method of page route in applet application, which comprises the following steps:
self-defining a page route to be configured;
judging whether the page route to be configured exists in a configuration file library of the applet application, if not, converting the page route to be configured into a target page route, and if so, determining that the page route to be configured is a jumpable page route;
the configuration file library stores a plurality of initial configured page routes, and the target page route corresponds to one initial configured page route.
Preferably, the method comprises the steps of,
the step of judging whether the page route to be configured exists in the configuration file library of the applet application comprises the following steps:
comparing the page route to be configured with each initial configured page route in the configuration file library;
when the page route matched with the page route to be configured does not exist in all the initial configured page routes, determining that the page route to be configured does not exist in the configuration file library, and triggering a page nonexistence event.
Preferably, after the step of triggering the page to have no event, the step of converting the to-be-configured page route into a target page route includes:
acquiring first target information and second target information in the page route to be configured through a preset regular expression;
matching to obtain a target configured route corresponding to the first target information in the initial configured page route;
converting the second target information into third target information in a preset page routing format;
and obtaining the target page route according to the first target information and the third target information.
Preferably, the step of obtaining the target page route according to the first target information and the third target information includes:
setting a first target character string corresponding to the third target information, wherein the first target character string corresponds to the service type corresponding to the page route to be configured;
the first target information, the first target character string and the third target information are spliced to obtain the target page route;
or alternatively, the first and second heat exchangers may be,
the step of obtaining the target page route according to the first target information and the third target information comprises the following steps:
acquiring a second target character string in the to-be-configured page route through a preset regular expression, wherein the second target character string corresponds to a service type corresponding to the to-be-configured page route;
the first target information and the second target character are spliced to obtain the target page route;
or alternatively, the first and second heat exchangers may be,
the step of obtaining the target page route according to the first target information and the third target information comprises the following steps:
setting a first target character string corresponding to the third target information, wherein the first target character string corresponds to the service type corresponding to the page route to be configured;
obtaining a second target character string in the page route to be configured through a preset regular expression, wherein the second target character string corresponds to the first target character string, the second target character string, the first target information and the third target information corresponding to the service type corresponding to the page route to be configured, and the target page route is obtained through splicing processing.
The application also provides a system for analyzing the page route in the applet application, which comprises: the self-defining module and the judging module;
the self-defining module is used for self-defining the page route to be configured;
the judging module is used for judging whether the page route to be configured exists in the configuration file library of the applet application, if not, converting the page route to be configured into a target page route, and if so, determining that the page route to be configured is a jumpable page route;
the configuration file library stores a plurality of initial configured page routes, and the target page route corresponds to one initial configured page route.
Preferably, the method comprises the steps of,
the judging module comprises: the comparison unit and the event triggering unit;
the comparison unit is used for comparing the page route to be configured with each initial configured page route in the configuration file library;
and the triggering unit is used for determining that the page route to be configured does not exist in the configuration file library when the page route matched with the page route to be configured does not exist in all the initial configured page routes, and triggering a page nonexistent event.
Preferably, the judging module further comprises an information obtaining unit, a matching unit, a converting unit and a page route obtaining unit, wherein the event triggering unit is further used for triggering the page to call the information obtaining unit after no event exists;
the information acquisition unit is used for acquiring first target information and second target information in the page route to be configured through a preset regular expression;
the matching unit is used for matching and obtaining a target configured route corresponding to the first target information in the initial configured page route;
the conversion unit is used for converting the second target information into third target information in a preset page routing format;
the page route obtaining unit is used for obtaining the target page route according to the first target information and the third target information.
Preferably, the method comprises the steps of,
the page route acquisition unit includes: a first character string setting subunit and a route obtaining subunit;
the first character string setting subunit is configured to set a first target character string corresponding to the third target information, where the first target character string corresponds to a service type corresponding to the to-be-configured page route;
the route acquisition subunit is used for performing splicing processing on the first target information, the first target character string and the third target information to obtain the target page route;
or alternatively, the first and second heat exchangers may be,
the page route acquisition unit includes: a second character string acquisition subunit and a route acquisition subunit;
the second character string obtaining subunit is configured to obtain a second target character string in the to-be-configured page route through a preset regular expression, where the second target character string corresponds to a service type corresponding to the to-be-configured page route;
the route obtaining subunit is used for obtaining the target page route according to the splicing processing of the first target information and the second target character string;
or alternatively, the first and second heat exchangers may be,
the page route obtaining unit comprises a first character string setting subunit, a second character string obtaining subunit and a route obtaining subunit:
the first character string setting subunit is configured to set a first target character string corresponding to the third target information, where the first target character string corresponds to a service type corresponding to the to-be-configured page route;
the second character string obtaining subunit obtains a second target character string in the to-be-configured page route through a preset regular expression, wherein the second target character string corresponds to a service type corresponding to the to-be-configured page route;
the route obtaining subunit is configured to splice the first target string, the second target string, the first target information, and the third target information to obtain the target page route.
The application also provides an electronic device comprising a memory, a processor and a computer program stored on the memory and executable on the processor, the processor implementing the parsing method as described above when executing the computer program.
The application also provides a computer readable storage medium having stored thereon a computer program which, when executed by a processor, implements the steps of the parsing method as described above.
On the basis of conforming to the common knowledge in the field, the above preferred conditions can be arbitrarily combined to obtain the preferred examples of the application.
The application has the positive progress effects that:
the application can successfully open the page route no matter whether the page route is statically configured in the configuration file library applied to the applet or not by self-defining the page route to be configured and converting the page route to be configured into the target page route, thereby not only meeting the configuration requirement of the WeChat applet, but also opening the page which the user hopes to acquire, further improving the user experience degree, and further supporting the analysis of the user-defined dynamic route which is not registered in the configuration file library.
Drawings
Fig. 1 is a flowchart of a method for resolving a page route in an applet application according to embodiment 1 of the application.
Fig. 2 is a flowchart of the implementation of step 102 in embodiment 2 of the present application.
Fig. 3 is a flowchart of an implementation of step 1028 in embodiment 2 of the present application.
Fig. 4 is a schematic diagram illustrating a page jump implemented by the parsing method in embodiment 2 of the present application under a specific scenario.
Fig. 5 is a schematic block diagram of a parsing system for page routing in an applet application according to embodiment 3 of the present application.
Fig. 6 is a schematic diagram of an implementation manner of the judging module in embodiment 4 of the present application.
Fig. 7 is a schematic diagram of an implementation manner of the page route obtaining unit in embodiment 4 of the present application.
Fig. 8 is a schematic structural diagram of an electronic device in embodiment 4 of the present application.
Detailed Description
The application is further illustrated by means of the following examples, which are not intended to limit the scope of the application.
Example 1
The embodiment provides a method for analyzing page routes in applet applications, wherein the applet applications include, but are not limited to, weChat applet applications.
As shown in fig. 1, the parsing method in this embodiment includes:
step 101, self-defining a to-be-configured page route.
Step 102, judging whether the page route to be configured exists in the configuration file library of the applet application, if not, invoking step 104, and if so, invoking step 103.
Step 103, determining the page route to be configured as a jumpable page route.
Step 104, converting the to-be-configured page route into a target page route.
The configuration file library stores a plurality of initial configured page routes, and the target page route corresponds to one initial configured page route.
When a user wants to view a certain webpage, if the webpage route corresponding to the webpage is not statically configured in the configuration file library, the user can jump to the user-defined route to be configured corresponding to the webpage through the target webpage route, so that the webpage is viewed.
Because the WeChat applet can only analyze the static configuration in app. Json (configuration file library) and the initial configured route in the configuration file library matched with the page route, but can not analyze the configuration file library initial configured route unmatched with the page route, therefore, in the embodiment, when the custom configuration to be page route does not exist in the configuration file library, the configuration to be page route is converted into the target page route matched with the configuration file library, thereby realizing the analysis of the configuration to the page route.
According to the embodiment, the page route to be configured is customized and converted into the target page route, and when a user needs to open the page route, whether the page route is statically configured in the configuration file library of the applet application or not can be successfully opened, so that the configuration requirements of the WeChat applet can be met, the page which the user wants to acquire can be opened, the user experience is further improved, and the analysis of the user-defined dynamic route which is not registered in the configuration file library is further supported.
Example 2
The embodiment provides a method for analyzing a page route in an applet application, which is a further improvement of embodiment 1, as shown in fig. 2, step 102 specifically includes:
and 1021, comparing the page route to be configured with each initial configured page route in the configuration file library.
Step 1022, determining whether there is no page route matching the page route to be configured in all the initial configured page routes, if yes, executing step 1023, and if no, executing step 103.
Step 1023, determining that the page route to be configured does not exist in the configuration file library.
Step 1024, trigger page no event.
In this embodiment, in step 1023, when the page route to be configured does not exist in the configuration file library, step 1024 is executed, that is, a page nonexistence event is triggered, specifically, the page nonexistence event of the page route to be opened by the WeChat applet may be monitored by the instruction App.
Optionally, in order to successfully convert the page route to be configured into the target page route, as shown in fig. 2, step 1024 may further include:
step 1025, acquiring the first target information and the second target information in the page route to be configured through a preset regular expression.
Step 1026, obtaining a target configured route corresponding to the first target information in the initial configured page route by matching.
Step 1027, converting the second target information into third target information in a preset page routing format.
Step 1028, obtaining the target page route according to the first target information and the third target information.
For better understanding of steps 1025-1028, the following description will be given by taking a specific example, assuming that the page to be configured is routed to be/pages/hotel/details/dope/2895314, the first target information obtained by the preset regular expression in step 1025 is/pages/hotel/details/index? (the target configured route corresponding to the first target information in the initial configured page route is/pages/hotel/detail/index. Finally, by step 1028, the first target information/pages/hotel/details/index is spliced with the third target information id=2895314 & biz=1 to obtain target page route/pages/hotel/details/index=2895314 & biz=1, and in the WeChat applet, the user can open the custom page route through the target page route.
Optionally, as shown in fig. 3, step 1028 specifically includes:
step 10281, setting a first target character string corresponding to the third target information.
Step 10282, obtaining a second target character string in the to-be-configured page route through a preset regular expression.
Step 10283, performing splicing processing on the first target information, the first target character string, the second target character string and the third target information to obtain the target page route.
And the first target character string and the second target character string correspond to the service type corresponding to the page route to be configured.
For better understanding of steps 10281-10283, this embodiment will be described by taking a specific example, for example, the custom route to be configured is/pages/hotel/detail/dope/2895314 pay=1, and the first target information is/pages/hotel/detail/index? Is the second target information dometic/2895314? The third target information is dometic, 2895314, then, the first target string corresponding to the third target information may be set through step 10281, assuming that the first target string set for dometic is biz=1 in this embodiment, the first target string set for 2895314 is id=, then, the first target string and the third target information are spliced according to the requirement, and the third target information are spliced through connectors & splice, such as id= 2895314, id= 2895314 and biz=1 are spliced to obtain id=2895314 & biz=1, then, the second target string pay=1 in the page route to be configured may be obtained according to step 10282, and then, the first target information/page/step/tail may be 10283 according to step 10282. And splicing the spliced third target information id=2895314 & biz=1 and the second target character string pay=1 to obtain a final target page route/pages/hotel/detail/index=2895314 & biz=1 pay=1. In this specific example, biz=1 represents a dometic, that is, a domestic hotel, and pay=1 represents a room type paid to a store, for example, when all domestic hotels need to be searched, a hotel meeting the requirement can be found by matching pages including biz=1 in the page route, and when all room types paid to a store need to be searched, a room type meeting the requirement can be found by matching pages including pay=1 in the page route.
It should be understood that the target page route may be obtained according to actual requirements, for example, step 10281 may not be performed, in which case, the target page route may be obtained according to the second target string, the first target information, and the third target information in step 10283; as another example, step 10282 may not be performed, in which case the target page route may be obtained based on the first target string, the first target information, and the third target information.
In addition, in this embodiment, the custom page route/pages/hotel/detail/oversea/999915 may be converted into the target page route/pages/hotel/detail/index=999915 & biz=2, where biz=2 represents a foreign hotel, and the custom page route/pages/hotel/brand/hasing may be converted into the target page route/pages/hotel/brand/index=hasting, where brand=hasting represents a hotel, and the identifiable mark of the brand hotel is hasting. The process of converting the custom page route to be configured into the page route is similar to the above, and therefore will not be described here again.
The overall analysis process of this embodiment is described below by way of a specific example:
the page route to be configured is pages/hotel/mgm/list, and the custom route is a dynamic route which is not configured in a configuration file library of the applet application, so that an event of page absence of the page route to be opened by the WeChat applet is monitored through an instruction App. Fig. 4 shows a schematic diagram of a page skip under the scene, under the current page, a user's view instruction of a user-defined to-be-configured page route with reference numeral 20 is obtained, at this time, by converting the to-be-assembled page route 20 into a target page route/pages/hotel/components/webview data = {_rl\https% 3 a-2 f%2 fm-ctrip. Com%2fweba, the page skip can be realized after the applet recognizes the route, and under the scene, the page with the real skip is the page with reference numeral 21.
In this embodiment, on the one hand, the user-defined page route to be configured can be successfully converted into the target page route meeting the configuration requirement of the configured page route, and the classification information included in the target page route can be rapidly distinguished according to the information in the target page route, so that the analysis efficiency of the page route is higher, the user can rapidly find the page meeting the requirement of the user, and the user experience is improved.
Example 3
The embodiment provides a system for analyzing page routing in applet applications, wherein the applet applications include, but are not limited to, weChat applet applications.
As shown in fig. 5, the parsing system in the present embodiment includes: the customization module 201 and the judgment module 202.
The customization module 201 is configured to customize the route of the page to be configured.
The judging module 202 is configured to judge whether the to-be-configured page route exists in the configuration file library of the applet application, if not, the to-be-configured page route is converted into a target page route, and if yes, the to-be-configured page route is determined to be a jumpable page route.
The configuration file library stores a plurality of initial configured page routes, and the target page route corresponds to one initial configured page route.
When a user wants to view a certain webpage, if the webpage route corresponding to the webpage is not statically configured in the configuration file library, the user can jump to the user-defined route to be configured corresponding to the webpage through the target webpage route, so that the view of the webpage is realized
Because the WeChat applet can only analyze the static configuration in the app. Json and the initial configuration of the routing in the configuration file library matched with the page route, but can not analyze the configuration of the configuration file library of the initial configuration of the routing of the page route, so in the embodiment, when the judgment module judges that the custom configuration of the page route does not exist in the configuration file library, will be configured to the page route matching with the configuration file library of the page route of the target page route, thereby realizing the configuration of the page route.
According to the embodiment, the page route to be configured is customized through the custom module, and is converted into the target page route through the judging module, when the user needs to open the page route, whether the page route is matched with the configured page route of the configuration file library of the applet application or not can be successfully opened, so that the configuration requirement of the WeChat applet can be met, the page which the user hopes to acquire can be opened, and the user experience is further improved.
Example 4
The present embodiment provides a system for analyzing page routing in applet application, which is a further improvement of embodiment 3, as shown in fig. 6, the judging module 202 specifically includes: the comparison unit 2021 and the event triggering unit 2022.
The comparison unit 2021 is configured to compare the to-be-configured page route with each of the initial configured page routes in the configuration file library.
The event triggering unit 2022 is configured to determine that the page route to be configured does not exist in the configuration file library when no page route matched with the page route to be configured exists in all the initial configured page routes, and trigger a page nonexistence event.
In this embodiment, when the event triggering unit 2022 determines that the page route to be configured does not exist in the configuration file library, the event triggering unit 2022 may specifically monitor the page absence event of the page route to be opened by the WeChat applet through an instruction App.
Optionally, as shown in fig. 6, the determining module 202 may further include an information acquiring unit 2023, a matching unit 2024, a converting unit 2025, and a page route acquiring unit 2026, where the event triggering unit 2022 is further configured to trigger the page to have no event, and call the information acquiring unit 2023.
The information obtaining unit 2023 is configured to obtain, by using a preset regular expression, the first target information and the second target information in the to-be-configured page route.
A matching unit 2024 is configured to match and obtain a target configured route corresponding to the first target information in the initial configured page route
The conversion unit 2025 is configured to convert the second target information into third target information in a preset page routing format.
The page route obtaining unit 2026 is configured to obtain the target page route according to the first target information and the third target information.
For better understanding of the information acquisition unit 2023, the matching unit 2024, the conversion unit 2025, and the page route acquisition unit 2026, the present embodiment will be described below as a specific example, assuming that the page route to be configured is/pages/hotel/detail/document/2895314, the first target information acquired by the preset regular expression in the information acquisition unit 2023 is/pages/hotel/detail/index? (the target configured route corresponding to the first target information in the initial configured page route is/pages/hotel/detail/index. Finally, the first target information/pages/hotel/details/index is spliced with the third target information id=2895314 & biz=1 by the page route obtaining unit 2026 so as to obtain the target page route/pages/hotel/details/index=2895314 & biz=1, and in the WeChat applet, the user can open the custom page route through the target page route.
Alternatively, as shown in fig. 7, the page route acquiring unit 2026 includes a first character string setting subunit 20261, a second character string acquiring subunit 20262, and a route acquiring subunit 20263.
The first string setting subunit 20261 is configured to set a first target string corresponding to the third target information, where the first target string corresponds to a service type corresponding to the to-be-configured page route.
The second string obtaining subunit 20262 obtains, by using a preset regular expression, a second target string in the to-be-configured page route, where the second target string corresponds to a service type corresponding to the to-be-configured page route.
The route obtaining subunit 20263 is configured to splice the first target information, the first target string, the second target string, and the third target information to obtain the target page route.
For better understanding of the first string setting subunit 20261, the second string obtaining subunit 20262, and the route obtaining subunit 20263, the following description will be given with reference to specific examples, such as custom routing to be configured as/pages/hotel/detail/dope/2895314? Is the first target information/pages/hotel/details/index? The second target information is domastic/2895314 pay=1, the third target information is domastic, 2895314 can be obtained by regular expression \pages/hotel/detail/[ a-zA-Z ] +/\d+ $\, then the first string setting subunit 20261 can set the first target string corresponding to the third target information, assuming that the first target string set for domastic in this embodiment is biz=1, the first target string set for 2895314 is id=, then the first target string and the third target information are spliced according to the requirement, and the third target information are spliced by connectors & for example by splicing id=and 2895314 to obtain id= 2895314, id= 2895314 and biz=1 to obtain id=2895314 biz=1, then the second string obtaining subunit 20262 can obtain the second target string=1 in the to-be-configured page route, and the first target string set for 2895314 is id=, then the first target string obtaining subunit 63 can obtain the third target information by splicing according to the requirement, and then the third target information is spliced by connectors & splicing according to the requirements, such as splicing id=3862 to obtain id= 2895314. And splicing the spliced third target information id=2895314 & biz=1 and the second target character string pay=1 to obtain a final target page route/pages/hotel/detail/index=2895314 & biz=1 pay=1. In this specific example, biz=1 represents a dometic, that is, a domestic hotel, and pay=1 represents a room type paid to a store, for example, when all domestic hotels need to be searched, a hotel meeting the requirement can be found by matching pages including biz=1 in the page route, and when all room types paid to a store need to be searched, a room type meeting the requirement can be found by matching pages including pay=1 in the page route.
It should be understood that the target page route may be acquired according to actual requirements, for example, the first string setting subunit 20261 may not be invoked, in which case the route acquiring subunit 20263 may acquire the target page route according to the second target string, the first target information, and the third target information; for another example, the second string retrieving subunit 20262 may not be invoked, in which case the route retrieving subunit 20263 may retrieve the target page route according to the first target string, the first target information, and the third target information.
In addition, in this embodiment, the custom page route/pages/hotel/detail/oversea/999915 may be converted into the target page route/pages/hotel/detail/index=999915 & biz=2, where biz=2 represents a foreign hotel, and the custom page route/pages/hotel/brand/hasing may be converted into the target page route/pages/hotel/brand/index=hasting, where brand=hasting represents a hotel, and the identifiable mark of the brand hotel is hasting. The process of converting the custom page route to be configured into the page route is similar to the above, and therefore will not be described here again.
The overall analysis process of this embodiment is described below by way of a specific example:
the page route to be configured is pages/hotel/mgm/list, and the custom route is a dynamic route which is not configured in a configuration file library of the applet application, so that an event of page absence of the page route to be opened by the WeChat applet is monitored through an instruction App. Fig. 4 shows a schematic diagram of a page skip under the scene, under the current page, a user's view instruction of a user-defined to-be-configured page route with reference numeral 20 is obtained, at this time, by converting the to-be-assembled page route 20 into a target page route/pages/hotel/components/webview data = {_rl\https% 3 a-2 f%2 fm-ctrip. Com%2fweba, the page skip can be realized after the applet recognizes the route, and under the scene, the page with the real skip is the page with reference numeral 21.
In this embodiment, on the one hand, the user-defined page route to be configured can be successfully converted into the target page route meeting the configuration requirement of the configured page route, and the classification information included in the target page route can be rapidly distinguished according to the information in the target page route, so that the analysis efficiency of the page route is higher, the user can rapidly find the page meeting the requirement of the user, and the user experience is improved.
Example 5
The present embodiment provides an electronic device, which may be expressed in the form of a computing device (for example, may be a server device), including a memory, a processor, and a computer program stored on the memory and capable of running on the processor, where the processor may implement the method for parsing a page route in any applet application in embodiments 1-2 when executing the computer program.
Fig. 8 shows a schematic diagram of the hardware structure of the present embodiment, and as shown in fig. 8, the electronic device 9 specifically includes:
at least one processor 91, at least one memory 92, and a bus 93 for connecting the different system components (including the processor 91 and the memory 92), wherein:
the bus 93 includes a data bus, an address bus, and a control bus.
The memory 92 includes volatile memory such as Random Access Memory (RAM) 921 and/or cache memory 922, and may further include Read Only Memory (ROM) 923.
Memory 92 also includes a program/utility 925 having a set (at least one) of program modules 924, such program modules 924 including, but not limited to: an operating system, one or more application programs, other program modules, and program data, each or some combination of which may include an implementation of a network environment.
The processor 91 executes various functional applications and data processing, such as the parsing method of the page route in any applet application in embodiment 1-embodiment 2 of the present application, by running a computer program stored in the memory 92.
The electronic device 9 may further communicate with one or more external devices 94 (e.g., keyboard, pointing device, etc.). Such communication may occur through an input/output (I/O) interface 95. Also, the electronic device 9 may communicate with one or more networks such as a Local Area Network (LAN), a Wide Area Network (WAN) and/or a public network, such as the Internet, through a network adapter 96. The network adapter 96 communicates with other modules of the electronic device 9 via the bus 93. It should be appreciated that although not shown in the figures, other hardware and/or software modules may be used in connection with the electronic device 9, including but not limited to: microcode, device drivers, redundant processors, external disk drive arrays, RAID (disk array) systems, tape drives, data backup storage systems, and the like.
It should be noted that although several units/modules or sub-units/modules of an electronic device are mentioned in the above detailed description, such a division is merely exemplary and not mandatory. Indeed, the features and functionality of two or more units/modules described above may be embodied in one unit/module in accordance with embodiments of the present application. Conversely, the features and functions of one unit/module described above may be further divided into ones that are embodied by a plurality of units/modules.
Example 6
The present embodiment provides a computer-readable storage medium having stored thereon a computer program which, when executed by a processor, implements the steps of the method for parsing a page route in any one of the applet applications in embodiments 1-2.
More specifically, among others, readable storage media may be employed including, but not limited to: portable disk, hard disk, random access memory, read only memory, erasable programmable read only memory, optical storage device, magnetic storage device, or any suitable combination of the foregoing.
In a possible embodiment, the application may also be implemented in the form of a program product comprising program code for causing a terminal device to carry out the steps of the parsing method for page routing in any of the applet applications of embodiments 1-2, when said program product is run on the terminal device.
Wherein the program code for carrying out the application may be written in any combination of one or more programming languages, which program code may execute entirely on the user device, partly on the user device, as a stand-alone software package, partly on the user device and partly on the remote device or entirely on the remote device.
While specific embodiments of the application have been described above, it will be appreciated by those skilled in the art that this is by way of example only, and the scope of the application is defined by the appended claims. Various changes and modifications to these embodiments may be made by those skilled in the art without departing from the principles and spirit of the application, but such changes and modifications fall within the scope of the application.

Claims (8)

1. A method for parsing a page route in an applet application, the method comprising:
self-defining a page route to be configured;
judging whether the page route to be configured exists in a configuration file library of the applet application, if not, converting the page route to be configured into a target page route, and if so, determining that the page route to be configured is a jumpable page route;
the step of converting the to-be-configured page route into a target page route comprises the following steps:
acquiring first target information and second target information in the page route to be configured through a preset regular expression;
matching to obtain a target configured route corresponding to the first target information in the initial configured page route;
converting the second target information into third target information in a preset page routing format;
obtaining the target page route according to the first target information and the third target information;
the configuration file library stores a plurality of initial configured page routes, and the target page route corresponds to one initial configured page route.
2. The method for resolving page routes in an applet application according to claim 1 wherein,
the step of judging whether the page route to be configured exists in the configuration file library of the applet application comprises the following steps:
comparing the page route to be configured with each initial configured page route in the configuration file library;
when the page route matched with the page route to be configured does not exist in all the initial configured page routes, determining that the page route to be configured does not exist in the configuration file library, and triggering a page nonexistence event.
3. The method for resolving a page route in an applet application according to claim 1, wherein the step of obtaining the target page route according to the first target information and the third target information comprises:
setting a first target character string corresponding to the third target information, wherein the first target character string corresponds to the service type corresponding to the page route to be configured;
the first target information, the first target character string and the third target information are spliced to obtain the target page route;
or alternatively, the first and second heat exchangers may be,
the step of obtaining the target page route according to the first target information and the third target information comprises the following steps:
acquiring a second target character string in the to-be-configured page route through a preset regular expression, wherein the second target character string corresponds to a service type corresponding to the to-be-configured page route;
the first target information and the second target character are spliced to obtain the target page route;
or alternatively, the first and second heat exchangers may be,
the step of obtaining the target page route according to the first target information and the third target information comprises the following steps:
setting a first target character string corresponding to the third target information, wherein the first target character string corresponds to the service type corresponding to the page route to be configured;
acquiring a second target character string in the to-be-configured page route through a preset regular expression, wherein the second target character string corresponds to a service type corresponding to the to-be-configured page route;
and performing splicing processing on the first target character string, the second target character string, the first target information and the third target information to obtain the target page route.
4. A parsing system for page routing in applet applications, said parsing system comprising: the self-defining module and the judging module;
the self-defining module is used for self-defining the page route to be configured;
the judging module is used for judging whether the page route to be configured exists in the configuration file library of the applet application, if not, converting the page route to be configured into a target page route, and if so, determining that the page route to be configured is a jumpable page route;
the judging module further comprises an information acquisition unit, a matching unit, a conversion unit and a page route acquisition unit;
the information acquisition unit is used for acquiring first target information and second target information in the page route to be configured through a preset regular expression;
the matching unit is used for matching to obtain a target configured route corresponding to the first target information in the initial configured page route;
the conversion unit is used for converting the second target information into third target information in a preset page routing format;
the page route acquisition unit is used for acquiring the target page route according to the first target information and the third target information;
the configuration file library stores a plurality of initial configured page routes, and the target page route corresponds to one initial configured page route.
5. The system for resolving page routing in an applet application according to claim 4,
the judging module comprises: the comparison unit and the event triggering unit;
the comparison unit is used for comparing the page route to be configured with each initial configured page route in the configuration file library;
and the event triggering unit is used for determining that the page route to be configured does not exist in the configuration file library when the page route matched with the page route to be configured does not exist in all the initial configured page routes, and triggering a page nonexistent event.
6. The system for resolving a page route in an applet application according to claim 4, wherein the page route acquiring unit comprises: a first character string setting subunit and a route obtaining subunit;
the first character string setting subunit is configured to set a first target character string corresponding to the third target information, where the first target character string corresponds to a service type corresponding to the to-be-configured page route;
the route acquisition subunit is used for performing splicing processing on the first target information, the first target character string and the third target information to obtain the target page route;
or alternatively, the first and second heat exchangers may be,
the page route acquisition unit includes: a second character string acquisition subunit and a route acquisition subunit;
the second character string obtaining subunit is configured to obtain a second target character string in the to-be-configured page route through a preset regular expression, where the second target character string corresponds to a service type corresponding to the to-be-configured page route;
the route obtaining subunit is used for obtaining the target page route according to the splicing processing of the first target information and the second target character string;
or alternatively, the first and second heat exchangers may be,
the page route obtaining unit comprises a first character string setting subunit, a second character string obtaining subunit and a route obtaining subunit:
the first character string setting subunit is configured to set a first target character string corresponding to the third target information, where the first target character string corresponds to a service type corresponding to the to-be-configured page route;
the second character string obtaining subunit obtains a second target character string in the to-be-configured page route through a preset regular expression, wherein the second target character string corresponds to a service type corresponding to the to-be-configured page route;
the route obtaining subunit is configured to splice the first target string, the second target string, the first target information, and the third target information to obtain the target page route.
7. An electronic device comprising a memory, a processor and a computer program stored on the memory for execution on the processor, wherein the processor implements a method of parsing a page route in an applet application according to any one of claims 1 to 3 when executing the computer program.
8. A computer readable storage medium having stored thereon a computer program, which when executed by a processor performs the steps of the method for parsing a page route in an applet application according to any one of claims 1 to 3.
CN202010291847.5A 2020-04-14 2020-04-14 Parsing methods, systems, equipment and media for page routing in mini program applications Active CN111552895B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202010291847.5A CN111552895B (en) 2020-04-14 2020-04-14 Parsing methods, systems, equipment and media for page routing in mini program applications

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202010291847.5A CN111552895B (en) 2020-04-14 2020-04-14 Parsing methods, systems, equipment and media for page routing in mini program applications

Publications (2)

Publication Number Publication Date
CN111552895A CN111552895A (en) 2020-08-18
CN111552895B true CN111552895B (en) 2023-10-31

Family

ID=72005738

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202010291847.5A Active CN111552895B (en) 2020-04-14 2020-04-14 Parsing methods, systems, equipment and media for page routing in mini program applications

Country Status (1)

Country Link
CN (1) CN111552895B (en)

Families Citing this family (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113821193B (en) * 2020-11-26 2023-09-26 北京京东振世信息技术有限公司 Information generation method, device and storage medium
CN112783580A (en) * 2021-01-18 2021-05-11 微民保险代理有限公司 Routing control method and device based on sub-application and computer equipment
CN112925586B (en) * 2021-03-10 2024-02-27 深圳市活力天汇科技股份有限公司 Applet routing method, device, computer equipment and storage medium
CN113472752B (en) * 2021-06-11 2023-12-01 北京达佳互联信息技术有限公司 Authority processing method and device, electronic equipment and storage medium

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US6314451B1 (en) * 1998-05-15 2001-11-06 Unicast Communications Corporation Ad controller for use in implementing user-transparent network-distributed advertising and for interstitially displaying an advertisement so distributed
CN108319489A (en) * 2018-02-13 2018-07-24 广东欧珀移动通信有限公司 Application page starting method and device, storage medium and electronic equipment
CN110764895A (en) * 2019-10-30 2020-02-07 江苏满运软件科技有限公司 Application service dynamic switching method, system, equipment and storage medium
CN110990057A (en) * 2019-11-22 2020-04-10 百度在线网络技术(北京)有限公司 Extraction method, device, equipment and medium of small program sub-chain information

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US6314451B1 (en) * 1998-05-15 2001-11-06 Unicast Communications Corporation Ad controller for use in implementing user-transparent network-distributed advertising and for interstitially displaying an advertisement so distributed
CN108319489A (en) * 2018-02-13 2018-07-24 广东欧珀移动通信有限公司 Application page starting method and device, storage medium and electronic equipment
CN110764895A (en) * 2019-10-30 2020-02-07 江苏满运软件科技有限公司 Application service dynamic switching method, system, equipment and storage medium
CN110990057A (en) * 2019-11-22 2020-04-10 百度在线网络技术(北京)有限公司 Extraction method, device, equipment and medium of small program sub-chain information

Non-Patent Citations (3)

* Cited by examiner, † Cited by third party
Title
Kazuaki Kajitori.generating code for simple dyamic web application via routing configurations.《International Journal or Modern Education and Computer Science》》.2017,第第9卷卷(第第9卷期),第1-12页. *
李哲等.微信小程序的架构与开发浅析.《福建电脑》.2019,第35卷(第第35卷期),第66-69页. *
陈辰等.基于路由模式的前端框架设计与改进.电脑知识与技术.2018,(12),第53-54+58页. *

Also Published As

Publication number Publication date
CN111552895A (en) 2020-08-18

Similar Documents

Publication Publication Date Title
CN111552895B (en) Parsing methods, systems, equipment and media for page routing in mini program applications
CN110297689B (en) Intelligent contract execution method, device, equipment and medium
CN113987074A (en) Distributed service full-link monitoring method and device, electronic equipment and storage medium
CN111190888A (en) Method and device for managing graph database cluster
CN104468189B (en) A kind of method for the automatic upgrading BIOS of different clients version
CN110895472B (en) A method and device for identifying business changes
CN110365724B (en) Task processing method and device and electronic equipment
CN110134702A (en) Data stream splicing method, device, device and storage medium
WO2023092580A1 (en) Page display method and apparatus, storage medium, and electronic device
WO2020199659A1 (en) Method and apparatus for determining push priority information
CN111158654A (en) Algorithm calling method, device, server and storage medium
CN114844792B (en) Dynamic monitoring method, device, equipment and storage medium based on LUA language
US20130262367A1 (en) Predicting an effect of events on assets
WO2020233013A1 (en) Data processing method and device, and storage medium
CN112948733B (en) Interface maintenance method, device, computing equipment and medium
CN110716804A (en) Method and device for automatically deleting useless resources, storage medium and electronic equipment
PH12015500034B1 (en) A web browser operation method and system
CN112486517A (en) Application program installation method and system, electronic equipment and storage medium
CN108089852B (en) Method, medium, apparatus and computing device for establishing attribute access
CN114168652B (en) A smart contract interaction method, device, equipment and storage medium
CN117130990A (en) A data processing method and device
CN117648386A (en) Detection method, detection device, detection equipment and storage medium
WO2023151397A1 (en) Application program deployment method and apparatus, device, and medium
CN119558320A (en) Request statement processing method and device, storage medium and electronic device
CN113626747B (en) Breadcrumb navigation generation method and device

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant