CN112417331A - Page routing method and device, electronic equipment and computer-readable storage medium - Google Patents
Page routing method and device, electronic equipment and computer-readable storage medium Download PDFInfo
- Publication number
- CN112417331A CN112417331A CN202011258511.5A CN202011258511A CN112417331A CN 112417331 A CN112417331 A CN 112417331A CN 202011258511 A CN202011258511 A CN 202011258511A CN 112417331 A CN112417331 A CN 112417331A
- Authority
- CN
- China
- Prior art keywords
- page
- target
- level
- current
- page data
- 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.)
- Pending
Links
Images
Classifications
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F16/00—Information retrieval; Database structures therefor; File system structures therefor
- G06F16/90—Details of database functions independent of the retrieved data types
- G06F16/95—Retrieval from the web
- G06F16/958—Organisation or management of web site content, e.g. publishing, maintaining pages or automatic linking
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F16/00—Information retrieval; Database structures therefor; File system structures therefor
- G06F16/90—Details of database functions independent of the retrieved data types
- G06F16/95—Retrieval from the web
- G06F16/957—Browsing optimisation, e.g. caching or content distillation
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F9/00—Arrangements for program control, e.g. control units
- G06F9/06—Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
- G06F9/44—Arrangements for executing specific programs
- G06F9/445—Program loading or initiating
- G06F9/44521—Dynamic linking or loading; Link editing at or after load time, e.g. Java class loading
- G06F9/44526—Plug-ins; Add-ons
Landscapes
- Engineering & Computer Science (AREA)
- Theoretical Computer Science (AREA)
- Databases & Information Systems (AREA)
- Software Systems (AREA)
- Physics & Mathematics (AREA)
- General Engineering & Computer Science (AREA)
- General Physics & Mathematics (AREA)
- Data Mining & Analysis (AREA)
- User Interface Of Digital Computer (AREA)
Abstract
The embodiment of the invention provides a page routing method and device, electronic equipment and a computer readable storage medium. The page routing method comprises the following steps: when a first target request is monitored under the condition that the level of a current page is equal to a first preset level, target page data are obtained; the first target request is used for indicating jumping from a current level page to a next level page; the target page data is page data corresponding to a next-level page; creating a first target assembly, and writing target page data into the first target assembly; adding a first target assembly comprising target page data to a current page to obtain a first target page; and displaying the first target page as a next-level page. The embodiment of the invention can display the page data in the current page in a component mode under the condition of not increasing the page level. The problem caused by continuously registering a new page after the page level reaches the maximum level is avoided, and the limitation of the page level is overcome.
Description
Technical Field
The present invention relates to the field of page processing technologies, and in particular, to a page routing method and apparatus, an electronic device, and a computer-readable storage medium.
Background
The applet is an application which can be used without downloading and installing, realizes the dream of 'being reachable by a touch' of the application, and can be opened by scanning or searching by a user.
Usually, a plurality of applets with different functions are attached to the same target application, and the applets provide the functions in the running process of the target application. It is necessary to ensure the proper functioning of the target application while the applet provides the functionality. The target application may set certain restrictions on the applet. For example, in the applet page routing process, a hierarchy limit is set for the applet page, i.e. after a certain number of hierarchy pages are opened in the applet, a new page cannot be opened.
However, the hierarchical limitation of pages is not friendly enough for a high volume of applets. It will not only affect the design of business logic in the applet, but also cause some trouble to the development. For example, many business logic in a small program may result in multiple layers of pages; one product in the current page is displayed in the recommendation position of another product, and the level quantity is occupied when the products are clicked one by one. Regardless of the tier restrictions, the applet may crash after multiple clicks during the page routing process.
Disclosure of Invention
In view of the above, embodiments of the present invention are proposed to provide a page routing method and apparatus, an electronic device, and a computer-readable storage medium, which overcome or at least partially solve the above problems.
In a first aspect, an embodiment of the present invention provides a page routing method, which is applied to a first target application, where the first target application runs in a second target application, and the method includes:
when a first target request is monitored under the condition that the level of a current page is equal to a first preset level, target page data are obtained; wherein the first target request is used for indicating jumping from the current level page to a next level page; the target page data is page data corresponding to the next-level page;
creating a first target component and writing the target page data into the first target component;
adding the first target assembly comprising the target page data to the current page to obtain a first target page;
and displaying the first target page as the next-level page.
Optionally, before the step of acquiring the target page data when the first target request is monitored when the level of the current page is equal to the first preset level, the method further includes:
when the first target request is monitored under the condition that the level of the current page is equal to a second preset level, registering a new page and creating a second target component; wherein the second preset level is smaller than the first preset level, and the numerical difference between the second preset level and the first preset level is 1;
acquiring the target page data, and writing the target page data into the second target assembly;
adding the second target assembly comprising the target page data into the new page to obtain a second target page;
displaying the second target page as the next-level page;
the adding the first target component including the target page data to the current page includes:
overlaying the first target component including the target page data onto the second target component including the target page data.
Optionally, after the step of displaying the first target page as the next-level page, the method further includes:
deleting the first target assembly in the current page under the condition that a second target request is monitored; wherein the second target request is used for indicating that a previous level page is returned from a current level page;
and displaying the current page after the first target assembly is deleted as the upper-level page.
Optionally, when the first target request is monitored when the level of the current page is equal to a first preset level, acquiring target page data includes:
monitoring the first target request;
when the first target request is monitored, determining the level of the current page;
and when the level of the current page is equal to the first preset level, acquiring the target page data.
Optionally, before the step of acquiring the target page data when the first target request is monitored when the level of the current page is equal to the first preset level, the method further includes:
registering a new page when the first target request is monitored under the condition that the level of the current page is smaller than a second preset level; wherein the second preset level is smaller than the first preset level, and the numerical difference between the second preset level and the first preset level is greater than 1;
acquiring the target page data and writing the target page data into the new page;
and displaying the new page comprising the target page data as the next-level page.
In a second aspect, an embodiment of the present invention further provides a page routing apparatus, which is applied to a first target application, where the first target application runs in a second target application, and the apparatus includes:
the first acquisition module is used for acquiring target page data when a first target request is monitored under the condition that the level of the current page is equal to a first preset level; wherein the first target request is used for indicating jumping from the current level page to a next level page; the target page data is page data corresponding to the next-level page;
the first creating module is used for creating a first target component and writing the target page data into the first target component;
the first processing module is used for adding the first target assembly comprising the target page data to the current page to obtain a first target page;
and the first routing module is used for displaying the first target page as the next-level page.
Optionally, the apparatus further comprises:
the new page module is used for registering a new page and creating a second target component when the first target request is monitored under the condition that the level of the current page is equal to a second preset level; wherein the second preset level is smaller than the first preset level, and the numerical difference between the second preset level and the first preset level is 1;
the second acquisition module is used for acquiring the target page data and writing the target page data into the second target assembly;
the second processing module is used for adding the second target assembly comprising the target page data into the new page to obtain a second target page;
the second routing module is used for displaying the second target page as the next-level page;
the first processing module is specifically configured to overlay the first target component including the target page data onto the second target component including the target page data.
Optionally, the apparatus further comprises:
the third processing module is used for deleting the first target assembly in the current page under the condition that a second target request is monitored; wherein the second target request is used for indicating that a previous level page is returned from a current level page;
and the third routing module is used for displaying the current page after the first target assembly is deleted as the upper-level page.
In a third aspect, an embodiment of the present invention further provides an electronic device, which includes a memory, a processor, and a computer program stored in the memory and executable on the processor, where the processor implements the steps in the page routing method when executing the computer program.
In a fourth aspect, the embodiment of the present invention further provides a computer-readable storage medium, where a computer program is stored on the computer-readable storage medium, and when executed by a processor, the computer program implements the steps in the page routing method described above.
In the embodiment of the present invention, a page routing method is applied to a first target application, where the first target application runs in a second target application, and the method includes: when a first target request is monitored under the condition that the level of a current page is equal to a first preset level, target page data are obtained; the first target request is used for indicating jumping from a current level page to a next level page; the target page data is page data corresponding to a next-level page. And creating a first target component, and writing the target page data into the first target component. Target page data is loaded by the component. And further adding a first target assembly comprising target page data to the current page to obtain a first target page. The target page data is displayed in the first target page in a component mode. And displaying the first target page as a next-level page. Therefore, target page data can be displayed without registering a new page. The embodiment of the invention can display the page data of the next-level page in the current page in a component mode under the condition of not increasing the page level. The problem of application crash caused by continuously registering a new page after the page level reaches the maximum level is avoided, and the limitation of the page level is overcome.
Drawings
In order to more clearly illustrate the technical solutions of the embodiments of the present invention, the drawings needed to be used in the description of the embodiments of the present invention will be briefly introduced below, and it is obvious that the drawings in the following description are only some embodiments of the present invention, and it is obvious for those skilled in the art that other drawings can be obtained according to these drawings without inventive labor.
Fig. 1 is a flowchart illustrating steps of a page routing method according to an embodiment of the present invention;
FIG. 2 is a flowchart of an application scenario of the page routing method according to the embodiment of the present invention;
fig. 3 is a block diagram of a page routing apparatus according to an embodiment of the present invention;
fig. 4 is a block diagram of an electronic device according to an embodiment of the present invention.
Detailed Description
The technical solutions in the embodiments of the present invention will be clearly and completely described below with reference to the drawings in the embodiments of the present invention, and it is obvious that the described embodiments are some, not all, embodiments of the present invention. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present invention.
It should be appreciated that reference throughout this specification to "one embodiment" or "an embodiment" means that a particular feature, structure or characteristic described in connection with the embodiment is included in at least one embodiment of the present invention. Thus, the appearances of the phrases "in one embodiment" or "in an embodiment" in various places throughout this specification are not necessarily all referring to the same embodiment. Furthermore, the particular features, structures, or characteristics may be combined in any suitable manner in one or more embodiments.
In various embodiments of the present invention, it should be understood that the sequence numbers of the following processes do not mean the execution sequence, and the execution sequence of each process should be determined by its function and inherent logic, and should not constitute any limitation to the implementation process of the embodiments of the present invention.
Referring to fig. 1, an embodiment of the present invention provides a page routing method, which is applied to a first target application, where the first target application runs in a second target application; the first target application may be an applet, but is not limited thereto.
The page routing method comprises the following steps:
It should be noted that, during the process of jumping from the current page to another page, it can be determined whether the page level changes by the monitored jumping method. For example, a jump method during page jump is monitored by a switch method, and when the jump method is determined to be a method for indicating page hierarchy increase, target page data is acquired. The first target request is used to indicate a jump from a current level page to a next level page, i.e., to increase the page level. The first target request may be understood as a native method in a computer program, such as, but not limited to, the wx. And the target page data is page data corresponding to the next-level page.
The specific value of the first preset level can be set according to the requirement. Specifically, the specific numerical value of the first preset level may be preset according to the restriction rule of the page level in the second target application. For example, in the case that the restriction rule of the page level in the second target application is that the maximum page level value does not exceed 10, the first preset level value may be 10, that is, the first preset level is the 10 th level.
It should be noted that the first target component is a component that can be exposed in a page. Preferably, the size of the first target component is the same as the size of the current page. The component model may be preset, and when the first target component is created, the first target component is created according to the component model. And writing the target page data into the first target component, namely loading the target page data through the first target component.
It should be noted that the target page data is displayed in the current page by means of components. That is, after a first target request indicating a jump from a current-level page to a next-level page is monitored, target page data is displayed in the current page without increasing the page level. Preferably, the first target component including the target page data can be overlaid on all components of the current page, so that only the target page data on the first target component is displayed, which is the same as the effect of displaying the target data in the new page, and the user can normally see the target page data without affecting the user experience.
And 104, displaying the first target page as a next-level page.
It should be noted that when the first object request is detected in step 101, the page does not need to be registered again. Since the current page is a page that has already been registered, the first target page is a page that has already been registered. The first target page may be displayed as a newly registered next-level page.
In the embodiment of the present invention, a page routing method is applied to a first target application, where the first target application runs in a second target application, and the method includes: when a first target request is monitored under the condition that the level of a current page is equal to a first preset level, target page data are obtained; the first target request is used for indicating jumping from a current level page to a next level page; the target page data is page data corresponding to a next-level page. And creating a first target component, and writing the target page data into the first target component. Target page data is loaded by the component. And further adding a first target assembly comprising target page data to the current page to obtain a first target page. The target page data is displayed in the first target page in a component mode. And displaying the first target page as a next-level page. Therefore, target page data can be displayed without registering a new page. The embodiment of the invention can display the page data of the next-level page in the current page in a component mode under the condition of not increasing the page level. The problem of application crash caused by continuously registering a new page after the page level reaches the maximum level is avoided, and the limitation of the page level is overcome.
Optionally, when the first target request is monitored when the level of the current page is equal to the first preset level, before the step of obtaining the target page data, the method further includes:
and when the first target request is monitored under the condition that the level of the current page is equal to a second preset level, registering a new page and creating a second target component.
In this step, the second preset level is smaller than the first preset level, and the numerical difference between the second preset level and the first preset level is 1. Since the second preset level is smaller than the first preset level, the limitation of the page level does not need to be considered, so that the page level can be increased, and a new page can be registered. The second target component may be the same as or different from the first target component. Preferably, the second target component and the first target component are the same component created by the same component model.
And acquiring target page data and writing the target page data into a second target assembly.
In this step, the first target requests at different page levels correspond to different target page data. Here, the writing of the target page data into the first target component is similar, and is not described herein again.
And adding a second target assembly comprising the target page data into the new page to obtain a second target page.
In this step, the target page data is displayed in the new page in the form of a component.
And displaying the second target page as a next-level page.
It should be noted that when the current page level is equal to the first preset level, the current page includes the new page and the second target component loaded with the target page data. Thus, adding a first target component including target page data to a current page includes: overlaying a first target component comprising target page data onto a second target component comprising target page data.
In the embodiment of the invention, when the first preset level page is loaded, corresponding target page data is displayed in the registered new page in a component mode by registering the new page and creating a component. Meanwhile, when the page larger than the first preset level is loaded, only the newly created component is required to be covered in the component of the current page, and the operation is simple and convenient.
Optionally, after the step of displaying the first target page as a next-level page, the method further includes:
deleting a first target assembly in the current page under the condition that a second target request is monitored; the second target request is used for indicating that the previous level page is returned from the current level page;
and displaying the current page with the first target assembly deleted as a previous-level page.
It should be noted that the second target request may be understood as a native method in the computer program; such as a method of returning to a previous level page. After the current page level is equal to the first preset level, each time the first target request is monitored, the acquired target page data needs to be displayed in the current page in a component mode. Therefore, multiple layers of components are superposed in the current page in a covering mode, and each layer of component is loaded with corresponding target page data. The multi-level page is simulated through the multi-level components, and when the page of the upper level is returned, only the uppermost component is needed to be deleted, and the component of the lower layer is displayed.
In the embodiment of the invention, the operation of returning to the previous-level page is simulated by deleting the components in the current page. The page data does not need to be acquired again, and the response time is shortened; and meanwhile, the flow consumption is saved for the user.
Optionally, when the first target request is monitored when the level of the current page is equal to the first preset level, acquiring target page data includes:
monitoring a first target request;
when a first target request is monitored, determining the level of a current page;
and when the hierarchy of the current page is equal to a first preset hierarchy, acquiring target page data.
It should be noted that the first target request may be understood as a native method in a computer program, such as, but not limited to, the wx. The method for skipping the page can be monitored by a switch method, and when the skipping method is determined to be a wx. Here, the level of the current page may be determined according to stack information for recording the page level in the second target application. Such as the page stack in WeChat.
Optionally, when the first target request is monitored when the level of the current page is equal to the first preset level, before the step of obtaining the target page data, the method further includes:
registering a new page when a first target request is monitored under the condition that the level of the current page is smaller than a second preset level; the second preset level is smaller than the first preset level, and the numerical difference value between the second preset level and the first preset level is larger than 1;
acquiring target page data and writing the target page data into a new page;
and displaying the new page including the target page data as a next-level page.
It should be noted that, when the level of the current page is smaller than the second preset level, it is stated that the level of the current page does not reach the maximum limit level represented by the first preset level. Therefore, when the hierarchy of the current page does not reach the maximum limit hierarchy, a new page can be registered, and the target page data is displayed by the new page. The target page data is presented without resorting to the form of a component. For example, by the page () method of wechat native, page jumping is normally performed.
In the embodiment of the invention, when the hierarchy of the current page does not reach the maximum limit hierarchy, a new page can be registered, and the target page data is displayed by using the new page. Target page data does not need to be presented in the form of components, and therefore workload in the development process is reduced.
Fig. 2 is a flowchart illustrating an application scenario of the page routing method according to the embodiment of the present invention; the page routing method is applied to the WeChat applet and comprises the following steps:
changing the jumping method, changing the methods of wx.navigatato, wx.redirect to, wx.switch Tab, wx.relaunch and the like of WeChat protogenesis into a user-defined routerTo () method; this routerTo () is used to control page routing. For example, in the page routing process, the page jump mode is monitored, where different jump modes will have different effects on the page level. And executing different operations according to different jump modes. When the jump mode is the mode indicated by wx. When the jumping mode is the mode indicated by wx.redirectto and wx.switchtab, since the change of the page level is not involved, the processing may be performed by the wechat native method.
And rewriting part or all pages, changing the native Page () method into a self-defined newPage method, and performing self-defined logic processing operation under the condition that the current Page level is equal to a first preset level. Here, the newPage method includes a native Page () method, and when a certain condition is satisfied, the native Page () method is directly used by an attribute value. When the page is rewritten, the page which possibly causes the page hierarchy to be overlarge can be selected for rewriting according to the logic between different pages in the application, and the workload in the development process can be reduced. Specifically, a file in which a method related to the rewritten file is described may be introduced to a page to be rewritten. The related files can be introduced, for example, through import.
In the process of rendering the page, the two situations of no parameter and the definition of the same-name parameter are divided; when there is no parameter, onload defaults to data; when the parameters with the same name are defined, calling a callback function preferentially; and then data render the page.
When the operation of returning to the upper-level page is carried out, the upper-level page can be directly returned; the topmost component can also be deleted in the current page, and the return to the previous-level page is simulated in a manner of showing the page data in the next-level component. The specific return mode is determined by the level of the current page and the page level rule of WeChat. The following is a specific example, see table 1:
TABLE 1
In table 1, the row of actual stack information indicates the actual page level condition in the wechat applet. Take the maximum page level of 10 layers as an example. The recording is done once per added level page in the actual stack information until layer 10 is reached. The SDK (Software Development Kit) page stack line indicates an additional stack for recording custom levels according to embodiments of the present invention. The level of customization here is greater than 10 levels. When the self-defined hierarchy is 11 layers, corresponding page data is loaded into the newly created component for storage, and no operation is performed on actual stack information. Similarly, when the self-defined level is 12 or more than 12, similar to the operation of the level being 11, the corresponding page data is loaded into the newly created component for storage, and no operation is performed on the actual stack information. So that a user can open pages with a hierarchy level greater than 10 while operating the applet. And when returning to the page of the previous level, the return from 13 to 1 in sequence can be realized through the cooperation of the SDK page stack and the actual stack information. That is, the user can access the applet as if the page level indicated by a row was normally open.
The page routing method provided by the embodiment of the present invention is described above, and the page routing apparatus provided by the embodiment of the present invention is described below with reference to the accompanying drawings.
Referring to fig. 3, an embodiment of the present invention further provides a page routing apparatus, which is applied to a first target application, where the first target application runs in a second target application, and the apparatus includes:
the first obtaining module 31 is configured to obtain target page data when a first target request is monitored when the level of the current page is equal to a first preset level; the first target request is used for indicating jumping from a current level page to a next level page; the target page data is page data corresponding to a next-level page;
a first creating module 32, configured to create a first target component, and write target page data into the first target component;
the first processing module 33 is configured to add a first target component including target page data to a current page to obtain a first target page;
and the first routing module 34 is configured to display the first target page as a next-level page.
Optionally, the apparatus further comprises:
the new page module is used for registering a new page and creating a second target component when the first target request is monitored under the condition that the level of the current page is equal to a second preset level; the second preset level is smaller than the first preset level, and the numerical difference value between the second preset level and the first preset level is 1;
the second acquisition module is used for acquiring target page data and writing the target page data into a second target assembly;
the second processing module is used for adding a second target assembly comprising target page data into the new page to obtain a second target page;
the second routing module is used for displaying the second target page as a next-level page;
the first processing module is specifically configured to overlay a first target component including the target page data onto a second target component including the target page data.
Optionally, the apparatus further comprises:
the third processing module is used for deleting the first target assembly in the current page under the condition that the second target request is monitored; the second target request is used for indicating that the previous level page is returned from the current level page;
and the third routing module is used for displaying the current page after the first target assembly is deleted as the page of the upper layer.
Optionally, the first obtaining module 31 is specifically configured to monitor the first target request; when a first target request is monitored, determining the level of a current page; and when the hierarchy of the current page is equal to a first preset hierarchy, acquiring target page data.
Optionally, the apparatus further comprises:
the native processing module is used for registering a new page when the first target request is monitored under the condition that the level of the current page is smaller than a second preset level; the second preset level is smaller than the first preset level, and the numerical difference value between the second preset level and the first preset level is larger than 1; acquiring target page data and writing the target page data into a new page; and displaying the new page including the target page data as a next-level page.
The page routing device provided by the embodiment of the present invention can implement each process implemented by the page routing method in the method embodiment of fig. 1, and is not described herein again in order to avoid repetition.
In the embodiment of the invention, the page data of the next-level page can be displayed in the current page in a component mode under the condition of not increasing the page level. The problem of application crash caused by continuously registering a new page after the page level reaches the maximum level is avoided, and the limitation of the page level is overcome.
On the other hand, the embodiment of the present invention further provides an electronic device, which includes a memory, a processor, a bus, and a computer program stored on the memory and executable on the processor, where the processor implements the steps in the page routing method when executing the program.
For example, fig. 4 shows a schematic physical structure diagram of an electronic device.
As shown in fig. 4, the electronic device may include: a processor (processor)410, a communication Interface 420, a memory (memory)430 and a communication bus 440, wherein the processor 410, the communication Interface 420 and the memory 430 are communicated with each other via the communication bus 440. The processor 410 may call logic instructions in the memory 430 to perform the following method:
when a first target request is monitored under the condition that the level of a current page is equal to a first preset level, target page data are obtained; wherein the first target request is used for indicating jumping from the current level page to a next level page; the target page data is page data corresponding to the next-level page;
creating a first target component and writing the target page data into the first target component;
adding the first target assembly comprising the target page data to the current page to obtain a first target page;
and displaying the first target page as the next-level page.
In addition, the logic instructions in the memory 430 may be implemented in the form of software functional units and stored in a computer readable storage medium when the software functional units are sold or used as independent products. Based on such understanding, the technical solution of the present invention may be embodied in the form of a software product, which is stored in a storage medium and includes instructions for causing a computer device (which may be a personal computer, a server, or a network device) to execute all or part of the steps of the method according to the embodiments of the present invention. And the aforementioned storage medium includes: a U-disk, a removable hard disk, a Read-Only Memory (ROM), a Random Access Memory (RAM), a magnetic disk or an optical disk, and other various media capable of storing program codes.
In still another aspect, an embodiment of the present invention further provides a computer-readable storage medium, on which a computer program is stored, where the computer program is implemented to, when executed by a processor, perform the page routing method provided in the foregoing embodiments, for example, including:
when a first target request is monitored under the condition that the level of a current page is equal to a first preset level, target page data are obtained; wherein the first target request is used for indicating jumping from the current level page to a next level page; the target page data is page data corresponding to the next-level page;
creating a first target component and writing the target page data into the first target component;
adding the first target assembly comprising the target page data to the current page to obtain a first target page;
and displaying the first target page as the next-level page.
The above-described embodiments of the apparatus are merely illustrative, and the units described as separate parts may or may not be physically separate, and parts displayed as units may or may not be physical units, may be located in one place, or may be distributed on a plurality of network units. Some or all of the modules may be selected according to actual needs to achieve the purpose of the solution of the present embodiment. One of ordinary skill in the art can understand and implement it without inventive effort.
Through the above description of the embodiments, those skilled in the art will clearly understand that each embodiment can be implemented by software plus a necessary general hardware platform, and certainly can also be implemented by hardware. With this understanding in mind, the above-described technical solutions may be embodied in the form of a software product, which can be stored in a computer-readable storage medium such as ROM/RAM, magnetic disk, optical disk, etc., and includes instructions for causing a computer device (which may be a personal computer, a server, or a network device, etc.) to execute the methods described in the embodiments or some parts of the embodiments.
Finally, it should be noted that: the above examples are only intended to illustrate the technical solution of the present invention, but not to limit it; although the present invention has been described in detail with reference to the foregoing embodiments, it will be understood by those of ordinary skill in the art that: the technical solutions described in the foregoing embodiments may still be modified, or some technical features may be equivalently replaced; and such modifications or substitutions do not depart from the spirit and scope of the corresponding technical solutions of the embodiments of the present invention.
Claims (10)
1. A page routing method is applied to a first target application, and is characterized in that the first target application runs in a second target application, and the method comprises the following steps:
when a first target request is monitored under the condition that the level of a current page is equal to a first preset level, target page data are obtained; wherein the first target request is used for indicating jumping from the current level page to a next level page; the target page data is page data corresponding to the next-level page;
creating a first target component and writing the target page data into the first target component;
adding the first target assembly comprising the target page data to the current page to obtain a first target page;
and displaying the first target page as the next-level page.
2. The method of claim 1, wherein before the step of obtaining target page data when the first target request is monitored when the level of the current page is equal to the first preset level, the method further comprises:
when the first target request is monitored under the condition that the level of the current page is equal to a second preset level, registering a new page and creating a second target component; wherein the second preset level is smaller than the first preset level, and the numerical difference between the second preset level and the first preset level is 1;
acquiring the target page data, and writing the target page data into the second target assembly;
adding the second target assembly comprising the target page data into the new page to obtain a second target page;
displaying the second target page as the next-level page;
the adding the first target component including the target page data to the current page includes:
overlaying the first target component including the target page data onto the second target component including the target page data.
3. The method of claim 1, wherein after the step of displaying the first target page as the next level page, the method further comprises:
deleting the first target assembly in the current page under the condition that a second target request is monitored; wherein the second target request is used for indicating that a previous level page is returned from a current level page;
and displaying the current page after the first target assembly is deleted as the upper-level page.
4. The method of claim 1, wherein when a first target request is monitored when a level of a current page is equal to a first preset level, acquiring target page data comprises:
monitoring the first target request;
when the first target request is monitored, determining the level of the current page;
and when the level of the current page is equal to the first preset level, acquiring the target page data.
5. The method of claim 1, wherein before the step of obtaining target page data when the first target request is monitored when the level of the current page is equal to the first preset level, the method further comprises:
registering a new page when the first target request is monitored under the condition that the level of the current page is smaller than a second preset level; wherein the second preset level is smaller than the first preset level, and the numerical difference between the second preset level and the first preset level is greater than 1;
acquiring the target page data and writing the target page data into the new page;
and displaying the new page comprising the target page data as the next-level page.
6. A page routing apparatus, applied to a first target application, wherein the first target application runs in a second target application, the apparatus comprising:
the first acquisition module is used for acquiring target page data when a first target request is monitored under the condition that the level of the current page is equal to a first preset level; wherein the first target request is used for indicating jumping from the current level page to a next level page; the target page data is page data corresponding to the next-level page;
the first creating module is used for creating a first target component and writing the target page data into the first target component;
the first processing module is used for adding the first target assembly comprising the target page data to the current page to obtain a first target page;
and the first routing module is used for displaying the first target page as the next-level page.
7. The apparatus of claim 6, further comprising:
the new page module is used for registering a new page and creating a second target component when the first target request is monitored under the condition that the level of the current page is equal to a second preset level; wherein the second preset level is smaller than the first preset level, and the numerical difference between the second preset level and the first preset level is 1;
the second acquisition module is used for acquiring the target page data and writing the target page data into the second target assembly;
the second processing module is used for adding the second target assembly comprising the target page data into the new page to obtain a second target page;
the second routing module is used for displaying the second target page as the next-level page;
the first processing module is specifically configured to overlay the first target component including the target page data onto the second target component including the target page data.
8. The apparatus of claim 6, further comprising:
the third processing module is used for deleting the first target assembly in the current page under the condition that a second target request is monitored; wherein the second target request is used for indicating that a previous level page is returned from a current level page;
and the third routing module is used for displaying the current page after the first target assembly is deleted as the upper-level page.
9. An electronic device comprising a processor, a memory and a computer program stored on the memory and executable on the processor, characterized in that the computer program, when executed by the processor, implements the steps of the page routing method according to any of claims 1 to 5.
10. A computer-readable storage medium, on which a computer program is stored which, when being executed by a processor, carries out the steps of the page routing method according to any one of claims 1 to 5.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202011258511.5A CN112417331A (en) | 2020-11-11 | 2020-11-11 | Page routing method and device, electronic equipment and computer-readable storage medium |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202011258511.5A CN112417331A (en) | 2020-11-11 | 2020-11-11 | Page routing method and device, electronic equipment and computer-readable storage medium |
Publications (1)
Publication Number | Publication Date |
---|---|
CN112417331A true CN112417331A (en) | 2021-02-26 |
Family
ID=74781276
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN202011258511.5A Pending CN112417331A (en) | 2020-11-11 | 2020-11-11 | Page routing method and device, electronic equipment and computer-readable storage medium |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN112417331A (en) |
Cited By (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN113127130A (en) * | 2021-05-08 | 2021-07-16 | 广州酷狗计算机科技有限公司 | Page jump method, device and storage medium |
CN113221048A (en) * | 2021-04-20 | 2021-08-06 | 武汉联影医疗科技有限公司 | Page jump method, device, computer equipment and storage medium |
Citations (6)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US6226656B1 (en) * | 1998-11-12 | 2001-05-01 | Sourcefinder, Inc. | System and method for creating, generating and processing user-defined generic specs |
CN110209967A (en) * | 2019-04-17 | 2019-09-06 | 北京奇艺世纪科技有限公司 | Page loading method, device, terminal device and computer-readable medium |
CN110413368A (en) * | 2019-08-07 | 2019-11-05 | 上海千杉网络技术发展有限公司 | Page switching method, device, electronic equipment and machine readable storage medium |
CN110634049A (en) * | 2019-09-05 | 2019-12-31 | 北京无限光场科技有限公司 | Page display content processing method and device, electronic equipment and readable medium |
CN111475246A (en) * | 2020-04-10 | 2020-07-31 | 腾讯科技(深圳)有限公司 | Applet page display method, device, terminal and storage medium |
CN111625741A (en) * | 2020-04-30 | 2020-09-04 | 贝壳技术有限公司 | Page data interaction method and device, storage medium and electronic equipment |
-
2020
- 2020-11-11 CN CN202011258511.5A patent/CN112417331A/en active Pending
Patent Citations (6)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US6226656B1 (en) * | 1998-11-12 | 2001-05-01 | Sourcefinder, Inc. | System and method for creating, generating and processing user-defined generic specs |
CN110209967A (en) * | 2019-04-17 | 2019-09-06 | 北京奇艺世纪科技有限公司 | Page loading method, device, terminal device and computer-readable medium |
CN110413368A (en) * | 2019-08-07 | 2019-11-05 | 上海千杉网络技术发展有限公司 | Page switching method, device, electronic equipment and machine readable storage medium |
CN110634049A (en) * | 2019-09-05 | 2019-12-31 | 北京无限光场科技有限公司 | Page display content processing method and device, electronic equipment and readable medium |
CN111475246A (en) * | 2020-04-10 | 2020-07-31 | 腾讯科技(深圳)有限公司 | Applet page display method, device, terminal and storage medium |
CN111625741A (en) * | 2020-04-30 | 2020-09-04 | 贝壳技术有限公司 | Page data interaction method and device, storage medium and electronic equipment |
Cited By (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN113221048A (en) * | 2021-04-20 | 2021-08-06 | 武汉联影医疗科技有限公司 | Page jump method, device, computer equipment and storage medium |
CN113127130A (en) * | 2021-05-08 | 2021-07-16 | 广州酷狗计算机科技有限公司 | Page jump method, device and storage medium |
CN113127130B (en) * | 2021-05-08 | 2024-05-14 | 广州酷狗计算机科技有限公司 | Page jump method, device and storage medium |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN108293081B (en) | Deep linking of program playback to mobile application state through user interface events | |
CN111104635B (en) | Method and device for generating form webpage | |
CN111475246A (en) | Applet page display method, device, terminal and storage medium | |
US20170024308A1 (en) | System and method for testing data representation for different mobile devices | |
CN108228293B (en) | Interface skin switching method and device | |
CN111814089A (en) | Page rendering method and device, rendering server and storage medium | |
CN110673924B (en) | Multi-architecture container cloud mirror image selection method, device, equipment and storage medium | |
CN111475161B (en) | Method, device and equipment for accessing component | |
CN112417331A (en) | Page routing method and device, electronic equipment and computer-readable storage medium | |
CN111223036B (en) | GPU (graphics processing unit) virtualization sharing method and device, electronic equipment and storage medium | |
CN107111418B (en) | Icon displacement with minimal disruption | |
CN110610352A (en) | Flow processing method and device, electronic equipment and computer readable storage medium | |
CN113221048A (en) | Page jump method, device, computer equipment and storage medium | |
CN116304442A (en) | Page code generation method and device, electronic equipment and storage medium | |
CN111381745B (en) | Page switching method, device and equipment | |
CN110442400B (en) | Browser control method and device | |
Delessio et al. | Sams teach yourself Android application development in 24 hours | |
CA3055859A1 (en) | Method and system for operating a software application on a processor of a mobile device | |
CN114679491A (en) | Micro front-end service application method and device, storage medium and electronic equipment | |
CN115686706B (en) | Terminal view configuration method, device, computer equipment and storage medium | |
CN117971221B (en) | Single page application layout container configuration system, method and product | |
CN114895995B (en) | Control view generation method and device, electronic equipment and readable medium | |
CN117111941B (en) | Component library adding method, device, equipment and storage medium | |
CN115268884B (en) | Mobile terminal visual page configuration and rendering method based on aPaaS platform | |
CN110032687B (en) | Webpage content processing 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 |