Report file generation method, device, computer equipment and storage medium
By identifying and labeling report data types and using the display interface display component to generate report files, the problem of manual processing of complex data in the existing technology is solved, and intelligent report file generation is realized.
Patent Information
- Application Number
- CN202010229014.6
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2020-03-27
- Publication Date
- 2025-02-14
- Estimated Expiration
- 2040-03-27
AI Technical Summary
The existing report file generation method requires manual processing when facing complex project data, resulting in insufficient intelligent generation.
By obtaining the original report data, identifying and annotating the data type, receiving selection instructions to display the component using the display interface, and determining the report sub-data based on the component identification and data type association relationship, and finally generating a report file based on the component attribute information.
It realizes intelligent report file generation without manual identification and addition of data content, improving generation efficiency and accuracy.
Smart Images

Figure CN111428464B_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the field of artificial intelligence technology, and in particular to a report file generation method, apparatus, computer equipment and storage medium. Background Art
[0002] Various types of reports are important written evidence for business and technical management and supervision of enterprises. The types and styles of reports vary greatly depending on the business the enterprise is engaged in.
[0003] The existing report generation method is mainly to use historical reports or to generate through general templates. For example, new content is added on the basis of historical reports, or pre-made general templates are modified according to different business contents, and then the report files are output.
[0004] However, when faced with more complex project data, manual processing is required before a report file can be generated, and thus the report file generation is not intelligent enough. Summary of the invention
[0005] Based on this, it is necessary to provide a report file generation method, apparatus, computer equipment and storage medium that can intelligently generate report files in response to the above technical problems.
[0006] A method for generating a report file, the method comprising:
[0007] Get raw report data;
[0008] Identify and label the data type of each report sub-data in the original report data;
[0009] Receiving a selection instruction for a component through a display interface, and displaying the selected component on the display interface according to the selection instruction, the component is used to display the report sub-data in the original report data, and the selection instruction carries a component identifier of the selected component;
[0010] Display the selected components in the display interface;
[0011] Based on the association relationship between the preset data type and the component identifier, determine the report sub-data corresponding to the selected component, and display the report sub-data through the component;
[0012] Obtain the attribute information of the component in the display interface, and generate a report file based on the attribute information and the report sub-data displayed in the component.
[0013] In one embodiment, the method further comprises:
[0014] Receiving an editing instruction for the report sub-data in the component through the display interface, and editing the data format and / or data content of the report sub-data based on the editing instruction;
[0015] Generate a report file based on the component information and the report sub-data displayed in the component, including:
[0016] A report file is generated based on the edited report sub-data and the attribute information of the component.
[0017] In one embodiment, a report file is generated based on the component information and the report sub-data displayed in the component, including:
[0018] receiving an interaction instruction for the report sub-data displayed in the component, and adjusting the display ratio and / or display area of the report sub-data displayed in the component according to the interaction instruction;
[0019] Intercept the report sub-data after the display ratio and / or display area are adjusted in the component to generate image data;
[0020] Generate a report file based on the image data and the acquired component attribute information.
[0021] In one embodiment, based on the association between the preset data type and the component identifier, determining the report sub-data corresponding to the selected component, and displaying the report sub-data through the component, includes:
[0022] Based on the association relationship, determine the data acquisition interface of the corresponding data type;
[0023] The report sub-data corresponding to the data type is obtained through the data acquisition interface and displayed through the component.
[0024] In one embodiment, identifying and labeling the data type of each report sub-data in the original report data includes:
[0025] Identify the data type of the original report data, and determine whether the original report data is data containing multiple different data types based on the identification result;
[0026] When the original report data contains data of multiple different data types, the original report data is split according to the difference of each data type to obtain multiple report sub-data;
[0027] Label the data type of each report sub-data separately.
[0028] A report file generating device, the device comprising:
[0029] An original report data acquisition module, used for acquiring original report data;
[0030] An identification and labeling module, used to identify and label the data type of each report sub-data in the original report data;
[0031] A selection instruction receiving module is used to receive a selection instruction for a component through a display interface, and display the selected component on the display interface according to the selection instruction, wherein the component is used to display the report sub-data in the original report data, and the selection instruction carries a component identifier of the selected component;
[0032] A report sub-data determination module, used to determine the report sub-data corresponding to the selected component based on the association relationship between the preset data type and the component identifier, and display the report sub-data through the component;
[0033] The report file generation module is used to obtain the attribute information of the components in the display interface, and generate a report file based on the attribute information and the report sub-data displayed in the components.
[0034] In one embodiment, the above device further comprises:
[0035] An editing instruction receiving module, used to receive an editing instruction for the report sub-data in the component through a display interface, and edit the data format and / or data content of the report sub-data based on the editing instruction;
[0036] The report file generation module is used to generate a report file based on the edited report sub-data and the attribute information of the component.
[0037] In one embodiment, the report file generation module includes:
[0038] An interactive instruction receiving submodule, used to receive interactive instructions for the report sub-data displayed in the component, and adjust the display ratio and / or display area of the report sub-data displayed in the component according to the interactive instructions;
[0039] An interception submodule is used to intercept the report sub-data after the display ratio and / or display area are adjusted in the component to generate image data;
[0040] The report file generation submodule is used to generate a report file based on the image data and the acquired component attribute information.
[0041] A computer device comprises a memory and a processor, wherein the memory stores a computer program, and the processor implements the steps of any one of the above methods when executing the computer program.
[0042] A computer-readable storage medium stores a computer program, which implements the steps of any of the above methods when executed by a processor.
[0043] The above-mentioned report file generation method, device, computer equipment and storage medium identify the data type of the acquired original report data and mark it, then receive the selection instruction for the component through the display interface, and display the selected component on the display interface according to the selection instruction, wherein the component is used to display the report sub-data in the original report data, and the selection instruction carries the component identification of the selected component. Further based on the association between the data type and the component identification, the report sub-data corresponding to the selected component is determined and displayed through the component, and the report file is generated according to the attribute information of the acquired component and the report sub-data displayed by the component. Therefore, there is no need to manually identify the data and add data content to the original report data used to generate the report file, making the generation of the report file more intelligent. BRIEF DESCRIPTION OF THE DRAWINGS
[0044] Figure 1 An application scenario diagram of a report file generating method in an embodiment;
[0045] Figure 2 A schematic diagram of a flow chart of a method for generating a report file in one embodiment;
[0046] Figure 3 A schematic diagram of display content of a display interface in one embodiment;
[0047] Figure 4 It is a structural block diagram of a report file generating device in one embodiment;
[0048] Figure 5 FIG. 4 is a diagram showing the internal structure of a computer device in one embodiment. DETAILED DESCRIPTION
[0049] In order to make the purpose, technical solution and advantages of the present application more clearly understood, the present application is further described in detail below in conjunction with the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are only used to explain the present application and are not used to limit the present application.
[0050] The report file generation method provided in this application can be applied to Figure 1In the application environment shown. Among them, the terminal 102 communicates with the server 104 through the network. The terminal 102 can be used to generate the original report data of the report file and send it to the server 104 through the network. After obtaining the original report data, the server 104 can identify and mark the data type of each report sub-data in the original report data obtained, and then the server 104 can receive the selection instruction for the component through the display interface, and display the selected component in the display interface. Further, the server 104 can determine the report sub-data corresponding to the selected component based on the association relationship between the preset data type and the component identifier of the selected component carried by the selection instruction, and display the determined report sub-data through the component, and then the server 104 can obtain the attribute information of the component in the display interface and the report sub-data displayed in the component to generate a report file. Among them, the terminal 102 can be, but is not limited to, various personal computers, laptops, smart phones, tablet computers and portable wearable devices, and the server 104 can be implemented with an independent server or a server cluster composed of multiple servers.
[0051] In one embodiment, Figure 2 As shown, a report file generation method is provided, which is applied to Figure 1 The server in the example is used to illustrate the following steps:
[0052] Step S202, obtaining original report data.
[0053] The original report data refers to the original data used to generate the report file, and may include data of various different data types, such as text data, image data, chart data, or map data.
[0054] In this embodiment, the original report data obtained by the server may be data directly input by the user on the terminal, or data stored in the server database, or data obtained from a third party's Enterprise Resource Planning (ERP) system through a related docking interface.
[0055] Specifically, the server obtains the corresponding data from the third-party ERP system through the relevant docking interface by sending a data request to the third-party system through the relevant docking interface, and the data request carries a data identifier of the requested data. After receiving the request, the third-party ERP system authenticates the data request, and after the authentication is passed, sends the relevant docking interface of the request to the server. The server obtains the corresponding data through the relevant docking interface.
[0056] Step S204: identifying and marking the data type of each report sub-data in the original report data.
[0057] As mentioned above, the original report data may include data of various different data types such as text data, picture data, chart data or map data. The original report data includes at least one report sub-data, that is, data of at least one data type.
[0058] In this embodiment, after the server obtains the original report data, it can identify and determine the report sub-data in the original report data, for example, image recognition, text recognition, etc., and mark the corresponding data type after identification.
[0059] Step S206, receiving a selection instruction for a component through the display interface, and displaying the selected component on the display interface according to the selection instruction, the component is used to display the report sub-data in the original report data, and the selection instruction carries the component identifier of the selected component.
[0060] The component refers to a control used to display report sub-data and edit the displayed report sub-data, and may include a text component, an image component, a chart component, or a map component.
[0061] Specifically, components correspond one-to-one to different data types, and report sub-data of a data type can be edited and displayed through corresponding components. For example, text components are used to display text data, and image components are used to display image data.
[0062] The component identifier refers to a unique identifier corresponding to a component, and the component identifier corresponds to the component one-to-one, that is, the component identifier may include a text component identifier corresponding to a file component, a map component identifier corresponding to a map component, and the like.
[0063] The display interface refers to the interface that can display data and perform human-computer interaction.
[0064] The selection instruction refers to an instruction generated when selecting a component, and the selection instruction carries the component identifier of the selected component.
[0065] In this embodiment, reference Figure 3 The display interface may include a component selection sub-interface 301 and a report editing display sub-interface 302. The component selection sub-interface 301 may display components corresponding to different data types, and the report editing display sub-interface 302 may display the selected components.
[0066] Specifically, the server may display the selected component in the report editing display sub-interface 302 based on the selection instruction of the component in the component selection sub-interface.
[0067] Step S208, based on the association relationship between the preset data type and the component identifier, determine the report sub-data corresponding to the selected component, and display the report sub-data through the component.
[0068] The association relationship refers to the relationship between the association component identifier and the data type set in advance by the user.
[0069] Specifically, the server can determine the data type corresponding to the associated relationship based on the component identifier carried in the component selection instruction, and based on the data type, determine the report sub-data of the same data type from the acquired original report data, and display the determined report sub-data in the component corresponding to the component identifier displayed on the display interface.
[0070] Optionally, there may be multiple report sub-data obtained from the original report data based on the association relationship. The server may generate key information corresponding to the multiple report sub-data, such as keywords, and then display the generated key information in the display interface. Based on the selection instructions for the key information received by the display interface, the server may determine the report sub-data displayed by the component and display the report sub-data through the component.
[0071] Step S210, acquiring attribute information of the component in the display interface, and generating a report file according to the attribute information and the report sub-data displayed in the component.
[0072] The attribute information of the component may include, but is not limited to, the size information of the component, the position information of the component in the display interface, etc.
[0073] A report file refers to a file used for reporting. Depending on different pre-set storage formats, the generated report file can be a file in different formats, such as a presentation (PowerPoint, PPT) file, a TXT file, a WORD file, etc.
[0074] Specifically, after receiving the report generation instruction, the server generates a corresponding report file according to the position information of each component on the display interface and the original data displayed in each component in accordance with the report generation format.
[0075] In the above-mentioned report file generation method, the data type of the acquired original report data is identified and annotated, and then a selection instruction for the component is received through the display interface, and the selected component is displayed on the display interface according to the selection instruction, wherein the component is used to display the report sub-data in the original report data, and the selection instruction carries the component identification of the selected component. Further based on the association between the data type and the component identification, the report sub-data corresponding to the selected component is determined and displayed through the component, and a report file is generated based on the attribute information of the acquired component and the report sub-data displayed by the component. Therefore, there is no need to manually identify the data and add data content to the original report data used to generate the report file, making the generation of the report file more intelligent.
[0076] In one of the embodiments, the method may further include: receiving an editing instruction for the report sub-data in the component through a display interface, and editing the data format and / or data content of the report sub-data based on the editing instruction.
[0077] Among them, the editing instructions are instructions for editing the report sub-data displayed in the component, which may include editing of data attributes, such as editing and replacing font size, font, color, etc., and may also include changes to data content, such as replacing typos, changing punctuation marks, segmenting text content, adding picture data points, lines and surfaces, editing of chart data display content, and adjusting map data to display points of interest (POI).
[0078] Specifically, the server may edit and modify the data format and / or data content of the report sub-data displayed in the component according to the received editing instruction.
[0079] Optionally, the server may also modify the properties of the component displayed in the display interface according to the received editing instruction for the property information of the component. For example, Figure 3 , edit and change the size of the component, change the location of the component in the display interface, and change the shape of the component, for example, changing it to a long strip, diamond, circle, or irregular shape.
[0080] In this embodiment, generating a report file according to the component information and the report sub-data displayed in the component may include: generating a report file based on the edited report sub-data and the attribute information of the component.
[0081] Specifically, the server generates a corresponding report file according to the attribute information of the edited component and the report sub-data displayed in the edited component.
[0082] In the above embodiment, the data format and / or data content of the report sub-data displayed in the component is edited by receiving the editing instructions, and a report file is generated based on the edited report sub-data in the display interface and the attribute information of the component. This can make the generated report file more accurate and complete, thereby improving the accuracy of the generated report and the quality of the generated report.
[0083] In one of the embodiments, generating a report file based on component information and report sub-data displayed in the component may include: receiving interactive instructions for the report sub-data displayed in the component, and adjusting the display ratio and / or display area of the report sub-data displayed in the component according to the interactive instructions; capturing the report sub-data in the component after the display ratio and / or display area are adjusted to generate image data; and generating a report file based on the image data and the acquired attribute information of the component.
[0084] As mentioned above, the report sub-data may be text data, picture data, chart data or map data.
[0085] In this embodiment, when the selected component is a chart component or a map component, the data type displayed in the component is the corresponding chart data or the corresponding map data. The server can perform interactive operations on the chart data or map data displayed in the component according to the received interactive instructions for the report sub-data displayed in the component. For example, Figure 3 The server can zoom in or out the displayed map, adjust the map or icon displayed in the component to a suitable display ratio, or adjust the display area, etc., to only display the content of the specified map area, or filter the displayed POIs to only display some POIs, etc.
[0086] Further, the server intercepts the report sub-data after the display ratio and / or display area are adjusted in the component and generates image data, for example, intercepts the map or icon displayed in the component and generates image data.
[0087] Furthermore, the server generates a report file based on the captured and generated image data and the property information such as the position and size of the component in the display interface.
[0088] Optionally, continue to refer to Figure 3 ,For ,map data, the server can also extract the name, attribute classification, level and other information of POI from the map data and ,display it. For example, the attribute classification is school, business office, hospital or leisure, and the level is general, key, tertiary ,level, etc.
[0089] The server may also highlight the corresponding POI in the component according to the received selection of the name, attribute classification, energy level and other information of the displayed POI.
[0090] Optionally, multiple components can be displayed simultaneously in the same display interface, that is, multiple report sub-data can be displayed through multiple components. Among them, the data types of the multiple report sub-data displayed can be the same or different, and the components in the display interface are displayed in the form of hierarchical superposition. The server can display the selected component at the top layer or the topmost layer of the display decoding according to the selection instruction of the component displayed in the display interface. Alternatively, after selecting the corresponding component, the server can adjust the level of the selected component according to the instructions such as "move up one layer", "move down one layer", "put on the top layer", "put on the bottom layer" received by the display interface.
[0091] In the above embodiment, image data is generated by intercepting report sub-data after the display ratio and / or display area are adjusted in the component, and a report file is generated based on the image data and the acquired attribute information of the component. Compared with directly generating a report file based on map data and chart data, the amount of data in the generated report file can be reduced, thereby improving the generation efficiency of the report file.
[0092] In one of the embodiments, based on the association relationship between a preset data type and a component identifier, report sub-data corresponding to a selected component is determined, and the report sub-data is displayed through the component, which may include: determining a data acquisition interface corresponding to the data type based on the association relationship; acquiring the report sub-data corresponding to the data type through the data acquisition interface, and displaying it through the component.
[0093] The data acquisition interface refers to an interface for acquiring report sub-data of different data types. For different data types of report sub-data, the data acquisition interface is different, for example, text data is acquired through a text data acquisition interface, and map data is acquired through a map data acquisition interface.
[0094] In the above embodiment, the corresponding report sub-data is obtained through the data acquisition interface of the corresponding data type, which can reduce the possibility of error in obtaining the report sub-data, and thus improve the accuracy of the generated report file.
[0095] In one embodiment, identifying and labeling the data type of each report sub-data in the original report data may include: identifying the data type of the original report data, and judging whether the original report data is data containing multiple different data types based on the identification result; when the original report data contains data of multiple different data types, splitting the original report data according to the difference of each data type to obtain multiple report sub-data; and labeling the data type of each report sub-data respectively.
[0096] As mentioned above, the original report data includes at least one type of report sub-data. After acquiring the original report data, the server can identify the data type of the original report data to determine whether the original report data includes multiple different types of report sub-data.
[0097] Specifically, when the server recognizes that the acquired original report data includes report sub-data of multiple different data types, for example, text data, map data, and chart data, the original report data can be split into multiple report sub-data according to different data types, and each report sub-data can be marked with the corresponding data type.
[0098] In the above embodiment, the data type of the original report data is identified and determined, and the data is split and labeled, so that the original report data finally exists in the form of report sub-data of a single data type, which is convenient for subsequent corresponding display and editing and adjustment through different types of components, thereby reducing the possibility of subsequent errors and improving the efficiency of report file generation.
[0099] It should be understood that although Figure 2 The steps in the flowchart are shown in sequence as indicated by the arrows, but these steps are not necessarily executed in the order indicated by the arrows. Unless otherwise specified in this document, there is no strict order restriction for the execution of these steps, and these steps can be executed in other orders. Moreover, Figure 2 At least part of the steps may include multiple sub-steps or multiple stages. These sub-steps or stages are not necessarily executed at the same time, but can be executed at different times. The execution order of these sub-steps or stages is not necessarily sequential, but can be executed in turn or alternately with other steps or at least part of the sub-steps or stages of other steps.
[0100] In one embodiment, Figure 4 As shown, a report file generating device is provided, comprising: an original report data acquiring module 100, an identifying and marking module 200, a selection instruction receiving module 300, a report sub-data determining module 400 and a report file generating module 500, wherein:
[0101] The original report data acquisition module 100 is used to acquire original report data.
[0102] The identification and labeling module 200 is used to identify and label the data type of each report sub-data in the original report data.
[0103] The selection instruction receiving module 300 is used to receive the selection instruction for the component through the display interface, and display the selected component on the display interface according to the selection instruction. The component is used to display the report sub-data in the original report data. The selection instruction carries the component identifier of the selected component.
[0104] The report sub-data determination module 400 is used to determine the report sub-data corresponding to the selected component based on the association relationship between the preset data type and the component identifier, and display the report sub-data through the component.
[0105] The report file generating module 500 is used to obtain the attribute information of the components in the display interface, and generate a report file according to the attribute information and the report sub-data displayed in the components.
[0106] In one embodiment, the above device may further include:
[0107] The editing instruction receiving module is used to receive the editing instruction of the report sub-data in the component through the display interface, and edit the data format and / or data content of the report sub-data based on the editing instruction.
[0108] The report file generating module 500 is used to generate a report file based on the edited report sub-data and the attribute information of the component.
[0109] In one embodiment, the report file generation module 500 may include:
[0110] The interaction instruction receiving submodule is used to receive interaction instructions for the report sub-data displayed in the component, and adjust the display ratio and / or display area of the report sub-data displayed in the component according to the interaction instructions.
[0111] The interception submodule is used to intercept the report sub-data after the display ratio and / or display area are adjusted in the component to generate image data.
[0112] The report file generation submodule is used to generate a report file based on the image data and the acquired component attribute information.
[0113] In one embodiment, the report sub-data determination module 400 may include:
[0114] The interface determination submodule is used to determine the data acquisition interface of the corresponding data type based on the association relationship.
[0115] The report sub-data acquisition sub-module is used to obtain the report sub-data corresponding to the data type through the data acquisition interface and display it through the component.
[0116] In one embodiment, the identification and labeling module 200 may include:
[0117] The identification submodule is used to identify the data type of the original report data and determine whether the original report data is data containing multiple different data types based on the identification result.
[0118] The splitting submodule is used to split the original report data according to the difference of each data type to obtain multiple report sub-data when the original report data contains data of multiple different data types.
[0119] The data type labeling submodule is used to label the data type of each report sub-data.
[0120] For the specific definition of the report file generation device, please refer to the definition of the report file generation method above, which will not be repeated here. Each module in the above-mentioned report file generation device can be implemented in whole or in part by software, hardware and a combination thereof. The above-mentioned modules can be embedded in or independent of the processor in the computer device in the form of hardware, or can be stored in the memory of the computer device in the form of software, so that the processor can call and execute the operations corresponding to the above modules.
[0121] In one embodiment, a computer device is provided. The computer device may be a server, and its internal structure diagram may be as follows: Figure 5 As shown. The computer device includes a processor, a memory, a network interface and a database connected through a system bus. Among them, the processor of the computer device is used to provide computing and control capabilities. The memory of the computer device includes a non-volatile storage medium and an internal memory. The non-volatile storage medium stores an operating system, a computer program and a database. The internal memory provides an environment for the operation of the operating system and the computer program in the non-volatile storage medium. The database of the computer device is used to store data such as original report data, report sub-data, generated report files, etc. The network interface of the computer device is used to communicate with an external terminal through a network connection. When the computer program is executed by the processor, a report file generation method is implemented.
[0122] Those skilled in the art will understand that Figure 5 The structure shown in the figure is only a block diagram of a part of the structure related to the solution of the present application, and does not constitute a limitation on the computer device to which the solution of the present application is applied. The specific computer device may include more or fewer components than those shown in the figure, or combine certain components, or have a different arrangement of components.
[0123] In one embodiment, a computer device is provided, including a memory and a processor, wherein the memory stores a computer program, and the processor implements the following steps when executing the computer program: obtaining original report data; identifying and marking the data type of each report sub-data in the original report data; receiving a selection instruction for a component through a display interface, and displaying the selected component on the display interface according to the selection instruction, wherein the component is used to display the report sub-data in the original report data, and the selection instruction carries a component identifier of the selected component; determining the report sub-data corresponding to the selected component based on an association between a preset data type and a component identifier, and displaying the report sub-data through the component; obtaining attribute information of the component in the display interface, and generating a report file according to the attribute information and the report sub-data displayed in the component.
[0124] In one embodiment, when the processor executes the computer program, the following steps may be further implemented: receiving an editing instruction for the report sub-data in the component through the display interface, and editing the data format and / or data content of the report sub-data based on the editing instruction. When the processor executes the computer program, generating a report file according to the component information and the report sub-data displayed in the component may include: generating a report file based on the edited report sub-data and the attribute information of the component.
[0125] In one of the embodiments, when the processor executes a computer program, generating a report file based on component information and report sub-data displayed in the component may include: receiving interaction instructions for the report sub-data displayed in the component, and adjusting the display ratio and / or display area of the report sub-data displayed in the component according to the interaction instructions; intercepting the report sub-data in the component after the display ratio and / or display area are adjusted to generate image data; and generating a report file based on the image data and the acquired attribute information of the component.
[0126] In one of the embodiments, when the processor executes the computer program, it determines the report sub-data corresponding to the selected component based on the association relationship between the preset data type and the component identifier, and displays the report sub-data through the component, which may include: determining the data acquisition interface corresponding to the data type based on the association relationship; acquiring the report sub-data corresponding to the data type through the data acquisition interface, and displaying it through the component.
[0127] In one of the embodiments, when the processor executes a computer program, it can identify and label the data type of each report sub-data in the original report data, which can include: identifying the data type of the original report data, and judging whether the original report data is data containing multiple different data types based on the identification result; when the original report data contains data of multiple different data types, splitting the original report data according to the difference of each data type to obtain multiple report sub-data; and labeling the data type of each report sub-data respectively.
[0128] In one embodiment, a computer-readable storage medium is provided, on which a computer program is stored, and when the computer program is executed by a processor, the following steps are implemented: obtaining original report data; identifying and marking the data type of each report sub-data in the original report data; receiving a selection instruction for a component through a display interface, and displaying the selected component on the display interface according to the selection instruction, the component is used to display the report sub-data in the original report data, and the selection instruction carries the component identification of the selected component; based on the association between a preset data type and the component identification, determining the report sub-data corresponding to the selected component, and displaying the report sub-data through the component; obtaining attribute information of the component in the display interface, and generating a report file according to the attribute information and the report sub-data displayed in the component.
[0129] In one embodiment, when the computer program is executed by the processor, the following steps may be implemented: receiving an editing instruction for the report sub-data in the component through the display interface, and editing the data format and / or data content of the report sub-data based on the editing instruction. When the computer program is executed by the processor, generating a report file according to the component information and the report sub-data displayed in the component may include: generating a report file based on the edited report sub-data and the attribute information of the component.
[0130] In one of the embodiments, when the computer program is executed by the processor, it is implemented to generate a report file based on the component information and the report sub-data displayed in the component, which may include: receiving interaction instructions for the report sub-data displayed in the component, and adjusting the display ratio and / or display area of the report sub-data displayed in the component according to the interaction instructions; intercepting the report sub-data in the component after the display ratio and / or display area are adjusted to generate image data; generating a report file based on the image data and the acquired attribute information of the component.
[0131] In one embodiment, when the computer program is executed by the processor, it is implemented to determine the report sub-data corresponding to the selected component based on the association relationship between the preset data type and the component identifier, and display the report sub-data through the component, which may include: determining the data acquisition interface corresponding to the data type based on the association relationship; acquiring the report sub-data corresponding to the data type through the data acquisition interface, and displaying it through the component.
[0132] In one of the embodiments, when the computer program is executed by the processor, it can identify and label the data type of each report sub-data in the original report data, which can include: identifying the data type of the original report data, and judging whether the original report data is data containing multiple different data types based on the identification result; when the original report data contains data of multiple different data types, splitting the original report data according to the difference of each data type to obtain multiple report sub-data; and labeling the data type of each report sub-data respectively.
[0133] Those skilled in the art can understand that all or part of the processes in the above-mentioned embodiment methods can be completed by instructing the relevant hardware through a computer program, and the computer program can be stored in a non-volatile computer-readable storage medium. When the computer program is executed, it can include the processes of the embodiments of the above-mentioned methods. Among them, any reference to memory, storage, database or other media used in the embodiments provided in this application can include non-volatile and / or volatile memory. Non-volatile memory can include read-only memory (ROM), programmable ROM (PROM), electrically programmable ROM (EPROM), electrically erasable programmable ROM (EEPROM) or flash memory. Volatile memory can include random access memory (RAM) or external cache memory. As an illustration and not limitation, RAM is available in many forms, such as static RAM (SRAM), dynamic RAM (DRAM), synchronous DRAM (SDRAM), double data rate SDRAM (DDRSDRAM), enhanced SDRAM (ESDRAM), synchronous link (Synchlink) DRAM (SLDRAM), memory bus (Rambus) direct RAM (RDRAM), direct memory bus dynamic RAM (DRDRAM), and memory bus dynamic RAM (RDRAM).
[0134] The technical features of the above embodiments may be arbitrarily combined. To make the description concise, not all possible combinations of the technical features in the above embodiments are described. However, as long as there is no contradiction in the combination of these technical features, they should be considered to be within the scope of this specification.
[0135] The above-mentioned embodiments only express several implementation methods of the present application, and the descriptions thereof are relatively specific and detailed, but they cannot be understood as limiting the scope of the invention patent. It should be pointed out that, for a person of ordinary skill in the art, several variations and improvements can be made without departing from the concept of the present application, and these all belong to the protection scope of the present application. Therefore, the protection scope of the patent of the present application shall be subject to the attached claims.
Claims
1. A method for generating a report file, characterized in that: The method comprises: Get raw report data; Identify and label the data type of each report sub-data in the original report data; receiving a selection instruction for a component through a display interface, and displaying a selected component on the display interface according to the selection instruction, wherein the component is used to display the report sub-data in the original report data, and the selection instruction carries a component identifier of the selected component; Determine the report sub-data corresponding to the selected component based on the association relationship between the preset data type and the component identifier, and display the report sub-data through the component; Acquire the attribute information of the component in the display interface, receive interaction instructions for the report sub-data displayed in the component, and adjust the display ratio and / or display area of the report sub-data displayed in the component according to the interaction instructions; intercept the report sub-data after the display ratio and / or display area are adjusted in the component to generate image data; generate a report file according to the image data and the acquired attribute information of the component.
2. The method according to claim 1, characterized in that The determining, based on the association relationship between the preset data type and the component identifier, the report sub-data corresponding to the selected component, and displaying the report sub-data through the component, includes: Based on the association relationship, determine a data acquisition interface corresponding to the data type; The report sub-data corresponding to the data type is acquired through the data acquisition interface and displayed through the component.
3. The method according to claim 1, characterized in that The identifying and marking the data type of each report sub-data in the original report data includes: Identifying the data type of the original report data, and determining whether the original report data is data containing multiple different data types based on the identification result; When the original report data contains data of multiple different data types, the original report data is split according to the difference of each data type to obtain multiple report sub-data; The data types of the report sub-data are marked respectively.
4. The method according to claim 1, characterized in that: The attribute information of the component includes size information of the component and position information of the component in the display interface.
5. The method according to claim 1, characterized in that The report sub-data includes at least one of text data, picture data, chart data or map data.
6. A report file generating device, characterized in that: The device comprises: An original report data acquisition module, used for acquiring original report data; An identification and labeling module, used for identifying and labeling the data type of each report sub-data in the original report data; A selection instruction receiving module, used for receiving a selection instruction for a component through a display interface, and displaying a selected component on the display interface according to the selection instruction, wherein the component is used for displaying the report sub-data in the original report data, and the selection instruction carries a component identifier of the selected component; A report sub-data determination module, configured to determine the report sub-data corresponding to the selected component based on the association between the preset data type and the component identifier, and to display the report sub-data through the component; A report file generation module is used to obtain attribute information of components in the display interface, receive interactive instructions for report sub-data displayed in the component, and adjust the display ratio and / or display area of the report sub-data displayed in the component according to the interactive instructions; intercept the report sub-data in the component after the display ratio and / or display area are adjusted to generate image data; and generate a report file based on the image data and the acquired attribute information of the component.
7. The device according to claim 6, characterized in that The report sub-data determination module comprises: The interface determination submodule is used to determine the data acquisition interface of the corresponding data type based on the association relationship; The report sub-data acquisition sub-module is used to obtain the report sub-data corresponding to the data type through the data acquisition interface and display it through the component.
8. The device according to claim 6, characterized in that The identification and labeling module includes: An identification submodule, used to identify the data type of the original report data, and determine whether the original report data is data containing multiple different data types based on the identification result; A splitting submodule is used to split the original report data according to the data types to obtain multiple report sub-data when the original report data contains data of multiple different data types; The data type labeling submodule is used to label the data type of each report sub-data.
9. A computer device comprising a memory and a processor, wherein the memory stores a computer program, wherein: When the processor executes the computer program, the steps of the method according to any one of claims 1 to 5 are implemented.
10. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the computer program is executed by a processor, the steps of the method according to any one of claims 1 to 5 are implemented.
Citation Information
Patent Citations
Configuration method and device for multi-data-source data
CN108052676A