A method, device and system for generating and signing electronic contracts based on parameter templates
Through the electronic contract generation and signing method based on parameter templates, using WORD document templates and rendering strategies, the problem of dynamic changes in complex contract content in the financial field is solved, and the rigor of document format and support of diverse content is achieved to meet the electronic content in the financial field. Contract signing requirements.
Patent Information
- Application Number
- CN202110868361.8
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2021-07-30
- Publication Date
- 2024-12-03
- Estimated Expiration
- 2041-07-30
AI Technical Summary
The existing electronic contract signing methods cannot meet the complex contract needs in the financial field, especially the dynamic changes in contract content, such as fonts, text colors, pictures and dynamic forms, etc., and cannot effectively maintain the document format, resulting in insufficient rigor of contract documents.
Using the electronic contract generation and signing method based on parameter templates, using WORD documents as templates, generating a rendering strategy by identifying and filling preset parameters, converting parameter information into rendering parameters, filling into the contract template, and converting it into PDF files, supporting Dynamic modification of multi-style content ensures the rigor of the contract document format.
It realizes dynamic modification of various types of electronic contracts, maintains document format, ensures the rigor of contract documents to the greatest extent, and meets the complex contract signing needs in the financial field.
Smart Images

Figure CN113536757B_ABST
Abstract
Description
Technical Field
[0001] The present invention belongs to the technical field of e-commerce, and in particular relates to a method, device and system for generating and signing an electronic contract based on a parameter template. Background Art
[0002] With the development of Internet technology and the improvement of the relevant laws and regulations of the "Electronic Signature Law of the People's Republic of China", electronic contracts have begun to be widely used in various fields and industries such as e-commerce B2B platforms, B2C platforms, online travel platforms, leasing industries, real estate industries, and Internet finance. Electronic contracts have gradually replaced paper contracts with the advantages of convenience and easy preservation. The current signing process of electronic contracts is usually completed through a third-party electronic contract platform.
[0003] The applicant has found through research that the existing electronic contract signing method has the following defects:
[0004] In the financial field, both parties often need to sign multiple different types of electronic contracts online, and different business products and different channels need to use their own contract templates, resulting in a wide variety of contract types. The customer information, interest rates, contract terms and repayment plans in the online signed contract text are all dynamically changing. In addition to simple text replacement, some contract contents also involve more complex and diverse requirements, such as fonts, text colors, pictures and dynamic tables, which also need to change dynamically according to actual conditions.
[0005] Most existing methods for implementing electronic contract signing are limited to simple text replacement and cannot meet the needs of business development. Summary of the invention
[0006] The purpose of the present invention is to solve the above-mentioned technical problems and to provide a method, device and system for generating and signing an electronic contract based on a parameter template.
[0007] In order to solve the above problems, the present invention is implemented according to the following technical solutions:
[0008] In a first aspect, the present invention provides a method for generating and signing an electronic contract based on a parameter template, the method comprising the following steps:
[0009] Acquire a contract signing request sent by a contract signing requesting party; wherein the contract signing request includes parameter information of a target electronic contract to be created;
[0010] Obtaining a contract template corresponding to the contract signing request; wherein the contract template is a WORD document;
[0011] Identify all preset parameters and the locations of preset parameters in the contract template; wherein the preset parameters are objects that the contract requesting party needs to dynamically modify in the contract template;
[0012] Generate rendering strategies corresponding to preset parameters;
[0013] Convert parameter information into rendering parameters according to the rendering strategy, and fill in the rendering parameters into the contract template accordingly;
[0014] Convert the WORD document filled with rendering parameters into a PDF file;
[0015] Call the electronic signature service to execute electronic contract signing.
[0016] In combination with the first aspect, the present invention further provides a first implementation manner of the first aspect, wherein the configuration rules of the preset parameters are as follows:
[0017] The preset parameter uses "${" as the start character and "}" as the end character. The characters between the start character and the end character are the rendering configuration information of the preset parameter.
[0018] The rendering strategy renders the rendering parameters based on the rendering configuration information.
[0019] In combination with the first aspect, the present invention further provides a second implementation of the first aspect, which converts the parameter information into rendering parameters according to the rendering strategy, and fills the rendering parameters into the contract template accordingly, specifically including:
[0020] Obtaining the parameter information;
[0021] Convert the parameter information into rendering parameters according to the rendering configuration information; wherein the rendering parameters are text, tables or pictures;
[0022] Call the software interface for operating the word file, fill in the rendering parameters corresponding to the preset parameters of the contract template, and delete the preset parameters.
[0023] In combination with the first aspect, the present invention further provides a third implementation of the first aspect, wherein the preset parameters include at least one of a text type, a picture type, and a table type.
[0024] In combination with the first aspect, the present invention further provides a fourth implementation of the first aspect, when the preset parameter is a text type, the configuration rule of the preset parameter is as follows:
[0025] ${@textData|fontSize:A|fontFamily:B|color:C} Among them, “@” indicates that the preset parameter is text type; “textData” is the filled text content; “|” is the attribute separator; “fontSize” is the font size, and “A” is the parameter value of the font size; “fontFamily” is the font type, and “B” is the parameter value of the font type; “color” is the font color, and “C” is the parameter value of the font color.
[0026] In combination with the first aspect, the present invention further provides a fifth implementation of the first aspect, when the preset parameter is a table type, the configuration rules of the preset parameter are as follows:
[0027] ${#tableData|fontSize:A|fontFamily:B|color:C} Among them, “#” indicates that the preset parameter is a table type; “tableData” is the table content filled in, including row and column content information; “|” is the attribute separator; “fontSize” is the font size, and “A” is the parameter value of the font size; “fontFamily” is the font type, and “B” is the parameter value of the font type; “color” is the font color, and “C” is the parameter value of the font color.
[0028] In combination with the first aspect, the present invention further provides a sixth implementation of the first aspect, where when the preset parameter is a picture type, the configuration rule of the preset parameter is as follows:
[0029] ${&imgData|higth:H|width:W}, where “&” indicates that the preset parameter is the image type; “imgData” is the image content filled in, “H” is the parameter value of the image height; “higth” is the image height; “width” is the image width, and “W” is the parameter value of the image width.
[0030] In combination with the first aspect, the present invention further provides a seventh implementation of the first aspect, where after the electronic contract is signed, the electronic contract is persistently stored in a designated file server using the FTP or SFTP protocol.
[0031] In a second aspect, the present invention further provides an electronic contract generation and signing device based on a parameter template, comprising:
[0032] A receiving module, which is used to obtain a contract signing request sent by a contract signing requesting party; wherein the contract signing request includes parameter information of a target electronic contract to be created;
[0033] An acquisition module, which is used to acquire a contract template corresponding to the contract signing request; wherein the contract template is a WORD document;
[0034] An identification module, which is used to identify all preset parameters and the positions of preset parameters in the contract template; wherein the preset parameters are objects that the contract requesting party needs to dynamically modify in the contract template;
[0035] A generation module, which is used to generate a rendering strategy corresponding to preset parameters;
[0036] A rendering module, which is used to convert parameter information into rendering parameters according to the rendering strategy, and fill the rendering parameters into the contract template accordingly;
[0037] A conversion module, which is used to convert a WORD document filled with rendering parameters into a PDF file;
[0038] The signing module is used to call the electronic signature service and execute the electronic contract signing.
[0039] In a third aspect, the present invention further provides an electronic contract signing system, comprising the electronic contract generation and signing device based on parameter template of the second aspect, a signature system database server, a cache server and an FTP server message queue;
[0040] The electronic contract generation and signing device performs data exchange with the business system based on the FTP server message pair, and the contract signing requesting party sends a contract signing request to the electronic contract generation and signing device through the business system.
[0041] Compared with the prior art, the present invention has the following beneficial effects:
[0042] In view of the shortcomings of existing electronic contract signing solutions, such as the inability to maintain document format and the inability to support modification of various contract content styles, the present invention proposes a brand-new solution: using word documents as templates, supporting dynamic modification of various content styles, supporting direct editing and replacement of document parameter content and writing multiple content styles as required, and effectively ensuring the document format of the contract, thereby ensuring the rigor of the contract documents to the greatest extent. BRIEF DESCRIPTION OF THE DRAWINGS
[0043] The specific embodiments of the present invention are further described in detail below in conjunction with the accompanying drawings, wherein:
[0044] Figure 1 It is a schematic diagram of the composition of the electronic contract signing system of the present invention;
[0045] Figure 2 It is a flow chart of the parameter template-based electronic contract generation and signing method of the present invention. DETAILED DESCRIPTION
[0046] The preferred embodiments of the present invention are described below in conjunction with the accompanying drawings. It should be understood that the preferred embodiments described herein are only used to illustrate and explain the present invention, and are not used to limit the present invention.
[0047] At present, in the financial field, both parties often need to sign multiple different types of electronic contracts online, and different business products and different channels need to use their own contract templates, resulting in a wide variety of contract types. The customer information, interest rates, contract terms and repayment plans in the text of the online signed contract are all dynamically changing. In addition to simple text replacement, some contract contents also involve more complex and diverse requirements, such as fonts, text colors, pictures and dynamic tables, which also need to change dynamically according to actual conditions. Existing electronic contract signing implementation methods are mostly limited to simple text replacement and cannot meet the needs of business development.
[0048] Based on this, the embodiment of this specification provides an electronic contract generation and signing method based on parameter templates, which uses a word document as a template on the basis of ensuring the effectiveness of the contract, supports dynamic modification of various content styles, supports direct editing and replacement of document parameter content, and can write multiple content styles as required, and effectively guarantees the document format of the contract, maximizes the rigor of the contract document, and meets user needs.
[0049] Figure 1 A schematic diagram of an application scenario of a method for generating and signing an electronic contract based on a parameter template provided in one or more embodiments of this specification is illustrated by a requesting user, such as Figure 1 As shown, the scenario includes: the terminal equipment of the requesting user, the business system and the business system database server, the FTP server message queue, the electronic contract generation and signing device based on the parameter template, the cache server and the signature system database server, and the electronic signature service.
[0050] The terminal device may be a mobile phone, a tablet computer, a desktop computer, a portable notebook computer, etc.; the cache server and the signature system database server store data, such as relevant data of the electronic contract.
[0051] Specifically, the terminal device of the requesting user responds to the contract creation operation of the contract signing requesting user, and sends a contract signing request to the electronic contract generation and signing device based on the parameter template connected to the business system according to the parameter information of the target electronic contract to be created. The electronic contract generation and signing device retrieves the contract template corresponding to the contract signing request, identifies all the preset parameters and the positions of the preset parameters in the contract template; generates a rendering strategy corresponding to the preset parameters, converts the parameter information into rendering parameters according to the rendering strategy, and fills the rendering parameters into the contract template; converts the WORD document filled with the rendering parameters into a PDF file; calls the electronic signature service to execute the electronic contract signing. And sends the signing result information to the corresponding terminal device of the requesting user.
[0052] Based on the above application scenario architecture, one or more embodiments of this specification provide a method for generating and signing an electronic contract based on a parameter template. Figure 2 A flowchart of a method for generating and signing an electronic contract based on a parameter template according to one or more embodiments of this specification is provided. Figure 2 The method in can be Figure 2 The electronic contract generation and signing device based on parameter template is executed, such as Figure 2 As shown, the method comprises the following steps:
[0053] S100: Acquire a contract signing request sent by a contract signing requesting party; wherein the contract signing request includes parameter information of a target electronic contract to be created.
[0054] In one implementation, the requesting user operates his terminal device to select the target template information corresponding to the target electronic contract to be created from the template information of multiple preset contract templates (such as template names, etc.), and edit the user identification information of each signatory user of the target electronic contract to be created, the replacement content of the target electronic contract, etc. The terminal device determines the template identification information of the contract template corresponding to the acquired target template information, the user identification information of each signatory user, the replacement content, etc. as parameter information, and sends a contract signing request to the electronic contract generation and signing device according to the parameter information.
[0055] It should be pointed out that this application does not limit the signatories, which can be individuals, enterprises, institutions, etc.
[0056] S200: Acquire a contract template corresponding to the contract signing request; wherein the contract template is a WORD document.
[0057] The present invention calls the corresponding contract template in the database based on the target template information in the contract signing request. It should be emphasized that the contract template of the present invention is a WORD document, specifically a DOC document in DOC format as a template.
[0058] The applicant explains this limitation as follows:
[0059] The production process of electronic contracts is the same as that of paper contracts, and both involve steps such as drafting, confirmation, approval, signing, and sending. Among them, the electronic contract drafting stage involves the operation of using customer data to customize and fill in the electronic contract template. In this field, there are currently two main solutions:
[0060] (1) The first solution: PDF is an international standard format in the printing field. With its outstanding performance in typesetting, rendering, cross-platform, openness, interactivity and security, it has become the preferred format for making electronic contracts. The common practice in the industry is to add form fields to a PDF file that has reserved blank space for filling data. The form field will record relevant attributes such as position, size, font and name. The PDF file with added form fields is then used as a filling template. The customer data is filled into the corresponding form field according to the form field name through the PDF processing program to complete the preparation of a customized electronic contract for customer data.
[0061] However, the applicant found that the block-based text organization of PDF files is extremely beneficial for rendering and storage, but extremely unfriendly for editing. Use PDF documents as templates, mark with special parameters where text needs to be dynamically replaced, reserve space for replacement parameters, then use the program to traverse the template, replace the parameters with actual content, and finally electronically sign the PDF file. This solution can maintain the original overall format of the document, but it is not friendly to dynamically changing parameters. For example, it is necessary to statically reserve the length of the filling parameter content, and there may be a part of the replaced content that is left blank or covers other text. It cannot support complex tables with variable numbers of rows and columns.
[0062] In addition, due to the fixed size of form fields, in the process of drafting electronic contracts, it is often the case that the rendered data is incomplete or too many spaces are left blank due to improper estimation of the length of customer data by the production staff, which brings unnecessary legal risks. There may also be a phenomenon in which the entire contract feels severely fragmented due to the inconsistency between the filled data and the font of the contract text, which reduces the reliability of the electronic contract and the customer's willingness to sign, and fails to play the role that the electronic contract should play.
[0063] (2) The second solution: Taking advantage of the structural flexibility of HTML documents, special parameters are used to mark the locations that need to be dynamically changed, and traversal and replacement are performed based on an open source template engine. The HTML document is then converted into a PDF file, and the PDF file is finally electronically signed. This solution can support multiple styles and complex table generation. However, the applicant found that the final document content format (font size, indentation, style, and paging, etc.) was significantly different from the initial version.
[0064] In summary, both commonly used solutions have shortcomings and undermine the rigor of contract documents.
[0065] To this end, the present invention proposes a new solution to the existing problems. This solution directly uses doc documents as templates, which can ensure the document format, support dynamic complex tables, support direct editing and replacement of document parameter content and can write in a variety of text styles, thereby ensuring the rigor of the contract documents to the greatest extent.
[0066] S300: Identify all preset parameters and the locations of the preset parameters in the contract template; wherein the preset parameters are objects that the contract signing requesting party needs to dynamically modify the contract template.
[0067] In one implementation, the configuration rules of the preset parameters are as follows: the preset parameters use "${" as the start character and "}" as the end character, and the characters between the start character and the end character are the rendering configuration information of the preset parameters. The preset parameters include at least one of a text type, a picture type, and a table type.
[0068] Correspondingly, when the requesting user sends a contract signing request, he can operate his terminal device to input replacement content as required. The replacement content is to fill in the contract template and dynamically modify the contract template to obtain the target electronic contract. Specifically, the replacement content can be text, pictures, or table content, etc. The template is rendered according to the parameter information in the contract signing request.
[0069] S400: Generate a rendering strategy corresponding to preset parameters.
[0070] In the present invention, the rendering strategy renders the rendering parameters based on the rendering configuration information.
[0071] With respect to the pre-examination parameters and rendering strategies of S300-S400, the present invention provides the following examples:
[0072] (1) When the preset parameter is of text type, the configuration rules of the preset parameter are as follows:
[0073] ${@textData|fontSize:A|fontFamily:B|color:C}
[0074] Among them, “@” indicates that the preset parameter is text type; “textData” is the filled text content; “|” is the attribute separator; “fontSize” is the font size, “A” is the parameter value of the font size; “fontFamily” is the font type, “B” is the parameter value of the font type; “color” is the font color, and “C” is the parameter value of the font color.
[0075] In a specific example, the preset parameter rule for the text type is "${@textData|fontSize:5|fontFamily:Songti|color:red}", where "@" indicates that the parameter type is text, "|" is the attribute separator, the value after ":" is used to input the parameter value of the attribute, fontSize indicates that the font size is 5, fontFamily indicates that the font is Songti, and color indicates that the font color is red.
[0076] Among them, textData represents the filled text content. Specifically, it is represented in JSON format as follows:
[0077] {
[0078] "text": "replacement content"
[0079] }
[0080] The rendering strategy for the text type: Obtain the replacement content string through textData in the input parameter information, generate the target string according to the configured text style, and finally call the software interface for operating the doc file to write the target string to the position of the preset parameter in the template (such as the content of "${@textData|fontSize:5|fontFamily:Songti|color:red}" above), and delete the preset parameter.
[0081] (2) When the preset parameter is of the table type, the configuration rule of the preset parameter is as follows:
[0082] ${#tableData|fontSize:A|fontFamily:B|color:C}
[0083] Among them, "#" indicates that the preset parameter is of the table type; "tableData" is the filled table content, including row and column content information; "|" is the attribute separator; "fontSize" is the font size, and "A" is the parameter value of the font size; "fontFamily" is the font type, and "B" is the parameter value of the font type; "color" is the font color, and "C" is the parameter value of the font color.
[0084] In a specific example, the preset parameter rule for the table type is like "${#tableData|fontSize:5|fontFamily:Songti|color:red}". Among them, "#" indicates that the parameter is a table, "|" is the attribute separator, the value after ":" is used to input the parameter value of the attribute, "fontSize" indicates that the font size is 5, "fontFamily" indicates that the font is Songti, and "color" indicates that the font color is red.
[0085] Among them, tableData represents the input table content, which contains information about the row and column content, and is represented in JSON format as follows:
[0086]
[0087]
[0088] Rendering strategy for table type: Obtain the table parameter content from tableData in the input parameter information. Among them, title in the parameter information is the name of the table, head is the table header data, and rows is the row data information of the table. The rendering strategy determines the rows and columns of the table according to the number of fields in the table header of the parameter information and the length of the rows list. And fill the fields of each row into the corresponding table. Finally, call the software interface for operating the doc file to insert the table into the position of the preset parameter of the template (such as the content of "${#tableData|fontSize:5|fontFamily:宋体|color:red}" above), and delete the preset parameter.
[0089] (3) When the preset parameter is of picture type, the configuration rule of the preset parameter is as follows:
[0090] ${&imgData|higth:A|width:B}
[0091] Among them, "&" indicates that the preset parameter is of picture type; "imgData" is the filled picture content; "higth" is the picture height, and "A" is the parameter value of the picture height; "width" is the picture width, and "B" is the parameter value of the picture width.
[0092] In a specific example, the picture parameter marking rule is as follows: "${&imgData|higth:140|width:140}", where "&" indicates that the parameter type is a picture, and "hight" and "width" respectively indicate that the height and width of the inserted picture are 140x140.
[0093] Among them, imgData is represented in JSON format as follows:
[0094]
[0095] Rendering strategy for image type: Get image parameter information through the input parameter information imgData, where title is the title of the image, srcPath is the location where the image is stored, and type is the format in which the image is stored. The program reads the image file, sets the length and width of the image, and finally calls the software interface for operating the doc file to insert the image into the preset parameters of the template (such as the above "${&imgData|higth:140|width:140}"), deletes the preset parameters, and writes the image title.
[0096] S500: Convert the parameter information into rendering parameters according to the rendering strategy, and fill the rendering parameters into the contract template accordingly.
[0097] In the present invention, the parameter information is converted into rendering parameters according to the rendering strategy, and the rendering parameters are correspondingly filled into the contract template, which specifically includes:
[0098] S510: Acquire the parameter information;
[0099] S520: Convert the parameter information into rendering parameters according to the rendering configuration information; wherein the rendering parameters are text, a table or a picture;
[0100] S530: calling a software interface for operating a word file, filling the rendering parameters into the positions of the preset parameters of the contract template, and deleting the preset parameters.
[0101] S600: Converting the WORD document filled with rendering parameters into a PDF file.
[0102] S700: Call the electronic signature service to execute electronic contract signing.
[0103] S800: After the electronic contract is signed, the electronic contract is persistently stored in a designated file server using the FTP or SFTP protocol.
[0104] After the present invention formulates the contract template according to the template specification, it is saved on the contract signing server, and the newly generated template and template type are configured and mapped on the contract server for use by subsequent programs. For different parameter types, the contract signing system needs to develop corresponding parsing and rendering strategy programs, and add them to the rendering process as needed during parsing, so as to realize the dynamic generation of the target electronic contract according to the configuration and input parameters.
[0105] The present invention provides a method for generating parameterized templates for complex electronic contract signing. The method supports dynamic complex tables, supports direct editing and replacement of document parameter content, supports multiple text styles, can ensure the format of contract documents, and maximizes the rigor of contract documents.
[0106] In order to achieve the above-mentioned purpose, the present invention provides an electronic contract generation and signing device based on parameter templates, which is used to execute the above-mentioned electronic contract generation and signing method to realize the electronic contract signing operation. Specifically, the electronic contract generation and signing device based on parameter templates includes:
[0107] A receiving module, which is used to obtain a contract signing request sent by a contract signing requesting party; wherein the contract signing request includes parameter information of a target electronic contract to be created;
[0108] An acquisition module, which is used to acquire a contract template corresponding to the contract signing request; wherein the contract template is a WORD document;
[0109] An identification module, which is used to identify all preset parameters and the positions of preset parameters in the contract template; wherein the preset parameters are objects that the contract requesting party needs to dynamically modify in the contract template;
[0110] A generation module, which is used to generate a rendering strategy corresponding to preset parameters;
[0111] A rendering module, which is used to convert parameter information into rendering parameters according to the rendering strategy, and fill the rendering parameters into the contract template accordingly;
[0112] A conversion module, which is used to convert a WORD document filled with rendering parameters into a PDF file;
[0113] The signing module is used to call the electronic signature service and execute the electronic contract signing.
[0114] Each of the above functional modules specifically executes the step flow of S100-S800.
[0115] At the same time, in order to achieve this purpose, the present invention proposes a reasonably designed and effective electronic contract signing system. In order to realize the signature function, the system includes: an electronic contract generation and signing device, a signature system database server, a cache server and an FTP server message queue. The electronic contract generation and signing device interacts with the business system based on the FTP server message queue, and the contract signing requesting party sends a contract signing request to the electronic contract generation and signing device through the business system.
[0116] Among them, the FTP server message queue is for docking with the business system, which can simplify the difficulty of business system access and realize the decoupling of the business system and the signature system. When it is necessary to dock with the contract signing, the business system only needs to push the signature parameter information to the message queue according to the message format specified by the electronic contract generation and signing device. At the same time, the message queue can cache the signing information and smooth the business peak, which can effectively deal with the sudden large business volume scenario.
[0117] A cache server is also introduced during the design to reduce time-consuming operations such as repeated reading of contract templates, thereby increasing the speed of contract signing. The signature system database server stores contract-related configuration information: contract type, template, storage server configuration, storage path and other information. The FTP server is used as a persistent storage contract text server. The electronic contract signing system is the core program for business implementation, coordinating with peripheral modules to complete functions such as contract signing.
[0118] For other structures of the method, device and system for generating and signing an electronic contract based on a parameter template described in this embodiment, refer to the prior art.
[0119] The above description is only a preferred embodiment of the present invention and does not limit the present invention in any form. Therefore, any modification, equivalent change and modification made to the above embodiment according to the technical essence of the present invention without departing from the technical solution of the present invention shall still fall within the scope of the technical solution of the present invention.
Claims
1. A method for generating and signing an electronic contract based on a parameter template. It is characterized in that The electronic contract generation and signing method includes the following steps: Acquire a contract signing request sent by a contract signing requesting party; wherein the contract signing request includes parameter information of a target electronic contract to be created, and the parameter information includes template identification information of a contract template, user identification information of each signatory user, and replacement content; Obtain a contract template corresponding to the contract signing request; wherein the contract template is a WORD document in DOC format; Identify all preset parameters and the locations of preset parameters in the contract template; wherein the preset parameters are objects that the contract requesting party needs to dynamically modify in the contract template; Generate rendering strategies corresponding to preset parameters; According to the rendering strategy, the parameter information is converted into rendering parameters, and the rendering parameters are filled in the contract template accordingly, including: Obtaining the parameter information; Convert the parameter information into rendering parameters according to the rendering configuration information; wherein the rendering parameters are text, tables and pictures; Call the software interface for operating the word file, fill in the rendering parameters corresponding to the preset parameters of the contract template, and delete the preset parameters; Convert the WORD document filled with rendering parameters into a PDF file; Call the electronic signature service to execute electronic contract signing; The configuration rules of the preset parameters are as follows: The preset parameter uses "${" as the start character and "}" as the end character. The characters between the start character and the end character are the rendering configuration information of the preset parameter. Wherein, the rendering strategy renders the rendering parameters based on the rendering configuration information; The preset parameters include at least one of a text type, a picture type, and a table type; When the preset parameter is a text type, Text type rendering strategy: Get the replacement content string through the textData in the input parameter information, and generate the target string according to the configured text style. Finally, call the software interface for operating the doc file to write the target string into the preset parameter position of the template and delete the preset parameters. When the preset parameter is a table type, Table type rendering strategy: Get the table parameter content through the tableData in the input parameter information, where title in the parameter information is the name of the table, head is the header data, and rows is the row data information of the table. The rendering strategy determines the rows and columns of the table based on the number of fields in the header of the parameter information and the length of the rows list, and fills the fields of each row into the corresponding table. Finally, call the software interface for operating the doc file to insert the table into the preset parameter position of the template and delete the preset parameters. When the preset parameter is a picture type, Rendering strategy for picture types: Get picture parameter information through the input parameter information imgData, where title is the picture title, srcPath is the location where the picture is stored, and type is the format in which the picture is stored. The program reads the picture file, sets the picture length and width, and finally calls the software interface for operating the doc file to insert the picture into the preset parameter position of the template, delete the preset parameters, and write the picture title; After the electronic contract is signed, the electronic contract is permanently stored in the designated file server using the FTP or SFTP protocol.
2. The method for generating and signing an electronic contract based on a parameter template according to claim 1, Features: When the preset parameter is of text type, the configuration rules of the preset parameter are as follows: ${@textData|fontSize:A|fontFamily:B|color:C} in, "@" indicates that the preset parameter is of text type; "textData" is the text content to be filled in; "|" is the attribute separator; "fontSize" is the font size, "A" is the parameter value of the font size; "fontFamily" is the font type, "B" is the parameter value of the font type; "color" is the font color, "C" is the parameter value of the font color.
3. The method for generating and signing an electronic contract based on a parameter template according to claim 2, Features: When the preset parameter is of table type, the configuration rules of the preset parameter are as follows: ${#tableData|fontSize:A|fontFamily:B|color:C} in, "#" indicates that the preset parameter is a table type; "tableData" is the table content to be filled in, including row and column content information; "|" is the attribute separator; "fontSize" is the font size, "A" is the parameter value of the font size; "fontFamily" is the font type, "B" is the parameter value of the font type; "color" is the font color, and "C" is the parameter value of the font color.
4. The method for generating and signing an electronic contract based on a parameter template according to claim 3, Features: When the preset parameter is a picture type, the configuration rules of the preset parameter are as follows: ${&imgData|height:H|width:W} in, "&" indicates that the preset parameter is the image type; "imgData" is the image content to be filled in; "higth" is the image height, "H" is the parameter value of the image height; "width" is the image width, "W" is the parameter value of the image width.
5. An electronic contract generation and signing device based on parameter template, It is characterized in that include: A receiving module, which is used to obtain a contract signing request sent by a contract signing requesting party; wherein the contract signing request includes parameter information of a target electronic contract to be created, and the parameter information includes template identification information of a contract template, user identification information of each signatory user, and replacement content; An acquisition module, which is used to acquire a contract template corresponding to the contract signing request; wherein the contract template is a WORD document in DOC format; An identification module, which is used to identify all preset parameters and the positions of preset parameters in the contract template; wherein the preset parameters are objects that the contract requesting party needs to dynamically modify in the contract template; A generation module, which is used to generate a rendering strategy corresponding to preset parameters; A rendering module, which is used to convert the parameter information into rendering parameters according to the rendering strategy, and fill the rendering parameters into the contract template accordingly, specifically including: obtaining the parameter information; converting the parameter information into rendering parameters according to the rendering configuration information; wherein the rendering parameters are text, table or picture; calling the software interface for operating the word file, filling the rendering parameters into the position of the preset parameters of the contract template accordingly, and deleting the preset parameters; A conversion module, which is used to convert a WORD document filled with rendering parameters into a PDF file; The signing module is used to call the electronic signature service and execute the electronic contract signing; The configuration rules of the preset parameters are as follows: The preset parameter uses "${" as the start character and "}" as the end character. The characters between the start character and the end character are the rendering configuration information of the preset parameter. Wherein, the rendering strategy renders the rendering parameters based on the rendering configuration information; The preset parameters include at least one of a text type, a picture type, and a table type; When the preset parameter is a table type, the rendering strategy of the table type: obtain the table parameter content through the tableData in the input parameter information, where the title in the parameter information is the name of the table, the head is the header data, and the rows is the row data information of the table. The rendering strategy determines the rows and columns of the table according to the number of fields in the header of the parameter information and the length of the rows list, and fills the fields of each row into the corresponding table. Finally, the software interface for operating the doc file is called to insert the table into the preset parameter position of the template, and delete the preset parameters; When the preset parameter is a text type, Text type rendering strategy: Get the replacement content string through the textData in the input parameter information, and generate the target string according to the configured text style. Finally, call the software interface for operating the doc file to write the target string into the preset parameter position of the template and delete the preset parameters. When the preset parameter is a picture type, Rendering strategy for picture types: Get picture parameter information through the input parameter information imgData, where title is the picture title, srcPath is the location where the picture is stored, and type is the format in which the picture is stored. The program reads the picture file, sets the picture length and width, and finally calls the software interface for operating the doc file to insert the picture into the preset parameter position of the template, delete the preset parameters, and write the picture title; After the electronic contract is signed, the electronic contract is permanently stored in the designated file server using the FTP or SFTP protocol.
6. An electronic contract signing system, It is characterized in that It includes the electronic contract generation and signing device based on parameter template as described in claim 5, the signature system database server, the cache server and the FTP server message queue; The electronic contract generation and signing device performs data exchange with the business system based on the FTP server message pair, and the contract signing requesting party sends a contract signing request to the electronic contract generation and signing device through the business system.
