A data collection method, device, equipment and storage medium

By parsing and storing JSON strings in the template library, the spreadsheet development and data acquisition process is simplified, and the problems of complex and poor versatility of spreadsheet template development in the existing technology are solved, and data acquisition efficiency and flexibility are improved.

CN116306537BActive Publication Date: 2025-01-10PEOPLE'S INSURANCE COMPANY OF CHINA
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202310147640.4
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2023-02-20
Publication Date
2025-01-10
Estimated Expiration
2043-02-20

AI Technical Summary

Technical Problem

The development process of existing spreadsheet templates is complicated and cannot be flexibly modified according to business needs, resulting in extremely poor universality of the spreadsheets developed and low data collection efficiency.

Method used

By finding and parsing JSON strings in the template library, generating and storing spreadsheet templates, the data entry party allows the data entry party to edit and upload the spreadsheet, perform verification and parsing, and dynamically splicing JSON strings to complete data collection.

Benefits of technology

It simplifies the spreadsheet development process, reduces professional skills requirements, improves data collection efficiency, and improves the versatility of spreadsheets, allowing flexible modification of templates according to business needs.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN116306537B_ABST
    Figure CN116306537B_ABST
Patent Text Reader

Abstract

The present application discloses a data collection method, which is used to solve the problem that when data is collected based on electronic forms, the development process of custom forms is relatively complicated, and the electronic form structure is single and cannot be flexibly modified according to business needs. The method includes: in response to the template download instruction uploaded by the data entry party, searching for the first JSON string corresponding to the template download instruction in the template library; generating an electronic form template according to the first JSON string, and sending the electronic form template to the data entry party; receiving the electronic form uploaded by the data entry party after editing the electronic form template, and verifying the electronic form; after the verification of the electronic form is passed, parsing the electronic form to obtain a second JSON string corresponding to the electronic form; storing the second JSON string according to the second identifier corresponding to the electronic form, and completing data collection.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the field of computer technology, and in particular to a data acquisition method, device, equipment and storage medium. Background Art

[0002] With the continuous development of computer technology, electronic spreadsheets represented by Excel have gradually replaced traditional paper registration forms and are widely used in corporate business operations.

[0003] In response to different business needs, companies often require spreadsheets to be presented in different formats. In existing electronic form software development, fixed-format spreadsheet templates are usually customized and developed according to business needs, and stored in specific system code packages in the background, and then the table structure of the Excel template is designed by developers. In the JAVA environment, the operation of Excel-related files is generally achieved by parsing and loading a simplified version of the Poor Obfuscation Implementation (POI) class.

[0004] The existing model is labor-intensive and cannot be completed by users independently. In addition, since the existing electronic form templates have already completed the format settings during development, they cannot be modified and customized according to business changes and needs. Since the design and coding is only for a certain fixed format of the form, the structure is rigid and has great limitations. If you want to modify and adjust the electronic form template according to actual business needs using the existing electronic form development method, developers need to develop functions and transform the database, and the code has poor versatility and low automation.

[0005] It can be seen that the existing solutions for data collection using electronic spreadsheets have a relatively complicated process for developing custom spreadsheets and require relatively high skills from the users themselves. In addition, the developed electronic spreadsheets have a single structure and are difficult to modify, resulting in extremely poor versatility of the developed electronic spreadsheets.

[0006] Therefore, there is an urgent need for a method that can efficiently develop electronic spreadsheet templates and use electronic spreadsheets to collect data. Summary of the invention

[0007] The embodiment of the present application provides a data collection method to solve the problem that when performing data collection based on electronic spreadsheets, the custom table development process is relatively complicated, and the structure of the developed electronic spreadsheet is single and cannot be flexibly modified according to business needs, resulting in extremely poor versatility of the developed electronic spreadsheet, which in turn leads to low data collection efficiency.

[0008] The embodiment of the present application also provides a data collection device to solve the problem that when collecting data based on electronic spreadsheets, the custom table development process is relatively complicated, and the developed electronic spreadsheet has a single structure and cannot be flexibly modified according to business needs, resulting in the poor versatility of the developed electronic spreadsheet, which in turn leads to low data collection efficiency.

[0009] The embodiment of the present application also provides a data collection device to solve the problem that when collecting data based on electronic spreadsheets, the custom table development process is relatively complicated, and the developed electronic spreadsheet has a single structure and cannot be flexibly modified according to business needs, resulting in the poor versatility of the developed electronic spreadsheet, which in turn leads to low data collection efficiency.

[0010] The embodiment of the present application also provides a computer-readable storage medium to solve the problem that when collecting data based on electronic spreadsheets, the custom form development process is relatively complicated, and the developed electronic spreadsheet has a single structure and cannot be flexibly modified according to business needs, resulting in the poor versatility of the developed electronic spreadsheet, which in turn leads to low data collection efficiency.

[0011] The present application embodiment adopts the following technical solutions:

[0012] A data collection method comprises: in response to a template download instruction uploaded by a data entry party, searching a template library for a first JSON string corresponding to the template download instruction, wherein the template download instruction carries a first identifier of a spreadsheet template to be downloaded, and the first JSON string stores identifier information of each cell in the spreadsheet template; generating a spreadsheet template according to the first JSON string, and sending the spreadsheet template to the data entry party; receiving a spreadsheet uploaded by the data entry party after editing the spreadsheet template, and verifying the spreadsheet; after the spreadsheet is verified, parsing the spreadsheet to obtain a second JSON string corresponding to the spreadsheet; storing the second JSON string according to a second identifier corresponding to the spreadsheet, and completing data collection.

[0013] A data collection device includes: a search unit, used to respond to a template download instruction uploaded by a data entry party, and search for a first JSON string corresponding to the template download instruction in a template library, wherein the template download instruction carries a first identifier of a spreadsheet template to be downloaded, and the first JSON string stores identifier information of each cell in the spreadsheet template; a table generation unit, used to parse the first JSON string, generate a spreadsheet template, and send the spreadsheet template to the data entry party; a verification unit, used to receive a spreadsheet uploaded by the data entry party after editing the spreadsheet template, and verify the spreadsheet; a parsing unit, used to parse the spreadsheet after the verification of the spreadsheet passes, and obtain a second JSON string corresponding to the spreadsheet; a storage unit, used to store the second JSON string according to the second identifier corresponding to the spreadsheet, to complete data collection.

[0014] A data acquisition device, comprising:

[0015] A processor; and a memory arranged to store computer-executable instructions, wherein the executable instructions, when executed, cause the processor to perform the following operations: in response to a template download instruction uploaded by a data entry party, search a template library for a first JSON string corresponding to the template download instruction, wherein the template download instruction carries a first identifier of a spreadsheet template to be downloaded, and the first JSON string stores identification information of each cell in the spreadsheet template; generate a spreadsheet template according to the first JSON string, and send the spreadsheet template to the data entry party; receive a spreadsheet uploaded by the data entry party after editing the spreadsheet template, and verify the spreadsheet; after the spreadsheet is verified, parse the spreadsheet to obtain a second JSON string corresponding to the spreadsheet; store the second JSON string according to the second identifier corresponding to the spreadsheet, and complete data collection.

[0016] A computer-readable storage medium stores one or more programs, which, when executed by an electronic device including multiple application programs, enable the electronic device to perform the following operations: in response to a template download instruction uploaded by a data entry party, search a template library for a first JSON string corresponding to the template download instruction, wherein the template download instruction carries a first identifier of a spreadsheet template to be downloaded, and the first JSON string stores identification information of each cell in the spreadsheet template; generate a spreadsheet template according to the first JSON string, and send the spreadsheet template to the data entry party; receive a spreadsheet uploaded by the data entry party after editing the spreadsheet template, and verify the spreadsheet; after the spreadsheet is verified, parse the spreadsheet to obtain a second JSON string corresponding to the spreadsheet; store the second JSON string according to a second identifier corresponding to the spreadsheet, and complete data collection.

[0017] At least one of the above technical solutions adopted in the embodiments of the present application can achieve the following beneficial effects:

[0018] By adopting a data collection method provided in an embodiment of the present application, a data collector can design and develop an electronic spreadsheet template for business data statistics according to business needs, and upload the template to a data collection system. After verifying the received electronic spreadsheet template, the data collection system parses the electronic spreadsheet template and dynamically splices it into a JSON string that complies with the specification, and stores the JSON string in a template library. When data collection is required later, the data collector can send the identifier of the pre-set electronic spreadsheet template (for example, the table name) to the data entry party, and then the data entry party can send a template download instruction carrying the template identifier to the data collection system. The data collection system responds to the template download instruction uploaded by the data entry party, searches the template library for the first JSON string corresponding to the template download instruction, and then sends the template download instruction to the data collection system. Dynamically splicing the first JSON string can generate a corresponding electronic form, and send the electronic form to the data entry party. The data entry party can fill in the corresponding data according to the requirements of the data collection party according to the received electronic form template, and re-upload the completed electronic form to the data collection system; the data collection system verifies the received electronic form template to ensure that the data content filled in by the data entry party meets the format and content required by the data collection party, thereby ensuring that the data can be uniformly stored and counted later; after the verification of the electronic form is passed, the data collection system will parse the electronic form to obtain a second JSON string corresponding to the electronic form, and store the second JSON string according to the unique identifier (for example, name) of the electronic form in the template library to complete data collection. Using the data collection method provided in the embodiment of the present application, the data collection party can quickly complete the development and design process for the electronic form template by entering the specified template rules in a specific cell of the electronic form. The electronic form development process is simple, and the professional skills requirements for developers are relatively low, which greatly improves the efficiency of data collection. On the other hand, using the data collection method provided by this solution, since the developed spreadsheet is stored in the template library in the form of a JSON string, the data collection system can dynamically splice the JSON string to obtain the corresponding spreadsheet template at any time according to the needs of the data collection party, and visually display the pre-designed spreadsheet template to the data collection party. The data collection party can then flexibly modify and adjust the spreadsheet template according to business needs, thereby greatly improving the versatility of the spreadsheet. BRIEF DESCRIPTION OF THE DRAWINGS

[0019] The drawings described herein are used to provide a further understanding of the present application and constitute a part of the present application. The illustrative embodiments of the present application and their descriptions are used to explain the present application and do not constitute an improper limitation on the present application. In the drawings:

[0020] Figure 1 A specific flow chart of a data collection method provided in an embodiment of the present application;

[0021] Figure 2 A schematic diagram of the specific structure of a data acquisition device provided in an embodiment of the present application;

[0022] Figure 3 A schematic diagram of the specific structure of a data acquisition device provided in an embodiment of the present application. DETAILED DESCRIPTION

[0023] In order to make the purpose, technical solution and advantages of the present application clearer, the technical solution of the present application will be clearly and completely described below in combination with the specific embodiments of the present application and the corresponding drawings. Obviously, the described embodiments are only part of the embodiments of the present application, not all of the embodiments. Based on the embodiments in the present application, all other embodiments obtained by ordinary technicians in this field without making creative work are within the scope of protection of the present application.

[0024] The executor of the data collection method provided in the embodiment of the present application may be, but is not limited to, at least one of a data collection server, a data management server, a database management device, a financial management system, a financial management system, or an operation and maintenance management server.

[0025] For ease of description, the following takes the execution subject of the method as a data acquisition system as an example to introduce the implementation of the method. It can be understood that the execution subject of the method as a data acquisition system is only an exemplary description and should not be understood as a limitation of the method.

[0026] Specifically, the specific implementation flow diagram of the data collection method provided in this application is as follows: Figure 1 As shown, it mainly includes the following steps:

[0027] Step 11, in response to the template download instruction uploaded by the data entry party, searching the template library for a first JSON string corresponding to the template download instruction;

[0028] The template download instruction carries a first identifier of the electronic form template to be downloaded, and the identifier of the electronic form template can be a template name set for the electronic form template by the data acquisition system when developing the template, or can also be a unique identifier automatically generated for the template by the data acquisition system when storing the electronic form template. The first JSON string stores the identifier information of each cell in the electronic form template.

[0029] In one embodiment, the electronic spreadsheet template stored in the template library of the data collection system is pre-designed and developed by the data collection party according to business needs. In the embodiment of the present application, before executing step 11, the data collection system can receive and store the electronic spreadsheet template uploaded by the data collection party according to the following sub-steps:

[0030] Sub-step 1101, receiving the electronic form template uploaded by the data collector;

[0031] Taking the electronic form used for data collection in this application as an Excel form as an example, in one implementation, the data collector can create a new Excel form locally according to the electronic form template rules, and create an Excel form template for data collection by entering specific information in each cell of the Excel form.

[0032] In one implementation, the data collector can enter the content to be collected in each cell of the first row of the first sheet page of the newly created Excel table, such as address, quarter, month, date, amount, name, gender, age, etc. And the input data type corresponding to the content to be collected can be entered in the corresponding cell of the second row of the first sheet page of the Excel table, for example, the input data type can be a string or a number, etc. In one implementation, 1 can be used to indicate that the input data type is a string, and 2 can be used to indicate that the input data type is a number.

[0033] Assume that the Excel spreadsheet template set by the data collector is as shown in Table 1, which means that the data collector needs to collect five types of data, namely: address, name, amount, gender and age, and the data types of the five types of data to be collected are: address-string, that is, for the address to be collected, the data entry party needs to enter a string to represent it; similarly, name-string, amount-number, gender-string, age-number.

[0034] Table 1Excel table template

[0035] address Name Amount gender age 1 1 2 1 2

[0036] After the data collector completes the creation of the Excel table template and names the Excel table, it uploads the Excel table to the data collection system.

[0037] Sub-step 1102, the data collection system performs format verification on the received electronic form template;

[0038] In order to avoid the problem of electronic spreadsheet template abnormality that may arise due to incorrect filling in by the data collector, in an embodiment of the present application, the data collection system may first perform a format check on the received Excel spreadsheet template before parsing and storing it. In the case where there is content in the cells of the second row but no content in the corresponding cells of the first row, the data collection system will send an error reminder to the data collection party to notify the data collection party that there is an error in the uploaded electronic spreadsheet template and please modify it and upload it again. In the case where there is content in the cells of the first row but no content in the corresponding cells of the second row, the data collection system may also send an error reminder message to the data collection party, or the data collection system may automatically add information to the cell according to preset rules. For example, for the unfilled cells in the second row, the data collection system may set the cell to "1" by default, that is, the data type is a string.

[0039] Sub-step 1103, when it is determined by executing sub-step 1102 that the electronic form model has passed verification, the data collection system may parse the electronic form template and generate a JSON string corresponding to the electronic form template;

[0040] Specifically, the data collection system can name the cells in the first row in sequence as: "col1, col2, col3...coln", and name the cells in the second row in sequence as: "col1 Type, col2 Type, col3Type...coln Type". Then, the data collection system traverses the spreadsheet template, identifies the content corresponding to each cell in the spreadsheet template, and generates a JSON string corresponding to the spreadsheet model.

[0041] Still taking the Excel table template shown in Table 1 as an example, the JSON string obtained by parsing the Excel table template is as follows:

[0042] {

[0043] "excel_module_name_N": {

[0044] "col1": "address",

[0045] "col2": "name",

[0046] "col3": "amount",

[0047] "col4": "Gender",

[0048] "col5": "age",

[0049] "col1Type":"1",

[0050] "col2Type":"1",

[0051] "col3Type":"2",

[0052] "col4Type": "1",

[0053] "col5Type":"2"

[0054] }

[0055] }

[0056] Here, "excel_module_name_N" indicates the name of the spreadsheet template.

[0057] Sub-step 1104, storing the JSON string generated by executing sub-step 1103 in the template library.

[0058] Before storing, the data collection system can set a number for the JSON string according to the number of templates in the current template library, and use the number and the name set by the data collection party for the template as the unique identifier of the JSON string in the template library. At the same time, the data collection system will also associate the unique identifier of the data collection party that uploaded the spreadsheet template and the upload time of the spreadsheet template with the JSON string of the spreadsheet template and save them in the template library for subsequent use.

[0059] It should also be noted that after the data collector uploads the completed spreadsheet template to the data collection system, the data collector can also preview the uploaded spreadsheet template through the data collection system and modify and adjust the spreadsheet template.

[0060] In the embodiment of the present application, the uploaded electronic form can be previewed and modified through the following sub-steps:

[0061] Sub-step 11-a, receiving a template query instruction sent by a data collector;

[0062] The template query instruction carries a third identifier of the electronic form template to be queried, such as a template file name.

[0063] Sub-step 11-b, in response to the query instruction, searching the template library for a third JSON string corresponding to the third identifier;

[0064] At the same time, in order to ensure the security of each spreadsheet template in the template library, after the data collection system queries the corresponding JSON string in response to the query instruction, before any subsequent operations, the data collection system will first authenticate the identity of the data collection party that sent the query instruction. Specifically, the data collection system can obtain the unique identifier of the data collection party that sent the query instruction, and compare it with the unique identifier of the data collection party corresponding to the JSON string to determine whether the user who currently needs to perform a template query is the data collection party that generated the spreadsheet template. Only when the judgment result is yes, can the subsequent operations be continued.

[0065] Sub-step 11-c, generating a corresponding electronic spreadsheet template according to the third JSON string, and feeding back the electronic spreadsheet template to the data collection party for visual display;

[0066] Sub-step 11-d, receiving a modified template uploaded by the data collector after modifying the electronic form template;

[0067] After viewing the table, the data collector can flexibly modify and adjust the current visual display spreadsheet template according to current business needs, such as adding, deleting, reducing, modifying the content of the collected data, or changing the type of data to be collected. After completing the template adjustment, the data collector can re-upload the updated spreadsheet template to the data collection system.

[0068] Sub-step 11-e, parsing the modified template to generate a modified string;

[0069] Sub-step 11-f, modifying and updating the original JSON string stored in the template library according to the modified string.

[0070] Through the above sub-steps, after the development and uploading of the spreadsheet template is completed for the first time, the data collector can also update and adjust the uploaded spreadsheet template at any time through the data collection system according to changes in business needs, which greatly improves the scope of application and flexibility of the spreadsheet template.

[0071] Step 12, generating an electronic spreadsheet template according to the first JSON string queried by executing step 11, and sending the electronic spreadsheet template to the data entry party;

[0072] Step 13, receiving the electronic form uploaded by the data entry party after editing the electronic form template, and verifying the electronic form;

[0073] In order to ensure that the data input by the data entry party meets the requirements of the data collection party, in one embodiment, after receiving the electronic form uploaded by the data entry party, the data collection system will first verify the electronic form. Specifically, in the embodiment of the present application, the data collection system can verify the electronic form according to the following sub-steps:

[0074] Sub-step 1301, determining a second identifier corresponding to the electronic form, and judging whether a JSON string corresponding to the second identifier exists in the template library according to the second identifier;

[0075] In order to ensure the efficiency of data collection and data statistics, the data entry party is generally not allowed to modify the name of the spreadsheet during data entry, that is, it is necessary to ensure that the name of the spreadsheet is consistent with the name of the corresponding spreadsheet template in the template library.

[0076] After receiving the electronic form uploaded by the data entry party, the data collection system can first obtain the file name of the electronic form, and search the template library for the existence of the electronic form template according to the file name. If the judgment result is no, it means that the data entry party has changed the file name of the electronic form, or the data entry party has uploaded an incorrect electronic form, and the data collection system will issue an error reminder to the data entry party; if the judgment result is yes, sub-step 1302 is executed;

[0077] Sub-step 1302, when the judgment result is yes, determining the cell data of the electronic spreadsheet template corresponding to the JSON string according to the JSON string;

[0078] The cell data includes the data type and data format corresponding to each cell in the electronic spreadsheet template. Through the cell data, the data type that the data collector needs to collect and the data format corresponding to each data type can be determined.

[0079] Sub-step 1303, verifying the electronic spreadsheet according to the cell data.

[0080] The data collection system verifies the data type and data format entered by the data entry party in the spreadsheet based on the cell data.

[0081] Step 14, after the electronic form is verified, the electronic form is parsed to obtain a second JSON string corresponding to the electronic form;

[0082] The data collection system traverses the spreadsheet, identifies the content corresponding to each cell in the spreadsheet, and then generates a JSON string corresponding to the spreadsheet.

[0083] If the verification fails, the data collection system will send an error prompt to the data entry party to remind the data entry party to re-download the correct electronic spreadsheet template and enter the data in the correct format.

[0084] Step 15: Store the second JSON string according to the second identifier corresponding to the electronic form to complete data collection.

[0085] In one embodiment, the data collection system can generate an entity class corresponding to the file name (i.e., a certain spreadsheet template) according to the file name corresponding to the spreadsheet, and store the parsed JSON string in the entity class. The subsequent data collection system can store all the JSON strings corresponding to other spreadsheets with the same file name received in the entity class, thereby completing the data collection.

[0086] By adopting a data collection method provided in an embodiment of the present application, a data collector can design and develop an electronic spreadsheet template for business data statistics according to business needs, and upload the template to a data collection system. After verifying the received electronic spreadsheet template, the data collection system parses the electronic spreadsheet template and dynamically splices it into a JSON string that complies with the specification, and stores the JSON string in a template library. When data collection is required later, the data collector can send the identifier of the pre-set electronic spreadsheet template (for example, the table name) to the data entry party, and then the data entry party can send a template download instruction carrying the template identifier to the data collection system. The data collection system responds to the template download instruction uploaded by the data entry party, searches the template library for the first JSON string corresponding to the template download instruction, and then sends the template download instruction to the data collection system. Dynamically splicing the first JSON string can generate a corresponding electronic form, and send the electronic form to the data entry party. The data entry party can fill in the corresponding data according to the requirements of the data collection party according to the received electronic form template, and re-upload the completed electronic form to the data collection system; the data collection system verifies the received electronic form template to ensure that the data content filled in by the data entry party meets the format and content required by the data collection party, thereby ensuring that the data can be uniformly stored and counted later; after the verification of the electronic form is passed, the data collection system will parse the electronic form to obtain a second JSON string corresponding to the electronic form, and store the second JSON string according to the unique identifier (for example, name) of the electronic form in the template library to complete data collection. Using the data collection method provided in the embodiment of the present application, the data collection party can quickly complete the development and design process for the electronic form template by entering the specified template rules in a specific cell of the electronic form. The electronic form development process is simple, and the professional skills requirements for developers are relatively low, which greatly improves the efficiency of data collection. On the other hand, using the data collection method provided by this solution, since the developed spreadsheet is stored in the template library in the form of a JSON string, the data collection system can dynamically splice the JSON string to obtain the corresponding spreadsheet template at any time according to the needs of the data collection party, and visually display the pre-designed spreadsheet template to the data collection party. The data collection party can then flexibly modify and adjust the spreadsheet template according to business needs, thereby greatly improving the versatility of the spreadsheet.

[0087] In one implementation, the present application also provides a data collection device to solve the problem that when collecting data based on electronic forms, the process of developing custom forms is relatively complicated, and the structure of the developed electronic forms is single and cannot be flexibly modified according to business needs, resulting in the poor versatility of the developed electronic forms, which in turn leads to low data collection efficiency. The specific structural diagram of the data collection device is shown in FIG. Figure 2 As shown, it includes: a search unit 21, a table generation unit 22, a verification unit 23, a parsing unit 24 and a storage unit 25.

[0088] The search unit 21 is used to search for a first JSON string corresponding to the template download instruction in the template library in response to the template download instruction uploaded by the data entry party, wherein the template download instruction carries a first identifier of the electronic form template to be downloaded, and the first JSON string stores the identifier information of each cell in the electronic form template;

[0089] A table generating unit 22 is used to parse the first JSON string, generate an electronic table template, and send the electronic table template to the data entry party;

[0090] A verification unit 23, configured to receive an electronic form uploaded by the data entry party after editing the electronic form template, and verify the electronic form;

[0091] A parsing unit 24, configured to parse the electronic form after the electronic form is verified to obtain a second JSON string corresponding to the electronic form;

[0092] The storage unit 25 is used to store the second JSON string according to the second identifier corresponding to the electronic form to complete data collection.

[0093] In one embodiment, the verification unit 23 is specifically used to: determine a second identifier corresponding to the spreadsheet; based on the second identifier, determine whether there is a JSON string corresponding to the second identifier in the template library; when the judgment result is yes, determine the cell data of the spreadsheet template corresponding to the JSON string based on the JSON string, wherein the cell data includes the data type and data format corresponding to each cell in the spreadsheet template; and verify the spreadsheet based on the cell data.

[0094] In one embodiment, it also includes a template storage unit, which is specifically used to: receive the spreadsheet template uploaded by the data collection party, and perform format verification on the spreadsheet template; after the format verification of the spreadsheet template passes, parse the spreadsheet template, generate a JSON string corresponding to the spreadsheet template, and store the JSON string in the template library.

[0095] In one embodiment, it also includes a query unit, which is specifically used to: receive a template query instruction sent by a data collection party, wherein the template query instruction carries a third identifier of the spreadsheet template to be queried; in response to the query instruction, search for a third JSON string corresponding to the third identifier in the template library; generate a corresponding spreadsheet template according to the third JSON string, and feed back the spreadsheet template to the data collection party for visual display.

[0096] In one embodiment, the query unit is also used to: receive a modified template uploaded by the data collector after modifying the electronic form template; parse the modified template to generate a modified string; and modify and update the original JSON string stored in the template library according to the modified string.

[0097] By adopting a data collection device provided in an embodiment of the present application, a data collection party can design and develop an electronic spreadsheet template for business data statistics according to business needs, and upload the template to a data collection system. After verifying the received electronic spreadsheet template, the data collection system parses the electronic spreadsheet template and dynamically splices it into a JSON string that complies with the specification, and stores the JSON string in a template library. When data collection is needed later, the data collection party can send the identifier of the pre-set electronic spreadsheet template (for example, the table name) to the data entry party, and then the data entry party can send a template download instruction carrying the template identifier to the data collection system. The data collection system responds to the template download instruction uploaded by the data entry party, searches the template library for the first JSON string corresponding to the template download instruction, and then sends the template download instruction to the data collection system. Dynamically splicing the first JSON string can generate a corresponding electronic form, and send the electronic form to the data entry party. The data entry party can fill in the corresponding data according to the requirements of the data collection party according to the received electronic form template, and re-upload the completed electronic form to the data collection system; the data collection system verifies the received electronic form template to ensure that the data content filled in by the data entry party meets the format and content required by the data collection party, thereby ensuring that the data can be uniformly stored and counted later; after the verification of the electronic form is passed, the data collection system will parse the electronic form to obtain a second JSON string corresponding to the electronic form, and store the second JSON string according to the unique identifier (for example, name) of the electronic form in the template library to complete data collection. Using the data collection method provided in the embodiment of the present application, the data collection party can quickly complete the development and design process for the electronic form template by entering the specified template rules in a specific cell of the electronic form. The electronic form development process is simple, and the professional skills requirements for developers are relatively low, which greatly improves the efficiency of data collection. On the other hand, using the data collection method provided by this solution, since the developed spreadsheet is stored in the template library in the form of a JSON string, the data collection system can dynamically splice the JSON string to obtain the corresponding spreadsheet template at any time according to the needs of the data collection party, and visually display the pre-designed spreadsheet template to the data collection party. The data collection party can then flexibly modify and adjust the spreadsheet template according to business needs, thereby greatly improving the versatility of the spreadsheet.

[0098] Figure 3 This is a schematic diagram of the structure of an electronic device according to an embodiment of the present application. Figure 3At the hardware level, the electronic device includes a processor, and optionally also includes an internal bus, a network interface, and a memory. The memory may include a memory, such as a high-speed random access memory (RAM), and may also include a non-volatile memory (non-volatile memory), such as at least one disk storage. Of course, the electronic device may also include hardware required for other services.

[0099] The processor, network interface and memory can be interconnected through an internal bus, which can be an ISA (Industry Standard Architecture) bus, a PCI (Peripheral Component Interconnect) bus or an EISA (Extended Industry Standard Architecture) bus. The bus can be divided into an address bus, a data bus, a control bus, etc. For ease of representation, Figure 3 Only one bidirectional arrow is used in the diagram, but this does not mean that there is only one bus or only one type of bus.

[0100] The memory is used to store the program. Specifically, the program may include a program code, and the program code includes a computer operation instruction. The memory may include a memory and a non-volatile memory, and provides instructions and data to the processor.

[0101] The processor reads the corresponding computer program from the non-volatile memory into the memory and then runs it, forming a data acquisition device at the logical level. The processor executes the program stored in the memory and is specifically used to perform the following operations:

[0102] In response to a template download instruction uploaded by a data entry party, a first JSON string corresponding to the template download instruction is searched in a template library, wherein the template download instruction carries a first identifier of a spreadsheet template to be downloaded, and the first JSON string stores identification information of each cell in the spreadsheet template; a spreadsheet template is generated according to the first JSON string, and the spreadsheet template is sent to the data entry party; a spreadsheet uploaded by the data entry party after editing the spreadsheet template is received, and the spreadsheet is verified; after the verification of the spreadsheet is passed, the spreadsheet is parsed to obtain a second JSON string corresponding to the spreadsheet; according to a second identifier corresponding to the spreadsheet, the second JSON string is stored to complete data collection.

[0103] The above application Figure 3 The method performed by the data acquisition electronic device disclosed in the illustrated embodiment can be applied to a processor or implemented by a processor. The processor may be an integrated circuit chip with signal processing capabilities. In the implementation process, each step of the above method can be completed by an integrated logic circuit of hardware in the processor or an instruction in the form of software. The above processor can be a general-purpose processor, including a central processing unit (CPU), a network processor (NP), etc.; it can also be a digital signal processor (DSP), an application-specific integrated circuit (ASIC), a field-programmable gate array (FPGA) or other programmable logic devices, discrete gates or transistor logic devices, discrete hardware components. The methods, steps and logic block diagrams disclosed in the embodiments of the present application can be implemented or executed. The general-purpose processor can be a microprocessor or the processor can also be any conventional processor, etc. The steps of the method disclosed in the embodiments of the present application can be directly embodied as a hardware decoding processor for execution, or a combination of hardware and software modules in the decoding processor for execution. The software module can be located in a storage medium mature in the art such as a random access memory, a flash memory, a read-only memory, a programmable read-only memory, or an electrically erasable programmable memory, a register, etc. The storage medium is located in the memory, and the processor reads the information in the memory and completes the steps of the above method in combination with its hardware.

[0104] Of course, in addition to software implementation methods, the electronic device of the present application does not exclude other implementation methods, such as logic devices or a combination of software and hardware, etc. That is to say, the execution subject of the following processing flow is not limited to each logic unit, but can also be hardware or logic devices.

[0105] The embodiment of the present application also provides a computer-readable storage medium, which stores one or more programs, wherein the one or more programs include instructions, which, when executed by a portable electronic device including a plurality of application programs, enable the portable electronic device to execute Figure 1 The method of the embodiment shown is specifically used to perform the following operations:

[0106] In response to a template download instruction uploaded by a data entry party, a first JSON string corresponding to the template download instruction is searched in a template library, wherein the template download instruction carries a first identifier of a spreadsheet template to be downloaded, and the first JSON string stores identification information of each cell in the spreadsheet template; a spreadsheet template is generated according to the first JSON string, and the spreadsheet template is sent to the data entry party; a spreadsheet uploaded by the data entry party after editing the spreadsheet template is received, and the spreadsheet is verified; after the verification of the spreadsheet is passed, the spreadsheet is parsed to obtain a second JSON string corresponding to the spreadsheet; according to a second identifier corresponding to the spreadsheet, the second JSON string is stored to complete data collection.

[0107] Those skilled in the art will appreciate that embodiments of the present invention may be provided as methods, systems, or computer program products. Therefore, the present invention may take the form of a complete hardware embodiment, a complete software embodiment, or an embodiment combining software and hardware. Moreover, the present invention may take the form of a computer program product implemented on one or more computer-usable storage media (including but not limited to disk storage, CD-ROM, optical storage, etc.) containing computer-usable program code.

[0108] The present invention is described with reference to flowcharts and / or block diagrams of methods, devices (systems), and computer program products according to embodiments of the present invention. It should be understood that each process and / or block in the flowchart and / or block diagram, as well as the combination of processes and / or blocks in the flowchart and / or block diagram, can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, a special-purpose computer, an embedded processor, or other programmable data processing device to produce a machine, so that the instructions executed by the processor of the computer or other programmable data processing device generate instructions for implementing the processes in the flowchart and / or block diagram. Figure 1 A process or multiple processes and / or boxes Figure 1 A device that provides the functions specified in a block or multiple blocks.

[0109] These computer program instructions may also be stored in a computer readable memory capable of directing a computer or other programmable data processing device to operate in a specific manner, so that the instructions stored in the computer readable memory produce an article of manufacture including an instruction device, which implements the process Figure 1 A process or multiple processes and / or boxes Figure 1 A function specified in one or more boxes.

[0110] These computer program instructions can also be loaded onto a computer or other programmable data processing device so that a series of operating steps are executed on the computer or other programmable device to produce a computer-implemented process, thereby providing instructions for implementing the process. Figure 1 A process or multiple processes and / or boxes Figure 1 The steps for the functions specified in one or more boxes.

[0111] In a typical configuration, a computing device includes one or more processors (CPU), input / output interfaces, network interfaces, and memory.

[0112] The memory may include non-permanent storage in a computer-readable medium, random access memory (RAM) and / or non-volatile memory in the form of read-only memory (ROM) or flash RAM. The memory is an example of a computer-readable medium.

[0113] Computer readable media include permanent and non-permanent, removable and non-removable media that can be implemented by any method or technology to store information. Information can be computer readable instructions, data structures, program modules or other data. Examples of computer storage media include, but are not limited to, phase change memory (PRAM), static random access memory (SRAM), dynamic random access memory (DRAM), other types of random access memory (RAM), read-only memory (ROM), electrically erasable programmable read-only memory (EEPROM), flash memory or other memory technology, compact disk read-only memory (CD-ROM), digital versatile disk (DVD) or other optical storage, magnetic cassettes, magnetic tape magnetic disk storage or other magnetic storage devices or any other non-transmission media that can be used to store information that can be accessed by a computing device. As defined herein, computer readable media does not include temporary computer readable media (transitory media), such as modulated data signals and carrier waves.

[0114] It should also be noted that the terms "include", "comprises" or any other variations thereof are intended to cover non-exclusive inclusion, so that a process, method, commodity or device including a series of elements includes not only those elements, but also other elements not explicitly listed, or also includes elements inherent to such process, method, commodity or device. In the absence of more restrictions, the elements defined by the sentence "comprises a ..." do not exclude the existence of other identical elements in the process, method, commodity or device including the elements.

[0115] Those skilled in the art will appreciate that the embodiments of the present application may be provided as methods, systems or computer program products. Therefore, the present application may adopt the form of a complete hardware embodiment, a complete software embodiment or an embodiment in combination with software and hardware. Moreover, the present application may adopt the form of a computer program product implemented on one or more computer-usable storage media (including but not limited to disk storage, CD-ROM, optical storage, etc.) that contain computer-usable program code.

[0116] The above is only an embodiment of the present application and is not intended to limit the present application. For those skilled in the art, the present application may have various changes and variations. Any modification, equivalent replacement, improvement, etc. made within the spirit and principle of the present application should be included in the scope of the claims of the present application.

Claims

1. A data collection method, characterized in that: include: In response to a template download instruction uploaded by a data entry party, searching a template library for a first JSON string corresponding to the template download instruction, wherein the template download instruction carries a first identifier of a spreadsheet template to be downloaded, and the first JSON string stores identifier information of each cell in the spreadsheet template; Generate an electronic spreadsheet template according to the first JSON string, and send the electronic spreadsheet template to the data entry party; Receiving the electronic form uploaded by the data entry party after editing the electronic form template, and verifying the electronic form; After the electronic form is verified, the electronic form is parsed to obtain a second JSON string corresponding to the electronic form; According to the second identifier corresponding to the electronic form, the second JSON string is stored to complete data collection; The verifying of the electronic form specifically includes: Determining a second identifier corresponding to the electronic form; According to the second identifier, determining whether there is a JSON string corresponding to the second identifier in the template library; When the judgment result is negative, an error reminder is issued to the data entry party; When the judgment result is yes, determining the cell data of the electronic spreadsheet template corresponding to the JSON string according to the JSON string, wherein the cell data includes the data type and data format corresponding to each cell in the electronic spreadsheet template; The electronic spreadsheet is verified according to the cell data.

2. The method according to claim 1, characterized in that The method further comprises: Receiving an electronic form template uploaded by a data collector, and performing format verification on the electronic form template, wherein the electronic form template is generated by the data collector by inputting a specific template rule in a specific cell of the electronic form; After the format check of the electronic form template is passed, the electronic form template is parsed to generate a JSON string corresponding to the electronic form template, and the JSON string is stored in a template library.

3. The method according to claim 2, characterized in that Also includes: Receiving a template query instruction sent by a data collector, wherein the template query instruction carries a third identifier of the electronic form template to be queried; In response to the query instruction, searching the template library for a third JSON string corresponding to the third identifier; A corresponding electronic spreadsheet template is generated according to the third JSON string, and the electronic spreadsheet template is fed back to the data collection party for visual display.

4. The method according to claim 3, characterized in that After feeding back the electronic form template to the data collector for visual display, the method further includes: Receiving a modified template uploaded by the data collector after modifying the electronic form template; Parsing the modification template to generate a modification string; The original JSON string stored in the template library is modified and updated according to the modified string.

5. A data acquisition device, characterized in that: include: a search unit, configured to search, in response to a template download instruction uploaded by a data entry party, a first JSON string corresponding to the template download instruction in a template library, wherein the template download instruction carries a first identifier of a spreadsheet template to be downloaded, and the first JSON string stores identifier information of each cell in the spreadsheet template; A table generation unit, used for parsing the first JSON string, generating an electronic table template, and sending the electronic table template to the data entry party; A verification unit, configured to receive an electronic form uploaded by the data entry party after editing the electronic form template, and verify the electronic form; A parsing unit, configured to parse the electronic form after the electronic form is verified to obtain a second JSON string corresponding to the electronic form; A storage unit, used to store the second JSON string according to the second identifier corresponding to the electronic form, to complete data collection; The verification unit is specifically used for: Determining a second identifier corresponding to the electronic form; According to the second identifier, determining whether there is a JSON string corresponding to the second identifier in the template library; When the judgment result is negative, an error reminder is issued to the data entry party; When the judgment result is yes, determining the cell data of the electronic spreadsheet template corresponding to the JSON string according to the JSON string, wherein the cell data includes the data type and data format corresponding to each cell in the electronic spreadsheet template; The electronic spreadsheet is verified according to the cell data.

6. The device according to claim 5, characterized in that It also includes a template storage unit, specifically used for: Receiving the electronic form template uploaded by the data collector, and performing format verification on the electronic form template; After the format check of the electronic form template is passed, the electronic form template is parsed to generate a JSON string corresponding to the electronic form template, and the JSON string is stored in a template library.

7. A data acquisition device, comprising: processor; as well as a memory arranged to store computer executable instructions which, when executed, cause the processor to: In response to a template download instruction uploaded by a data entry party, searching a template library for a first JSON string corresponding to the template download instruction, wherein the template download instruction carries a first identifier of a spreadsheet template to be downloaded, and the first JSON string stores identifier information of each cell in the spreadsheet template; Generate an electronic spreadsheet template according to the first JSON string, and send the electronic spreadsheet template to the data entry party; Receiving the electronic form uploaded by the data entry party after editing the electronic form template, and verifying the electronic form; After the electronic form is verified, the electronic form is parsed to obtain a second JSON string corresponding to the electronic form; According to the second identifier corresponding to the electronic form, the second JSON string is stored to complete data collection; The verifying of the electronic form specifically includes: Determining a second identifier corresponding to the electronic form; According to the second identifier, determining whether there is a JSON string corresponding to the second identifier in the template library; When the judgment result is negative, an error reminder is issued to the data entry party; When the judgment result is yes, determining the cell data of the electronic spreadsheet template corresponding to the JSON string according to the JSON string, wherein the cell data includes the data type and data format corresponding to each cell in the electronic spreadsheet template; The electronic spreadsheet is verified according to the cell data.

8. A computer-readable storage medium storing one or more programs, which, when executed by an electronic device including a plurality of application programs, enable the electronic device to execute the method as claimed in any one of claims 1 to 4.

Citation Information

Patent Citations

  • A data collection method and system based on a dynamic template

    CN109284463A

  • Spreadsheet modeling storage method and device and medium

    CN114416750A