Report management system and report making method
Through the visual report management system, users can design report templates by dragging and dropping, accessing multiple data sources and performing data processing, solving the problem of fixed format and poor interactivity of traditional report systems, and improving report production efficiency and personalized support.
Patent Information
- Application Number
- CN202510511247.8
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-04-23
- Publication Date
- 2025-08-05
AI Technical Summary
Traditional report management systems have problems such as fixed format, single data source, and poor user interaction, which leads to low report production efficiency and difficulty in meeting personalized needs.
It provides a report management system, including a user interface layer, a data processing layer and a data storage layer. It designs report templates through visual drag and drop operations, supports access to multiple data sources, and performs data cleaning, calculation and conversion at the data processing layer to generate report files.
It realizes that users can generate personalized reports through simple drag and drop operations, improves report production efficiency, supports multiple data sources access and processing, and meets users' flexible data statistics and display needs.
Smart Images

Figure CN120428975A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of report management, and in particular to a report management system and a report making method. Background Art
[0002] With the development of information technology, enterprises generate large amounts of data every day. It is becoming increasingly important to accurately and timely generate data statistical reports that meet the management needs of enterprises and provide analytical basis for corporate decision-making. In the operational management of today's enterprises and various organizations, reports are extremely important information carriers and decision-making bases. Traditional report management systems often have many limitations. For example, the report format is fixed, making it difficult to meet the diverse needs of different users; the data source is single and difficult to integrate, making it impossible to flexibly obtain and process data from multiple data sources according to user-specific needs; the user-report system has poor interactivity, making it difficult for ordinary users to independently design, modify, and customize reports. These problems result in either a large amount of manpower and time costs to customize the development of reports in actual applications, or users are forced to use general reports that do not accurately meet their needs, seriously affecting work efficiency and decision-making accuracy. Summary of the Invention
[0003] The purpose of the present invention is to overcome the defects existing in the prior art and provide a report management system and report production method that supports connecting to various types of data sources to obtain fill data for reports, allowing users to complete report element layout, style setting and data mapping through simple drag and drop operations, generate report templates, and automatically process the fill data according to the report template and generate report files.
[0004] In a first aspect, the present invention provides a report management system comprising: a user interface layer, a data processing layer, a data access layer, and a data storage layer; The user interface layer includes HTML, Vue, JQuery and Canvas, which are used to build a visual report template design interface, provide users with graphic drawing tools, event processing, animation, interactive methods of DOM operations and data-driven components, so that users can freely drag and drop various report elements on the report template design interface and set the properties of the elements, generate corresponding report templates, and receive fill data entered by users; The data access layer is used to connect to the data source, extract target data from the data source according to the user's operation instructions, and input the target data into the user interface layer as the filling data of the report template; The data processing layer is used to process and convert the filled data according to the page content in the report template, including cleaning, calculating, classifying and summarizing the filled data, and converting the data format according to the data binding and processing rules set in the report template, so that the filled data is presented in the report template according to the preset rules and a report file is generated; The data storage layer includes a database and a third-party system interface, which is used to provide a data source, save the report file in the database, and interact with the third-party system through the third-party system interface to share the report file in the third-party system.
[0005] Furthermore, the user interface layer is integrated with a report engine, which is used to adjust the text style, apply conditional formatting, adjust the report structure, edit the content and perform data analysis operations on the report file according to the user's operating instructions. The style adjustment includes text alignment, rotation, truncation, overflow, and automatic line wrapping. The report structure adjustment includes inserting, deleting, hiding rows or columns, and merging cells.
[0006] Furthermore, the data access layer includes an API interface, a database driver, and a custom script. The multiple types of data sources include external service data sources and databases. The custom script is used to instruct the data access layer to extract target data and instruct the data processing layer to perform fill data processing, including Sql scripts, Json scripts, Java scripts, and Javascript scripts. When connecting to a data source, the data access layer is specifically used to access the external service data source through Http or Https calling the API interface, access the database through the database driver, extract the target data by executing the custom script, and format, calculate and dynamically generate the target data to obtain the fill data.
[0007] Furthermore, the data processing layer includes a component management module, a chart management module, a template rendering module, a layout calculation module and a script parsing module; The data processing layer is further used to perform tag decomposition, grammatical rule checking, semantic checking, data conversion, script execution and data transmission on the custom script.
[0008] Furthermore, when the data processing layer performs tag decomposition, grammar rule checking and semantic checking on the Sql script, it is specifically used to decompose the Sql script into a first tag including keywords, identifiers, operators, and strings; and check whether the first tag complies with the Sql grammar rules and whether the semantics are correct.
[0009] Furthermore, when the data processing layer performs tag decomposition, syntax rule checking and semantic checking on the Json script, it is specifically used to decompose the Json script into second tags including object start symbols, end symbols, array start symbols, end symbols, key-value pair symbols, strings, numbers, Boolean values and Null; and check whether the second tags comply with the Json syntax rules and whether the semantics are correct.
[0010] Furthermore, when the data processing layer performs tag decomposition, grammar rule checking and semantic checking on the Javascript script, it is specifically used to decompose the Javascript script into a third tag including keywords, identifiers, operators, and punctuation marks, and check whether the third tag complies with the Javascript grammar rules and whether the semantics are correct.
[0011] Furthermore, the report management system further includes an authority control module, which is used to set and verify the user's system identity and manage the operation authority granted by the user's system identity.
[0012] Furthermore, the report management system also includes a template library, which is used to store system preset report templates and user-generated report templates.
[0013] In a second aspect, the present invention provides a report generation method applicable to the report management system described in any one of the first aspects, comprising: Receive the relevant information of the configuration data source input by the user and determine the source method of the data; Receive the data screening conditions entered by the user and determine the fill data that needs to be obtained; Create a report template according to the user's operation instructions, wherein the report template includes the binding relationship between data and report elements and the presentation method of data in the report; Calling corresponding data processing rules according to the binding relationship between the data and the report elements in the report template to perform corresponding data processing operations on the filling data to obtain processed filling data; The processed filled data is written into the report template in a corresponding format according to the presentation mode of the data in the report template to generate a report file.
[0014] The advantages and beneficial effects of the present invention are as follows: the present invention provides a visual report design tool that realizes rich data applications through interactive methods such as graphic drawing tools, event processing, animation, and Dom operations, allowing users to complete the creation of report templates through simple drag-and-drop operations, and can flexibly meet the user's personalized data statistics and display needs. At the same time, it can access multiple data sources to automatically obtain the fill-in data required by the user, and the fill-in data is processed and converted by the data processing layer according to the page content in the report template. Report files can be generated without the user manually processing the data, and reports can be quickly created and adjusted through templates without having to design from scratch. Report production can be completed conveniently and quickly, thereby improving report production efficiency. BRIEF DESCRIPTION OF THE DRAWINGS
[0015] Figure 1 This is a structural diagram of the report management system of the present invention; Figure 2 Schematic diagram of the flow of the report preparation method of the present invention. DETAILED DESCRIPTION
[0016] The following embodiments are further described in conjunction with the accompanying drawings and examples. The following embodiments are only used to more clearly illustrate the technical solutions of the present invention and are not intended to limit the scope of protection of the present invention.
[0017] according to Figure 1 As shown, the present invention discloses a report management system, which includes: a user interface layer, a data processing layer, a data access layer, and a data storage layer; the user interface layer includes HTML, Vue, jQuery, and Canvas, and is used to build a visual report template design interface, providing users with graphic drawing tools, event processing, animation, Dom operation interaction methods, and data-driven components, so that users can freely drag and drop various report elements on the report template design interface and set the attributes of the elements to generate corresponding report templates and receive user-entered fill data; the data access layer is used to connect to the data source, extract target data from the data source according to the user's operation instructions, and input it into the user interface layer as fill data for the report template; the data processing layer is used to process and convert the fill data according to the page content in the report template, including cleaning, calculating, classifying and summarizing the fill data, and converting the data format according to the data binding and processing rules set in the report template, so that the fill data is presented in the report template according to preset rules and a report file is generated; the data storage layer includes a database and a third-party system interface, and is used to provide a data source, save the report file in the database, and interact with the third-party system through the third-party system interface to share the report file with the third-party system.
[0018] HTML is the carrier of page content and structure, defining the page structure and static content of the user interface layer. Vue serves as the front-end framework for building the interactive interface of the user interface layer. The JavaScript tool library is used to simplify DOM operations and event handling. Canvas is the API (Application Programming Interface) of the drawing tool, which can dynamically render graphics. The user interface layer, which includes HTML, Vue, jQuery, and Canvas, allows users to freely drag and drop various report elements such as tables, charts (bar charts, line charts, pie charts, etc.), text boxes, etc. on the user interface, and set the properties of these elements, including position, size, color, font, data binding, etc. The system has a variety of preset report templates built in, and users can also customize them based on these templates or create completely new report templates from scratch.
[0019] The data access layer extracts the fill-in data used to create reports from the connected data source and inputs it into the user interface layer. Users can configure the source of the required data according to their needs, including data source type, authentication information (such as user name, password, token, etc.), connection string, data filtering conditions, etc., so that the system can accurately obtain the required data.
[0020] The data processing layer processes and converts the fill-in data input by the user interface layer and the static page content of the report template. The fill-in data and the static page include element layout and style, data calculation method, data binding relationship, conditional judgment and loop output control logic, page cache mechanism, etc. The data processing layer can clean the data (such as removing noise data, duplicate data, etc.), calculate (such as sum, average, extreme value, count, etc.), classify and summarize, and convert data format (such as data format exchange, date format conversion, numerical precision adjustment, etc.) according to the data binding and processing rules set in the report template to ensure that the fill-in data can be accurately and appropriately presented in the report template.
[0021] Based on the user-designed report template and processed data, the system generates the final report file. Report files can be formatted in a variety of formats, such as Excel, PDF, and HTML. Before generating a report, users can preview the report to see how it will look. If any issues are found, they can return to the report template design interface to make adjustments.
[0022] Databases in the data storage layer include MySQL, Oracle, Sqlserver, Mongodb, and Redis. These databases can be used to persist completed report files to storage media, and can also serve as access data sources to provide fill-in data for report templates, allowing users to directly enter fill-in data into the user interface layer to create reports. For example, persistent data storage in the database ensures that data is not lost due to system restarts or failures, supports complex data queries and aggregation operations, and accelerates data retrieval efficiency through reasonable data organization and indexing strategies. Third-party systems can provide a source of fill-in data, and by interacting with third-party systems, data can be shared between different platforms and devices without having to understand the internal workings of the third-party system, simplifying the data exchange process.
[0023] The present invention provides a visual report design tool that enables rich data applications through interactive methods such as graphic drawing tools, event processing, animation, and Dom operations. It allows users to complete the creation of report templates through simple drag-and-drop operations, and can flexibly meet users' personalized data statistics and display needs. At the same time, it can access multiple data sources to automatically obtain the fill data required by the user. The fill data is processed and converted by the data processing layer based on the page content in the report template. Report files can be generated without the user manually processing the data. In addition, reports can be quickly created and adjusted through templates without having to design from scratch. Report creation can be completed conveniently and quickly, improving report creation efficiency.
[0024] To provide users with an easy-to-use online spreadsheet solution, allowing multiple users to work on a single document simultaneously and synchronize their changes in real time, ensuring smooth collaboration among team members, a further preferred embodiment integrates a report engine into the user interface layer. The report engine is used to adjust text styles, apply conditional formatting, adjust report structure, edit content, and perform data analysis operations on report files based on user instructions. Style adjustments include text alignment, rotation, truncation, overflow, and word wrap, while report structure adjustments include inserting, deleting, hiding rows or columns, and merging cells. It also includes a large number of built-in functions such as text processing, date and time, and reference lookup to meet daily data analysis needs. It can create various types of charts, such as bar charts, line charts, and pie charts, and allows users to customize chart styles.
[0025] In order to enable users to freely and conveniently access data used to create reports to the report management system and obtain high-quality filling data, a further preferred technical solution is that the data access layer includes an API interface, a database driver and a custom script. The various types of data sources include external service data sources and databases. The custom script is used to instruct the data access layer to extract target data and instruct the data processing layer to process the filling data, including Sql (Structured Query Language) scripts, Json (JavaScript Object Notation) scripts, Java scripts and Javascript scripts; when connecting to the data source, the data access layer is specifically used to access the external service data source through Http or Https calling the API interface, access the database through the database driver, extract the target data by executing the custom script, and format, calculate and dynamically generate the target data to obtain the filling data.
[0026] SQL scripts are used for database management and operations, Json scripts are used for data transmission between data sources and systems, Java scripts are used for data processing and automation tasks, and Javascript scripts are used to implement dynamic interaction logic.
[0027] In order to ensure that the filled data can be accurately and appropriately presented in the report template, a further preferred technical solution is that the data processing layer will filter, calculate and map the filled data in the report template. For example, the front-end control Vue (such as drop-down lists, date selectors, text box contents, etc.) receives user input as part of the filtering conditions, and filters out data subsets that meet the requirements according to specific conditions; adapts and is compatible with Json data in different formats returned by different API interfaces; dynamically adjusts record rows and columns according to different data subsets; performs mathematical operations such as summation, average, count, extreme value, or row and column aggregation operations on the data in the data subset; references values in other workbooks or cells, and calls external functions to perform complex calculation tasks; controls the dynamic changes of cell background colors and dynamic loading of charts according to specific business logic, etc.
[0028] In order to modularize the data processing layer and ensure that the custom scripts can be executed correctly, a further preferred technical solution is that the data processing layer includes a component management module, a chart management module, a template rendering module, a layout calculation module and a script parsing module; the data processing layer is also used to perform tag decomposition, syntax rule checking, semantic checking, data conversion, script execution and data transmission on the custom scripts.
[0029] In order to ensure that the SQL script can be executed correctly, a further preferred technical solution is that when the data processing layer performs token decomposition, syntax rule checking and semantic checking on the SQL script, it is specifically used to decompose the SQL script into a first token including keywords, identifiers, operators, and strings; and check whether the first token complies with the SQL syntax rules and whether the semantics are correct.
[0030] The data processing layer breaks down the input SQL script into tokens such as keywords, identifiers, operators, and strings. It then checks whether the tokens conform to SQL syntax rules and are semantically correct, for example, whether table and column names exist and whether data types match. It then optimizes the SQL statement to improve query performance, selecting the most efficient execution path. This includes selecting appropriate indexes, adjusting join order, and rewriting queries. Finally, it executes the query, reads and processes the data, and returns the query results. SQL scripts can be used to define new database and table structures and execute complex data queries, including multi-table joins, data filtering, and result set sorting and grouping.
[0031] In order to ensure that the Json script can be executed correctly, a further preferred technical solution is that the data processing layer is used to decompose the Json script into second tags including object start symbols, end symbols, array start symbols, end symbols, key-value pair symbols, strings, numbers, Boolean values and Null when performing tag decomposition, syntax rule checking and semantic checking on the Json script; and check whether the second tags comply with the Json syntax rules and whether the semantics are correct.
[0032] The data processing layer breaks down the input JSON script into markers such as object start and end symbols, array start and end symbols, symbols in key-value pairs, strings, numbers, Boolean values, and Null. It then checks whether the markers conform to JSON syntax rules and are semantically correct, such as whether the key name is a valid string, whether the value is within the legal range, and whether the Boolean value is True or False. It then converts the structure and logical relationships of the JSON data into native objects in the target programming language, such as Object and Array. If any non-compliant JSON code is encountered during the parsing process, an error is thrown and detailed error information is provided to help developers quickly identify and resolve the issue. JSON scripts can be used to define complex data models, such as user information, order details, and product lists.
[0033] In order to enable the system to write batch processing tasks, a further preferred technical solution is that the data processing layer will dynamically load and execute Java scripts. Batch processing tasks such as file processing, data conversion, scheduled tasks, etc. can be written through Java scripts, and personalized page elements and integration with other systems can be dynamically generated based on user input or database query results.
[0034] In order to ensure that the Javascript script can be executed correctly, a further preferred technical solution is that when the data processing layer performs token decomposition, grammatical rule checking and semantic checking on the Javascript script, it is specifically used to decompose the Javascript script into a third token including keywords, identifiers, operators, and punctuation marks, and check whether the third token complies with the Javascript grammatical rules and whether the semantics are correct.
[0035] The data processing layer breaks down the input Javascript script into tokens such as keywords, identifiers, operators, and punctuation marks. It then checks whether the tokens conform to Javascript syntax rules and are semantically correct, for example, checking for duplicate variable declarations, legal function calls, and type matching. It also handles optimization tasks such as constant folding and inline expansion. It then converts the structure and logical relationships of the Javascript data into an intermediate representation and compiles it into bytecode or machine code. Finally, it executes the bytecode or machine code line by line based on the current environment's state (such as variable values and scope chains). Javascript scripts can dynamically modify web page content and structure without reloading the entire page, monitor and respond to various user actions such as clicks, keyboard input, and scrolling, create complex animations and visual effects, and provide corresponding functions or styles based on different browsers.
[0036] In order to ensure the data security and integrity of the report management system and achieve fine-grained operation control, a further preferred technical solution is that the report management system also includes a permission control module, which is used to set and verify the user's system identity and manage the operation permissions granted to the user's system identity.
[0037] The permission control module is used for system identity authentication. Only verified legitimate users can access system resources. For example, when communicating with the front-end or back-end, or connecting to network services to retrieve system data, the authentication mechanism verifies the user's identity by checking the credentials (username, password, token, etc.). Once the user's identity is verified, the system determines which resources the user can access or which operations they can perform within the validity period based on pre-defined permission rules.
[0038] The permission control module can also manage user permissions and set different user roles, such as administrator, report designer, report viewer, etc. Each role is given different operating permissions. For example, the administrator can comprehensively manage the entire report management system, including adding, deleting, modifying data sources, user account management, etc.; the report designer can only design and modify report templates; the report viewer can only view the generated reports but cannot perform editing operations, etc.
[0039] In order to facilitate rapid generation of report templates, a further preferred technical solution is that the report management system further includes a template library, which is used to store system preset report templates and user-generated report templates.
[0040] All report templates are stored in a template library, allowing users to quickly create the reports they need. When business needs change, existing templates can be adjusted to quickly adapt. The template library supports features such as automatic data filling and dynamic content updates. For example, using parameterized fields and data binding technology, users only need to enter a small amount of information, and the system will automatically generate a complete report.
[0041] according to Figure 2 As shown, the present invention discloses a report management method, which is applicable to the report management system introduced in the above embodiment, including: S201: Receive relevant information of configuring a data source input by a user, and determine the source mode of the data.
[0042] After accessing the report management system, users configure data source information in the data access layer to determine the data source method. In step SS1, data source types are divided into two categories: HTTP-based API interface configuration and database-based configuration. Supported databases include MySQL, Oracle, Sqlserver, MongoDB, and Redis.
[0043] In S201, after selecting Http as the data source type, fill in the data source code, data source name, data source description, request method, request path, request header, request body, authentication type, Token expiration time and parameter name. After the parameters are configured, you can click the Test button to verify whether the API interface call is successful.
[0044] In S201, after selecting the database as the data source type, fill in the data source code, data source name, data source description, driver type, connection string, user name and password. After the parameters are configured, you can click the test button to verify whether the database connection is successful.
[0045] S202: Receive data screening conditions input by the user and determine the filling data to be obtained.
[0046] Set data filtering conditions in the data access layer to determine the range of data to be obtained.
[0047] In S202, after selecting Http for the dataset type, select whether identity authentication is required. If identity authentication is required, select the data source code created in step S201. If identity authentication is not required, do not select the data source code created in step 201. Then fill in the dataset code, dataset name, dataset description, request method, request path, request header, and request body. Add the parameters required to call the API interface and set the parameter name and parameter description. Select the data type, including character, number, date, object, array, or function. After the interface is configured, you can add a Json script to output the data in a specified format, such as array, string, object, etc. After adding the script, you can use the Test button to verify whether the API interface call reports an error and view the data returned by the interface. In S202, after selecting the database as the dataset type, select the data source code created in step S201, then fill in the dataset code, dataset name and dataset description, add the Sql script for query or statistics, add parameters as report query conditions, and set the parameter name and parameter description, select the data type and query condition control type, including text box, time box, single-select drop-down box, multi-select drop-down box, cascade drop-down box, check box, etc. After configuration, you can use the test button to verify whether the Sql script is executed successfully and view the data output after execution.
[0048] In S202, after selecting script as the dataset type, fill in the dataset code, dataset name, and dataset description. After selecting the script type, add the script file to be executed. After adding the script file, you can click the test button to verify whether the script execution reports an error.
[0049] S203: Create a report template according to the user's operation instruction. The report template includes the binding relationship between data and report elements and the presentation method of data in the report.
[0050] In the user interface, use the system's visual design tools to create report templates. You can start with a blank page or modify a report template from the template library. By dragging report elements to designated locations and setting their properties, you can establish binding relationships between data and report elements and determine how the data will be presented in the report.
[0051] In S203, the dataset created in step S202 is added to the dataset management, and the dataset is dragged into a blank cell to complete data binding.
[0052] In S203, you can use the system's built-in data sets and select methods in blank cells, including meter reading records, energy consumption statistics, indicator calculations, reported data, trend data, etc. Select data statistical dimensions such as daily, monthly, annual, cumulative, year-on-year, quarter-on-quarter, shift, etc. Select the gateway and meter to complete data binding.
[0053] In S203, different API interfaces return different Json data formats, which can be compatible with Json data of different formats and output the data set required for the custom report. The method for adapting the Json format data returned by the API interface includes: a. using JsonNode to parse and convert the Json data returned by the interface in a tree structure to facilitate flexible and efficient access and modification of the Json data; b. parsing the placeholder content as a path to obtain the JsonNode data; c. traversing the tree structure data of the JsonNode and obtaining data according to the path parsed by the placeholder content; d. reorganizing the obtained data into the data format required for the custom report.
[0054] In S203, the record rows and columns returned by different data sets are not fixed. You can choose to automatically expand to determine whether the table expands horizontally or vertically. This is used to dynamically load the header and record rows of a fixed table when the number of data sets is uncertain. The method of automatic table expansion includes: a. obtaining the total number of rows and columns in the data set, b. determining whether the table needs to add rows or columns based on the horizontal expansion or vertical expansion setting. If vertical expansion is set, the rows of the table are expanded; if horizontal expansion is set, the columns of the table are expanded, c. calculating the difference between the rows and columns of the data set records and the rows and columns in the report template to determine the values that need to be expanded. If there are merged cells in the table, first calculate the row and column values of the merged cells, and then calculate the row and column values that actually need to be expanded, d. expand the cells according to the calculated expansion value.
[0055] In S203, multiple cells need to be jointly calculated, including multi-cell joint calculations in the same workbook and joint calculations of cells in different workbooks. Select a function in a cell and use the cells that need to be jointly calculated as input parameters to complete calculations such as sum, average, accumulation, and maximum value. You can use another function as a parameter within a function, or combine logical functions to create conditional calculation logic. You can also select an array formula to form an array of data from multiple cells, operate on the data of multiple cells in one cell, and return a single result. In S203, you can add chart displays, including pie charts, line charts, and bar charts, select the chart type, select the data type to fill the chart, including meter reading records, energy consumption statistics, trend data, etc., and select the data statistical dimension, such as daily, monthly, annual, year-on-year, quarter-on-quarter, etc., to complete data binding.
[0056] S204 : Call corresponding data processing rules according to the binding relationship between the data and the report elements in the report template to perform corresponding data processing operations on the filling data to obtain processed filling data.
[0057] After the report template is designed, the data processing layer automatically calls the data processing and conversion module to process the data obtained from the data source according to the data binding rules in the template. According to the user-defined cleaning, calculation, conversion and other rules, a series of operations are performed on the data to obtain the processed data suitable for report generation.
[0058] S205 , writing the processed filled data into the report template in a corresponding format according to the presentation mode of the data in the report template, and generating a report file.
[0059] Before generating a report, users can preview it to check whether the report's layout, data accuracy, and other aspects meet their requirements. If any issues are found, they can return to S203 to make corrections. If all is correct, the final report file can be generated. Through the data storage layer, users can choose to export and save the report locally, publish it to a designated third-party system, or push it to designated users, depending on their needs.
[0060] The above is only a preferred embodiment of the present invention. It should be pointed out that for ordinary technicians in this technical field, several improvements and modifications can be made without departing from the technical principles of the present invention. These improvements and modifications should also be regarded as within the scope of protection of the present invention.
Claims
1. A report management system, characterized in that: Includes: user interface layer, data processing layer, data access layer and data storage layer; The user interface layer includes HTML, Vue, JQuery and Canvas, which are used to build a visual report template design interface, provide users with graphic drawing tools, event processing, animation, interactive methods of DOM operations and data-driven components, so that users can freely drag and drop various report elements on the report template design interface and set the properties of the elements, generate corresponding report templates, and receive fill data entered by users; The data access layer is used to connect to the data source, extract target data from the data source according to the user's operation instructions, and input the target data into the user interface layer as the filling data of the report template; The data processing layer is used to process and convert the filled data according to the page content in the report template, including cleaning, calculating, classifying and summarizing the filled data, and converting the data format according to the data binding and processing rules set in the report template, so that the filled data is presented in the report template according to the preset rules and a report file is generated; The data storage layer includes a database and a third-party system interface, which is used to provide a data source, save the report file in the database, and interact with the third-party system through the third-party system interface to share the report file in the third-party system.
2. The report management system according to claim 1, characterized in that: The user interface layer is integrated with a report engine, which is used to adjust the text style, apply conditional formatting, adjust the report structure, edit the content and perform data analysis operations on the report file according to the user's operating instructions. The style adjustment includes text alignment, rotation, truncation, overflow, and automatic line wrapping. The report structure adjustment includes inserting, deleting, hiding rows or columns, and merging cells.
3. The report management system according to claim 1, characterized in that: The data access layer includes an API interface, a database driver, and a custom script. The multiple types of data sources include external service data sources and databases. The custom script is used to instruct the data access layer to extract target data and instruct the data processing layer to perform fill data processing, including Sql scripts, Json scripts, Java scripts, and Javascript scripts; When connecting to a data source, the data access layer is specifically used to access the external service data source through Http or Https calling the API interface, access the database through the database driver, extract the target data by executing the custom script, and format, calculate and dynamically generate the target data to obtain the fill data.
4. The report management system according to claim 3, characterized in that: The data processing layer includes a component management module, a chart management module, a template rendering module, a layout calculation module and a script parsing module; The data processing layer is further used to perform tag decomposition, grammatical rule checking, semantic checking, data conversion, script execution and data transmission on the custom script.
5. The report management system according to claim 4, characterized in that: When the data processing layer performs token decomposition, grammatical rule checking and semantic checking on the Sql script, it is specifically used to decompose the Sql script into first tokens including keywords, identifiers, operators and character strings; and check whether the first tokens comply with the Sql grammatical rules and whether the semantics are correct.
6. The report management system according to claim 4, characterized in that: When the data processing layer performs tag decomposition, syntax rule checking and semantic checking on the Json script, it is specifically used to decompose the Json script into second tags including object start symbols, end symbols, array start symbols, end symbols, key-value pair symbols, strings, numbers, Boolean values and Null; and check whether the second tags comply with the Json syntax rules and whether the semantics are correct.
7. The report management system according to claim 4, characterized in that: When performing token decomposition, grammatical rule checking and semantic checking on a Javascript script, the data processing layer is specifically used to decompose the Javascript script into third tokens including keywords, identifiers, operators and punctuation marks, and check whether the third tokens comply with the Javascript grammatical rules and whether the semantics are correct.
8. The report management system according to claim 1, characterized in that: The report management system further comprises an authority control module, which is used to set and verify the system identity of the user and manage the operation authority granted by the system identity of the user.
9. The report management system according to claim 1, characterized in that: The report management system further comprises a template library, which is used to store system preset report templates and user generated report templates.
10. A report generation method, applicable to the report management system according to any one of claims 1 to 9, characterized in that: include: Receive the relevant information of the configuration data source input by the user and determine the source method of the data; Receive the data screening conditions entered by the user and determine the fill data that needs to be obtained; Create a report template according to the user's operation instructions, wherein the report template includes the binding relationship between data and report elements and the presentation method of data in the report; Calling corresponding data processing rules according to the binding relationship between the data and the report elements in the report template to perform corresponding data processing operations on the filling data to obtain processed filling data; The processed filled data is written into the report template in a corresponding format according to the presentation mode of the data in the report template to generate a report file.
Citation Information
Cited By
Method for realizing draggable custom visual report
CN121578922A
