CN111090976A - Method and device for generating inspection document based on dynamic data - Google Patents

Method and device for generating inspection document based on dynamic data Download PDF

Info

Publication number
CN111090976A
CN111090976A CN201911309482.8A CN201911309482A CN111090976A CN 111090976 A CN111090976 A CN 111090976A CN 201911309482 A CN201911309482 A CN 201911309482A CN 111090976 A CN111090976 A CN 111090976A
Authority
CN
China
Prior art keywords
document
dynamic
verification
content
dynamic content
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Granted
Application number
CN201911309482.8A
Other languages
Chinese (zh)
Other versions
CN111090976B (en
Inventor
黄希发
张学谦
洪扬
宋雪阳
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
CHINA INSTITUTE OF SPORT SCIENCE
Original Assignee
CHINA INSTITUTE OF SPORT SCIENCE
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by CHINA INSTITUTE OF SPORT SCIENCE filed Critical CHINA INSTITUTE OF SPORT SCIENCE
Priority to CN201911309482.8A priority Critical patent/CN111090976B/en
Publication of CN111090976A publication Critical patent/CN111090976A/en
Application granted granted Critical
Publication of CN111090976B publication Critical patent/CN111090976B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Landscapes

  • Document Processing Apparatus (AREA)

Abstract

本发明公开了基于动态数据的检验文档生成方法,包括:确定动态内容的表达规则;建立文档模板,所述文档模板包括动态内容名称和与动态内容名称对应的待填充区域;遍历资源文件,将所述资源文件中与所述表达规则匹配的数据作为动态内容,并填充至所述待填充区域,生成检验文档。本发明还提供了基于动态数据的检验文档生成装置。本发明在文档内容或文档格式发生变化时,无需程序员修改程序,操作简便。

Figure 201911309482

The invention discloses a method for generating an inspection document based on dynamic data, which includes: determining expression rules of dynamic content; establishing a document template, wherein the document template includes a dynamic content name and an area to be filled corresponding to the dynamic content name; The data in the resource file that matches the expression rule is used as dynamic content, and is filled into the to-be-filled area to generate a verification document. The invention also provides an inspection document generation device based on dynamic data. When the content of the document or the format of the document changes, the present invention does not need the programmer to modify the program, and the operation is simple.

Figure 201911309482

Description

Method and device for generating inspection document based on dynamic data
Technical Field
The present invention relates to the field of computer software. More particularly, the present invention relates to a verification document generation method and apparatus based on dynamic data.
Background
In the process of checking and checking in stadiums, an official document showing the checking/checking result is often required to be issued to a checked unit, and the document is printed into a paper document and then signed and stamped to be sent to the checked unit. In the specific inspection process, although the inspection process is basically the same for each different stadium, the inspection process is performed by submitting an inspection request book, signing an inspection contract, specifying an inspection process plan, recording a field inspection result, rectifying and verifying rectification information, issuing an inspection result and a report, and the like, the contents of the information of each stadium and the result of the field inspection are greatly different, so that the contents of the inspection report issued for the stadium need to have the corresponding contents according to the type of the stadium.
The traditional report content is originally written by staff, but with the progressive informatization, the function of generating documents (reports) by a system appears: it is common practice to call the document contents dynamically built part by program from the underlying API of a document management program (usually a word or the like program) according to the contents and format of the final document. But can only be modified by programmers familiar with this operation due to the generally lower level of the API of the document manager. When the content of the document or the format of the document is changed, a new verification document can be generated only after a programmer writes or modifies the program, and the operation is complex, long and high in cost. Therefore, it is desirable to design a technical solution that can overcome the above-mentioned drawbacks to a certain extent.
Disclosure of Invention
The invention aims to provide a method and a device for generating a check document based on dynamic data, which do not need a programmer to modify a program when the content or format of the document changes and are simple and convenient to operate.
To achieve these objects and other advantages in accordance with the purpose of the invention, there is provided a verification document generation method based on dynamic data, including:
determining an expression rule of the dynamic content;
establishing a document template, wherein the document template comprises a dynamic content name and a region to be filled corresponding to the dynamic content name;
and traversing the resource file, taking the data matched with the expression rule in the resource file as dynamic content, and filling the dynamic content into the area to be filled to generate a check document.
Preferably, in the method for generating a test document based on dynamic data, the resource file at least includes a test order, test contract information, a test flow plan, a field test result, correction information, a test result, and report information.
Preferably, in the verification document generation method based on dynamic data, the dynamic content has a preset format;
and converting the data matched with the expression rule in the resource file into a preset format and using the preset format as dynamic content.
Preferably, in the method for generating a verification document based on dynamic data, the regions to be filled of the blank document template are filled with placeholders corresponding to dynamic content one to one;
in populating the dynamic content, the placeholders are replaced with the dynamic content.
Preferably, the verification document generation method based on dynamic data further includes:
after the verification document is generated, the verification document is electronically signed.
Preferably, the verification document generation method based on dynamic data further includes:
when the resource file is traversed each time, writing each dynamic content into a first intermediate file respectively, and storing the first intermediate file;
acquiring a storage path of the first intermediate file, and generating a first link in the corresponding region to be filled according to the storage path;
after detecting the modification operation on the resource file each time, acquiring the modification content of each dynamic content, writing the modification content into a second intermediate file, and storing the second intermediate file;
acquiring a storage path of the second intermediate file, and generating a second link in the corresponding region to be filled according to the storage path;
and receiving a click command of the first link or the second link, and filling the corresponding content of the first intermediate file or the second intermediate file into the corresponding area to be filled.
The invention also provides a verification document generation device based on dynamic data, which comprises:
a processor;
a memory storing executable instructions;
wherein the processor is configured to execute the executable instructions to perform the method for verification document generation based on dynamic data.
The invention at least comprises the following beneficial effects:
aiming at the practical situations that the inspection flow of the stadium is fixed, but the inspected data contents are different, the project data items change greatly, the types (texts, numbers, pictures) and the like of all the data items are different, the invention sequentially determines the expression rule of the dynamic content, establishes a document template, traverses the resource file, takes the data matched with the expression rule in the resource file as the dynamic content, and fills the dynamic content into the area to be filled to generate the inspection document. The invention can be operated by non-professional IT personnel with general IT skills when the content or format of a newly added inspection item or an inspection report changes, and has the advantages of simple and convenient operation, short time consumption and low cost.
Additional advantages, objects, and features of the invention will be set forth in part in the description which follows and in part will become apparent to those having ordinary skill in the art upon examination of the following or may be learned from practice of the invention.
Drawings
FIG. 1 is a flow chart of the present invention.
Detailed Description
The present invention is further described in detail below with reference to the attached drawings so that those skilled in the art can implement the invention by referring to the description text.
It will be understood that terms such as "having," "including," and "comprising," as used herein, do not preclude the presence or addition of one or more other elements or groups thereof.
In one embodiment, as shown in fig. 1, a method for generating a verification document based on dynamic data includes:
determining an expression rule of the dynamic content;
establishing a document template, wherein the document template comprises a dynamic content name and a region to be filled corresponding to the dynamic content name;
and traversing the resource file, taking the data matched with the expression rule in the resource file as dynamic content, and filling the dynamic content into the area to be filled to generate a check document.
In the above technical solution, the dynamic content refers to content of each data entry in the inspection document, and changes with different resource files. The expression rule can generally represent the expression mode of each data item, for example, the expression mode of the test date is year, month and day, the telephone number, address, company name, test item, test result and the like also have the specific expression mode thereof, and can be determined according to statistics or experience. The document template comprises a dynamic content name meeting the current requirement and a region to be filled for filling the dynamic content, and can be customized by a user according to the requirement of the user. The resource file is a source file of the inspection document and comprises data required by the inspection document, and the data which accords with the expression rule is filled into the region to be filled as dynamic content by traversing the resource file until all the regions to be filled in the document template are filled.
It can be seen that the technical scheme defines the expression rule in advance, then customizes the document template, and generates the inspection document by traversing the resource file and filling the document template. When the content or format of the newly added inspection item or the inspection report changes, a non-professional IT person with general IT skills can edit or modify the document template, so that the operation is simple and convenient, the time consumption is short, and the cost is low.
In another technical solution, in the method for generating a test document based on dynamic data, the resource file at least includes a test order, test contract information, a test flow plan, a field test result, correction information, a test result, and report information. The resource file is used for providing dynamic content for the verification document, and the attribute of the information and the data type of the attribute are defined in advance, wherein the data type of the attribute supports text strings, integers, decimal numbers, dates, time, pictures and documents.
In another technical solution, in the method for generating a test document based on dynamic data, the dynamic content has a preset format;
and converting the data matched with the expression rule in the resource file into a preset format and using the preset format as dynamic content. Here, the dynamic content is converted into a preset format of the area to be filled, such as attributes and data types specified in the above technical solution. And then filling the region to be filled with the inspection file, wherein the technical scheme ensures that the obtained inspection file is more in line with the actual requirement.
In another technical scheme, in the inspection document generation method based on dynamic data, placeholders corresponding to dynamic contents one by one are filled in a to-be-filled area of a blank document template;
in populating the dynamic content, the placeholders are replaced with the dynamic content. Here, the placeholder occupies the to-be-filled area of the blank document template, and corresponds to the corresponding dynamic content one to one, so that a user can design the document template conveniently, find the accurate position of each dynamic content conveniently, and fill the dynamic content in the resource file to the accurate position conveniently. The replacement is performed according to the data type of the resource attribute declared by the placeholder.
In another technical solution, the method for generating a test document based on dynamic data further includes:
after the verification document is generated, the verification document is electronically signed. Here, the electronic signature is used to ensure non-tamper-ability of the electronic verification document.
In another technical solution, the method for generating a test document based on dynamic data further includes:
when the resource file is traversed each time, writing each dynamic content into a first intermediate file respectively, and storing the first intermediate file;
acquiring a storage path of the first intermediate file, and generating a first link in the corresponding region to be filled according to the storage path;
after detecting the modification operation on the resource file each time, acquiring the modification content of each dynamic content, writing the modification content into a second intermediate file, and storing the second intermediate file;
acquiring a storage path of the second intermediate file, and generating a second link in the corresponding region to be filled according to the storage path;
and receiving a click command of the first link or the second link, and filling the corresponding content of the first intermediate file or the second intermediate file into the corresponding area to be filled.
According to the technical scheme, when the resource file is traversed, a first intermediate file is generated and used for storing corresponding dynamic contents, and after the resource file is modified, a second intermediate file is generated and used for storing corresponding modified contents. And displaying the link in the corresponding area to be filled by the first intermediate file and the second intermediate file. And storing the corresponding first intermediate file and the second intermediate file every time of traversing and modifying. And clicking the link by the user, and presenting the required content in the area to be filled. The user experience is further improved through the first intermediate file and the second intermediate file, and the situation that all resource files need to be traversed every time the resource files are added, replaced or modified is avoided.
The invention also provides a verification document generation device based on dynamic data, which comprises:
a processor;
a memory storing executable instructions;
wherein the processor is configured to execute the executable instructions to perform the method for verification document generation based on dynamic data.
The technical scheme is obtained based on the same inventive concept as the method for generating the inspection document based on the dynamic data, and the description of the method part can be referred. The device of the technical scheme is not limited to be realized by a PC, a terminal and a server.
The following is a specific description.
Defining the data type: the data types supported by the system and required to be used are predefined, such as text strings, numbers, dates, time, pictures and document basic types. This data type mainly determines the canonical representation of the next data model, and the format and representation of the data in the final document, such as pictures, may require a special blank space to store and define the size and position of the final program.
Define data model (CDM or PDM): since the inspection process of the stadium is substantially the same, the information collected in the whole process is mainly information of 6 subjects, such as an inspection order, inspection contract information, inspection flow plan, field inspection result, correction information, inspection result, report information, and the like. The information of each object is mainly divided into two parts, one is the preset information related to the process, such as the information of the state of the inspection process, the occurrence time of each step, the operator and the like, and the part is mainly set by the system design; and secondly, the related data items are specifically checked, business personnel can dynamically add or modify the data items according to the needs when the system runs, the names and the data types of the data items are simply set, and finally, the system automatically sets a related interface for data management according to the business personnel and the business personnel enter the related data.
Defining a model document template: the method is characterized in that a document template is generated by a service person according to a method for writing a standard document, and the dynamic content can be marked by a special expression method: the content such as the date of verification is included in the template in parenthesis such as: { date of examination }. The method can be unfixed, and only one or more ways which are convenient for business personnel to understand can be selected according to the requirement.
Template processing/document creation program module: the document generation program module loads the data model of the type of the examination venue and automatically loads the corresponding data from the system; the document generation program module loads a template file, traverses the content of the document, finds all dynamic content areas in the document according to the expression rule of the dynamic content, loads and formats actual data according to the data type and display parameters of the dynamic content defined in the data model, and finally replaces the corresponding placeholder content in the template at the moment.
For data items not found in the data model or data, special processing such as blank processing can be performed. For in-depth applications, expressions can be used in the templates to support certain user-controlled more dynamic control of content, such as common IF conditional decisions/data loops, etc.
Document signing: after the document is generated, the document may be automatically electronically signed according to a pre-configured system. This part is mainly to ensure the non-tamper property of the electronic document (i.e. the electronic signature of the document will automatically fail after the document is modified), so as to provide a better application scenario of the electronic document in the application process of the whole system, and in the future, the signed electronic document can be considered to replace the document with a paper printed official seal.
The number of apparatuses and the scale of the process described herein are intended to simplify the description of the present invention. Applications, modifications and variations of the method and apparatus for generating a verification document based on dynamic data of the present invention will be apparent to those skilled in the art.
While embodiments of the invention have been described above, it is not limited to the applications set forth in the description and the embodiments, which are fully applicable in various fields of endeavor to which the invention pertains, and further modifications may readily be made by those skilled in the art, it being understood that the invention is not limited to the details shown and described herein without departing from the general concept defined by the appended claims and their equivalents.

Claims (7)

1. The method for generating the inspection document based on the dynamic data is characterized by comprising the following steps:
determining an expression rule of the dynamic content;
establishing a document template, wherein the document template comprises a dynamic content name and a region to be filled corresponding to the dynamic content name;
and traversing the resource file, taking the data matched with the expression rule in the resource file as dynamic content, and filling the dynamic content into the region to be filled of the document template to generate a check document.
2. The method of claim 1, wherein the resource file includes at least a verification order, a verification contract information, a verification flow plan, a field verification result, a rectification information, a verification result, and a report information.
3. The verification document generation method based on dynamic data as claimed in claim 1, wherein the dynamic content has a preset format;
and converting the data matched with the expression rule in the resource file into a preset format and using the preset format as dynamic content.
4. The method for generating a verification document based on dynamic data according to claim 1, wherein the regions to be filled of the blank document template are filled with placeholders corresponding to dynamic contents one to one;
in populating the dynamic content, the placeholders are replaced with the dynamic content.
5. The method for generating a verification document based on dynamic data according to claim 1, further comprising:
after the verification document is generated, the verification document is electronically signed.
6. The method for generating a verification document based on dynamic data according to claim 1, further comprising:
when the resource file is traversed each time, writing each dynamic content into a first intermediate file respectively, and storing the first intermediate file;
acquiring a storage path of the first intermediate file, and generating a first link in the corresponding region to be filled according to the storage path;
after detecting the modification operation on the resource file each time, acquiring the modification content of each dynamic content, writing the modification content into a second intermediate file, and storing the second intermediate file;
acquiring a storage path of the second intermediate file, and generating a second link in the corresponding region to be filled according to the storage path;
and receiving a click command of the first link or the second link, and filling the corresponding content of the first intermediate file or the second intermediate file into the corresponding area to be filled.
7. The verification document generation device based on dynamic data is characterized by comprising:
a processor;
a memory storing executable instructions;
wherein the processor is configured to execute the executable instructions to perform the method of generating a verification document based on dynamic data according to any one of claims 1 to 6.
CN201911309482.8A 2019-12-18 2019-12-18 Method and device for generating inspection document based on dynamic data Active CN111090976B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201911309482.8A CN111090976B (en) 2019-12-18 2019-12-18 Method and device for generating inspection document based on dynamic data

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201911309482.8A CN111090976B (en) 2019-12-18 2019-12-18 Method and device for generating inspection document based on dynamic data

Publications (2)

Publication Number Publication Date
CN111090976A true CN111090976A (en) 2020-05-01
CN111090976B CN111090976B (en) 2022-11-15

Family

ID=70395703

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201911309482.8A Active CN111090976B (en) 2019-12-18 2019-12-18 Method and device for generating inspection document based on dynamic data

Country Status (1)

Country Link
CN (1) CN111090976B (en)

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113449502A (en) * 2021-06-29 2021-09-28 平安资产管理有限责任公司 Document generation method and system based on dynamic data
CN114492354A (en) * 2021-12-24 2022-05-13 永中软件股份有限公司 Streaming document generation method, computing device and computer readable medium
CN117910438A (en) * 2024-03-13 2024-04-19 江苏中威科技软件系统有限公司 Dynamic format file DLF generation device

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103778234A (en) * 2014-01-26 2014-05-07 北京恒华伟业科技股份有限公司 Report form generating method and device
CN108334477A (en) * 2018-01-30 2018-07-27 深圳壹账通智能科技有限公司 Implementation method, device, computer equipment and the storage medium of Intelligent file
CN108572944A (en) * 2017-11-24 2018-09-25 北京金山云网络技术有限公司 A document generation method, device, electronic device and storage medium
CN109684614A (en) * 2018-11-30 2019-04-26 南京越博动力系统股份有限公司 A kind of vehicle performance simulation report automatic creation system and its generation method
CN109783785A (en) * 2018-12-27 2019-05-21 长沙通诺信息科技有限责任公司 Generate the method, apparatus and computer equipment of tryout test report

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103778234A (en) * 2014-01-26 2014-05-07 北京恒华伟业科技股份有限公司 Report form generating method and device
CN108572944A (en) * 2017-11-24 2018-09-25 北京金山云网络技术有限公司 A document generation method, device, electronic device and storage medium
CN108334477A (en) * 2018-01-30 2018-07-27 深圳壹账通智能科技有限公司 Implementation method, device, computer equipment and the storage medium of Intelligent file
CN109684614A (en) * 2018-11-30 2019-04-26 南京越博动力系统股份有限公司 A kind of vehicle performance simulation report automatic creation system and its generation method
CN109783785A (en) * 2018-12-27 2019-05-21 长沙通诺信息科技有限责任公司 Generate the method, apparatus and computer equipment of tryout test report

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113449502A (en) * 2021-06-29 2021-09-28 平安资产管理有限责任公司 Document generation method and system based on dynamic data
CN114492354A (en) * 2021-12-24 2022-05-13 永中软件股份有限公司 Streaming document generation method, computing device and computer readable medium
CN117910438A (en) * 2024-03-13 2024-04-19 江苏中威科技软件系统有限公司 Dynamic format file DLF generation device

Also Published As

Publication number Publication date
CN111090976B (en) 2022-11-15

Similar Documents

Publication Publication Date Title
USRE50043E1 (en) Method for associating third party content with online document signing
US9696967B2 (en) Generation of an application from data
CN111061733B (en) Data processing method, device, electronic equipment and computer readable storage medium
CN108762743B (en) Data table operation code generation method and device
US10223698B2 (en) Integrating a web-based CRM system with a PIM client application
ITMI20130390U1 (en) METHODS AND SYSTEM FOR DYNAMIC ENDPOINT GENERATORS, DETECTION AND MEDIATION (BROKERAGE) OF DYNAMIC REMOTE OBJECTS
CN111090976A (en) Method and device for generating inspection document based on dynamic data
CN114861623A (en) Protocol template generation method and device, electronic equipment and storage medium
CN113254455A (en) Dynamic configuration method and device of database, computer equipment and storage medium
CN115543969A (en) Data migration method, device, equipment and medium
CN114004591A (en) Custom form automatic review method, device, electronic device and storage medium
WO2024244727A1 (en) Application packaging method and apparatus, device, and storage medium
US8239754B1 (en) System and method for annotating data through a document metaphor
AU2015200816A1 (en) Generating a signed electronic document
CN119203963A (en) Business report generation method, device and electronic equipment
CN119149541A (en) Service form generation tool and method
CN115828866A (en) A method and device for importing and exporting Excel data
CN116301856A (en) Design method, device, equipment and medium of visual form designer
CN115422068A (en) Test data generation method, test data generation device, test method and storage medium
JP7780230B1 (en) Report creation support system, report creation support method, and program
US11755824B2 (en) System and method for predicting and moderating signature locations within electronic documents
JP2002215856A (en) Workflow system and storage medium
TW202605653A (en) Document generation system and method
CN119065651A (en) A method for visually generating an interface
CN117787876A (en) An Internet of Vehicles system level approval method, terminal equipment and storage medium

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant