A report generation method, device, system, equipment and medium
By detecting data integrity on the client and providing missing data on the server according to the load status, dynamically generate reports, the problems of resource waste, waiting time and user experience in the existing report generation methods are solved, and efficient and user-friendly report generation is achieved.
Patent Information
- Application Number
- CN202210697391.1
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2022-06-20
- Publication Date
- 2025-04-25
- Estimated Expiration
- 2042-06-20
AI Technical Summary
Existing report generation methods may lead to waste of resources, long waiting time, missing necessary data, slow report generation speed and stuttering pages, resulting in poor user experience.
The client detects whether all the data to be displayed are stored. If not, a message acquisition request is sent to the server. The server feedbacks the report or target data to be displayed corresponding to all the data to be displayed based on the current load status and requests. The client generates and provides reports based on the received data.
By dynamically generating reports and allocating calculation pressure, resource waste and waiting time are avoided, and data integrity and user experience are improved.
Smart Images

Figure CN115081413B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of computer technology, and in particular to a report generation method, device, system, equipment and medium. Background Art
[0002] With the rapid development of the Internet, online users are increasing. Various data information can be presented to users in the form of reports through electronic devices, so that users can grasp the data information intuitively and quickly.
[0003] In the related art, the commonly used report generation method is that each client sends a report generation request to the server, and then the server generates a report based on the data, or each client generates a report based on the data by itself. The defect of the report generation method in which the server generates a report based on the data is that: it is possible that all the data is already on the client, but the data still needs to be transmitted back to the server before the report can be generated, and the back and forth transmission of data causes a waste of resources; when the server is under high load, it cannot respond to the report generation request in time, and there will be an extremely long waiting time, which may affect other user operations. The defect of the report generation method in which each client generates a report based on the data by itself is that: the client's data is incomplete and the necessary data for generating the report is missing; the client performance is poor, which may cause the report generation speed to be slow, and cause the page to freeze, resulting in a poor experience. Summary of the invention
[0004] The present invention provides a report generation method, apparatus, system, device and medium to solve the problem that the report generation method in the related art may cause waste of resources, excessively long waiting time, or lack of necessary data for generating reports, slow report generation speed, and cause page freezes and poor experience.
[0005] According to one aspect of the present invention, a report generation method is provided, which is applied to a client and includes:
[0006] Obtaining a data identifier of at least one item of data to be displayed input by a user, and detecting whether all the data to be displayed are stored in the client according to the data identifier of each item of data to be displayed;
[0007] If the target data to be displayed is not stored, an information acquisition request is sent to the server, so that the server feeds back a report corresponding to all the data to be displayed or the target data to be displayed according to the current load state of the server and the information acquisition request; wherein the information acquisition request carries the data identifier of the target data to be displayed and the stored data to be displayed;
[0008] If a report corresponding to all the data to be displayed is received, providing the report to the user;
[0009] If the target data to be displayed is received, the target data to be displayed and the stored data to be displayed are merged into all the data to be displayed, a report is generated according to all the data to be displayed, and the report is provided to the user.
[0010] According to another aspect of the present invention, a report generation method is provided, which is applied to a server and includes:
[0011] Receiving an information acquisition request sent by a client; wherein the information acquisition request carries a data identifier of target data to be displayed and stored data to be displayed; the target data to be displayed is data to be displayed that is not stored in the client;
[0012] According to the current load status of the server and the information acquisition request, a report corresponding to all the data to be displayed or the target data to be displayed is fed back to the client.
[0013] According to another aspect of the present invention, there is provided a report generation device, which is configured in a client and includes:
[0014] A data detection module, used to obtain a data identifier of at least one item of data to be displayed input by a user, and detect whether all the data to be displayed are stored in the client according to the data identifier of each item of data to be displayed;
[0015] A request sending module, used for sending an information acquisition request to a server if the target data to be displayed is not stored, so that the server feeds back a report corresponding to all the data to be displayed or the target data to be displayed according to the current load state of the server and the information acquisition request; wherein the information acquisition request carries the data identifier of the target data to be displayed and the stored data to be displayed;
[0016] A report receiving module, configured to provide the report to the user if a report corresponding to all the data to be displayed is received;
[0017] The data receiving module is used for merging the target data to be displayed and the stored data to be displayed into all the data to be displayed if the target data to be displayed is received, generating a report according to all the data to be displayed, and providing the report to the user.
[0018] According to another aspect of the present invention, there is provided a report generation device, which is configured in a server and includes:
[0019] A request receiving module, used to receive an information acquisition request sent by a client; wherein the information acquisition request carries a data identifier of target data to be displayed and stored data to be displayed; the target data to be displayed is data to be displayed that is not stored in the client;
[0020] The information feedback module is used to feed back the report corresponding to all the data to be displayed or the target data to be displayed to the client according to the current load status of the server and the information acquisition request.
[0021] According to another aspect of the present invention, there is provided a report generation system, comprising:
[0022] A client, and a server corresponding to the client;
[0023] Wherein, the client is used to obtain the data identification of at least one item of data to be displayed input by the user, and detect whether all the data to be displayed are stored in the client according to the data identification of each data to be displayed; if the target data to be displayed is not stored, an information acquisition request is sent to the server, so that the server feeds back a report corresponding to all the data to be displayed or the target data to be displayed according to the current load state of the server and the information acquisition request; wherein the information acquisition request carries the data identification of the target data to be displayed and the stored data to be displayed; if a report corresponding to all the data to be displayed is received, the report is provided to the user; if the target data to be displayed is received, the target data to be displayed and the stored data to be displayed are merged into all the data to be displayed, a report is generated according to all the data to be displayed, and the report is provided to the user;
[0024] The server is used to receive an information acquisition request sent by the client; wherein the information acquisition request carries a data identifier of target data to be displayed and stored data to be displayed; the target data to be displayed is data to be displayed that is not stored in the client; and according to the current load status of the server and the information acquisition request, a report corresponding to all data to be displayed or the target data to be displayed is fed back to the client.
[0025] According to another aspect of the present invention, an electronic device is provided, the electronic device comprising:
[0026] at least one processor; and
[0027] a memory communicatively connected to the at least one processor; wherein,
[0028] The memory stores a computer program executable by the at least one processor, and the computer program is executed by the at least one processor so that the at least one processor can execute the report generation method described in any embodiment of the present invention.
[0029] According to another aspect of the present invention, a computer-readable storage medium is provided, wherein the computer-readable storage medium stores computer instructions, and the computer instructions are used to enable a processor to implement the report generation method described in any embodiment of the present invention when executed.
[0030] The technical solution of the embodiment of the present invention obtains the data identification of at least one item of data to be displayed input by the user, and detects whether all the data to be displayed are stored in the client according to the data identification of each data to be displayed; when the target data to be displayed is not stored, sends an information acquisition request to the server, so that the server feeds back a report corresponding to all the data to be displayed or the target data to be displayed according to the current load state of the server and the information acquisition request; then, when the report corresponding to all the data to be displayed is received, the report is provided to the user; when the target data to be displayed is received, the target data to be displayed and the stored data to be displayed are merged into all the data to be displayed, Generate a report based on all the data to be displayed and provide the report to the user, which solves the problem that the report generation method in the related art may cause waste of resources, excessively long waiting time, or lack of necessary data for generating reports, slow report generation speed, and cause page freezes and poor experience. It is found that when the client lacks data that needs to be displayed in the form of a report, the server can feed back the report or the missing data to the client according to the load status, so that the client can directly provide the report fed back by the server to the user, or generate a report based on the missing data and the stored data and provide it to the user, realizing dynamic generation according to the data missing situation of the client and the load status of the server. The system can generate reports and dynamically allocate the calculation pressure of generating reports, thereby avoiding the waste of resources caused by fixedly generating lists through the server or client, excessive waiting time, missing necessary data for generating reports, slow report generation speed, and page jamming, poor experience and other beneficial effects; when the client has complete data that needs to be displayed in the form of a report, the report can be directly generated through the client to avoid the waste of resources caused by transmitting data resources back and forth between the client and the server; the report can be conveniently generated through the report engine set in the client, and the report template can be stored through the report template server to reduce the data storage pressure of the server; when the client lacks data that needs to be displayed in the form of a report and the server is in a high-load state, the report can be generated through the client according to the missing data returned by the server; when the client lacks data that needs to be displayed in the form of a report and the server is in a low-load state, the report can be generated through the server, realizing dynamic generation of reports according to the data missing situation of the client and the load state of the server, and dynamically allocating the calculation pressure of generating reports, and can reduce the data processing pressure of the server through the client when the server is in a high-load state; the report can be conveniently generated through the report engine set in the server, and the report template can be stored through the report template server to reduce the data storage pressure of the server.
[0031] It should be understood that the contents described in this section are not intended to identify the key or important features of the embodiments of the present invention, nor are they intended to limit the scope of the present invention. Other features of the present invention will become easily understood through the following description. BRIEF DESCRIPTION OF THE DRAWINGS
[0032] In order to more clearly illustrate the technical solutions in the embodiments of the present invention, the following briefly introduces the drawings required for use in the description of the embodiments. Obviously, the drawings described below are only some embodiments of the present invention. For ordinary technicians in this field, other drawings can be obtained based on these drawings without creative work.
[0033] Figure 1 The present invention provides a flowchart of a report generation method according to the first embodiment of the present invention.
[0034] Figure 2 The present invention provides a flowchart of a report generation method according to the second embodiment of the present invention.
[0035] Figure 3A This is a flow chart of a report generation method provided in Embodiment 3 of the present invention.
[0036] Figure 3B A schematic diagram of a report generation process provided in Embodiment 3 of the present invention.
[0037] Figure 4 This is a structural diagram of a report generating device provided in Embodiment 4 of the present invention.
[0038] Figure 5 This is a structural diagram of a report generating device provided in Embodiment 5 of the present invention.
[0039] Figure 6 A structural diagram of a report generation system provided in Embodiment 6 of the present invention.
[0040] Figure 7 A schematic diagram of the structure of an electronic device for implementing the report generation method according to an embodiment of the present invention. DETAILED DESCRIPTION
[0041] In order to enable those skilled in the art to better understand the scheme of the present invention, the technical scheme in the embodiments of the present invention will be clearly and completely described below in conjunction with the drawings in the embodiments of the present invention. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work should fall within the scope of protection of the present invention.
[0042] It should be noted that the terms "target", "first", "second", etc. in the specification and claims of the present invention and the above-mentioned drawings are used to distinguish similar objects, and are not necessarily used to describe a specific order or sequence. It should be understood that the data used in this way can be interchanged where appropriate, so that the embodiments of the present invention described herein can be implemented in an order other than those illustrated or described herein. In addition, the terms "comprise", "include" and "have" and any variations thereof are intended to cover non-exclusive inclusions, for example, a process, method, system, product or device that includes a series of steps or units is not necessarily limited to those steps or units clearly listed, but may include other steps or units that are not clearly listed or inherent to these processes, methods, products or devices.
[0043] Embodiment 1
[0044] Figure 1 This is a flow chart of a report generation method provided in the first embodiment of the present invention. The embodiment of the present invention is applicable to the case where a client and a server dynamically generate corresponding reports according to a report generation request input by a user. The method can be executed by a report generation device provided in the embodiment of the present invention, which can be implemented in software and / or hardware and can generally be integrated in a client.
[0045] Optionally, the client is set in the user's terminal device to interact with the user and provide report services for the user. The server is a background server corresponding to the client, establishes a communication connection with the client, can exchange information with the client, and provide the client with corresponding data or reports.
[0046] like Figure 1 As shown, the method includes:
[0047] Step 101: obtaining a data identifier of at least one item of data to be displayed input by a user, and detecting whether all the data to be displayed are stored in the client according to the data identifier of each item of data to be displayed.
[0048] Optionally, the data to be displayed is data specified by a user that needs to be displayed in a report form. The data specified by a user that needs to be displayed in a report form may be specified business indicator data or specified performance indicator data.
[0049] Optionally, obtaining a data identifier of at least one item of data to be displayed input by a user includes: obtaining a data identifier of at least one item of data to be displayed input by a user through a report processing page.
[0050] Optionally, the report processing page is a page in the client for interacting with the user, obtaining various types of information related to the report input by the user, and displaying the generated report to the user. The user can enter at least one data identifier of the data to be displayed by filling in or selecting at least one data identifier of the data to be displayed in the report processing page. The data identifier is identification information used to distinguish different data. Different data corresponds to different data identifiers.
[0051] Optionally, detecting whether all the data to be displayed are stored in the client according to the data identifier of each data to be displayed includes: searching for the same data identifier as the data identifier of each data to be displayed among the data identifiers of each data stored in the local database of the client; if the same data identifier as the data identifier of each data to be displayed is found, determining that all the data to be displayed are stored in the client; if there is target data to be displayed with the same data identifier that cannot be found among the data to be displayed, determining that the target data to be displayed is not stored in the client. The target data to be displayed is the data to be displayed that is not stored in the client.
[0052] Optionally, the local database of the client can be used to store multiple data related to the client. The local database of the client stores each data and the data identifier of each data accordingly.
[0053] Optionally, for each item of data to be displayed: if a data identifier identical to the data identifier of the data to be displayed is found among the data identifiers of the data stored in the local database of the client, it indicates that the data to be displayed has been stored in the local database of the client, that is, the data to be displayed is stored in the client. If a data identifier identical to the data identifier of the data to be displayed is not found among the data identifiers of the data stored in the local database of the client, it indicates that the data to be displayed is not stored in the local database of the client, that is, the data to be displayed is not stored in the client.
[0054] Step 102: If the target data to be displayed is not stored, an information acquisition request is sent to the server, so that the server feeds back a report corresponding to all the data to be displayed or the target data to be displayed according to the current load state of the server and the information acquisition request.
[0055] The information acquisition request carries the data identifier of the target data to be displayed and the stored data to be displayed.
[0056] Optionally, the information acquisition request is used to request the server to feedback a report corresponding to all the data to be displayed or the target data to be displayed. The information acquisition request carries the data identifier of the target data to be displayed and the stored data to be displayed. The stored data to be displayed is the data to be displayed that has been stored in the client among the data to be displayed.
[0057] Optionally, if the target data to be displayed is not stored, the client sends an information acquisition request to the server. The server receives the information acquisition request sent by the client. Then, the server feeds back a report corresponding to all the data to be displayed or the target data to be displayed to the client according to the current load state of the server and the information acquisition request.
[0058] Optionally, the server feeds back a report corresponding to all the data to be displayed or the target data to be displayed to the client according to the current load state of the server and the information acquisition request, including: the server detects the current load state of the server; if the current load state is a low load state, the server obtains the target data to be displayed according to the data identifier of the target data to be displayed, merges the target data to be displayed and the stored data to be displayed into all the data to be displayed, generates a report corresponding to all the data to be displayed according to all the data to be displayed, and feeds back the report to the client; if the current load state is a high load state, the server obtains the target data to be displayed according to the data identifier of the target data to be displayed, and feeds back the target data to be displayed to the client.
[0059] Optionally, the current load state of the server is the load state of the server at the current moment. The current load state of the server is a high load state or a low load state. The current load state of the server is a high load state, indicating that there are many processes running on the server at the current moment, the load is high, and the information acquisition request may not be responded to in time, resulting in an excessively long waiting time. The current load state of the server is a low load state, indicating that there are few processes running on the server at the current moment, the load is low, and the information acquisition request can be responded to in time.
[0060] Optionally, the server may determine the current load status of the server based on indicator data related to the server load, such as the central processing unit (CPU) utilization rate of the server at the current moment and the number of requests being processed.
[0061] Optionally, detecting the current load state of the server includes: obtaining the CPU utilization of the server at the current moment, and determining whether the CPU utilization is greater than a preset CPU utilization threshold; if the number of request processing is greater than the preset CPU utilization threshold, determining that the current load state of the server is a high load state; if the CPU utilization is less than or equal to the preset CPU utilization threshold, determining that the current load state of the server is a low load state.
[0062] Optionally, if the current load state is a low load state, the server obtains the target data to be displayed according to the data identifier of the target data to be displayed, merges the target data to be displayed and the stored data to be displayed into all the data to be displayed, generates a report corresponding to all the data to be displayed based on all the data to be displayed, and feeds the report back to the client.
[0063] Optionally, a preset database in the server stores various data that can be viewed by the user. The preset database stores various data and data identifiers of various data in a corresponding manner. The server obtains the target data to be displayed according to the data identifier of the target data to be displayed, including: obtaining data with the same data identifier as the data identifier of the target data to be displayed in the preset database in the server. The data is the target data to be displayed.
[0064] Optionally, the target data to be displayed is data to be displayed that is not stored in the client among the data to be displayed. The stored data to be displayed is data to be displayed that is stored in the client among the data to be displayed. The target data to be displayed and the stored data to be displayed constitute all the data to be displayed. The server may merge the target data to be displayed and the stored data to be displayed into all the data to be displayed.
[0065] Optionally, the server generates a report corresponding to all the data to be displayed based on all the data to be displayed, including: the server sends all the data to be displayed to a report engine in the server, calls the report engine in the server to obtain a target report template corresponding to all the data to be displayed from a report template server, fills all the data to be displayed into the target report template, and generates a report corresponding to all the data to be displayed.
[0066] Optionally, the report engine in the server is an engine tool for generating reports written by developers and set in the server. The report engine can be a JavaScript (JS) engine for generating reports. The server can call the report engine in the server by sending all the data to be displayed to the report engine in the server. After receiving all the data to be displayed sent by the server, the report engine in the server obtains the target report template corresponding to all the data to be displayed from the report template server, fills all the data to be displayed into the target report template, and generates a report corresponding to the all the data to be displayed.
[0067] Optionally, the server sends all the data to be displayed to a report engine in the server, calls the report engine in the server, and performs the following operations through the report engine in the server: according to the data identifiers of all the data to be displayed and the data identifiers corresponding to the report templates stored in the report template server, obtain a target report template corresponding to all the data to be displayed from the report templates stored in the report template server; fill all the data to be displayed into the target report template, and generate a report corresponding to the all the data to be displayed.
[0068] Optionally, the report template server is a server for storing report templates. The report template server may be a content delivery network (Content Delivery Network, CDN) server.
[0069] Optionally, a report template server stores multiple report templates of different report types. A report template is a template for generating a report. A report template may include multiple report cells for filling in data to be displayed. Each report cell is provided with a corresponding data identifier. The data identifier corresponding to the report cell is a data identifier of the data to be displayed that can be filled in the report cell. According to the data identifier corresponding to each report cell in the report template, the data to be displayed that can be filled in each report cell is determined, and then each data to be displayed is filled in the corresponding report cell, thereby generating a report for displaying each data to be displayed.
[0070] Optionally, the data identifiers corresponding to all report cells of the report template are the data identifiers corresponding to the report template. The data identifiers corresponding to the report template are the data identifiers of the data to be displayed that can be filled into the report template for display.
[0071] Optionally, based on the data identifiers of all the data to be displayed and the data identifiers corresponding to each report template stored in the report template server, a target report template corresponding to all the data to be displayed is obtained from each report template stored in the report template server, including: among each report template stored in the report template server, querying the report template whose corresponding data identifier contains the data identifier of all the data to be displayed; and determining the queried report template as the target report template corresponding to all the data to be displayed.
[0072] The target report template corresponding to the all data to be displayed is a report template containing report cells for filling the all data to be displayed. The data identifier corresponding to the report template contains the data identifier of the all data to be displayed, indicating that all report cells of the report template contain report cells for filling the all data to be displayed. Each of the all data to be displayed is filled into the corresponding report cell in the target report template, thereby generating a report for displaying the all data to be displayed.
[0073] Optionally, all the data to be displayed are filled into the target report template, and the report corresponding to all the data to be displayed includes: performing the following operations for each data to be displayed among all the data to be displayed: in each report cell of the target report template, determining a target report cell whose data identifier corresponding to the report cell is the same as the data identifier of the data to be displayed; and filling the data to be displayed into the target report cell.
[0074] Optionally, if the current load state is a high load state, the server obtains the target data to be displayed according to the data identifier of the target data to be displayed, and feeds the target data to be displayed back to the client.
[0075] Step 103: If a report corresponding to all the data to be displayed is received, the report is provided to the user.
[0076] Optionally, the client receives a report corresponding to all the data to be displayed fed back by the server, and provides the report to the user.
[0077] Optionally, providing the report to the user includes: the client provides the report to the user through a report processing page. The client displays the report in a report display area provided by the report processing page, thereby presenting all the data to be displayed specified by the user to the user in the form of a report, so that the user can intuitively and quickly grasp all the data to be displayed. The report display area is a page area in the report processing page used to display the report.
[0078] Step 104: if the target data to be displayed is received, the target data to be displayed and the stored data to be displayed are merged into all the data to be displayed, a report is generated according to all the data to be displayed, and the report is provided to the user.
[0079] Optionally, the client receives the target data to be displayed fed back by the server, merges the target data to be displayed and the stored data to be displayed into all the data to be displayed, generates a report according to all the data to be displayed, and provides the report to the user.
[0080] Optionally, the target data to be displayed is the data to be displayed that is not stored in the client among the data to be displayed. The stored data to be displayed is the data to be displayed that is stored in the client among the data to be displayed. The target data to be displayed and the stored data to be displayed constitute all the data to be displayed. The client may merge the target data to be displayed and the stored data to be displayed into all the data to be displayed.
[0081] Optionally, generating a report based on all the data to be displayed includes: sending all the data to be displayed to a report engine in the client, calling the report engine in the client to obtain a target report template corresponding to all the data to be displayed from a report template server, filling all the data to be displayed into the target report template, and generating a report.
[0082] Therefore, reports can be generated conveniently through the report engine set in the client, and report templates can be stored through the report template server, thereby reducing the data storage pressure of the server.
[0083] Optionally, the report engine in the client is an engine tool for generating reports written by a developer and set in the client. The report engine may be a JavaScript (JS) engine for generating reports. The client may call the report engine in the client by sending all the data to be displayed to the report engine in the client. After receiving all the data to be displayed sent by the client, the report engine in the client obtains a target report template corresponding to all the data to be displayed from the report template server, fills all the data to be displayed into the target report template, and generates a report.
[0084] Optionally, the client sends all the data to be displayed to the report engine in the client, calls the report engine in the client, and performs the following operations through the report engine in the client: according to the data identifiers of all the data to be displayed and the data identifiers corresponding to the report templates stored in the report template server, obtain the target report template corresponding to the all the data to be displayed from the report templates stored in the report template server; fill all the data to be displayed into the target report template to generate a report.
[0085] Optionally, based on the data identifiers of all the data to be displayed and the data identifiers corresponding to each report template stored in the report template server, a target report template corresponding to all the data to be displayed is obtained from each report template stored in the report template server, including: among each report template stored in the report template server, querying the report template whose corresponding data identifier contains the data identifier of all the data to be displayed; and determining the queried report template as the target report template corresponding to all the data to be displayed.
[0086] The target report template corresponding to the all data to be displayed is a report template containing report cells for filling the all data to be displayed. The data identifier corresponding to the report template contains the data identifier of the all data to be displayed, indicating that all report cells of the report template contain report cells for filling the all data to be displayed. Each of the all data to be displayed is filled into the corresponding report cell in the target report template, thereby generating a report for displaying the all data to be displayed.
[0087] Optionally, filling all the data to be displayed into the target report template to generate a report, including: performing the following operations for each data to be displayed among all the data to be displayed: in each report cell of the target report template, determining a target report cell whose data identifier corresponding to the report cell is the same as the data identifier of the data to be displayed; and filling the data to be displayed into the target report cell.
[0088] Optionally, after detecting whether all the data to be displayed are stored in the client according to the data identifier of each data to be displayed, the method further includes: if all the data to be displayed are stored, generating a report according to all the data to be displayed, and providing the report to the user.
[0089] Optionally, if the client stores all the data to be displayed, that is, all the data specified by the user to be displayed in the form of a report is stored in the local database of the client, the client directly generates a report based on the data to be displayed and provides the report to the user.
[0090] Therefore, when the client has complete data that needs to be presented in the form of a report, the report can be generated directly through the client, avoiding the waste of resources caused by transmitting data resources back and forth between the client and the server.
[0091] The technical solution of the embodiment of the present invention obtains the data identification of at least one item of data to be displayed input by the user, and detects whether all the data to be displayed are stored in the client according to the data identification of each data to be displayed; when the target data to be displayed is not stored, sends an information acquisition request to the server, so that the server feeds back a report corresponding to all the data to be displayed or the target data to be displayed according to the current load state of the server and the information acquisition request; then, when the report corresponding to all the data to be displayed is received, the report is provided to the user; when the target data to be displayed is received, the target data to be displayed and the stored data to be displayed are merged into all the data to be displayed, a report is generated according to all the data to be displayed, and the report is provided to the user, so as to solve the problem that the report generation method in the related art may cause resource waste. In order to solve the problems of extremely long waiting time, missing necessary data for report generation, slow report generation, page freeze and poor experience, it is found that when the client lacks data that needs to be displayed in the form of a report, the server can feed back the report or missing data to the client according to the load status, so that the client can directly provide the report fed back by the server to the user, or generate a report based on the missing data and the stored data and provide it to the user. It realizes dynamic generation of reports according to the data missing situation of the client and the load status of the server, and dynamic allocation of the computing pressure of generating reports, thereby avoiding the waste of resources caused by fixed generation of lists through the server or client, excessive long waiting time, missing necessary data for report generation, slow report generation, page freeze and poor experience, etc.
[0092] Embodiment 2
[0093] Figure 2 This is a flow chart of a report generation method provided in the second embodiment of the present invention. The embodiment of the present invention is applicable to the case where a server and a client dynamically generate corresponding reports according to a report generation request input by a user. The method can be executed by a report generation device provided in the embodiment of the present invention, which can be implemented in software and / or hardware and can generally be integrated in a server.
[0094] like Figure 2 As shown, the method includes:
[0095] Step 201: Receive an information acquisition request sent by a client.
[0096] The information acquisition request carries the data identifier of the target data to be displayed and the stored data to be displayed; the target data to be displayed is the data to be displayed that is not stored in the client.
[0097] Optionally, the information acquisition request is used to request the server to feedback a report corresponding to all the data to be displayed or the target data to be displayed. The information acquisition request carries the data identifier of the target data to be displayed and the stored data to be displayed. The stored data to be displayed is the data to be displayed that has been stored in the client among the data to be displayed.
[0098] Step 202: Feedback the report corresponding to all the data to be displayed or the target data to be displayed to the client according to the current load status of the server and the information acquisition request.
[0099] Optionally, the method of feeding back a report corresponding to all the data to be displayed or the target data to be displayed to the client based on the current load state of the server and the information acquisition request includes: detecting the current load state of the server; if the current load state is a low load state, acquiring the target data to be displayed based on a data identifier of the target data to be displayed, merging the target data to be displayed and the stored data to be displayed into all the data to be displayed, generating a report corresponding to all the data to be displayed based on all the data to be displayed, and feeding back the report to the client; if the current load state is a high load state, acquiring the target data to be displayed based on the data identifier of the target data to be displayed, and feeding back the target data to be displayed to the client.
[0100] Therefore, when the client is missing data that needs to be displayed in the form of a report and the server is in a high-load state, the client can generate a report based on the missing data returned by the server. When the client is missing data that needs to be displayed in the form of a report and the server is in a low-load state, the server can generate a report. This realizes dynamic generation of reports based on the client's data missing situation and the server's load status, and dynamic allocation of the computing pressure of generating reports. When the server is in a high-load state, the data processing pressure of the server can be reduced through the client.
[0101] Optionally, the current load state of the server is the load state of the server at the current moment. The current load state of the server is a high load state or a low load state. The current load state of the server is a high load state, indicating that there are many processes running on the server at the current moment, the load is high, and the information acquisition request may not be responded to in time, resulting in an excessively long waiting time. The current load state of the server is a low load state, indicating that there are few processes running on the server at the current moment, the load is low, and the information acquisition request can be responded to in time.
[0102] Optionally, the server may determine the current load status of the server based on indicator data related to the server load, such as the CPU utilization rate of the server at the current moment and the number of requests being processed.
[0103] Optionally, detecting the current load state of the server includes: obtaining the CPU utilization of the server at the current moment, and determining whether the CPU utilization is greater than a preset CPU utilization threshold; if the number of request processing is greater than the preset CPU utilization threshold, determining that the current load state of the server is a high load state; if the CPU utilization is less than or equal to the preset CPU utilization threshold, determining that the current load state of the server is a low load state.
[0104] Optionally, if the current load state is a low load state, the server obtains the target data to be displayed according to the data identifier of the target data to be displayed, merges the target data to be displayed and the stored data to be displayed into all the data to be displayed, generates a report corresponding to all the data to be displayed based on all the data to be displayed, and feeds the report back to the client.
[0105] Optionally, a preset database in the server stores various data that can be viewed by the user. The preset database stores various data and data identifiers of various data in a corresponding manner. The server obtains the target data to be displayed according to the data identifier of the target data to be displayed, including: obtaining data with the same data identifier as the data identifier of the target data to be displayed in the preset database in the server. The data is the target data to be displayed.
[0106] Optionally, the target data to be displayed is data to be displayed that is not stored in the client among the data to be displayed. The stored data to be displayed is data to be displayed that is stored in the client among the data to be displayed. The target data to be displayed and the stored data to be displayed constitute all the data to be displayed. The server may merge the target data to be displayed and the stored data to be displayed into all the data to be displayed.
[0107] Optionally, the server generates a report corresponding to all the data to be displayed based on all the data to be displayed, including: the server sends all the data to be displayed to a report engine in the server, calls the report engine in the server to obtain a target report template corresponding to all the data to be displayed from a report template server, fills all the data to be displayed into the target report template, and generates a report corresponding to all the data to be displayed.
[0108] Therefore, reports can be generated conveniently through the report engine set in the server, and report templates can be stored through the report template server, reducing the data storage pressure of the server.
[0109] Optionally, the report engine in the server is an engine tool for generating reports written by developers and set in the server. The report engine can be a JavaScript (JS) engine for generating reports. The server can call the report engine in the server by sending all the data to be displayed to the report engine in the server. After receiving all the data to be displayed sent by the server, the report engine in the server obtains the target report template corresponding to all the data to be displayed from the report template server, fills all the data to be displayed into the target report template, and generates a report corresponding to the all the data to be displayed.
[0110] Optionally, the server sends all the data to be displayed to a report engine in the server, calls the report engine in the server, and performs the following operations through the report engine in the server: according to the data identifiers of all the data to be displayed and the data identifiers corresponding to the report templates stored in the report template server, obtain a target report template corresponding to all the data to be displayed from the report templates stored in the report template server; fill all the data to be displayed into the target report template, and generate a report corresponding to the all the data to be displayed.
[0111] Optionally, the report template server is a server for storing report templates. The report template server may be a CDN server.
[0112] Optionally, a report template server stores multiple report templates of different report types. A report template is a template for generating a report. A report template may include multiple report cells for filling in data to be displayed. Each report cell is provided with a corresponding data identifier. The data identifier corresponding to the report cell is a data identifier of the data to be displayed that can be filled in the report cell. According to the data identifier corresponding to each report cell in the report template, the data to be displayed that can be filled in each report cell is determined, and then each data to be displayed is filled in the corresponding report cell, thereby generating a report for displaying each data to be displayed.
[0113] Optionally, the data identifiers corresponding to all report cells of the report template are the data identifiers corresponding to the report template. The data identifiers corresponding to the report template are the data identifiers of the data to be displayed that can be filled into the report template for display.
[0114] Optionally, based on the data identifiers of all the data to be displayed and the data identifiers corresponding to each report template stored in the report template server, a target report template corresponding to all the data to be displayed is obtained from each report template stored in the report template server, including: among each report template stored in the report template server, querying the report template whose corresponding data identifier contains the data identifier of all the data to be displayed; and determining the queried report template as the target report template corresponding to all the data to be displayed.
[0115] The target report template corresponding to the all data to be displayed is a report template containing report cells for filling the all data to be displayed. The data identifier corresponding to the report template contains the data identifier of the all data to be displayed, indicating that all report cells of the report template contain report cells for filling the all data to be displayed. Each of the all data to be displayed is filled into the corresponding report cell in the target report template, thereby generating a report for displaying the all data to be displayed.
[0116] Optionally, all the data to be displayed are filled into the target report template, and the report corresponding to all the data to be displayed includes: performing the following operations for each data to be displayed among all the data to be displayed: in each report cell of the target report template, determining a target report cell whose data identifier corresponding to the report cell is the same as the data identifier of the data to be displayed; and filling the data to be displayed into the target report cell.
[0117] Optionally, if the current load state is a high load state, the server obtains the target data to be displayed according to the data identifier of the target data to be displayed, and feeds the target data to be displayed back to the client.
[0118] The technical solution of the embodiment of the present invention receives an information acquisition request sent by a client, the information acquisition request carries the data identifier of the target data to be displayed and the stored data to be displayed, the target data to be displayed is the data to be displayed that is not stored in the client, and then according to the current load status of the server and the information acquisition request, the report corresponding to all the data to be displayed or the target data to be displayed is fed back to the client, thereby solving the problem that the report generation method in the related art may cause resource waste, excessive waiting time, or lack of necessary data for generating reports, slow report generation speed, and cause page jamming and poor experience. When the client lacks data that needs to be displayed in the form of a report, the server feeds back the report or the missing data to the client according to the load status, so that the client can directly provide the report fed back by the server to the user, or generate a report according to the missing data and the stored data and provide it to the user, realizing dynamic generation of reports according to the data missing situation of the client and the load status of the server, and dynamically allocating the calculation pressure of generating reports, thereby avoiding the beneficial effect that fixed generation of lists through the server or the client may cause resource waste, excessive waiting time, lack of necessary data for generating reports, slow report generation speed, and cause page jamming and poor experience.
[0119] Embodiment 3
[0120] Figure 3A A flow chart of a report generation method provided in Embodiment 3 of the present invention includes the following steps:
[0121] Step 301, the client obtains the data identifier of at least one item of data to be displayed input by the user, and detects whether all the data to be displayed are stored in the client according to the data identifier of each data to be displayed: if all the data to be displayed are stored, execute step 302; if the target data to be displayed is not stored, execute step 303.
[0122] Step 302: The client generates a report based on all the data to be displayed, and provides the report to the user.
[0123] Step 303: The client sends an information acquisition request to the server.
[0124] The information acquisition request carries the data identifier of the target data to be displayed and the stored data to be displayed.
[0125] Step 304: The server receives the information acquisition request sent by the client.
[0126] The information acquisition request carries the data identifier of the target data to be displayed and the stored data to be displayed; the target data to be displayed is the data to be displayed that is not stored in the client.
[0127] Step 305 , the server detects the current load state of the server: if the current load state is a low load state, execute step 306 ; if the current load state is a high load state, execute step 308 .
[0128] Step 306: The server obtains the target data to be displayed according to the data identifier of the target data to be displayed, merges the target data to be displayed and the stored data to be displayed into all the data to be displayed, generates a report corresponding to the all the data to be displayed according to the all the data to be displayed, and feeds the report back to the client.
[0129] Step 307: The client receives a report corresponding to all the data to be displayed fed back by the server, and provides the report to the user.
[0130] Step 308: The server obtains the target data to be displayed according to the data identifier of the target data to be displayed, and feeds the target data to be displayed back to the client.
[0131] Step 309: the client receives the target data to be displayed fed back by the server, merges the target data to be displayed and the stored data to be displayed into all the data to be displayed, generates a report based on all the data to be displayed, and provides the report to the user.
[0132] In a specific example, if Figure 3BAs shown, if the client 311 stores all the data to be displayed, the client 311 sends all the data to be displayed to the report engine 316 in the client, calls the report engine 316 in the client to obtain the target report template corresponding to all the data to be displayed from the report template server 317, fills all the data to be displayed into the target report template, and generates a report 315. If the client 311 does not store the target data to be displayed, it sends an information acquisition request to the server 312, so that the server 312 feeds back the report corresponding to all the data to be displayed or the target data to be displayed according to the current load state 313 of the server and the information acquisition request. The server 312 receives the information acquisition request sent by the client 311. The server 312 detects the current load state 313 of the server. If the current load state 313 of the server is a low load state, the server 312 obtains the target data to be displayed according to the data identifier of the target data to be displayed, merges the target data to be displayed and the stored data to be displayed into all the data to be displayed, and then sends all the data to be displayed to the report engine 314 in the server, and calls the report engine 314 in the server to generate a report 315. If the current load state 313 of the server is a high load state, the server 312 obtains the target data to be displayed according to the data identifier of the target data to be displayed, and feeds the target data to be displayed back to the client 311, so that the client 311 merges the target data to be displayed and the stored data to be displayed into all the data to be displayed, and then sends all the data to be displayed to the report engine 316 in the client, calls the report engine 316 in the client to obtain the target report template corresponding to all the data to be displayed from the report template server 317, fills all the data to be displayed into the target report template, and generates a report 315.
[0133] The technical solution of the embodiment of the present invention achieves dynamic generation of reports and dynamic allocation of computing pressure for generating reports according to the data missing situation of the client and the load status of the server: when the client has complete data that needs to be displayed in the form of a report, the report is directly generated through the client; when the client lacks data that needs to be displayed in the form of a report and the server is in a high-load state, the report is generated through the client according to the missing data returned by the server; when the client lacks data that needs to be displayed in the form of a report and the server is in a low-load state, the report is generated through the server; when the server is in a high-load state, the data processing pressure of the server can be reduced through the client, and when the client has complete data that needs to be displayed in the form of a report, the report can be directly generated through the client, thereby avoiding the waste of resources caused by transmitting data resources back and forth between the client and the server.
[0134] Embodiment 4
[0135] Figure 4This is a structural diagram of a report generation device provided by Embodiment 4 of the present invention. The device can be configured in a client. Figure 4 As shown, the device includes: a data detection module 401, a request sending module 402, a report receiving module 403 and a data receiving module 404.
[0136] Among them, the data detection module 401 is used to obtain the data identification of at least one item of data to be displayed input by the user, and detect whether all the data to be displayed are stored in the client according to the data identification of each data to be displayed; the request sending module 402 is used to send an information acquisition request to the server if the target data to be displayed is not stored, so that the server can feedback a report corresponding to all the data to be displayed or the target data to be displayed according to the current load status of the server and the information acquisition request; wherein the information acquisition request carries the data identification of the target data to be displayed and the stored data to be displayed; the report receiving module 403 is used to provide the report corresponding to all the data to be displayed to the user if the report is received; the data receiving module 404 is used to merge the target data to be displayed and the stored data to be displayed into all the data to be displayed if the target data to be displayed is received, generate a report according to all the data to be displayed, and provide the report to the user.
[0137] The technical solution of the embodiment of the present invention obtains the data identification of at least one item of data to be displayed input by the user, and detects whether all the data to be displayed are stored in the client according to the data identification of each data to be displayed; when the target data to be displayed is not stored, sends an information acquisition request to the server, so that the server feeds back a report corresponding to all the data to be displayed or the target data to be displayed according to the current load state of the server and the information acquisition request; then, when the report corresponding to all the data to be displayed is received, the report is provided to the user; when the target data to be displayed is received, the target data to be displayed and the stored data to be displayed are merged into all the data to be displayed, a report is generated according to all the data to be displayed, and the report is provided to the user, so as to solve the problem that the report generation method in the related art may cause resource waste. In order to solve the problems of extremely long waiting time, missing necessary data for report generation, slow report generation, page freeze and poor experience, it is found that when the client lacks data that needs to be displayed in the form of a report, the server can feed back the report or missing data to the client according to the load status, so that the client can directly provide the report fed back by the server to the user, or generate a report based on the missing data and the stored data and provide it to the user. It realizes dynamic generation of reports according to the data missing situation of the client and the load status of the server, and dynamic allocation of the computing pressure of generating reports, thereby avoiding the waste of resources caused by fixed generation of lists through the server or client, excessive long waiting time, missing necessary data for report generation, slow report generation, page freeze and poor experience, etc.
[0138] In an optional implementation manner of the embodiment of the present invention, optionally, the report generation device further includes: a report generation module, which is used to generate a report according to all the data to be displayed if all the data to be displayed is stored, and provide the report to the user.
[0139] In an optional implementation of an embodiment of the present invention, optionally, when the data receiving module 404 or the report generating module performs the operation of generating a report based on the all data to be displayed, it is specifically used to: send the all data to be displayed to the report engine in the client, call the report engine in the client to obtain a target report template corresponding to the all data to be displayed from a report template server, fill the all data to be displayed into the target report template, and generate a report.
[0140] Regarding the device in the above embodiment, the specific manner in which each module performs operations has been described in detail in the embodiment of the method, and will not be elaborated here.
[0141] Embodiment 5
[0142] Figure 5 This is a structural diagram of a report generation device provided in Embodiment 5 of the present invention. The device may be configured in a server. Figure 5 As shown, the device includes: a request receiving module 501 and an information feedback module 502.
[0143] Among them, the request receiving module 501 is used to receive an information acquisition request sent by the client; wherein the information acquisition request carries the data identifier of the target data to be displayed and the stored data to be displayed; the target data to be displayed is the data to be displayed that is not stored in the client; the information feedback module 502 is used to feed back a report corresponding to all the data to be displayed or the target data to be displayed to the client according to the current load status of the server and the information acquisition request.
[0144] The technical solution of the embodiment of the present invention receives an information acquisition request sent by a client, the information acquisition request carries the data identifier of the target data to be displayed and the stored data to be displayed, the target data to be displayed is the data to be displayed that is not stored in the client, and then according to the current load status of the server and the information acquisition request, the report corresponding to all the data to be displayed or the target data to be displayed is fed back to the client, thereby solving the problem that the report generation method in the related art may cause resource waste, excessive waiting time, or lack of necessary data for generating reports, slow report generation speed, and cause page jamming and poor experience. When the client lacks data that needs to be displayed in the form of a report, the server feeds back the report or the missing data to the client according to the load status, so that the client can directly provide the report fed back by the server to the user, or generate a report according to the missing data and the stored data and provide it to the user, realizing dynamic generation of reports according to the data missing situation of the client and the load status of the server, and dynamically allocating the calculation pressure of generating reports, thereby avoiding the beneficial effect that fixed generation of lists through the server or the client may cause resource waste, excessive waiting time, lack of necessary data for generating reports, slow report generation speed, and cause page jamming and poor experience.
[0145] In an optional implementation of an embodiment of the present invention, optionally, the information feedback module 502 is specifically used to: detect the current load state of the server; if the current load state is a low load state, obtain the target data to be displayed according to the data identifier of the target data to be displayed, merge the target data to be displayed and the stored data to be displayed into all the data to be displayed, generate a report corresponding to all the data to be displayed according to all the data to be displayed, and feed back the report to the client; if the current load state is a high load state, obtain the target data to be displayed according to the data identifier of the target data to be displayed, and feed back the target data to be displayed to the client.
[0146] Regarding the device in the above embodiment, the specific manner in which each module performs operations has been described in detail in the embodiment of the method, and will not be elaborated here.
[0147] Embodiment 6
[0148] Figure 6 This is a structural diagram of a report generation system provided by Embodiment 6 of the present invention. Figure 6 As shown, the system includes: a client 601 and a server 602 corresponding to the client 601 .
[0149] The client 601 is used to obtain the data identifier of at least one item of data to be displayed input by the user, and detect whether all the data to be displayed are stored in the client 601 according to the data identifier of each data to be displayed; if the target data to be displayed is not stored, an information acquisition request is sent to the server 602, so that the server 602 feeds back a report corresponding to all the data to be displayed or the target data to be displayed according to the current load state of the server 602 and the information acquisition request; wherein the information acquisition request carries the data identifier of the target data to be displayed and the stored data to be displayed; if a report corresponding to all the data to be displayed is received, the report is provided to the server 602. user; if the target data to be displayed is received, the target data to be displayed and the stored data to be displayed are merged into all the data to be displayed, a report is generated according to all the data to be displayed, and the report is provided to the user; the server 602 is used to receive the information acquisition request sent by the client 601; wherein the information acquisition request carries the data identifier of the target data to be displayed and the stored data to be displayed; the target data to be displayed is the data to be displayed that is not stored in the client 601; according to the current load state of the server 602 and the information acquisition request, the report corresponding to all the data to be displayed or the target data to be displayed is fed back to the client 601.
[0150] The technical solution of the embodiment of the present invention obtains the data identification of at least one item of data to be displayed input by the user, and detects whether all the data to be displayed are stored in the client according to the data identification of each data to be displayed; when the target data to be displayed is not stored, sends an information acquisition request to the server, so that the server feeds back a report corresponding to all the data to be displayed or the target data to be displayed according to the current load state of the server and the information acquisition request; then, when the report corresponding to all the data to be displayed is received, the report is provided to the user; when the target data to be displayed is received, the target data to be displayed and the stored data to be displayed are merged into all the data to be displayed, a report is generated according to all the data to be displayed, and the report is provided to the user, so as to solve the problem that the report generation method in the related art may cause resource waste. In order to solve the problems of extremely long waiting time, missing necessary data for report generation, slow report generation, page freeze and poor experience, it is found that when the client lacks data that needs to be displayed in the form of a report, the server can feed back the report or missing data to the client according to the load status, so that the client can directly provide the report fed back by the server to the user, or generate a report based on the missing data and the stored data and provide it to the user. It realizes dynamic generation of reports according to the data missing situation of the client and the load status of the server, and dynamic allocation of the computing pressure of generating reports, thereby avoiding the waste of resources caused by fixed generation of lists through the server or client, excessive long waiting time, missing necessary data for report generation, slow report generation, page freeze and poor experience, etc.
[0151] Embodiment 7
[0152] Figure 7 A schematic diagram of the structure of an electronic device 10 that can be used to implement the report generation method of an embodiment of the present invention is shown. The electronic device is intended to represent various forms of digital computers, such as laptop computers, desktop computers, workstations, personal digital assistants, servers, blade servers, mainframe computers, and other suitable computers. The electronic device can also represent various forms of mobile devices, such as personal digital processing, cellular phones, smart phones, wearable devices (such as helmets, glasses, watches, etc.) and other similar computing devices. The components shown herein, their connections and relationships, and their functions are merely examples and are not intended to limit the implementation of the present invention described and / or required herein.
[0153] like Figure 7As shown, the electronic device 10 includes at least one processor 11, and a memory connected to the at least one processor 11, such as a read-only memory (ROM) 12, a random access memory (RAM) 13, etc., wherein the memory stores a computer program that can be executed by at least one processor, and the processor 11 can perform various appropriate actions and processes according to the computer program stored in the read-only memory (ROM) 12 or the computer program built from the storage unit 18 to the random access memory (RAM) 13. In the RAM 13, various programs and data required for the operation of the electronic device 10 can also be stored. The processor 11, the ROM 12, and the RAM 13 are connected to each other through a bus 14. An input / output (I / O) interface 15 is also connected to the bus 14.
[0154] A number of components in the electronic device 10 are connected to the I / O interface 15, including: an input unit 16, such as a keyboard, a mouse, etc.; an output unit 17, such as various types of displays, speakers, etc.; a storage unit 18, such as a disk, an optical disk, etc.; and a communication unit 19, such as a network card, a modem, a wireless communication transceiver, etc. The communication unit 19 allows the electronic device 10 to exchange information / data with other devices through a computer network such as the Internet and / or various telecommunication networks.
[0155] The processor 11 may be a variety of general and / or special processing components with processing and computing capabilities. Some examples of the processor 11 include, but are not limited to, a central processing unit (CPU), a graphics processing unit (GPU), various special artificial intelligence (AI) computing chips, various processors running machine learning model algorithms, a digital signal processor (DSP), and any appropriate processor, controller, microcontroller, etc. The processor 11 executes the various methods and processes described above, such as a report generation method.
[0156] In some embodiments, the report generation method may be implemented as a computer program, which is tangibly contained in a computer-readable storage medium, such as a storage unit 18. In some embodiments, part or all of the computer program may be loaded and / or installed on the electronic device 10 via the ROM 12 and / or the communication unit 19. When the computer program is built into the RAM 13 and executed by the processor 11, one or more steps of the report generation method described above may be performed. Alternatively, in other embodiments, the processor 11 may be configured to execute the report generation method in any other appropriate manner (e.g., by means of firmware).
[0157] Various implementations of the systems and techniques described above herein can be implemented in digital electronic circuit systems, integrated circuit systems, field programmable gate arrays (FPGAs), application specific integrated circuits (ASICs), application specific standard products (ASSPs), systems on chips (SOCs), load programmable logic devices (CPLDs), computer hardware, firmware, software, and / or combinations thereof. These various implementations can include: being implemented in one or more computer programs that can be executed and / or interpreted on a programmable system including at least one programmable processor, which can be a special purpose or general purpose programmable processor that can receive data and instructions from a storage system, at least one input device, and at least one output device, and transmit data and instructions to the storage system, the at least one input device, and the at least one output device.
[0158] The computer programs for implementing the report generation method of the present invention may be written in any combination of one or more programming languages. These computer programs may be provided to a processor of a general-purpose computer, a special-purpose computer or other programmable data processing device, so that when the computer programs are executed by the processor, the functions / operations specified in the flow chart and / or block diagram are implemented. The computer programs may be executed entirely on the machine, partially on the machine, partially on the machine and partially on a remote machine as a stand-alone software package, or entirely on a remote machine or server.
[0159] In the context of the present invention, a computer-readable storage medium may be a tangible medium that may contain or store a computer program for use by or in combination with an instruction execution system, device or equipment. A computer-readable storage medium may include, but is not limited to, electronic, magnetic, optical, electromagnetic, infrared, or semiconductor systems, devices or equipment, or any suitable combination of the foregoing. Alternatively, a computer-readable storage medium may be a machine-readable signal medium. A more specific example of a machine-readable storage medium may include an electrical connection based on one or more lines, a portable computer disk, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disk read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the foregoing.
[0160] To provide interaction with a user, the systems and techniques described herein may be implemented on an electronic device having: a display device (e.g., a CRT (cathode ray tube) or LCD (liquid crystal display) monitor) for displaying information to the user; and a keyboard and a pointing device (e.g., a mouse or trackball) through which the user can provide input to the electronic device. Other types of devices may also be used to provide interaction with the user; for example, the feedback provided to the user may be any form of sensory feedback (e.g., visual feedback, auditory feedback, or tactile feedback); and input from the user may be received in any form (including acoustic input, voice input, or tactile input).
[0161] The systems and techniques described herein may be implemented in a computing system that includes backend components (e.g., as a data server), or a computing system that includes middleware components (e.g., an application server), or a computing system that includes frontend components (e.g., a user computer with a graphical user interface or a web browser through which a user can interact with implementations of the systems and techniques described herein), or a computing system that includes any combination of such backend components, middleware components, or frontend components. The components of the system may be interconnected by any form or medium of digital data communication (e.g., a communication network). Examples of communication networks include: a local area network (LAN), a wide area network (WAN), a blockchain network, and the Internet.
[0162] A computing system may include a client and a server. The client and the server are generally remote from each other and usually interact through a communication network. The client and server relationship is generated by computer programs running on the corresponding computers and having a client-server relationship with each other. The server may be a cloud server, also known as a cloud computing server or cloud host, which is a host product in the cloud computing service system to solve the defects of difficult management and weak business scalability in traditional physical hosts and VPS services.
[0163] It should be understood that the various forms of processes shown above can be used to reorder, add or delete steps. For example, the steps described in the present invention can be executed in parallel, sequentially or in different orders, as long as the desired results of the technical solution of the present invention can be achieved, and this document does not limit this.
[0164] The above specific implementations do not constitute a limitation on the protection scope of the present invention. It should be understood by those skilled in the art that various modifications, combinations, sub-combinations and substitutions can be made according to design requirements and other factors. Any modification, equivalent substitution and improvement made within the spirit and principle of the present invention should be included in the protection scope of the present invention.
Claims
1. A report generation method, characterized in that: Applied to the client, including: Obtaining a data identifier of at least one item of data to be displayed input by a user, and detecting whether all the data to be displayed are stored in the client according to the data identifier of each item of data to be displayed; If the target data to be displayed is not stored, an information acquisition request is sent to the server, so that the server feeds back a report corresponding to all the data to be displayed or the target data to be displayed according to the current load state of the server and the information acquisition request; wherein the information acquisition request carries the data identifier of the target data to be displayed and the stored data to be displayed; the server feeds back a report corresponding to all the data to be displayed or the target data to be displayed according to the current load state of the server and the information acquisition request, including: the server detects the current load state of the server; if the current load state is a low load state, the server obtains the target data to be displayed according to the data identifier of the target data to be displayed, merges the target data to be displayed and the stored data to be displayed into all the data to be displayed, generates a report corresponding to all the data to be displayed according to all the data to be displayed, and feeds back the report to the client; if the current load state is a high load state, the server obtains the target data to be displayed according to the data identifier of the target data to be displayed, and feeds back the target data to be displayed to the client; If a report corresponding to all the data to be displayed is received, providing the report to the user; If the target data to be displayed is received, the target data to be displayed and the stored data to be displayed are merged into all the data to be displayed, a report is generated according to all the data to be displayed, and the report is provided to the user.
2. The method according to claim 1, characterized in that After detecting whether all the data to be displayed are stored in the client according to the data identifiers of the data to be displayed, the method further includes: If all the data to be displayed are stored, a report is generated according to all the data to be displayed, and the report is provided to the user.
3. The method according to claim 1 or 2, characterized in that: The generating of a report according to all the data to be displayed includes: Send all the data to be displayed to the report engine in the client, call the report engine in the client to obtain the target report template corresponding to all the data to be displayed from the report template server, fill all the data to be displayed into the target report template, and generate a report.
4. A report generation method, characterized in that: Applied to servers, including: Receiving an information acquisition request sent by a client; wherein the information acquisition request carries a data identifier of target data to be displayed and stored data to be displayed; the target data to be displayed is data to be displayed that is not stored in the client; According to the current load state of the server and the information acquisition request, a report corresponding to all the data to be displayed or the target data to be displayed is fed back to the client; wherein, according to the current load state of the server and the information acquisition request, a report corresponding to all the data to be displayed or the target data to be displayed is fed back to the client, including: detecting the current load state of the server; if the current load state is a low load state, acquiring the target data to be displayed according to the data identifier of the target data to be displayed, merging the target data to be displayed and the stored data to be displayed into all the data to be displayed, generating a report corresponding to all the data to be displayed according to all the data to be displayed, and feeding back the report to the client; if the current load state is a high load state, acquiring the target data to be displayed according to the data identifier of the target data to be displayed, and feeding back the target data to be displayed to the client.
5. A report generation device, characterized in that: Configured in the client, including: A data detection module, used to obtain a data identifier of at least one item of data to be displayed input by a user, and detect whether all the data to be displayed are stored in the client according to the data identifier of each item of data to be displayed; A request sending module, for sending an information acquisition request to a server if the target data to be displayed is not stored, so that the server feeds back a report corresponding to all the data to be displayed or the target data to be displayed according to the current load state of the server and the information acquisition request; wherein the information acquisition request carries the data identifier of the target data to be displayed and the stored data to be displayed; the server feeds back a report corresponding to all the data to be displayed or the target data to be displayed according to the current load state of the server and the information acquisition request, including: the server detects the current load state of the server; if the current load state is a low load state, the server obtains the target data to be displayed according to the data identifier of the target data to be displayed, merges the target data to be displayed and the stored data to be displayed into all the data to be displayed, generates a report corresponding to all the data to be displayed according to all the data to be displayed, and feeds back the report to the client; if the current load state is a high load state, the server obtains the target data to be displayed according to the data identifier of the target data to be displayed, and feeds back the target data to be displayed to the client; A report receiving module, configured to provide the report to the user if a report corresponding to all the data to be displayed is received; The data receiving module is used for merging the target data to be displayed and the stored data to be displayed into all the data to be displayed if the target data to be displayed is received, generating a report according to all the data to be displayed, and providing the report to the user.
6. A report generation device, characterized in that: Configured in the server, including: A request receiving module, used to receive an information acquisition request sent by a client; wherein the information acquisition request carries a data identifier of target data to be displayed and stored data to be displayed; the target data to be displayed is data to be displayed that is not stored in the client; An information feedback module is used to feed back a report corresponding to all the data to be displayed or the target data to be displayed to the client according to the current load state of the server and the information acquisition request; wherein, feeding back a report corresponding to all the data to be displayed or the target data to be displayed to the client according to the current load state of the server and the information acquisition request comprises: detecting the current load state of the server; if the current load state is a low load state, acquiring the target data to be displayed according to the data identifier of the target data to be displayed, merging the target data to be displayed and the stored data to be displayed into all the data to be displayed, generating a report corresponding to all the data to be displayed according to all the data to be displayed, and feeding back the report to the client; if the current load state is a high load state, acquiring the target data to be displayed according to the data identifier of the target data to be displayed, and feeding back the target data to be displayed to the client.
7. A report generation system, characterized in that: include: A client, and a server corresponding to the client; Wherein, the client is used to obtain the data identification of at least one item of data to be displayed input by the user, and detect whether all the data to be displayed are stored in the client according to the data identification of each data to be displayed; if the target data to be displayed is not stored, an information acquisition request is sent to the server, so that the server feeds back a report corresponding to all the data to be displayed or the target data to be displayed according to the current load state of the server and the information acquisition request; wherein the information acquisition request carries the data identification of the target data to be displayed and the stored data to be displayed; if a report corresponding to all the data to be displayed is received, the report is provided to the user; if the target data to be displayed is received, the target data to be displayed and the stored data to be displayed are merged into all the data to be displayed, a report is generated according to all the data to be displayed, and the report is provided to the user; The server is configured to receive an information acquisition request sent by the client; wherein the information acquisition request carries a data identifier of target data to be displayed and stored data to be displayed; the target data to be displayed is data to be displayed that is not stored in the client; according to the current load state of the server and the information acquisition request, a report corresponding to all data to be displayed or the target data to be displayed is fed back to the client; Among them, according to the current load state of the server and the information acquisition request, a report corresponding to all the data to be displayed or the target data to be displayed is fed back to the client, including: detecting the current load state of the server; if the current load state is a low load state, obtaining the target data to be displayed according to the data identifier of the target data to be displayed, merging the target data to be displayed and the stored data to be displayed into all the data to be displayed, generating a report corresponding to all the data to be displayed according to all the data to be displayed, and feeding back the report to the client; if the current load state is a high load state, obtaining the target data to be displayed according to the data identifier of the target data to be displayed, and feeding back the target data to be displayed to the client.
8. An electronic device, characterized in that: The electronic device comprises: at least one processor; and a memory communicatively connected to the at least one processor; wherein, The memory stores a computer program executable by the at least one processor, and the computer program is executed by the at least one processor so that the at least one processor can execute the report generation method according to any one of claims 1 to 3, or the report generation method according to claim 4.
9. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores computer instructions, and the computer instructions are used to enable a processor to implement the report generation method according to any one of claims 1 to 3, or the report generation method according to claim 4 when executed.
Citation Information
Patent Citations
Report making method and system
CN102081757A
Report form data processing method and related equipment
CN104408068A