CN110019970A - Inventory downloads template creation method, device, terminal and readable storage medium storing program for executing - Google Patents

Inventory downloads template creation method, device, terminal and readable storage medium storing program for executing Download PDF

Info

Publication number
CN110019970A
CN110019970A CN201810622915.4A CN201810622915A CN110019970A CN 110019970 A CN110019970 A CN 110019970A CN 201810622915 A CN201810622915 A CN 201810622915A CN 110019970 A CN110019970 A CN 110019970A
Authority
CN
China
Prior art keywords
template
inventory
file
excel
downloads template
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
CN201810622915.4A
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 Life Insurance Company of China Ltd
Original Assignee
Ping An Life Insurance Company of China 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 Life Insurance Company of China Ltd filed Critical Ping An Life Insurance Company of China Ltd
Priority to CN201810622915.4A priority Critical patent/CN110019970A/en
Publication of CN110019970A publication Critical patent/CN110019970A/en
Pending legal-status Critical Current

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/80Information retrieval; Database structures therefor; File system structures therefor of semi-structured data, e.g. markup language structured data such as SGML, XML or HTML
    • G06F16/84Mapping; Conversion
    • 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/177Editing, e.g. inserting or deleting of tables; using ruled lines
    • G06F40/18Editing, e.g. inserting or deleting of tables; using ruled lines of spreadsheets

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Audiology, Speech & Language Pathology (AREA)
  • Computational Linguistics (AREA)
  • General Health & Medical Sciences (AREA)
  • Health & Medical Sciences (AREA)
  • Artificial Intelligence (AREA)
  • Data Mining & Analysis (AREA)
  • Databases & Information Systems (AREA)
  • Management, Administration, Business Operations System, And Electronic Commerce (AREA)

Abstract

The present invention provides a kind of inventory downloads template creation method, comprising: receives the data format definition information that user is inputted based on template data configuration interface, and according to the data format definition information, generates Excel template file;The Excel template file is parsed, XML content information is obtained;According to the XML content information, corresponding inventory downloads template is created.The present invention also provides a kind of inventory downloads template creating device, terminal and readable storage medium storing program for executing.The creation of inventory downloads template can be completed without user's craft binding data variable after input data format defines information, without manual format transformation in user of the present invention, greatly improves the convenience and efficiency of the creation of inventory downloads template.

Description

Inventory downloads template creation method, device, terminal and readable storage medium storing program for executing
Technical field
The present invention relates to computer field more particularly to a kind of inventory downloads template creation method, device, terminals and readable Storage medium.
Background technique
With the fast development of network technology, banking and insurance business field gradually adopts database purchase insurance data and number of users According to, and with the continuous sale of insurance, the insurance data and user data stored in database is also more and more, in practical operation In the process, there is the case where needs are from database downloading data inventory, and database purchase has a large amount of insurance data and user Data, it is therefore desirable to create inventory downloads template, downloading data could be found from a large amount of insurance data and user data Data needed for inventory, thus downloading data inventory.
Currently, the creation mode of inventory download module is that excel file is converted to XML (Extensible Markup Language, extensible markup language) then the file of format tied up in data variable and by user's craft binding data variable After fixed completion, the inventory that the file of XML format is converted to ST (Structured Text, structured text) format is downloaded Template, however, user, in manual binding data variable, since quantitative variation is more, the binding of data variable is relatively complicated, and It is related to multiple format conversion, is easy to appear mistake, needs to be implemented the creation operation of multiple inventory downloads templates, be not easy to user certainly Definition creation inventory downloads template.
Therefore, inventory downloads template how is easily created, the creation efficiency for improving inventory downloads template is at present urgently It solves the problems, such as.
Summary of the invention
The main purpose of the present invention is to provide a kind of inventory downloads template creation method, device, terminal and readable storages Medium, it is intended to improve the convenience and efficiency of the creation of inventory downloads template.
To achieve the above object, the present invention provides a kind of inventory downloads template creation method, the inventory downloads template wound Construction method the following steps are included:
The data format definition information that user is inputted based on template data configuration interface is received, and according to the data format Information is defined, Excel template file is generated;
The Excel template file is parsed, XML content information is obtained;
According to the XML content information, corresponding inventory downloads template is created.
Optionally, according to the data format definition information, the step of generating corresponding Excel template file, includes:
Excel title, sheet pages of title, column field name and data are obtained from the data format definition information to tie up Determine variable-definition relationship;
Relationship, generation pair are defined according to the Excel title, sheet pages of title, column field name and data binding variable The Excel template file answered.
Optionally, the Excel template file is parsed, obtain XML content information the step of include:
Currently available memory source is obtained, and corresponding parsing strategy is selected according to the currently available memory source;
The parsing strategy is executed, the Excel template file is parsed, XML content information is obtained.
Optionally, include: according to the step that the currently available memory source selects corresponding parsing tactful
Determine free memory resource section locating for the currently available memory source;
The mapping table between the free memory resource section prestored and parsing policy tag is inquired, can be used described in acquisition The corresponding parsing policy tag in memory source section;
Corresponding parsing strategy is selected according to the parsing policy tag.
Optionally, according to the XML content information, the step of creating corresponding inventory downloads template, includes:
According to the XML content information, the Excel template file is decomposed into the file pattern submodule of preset format Plate, sheet pages of subtemplate, data binding variable subtemplate and special-effect subtemplate;
According to the file pattern subtemplate, sheet pages of subtemplate, data binding variable subtemplate and special-effect submodule Plate creates corresponding inventory downloads template.
Optionally, according to the XML content information, after the step of creating corresponding inventory downloads template, further includes:
When detecting the parameter edit requests of inventory downloads template of triggering, obtained from the parameter edit requests clear Single downloads template mark;
It is determined as inventory downloads template to be edited for corresponding inventory downloads template is identified with the inventory downloads template;
The inventory downloads template to be edited is converted into corresponding Excel template file to be edited, and in the mould The Excel template file to be edited is opened in plate data configuration interface.
Optionally, according to the XML content information, after the step of creating corresponding inventory downloads template, further includes:
When the inventory for detecting triggering downloads request, inventory downloading request is sent to server;
It receives the server and the data that request returns is downloaded based on the inventory, and obtained from inventory downloading request Inventory downloads template is taken to identify;
Inventory downloads template corresponding with the inventory downloads template mark is obtained, and the data of return are filled to described Inventory downloads template, to generate list file.
In addition, to achieve the above object, the present invention also provides a kind of inventory downloads template creating device, the inventory downloading Template creating device includes:
In addition, to achieve the above object, the present invention also provides a kind of inventory downloads templates to create terminal, the inventory downloading Template creation terminal includes processor, memory and is stored on the memory and can be executed by the processor clear Single downloads template creates program, wherein realizing when inventory downloads template creation program is executed by the processor as above-mentioned Inventory downloads template creation method the step of.
In addition, to achieve the above object, the present invention also provides a kind of readable storage medium storing program for executing, being deposited on the readable storage medium storing program for executing Inventory downloads template creation program is contained, wherein realizing as above when inventory downloads template creation program is executed by processor The step of inventory downloads template creation method stated.
The present invention provides a kind of inventory downloads template creation method, device, terminal and readable storage medium storing program for executing, passes through and provides number According to the visualization input interface of format definition information, information is defined convenient for user/developer's input data format, and visualize The edit mode at interface and the edit mode of Excel file are identical, user-friendly, in addition, user is in input data format After defining information, inventory downloads template can be completed without user's craft binding data variable without manual format transformation Creation, greatly improve inventory downloads template creation convenience and efficiency.
Detailed description of the invention
Fig. 1 is the hardware structural diagram that the inventory downloads template that various embodiments of the present invention are related to creates terminal;
Fig. 2 is the flow diagram of inventory downloads template creation method first embodiment of the present invention;
Fig. 3 is the refinement flow diagram of step S101 in first embodiment of the invention;
Fig. 4 is the refinement flow diagram of step S102 in second embodiment of the invention;
Fig. 5 is the flow diagram of inventory downloads template creation method 3rd embodiment of the present invention;
Fig. 6 is the functional block diagram of inventory downloads template creating device first embodiment of the present invention.
The embodiments will be further described with reference to the accompanying drawings for the realization, the function and the advantages of the object of the present invention.
Specific embodiment
It should be appreciated that the specific embodiments described herein are merely illustrative of the present invention, it is not intended to limit the present invention.
The present embodiments relate to inventory downloads template creation method be mainly used in inventory downloads template creation terminal, Inventory downloads template creation terminal can be PC (personal computer personal computer), portable computer, movement eventually The equipment that end etc. has display and processing function.
Referring to Fig.1, Fig. 1 is that the hardware configuration of the creation terminal of inventory downloads template involved in the embodiment of the present invention shows It is intended to.In the embodiment of the present invention, inventory downloads template creation terminal may include (such as the central processing unit of processor 1001 Central Processing Unit, CPU), communication bus 1002, user interface 1003, network interface 1004, memory 1005.Wherein, communication bus 1002 is for realizing the connection communication between these components;User interface 1003 may include display Shield (Display), input unit such as keyboard (Keyboard);Network interface 1004 optionally may include that the wired of standard connects Mouth, wireless interface (such as WI-FI interface);Memory 1005 can be high speed RAM memory, be also possible to stable memory (non-volatile memory), such as magnetic disk storage, memory 1005 optionally can also be independently of aforementioned processor 1001 storage device.It will be understood by those skilled in the art that hardware configuration shown in Fig. 1 is not constituted to limit of the invention It is fixed, it may include perhaps combining certain components or different component layouts than illustrating more or fewer components.
With continued reference to Fig. 1, the memory 1005 in Fig. 1 as a kind of readable storage medium storing program for executing may include operating system, net Network communication module and inventory downloads template create program.In Fig. 1, network communication module is mainly used for connecting server, with Server carries out data communication;And processor 1001 can call the inventory downloads template stored in memory 1005 to create journey Sequence, and execute inventory downloads template creation method provided in an embodiment of the present invention.
The embodiment of the invention provides a kind of inventory downloads template creation methods.
It is the flow diagram of inventory downloads template creation method first embodiment of the present invention referring to Fig. 2, Fig. 2.
In the present embodiment, which is realized by inventory downloads template creation terminal, under the inventory Back(ing) board creation terminal can be the terminals such as PC, palm PC and tablet computer, be chosen as terminal shown in FIG. 1, the inventory Downloads template creation method the following steps are included:
Step S101 receives the data format definition information that user is inputted based on template data configuration interface, and according to number According to format definition information, Excel template file is generated;
Step S102 parses Excel template file, obtains XML content information;
Step S103 creates corresponding inventory downloads template according to XML content information.
Currently, the creation mode of inventory download module is that excel file is converted to XML (Extensible Markup Language, extensible markup language) then the file of format tied up in data variable and by user's craft binding data variable After fixed completion, the inventory that the file of XML format is converted to ST (Structured Text, structured text) format is downloaded Template, however, user, in manual binding data variable, since quantitative variation is more, the binding of data variable is relatively complicated, and It is related to multiple format conversion, is easy to appear mistake, needs to be implemented the creation operation of multiple inventory downloads templates, be not easy to user certainly Definition creation inventory downloads template.In view of the above problem, a kind of inventory downloads template creation method is proposed in the present embodiment, When needing to create inventory download module, user defines information by visualization interface input data format, and terminal receives user's base In the data format definition information of template data configuration interface input, and according to data format definition information, Excel template is generated Then file parses Excel template file, obtain XML content information, and finally according to XML content information, creation is corresponded to Inventory downloads template, to improve the convenience and efficiency of inventory downloads template.
The specific foundation step of inventory downloads template is realized in this programme described in detail below:
Step S101 receives the data format definition information that user is inputted based on template data configuration interface, and according to number According to format definition information, Excel template file is generated;
In the present embodiment, terminal is equipped with inventory template visualization tool, when user needs to create inventory downloads template, The icon of click or touch-control inventory template visualization tool, at this point, inventory downloads template creates terminal indicating template data configuration Interface, and the edit mode of the template data configuration interface is identical as the edit mode of Excel file, user can be according to editor The mode input data format of Excel file defines information, and terminal receives what user was inputted based on template data configuration interface Data format definition information, and according to the data format definition information, generate Excel template file.
Wherein, which is the related data format information for defining Excel template file, including But it is not limited to Excel title, sheet pages of title, column field name, data binding variable and defines relationship and file pattern, Excel The mark of entitled Excel template file to be generated, for uniquely indicating Excel template file, sheet pages of entitled Excel Sheet pages of mark in template file, for uniquely indicating sheet pages, column field name is current in Excel template file Column mark in sheet pages, for uniquely indicating that column, data binding variable define the correspondence between contextual definition column and data Relationship is bound a variable by each column and is realized, file pattern includes the font of text, word in Excel template file to be generated Number and color etc..
Further, the data type that developer can be related to according to database, as attribution data month, secondary facility, Number of policy, receipt number, charge time, card number, the amount of money, insurer, warrantee, beneficiary, operator, commission pay dues type, hold Card name claims, passport NO., orphan singly indicate, fee-collector's division code, fee-collector's department name, fee-collector's type, fee-collector Code, fee-collector's name, solicitor's division code, solicitor's department name, solicitor's type, solicitor's code, solicitor's surname Name, region code, feedback result, whether contact client, client whether know business personnel leave office, preset each data type with The corresponding relationship of variable, then user inputs column field name according to the corresponding relationship of setting, and according to the column field name of input Data type belonging to claiming binds corresponding variable, defines relationship without user input data binding variable.
Specifically, include: referring to Fig. 3, step S101
Step S1011, from data format definition information obtain Excel title, sheet pages of title, column field name and Data binding variable defines relationship;
In this step, the data format definition information that user is inputted based on template data configuration interface is with the side of mapping table Formula stores in the terminal, and when data format definition information input is completed, terminal is obtained from the data format definition information Excel title, sheet pages of title, column field name and data binding variable define relationship, i.e., from the storage data format definition The gauge outfit field of each gauge outfit is read in the mapping table of information, and inquiry table head file is Excel title, sheet from mapping table Page, column field and data binding variable define the gauge outfit of relationship, obtain Excel title, sheet pages of title, column field name and Data binding variable defines relationship.Wherein, gauge outfit field includes but is not limited to Excel title, sheet pages, column field and data Binding variable defines relationship.
Step S1012 defines relationship according to Excel title, sheet pages of title, column field name and data binding variable, Generate corresponding Excel template file.
In this step, terminal obtains the Excel title of Excel template file to be generated, sheet pages of title, column field After identifying the corresponding relationship (pass through each column bind variable realize) between column and data, with the Excel it is entitled to Generate Excel template file title, with sheet pages of title in this sheet pages entitled Excel template file to be generated, The initial Excel template file frame of an Exclude Col field is generated, then according to the initial Excel template file frame from a left side The column of initial Excel template file frame are successively written in each column field name by sequence of turning right, and based between column and data Corresponding relationship binds corresponding variable, to generate corresponding Excel template file.
Step S102 parses Excel template file, obtains XML content information;
In the present embodiment, terminal parses the Excel template file after generating Excel template file, obtains XML content information, wherein the XML content information includes but is not limited to Excel title, sheet pages of title, column field name, number Relationship and file pattern are defined according to binding variable, the analysis mode of Excel template file includes but is not limited to SAX (Simple API for XML, handle XML event-driven) parsing, DOM (Document Object Model, DOM Document Object Model) parsing, JDOM (Java Document Object Model, Java DOM Document Object Model) parsing and DOM4J (open source XML parsing packet) solution Analysis.
Specifically, it is illustrated by taking SAX parsing and DOM parsing as an example, SAX parsing is carried out to the Excel template file Sequential scan, and the xml content information scanned is read into memory, until the end of scan of Excel template file;DOM Parsing is all to load the Excel template file to memory, and construct a resident tree in memory, then right The tree is scanned, and the xml content information scanned is read into memory, until the scanning knot of the tree Beam.
Step S103 creates corresponding inventory downloads template according to XML content information.
In the present embodiment, terminal parses Excel template file, after obtaining XML content information, according to the XML Content information creates corresponding inventory downloads template, wherein inventory downloads template is by Excel file pattern subtemplate Head.st, sheet pages of subtemplates, data binding variable subtemplate and special-effect subtemplate create.
Specifically, in the present embodiment, step S103 includes:
Step a1, according to XML content information, by Excel template file be decomposed into preset format file pattern subtemplate, Sheet pages of subtemplate, data binding variable subtemplate and special-effect subtemplate;
In this step, Excel template file is decomposed into the file sample of preset format according to XML content information by terminal Formula template, sheet pages of subtemplate, data binding variable subtemplate and special-effect subtemplate, i.e., by the Excel of XML format Template file is decomposed into four subtemplates (Excel file pattern subtemplate head.st, sheet pages of subtemplates, numbers of ST format According to binding variable subtemplate and special-effect subtemplate).Wherein, Excel file pattern subtemplate head.st defines Excel The pattern of file, such as font, font size and color;Sheet pages of subtemplate body_head.st defines single sheet pages of head Portion, such as sheet include how many row, Duo Shaolie, sheet pages of titles and column name;Data binding variable subtemplate body_ Row.st defines the corresponding relationship between column and data, binds a variable by each column to realize;Special-effect submodule Plate body_end.st defines specific function, such as drop-down list and pop-up box.
Step a2, according to file pattern subtemplate, sheet pages of subtemplate, data binding variable subtemplate and special-effect Subtemplate creates corresponding inventory downloads template.
In this step, terminal by Excel template file be decomposed into preset format file pattern subtemplate, sheet pages After subtemplate, data binding variable subtemplate and special-effect subtemplate, according to file pattern subtemplate, sheet pages of submodule Plate, data binding variable subtemplate and special-effect subtemplate, create corresponding inventory downloads template, i.e., inventory downloads template by Head.st, sheet pages of subtemplates of Excel file pattern subtemplate, data binding variable subtemplate and special-effect subtemplate wound It builds.Wherein, special-effect subtemplate is inessential template, head.st, sheet pages of submodules of Excel file pattern subtemplate Plate, data binding variable subtemplate are necessary template.
In the present embodiment, the data format definition information that reception user is inputted based on template data configuration interface, and according to Data format definition information generates Excel template file, then parses to Excel template file, obtains XML content letter Breath, then according to XML content information, creates corresponding inventory downloads template.In the above manner, the present embodiment is by providing number According to the visualization input interface of format definition information, information is defined convenient for user/developer's input data format, and visualize The edit mode at interface and the edit mode of Excel file are identical, user-friendly, in addition, user is in input data format After defining information, inventory downloads template can be completed without user's craft binding data variable without manual format transformation Creation, realize the automatic conversion of format and the automatic binding of data variable, greatly improve inventory downloads template creation Convenience and efficiency.
Further, referring to Fig. 4, it is based on above-mentioned first embodiment, proposes inventory downloads template creation method of the present invention Second embodiment, the difference with previous embodiment is that step S102 includes:
Step S1021 obtains currently available memory source, and selects corresponding parsing plan according to currently available memory source Slightly;
In this step, terminal obtains terminal after generating Excel template file according to data format definition information Currently available memory source, and corresponding parsing strategy is selected according to currently available memory source, then execute the parsing of selection Strategy.Wherein, parsing strategy includes but is not limited to SAX parsing strategy, DOM parsing strategy, JDOM parsing strategy and DOM4J parsing Strategy.
Specifically, it after terminal obtains currently available memory source, determines in can be used locating for currently available memory source Resource section is deposited, and inquires the mapping table between the free memory resource section prestored and parsing policy tag, acquisition can With the corresponding parsing policy tag in memory source section, corresponding parsing strategy is then selected according to parsing policy tag.It needs Illustrate, the mapping relations between the free memory resource section prestored and parsing policy tag can be by those skilled in the art It is arranged based on actual conditions, the present embodiment is not especially limited this.
Step S1022 executes parsing strategy, parses to Excel template file, obtains XML content information.
In this step, after selecting corresponding parsing strategy, the parsing strategy of selection is executed, to Excel template text Part is parsed, and XML content information is obtained.Wherein, which includes but is not limited to Excel title, sheet pages of name Title, column field name, data binding variable define relationship and file pattern.For example, the parsing strategy selected parses plan for DOM Slightly, then the Excel template file is all loaded to memory, and constructs a resident tree in memory, it is then right The tree is scanned, and the xml content information scanned is read into memory, until the scanning knot of the tree Beam.
In the present embodiment, corresponding parsing strategy is selected by the currently available memory source of terminal, to Excel template text Part is parsed, and the memory source of reasonable utilization terminal is capable of, and the resolution speed of Excel template file is improved, thus into one The creation efficiency of the raising inventory downloads template of step.
Further, referring to Fig. 5, above-mentioned first or second embodiments are based on, propose inventory downloads template wound of the present invention The 3rd embodiment of construction method, the difference with previous embodiment are, after step S103, the inventory downloads template creation method Further include:
Step 104, it when detecting the parameter edit requests of inventory downloads template of triggering, is obtained from parameter edit requests Inventory downloads template is taken to identify;
Terminal exists in creation inventory downloads template, and after storing the inventory downloads template and needs to edit inventory downloading The case where parameter in template, since the inventory downloads template of creation is ST format, ST format needs user to have higher programming Otherwise ability is easy to cause the inventory downloads template after editor unavailable, for this purpose, the present embodiment provides a kind of inventories to download mould The specific edit mode of plate, is only explained below, other to can refer to previous embodiment.
In this step, terminal is in the parameter edit requests for detecting inventory downloads template, from the parameter edit requests Middle acquisition inventory downloads template mark, that is, determine the mark of inventory downloads template to be edited, and inventory downloads template mark is used In uniquely expression inventory downloads template.
Step 105, corresponding inventory downloads template will be identified with inventory downloads template is determined as inventory downloading to be edited Template;
It in this step, will be corresponding with inventory downloads template mark clear after getting inventory downloads template mark Single downloads template is determined as inventory downloads template to be edited, that is, inquires the inventory downloads template mark prestored and download mould with inventory Mapping table between plate determines that the inventory downloads template identifies corresponding inventory downloads template, and the inventory is downloaded mould Plate is determined as inventory downloads template to be edited.
Step 106, inventory downloads template to be edited is converted into corresponding Excel template file to be edited, and in mould Excel template file to be edited is opened in plate data configuration interface.
In this step, terminal by with inventory downloads template identify corresponding inventory downloads template be determined as it is to be edited After inventory downloads template, inventory downloads template to be edited is converted into corresponding Excel template file to be edited, and in mould Excel template file to be edited is opened in plate data configuration interface, i.e., will edit the biggish inventory downloads template of difficulty, is converted It is smaller for editor's difficulty, and facilitate the Excel template file of editor.
In the present embodiment, it by the way that inventory downloads template to be edited is converted to Excel template file, and is visualizing The Excel template file is opened in interface, so that user can the corresponding inventory downloading of editor in the way of editing Excel file Template greatly facilitates user and edits inventory downloads template, the effective editor's simplicity for improving inventory downloads template.
Further, it is based on above-mentioned first, second or third embodiment, proposes inventory downloads template of the present invention creation side The fourth embodiment of method, the difference with previous embodiment are, after step S103, which is also wrapped It includes:
Inventory downloading request is sent to server when the inventory for detecting triggering downloads request by step b;
It should be noted that a kind of specific generating mode of list file is proposed the present invention is based on previous embodiment, It is only explained below, other can refer to previous embodiment.
In this step, inventory downloading request is sent to service in the inventory downloading request for detecting triggering by terminal Device obtains corresponding data based on the data query conditions in inventory downloading request by the server from database, and will The data return to terminal.Wherein, inventory downloading request carries the information such as inventory downloads template mark and terminal recognition code.
Step c receives server based on inventory and downloads the data that request returns, and obtains inventory from inventory downloading request Downloads template mark;
In this step, terminal receives server and downloads the data that request returns based on the inventory, and asks from inventory downloading Middle acquisition inventory downloads template is asked to identify, wherein to can determine corresponding inventory downloads template based on inventory downloads template mark, i.e., The mapping table that the inventory downloads template mark and inventory downloads template that prestore can be inquired, determines that the inventory downloads template identifies Corresponding inventory downloads template.
Step d obtains inventory downloads template corresponding with inventory downloads template mark, and the data of return is filled to clear Single downloads template, to generate list file.
In this step, terminal obtains clear with this after getting inventory downloads template mark in inventory downloading request Single downloads template identifies corresponding inventory downloads template, and the data of return are filled to inventory downloads template, to generate data Inventory file specially parses the data variable in the inventory downloads template, and is closed according to the binding between data variable and column System, and fill the data to respective column according to the sequencing of line number.Wherein, the generating mode of list file includes Timing generates and Mass production, the data that server timing returns to default number of branches is generated as in real time, by terminal by default number of branches Data are filled to inventory downloads template to generate list file;Mass production first obtains for server meets data query item The total data of part, then returns to terminal for total data, is filled the total data of return to inventory by terminal and downloads mould Plate is to generate list file.
In the present embodiment, when detecting inventory downloading request, listings data is obtained from server, and by listings data Filling greatly facilitates user's downloading data inventory file to generate list file to inventory downloads template.
In addition, the embodiment of the present invention also provides a kind of inventory downloads template creating device.
It is the functional block diagram of inventory downloads template creating device first embodiment of the present invention referring to Fig. 6, Fig. 6.
Inventory downloads template creating device of the present invention is virtual bench, is stored in the creation of inventory downloads template shown in Fig. 1 eventually In the memory 1005 at end, the institute for realizing inventory downloads template creation program is functional;Inventory downloads template creating device Each module when being executed by processor 1001, it is possible to provide data format definition information visuallization input interface, convenient for user/open Hair personnel's input data format defines information, and the edit mode of visualization interface is identical as the edit mode of Excel file, side Just user uses, in addition, user after input data format defines information, is not necessarily to manual format transformation, without user hand Work binding data variable, can be completed the creation of inventory downloads template, realize format automatic conversion and data variable from Dynamic binding, greatly improves the convenience and efficiency of the creation of inventory downloads template.
Specifically, in the present embodiment, the inventory downloads template creating device includes:
File generating module 101, the data format definition letter inputted for receiving user based on template data configuration interface Breath, and according to the data format definition information, generate Excel template file;
Document analysis module 102 obtains XML content information for parsing to the Excel template file;
Template creation module 103, for creating corresponding inventory downloads template according to the XML content information.
Further, the file generating module 101 includes:
Data capture unit, for obtaining Excel title, sheet pages of title, column from the data format definition information Field name and data binding variable define relationship;
File generating unit becomes for being bound according to the Excel title, sheet pages of title, column field name and data Definition relationship is measured, corresponding Excel template file is generated.
Further, the document analysis module 102 includes:
Policy selection unit is selected for obtaining currently available memory source, and according to the currently available memory source Corresponding parsing strategy;
Strategy execution unit parses the Excel template file, obtains XML for executing the parsing strategy Content information.
Further, the policy selection unit is also used to:
Determine free memory resource section locating for the currently available memory source;
The mapping table between the free memory resource section prestored and parsing policy tag is inquired, can be used described in acquisition The corresponding parsing policy tag in memory source section;
Corresponding parsing strategy is selected according to the parsing policy tag.
Further, the template creation module 103 includes:
Decomposition unit, for according to the XML content information, the Excel template file to be decomposed into preset format File pattern subtemplate, sheet pages of subtemplate, data binding variable subtemplate and special-effect subtemplate;
Template creating unit, for according to the file pattern subtemplate, sheet pages of subtemplate, data binding variable Template and special-effect subtemplate create corresponding inventory downloads template.
Further, the inventory downloads template creating device further include:
Detection obtains module, for when detecting the parameter edit requests of inventory downloads template of triggering, from the ginseng Inventory downloads template mark is obtained in number edit requests;
Template determining module, for being determined as inventory downloads template corresponding with the inventory downloads template mark wait compile The inventory downloads template collected;
Display module is converted, for the inventory downloads template to be edited to be converted to corresponding Excel mould to be edited Plate file, and the Excel template file to be edited is opened in the template data configuration interface.
Further, the inventory downloads template creating device further include:
Request sending module, for the inventory being downloaded request and is sent when the inventory for detecting triggering downloading request To server;
Data reception module downloads the data that request returns based on the inventory for receiving the server, and from institute It states in inventory downloading request and obtains inventory downloads template mark;
Database population module for obtaining inventory downloads template corresponding with the inventory downloads template mark, and will return The data returned are filled to the inventory downloads template, to generate list file.
Wherein, the function of modules is realized and above-mentioned inventory downloads template wound in above-mentioned inventory downloads template creating device Each step is corresponding in construction method embodiment, and function and realization process no longer repeat one by one here.
In addition, the embodiment of the present invention also provides a kind of readable storage medium storing program for executing.
Inventory downloads template creation program is stored on readable storage medium storing program for executing of the present invention, wherein the inventory downloads template is created When building program and being executed by processor, realize such as the step of above-mentioned inventory downloads template creation method.
Wherein, inventory downloads template creation program, which is performed realized method, can refer to inventory downloads template of the present invention Each embodiment of creation method, details are not described herein again.
It should be noted that, in this document, the terms "include", "comprise" or its any other variant are intended to non-row His property includes, so that the process, method, article or the system that include a series of elements not only include those elements, and And further include other elements that are not explicitly listed, or further include for this process, method, article or system institute it is intrinsic Element.In the absence of more restrictions, the element limited by sentence "including a ...", it is not excluded that including being somebody's turn to do There is also other identical elements in the process, method of element, article or system.
The serial number of the above embodiments of the invention is only for description, does not represent the advantages or disadvantages of the embodiments.
Through the above description of the embodiments, those skilled in the art can be understood that above-described embodiment side Method can be realized by means of software and necessary general hardware platform, naturally it is also possible to by hardware, but in many cases The former is more preferably embodiment.Based on this understanding, technical solution of the present invention substantially in other words does the prior art The part contributed out can be embodied in the form of software products, which is stored in one as described above In storage medium (such as ROM/RAM, magnetic disk, CD), including some instructions are used so that terminal device (it can be mobile phone, Computer, server, air conditioner or network equipment etc.) execute method described in each embodiment of the present invention.
The above is only a preferred embodiment of the present invention, is not intended to limit the scope of the invention, all to utilize this hair Equivalent structure or equivalent flow shift made by bright specification and accompanying drawing content is applied directly or indirectly in other relevant skills Art field, is included within the scope of the present invention.

Claims (10)

1. a kind of inventory downloads template creation method, which is characterized in that the inventory downloads template creation method includes following step It is rapid:
The data format definition information that user is inputted based on template data configuration interface is received, and according to the data format definition Information generates Excel template file;
The Excel template file is parsed, XML content information is obtained;
According to the XML content information, corresponding inventory downloads template is created.
2. inventory downloads template creation method as described in claim 1, which is characterized in that believed according to the data format definition Breath, the step of generating corresponding Excel template file include:
Excel title, sheet pages of title, column field name and data binding is obtained from the data format definition information to become Measure definition relationship;
Relationship is defined according to the Excel title, sheet pages of title, column field name and data binding variable, is generated corresponding Excel template file.
3. inventory downloads template creation method as described in claim 1, which is characterized in that the Excel template file into Row parsing, obtain XML content information the step of include:
Currently available memory source is obtained, and corresponding parsing strategy is selected according to the currently available memory source;
The parsing strategy is executed, the Excel template file is parsed, XML content information is obtained.
4. inventory downloads template creation method as claimed in claim 3, which is characterized in that provided according to the currently available memory Source select it is corresponding parsing strategy step include:
Determine free memory resource section locating for the currently available memory source;
The mapping table between the free memory resource section prestored and parsing policy tag is inquired, the free memory is obtained The corresponding parsing policy tag in resource section;
Corresponding parsing strategy is selected according to the parsing policy tag.
5. inventory downloads template creation method as described in claim 1, which is characterized in that according to the XML content information, wound The step of building corresponding inventory downloads template include:
According to the XML content information, by the Excel template file be decomposed into preset format file pattern subtemplate, Sheet pages of subtemplate, data binding variable subtemplate and special-effect subtemplate;
According to the file pattern subtemplate, sheet pages of subtemplate, data binding variable subtemplate and special-effect subtemplate, Create corresponding inventory downloads template.
6. inventory downloads template creation method according to any one of claims 1 to 5, which is characterized in that according to the XML Content information, after the step of creating corresponding inventory downloads template, further includes:
When detecting the parameter edit requests of inventory downloads template of triggering, obtained under inventory from the parameter edit requests Back(ing) board mark;
It is determined as inventory downloads template to be edited for corresponding inventory downloads template is identified with the inventory downloads template;
The inventory downloads template to be edited is converted into corresponding Excel template file to be edited, and in the template number According to opening the Excel template file to be edited in configuration interface.
7. inventory downloads template creation method according to any one of claims 1 to 5, which is characterized in that according to the XML Content information, after the step of creating corresponding inventory downloads template, further includes:
When the inventory for detecting triggering downloads request, inventory downloading request is sent to server;
It receives the server and downloads the data for requesting to return based on the inventory, and obtained clearly from inventory downloading request Single downloads template mark;
Inventory downloads template corresponding with the inventory downloads template mark is obtained, and the data of return are filled to the inventory Downloads template, to generate list file.
8. a kind of inventory downloads template creating device, which is characterized in that the inventory downloads template creating device includes:
File generating module, the data format definition information inputted for receiving user based on template data configuration interface, and root According to the data format definition information, Excel template file is generated;
Document analysis module obtains XML content information for parsing to the Excel template file;
Template creation module, for creating corresponding inventory downloads template according to the XML content information.
9. a kind of inventory downloads template creates terminal, which is characterized in that the inventory downloads template creation terminal include processor, It memory and is stored on the memory and program can be created by the inventory downloads template that the processor executes, wherein When the inventory downloads template creation program is executed by the processor, realize clear as described in any one of claims 1 to 7 The step of single downloads template creation method.
10. a kind of readable storage medium storing program for executing, which is characterized in that be stored with inventory downloads template creation journey on the readable storage medium storing program for executing Sequence, wherein being realized as described in any one of claims 1 to 7 when inventory downloads template creation program is executed by processor Inventory downloads template creation method the step of.
CN201810622915.4A 2018-06-15 2018-06-15 Inventory downloads template creation method, device, terminal and readable storage medium storing program for executing Pending CN110019970A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201810622915.4A CN110019970A (en) 2018-06-15 2018-06-15 Inventory downloads template creation method, device, terminal and readable storage medium storing program for executing

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201810622915.4A CN110019970A (en) 2018-06-15 2018-06-15 Inventory downloads template creation method, device, terminal and readable storage medium storing program for executing

Publications (1)

Publication Number Publication Date
CN110019970A true CN110019970A (en) 2019-07-16

Family

ID=67188298

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201810622915.4A Pending CN110019970A (en) 2018-06-15 2018-06-15 Inventory downloads template creation method, device, terminal and readable storage medium storing program for executing

Country Status (1)

Country Link
CN (1) CN110019970A (en)

Cited By (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110399420A (en) * 2019-07-30 2019-11-01 广州吉信网络科技开发有限公司 A kind of deriving method, electronic equipment and the medium of configurableization Excel format
CN111666745A (en) * 2020-06-03 2020-09-15 中国建设银行股份有限公司 File downloading method, device, server and medium
CN112560415A (en) * 2020-12-18 2021-03-26 深圳市元征科技股份有限公司 Data processing method, device, equipment and medium
CN113051219A (en) * 2019-12-26 2021-06-29 贵州白山云科技股份有限公司 Database management method, device, equipment and storage medium

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20080306981A1 (en) * 2007-06-06 2008-12-11 Oracle International Corporation Extensible Document Transformation Language: An Innovative Way of Generating Business Document and Report
CN101777045A (en) * 2008-09-01 2010-07-14 西北工业大学 Method for analyzing XML file by indexing
CN107688456A (en) * 2017-05-05 2018-02-13 平安科技(深圳)有限公司 Document generating method, equipment and computer-readable recording medium

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20080306981A1 (en) * 2007-06-06 2008-12-11 Oracle International Corporation Extensible Document Transformation Language: An Innovative Way of Generating Business Document and Report
CN101777045A (en) * 2008-09-01 2010-07-14 西北工业大学 Method for analyzing XML file by indexing
CN107688456A (en) * 2017-05-05 2018-02-13 平安科技(深圳)有限公司 Document generating method, equipment and computer-readable recording medium

Cited By (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110399420A (en) * 2019-07-30 2019-11-01 广州吉信网络科技开发有限公司 A kind of deriving method, electronic equipment and the medium of configurableization Excel format
CN110399420B (en) * 2019-07-30 2022-11-22 广州吉信网络科技开发有限公司 Export method, electronic equipment and medium of configurable Excel format
CN113051219A (en) * 2019-12-26 2021-06-29 贵州白山云科技股份有限公司 Database management method, device, equipment and storage medium
CN111666745A (en) * 2020-06-03 2020-09-15 中国建设银行股份有限公司 File downloading method, device, server and medium
CN112560415A (en) * 2020-12-18 2021-03-26 深圳市元征科技股份有限公司 Data processing method, device, equipment and medium

Similar Documents

Publication Publication Date Title
CN110019970A (en) Inventory downloads template creation method, device, terminal and readable storage medium storing program for executing
TWI416342B (en) Designating, setting, and discovering parameters for spreadsheet documents
US9348482B2 (en) Modeling system for graphic user interface
US9430455B2 (en) Methods and systems for intelligent form-filling and electronic document generation
CN101122899B (en) Report generation method and device
CN108628741A (en) Webpage test method, device, electronic equipment and medium
CN101661512A (en) System and method for identifying traditional form information and establishing corresponding Web form
CN104331640B (en) Project concluding report analysis system and method based on biological cloud platform
CN109657215A (en) Document structure tree method, equipment, storage medium and device based on template
CN102929646B (en) Application program generation method and device
CN112287013A (en) Data conversion method and adapter
CN109710250A (en) It is a kind of for constructing the visualization engine system and method for user interface
CN112083919A (en) YAML template-based target service code generation method and device
CN110069573A (en) Product data integration method, apparatus, computer equipment and storage medium
US8140977B2 (en) Hosted data visualization service
CN108170409A (en) The development approach and system of WEB front-end control
CN104081347A (en) Graphical representation of an order of operations
CN117236356A (en) Label on-line design and printing method based on WEB
JP4133549B2 (en) Structured document file management apparatus and structured document file management method
CN112257392B (en) Method, device and equipment for generating computer program operation document
CN108874829A (en) Processing method, device, smart machine and the computer storage medium of webpage
CN113672222A (en) Application program interface management device and construction method thereof
CN112825038A (en) Visual page making method based on general component language specification and related product
CN109597845A (en) Report configuration method, device, computer equipment and storage medium
CN116911264B (en) Large PDF annotation method and device

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