CN117390313A - Page processing method, device, computer equipment, storage medium and product - Google Patents

Page processing method, device, computer equipment, storage medium and product Download PDF

Info

Publication number
CN117390313A
CN117390313A CN202311099137.2A CN202311099137A CN117390313A CN 117390313 A CN117390313 A CN 117390313A CN 202311099137 A CN202311099137 A CN 202311099137A CN 117390313 A CN117390313 A CN 117390313A
Authority
CN
China
Prior art keywords
page
sequence
pages
local
switching
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
Application number
CN202311099137.2A
Other languages
Chinese (zh)
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.)
Bank of China Ltd
Original Assignee
Bank of China 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 Bank of China Ltd filed Critical Bank of China Ltd
Priority to CN202311099137.2A priority Critical patent/CN117390313A/en
Publication of CN117390313A publication Critical patent/CN117390313A/en
Pending legal-status Critical Current

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR 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/957Browsing optimisation, e.g. caching or content distillation
    • G06F16/9574Browsing optimisation, e.g. caching or content distillation of access to content, e.g. by caching
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR 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/957Browsing optimisation, e.g. caching or content distillation
    • G06F16/9577Optimising the visualization of content, e.g. distillation of HTML documents
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/01Input arrangements or combined input and output arrangements for interaction between user and computer
    • G06F3/048Interaction techniques based on graphical user interfaces [GUI]
    • G06F3/0484Interaction techniques based on graphical user interfaces [GUI] for the control of specific functions or operations, e.g. selecting or manipulating an object, an image or a displayed text element, setting a parameter value or selecting a range
    • G06F3/04842Selection of displayed objects or displayed text elements
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/01Input arrangements or combined input and output arrangements for interaction between user and computer
    • G06F3/048Interaction techniques based on graphical user interfaces [GUI]
    • G06F3/0487Interaction techniques based on graphical user interfaces [GUI] using specific features provided by the input device, e.g. functions controlled by the rotation of a mouse with dual sensing arrangements, or of the nature of the input device, e.g. tap gestures based on pressure sensed by a digitiser
    • G06F3/0488Interaction techniques based on graphical user interfaces [GUI] using specific features provided by the input device, e.g. functions controlled by the rotation of a mouse with dual sensing arrangements, or of the nature of the input device, e.g. tap gestures based on pressure sensed by a digitiser using a touch-screen or digitiser, e.g. input of commands through traced gestures
    • G06F3/04883Interaction techniques based on graphical user interfaces [GUI] using specific features provided by the input device, e.g. functions controlled by the rotation of a mouse with dual sensing arrangements, or of the nature of the input device, e.g. tap gestures based on pressure sensed by a digitiser using a touch-screen or digitiser, e.g. input of commands through traced gestures for inputting data by handwriting, e.g. gesture or text

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • General Engineering & Computer Science (AREA)
  • Databases & Information Systems (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Data Mining & Analysis (AREA)
  • Human Computer Interaction (AREA)
  • User Interface Of Digital Computer (AREA)

Abstract

The application relates to a page processing method, a page processing device, computer equipment, a storage medium and a page processing product. The method comprises the following steps: in the page container, displaying one page in a local page sequence adapted by the page container; responding to a switching operation triggered by a currently displayed page, and determining a page switching direction indicated by the switching operation; when a next page of the currently displayed page exists in the local page sequence along the ordering direction consistent with the page switching direction, switching to the next page for display in the page container; when the ordering direction consistent with the page switching direction in the local page sequence does not exist the next page of the currently displayed page, updating a batch of pages in the local page sequence into the next batch of pages in the page total sequence along the ordering direction through a network; and in the page container, switching to the first page in the sorting direction in the updated local page sequence for display. By adopting the method, the page processing efficiency can be improved.

Description

Page processing method, device, computer equipment, storage medium and product
Technical Field
The present disclosure relates to the field of computer technologies, and in particular, to a page processing method, apparatus, computer device, storage medium, and product.
Background
With the development of computer technology, the information presentation mode is more and more rich. In general, it is difficult for one page of a terminal to display excessive information, and when one page displays more information, the problems of inconvenient reading and information fatigue are caused, so that the terminal usually displays different information in a plurality of pages. The terminal can load a plurality of pages from the server, and display different pages through switching operation of a user.
However, when the terminal loads a plurality of pages, there is a problem that the loading speed is slow, and the page processing efficiency is low.
Disclosure of Invention
In view of the foregoing, it is desirable to provide a page processing method, apparatus, computer device, storage medium, and product that can improve page processing efficiency.
In a first aspect, the present application provides a page processing method. The method comprises the following steps:
displaying one page in a local page sequence adapted by the page container in the page container; in the local page sequence, a batch of pages are arranged in sequence; the pages in the local page sequence are part of continuous pages in the total page sequence, and the pages in the total page sequence are arranged in sequence;
Responding to a switching operation triggered by a currently displayed page, and determining a page switching direction indicated by the switching operation;
when the next page of the currently displayed page exists in the local page sequence along the ordering direction consistent with the page switching direction, switching to the next page for display in the page container;
when the sorting direction consistent with the page switching direction in the local page sequence does not exist the next page of the currently displayed page, updating the batch of pages in the local page sequence into the next batch of pages in the page total sequence along the sorting direction through a network; and in the page container, switching to the first page along the sorting direction in the updated local page sequence for display.
In a second aspect, the present application further provides a page processing apparatus. The device comprises:
the page display module is used for displaying one page in the local page sequence adapted to the page container in the page container; in the local page sequence, a batch of pages are arranged in sequence; the pages in the local page sequence are part of continuous pages in the total page sequence, and the pages in the total page sequence are arranged in sequence;
The switching triggering module is used for responding to the switching operation triggered by the currently displayed page and determining the page switching direction indicated by the switching operation;
the page switching module is used for switching to the next page for display in the page container when the next page of the currently displayed page exists in the sequence of the local pages along the ordering direction consistent with the page switching direction;
the page sequence switching module is used for updating the batch of pages in the local page sequence into the next batch of pages in the page total sequence along the sorting direction through a network when the sorting direction consistent with the page switching direction does not exist in the local page sequence; and in the page container, switching to the first page along the sorting direction in the updated local page sequence for display.
In a third aspect, the present application also provides a computer device. The computer device comprises a memory storing a computer program and a processor which when executing the computer program performs the steps of:
Displaying one page in a local page sequence adapted by the page container in the page container; in the local page sequence, a batch of pages are arranged in sequence; the pages in the local page sequence are part of continuous pages in the total page sequence, and the pages in the total page sequence are arranged in sequence;
responding to a switching operation triggered by a currently displayed page, and determining a page switching direction indicated by the switching operation;
when the next page of the currently displayed page exists in the local page sequence along the ordering direction consistent with the page switching direction, switching to the next page for display in the page container;
when the sorting direction consistent with the page switching direction in the local page sequence does not exist the next page of the currently displayed page, updating the batch of pages in the local page sequence into the next batch of pages in the page total sequence along the sorting direction through a network; and in the page container, switching to the first page along the sorting direction in the updated local page sequence for display.
In a fourth aspect, the present application also provides a computer-readable storage medium. The computer readable storage medium having stored thereon a computer program which when executed by a processor performs the steps of:
displaying one page in a local page sequence adapted by the page container in the page container; in the local page sequence, a batch of pages are arranged in sequence; the pages in the local page sequence are part of continuous pages in the total page sequence, and the pages in the total page sequence are arranged in sequence;
responding to a switching operation triggered by a currently displayed page, and determining a page switching direction indicated by the switching operation;
when the next page of the currently displayed page exists in the local page sequence along the ordering direction consistent with the page switching direction, switching to the next page for display in the page container;
when the sorting direction consistent with the page switching direction in the local page sequence does not exist the next page of the currently displayed page, updating the batch of pages in the local page sequence into the next batch of pages in the page total sequence along the sorting direction through a network; and in the page container, switching to the first page along the sorting direction in the updated local page sequence for display.
In a fifth aspect, the present application also provides a computer program product. The computer program product comprises a computer program which, when executed by a processor, implements the steps of:
displaying one page in a local page sequence adapted by the page container in the page container; in the local page sequence, a batch of pages are arranged in sequence; the pages in the local page sequence are part of continuous pages in the total page sequence, and the pages in the total page sequence are arranged in sequence;
responding to a switching operation triggered by a currently displayed page, and determining a page switching direction indicated by the switching operation;
when the next page of the currently displayed page exists in the local page sequence along the ordering direction consistent with the page switching direction, switching to the next page for display in the page container;
when the sorting direction consistent with the page switching direction in the local page sequence does not exist the next page of the currently displayed page, updating the batch of pages in the local page sequence into the next batch of pages in the page total sequence along the sorting direction through a network; and in the page container, switching to the first page along the sorting direction in the updated local page sequence for display.
According to the page processing method, the device, the computer equipment, the storage medium and the product, after the switching operation is triggered on the page currently displayed in the page container, when the next page of the page currently displayed exists in the local page sequence along the ordering direction, the next page is switched to be displayed in the page container, the next page can be acquired locally when the switching operation is triggered by a user, the rapid switching is realized on the page in the local page sequence, and the page display efficiency is improved; and when the local page sequence does not have the next page of the currently displayed pages along the ordering direction, updating a batch of pages in the local page sequence into the next batch of pages along the ordering direction in the total page sequence through a network, so that when the pages are displayed each time, all the pages in the total page sequence do not need to be acquired at one time, but the pages are acquired in batches and the local page sequence is updated, thereby avoiding loading excessive pages at one time and improving the page processing efficiency.
Drawings
FIG. 1 is an application environment diagram of a page processing method in one embodiment;
FIG. 2 is a flow diagram of a method of page processing in one embodiment;
FIG. 3 is a flow diagram illustrating steps of a page processing core in one embodiment;
FIG. 4 is a schematic diagram of module connections in one embodiment;
FIG. 5 is a block diagram of a page processing apparatus in one embodiment;
fig. 6 is an internal structural diagram of a computer device in one embodiment.
Detailed Description
In order to make the objects, technical solutions and advantages of the present application more apparent, the present application will be further described in detail with reference to the accompanying drawings and examples. It should be understood that the specific embodiments described herein are for purposes of illustration only and are not intended to limit the present application.
The page processing method provided by the embodiment of the application can be applied to an application environment shown in fig. 1. Wherein the terminal 102 communicates with the server 104 via a network. The data storage system may store data that the server 104 needs to process. The data storage system may be integrated on the server 104 or may be located on the cloud or other servers. The terminal 102 may display a page container, in which one page in a local page sequence adapted to the page container is displayed, and after a switching operation triggered for a currently displayed page, may switch to a next page in the page container for display, or acquire a next batch of pages in the local page sequence from the server 104 through a network and update, and display a page in the next batch of pages in the page container. The terminal 102 may be, among other things, a desktop computer, a notebook computer, a smart phone, a tablet computer, and a portable wearable device. The portable wearable device may be a smart watch, a headset, or the like. The server 104 may be implemented as a stand-alone server or as a server cluster of multiple servers.
In one embodiment, as shown in fig. 2, a page processing method is provided, and this embodiment is described by taking the application of the method to the terminal 102 in fig. 1 as an example, the method includes the following steps:
step 202, in a page container, displaying one page in a local page sequence adapted to the page container; in the local page sequence, a batch of pages are arranged in sequence; the pages in the local page sequence are a part of continuous pages in the total sequence of pages, and the pages in the total sequence of pages are arranged in order.
Wherein the page container is a container for accommodating pages. The page container may specifically be one of a sequence of local pages for accommodating page container adaptations. The page container may specifically be an interface, may be an area defined in the interface, or may be a window.
The local page sequence is a page sequence stored in a local cache and adapted to the page container. The page container is adapted to the local page sequence, meaning that the page container is associated with the local page sequence such that the page container is capable of displaying one of the local page sequence. One page in the local page sequence displayed in the page container may be any page in the local page sequence, and specifically may be the first page, the last page or other pages in the middle. The group of pages in the local page sequence is all the current pages of the local page sequence. The batch of pages in the local page sequence may be obtained from a local cache or may be obtained through a network. The total sequence of pages is a sequence formed by a plurality of pages for batch updates to the local page sequence. For example, the total sequence of pages may include 100 pages in a sequential order, each page presenting a choice question, and the collection of pages in the local sequence of pages may be 10 consecutive pages of the 100 pages.
A page is a visual file used in a computer system to carry information. The page may be used to present information for viewing only, such as presenting articles, pictures, videos, or other information for viewing only by the user; the page may also be used to present interactable information, such as presenting options for user selection, text boxes for user input of content, and the like.
For example, when the page is used for presenting interactable information, the page may specifically display one or more questions in a questionnaire or test question, each of which may include a question stem portion and an answer portion, and the answer portion may be a plurality of candidates for selection by a user or a text box for the user to input an answer. In the banking field, when a user seeks advice to select a financial risk product to a banking person, the banking person may provide a risk tolerance assessment questionnaire to the user to assess the user's risk tolerance through answers that the user feeds back to the risk tolerance assessment questionnaire, where topics in the risk tolerance assessment questionnaire may be presented in a page. In other scenarios, for example, a bank application may offer an answer function to provide a user with financial test questions for verifying the level of financial knowledge, where the questions in the financial test questions may be presented in a page.
In one embodiment, the terminal may display a page container in the interface in response to a page display event, in which one page in a local page sequence that the page container adapts to is displayed. Wherein the page display event is an event that triggers the display of a page container and one page in the local page sequence. The page display event may be a manual trigger operation, for example, when a trigger operation is performed on an entry link corresponding to the total sequence of pages; or an automatic triggering event, for example, after the terminal is started at regular time, the terminal automatically displays a main interface of the browser, and automatically displays a page container and one page in the local page sequence in the main interface. When the total sequence of pages is all of the topics in the questionnaire, the entry links corresponding to the total sequence of pages may be the entry links of the questionnaire.
Step 204, in response to the switching operation triggered for the currently displayed page, determining the page switching direction indicated by the switching operation.
The switching operation is an operation of switching a currently displayed page. The switching operation may be a sliding operation, for example, an operation of sliding in an area where a currently displayed page is located, or an operation of sliding in an area where a page indicator corresponding to a page container is located; the switching operation may also be a click operation, such as a mouse click operation or a touch operation on a switching flag displayed in the page container. The page indicator is an element that indicates where in the local page sequence the currently displayed page in the page container is located. The switching mark is an element which can be switched according to the page switching direction corresponding to the switching mark after the mark is clicked.
The page switching direction is a direction indicated by the switching operation. When the switching operation is a sliding operation, the page switching direction may be two directions of sliding in the horizontal direction, for example, a direction of sliding to the left or a direction of sliding to the right; when the switching operation is a click operation, the page switching direction may be two directions that are switched in the horizontal direction, for example, a direction that is switched to the left or a direction that is switched to the right.
In one embodiment, the switching operation may be a sliding operation. In this embodiment, the terminal may obtain the sliding start point and the sliding end point of the switching operation in response to the triggered switching operation for the currently displayed page, and determine the page switching direction indicated by the switching operation according to the sliding start point and the sliding end point. Wherein the slide start point is a start touch point of the slide operation. The slide end point is the end touch point of the slide operation. The page switching direction may specifically be a direction in which the slide start point points to the slide end point. For example, when the slide start point points in a direction in which the slide end point is leftward, the page switching direction may be a direction of leftward slide.
In one embodiment, the switching operation may be a click operation. In this embodiment, the terminal may determine a switching identifier corresponding to the switching operation in response to a triggered switching operation for a currently displayed page, and determine a page switching direction indicated by the switching operation according to a direction indicated by the switching identifier. For example, the switch flag may be an arrow characterizing right, and the page switch direction may be the direction of the right switch.
In step 206, when there is a next page of the currently displayed page in the local page sequence along the ordering direction consistent with the page switching direction, the next page is switched to display in the page container.
Wherein, each page in the total sequence of pages can be respectively corresponding to different page sequence numbers. The ordering direction is the direction in which pages are ordered according to page sequence numbers. The ordering direction may be a direction ordered from small to large page numbers or a direction ordered from large to small page numbers. The developer can carry out consistency configuration on the page switching direction and the ordering direction, specifically, the left sliding direction and the ordering direction from small to large according to page sequence numbers are consistent, and the right sliding direction and the ordering direction from large to small according to page sequence numbers are consistent; for example, the page sequence number in the total sequence of pages may be from 1 to 100, and when the page switching direction is a direction sliding to the right, the ordering direction consistent with the page switching direction is a direction ordered from 100 to 1.
In one embodiment, when there is a next page of the currently displayed page in the local page sequence along the ordering direction consistent with the page switching direction, the next page is displayed as the current page after the currently displayed page is canceled from being displayed in the page container.
In one embodiment, the terminal may determine a last page in the local page sequence along a ranking direction consistent with the page switching direction, and in the case that the currently displayed page is not the last page, determine that in the local page sequence, there is a next page of the currently displayed page along the ranking direction consistent with the page switching direction.
In one embodiment, the terminal may determine a page sequence number range of the local page sequence, determine a page sequence number of the currently displayed page, determine a sequence number of a next page according to the page sequence number of the currently displayed page and a sorting direction consistent with the page switching direction, and determine that the next page of the currently displayed page exists in the local page sequence along the sorting direction consistent with the page switching direction when the page sequence number corresponding to the next page is within the page sequence number range. The page sequence number range is a range formed by page sequence numbers corresponding to two end pages of the local page sequence.
Step 208, when there is no next page of the currently displayed pages in the ordering direction consistent with the page switching direction in the local page sequence, updating a batch of pages in the local page sequence to be the next batch of pages in the page total sequence along the ordering direction through the network; and in the page container, switching to the first page in the sorting direction in the updated local page sequence for display.
The next batch of pages can be overlapped with the current batch of pages of the local page sequence, or can be closely adjacent to the current batch of pages of the local page sequence in the total page sequence.
In one embodiment, when the ordering direction consistent with the page switching direction in the local page sequence does not exist a next page of the currently displayed page, the terminal may acquire a next page of a batch of pages in the local page sequence along the ordering direction in the total page sequence from the server through the network, and update the next page of the batch of pages in the local page sequence to the next page acquired from the server.
In one embodiment, when in the local page sequence, the ordering direction consistent with the page switching direction does not exist next page of the currently displayed page, and in the local cache, there is no next page of a batch of pages in the local page sequence along the ordering direction in the total page sequence, the terminal may update, through the network, a batch of pages in the local page sequence to be next page in the total page sequence along the ordering direction.
In the page processing method, after the switching operation is triggered on the currently displayed page in the page container, when the local page sequence has the next page of the currently displayed page along the ordering direction, the next page is switched to be displayed in the page container, the next page can be acquired locally when the switching operation is triggered by a user, the rapid switching of the page in the local page sequence is realized, and the page display efficiency is improved; and when the local page sequence does not have the next page of the currently displayed pages along the ordering direction, updating a batch of pages in the local page sequence into the next batch of pages along the ordering direction in the total page sequence through a network, so that when the pages are displayed each time, all the pages in the total page sequence do not need to be acquired at one time, but the pages are acquired in batches and the local page sequence is updated, thereby avoiding loading excessive pages at one time and improving the page processing efficiency.
In one embodiment, the step of updating, in step 208, a batch of pages in the local page sequence to a next batch of pages in the total sequence of pages along the ordering direction over the network may include: determining a first page sequence number of a last page in the local page sequence along the ordering direction; the first page serial number represents the arrangement position of the last page in the page total sequence along the preset ordering direction; determining a second page sequence number of a first page in a next batch of pages to be updated to the local page sequence according to the first page sequence number; inquiring a preset number of pages along the ordering direction from the page corresponding to the second page sequence number in the total page sequence through a network; and when the preset number of pages are queried, determining the preset number of pages as the next batch of pages in the total sequence of the pages along the ordering direction.
The first page sequence number is the page sequence number of the last page in the sorting direction in the local page sequence. The preset sorting direction is a preset sorting direction, and specifically may be a direction of sorting from small to large according to page sequence numbers. For example, when the first page sequence number is 10, the first page sequence number characterizes the last page in the local page sequence along the sorting direction, and the 10 th bit in the direction of sorting from small to large in the total page sequence.
The second page sequence number is the page sequence number of the first page in the next batch of pages updated to the local page sequence. The second page sequence number may be the same as the first page sequence number, or may be the next page sequence number of the first page sequence number in the ordering direction in the total page sequence. For example, when the total sequence of pages is 100 pages formed by 100 questions of the risk tolerance assessment questionnaire in the banking field, the page sequence numbers are 1 to 100, a batch of pages in the local page sequence are pages with page sequence numbers 13 to 22, and the sorting direction is the sorting direction from big to small, the first page sequence number is 13, and the second page sequence number can be 13 or 12.
The preset number is a preset number. The preset number may be 5, 10 or others. The preset number may be configured by a developer, and in particular may be configured as a natural number that is not greater than a ratio between the total number of pages in the total sequence of pages and the preset multiple. Preset multiples such as 5, 8, 10 or others. For example, the total number of pages in the total sequence of pages is 100, the preset multiple is 10, and the ratio of the total number of pages to the preset multiple is 10, then the preset number may be 10.
In this embodiment, by determining the first page sequence number of the last page in the local page sequence along the sorting direction and determining the second page sequence number by the first page sequence number, and combining the preset number, the next batch of pages in the total page sequence, which specifically need to be updated to the local page sequence, can be determined quickly, and further, a batch of pages in the local page sequence can be updated to the next batch of pages, thereby improving the page processing efficiency.
In one embodiment, the above page processing method may further include the following steps: and when the number of the pages from the page corresponding to the second page sequence number to the last page along the ordering direction in the page total sequence is smaller than the preset number, determining the page from the page corresponding to the second page sequence number to the last page as the next batch of pages along the ordering direction in the page total sequence.
Wherein, last page is the page arranged at last bit along the ordering direction in the total sequence of pages. For example, when the total sequence of pages is 100 pages with page numbers of 1 to 100, the ordering direction is the direction of ordering from big to small according to the page numbers, and the last page is the page with page number of 1 in the total sequence of pages; when the preset number is 10 and the second page sequence number is 4, the number of pages from the page corresponding to the second page sequence number to the last page is only 4, and when the number is smaller than the preset number of 10, the pages from the page sequence numbers 1 to 4 are determined to be the next batch of pages in the total sequence of the pages along the ordering direction.
In this embodiment, when the page corresponding to the second page sequence number starts to the last page along the ordering direction in the total sequence of pages, the number of pages is smaller than the preset number, and the page from the page corresponding to the second page sequence number to the last page is determined as the next batch of pages along the ordering direction in the total sequence of pages, so that the next batch of pages can be accurately determined, error reporting is avoided, and page processing efficiency is improved.
In one embodiment, the step of querying, from the page corresponding to the second page sequence number in the total sequence of pages, a preset number of pages along the ordering direction through the network may include: determining a query interface corresponding to the sorting direction; the query interface is called to send a query request through a network, wherein the query request carries a second page sequence number and a preset number; the query request is used for requesting to query a preset number of pages along the ordering direction from the page corresponding to the second page sequence number in the total sequence of pages.
The query interface is a computer software interface for initiating a query request after being called. Different ordering directions may correspond to different query interfaces.
Specifically, when the sorting direction is the direction of sorting from small to large according to the page sequence number, the query interface corresponding to the sorting direction is used for querying the pages in the direction of sorting from small to large according to the page sequence number, and the query interface can be called as a first query interface.
When the ordering direction is the direction of ordering from big to small according to the page sequence number, the query interface corresponding to the ordering direction is used for querying the pages according to the direction of ordering from big to small according to the page sequence number, and the query interface can be called as a second query interface.
In this embodiment, different sorting directions correspond to different query interfaces, so that interface logic confusion can be avoided; and calling a query interface, sending a query request through a network, and reducing the service code coupling, so that the code maintenance resource is reduced when the query is performed from the page corresponding to the second page sequence number in the total sequence of the pages to query the preset number of pages along the ordering direction.
In one embodiment, the above page processing may further include the steps of: when the ordering direction consistent with the page switching direction in the local page sequence does not exist next page of the currently displayed page, and next page of a batch of pages in the local page sequence along the ordering direction in the page total sequence exists in the local cache, and the version number corresponding to the next page stored in the local cache is the same as the latest version number corresponding to the page total sequence stored in the server, updating the next page stored in the local cache with the batch of pages in the local page sequence.
The local cache is a storage space used for temporarily storing data locally by the terminal. The cache may be a storage space in a memory or a storage space in a hard disk. The version number is an identification number of the version and can characterize the iterative update state of the page sequence. The latest version number is a version number corresponding to a version whose version update time is closest to the current time.
And when the version number corresponding to the next batch of pages stored in the local cache is the same as the latest version number corresponding to the total sequence of the pages stored in the server, representing that the next batch of pages in the local cache are the pages of the latest version.
In this embodiment, the local cache may store a next batch of pages, so that when the local page sequence needs to be updated, the next batch of pages can be quickly acquired and updated into the local page sequence; and compared with the version number corresponding to the next batch of pages in the local cache and the latest version number corresponding to the total sequence of the pages in the server, the method can ensure that the next batch of pages in the local page sequence are updated to be the latest, and can ensure the accuracy of page display while improving the page processing efficiency.
In one embodiment, when the ordering direction consistent with the page switching direction in the local page sequence does not exist next page of the currently displayed page, and in the local cache, there is next page of a batch of pages in the local page sequence along the ordering direction in the page total sequence, and the version number corresponding to the next page stored in the local cache is different from the latest version number corresponding to the page total sequence stored in the server, updating the next page of the local page sequence into the next page of the page total sequence along the ordering direction through the network.
In one embodiment, each time a batch of pages in the local page sequence is updated to be the next batch of pages in the page total sequence along the ordering direction, the terminal can store the replaced batch of pages in the local cache until the storage space of the local cache reaches the upper limit of space, and then the pages stored in the local cache are deleted from the page with the earliest storage time in the local cache until the deletion stopping condition is reached, and the latest replaced batch of pages are continuously stored in the local cache. The condition for stopping deleting is that deleting the page stored in the local cache is stopped, and the ratio of the remaining storage space to the total storage space of the local cache after deleting the page is not less than a preset ratio value, for example, 70%, 50% or other.
In one embodiment, the above page processing may further include the steps of: responding to a data input operation triggered by a currently displayed page, and storing data input by the data input operation as input data corresponding to the currently displayed page into a local cache; after triggering the switching operation for the currently displayed page, when the ordering direction consistent with the page switching direction does not exist in the local page sequence, triggering a data submitting request, wherein the data submitting request is used for indicating input data corresponding to the page in the local page sequence to be stored in a local cache and writing the input data into a database.
The data input operation is an operation of inputting data in a page after triggering. A data commit request is a request to commit incoming data to a database.
In this embodiment, the data input by the data input operation is stored as the input data corresponding to the currently displayed page to the local cache, after the switching operation for the currently displayed page is triggered, when the next page of the currently displayed page does not exist in the local page sequence in the ordering direction consistent with the page switching direction, the data submitting request is triggered, and therefore writing of data into the database when each page inputs data can be avoided, frequent writing of data into the database is avoided, resource consumption required by the terminal and database connection consumption are reduced, and resources can be saved.
In one embodiment, in a specific application scenario, the above page processing method may be implemented based on a flow chart of the page processing core steps shown in fig. 3 and a module connection diagram shown in fig. 4, where the terminal may run a banking application, and the page container may be displayed in an interface of the banking application; the page processing method specifically comprises the following steps.
The terminal can respond to the page display event, call a query interface for querying pages in the direction of ordering from small to large according to the page sequence number, query 10 pages in the direction of ordering from small to large according to the page sequence number from the page sequence number 1 in the total sequence of pages through a network, store the queried pages with the page sequence number 1 to 10 in a local cache and then serve as a batch of pages of a local page sequence matched with a page container; and displaying a page container in an interface of the bank application program, and displaying a first page in a local page sequence adapted by the page container, namely, a page with the page sequence number of 1 in the page container.
The number of pages in the total sequence of pages can be 100, and the pages are arranged according to the sequence from 1 to 100, and each page can display a choice question. The content of the pages in the page total sequence can be specifically a risk bearing capacity assessment questionnaire and a financial level test question in the banking field. The style of the page container may be similar to a carousel view, and the user may slide the page container left and right in a horizontal direction.
The terminal may determine a page switching direction indicated by the switching operation in response to the switching operation triggered for the currently displayed page. The switching operation may be a sliding operation, and the page switching direction may be a direction of sliding left or a direction of sliding right. The sorting direction consistent with the direction of the left-hand sliding may be a direction sorted by page number from small to large, and may be referred to as a first sorting direction; the sort direction consistent with the direction of the rightward swipe may be a direction sorted by page order number from large to small, and may be referred to as a second sort direction.
And when the page switching direction is the direction sliding leftwards, determining the ordering direction as a first ordering direction, and when the next page of the currently displayed page exists along the first ordering direction in the local page sequence, namely the currently displayed page is not the last page along the first ordering direction in the local page sequence, switching to the next page in the page container for display. For example, when the local page sequence is a page with page numbers 13 to 22 and the page number of the current page is 21, sliding to the left, the page number of the next page is 22, and the page with page number 22 is displayed in the page container.
When the page switching direction is a direction sliding leftwards, and in the local page sequence, along the first sorting direction, the next page of the currently displayed page does not exist, namely, the currently displayed page is the last page in the local page sequence along the first sorting direction, then the first page sequence number of the last page in the local page sequence along the first sorting direction is determined, and the second page sequence number of the first page in the next batch of pages to be updated to the local page sequence is determined (the second page sequence number is the same as the first page sequence number); taking the second page serial numbers and the preset number as interface parameters, calling a first query interface to send a query request through a network, requesting to query the preset number of pages along the first ordering direction from pages corresponding to the second page serial numbers in the total page sequence; when the preset number of pages are queried, determining the preset number of pages as the next batch of pages in the total sequence of the pages along the first ordering direction, and updating the next batch of pages to a local page sequence; and in the page container, switching to the first page along the first ordering direction in the updated local page sequence for display.
For example, when the local page sequence is the pages with page numbers 4 to 13 and the page switching direction is the direction of sliding to the left, the first page number is 13, the second page number is 13 (interface parameter no=13), and if the preset number is 10 (interface parameter pagesize=10), the first query interface may query the pages with page numbers 13 to 22 as the next batch of pages along the first sorting direction.
When the page switching direction is the direction of rightward sliding, determining the ordering direction as a second ordering direction (the direction of ordering from large to small according to the page sequence number), and when the next page of the currently displayed page exists in the local page sequence along the second ordering direction, namely the currently displayed page is not the last page in the local page sequence along the second ordering direction, switching to the next page in the page container for displaying. For example, when the local page sequence is a page with page numbers 13 to 22 and the page number of the current page is 21, sliding to the right, the page number of the next page is 20, and the page with page number 20 is displayed in the page container.
When the page switching direction is a direction sliding to the right and in the local page sequence, along the second sorting direction, there is no next page of the currently displayed page, i.e. the currently displayed page is the last page in the local page sequence along the second sorting direction, determining the first page sequence number of the last page in the local page sequence along the second sorting direction, and determining the second page sequence number of the first page in the next batch of pages to be updated to the local page sequence (so that the second page sequence number is the same as the first page sequence number); taking the second page serial numbers and the preset number as interface parameters, calling a second query interface to send a query request through a network, requesting to query the preset number of pages along a second ordering direction from pages corresponding to the second page serial numbers in the total page sequence; when the preset number of pages are queried, determining the preset number of pages as the next batch of pages along the second ordering direction in the total sequence of the pages, and updating the next batch of pages to a local page sequence; and in the page container, switching to the first page along the second ordering direction in the updated local page sequence for display.
For example, when the local page sequence is the pages with page numbers 13 to 22 and the page switching direction is the direction of sliding to the right, the first page number is 13, the second page number is 13 (interface parameter no=13), and if the preset number is 10 (interface parameter pagesize=10), the first query interface may query the pages with page numbers 4 to 13 as the next batch of pages along the second sorting direction.
It should be understood that, although the steps in the flowcharts related to the embodiments described above are sequentially shown as indicated by arrows, these steps are not necessarily sequentially performed in the order indicated by the arrows. The steps are not strictly limited to the order of execution unless explicitly recited herein, and the steps may be executed in other orders. Moreover, at least some of the steps in the flowcharts described in the above embodiments may include a plurality of steps or a plurality of stages, which are not necessarily performed at the same time, but may be performed at different times, and the order of the steps or stages is not necessarily performed sequentially, but may be performed alternately or alternately with at least some of the other steps or stages.
Based on the same inventive concept, the embodiment of the application also provides a page processing device for realizing the above-mentioned page processing method. The implementation of the solution provided by the device is similar to the implementation described in the above method, so the specific limitation in one or more embodiments of the page processing device provided below may refer to the limitation of the page processing method described above, and will not be repeated here.
In one embodiment, as shown in fig. 5, there is provided a page processing apparatus 500, comprising: a page display module 510, a switch trigger module 520, a page switch module 530, and a page sequence switch module 540, wherein:
a page display module 510, configured to display, in a page container, one page in a local page sequence adapted to the page container; in the local page sequence, a batch of pages are arranged in sequence; the pages in the local page sequence are part of continuous pages in the total page sequence, and the pages in the total page sequence are arranged in sequence;
a switching trigger module 520, configured to determine a page switching direction indicated by a switching operation in response to a switching operation triggered for a currently displayed page;
The page switching module 530 is configured to switch to a next page for display in the page container when there is a next page of the currently displayed page in the local page sequence along the ordering direction consistent with the page switching direction;
the page sequence switching module 540 is configured to update, when there is no next page of the currently displayed pages in the local page sequence in the ordering direction consistent with the page switching direction, a batch of pages in the local page sequence to a next batch of pages in the page total sequence along the ordering direction through the network; and in the page container, switching to the first page in the sorting direction in the updated local page sequence for display.
In one embodiment, the page sequence switching module 540 is further configured to determine a first page sequence number of a last page in the local page sequence along the ordering direction; the first page serial number represents the arrangement position of the last page in the page total sequence along the preset ordering direction; determining a second page sequence number of a first page in a next batch of pages to be updated to the local page sequence according to the first page sequence number; inquiring a preset number of pages along the ordering direction from the page corresponding to the second page sequence number in the total page sequence through a network; and when the preset number of pages are queried, determining the preset number of pages as the next batch of pages in the total sequence of the pages along the ordering direction.
In one embodiment, the page sequence switching module 540 is further configured to determine, when the number of pages from the page corresponding to the second page sequence number to the last page in the sorting direction in the total page sequence is smaller than the preset number, the page from the page corresponding to the second page sequence number to the last page as the next batch of pages in the total page sequence in the sorting direction.
In one embodiment, the page sequence switching module 540 is further configured to determine a query interface corresponding to the ranking direction; the query interface is called to send a query request through a network, wherein the query request carries a second page sequence number and a preset number; the query request is used for requesting to query a preset number of pages along the ordering direction from the page corresponding to the second page sequence number in the total sequence of pages.
In one embodiment, the page sequence switching module 540 is further configured to, when in the local page sequence, the ordering direction consistent with the page switching direction does not exist a next page of the currently displayed page, and in the local cache, there is a next page of a batch of pages in the local page sequence along the ordering direction in the page total sequence, and the version number corresponding to the next page stored in the local cache is the same as the latest version number corresponding to the page total sequence stored in the server, update the next page stored in the local cache with a batch of pages in the local page sequence.
In one embodiment, the above page processing apparatus further includes an input data management module, where the input data management module is configured to respond to a data input operation triggered for a currently displayed page, and store data input by the data input operation as input data corresponding to the currently displayed page to the local cache; after triggering the switching operation for the currently displayed page, when the ordering direction consistent with the page switching direction does not exist in the local page sequence, triggering a data submitting request, wherein the data submitting request is used for indicating input data corresponding to the page in the local page sequence to be stored in a local cache and writing the input data into a database.
The respective modules in the above-described page processing apparatus may be implemented in whole or in part by software, hardware, and combinations thereof. The above modules may be embedded in hardware or may be independent of a processor in the computer device, or may be stored in software in a memory in the computer device, so that the processor may call and execute operations corresponding to the above modules.
In one embodiment, a computer device is provided, which may be a terminal, and the internal structure of which may be as shown in fig. 6. The computer device includes a processor, a memory, an input/output interface, a communication interface, a display unit, and an input means. The processor, the memory and the input/output interface are connected through a system bus, and the communication interface, the display unit and the input device are connected to the system bus through the input/output interface. Wherein the processor of the computer device is configured to provide computing and control capabilities. The memory of the computer device includes a non-volatile storage medium and an internal memory. The non-volatile storage medium stores an operating system and a computer program. The internal memory provides an environment for the operation of the operating system and computer programs in the non-volatile storage media. The input/output interface of the computer device is used to exchange information between the processor and the external device. The communication interface of the computer device is used for carrying out wired or wireless communication with an external terminal, and the wireless mode can be realized through WIFI, a mobile cellular network, NFC (near field communication) or other technologies. The computer program is executed by a processor to implement a page processing method. The display unit of the computer equipment is used for forming a visual picture, and can be a display screen, a projection device or a virtual reality imaging device, wherein the display screen can be a liquid crystal display screen or an electronic ink display screen, the input device of the computer equipment can be a touch layer covered on the display screen, can also be a key, a track ball or a touch pad arranged on a shell of the computer equipment, and can also be an external keyboard, a touch pad or a mouse and the like.
It will be appreciated by those skilled in the art that the structure shown in fig. 6 is merely a block diagram of some of the structures associated with the present application and is not limiting of the computer device to which the present application may be applied, and that a particular computer device may include more or fewer components than shown, or may combine certain components, or have a different arrangement of components.
In an embodiment, there is also provided a computer device comprising a memory and a processor, the memory having stored therein a computer program, the processor implementing the steps of the method embodiments described above when the computer program is executed.
In one embodiment, a computer-readable storage medium is provided, on which a computer program is stored which, when executed by a processor, carries out the steps of the method embodiments described above.
In an embodiment, a computer program product is provided, comprising a computer program which, when executed by a processor, implements the steps of the method embodiments described above.
It should be noted that, the user information (including, but not limited to, user equipment information, user personal information, etc.) and the data (including, but not limited to, data for analysis, stored data, presented data, etc.) referred to in the present application are information and data authorized by the user or sufficiently authorized by each party, and the collection, use and processing of the related data are required to comply with the related laws and regulations and standards of the related countries and regions.
Those skilled in the art will appreciate that implementing all or part of the above described methods may be accomplished by way of a computer program stored on a non-transitory computer readable storage medium, which when executed, may comprise the steps of the embodiments of the methods described above. Any reference to memory, database, or other medium used in the various embodiments provided herein may include at least one of non-volatile and volatile memory. The nonvolatile Memory may include Read-Only Memory (ROM), magnetic tape, floppy disk, flash Memory, optical Memory, high density embedded nonvolatile Memory, resistive random access Memory (ReRAM), magnetic random access Memory (Magnetoresistive Random Access Memory, MRAM), ferroelectric Memory (Ferroelectric Random Access Memory, FRAM), phase change Memory (Phase Change Memory, PCM), graphene Memory, and the like. Volatile memory can include random access memory (Random Access Memory, RAM) or external cache memory, and the like. By way of illustration, and not limitation, RAM can be in the form of a variety of forms, such as static random access memory (Static Random Access Memory, SRAM) or dynamic random access memory (Dynamic Random Access Memory, DRAM), and the like. The databases referred to in the various embodiments provided herein may include at least one of relational databases and non-relational databases. The non-relational database may include, but is not limited to, a blockchain-based distributed database, and the like. The processors referred to in the embodiments provided herein may be general purpose processors, central processing units, graphics processors, digital signal processors, programmable logic units, quantum computing-based data processing logic units, etc., without being limited thereto.
The technical features of the above embodiments may be arbitrarily combined, and all possible combinations of the technical features in the above embodiments are not described for brevity of description, however, as long as there is no contradiction between the combinations of the technical features, they should be considered as the scope of the description.
The above examples only represent a few embodiments of the present application, which are described in more detail and are not to be construed as limiting the scope of the present application. It should be noted that it would be apparent to those skilled in the art that various modifications and improvements could be made without departing from the spirit of the present application, which would be within the scope of the present application. Accordingly, the scope of protection of the present application shall be subject to the appended claims.

Claims (10)

1. A method of page processing, the method comprising:
displaying one page in a local page sequence adapted by the page container in the page container; in the local page sequence, a batch of pages are arranged in sequence; the pages in the local page sequence are part of continuous pages in the total page sequence, and the pages in the total page sequence are arranged in sequence;
Responding to a switching operation triggered by a currently displayed page, and determining a page switching direction indicated by the switching operation;
when the next page of the currently displayed page exists in the local page sequence along the ordering direction consistent with the page switching direction, switching to the next page for display in the page container;
when the sorting direction consistent with the page switching direction in the local page sequence does not exist the next page of the currently displayed page, updating the batch of pages in the local page sequence into the next batch of pages in the page total sequence along the sorting direction through a network; and in the page container, switching to the first page along the sorting direction in the updated local page sequence for display.
2. The method of claim 1, wherein updating, via the network, the set of pages in the local page sequence to a next set of pages in the total sequence of pages along the ordering direction comprises:
determining a first page sequence number of a last page in the local page sequence along the sorting direction; the first page sequence number represents the arrangement position of the last page in the page total sequence along the preset ordering direction;
Determining a second page sequence number of a first page in a next batch of pages to be updated to the local page sequence according to the first page sequence number;
starting from pages corresponding to the second page sequence number in the page total sequence through a network, inquiring a preset number of pages along the ordering direction;
and when the preset number of pages are queried, determining the preset number of pages as the next batch of pages in the total sequence of the pages along the sorting direction.
3. The method according to claim 2, wherein the method further comprises:
when the page number corresponding to the second page sequence number in the total page sequence is started to the last page along the sorting direction, if the page number is smaller than the preset number
And determining the page from the page corresponding to the second page sequence number to the last page as the next batch of pages in the total page sequence along the ordering direction.
4. The method according to claim 2, wherein the querying, through the network, a preset number of pages along the sorting direction from the page corresponding to the second page sequence number in the total sequence of pages includes:
Determining a query interface corresponding to the sorting direction;
invoking the query interface to send a query request through a network, wherein the query request carries the second page sequence number and the preset number;
the query request is used for requesting to query the preset number of pages along the ordering direction from the page corresponding to the second page sequence number in the page total sequence.
5. The method according to claim 1, wherein the method further comprises:
and when the sorting direction consistent with the page switching direction in the local page sequence does not exist next page of the currently displayed page, and in the local cache, next page of the batch of pages in the local page sequence along the sorting direction in the page total sequence exists, and the version number corresponding to the next page stored in the local cache is the same as the latest version number corresponding to the page total sequence stored in the server, updating the batch of pages in the local page sequence into the next page stored in the local cache.
6. The method according to any one of claims 1 to 5, further comprising:
Responding to a data input operation triggered by a currently displayed page, and storing data input by the data input operation as input data corresponding to the currently displayed page into a local cache;
after triggering the switching operation for the currently displayed page, when the ordering direction consistent with the page switching direction does not exist in the local page sequence, triggering a data submitting request, wherein the data submitting request is used for indicating input data which is stored in the local cache and corresponds to the page in the local page sequence, and writing the input data into a database.
7. A page processing apparatus, the apparatus comprising:
the page display module is used for displaying one page in the local page sequence adapted to the page container in the page container; in the local page sequence, a batch of pages are arranged in sequence; the pages in the local page sequence are part of continuous pages in the total page sequence, and the pages in the total page sequence are arranged in sequence;
the switching triggering module is used for responding to the switching operation triggered by the currently displayed page and determining the page switching direction indicated by the switching operation;
The page switching module is used for switching to the next page for display in the page container when the next page of the currently displayed page exists in the sequence of the local pages along the ordering direction consistent with the page switching direction;
the page sequence switching module is used for updating the batch of pages in the local page sequence into the next batch of pages in the page total sequence along the sorting direction through a network when the sorting direction consistent with the page switching direction does not exist in the local page sequence; and in the page container, switching to the first page along the sorting direction in the updated local page sequence for display.
8. A computer device comprising a memory and a processor, the memory storing a computer program, characterized in that the processor implements the steps of the method of any of claims 1 to 6 when the computer program is executed.
9. A computer readable storage medium, on which a computer program is stored, characterized in that the computer program, when being executed by a processor, implements the steps of the method of any of claims 1 to 6.
10. A computer program product comprising a computer program, characterized in that the computer program, when being executed by a processor, implements the steps of the method of any of claims 1 to 6.
CN202311099137.2A 2023-08-29 2023-08-29 Page processing method, device, computer equipment, storage medium and product Pending CN117390313A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202311099137.2A CN117390313A (en) 2023-08-29 2023-08-29 Page processing method, device, computer equipment, storage medium and product

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202311099137.2A CN117390313A (en) 2023-08-29 2023-08-29 Page processing method, device, computer equipment, storage medium and product

Publications (1)

Publication Number Publication Date
CN117390313A true CN117390313A (en) 2024-01-12

Family

ID=89469031

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202311099137.2A Pending CN117390313A (en) 2023-08-29 2023-08-29 Page processing method, device, computer equipment, storage medium and product

Country Status (1)

Country Link
CN (1) CN117390313A (en)

Similar Documents

Publication Publication Date Title
CN106528587B (en) Page display method and device in composite webpage system
CN117390313A (en) Page processing method, device, computer equipment, storage medium and product
CN115168668A (en) Information recommendation method and device, computer equipment and storage medium
CN111221817B (en) Service information data storage method, device, computer equipment and storage medium
CN117290302B (en) Directory separation method, apparatus, computer device and storage medium
CN115221222A (en) Receipt processing method and device, computer equipment and storage medium
CN117435651A (en) Test data processing method, device, computer equipment and storage medium
CN117435589A (en) Data transfer method, device, computer equipment and storage medium
CN117350499A (en) Flow chart verification method, device, apparatus, storage medium and program product
CN117130708A (en) Application program language switching method, device, computer equipment and storage medium
CN114610688A (en) Log aggregation method and device, computer equipment and storage medium
CN118229251A (en) Mail retrieval display method, device, computer equipment and storage medium
CN114201464A (en) Data display method and device, computer equipment and storage medium
CN114820105A (en) Product display method and device, computer equipment and storage medium
CN116661648A (en) Application recommendation method, apparatus, computer device, storage medium and computer program product
CN118245160A (en) Tab label updating method, device, computer equipment and storage medium
CN117033451A (en) Searching method, searching device, computer equipment and storage medium
CN118170867A (en) Service content acquisition method, device, computer equipment, medium and program product
CN117112103A (en) Component information display method, device, computer equipment and storage medium
CN117612192A (en) Electronic drawing information identification method, system, electronic equipment and storage medium
CN116775186A (en) Page data processing method and device, computer equipment and storage medium
CN117455386A (en) Resource auditing method and device, computer equipment and storage medium thereof
CN116304407A (en) Page rendering method, device, computer equipment and storage medium
CN116719892A (en) Data display method, device, computer equipment and storage medium
CN117193924A (en) Page display method and device and computer equipment

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