CN109446499A - Contract template generation method, device, equipment and medium based on XML - Google Patents

Contract template generation method, device, equipment and medium based on XML Download PDF

Info

Publication number
CN109446499A
CN109446499A CN201811113578.2A CN201811113578A CN109446499A CN 109446499 A CN109446499 A CN 109446499A CN 201811113578 A CN201811113578 A CN 201811113578A CN 109446499 A CN109446499 A CN 109446499A
Authority
CN
China
Prior art keywords
xml
target
contract template
insurance products
new insurance
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.)
Pending
Application number
CN201811113578.2A
Other languages
Chinese (zh)
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.)
Ping An Technology Shenzhen Co Ltd
Original Assignee
Ping An Technology Shenzhen Co Ltd
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 Ping An Technology Shenzhen Co Ltd filed Critical Ping An Technology Shenzhen Co Ltd
Priority to CN201811113578.2A priority Critical patent/CN109446499A/en
Publication of CN109446499A publication Critical patent/CN109446499A/en
Pending legal-status Critical Current

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F40/00Handling natural language data
    • G06F40/10Text processing
    • G06F40/166Editing, e.g. inserting or deleting
    • G06F40/174Form filling; Merging
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06QINFORMATION AND COMMUNICATION TECHNOLOGY [ICT] SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES; SYSTEMS OR METHODS SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES, NOT OTHERWISE PROVIDED FOR
    • G06Q40/00Finance; Insurance; Tax strategies; Processing of corporate or income taxes
    • G06Q40/08Insurance

Landscapes

  • Engineering & Computer Science (AREA)
  • Business, Economics & Management (AREA)
  • Theoretical Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Finance (AREA)
  • Accounting & Taxation (AREA)
  • Physics & Mathematics (AREA)
  • General Health & Medical Sciences (AREA)
  • General Engineering & Computer Science (AREA)
  • Health & Medical Sciences (AREA)
  • Computational Linguistics (AREA)
  • Audiology, Speech & Language Pathology (AREA)
  • Artificial Intelligence (AREA)
  • Development Economics (AREA)
  • Economics (AREA)
  • Marketing (AREA)
  • Strategic Management (AREA)
  • Technology Law (AREA)
  • General Business, Economics & Management (AREA)
  • Financial Or Insurance-Related Operations Such As Payment And Settlement (AREA)

Abstract

The contract template generation method based on XML that the invention discloses a kind of, device, computer equipment and storage medium, this method comprises: because when XML object element is combined using preset XML element combined method, step is simple, so being quickly obtained target XML file, XML object element is obtained by inserting the target field of the new insurance products of setting into XML sky element, because target field belongs to new setting, obtaining XML object element is also newly to be arranged, and then it is also newly-generated for obtaining target XML file, again because fresh target XML file can be quickly obtained, so in the first standard clauses that obtained fresh target XML file filling is got, also the target contract template of new insurance products can quickly be obtained, conversion will can not efficiently be needed simultaneously Target contract template is saved into specified database, improves the efficiency for generating contract template.

Description

Contract template generation method, device, equipment and medium based on XML
Technical field
The present invention relates to data processing field more particularly to it is a kind of by the contract template generation method of XML, device, based on Calculate machine equipment and storage medium.
Background technique
Currently, needing to formulate the contract template of insurance products in financial industry, the contract template is consolidated by insurance company Determine format module and insurance products target composition.In general, old insurance products target variation is less, for old insurance products Contract template is updated using manual type.Insurance products are more and more welcomed by the people, and insurance company can constantly release new guarantor Dangerous product, and the frequency of iteration is high, with stylish insurance products target belong to it is new-create, so needing efficiently to generate new guarantor The target contract template of dangerous product still writes the contract template inefficiency of new insurance products using traditional artificial mode, because This, finds the problem of a kind of efficient contract template method becomes those skilled in the art's urgent need to resolve.
Summary of the invention
The embodiment of the present invention provides a kind of contract template generation method based on XML, device, computer equipment and storage and is situated between Matter, to solve the problems, such as that generation insurance contract template efficiency is low.
A kind of contract template generation method based on XML, comprising:
Each target field of new insurance products is set;
Obtain the first standard clauses of the new insurance products;
Each target field is respectively filled in preset each XML sky element, each XML object element is obtained;
Each XML object element is combined using preset XML element combined method, obtains target XML file;
The target XML file is inserted in first standard clauses, the target contract of the new insurance products is obtained Template;
The target contract template is saved in specified database, in order to when the contract for generating the new insurance products When the target contract template is called from the specified database.
A kind of contract template generating means based on XML, comprising:
Setup module, for each target field of new insurance products to be arranged;
Module is obtained, for obtaining the first standard clauses of the new insurance products;
First filling module is obtained for each target field to be respectively filled in preset each XML sky element Each XML object element;
Composite module is obtained for being combined each XML object element using preset XML element combined method Target XML file;
Second filling module obtains the new guarantor for inserting the target XML file in first standard clauses The target contract template of dangerous product;
Preserving module, for the target contract template to be saved in specified database, in order to described new when generating The target contract template is called when the contract of insurance products from the specified database.
A kind of computer equipment, including memory, processor and storage are in the memory and can be in the processing The computer program run on device, the processor realize the above-mentioned contract template based on XML when executing the computer program The step of generation method.
A kind of computer readable storage medium, the computer-readable recording medium storage have computer program, the meter Calculation machine program realizes the step of above-mentioned contract template generation method based on XML when being executed by processor.
Above-mentioned contract template generation method, device, computer equipment and storage medium based on XML is new by being first arranged Each target field of insurance products, and the first contractual format clause of new insurance products is obtained, then by each target Field is respectively filled in preset XML sky element, obtains each XML object element, is next combined using preset XML element Each XML object element is combined by method, obtains target XML file, and the target XML file is next inserted institute It states in the first standard clauses, obtains the target contract template of the new insurance products, finally save the target contract template Into specified database, in order to call the mesh from the specified database when generating the contract of the new insurance products Mark contract template.Because each XML object element is combined using preset XML element combined method, step it is simple and Easy to operate, so target XML file can be obtained quickly and easily, each XML object element is by will be described each A target field is respectively filled in into preset XML sky element and obtains, and each target field is the new insurance products of setting Each target field obtain each XML object element because each target field of new insurance products belongs to newly-installed Newly-installed, so obtain target XML file be also it is newly-generated, because fresh target XML text can be obtained quickly and easily Part, so also can quickly obtain the new guarantor in the first standard clauses that obtained fresh target XML file filling is got The target contract template of dangerous product, further, target contract template (target XML file), which does not need conversion, directly to be stored Into database, therefore efficiently the target contract template can be saved in specified database, in order to when generation institute The target contract template is called when stating the contract of new insurance products from the specified database, improves generation contract template Efficiency.
Detailed description of the invention
In order to illustrate the technical solution of the embodiments of the present invention more clearly, below by institute in the description to the embodiment of the present invention Attached drawing to be used is needed to be briefly described, it should be apparent that, the accompanying drawings in the following description is only some implementations of the invention Example, for those of ordinary skill in the art, without any creative labor, can also be according to these attached drawings Obtain other attached drawings.
Fig. 1 is an application environment schematic diagram of the contract template generation method in one embodiment of the invention based on XML;
Fig. 2 is a flow chart of the contract template generation method in one embodiment of the invention based on XML;
Fig. 3 is a flow chart of step S20 in contract template generation method in one embodiment of the invention based on XML;
Fig. 4 is a flow chart of step S30 in contract template generation method in one embodiment of the invention based on XML;
Fig. 5 is a flow chart of step S40 in contract template generation method in one embodiment of the invention based on XML;
Fig. 6 is one of displaying target contract template in contract template generation method in one embodiment of the invention based on XML Flow chart;
Fig. 7 is a schematic diagram of the contract template generating means in one embodiment of the invention based on XML;
Fig. 8 is a schematic diagram of computer equipment in one embodiment of the invention.
Specific embodiment
Following will be combined with the drawings in the embodiments of the present invention, and technical solution in the embodiment of the present invention carries out clear, complete Site preparation description, it is clear that described embodiments are some of the embodiments of the present invention, instead of all the embodiments.Based on this hair Embodiment in bright, every other implementation obtained by those of ordinary skill in the art without making creative efforts Example, shall fall within the protection scope of the present invention.
Contract template generation method provided by the present application based on XML, can be applicable in the application environment such as Fig. 1, wherein Client is communicated by network with server.Wherein, client can be, but not limited to various personal computers, notebook electricity Brain, smart phone, tablet computer and portable wearable device.Server can use the either multiple services of independent server The server cluster of device composition is realized.
It in one embodiment, should be based on XML's as shown in Fig. 2, providing a kind of contract template generation method based on XML Contract template generation method is applied in data processing industries, applies be illustrated for the server in Fig. 1 in this way, Include the following steps:
Each target field of S10, the new insurance products of setting;
In the present embodiment, target is existing rights and duties relationship between the both parties of contract, is that insurance is closed With the necessary condition set up.
Specifically, usually at regular intervals, insurance company can release new insurance products, if serious disease is dangerous in hospital, Mei Gexin There are respective targets for insurance products, in order to which each target by using new insurance products generates the contract mould of new insurance products Plate needs first to be arranged each target field of new insurance products, such as each target field of vehicle insurance, uses year including vehicle Limit, the traveling milimeter number of vehicle and engine model etc..
It should be noted that the particular content of new insurance products and target field, can be set according to practical application, Herein with no restrictions.
It is to be appreciated that there are target types for the target of insurance products, and as the target type of vehicle insurance is logo, person meaning Outer dangerous target type is personal target, and the target type of new insurance products can be with the target type one of existing insurance products It causes, or the target type of new insurance products can be with the target Type-Inconsistencies of existing insurance products.
S20, the first standard clauses for obtaining new insurance products;
In the present embodiment, party is that have due to the equity generation dispute in the applicable law, or with specific juristic fact Direct relation and enter lawsuit, and the people contained by law court judge.First standard clauses are that party is pre- in order to reuse First draft and settle a bargain Shi Weiyu other side negotiation clause, such as insure standard form of contract, which includes one party And adversary, as insured insurer and the insurer in standard form of contract
It should be noted that the first standard clauses namely preset standard form of contract of new insurance products are pre-set, and It is stored in clause database, in the state that can be called at any time.
Specifically, store path of the first standard clauses of new insurance products in clause database is obtained first, then The first standard clauses of new insurance products are extracted from clause database according to the store path.Such as, new insurance products are vehicle insurance, The first standard clauses namely standard form of contract of new insurance products, the wherein clause in the standard form of contract is " water inflow of the engine Caused engine damage, the not responsible reparation of insurance company ", clause database are SQL first database, which exists Store path in SQL first database is " C: Documentsand Settings All Users Application Data MySQL MySQLServer 5.1 data ", then first obtain " C: Documentsand Settings All Users Application Data MySQL MySQL Server 5.1 data ", then according to " C: Documentsand Settings All Users Application Data MySQL MySQL Server 5.1 data " extract the format conjunction " engine damage caused by water inflow of the engine, the not responsible reparation of insurance company " together namely in the standard form of contract.
It should be noted that the particular content of clause database, can be set according to practical application, not limited herein System.
S30, each target field is respectively filled in preset each XML sky element, obtains each XML object element;
In the present embodiment, XML sky element is only comprising the XML element for starting label and end-tag, such as < Address2 ></Address2>, wherein<address2></Address2>for address blank element.
Specifically, each XML object element wanted in order to obtain, each target field is respectively filled in preset each In XML sky element.As in order to obtain<year>durable years</year>or<kilometre>run kilometre</ Kilometre>, it needs to insert " durable years "<year></year>in, " run kilometre " is inserted< Kilometre></kilometre>in, wherein<year>durable years</year>for service life XML target element Element,<kilometre>run kilometre</kilometre>to travel milimeter number XML object element.
It should be noted that the particular content of XML sky element, can be set according to practical application, not limited herein System.
S40, each XML object element is combined using preset XML element combined method, obtains target XML text Part;
In the present embodiment, preset XML element combined method can to merge designer in Visual Studio, or XML schema designer etc., the particular content of preset XML element combined method, can be set, herein according to practical application With no restrictions.
Specifically, the target XML file wanted in order to obtain, needing will be each using preset XML element combined method XML object element is combined, e.g., will using XML schema designer<car>information of vehicles</car>,<year>service life </year>with<kilometre>travel milimeter number</kilometre>nesting is carried out, obtains target XML file, target XML File is specific as follows:
<? xml version=" 1.0 "?>
<car>information of vehicles
<year>service life</year>
<kilometre>travel milimeter number</kilometre></car>.
S50, target XML file is inserted in the first standard clauses, obtains the target contract template of new insurance products;
Specifically, the target contract template of new insurance products, the target XML file filling for needing to obtain obtain in order to obtain In the first standard clauses got, in the preset standard form of contract that the target XML file filling that will also obtain is got, such as protect Dangerous standard form of contract has insurance clause in the insurance standard form of contract, such as " insurant has an accident injury in period insured, and The internal cause unexpected injury on the 180th is die from occurring from unexpected injury, and the insurer dies insurance money by insured amount payment, The termination of cover to the insurant." or " insurant injures because having an accident and removes day from unexpected injury generation Fall unknown, by people's court's declaration of death, the insurer dies insurance money by insured amount payment.If but insurant is declared Accuse it is dead after survive, insurance money allottee Ying Yu know or should appreciate that returned in 30 days after insurant survives the insurer to The insurance money of dieing paid.".
S60, target contract template is saved in specified database, in order to when generating the contract of new insurance products from Invocation target contract template in specified database.
Specifically, obtained target contract template is saved in specified database using preset the first script of SQL, side Convenient for the target contract template can be called from specified database when generating the contract of new insurance products.
It should be noted that the particular content of preset XML script and specified database, can carry out according to practical application Setting, herein with no restrictions.
In the corresponding embodiment of Fig. 2, by the way that each target field of new insurance products, and the new insurance production of acquisition is first arranged Then each target field is respectively filled in preset XML sky element, obtains each by the first contractual format clause of product Next each XML object element is combined using preset XML element combined method, obtains target by XML object element The target XML file is next inserted in first standard clauses, obtains the new insurance products by XML file The target contract template is finally saved in specified database by target contract template, in order to when the generation new insurance The target contract template is called when the contract of product from the specified database.Because when using preset XML element group When each XML object element is combined by conjunction method, step is simply and readily operated, so quickly and easily obtaining target XML file, each XML object element are by being respectively filled in each target field to preset XML sky element In obtain, each target field is each target field of the new insurance products of setting, because new insurance products is each Target field belongs to newly-installed, and it is also newly-installed for obtaining each XML object element, and then obtains target XML file and be also Newly-generated, then, because fresh target XML file can be obtained quickly and easily, obtained fresh target XML file is filled out Enter in the first standard clauses got, also can quickly obtain the target contract template of the new insurance products, further, Target contract template (target XML file), which does not need conversion, to be directly stored in database, therefore can be efficiently by institute It states target contract template to be saved in specified database, in order to specify when generating the contract of the new insurance products from described The target contract template is called in database, improves the efficiency for generating contract template.
In one embodiment, it is somebody's turn to do the contract template generation method based on XML to apply in data processing industries, such as Fig. 3 institute Process of the step S20 under an application scenarios in a kind of contract template generation method based on XML in 2 corresponding embodiment of diagram Figure, specifically comprises the following steps:
S201, the target type for obtaining new insurance products;
Specifically, every to release a new insurance products, the target of the insurance products has corresponding target type, such as shipping object The corresponding target type of target of stream danger is Logistics Types, it is possible to understand that, obtain the target class of the new insurance products of every release Type.
It should be noted that the particular content of target type, can be set according to actual needs, not limited herein System.
S202, existing target type and the second standard clauses are obtained;
In the embodiment of the present invention, existing target type is pre-saved in existing types of database, at any time can be with The state of calling.Second standard clauses pre-save in existing clause database, and in the state that can be called at any time, this Two standard clauses are the proprietary standard clauses of existing target type.
Specifically, type store path of the existing target type in existing types of database is obtained, and obtains second Clause store path of the standard clauses in existing clause database, then according to the type store path in existing categorical data The existing target type is extracted in library, and second format is extracted in existing clause database according to the clause store path Clause.
It should be noted that existing types of database is SQL database or orable database etc., has clause database For SQL database or orable database etc., have the particular content of types of database and existing clause database, it can basis Practical application is set, herein with no restrictions.
Whether S203, the target type for judging new insurance products are existing target type, if so, thening follow the steps S204, if it is not, thening follow the steps S205;
In the present embodiment, existing target type is stored in types of database, in the state that can be called at any time.
Specifically, store path of the existing target type in types of database is obtained first, then according to the storage Next the path extraction existing target type judges whether the target type for the new insurance products released is the existing mark Type, if so, S204 is thened follow the steps, if it is not, thening follow the steps S205.
It should be noted that types of database can be SQL database or orable database etc., the tool of types of database Hold in vivo, can be set according to practical application, herein with no restrictions.
S204, first standard clauses of second standard clauses as new insurance products are obtained;
In the present embodiment, the second standard clauses are the proprietary standard clauses of existing target type, such as the format of logo Clause be " insurance vehicle because third party damage should by third party's liable for compensation, but can not find really it is third-party, The insurer gives compensation, but carries out deductible franchise 50% meeting to compensate within the scope of the defined amount of money.There are class in 8 insurance companies Like clause, but franchise is different.", different types of the second standard clauses of target are different.
Specifically, when the target type of new insurance products is existing target type, existing target class is obtained first The corresponding second standard clauses store path in clause database of type, then mentions from clause database according to the store path Second standard clauses are taken, next using second standard clauses extracted as the first standard clauses of new insurance products.
S205, first standard clauses of the default form clause as new insurance products are obtained.
In the present embodiment, it usually can also be set while to each target type, corresponding second standard clauses are set Set default form clause, wherein default form clause is the general standard clauses of preset various target types.
It should be noted that default form clause is stored in clause database, in the state that can be called at any time.
Specifically, when the target type of new insurance products is not existing target type, default form item is obtained first Then money store path in clause database extracts the default form clause according to the store path from clause database, Next using the default form clause extracted as the first standard clauses of new insurance products.
In the corresponding embodiment of Fig. 3, by obtaining the target type of new insurance products, obtain existing target type and Second standard clauses, second standard clauses are the proprietary standard clauses of existing target type, judge the mark of new insurance products Type whether be existing target type, when the target type of new insurance products be existing target type when, obtain second First standard clauses of the standard clauses as new insurance products, when the target type of new insurance products is not existing target type When, first standard clauses of the default form clause as new insurance products are obtained, default form clause is preset target type General standard clauses.Because whether the target type for first determining whether new insurance products is existing target type, when insurance produces When the target type of product is existing target type, the second standard clauses of existing target type are obtained as new insurance products The first standard clauses, do not need that new standard clauses are arranged, when the target type of insurance products is not existing target type When, first standard clauses of the default form clause as new insurance products are obtained, obtain the of new insurance products so improving The efficiency of one standard clauses.
In one embodiment, it is somebody's turn to do the contract template generation method based on XML to apply in data processing industries, such as Fig. 4 institute Process of the step S30 under an application scenarios in a kind of contract template generation method based on XML in 2 corresponding embodiment of diagram Figure, specifically comprises the following steps:
S301, each XML sky element is ranked up, each XML sky element after being sorted;
Specifically, preset each XML sky element is ranked up, each XML sky element after being sorted, further Ground can label to each XML sky element after each sequence, in order to distinguish.
S302, each target field is ranked up, each target field after being sorted;
Specifically, each target field that setting obtains is ranked up, each target field after being sorted, into one Step ground can label to each target field after each sequence, in order to distinguish.
It should be noted that the mode of sequence can be the sequence arrangement etc. according to each target field from left to right, row The particular content of the mode of sequence can be set, herein with no restrictions according to practical application.
S303, sequence in each XML sky element after sequence is determined as the empty member of current XML near preceding XML sky element Element;
Specifically, sequence in ordering each XML sky element is determined as current XML sky near preceding XML sky element Element.
It should be noted that the mode of sequence can be the sequence arrangement etc. according to each XML sky element from top to bottom, row The particular content of the mode of sequence can be set, herein with no restrictions according to practical application.
S304, sequence in each target field after sequence is determined as current target field near preceding target field;
Specifically, sequence in each target field after sequence is determined as current target word near preceding target field Section.
S305, current XML sky element beginning label and terminate label between, insert current target field and obtain XML Object element;
Specifically, it between the beginning label of current XML sky element and end label, inserts current target field and obtains XML object element, such as<year>with</year>between insert " service life ", or<kilometre>with</kilometre>it Between filling " traveling milimeter number ", obtain<year>service life</year>, or<kilometre>travel milimeter number</ kilometre>。
S306, until having inserted completion until all target fields, next XML of current XML sky element is empty Element is determined as new current XML sky element, and next target field of current target field is determined as new current target Field, and return to step S305.
Specifically, until all target fields are successfully filled into the beginning label of all XML sky elements and terminate to mark Before between note, next XML sky element of current XML sky element is determined as to new current XML sky element, by current target Next target field of field is determined as new current target field, and returns to step S305.
In the corresponding embodiment of Fig. 4, by the way that first each XML sky element is ranked up, each XML after being sorted Each target field is ranked up by empty element, each target field after being sorted, then by each XML after sequence Sequence is determined as current XML sky element near preceding XML sky element in empty element, will sort in each target field after sequence It is determined as current target field near preceding target field, is next marked in the beginning label of current XML sky element and end Between, insert current target field and obtain XML object element, finally until all target fields inserted be completed to it is all Before between the beginning label and end label of XML sky element, next XML sky element of the current XML sky element is determined For new current XML sky element, next target field of the current target field is determined as to new current target field, and It returns and executes between the beginning label and end label of current XML sky element, insert current target field and obtain XML target element The step of element.Because being distinguished in each XML sky element by each target field that will have been sorted, until all target fields are equal Until being successfully filled into all XML sky elements, so improving the success rate of target field filling XML sky element.
In one embodiment, it is somebody's turn to do the contract template generation method based on XML to apply in data processing industries, such as Fig. 5 institute Process of the step S40 under an application scenarios in a kind of contract template generation method based on XML in 2 corresponding embodiment of diagram Figure, specifically comprises the following steps:
S401, it will be arranged in each XML object element near preceding according to the sequence from top to bottom of each XML object element XML object element be determined as XML root element;
In the present embodiment, XML root element is father's element of all elements in XML file, in addition to XML root element XML element is XML daughter element, and XML root element possesses XML daughter element.
Specifically, firstly, the sequence that is arranged above and below according to each XML object element arranges each XML object element Sequence is good, and arrangement in each XML object element to have sorted is then determined as XML root element near preceding XML object element.
S402, according to XML file tree construction mode, using preset XML schema designer by remaining XML object element Nesting obtains target XML file into XML root element, and remaining XML object element is the XML target in addition to XML root element Element.
In the present embodiment, preset XML schema designer can be Visual Studio 2017 etc..
Specifically, according to XML file tree construction mode, using preset XML schema designer, such as Visual Studio 2017, by remaining XML object element nesting into XML root element, obtain target XML file, wherein remaining XML target Element is the XML object element in addition to XML root element.
In the corresponding embodiment of Fig. 5, pass through being arranged above and below each XML mesh sequentially according to each XML object element Arrangement is determined as XML root element near preceding XML object element in mark element, according to XML file tree construction mode, using default XML schema designer by remaining XML object element nesting into XML root element, obtain target XML file, remaining XML Object element is the XML object element in addition to XML root element.Because preset XML schema designer, which has, facilitates operation Function, so using preset XML schema designer by the XML object element nesting in addition to XML root element to XML root element In, target XML file can be obtained easyly, improve the convenience for generating target XML file.
In one embodiment, it is somebody's turn to do the contract template generation method based on XML to apply in data processing industries, such as Fig. 6 institute Displaying target contract template exists in a kind of contract template generation method based on XML in any figure corresponding embodiment in diagram 2 to 5 Flow chart under one application scenarios, specifically comprises the following steps:
Target contract template in S701, calling specified database;
Specifically, the target contract template in specified database is called using preset the second script of SQL.
S702, since the root node of target contract template, each node of target contract template is subjected to stacking;
In the present embodiment, target contract template is the contract XML text that target XML file and the first standard clauses are combined into Part, the root node of target contract template are the root node of contract XML file.
It should be noted that stack is a kind of linear list that operation is limited.
Specifically, each node of target contract template is subjected to stacking since the root node of target contract template, Each node of contract XML file is subjected to stacking i.e. since the root node of contract XML file.
S703, each node of the stacking of target contract template is popped according to sequence is popped, while using pre- If code transformation tool the node popped is converted, the corresponding page display code of the node popped;
In the present embodiment, page display code can be shown for HTML code or javascript show code etc. other Show code.
Specifically, each node of the stacking of target contract template is popped according to sequence is popped, is used simultaneously Preset code transformation tool, such as EasyXML convert the node popped, and the corresponding page of the node popped is aobvious Show code, wherein EasyXML is the XML tool that a XML is translated into HTML code.
It should be noted that the particular content of preset code transformation tool, can be set according to practical application, this Place is with no restrictions.
S704, the page display code of all destination nodes is shown using preset page display method, is obtained To the display page of the contract of new insurance products.
In the present embodiment, preset page font display methods is font display methods, in IE browser GB2312 encodes display methods namely Chinese character display method.
Specifically, the page display code of all destination nodes is shown using preset page font display methods Show, obtains the display page of the contract of new insurance products.
It should be noted that preset page font display methods can also be the UTF-8 display methods in IE browser, The particular content of preset page font display methods, can be set, herein with no restrictions according to practical application, wherein UTF-8, full name are 8-bit Unicode Transformation Format, refer to Unicode.
In the corresponding embodiment of Fig. 6, by calling the target contract template in specified database, from target contract template Root node start, each node of target contract template is subjected to stacking, according to sequence of popping by target contract template Each node of stacking is popped, while being converted the node popped using preset code transformation tool, is gone out The page of all destination nodes is shown generation using preset page display method by the corresponding page display code of the node of stack Code is shown, the display page of the contract of new insurance products is obtained.It, can be according to out because stack, which has, first enters the principle gone out afterwards Stack sequence pops each node of the stacking of target contract template in an orderly manner, while using preset code conversion work Tool converts the node popped, the corresponding page display code of the node that can be popped in an orderly manner, it is possible to have Sequence is fitly shown the page display code of all destination nodes using preset page display method, is newly protected The display page of the contract of dangerous product improves the regularity of the display page for the contract for showing new insurance products.
It should be understood that the size of the serial number of each step is not meant that the order of the execution order in above-described embodiment, each process Execution sequence should be determined by its function and internal logic, the implementation process without coping with the embodiment of the present invention constitutes any limit It is fixed.
In one embodiment, a kind of contract template generating means based on XML are provided, it should be based on the contract template life of XML It is corresponded at the contract template generation method based on XML in device and above-described embodiment.As shown in fig. 7, should the conjunction based on XML Include setup module 701 with template generation device, obtain module 702, first and insert module 703, composite module 704, second fill out Enter module 705 and preserving module 706.Detailed description are as follows for each functional module:
Setup module 701, for each target field of new insurance products to be arranged;
Module 702 is obtained, for obtaining the first standard clauses of new insurance products;
First filling module 703 is obtained for each target field to be respectively filled in preset each XML sky element Each XML object element;
Composite module 704 is obtained for being combined each XML object element using preset XML element combined method To target XML file;
Second filling module 705 obtains new insurance products for inserting target XML file in the first standard clauses Target contract template;
Preserving module 706, for target contract template to be saved in specified database, in order to be produced when the new insurance of generation When the contract of product from specified database invocation target contract template.
Further, obtaining module 702 includes:
First obtains submodule, for obtaining the target type of new insurance products;
Second obtains submodule, and for obtaining existing target type and the second standard clauses, the second standard clauses are The proprietary standard clauses of some target types;
Judging submodule, for judging whether the target type of new insurance products is existing target type;
Third obtains submodule, for obtaining second when the target type of new insurance products is existing target type First standard clauses of the standard clauses as new insurance products, the second standard clauses are the proprietary format item of existing target type Money;
4th obtains submodule, silent for obtaining when the target type of new insurance products is not existing target type Recognize first standard clauses of the standard clauses as new insurance products, default form clause is that preset various target types are general Standard clauses.
Further, the first filling module 703 includes:
First sorting sub-module, each XML sky element for each XML sky element to be ranked up, after being sorted;
Second sorting sub-module, each target field for each target field to be ranked up, after being sorted;
First determines submodule, determines for sorting in each XML sky element after sorting near preceding XML sky element For current XML sky element;
Second determines submodule, for sequence in each target field after sequence to be determined as near preceding target field Current target field;
Input submodule, for inserting current target word between the beginning label of current XML sky element and end label Section obtains XML object element;
Third determines submodule, for until having inserted completion until all target fields, by current XML sky element Next XML sky element be determined as new current XML sky element, next target field of current target field is determined as New current target field, and trigger input submodule.
Further, composite module 704 includes:
4th determines submodule, for the sequence from top to bottom according to each XML object element by each XML target element Arrangement is determined as XML root element near preceding XML object element in element;
Nested submodule is used for according to XML file tree construction mode, will be remaining using preset XML schema designer XML object element nesting obtains target XML file into XML root element, remaining XML object element be except XML root element it Outer XML object element.
Further, the contract template generating means based on XML further include:
Calling module, for calling the target contract template in specified database;
Stacking module, for since the root node of target contract template, each node of target contract template to be carried out Stacking;
It pops module, for each node of the stacking of target contract template to be popped according to sequence is popped, together The preset code transformation tool of Shi Caiyong converts the node popped, and the corresponding page of the node popped shows generation Code;
Display module, for being carried out the page display code of all destination nodes using preset page display method It has been shown that, obtains the display page of the contract of new insurance products.
Specific restriction about the contract template generating means based on XML may refer to above for the conjunction based on XML With the restriction of template generation method, details are not described herein.Modules in the above-mentioned contract template generating means based on XML can It is realized fully or partially through software, hardware and combinations thereof.Above-mentioned each module can be embedded in the form of hardware or independently of meter It calculates in the processor in machine equipment, can also be stored in a software form in the memory in computer equipment, in order to handle Device, which calls, executes the corresponding operation of the above modules.
In one embodiment, a kind of computer equipment is provided, which can be server, internal junction Composition can be as shown in Figure 8.The computer equipment include by system bus connect processor, memory, network interface and Database.Wherein, the processor of the computer equipment is for providing calculating and control ability.The memory packet of the computer equipment Include non-volatile memory medium, built-in storage.The non-volatile memory medium is stored with operating system, computer program and data Library.The built-in storage provides environment for the operation of operating system and computer program in non-volatile memory medium.The calculating The database of machine equipment is for storing the data information that the contract template generation method based on XML is related to.The computer equipment Network interface is used to communicate with external terminal by network connection.To realize one kind when the computer program is executed by processor Contract template generation method based on XML.
In one embodiment, a kind of computer equipment is provided, including memory, processor and storage are on a memory And the computer program that can be run on a processor, processor realize above-described embodiment based on XML's when executing computer program The step of contract template generation method, such as step S10 shown in Fig. 2 to step S60.Alternatively, processor executes computer journey The function of each module/unit of the contract template generating means in above-described embodiment based on XML is realized when sequence, such as shown in Fig. 7 Setup module 701 to preserving module 706 function.To avoid repeating, which is not described herein again.
In one embodiment, a kind of computer readable storage medium is provided, computer program is stored thereon with, is calculated The contract template generation method based on XML in above method embodiment is realized when machine program is executed by processor, alternatively, the calculating Each module in the contract template generating means based on XML/mono- is realized in above-mentioned apparatus embodiment when machine program is executed by processor The function of member.To avoid repeating, which is not described herein again.Those of ordinary skill in the art will appreciate that realizing above-described embodiment method In all or part of the process, be that relevant hardware can be instructed to complete by computer program, the computer journey Sequence can be stored in a non-volatile computer read/write memory medium, and the computer program is when being executed, it may include such as above-mentioned The process of the embodiment of each method.Wherein, to memory, storage, data used in each embodiment provided herein Any reference of library or other media, may each comprise non-volatile and/or volatile memory.Nonvolatile memory may include Read-only memory (ROM), programming ROM (PROM), electrically programmable ROM (EPROM), electrically erasable ROM (EEPROM) Or flash memory.Volatile memory may include random access memory (RAM) or external cache.As explanation Non- limitation, RAM is available in many forms, such as static state RAM (SRAM), dynamic ram (DRAM), synchronous dram (SDRAM), even numbers According to rate SDRAM (DDRSDRAM), enhanced SDRAM (ESDRAM), synchronization link (Synchlink) DRAM (SLDRAM), storage Device bus (Rambus) directly RAM (RDRAM), direct memory bus dynamic ram (DRDRAM) and memory bus dynamic RAM (RDRAM) etc..
It is apparent to those skilled in the art that for convenience of description and succinctly, only with above-mentioned each function Can unit, module division progress for example, in practical application, can according to need and by above-mentioned function distribution by different Functional unit, module are completed, i.e., the internal structure of described device is divided into different functional unit or module, more than completing The all or part of function of description.
Embodiment described above is merely illustrative of the technical solution of the present invention, rather than its limitations;Although referring to aforementioned reality Applying example, invention is explained in detail, those skilled in the art should understand that: it still can be to aforementioned each Technical solution documented by embodiment is modified or equivalent replacement of some of the technical features;And these are modified Or replacement, the spirit and scope for technical solution of various embodiments of the present invention that it does not separate the essence of the corresponding technical solution should all It is included within protection scope of the present invention.

Claims (10)

1. a kind of contract template generation method based on XML, which is characterized in that the contract template generation method based on XML Include:
Each target field of new insurance products is set;
Obtain the first standard clauses of the new insurance products;
Each target field is respectively filled in preset each XML sky element, each XML object element is obtained;
Each XML object element is combined using preset XML element combined method, obtains target XML file;
The target XML file is inserted in first standard clauses, the target contract template of the new insurance products is obtained;
The target contract template is saved in specified database, in order to when generating the contract of the new insurance products from The target contract template is called in the specified database.
2. the contract template generation method based on XML as described in claim 1, which is characterized in that described to obtain the new guarantor First standard clauses of dangerous product include:
Obtain the target type of the new insurance products;
Existing target type and the second standard clauses are obtained, second standard clauses are that the existing target type is proprietary Standard clauses;
Whether the target type for judging the new insurance products is the existing target type;
When the target type of the new insurance products is the existing target type, the second standard clauses conduct is obtained First standard clauses of the new insurance products;
When the target type of the new insurance products is not the existing target type, default form clause is obtained as institute The first standard clauses of new insurance products are stated, the default form clause is the general standard clauses of preset target type.
3. the contract template generation method based on XML as described in claim 1, which is characterized in that described by each mark Field be respectively filled in preset each XML sky element, obtaining each XML object element includes:
Each XML sky element is ranked up, each XML sky element after being sorted;
Each target field is ranked up, each target field after being sorted;
Sequence in each XML sky element after the sequence is determined as current XML sky element near preceding XML sky element;
Sequence in each target field after the sequence is determined as current target field near preceding target field;
Between the beginning label and end label of the current XML sky element, the current target field is inserted, XML is obtained Object element;
It is until having inserted completion until all target fields, next XML sky element of the current XML sky element is true It is set to new current XML sky element, next target field of the current target field is determined as to new current target word Section, and return and execute the beginning label in the current XML sky element and terminate to insert the current target between label Field obtains the step of XML object element.
4. the contract template generation method based on XML as described in claim 1, which is characterized in that described to use preset XML Each XML object element is combined by element combinations method, is obtained target XML file and is included:
According to the sequence from top to bottom of each XML object element by arrangement in each XML object element near preceding XML object element be determined as XML root element;
According to XML file tree construction mode, using preset XML schema designer by remaining XML object element nesting to institute It states in XML root element, obtains target XML file, the remaining XML object element is the XML in addition to the XML root element Object element.
5. the contract template generation method based on XML according to any one of claims 1 to 4, which is characterized in that described After the target contract template is saved in specified database, the contract template generation method based on XML further include:
Call the target contract template in the specified database;
Since the root node of the target contract template, each node of the target contract template is subjected to stacking;
Each node of the stacking of the target contract template is popped according to sequence is popped, while using preset generation Code crossover tool converts the node popped, the corresponding page display code of the node popped;
The page display code of all destination nodes is shown using preset page display method, is obtained described The display page of the contract of new insurance products.
6. a kind of contract template generating means based on XML, which is characterized in that the contract template generating means based on XML Include:
Setup module, for each target field of new insurance products to be arranged;
Module is obtained, for obtaining the first standard clauses of the new insurance products;
First filling module obtains each for each target field to be respectively filled in preset each XML sky element XML object element;
Composite module obtains target for being combined each XML object element using preset XML element combined method XML file;
Second filling module obtains the new insurance and produces for inserting the target XML file in first standard clauses The target contract template of product;
Preserving module, for the target contract template to be saved in specified database, in order to when the generation new insurance The target contract template is called when the contract of product from the specified database.
7. the contract template generating means based on XML as claimed in claim 6, which is characterized in that the acquisition module includes:
First obtains submodule, for obtaining the target type of the new insurance products;
Second obtains submodule, and for obtaining existing target type and the second standard clauses, second standard clauses are institute State the proprietary standard clauses of existing target type;
Judging submodule, for judging whether the target type of the new insurance products is the existing target type;
Third obtains submodule, for obtaining when the target type of the new insurance products is the existing target type First standard clauses of second standard clauses as the new insurance products;
4th obtains submodule, for obtaining when the target type of the new insurance products is not the existing target type Take default form clause as the first standard clauses of the new insurance products, the default form clause is preset target class The general standard clauses of type.
8. the contract template generating means based on XML as described in any one of claim 6 to 7, which is characterized in that described One, which inserts module, includes:
First sorting sub-module, for each XML sky element to be ranked up, each XML sky element after being sorted;
Second sorting sub-module, for each target field to be ranked up, each target field after being sorted;
First determines submodule, determines for will sort in each XML sky element after the sequence near preceding XML sky element For current XML sky element;
Second determines submodule, for sequence in each target field after the sequence to be determined as near preceding target field Current target field;
Input submodule, for inserting the current mark between the beginning label of the current XML sky element and end label Field obtain XML object element;
Third determines submodule, for until having inserted completion until all target fields, by the current XML sky element Next XML sky element is determined as new current XML sky element, and next target field of the current target field is determined For new current target field, and trigger the input submodule.
9. a kind of computer equipment, including memory, processor and storage are in the memory and can be in the processor The computer program of upper operation, which is characterized in that the processor realized when executing the computer program as claim 1 to The step of contract template generation method described in any one of 5 based on XML.
10. a kind of computer readable storage medium, the computer-readable recording medium storage has computer program, and feature exists In contract mould of the realization as described in any one of claims 1 to 5 based on XML when the computer program is executed by processor The step of plate generation method.
CN201811113578.2A 2018-09-25 2018-09-25 Contract template generation method, device, equipment and medium based on XML Pending CN109446499A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201811113578.2A CN109446499A (en) 2018-09-25 2018-09-25 Contract template generation method, device, equipment and medium based on XML

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201811113578.2A CN109446499A (en) 2018-09-25 2018-09-25 Contract template generation method, device, equipment and medium based on XML

Publications (1)

Publication Number Publication Date
CN109446499A true CN109446499A (en) 2019-03-08

Family

ID=65530758

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201811113578.2A Pending CN109446499A (en) 2018-09-25 2018-09-25 Contract template generation method, device, equipment and medium based on XML

Country Status (1)

Country Link
CN (1) CN109446499A (en)

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110347984A (en) * 2019-05-20 2019-10-18 中国平安财产保险股份有限公司 Declaration form page variation, device, computer equipment and storage medium
CN110378795A (en) * 2019-06-17 2019-10-25 中国平安人寿保险股份有限公司 A kind of generation method of provision file, device, storage medium and server
CN110609808A (en) * 2019-09-19 2019-12-24 中国银行股份有限公司 File sending method and device

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101493839A (en) * 2009-03-04 2009-07-29 北京航空航天大学 Method for generating general-purpose test document
CN102855304A (en) * 2012-08-20 2013-01-02 清华大学 Variable-clause electronic contract automatic generation method in business to customer (B2C) transaction
CN106021594A (en) * 2016-06-06 2016-10-12 福建榕基软件股份有限公司 Database table and XML message mapping processing method and system
CN106610921A (en) * 2015-10-23 2017-05-03 镇江金软计算机科技有限责任公司 User-defined tag-based contract template realization method
CN107766304A (en) * 2017-10-23 2018-03-06 国电南瑞科技股份有限公司 A kind of binary profile file generation method based on XML

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101493839A (en) * 2009-03-04 2009-07-29 北京航空航天大学 Method for generating general-purpose test document
CN102855304A (en) * 2012-08-20 2013-01-02 清华大学 Variable-clause electronic contract automatic generation method in business to customer (B2C) transaction
CN106610921A (en) * 2015-10-23 2017-05-03 镇江金软计算机科技有限责任公司 User-defined tag-based contract template realization method
CN106021594A (en) * 2016-06-06 2016-10-12 福建榕基软件股份有限公司 Database table and XML message mapping processing method and system
CN107766304A (en) * 2017-10-23 2018-03-06 国电南瑞科技股份有限公司 A kind of binary profile file generation method based on XML

Cited By (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110347984A (en) * 2019-05-20 2019-10-18 中国平安财产保险股份有限公司 Declaration form page variation, device, computer equipment and storage medium
CN110347984B (en) * 2019-05-20 2024-05-03 中国平安财产保险股份有限公司 Policy page changing method and device, computer equipment and storage medium
CN110378795A (en) * 2019-06-17 2019-10-25 中国平安人寿保险股份有限公司 A kind of generation method of provision file, device, storage medium and server
CN110378795B (en) * 2019-06-17 2024-03-15 中国平安人寿保险股份有限公司 Method and device for generating clause file, storage medium and server
CN110609808A (en) * 2019-09-19 2019-12-24 中国银行股份有限公司 File sending method and device

Similar Documents

Publication Publication Date Title
CN109446499A (en) Contract template generation method, device, equipment and medium based on XML
CN106991143B (en) Multi-layer image file, generation method and device, read method and device
Majeau‐Bettez et al. Unified theory of allocations and constructs in life cycle assessment and input‐output analysis
CN110489561A (en) Knowledge mapping construction method, device, computer equipment and storage medium
CN109445842A (en) Rule generating method, device, computer equipment and storage medium
US20210049711A1 (en) Method of automatically transmitting data information and device of automatically transmitting data information
Pham et al. Practical anti-counterfeit medicine management system based on blockchain technology
CN111160140B (en) Image detection method and device
CN110009225A (en) Risk evaluating system construction method, device, computer equipment and storage medium
CN110362542B (en) Nuclear power station file encoding method and device, computer equipment and storage medium
CN105204920B (en) A kind of implementation method and device of the distributed computing operation based on mapping polymerization
CN107895311A (en) A kind of method and apparatus of order matching distribution
CN104992297A (en) Electricity fee collection risk assessment device based on big data platform clustering algorithm and method thereof
CN110033515A (en) Figure conversion method, device, computer equipment and storage medium
CN110119440A (en) Contract automatic generation method, device, computer equipment and storage medium
CN105740293B (en) Data export method and device
CN105912723A (en) Storage method of custom field
CN109360111A (en) Questionnaire data modification method, device, computer equipment and storage medium
Nungesser et al. Modelling Hazard for Tailings Dam Failures at Copper Mines in Global Supply Chains
CN106933783A (en) A kind of method and device on the intelligent extraction date from text
CN113486097B (en) Big data export method, device, equipment and storage medium
CN110097250A (en) Product risks prediction technique, device, computer equipment and storage medium
CN109657929A (en) Appraisal procedure, device and the computer equipment of trade mark registration percent of pass
CN113610512A (en) Electronic signature generation method, device, equipment and storage medium
CN108121754A (en) A kind of method and device for obtaining keyword attribute combination

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