[go: up one dir, main page]
More Web Proxy on the site http://driver.im/

CN109240625A - A kind of document structure tree method, apparatus and computer storage medium suitable for printing - Google Patents

A kind of document structure tree method, apparatus and computer storage medium suitable for printing Download PDF

Info

Publication number
CN109240625A
CN109240625A CN201810903428.5A CN201810903428A CN109240625A CN 109240625 A CN109240625 A CN 109240625A CN 201810903428 A CN201810903428 A CN 201810903428A CN 109240625 A CN109240625 A CN 109240625A
Authority
CN
China
Prior art keywords
placeholder
document
category
document template
identification information
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
CN201810903428.5A
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.)
Shenzhen Pocket Network Technology Co Ltd
Original Assignee
Shenzhen Pocket Network Technology 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 Shenzhen Pocket Network Technology Co Ltd filed Critical Shenzhen Pocket Network Technology Co Ltd
Priority to CN201810903428.5A priority Critical patent/CN109240625A/en
Publication of CN109240625A publication Critical patent/CN109240625A/en
Pending legal-status Critical Current

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/12Digital output to print unit, e.g. line printer, chain printer
    • G06F3/1201Dedicated interfaces to print systems
    • G06F3/1202Dedicated interfaces to print systems specifically adapted to achieve a particular effect
    • G06F3/1203Improving or facilitating administration, e.g. print management
    • G06F3/1206Improving or facilitating administration, e.g. print management resulting in increased flexibility in input data format or job format or job type
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/12Digital output to print unit, e.g. line printer, chain printer
    • G06F3/1201Dedicated interfaces to print systems
    • G06F3/1223Dedicated interfaces to print systems specifically adapted to use a particular technique
    • G06F3/1237Print job management
    • G06F3/1253Configuration of print job parameters, e.g. using UI at the client
    • G06F3/1257Configuration of print job parameters, e.g. using UI at the client by using pre-stored settings, e.g. job templates, presets, print styles

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Human Computer Interaction (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Document Processing Apparatus (AREA)

Abstract

The embodiment of the invention discloses a kind of document structure tree method, apparatus and computer storage medium suitable for printing, this method comprises: obtaining the document template for having been filled with placeholder of at least one classification;After getting print command, the classification logotype information and placeholder replacement instruction information that the print command carries are determined;Instruction information is replaced according to the placeholder, each placeholder in the corresponding document template of the classification logotype information is replaced, document to be printed is obtained.It can be seen that, the embodiment of the present invention is not merely to obtain document to be printed based on intrinsic template, but the document template for meeting use demand can be obtained by way of filling placeholder, and placeholder replacement is carried out by the way of the replacement placeholder determined by print command to obtained document template, obtain document to be printed;In this way, the embodiment of the present invention neatly can obtain document to be printed according to use demand, print from the definition is realized.

Description

Document generation method and device suitable for printing and computer storage medium
Technical Field
The invention relates to a document custom printing technology, in particular to a document generation method and device suitable for printing and a computer storage medium.
Background
With the popularization of a cloud computing and Software-as-a-Service (SaaS) system, more and more enterprise services can be managed by using the SaaS system conveniently, but the more users of the SaaS system, the higher the requirements on the SaaS system are, the higher the personalized requirements of the users of the SaaS system are, and the higher the requirements on the SaaS system are.
In some printing schemes of the existing SaaS system, a user-defined template cannot be printed according to the use requirements of a user, or the printing can be performed only on the basis of one or more inherent templates; in other printing schemes of the existing SaaS system, a certain degree of custom printing of the SaaS system can be realized by dragging a control, or the certain degree of custom printing of the SaaS system can be realized by assisting a client-side ActiveX plug-in, where the ActiveX: is the name given by Microsoft (Microsoft) to a series of strategic Object-oriented programming techniques and tools, the main technique of which is the Component Object Model (COM), which becomes distributed COM (dcom) in networks with directories and other support; the scheme for realizing the custom printing of the SaaS system by dragging the control is complex and complicated to operate, and can not be used by most users; according to the scheme for realizing the custom printing of the SaaS system by the aid of the ActiveX plug-ins, the client plug-ins need to be installed, and the problems of complex use, low compatibility and the like exist;
in summary, the printing scheme of the existing SaaS system cannot realize custom printing through a simple operation mode, and cannot really meet the user requirements.
Disclosure of Invention
Embodiments of the present invention are intended to provide a method, an apparatus, and a computer storage medium for generating a document suitable for printing, and aim to solve the problem that custom printing of a SaaS system cannot be realized by a simple operation mode.
The embodiment of the invention provides a document generation method suitable for printing, which comprises the following steps:
acquiring at least one category of document templates filled with placeholders;
after a printing instruction is acquired, determining category identification information and placeholder replacement indication information carried by the printing instruction, wherein the category identification information is used for identifying the category of a document template, and the placeholder replacement indication information is used for indicating: a replacement mode of each placeholder in the document template corresponding to the category identification information;
and replacing each placeholder in the document template corresponding to the category identification information according to the placeholder replacement indication information to obtain the document to be printed.
In the above solution, the placeholder in the document template of each category is predetermined according to the usage requirement.
In the above scheme, the obtaining the document template of at least one category filled with placeholders includes:
opening a document template of at least one category without filling placeholders based on office software, and filling the opened document template with placeholders to obtain the document template of at least one category with filled placeholders.
In the foregoing solution, replacing each placeholder in the document template corresponding to the category identification information according to the placeholder replacement indication information to obtain a document to be printed includes:
according to the placeholder replacement indication information, determining replacement content of each placeholder in the document template corresponding to the category identification information;
and replacing each placeholder in the document template corresponding to the category identification information according to the determined replacement content to obtain the document to be printed.
In the foregoing solution, the determining, according to the placeholder replacement indication information, the replacement content of each placeholder in the document template corresponding to the category identification information includes:
determining a database corresponding to the placeholder replacement indication information, wherein the database corresponding to the placeholder replacement indication information is used for storing replacement content of each placeholder in the document template corresponding to the category identification information;
and determining the replacement content of each placeholder in the document template corresponding to the category identification information in the database corresponding to the placeholder replacement indication information.
The embodiment of the invention also provides a document generating device suitable for printing, which comprises: the device comprises an acquisition module and a determination module; wherein,
the acquisition module is used for acquiring at least one category of document templates filled with placeholders; after a printing instruction is acquired, a determining module is triggered;
the determining module is used for determining category identification information and placeholder replacement indication information carried by the printing instruction when triggered, and replacing each placeholder in the document template corresponding to the category identification information according to the placeholder replacement indication information to obtain a document to be printed; wherein the category identification information is used for identifying a category of the document template, and the placeholder replacement indication information is used for indicating that: and replacing each placeholder in the document template corresponding to the category identification information.
In the above solution, the placeholder in the document template of each category is predetermined according to the usage requirement.
In the foregoing scheme, the obtaining module is specifically configured to open at least one category of document templates without placeholders being filled based on office software, fill placeholders in the opened document templates, and obtain the at least one category of document templates with placeholders being filled.
The embodiment of the invention also provides another document generation device suitable for printing, which comprises a processor and a memory for storing a computer program capable of running on the processor; wherein,
the processor is configured to execute the steps of any one of the above-mentioned document printing methods when running the computer program.
Embodiments of the present invention further provide a computer storage medium, on which a computer program is stored, where the computer program, when executed by a processor, implements the steps of any one of the above-mentioned document generation methods suitable for printing.
In the embodiment of the invention, at least one type of document template filled with placeholders is obtained; then, after a printing instruction is acquired, determining category identification information and placeholder replacement indication information carried by the printing instruction, wherein the category identification information is used for identifying the category of the document template, and the placeholder replacement indication information is used for indicating: a replacement mode of each placeholder in the document template corresponding to the category identification information; and replacing each placeholder in the document template corresponding to the category identification information according to the placeholder replacement indication information to obtain the document to be printed.
It can be seen that, in the embodiment of the present invention, the document to be printed is not obtained based on the inherent template, but the document template meeting the use requirement can be obtained by filling the placeholder, and the placeholder is replaced for the obtained document template in the manner of replacing the placeholder determined by the print instruction, so as to obtain the document to be printed; therefore, the document to be printed can be flexibly obtained according to the use requirement, the user-defined printing is realized, the printing is realized in the embodiment of the invention without adopting complicated operation modes such as dragging a control and the like, and the document to be printed is obtained through a simple mode of filling placeholders and replacing the placeholders, so that the user-defined printing is realized.
Drawings
FIG. 1 is a flow chart of a document generation method suitable for printing according to an embodiment of the present invention;
FIG. 2 is a schematic diagram of an unfilled placeholder document template in accordance with embodiments of the present invention;
FIG. 3 is a schematic diagram of a placeholder populated document template, in accordance with embodiments of the present invention;
FIG. 4 is a schematic view of a document to be printed according to an embodiment of the present invention;
FIG. 5 is a diagram illustrating a document template submission process according to an embodiment of the present invention;
FIG. 6 is a schematic illustration of a printing process flow according to an embodiment of the invention;
fig. 7 is a schematic diagram of a printing flow of the Saas system in an embodiment of the present invention;
FIG. 8 is a schematic diagram of a workflow of an Office document synthesizer according to an embodiment of the present invention;
FIG. 9 is a diagram illustrating a decompression result of a document template according to an embodiment of the present invention;
FIG. 10 is a schematic diagram of a document creation apparatus suitable for printing according to an embodiment of the present invention;
FIG. 11 is a diagram illustrating a hardware configuration of another document generating apparatus suitable for printing according to an embodiment of the present invention.
Detailed Description
The technical solution in the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings in the embodiments of the present invention.
The embodiment Of the invention can be applied to a terminal or a server, wherein the terminal can be a fixed terminal such as a computer or the like, and can also be a mobile terminal, the mobile terminal refers to a computer device which can be used in moving, and the mobile terminal broadly comprises a mobile phone, a notebook, a tablet computer, a Point Of Sale (POS) machine, a vehicle-mounted computer and the like; in the embodiment of the present invention, the type of the operating system used by the terminal is not limited.
Based on the above description, the following specific examples are proposed
Example one
Fig. 1 is a flowchart of a document generating method suitable for printing according to an embodiment of the present invention, and as shown in fig. 1, the flowchart may include:
step 101: a placeholder-populated document template for at least one category is obtained.
Here, the document template may be used to represent a template of a document that can be opened using computer software, and the document template may have various implementation forms, for example, the document template may or may not include a form; in practical application, the computer software may be Office software such as word, excel, ppt, and accordingly, the document template may be all types of Office document templates, such as word, excel, ppt, and the like.
In the document template, each placeholder represents occupation of a fixed position, in one document template, the placeholder can be predetermined according to use requirements, specifically, a user can define the placeholder in one document template according to own use requirements, and in one document template, the placeholder can be one or multiple.
In an embodiment, the document templates may be classified according to at least one of: the function and implementation form of the document template, for example, the category of the document template derived according to the function of the document template may include: an approval form, an attendance form, an evaluation form, and the like.
In practical implementation, the document template of each category may be predefined according to the usage requirement, so that the document template of each category may conform to the file specification and usage habit of the user,
for an implementation of obtaining the document template with the filled placeholders of the at least one category, in one example, the document template with the unfilled placeholders of the at least one category may be opened based on office software, and the placeholders may be filled in the opened document template, so as to obtain the document template with the filled placeholders of the at least one category.
For example, fig. 2 is a schematic diagram of a document template without filling placeholders according to an embodiment of the present invention, in actual implementation, after the document template (i.e., a official reception and approval table) shown in fig. 2 is opened by office software, it can be found that some positions in the table in fig. 2 need to be filled with corresponding contents, for example, corresponding contents need to be filled at positions behind guest units, guest numbers, signatures, and the like, the positions may be filled with placeholders first, and the format of the placeholders may be { { xxx } } or other formats with tag characteristics, where xxx represents a user tag, and for example, a position that requires a Saas system fill unit may adopt a custom tag { { unit } }; after filling placeholders with respect to FIG. 2, a schematic diagram of the placeholder filled document template shown in FIG. 3 can be obtained, wherein in FIG. 3, { { name } }, { { age } } and the like denote filled placeholders; the office software may be office editing tools, such as microsoft office or wps software.
In the embodiment of the invention, the document template filled with the placeholders is a template file filled with tags.
Step 102: after a printing instruction is acquired, determining category identification information and placeholder replacement indication information carried by the printing instruction, wherein the category identification information is used for identifying the category of a document template, and the placeholder replacement indication information is used for indicating: a replacement mode of each placeholder in the document template corresponding to the category identification information;
that is, the printing instruction at least carries the category identification information and the placeholder replacement indication information, and it can be seen that a category of document template can be determined according to the category identification information; because the placeholder replacement indication information indicates the replacement mode of each placeholder in the document template corresponding to the category identification information, the placeholder replacement mode of the document template of one category can be determined according to the category identification information and the placeholder replacement indication information.
Step 103: replacing each placeholder in the document template corresponding to the category identification information according to the placeholder replacement indication information to obtain a document to be printed;
in practical application, after the print instruction is acquired, the document template corresponding to the category identification information carried by the print instruction can be searched from the document templates which are acquired in advance and have been filled with the placeholders and in at least one category.
That is to say, when the print instruction is acquired, the document to be printed is not generated, but the placeholder of the document template of one category is replaced according to the category identification information and the placeholder replacement indication information in the print instruction, so as to obtain the document to be printed.
For example, if the document template corresponding to the category identification information carried by the print instruction is: the document template filled with the placeholders shown in fig. 3 can be subjected to placeholder replacement according to the placeholder replacement indication information carried in the printing instruction, so as to obtain the document to be printed shown in fig. 4.
For the implementation manner of this step, in an example, the selectable replacement content of each placeholder in the document template of each category may be stored in advance, and the placeholder replacement indication information carried in the print instruction is used to indicate how to find the replacement content of the placeholder in the document template of the corresponding category stored in advance, for example, for the document template shown in fig. 3, the selectable replacement content of each placeholder in the document template shown in fig. 3 may be stored in advance, so that after the print instruction is obtained, the replacement content of each placeholder in the document template shown in fig. 3 may be found according to the placeholder replacement indication information, and then the replacement of the placeholder is completed.
It should be noted that the form of the optional alternative content of each placeholder can be characters, pictures or other forms.
In practice, at least one database may be used to store the optional replacement content for each placeholder in each category of document template.
Further, for each category of document template, a plurality of databases may be set in advance; a preset placeholder replacement mode of the document template corresponding to each database; the placeholder replacement indication information can be database identification information, so that after the printing instruction is obtained, a database corresponding to the placeholder replacement indication information can be determined, wherein the database corresponding to the placeholder replacement indication information is used for storing replacement content of each placeholder in the document template corresponding to the category identification information;
after the database corresponding to the placeholder replacement indication information is determined, the replacement content of each placeholder in the document template corresponding to the category identification information can be determined in the database corresponding to the placeholder replacement indication information, and then placeholder replacement is completed.
For example, for the document template shown in fig. 3, databases 1 to 5 may be preset, where the databases 1 to 5 are used to store 5 different replacement contents of the placeholders in the document template shown in fig. 3, and if the database corresponding to the placeholder replacement indication information in the print instruction is the database 2, the replacement content of each placeholder in the document template shown in fig. 3 may be found in the database 2.
It can be seen that for a type of document template filled with placeholders, different users can set different placeholder replacement modes, and then different documents to be printed are obtained.
Steps 101 to 103 may be implemented by a device such as a processor in a terminal or a server
Further, after step 103, the document to be printed may also be printed.
It can be understood that, in the embodiment of the present invention, the document to be printed is not obtained based on the inherent template, but a document template meeting the use requirement may be obtained by filling the placeholder, and the placeholder is replaced for the obtained document template in a manner of replacing the placeholder determined by the print instruction, so as to obtain the document to be printed; in addition, each type of document template can be predetermined according to the use requirement, so that the document to be printed can be flexibly obtained according to the use requirement to realize the custom printing, and the document to be printed is obtained by simply filling placeholders and replacing the placeholders without adopting complicated operation modes such as dragging controls and the like to realize the printing, so that the custom printing is realized.
Example two
In order to further embody the object of the present invention, the foregoing embodiments of the present invention are further illustrated.
The second embodiment of the present invention can be applied to a server using a SaaS system in which the server and a terminal used by a client form a communication connection; here, SaaS is a mode of providing software through the internet, in practical applications, a manufacturer can uniformly deploy application software on its own server, and a customer can order a desired application software service from the manufacturer through the internet according to its actual needs, pay a fee to the manufacturer according to the amount and duration of the service ordered, and obtain the service provided by the manufacturer through the internet.
Illustratively, the flow of the document printing method of the embodiment of the present invention may include a document template submission flow and a printing flow, which are respectively described below.
Fig. 5 is a schematic diagram of a document template submission process according to an embodiment of the present invention, and as shown in fig. 5, the process may include:
step 501: on the terminal side, a user positions the placeholders in the document templates of each category according to the use requirements, and submits the defined placeholders to a server of the SaaS system.
Step 502: at the terminal side, a document template of at least one category which is not filled with placeholders is opened, and predefined placeholders are filled.
The implementation of this step has already been explained in the foregoing embodiments, and is not described here again.
Step 503: submitting the document template of the at least one category filled with the placeholders to a server of the SaaS system.
For example, if the document templates are classified according to functions, after the document templates are submitted to a server of the SaaS system, in the SaaS system, the document templates with the placeholders filled in each category may be associated with the functions of the document templates, so that the SaaS system may perform association binding of the functions of the document templates according to the placeholders filled document templates.
Fig. 6 is a schematic diagram of a printing process according to an embodiment of the present invention, and as shown in fig. 6, the process may include:
step 601: and when the server of the SaaS system receives the printing instruction, searching the document template according to the printing instruction.
In practical application, a printing instruction can be generated at a terminal side, and then the terminal sends the printing instruction to a server of the SaaS system; in addition, the implementation of searching for a document template according to a print instruction has been described in the foregoing embodiments, and is not described here again.
Step 602: and the server of the SaaS system determines each placeholder in the searched document template.
Step 603: and the server of the SaaS system searches the replacing content of the placeholder according to the placeholder replacing indication information in the printing instruction, and replaces the placeholder with the corresponding content in the searched document template to obtain the document to be printed.
The implementation of steps 602 to 603 has already been described in the foregoing embodiments, and is not described here again.
Step 604: and the server of the SaaS system sends the document to be printed to the terminal and informs the printer of the terminal to print.
The flow of the SaaS system document printing method shown in fig. 5 and fig. 6 is described by a specific application embodiment, in which the official acceptance examination and approval table shown in fig. 2 is taken as an example for description, and the application embodiment can be described by the following steps
The method comprises the following steps: opening the official business reception examination and approval table shown in fig. 2 by using an office editing tool, and filling placeholders in fig. 2 to obtain a document template shown in fig. 3; for ease of explanation, the document template that has been filled with placeholders may be referred to as an ml file.
Step two: an administrator with a defined process logs in the Saas system, a process which is 'official approval' is defined, and the process comprises the following steps: the fields, field names, etc. of the unit, name, number of people, etc. are kept consistent with xxx in the definition tag { { xxx } } of step one, and the m1 file created in step one is selected, and then all fields, process names and template files are submitted to the database, assuming that the id of the definition process is 123.
Here, the administrator-defined flow is used to represent the above-mentioned document template filled with placeholders, and the id and name of the flow are category identification information used to represent the category of the flow; when the administrator submits all the fields, process names and template files to the database, the fact that the document template which is not filled with the placeholder is stored in the database is indicated.
Step three: the process applicant logs in the Saas system, selects a process with id of 123 and process name of "official acceptance and approval" and fills in the corresponding application field, and submits the application, at this time, the Saas system will generate a process example of official acceptance and approval, assuming that the example id is 456,
here, the flow applicant can make the Saas system know the placeholder replacement mode of the corresponding flow (document template) by filling in the corresponding application field, and obviously, the Saas system can determine the corresponding relationship between the flow instance with id 456 and the flow with id 123.
Step four: and the process approver logs in the Saas system to complete the approval of the process example of the official acceptance approval with the id number of 456.
Step five: after the flow of the process example of the official reception approval with the id of 456 is completed, the administrator who prints the process example clicks a print button of an interface, so that the custom printing of the official reception approval process can be completed, and the final output result is a pdf file shown in fig. 4, where:
in actual implementation, when the administrator who prints the process instance clicks a print button of the interface, the Saas system knows that the process corresponding to the process instance whose id number is 456 and which is subject to approval is the process whose id is 123, and knows the placeholder replacement manner of the process whose id is 123 (i.e., knows the placeholder replacement indication information), and thus the Saas system can generate the above-mentioned print instruction.
Fig. 7 is a schematic diagram of a printing process of the Saas system in an embodiment of the present invention, and as shown in fig. 7, the printing process may include:
step 701: the client initiates a request to the server to print an instance of the flow with id 456.
The server here is a server of the Saas system.
Step 702: the server retrieves the information associated with the flow instance with id 456.
Specifically, the server may retrieve information associated with the process instance with id 456 from the database, where the information associated with the process instance with id 456 includes ml files with id 123, and application data and approval data of the process instance with id 456.
Step 703: and synthesizing the document by using an Office document synthesizer to obtain the file with the replaced placeholder.
That is to say, an Office document synthesizer is used for carrying out document synthesis on the ml file with the id of 123, the application data and the approval data of the process example with the id of 456, and a file with the placeholder replaced, namely the file with the data filled, is obtained.
FIG. 8 is a schematic diagram of a workflow of an Office document synthesizer, as shown in FIG. 8, the workflow may include:
step A1: after receiving the document template in the compressed format, the Office document synthesizer decompresses the received document template to obtain a decompressed document template;
it should be noted that, after the received document template is decompressed, the decompression result shown in fig. 9 can be obtained, as can be seen from fig. 9, the decompression result mainly includes an Extensible Markup Language (xml) file and some resources, the resources in the decompression result may be files referenced externally, such as pictures or music, and are constructed through a certain format and rules, and the Office document synthesizer performs searching, replacing, and writing operations on the xml file according to the specification of the Office document after decompression, and finally obtains the Office file that is usually used through compression.
Step A2: and searching the document template with the corresponding label (the document template filled with the corresponding placeholder) in the decompressed document template, and acquiring the content required to be filled in the document template with the corresponding label (which can be acquired through the application data and the approval data of the process example).
Step A3: and filling corresponding content in the searched document template to obtain the uncompressed file after the placeholder is replaced.
In practical applications, a template engine for filling the document template content may be provided in the Office document synthesizer, and step a3 may be implemented by using the template engine.
Here, the template engine may be a template engine for Web development, which is generated to separate a user interface from business data (contents), and generates a document in a specific format, and the template engine for a Web site generates a standard HTML document.
Step A4: and compressing the uncompressed file after replacing the placeholder to obtain the file after replacing the placeholder.
Further, the Office document synthesizer can output the file with the replaced placeholder after obtaining the file with the replaced placeholder.
Step 704: and converting the file after the placeholder replacement into a PDF file, and sending the PDF file to the client.
Here, the file after placeholder replacement can be converted into a PDF file by using OpenOffice software or other Office editing tools with similar functions (such as microsoft Office). OpenOffice software is a set of cross-platform office software suite, can be executed on operating systems such as Windows, Linux, MacOS X (X11) and Solaris, and is compatible with all main office software suites.
Step 705: the received PDF file is printed at the client.
In practical applications, PDF file printing can be realized by using a module or software for printing PDF at a client.
In a related scene of processing services by using the SaaS system, a user hopes that printing can be carried out according to a common file specification and a use habit, and the existing printing scheme of the SaaS system cannot realize custom printing through a simple operation mode; in the embodiment of the invention, the SaaS system is printed by setting placeholders, filling placeholders in the document template and replacing the placeholders of the document template by fully utilizing the existing document editing tools such as office and the like without changing the using habits of users; during printing, the original file specification and the use habit of a user can be maintained without loss, and the whole printing process does not need extra skill learning of the user, so that the embodiment of the invention can realize the user-defined printing requirement of the user with high efficiency and high fidelity.
EXAMPLE III
On the basis of the document generating method suitable for printing proposed by the foregoing embodiment, the third embodiment of the present invention provides a document printing apparatus.
FIG. 10 is a schematic diagram showing the constitution of a document printing apparatus according to an embodiment of the present invention, and as shown in FIG. 10, the apparatus includes an obtaining module 1001 and a determining module 1002; wherein,
an obtaining module 1001 configured to obtain at least one category of document templates filled with placeholders; after a printing instruction is acquired, a determining module is triggered;
the determining module 1002 is configured to determine category identification information and placeholder replacement indication information carried by the print instruction when triggered, and replace each placeholder in the document template corresponding to the category identification information according to the placeholder replacement indication information to obtain a document to be printed; wherein the category identification information is used for identifying a category of the document template, and the placeholder replacement indication information is used for indicating that: and replacing each placeholder in the document template corresponding to the category identification information.
In one embodiment, the placeholders in the document template of each category are predetermined according to usage requirements.
In an embodiment, the obtaining module 1001 is specifically configured to open at least one category of document templates without placeholders being filled in based on office software, fill placeholders in the opened document templates, and obtain at least one category of document templates with placeholders being filled in.
In an embodiment, the determining module 1002 is specifically configured to determine, according to the placeholder replacement indication information, replacement content of each placeholder in the document template corresponding to the category identification information; and replacing each placeholder in the document template corresponding to the category identification information according to the determined replacement content to obtain the document to be printed.
In an embodiment, the determining module 1002 is specifically configured to determine a database corresponding to the placeholder replacement indication information, where the database corresponding to the placeholder replacement indication information is used to store replacement content of each placeholder in a document template corresponding to the category identification information; and determining the replacement content of each placeholder in the document template corresponding to the category identification information in the database corresponding to the placeholder replacement indication information.
In practical applications, the obtaining module 1001 and the determining module 1002 can be implemented by a Central Processing Unit (CPU), a microprocessor Unit (MPU), a Digital Signal Processor (DSP), a Field Programmable Gate Array (FPGA), or the like.
In addition, each functional module in this embodiment may be integrated into one processing unit, or each unit may exist alone physically, or two or more units are integrated into one unit. The integrated unit can be realized in a form of hardware or a form of a software functional module.
Based on the understanding that the technical solution of the present embodiment essentially or a part contributing to the prior art, or all or part of the technical solution may be embodied in the form of a software product stored in a storage medium, and include several instructions for causing a computer device (which may be a personal computer, a server, or a network device, etc.) or a processor (processor) to execute all or part of the steps of the method of the present embodiment. And the aforementioned storage medium includes: various media capable of storing program codes, such as a usb disk, a removable hard disk, a Read Only Memory (ROM), a Random Access Memory (RAM), a magnetic disk, or an optical disk.
Specifically, the computer program instructions corresponding to a printing-suitable document generating method in the present embodiment may be stored on a storage medium such as an optical disc, a hard disc, a usb disk, or the like, and when the computer program instructions corresponding to a printing-suitable document generating method in the storage medium are read or executed by an electronic device, the steps of any one of the printing-suitable document generating methods in the foregoing embodiments are implemented.
Based on the same technical concept of the foregoing embodiment, referring to fig. 11, it shows another document generating apparatus 110 suitable for printing provided by the embodiment of the present invention, which may include: memory 111, processor 112, and bus 113; wherein,
the bus 113 is used for connecting the memory 111, the processor 112 and the intercommunication among these devices;
the memory 111 for storing computer programs and data;
the processor 112 is configured to execute the computer program stored in the memory to implement the steps of any one of the document generation methods suitable for printing in the foregoing embodiments.
In practical applications, the memory 111 may be a volatile memory (RAM); or a non-volatile memory (non-volatile memory) such as a ROM, a flash memory (flash memory), a Hard Disk (Hard Disk Drive, HDD) or a Solid-State Drive (SSD); or a combination of the above types of memories and provides instructions and data to the processor 112.
The processor 112 may be at least one of an Application Specific Integrated Circuit (ASIC), a DSP, a Digital Signal Processing Device (DSPD), a Programmable Logic Device (PLD), an FPGA, a CPU, a controller, a microcontroller, and a microprocessor. It will be appreciated that the electronic devices used to implement the processor functions described above may be other devices, and embodiments of the present invention are not limited in particular.
The above-mentioned serial numbers of the embodiments of the present invention are merely for description and do not represent the merits of the embodiments.
Through the above description of the embodiments, those skilled in the art will clearly understand that the method of the above embodiments can be implemented by software plus a necessary general hardware platform, and certainly can also be implemented by hardware, but in many cases, the former is a better implementation manner. Based on such understanding, the technical solutions of the present invention may be embodied in the form of a software product, which is stored in a storage medium (such as ROM/RAM, magnetic disk, optical disk) and includes instructions for enabling a terminal (such as a mobile phone, a computer, a server, an air conditioner, or a network device) to execute the method according to the embodiments of the present invention.
While the present invention has been described with reference to the embodiments shown in the drawings, the present invention is not limited to the embodiments, which are illustrative and not restrictive, and it will be apparent to those skilled in the art that various changes and modifications can be made therein without departing from the spirit and scope of the invention as defined in the appended claims.

Claims (10)

1. A method of document generation suitable for printing, the method comprising:
acquiring at least one category of document templates filled with placeholders;
after a printing instruction is acquired, determining category identification information and placeholder replacement indication information carried by the printing instruction, wherein the category identification information is used for identifying the category of a document template, and the placeholder replacement indication information is used for indicating: a replacement mode of each placeholder in the document template corresponding to the category identification information;
and replacing each placeholder in the document template corresponding to the category identification information according to the placeholder replacement indication information to obtain the document to be printed.
2. The method of claim 1, wherein the placeholders in the document template for each category are predetermined according to usage requirements.
3. The method of claim 1 or 2, wherein obtaining at least one category of placeholder-populated document templates comprises:
opening a document template of at least one category without filling placeholders based on office software, and filling the opened document template with placeholders to obtain the document template of at least one category with filled placeholders.
4. The method according to claim 1, wherein the replacing each placeholder in the document template corresponding to the category identification information according to the placeholder replacement indication information to obtain the document to be printed comprises:
according to the placeholder replacement indication information, determining replacement content of each placeholder in the document template corresponding to the category identification information;
and replacing each placeholder in the document template corresponding to the category identification information according to the determined replacement content to obtain the document to be printed.
5. The method according to claim 4, wherein the determining, according to the placeholder replacement indication information, replacement content of each placeholder in the document template corresponding to the category identification information includes:
determining a database corresponding to the placeholder replacement indication information, wherein the database corresponding to the placeholder replacement indication information is used for storing replacement content of each placeholder in the document template corresponding to the category identification information;
and determining the replacement content of each placeholder in the document template corresponding to the category identification information in the database corresponding to the placeholder replacement indication information.
6. A document creation apparatus adapted for printing, the apparatus comprising: the device comprises an acquisition module and a determination module; wherein,
the acquisition module is used for acquiring at least one category of document templates filled with placeholders; after a printing instruction is acquired, a determining module is triggered;
the determining module is used for determining category identification information and placeholder replacement indication information carried by the printing instruction when triggered, and replacing each placeholder in the document template corresponding to the category identification information according to the placeholder replacement indication information to obtain a document to be printed; wherein the category identification information is used for identifying a category of the document template, and the placeholder replacement indication information is used for indicating that: and replacing each placeholder in the document template corresponding to the category identification information.
7. The apparatus of claim 6, wherein placeholders in document templates of each category are predetermined according to usage requirements.
8. The apparatus according to claim 6 or 7, wherein the obtaining module is specifically configured to open at least one category of document templates without placeholders based on office software, fill placeholders in the opened document templates, and obtain the at least one category of document templates with placeholders filled.
9. A document creation apparatus adapted for printing, the apparatus comprising a processor and a memory for storing a computer program operable on the processor; wherein,
the processor is adapted to perform the steps of the method of any one of claims 1 to 5 when running the computer program.
10. A computer storage medium on which a computer program is stored, characterized in that the computer program realizes the steps of the method of any one of claims 1 to 5 when executed by a processor.
CN201810903428.5A 2018-08-09 2018-08-09 A kind of document structure tree method, apparatus and computer storage medium suitable for printing Pending CN109240625A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201810903428.5A CN109240625A (en) 2018-08-09 2018-08-09 A kind of document structure tree method, apparatus and computer storage medium suitable for printing

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201810903428.5A CN109240625A (en) 2018-08-09 2018-08-09 A kind of document structure tree method, apparatus and computer storage medium suitable for printing

Publications (1)

Publication Number Publication Date
CN109240625A true CN109240625A (en) 2019-01-18

Family

ID=65071428

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201810903428.5A Pending CN109240625A (en) 2018-08-09 2018-08-09 A kind of document structure tree method, apparatus and computer storage medium suitable for printing

Country Status (1)

Country Link
CN (1) CN109240625A (en)

Cited By (10)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110221790A (en) * 2019-05-28 2019-09-10 迈克医疗电子有限公司 Universal printing method and device, analysis instrument and storage medium
CN110347989A (en) * 2019-07-04 2019-10-18 北京明略软件系统有限公司 The generation method and device of electrical form
CN110430022A (en) * 2019-08-19 2019-11-08 深圳市鹏海运电子数据交换有限公司 Data transmission method and device
CN111414141A (en) * 2020-03-17 2020-07-14 山东浪潮易云在线科技有限公司 Method and system for generating visual intelligent layout printing template based on SaaS mode
CN111596872A (en) * 2020-05-25 2020-08-28 上海泛微网络科技股份有限公司 Data printing method and data printing device
CN112000302A (en) * 2020-08-25 2020-11-27 上海合阔信息技术有限公司 Label generation method, template configuration method, device and storage medium
CN112068785A (en) * 2020-09-21 2020-12-11 山东浪潮通软信息科技有限公司 Report printing method and device and readable medium
CN113779952A (en) * 2021-09-28 2021-12-10 北京字跳网络技术有限公司 Text processing method and device and electronic equipment
CN114861623A (en) * 2022-05-09 2022-08-05 深圳市富途网络科技有限公司 Protocol template generation method and device, electronic equipment and storage medium
CN115270748A (en) * 2022-07-25 2022-11-01 中化现代农业有限公司 File generation method and device, electronic equipment and storage medium

Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101976235A (en) * 2010-09-21 2011-02-16 天津神舟通用数据技术有限公司 Extensible Word report automatically-generating method based on dynamic web page
US20140095645A1 (en) * 2012-09-28 2014-04-03 Interactive Memories, Inc. Method for Caching Data on Client Device to Optimize Server Data Persistence in Building of an Image-Based Project
CN104572597A (en) * 2015-01-12 2015-04-29 浪潮通用软件有限公司 Automatic word analysis report generation method and device
CN106708480A (en) * 2015-07-29 2017-05-24 腾讯科技(深圳)有限公司 Management platform realization method and apparatus
CN106776507A (en) * 2015-11-19 2017-05-31 北京国双科技有限公司 Word file generation method and device
CN108228119A (en) * 2018-01-11 2018-06-29 平安万家医疗投资管理有限责任公司 Method of printing, terminal device and storage medium based on HXML

Patent Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101976235A (en) * 2010-09-21 2011-02-16 天津神舟通用数据技术有限公司 Extensible Word report automatically-generating method based on dynamic web page
US20140095645A1 (en) * 2012-09-28 2014-04-03 Interactive Memories, Inc. Method for Caching Data on Client Device to Optimize Server Data Persistence in Building of an Image-Based Project
CN104572597A (en) * 2015-01-12 2015-04-29 浪潮通用软件有限公司 Automatic word analysis report generation method and device
CN106708480A (en) * 2015-07-29 2017-05-24 腾讯科技(深圳)有限公司 Management platform realization method and apparatus
CN106776507A (en) * 2015-11-19 2017-05-31 北京国双科技有限公司 Word file generation method and device
CN108228119A (en) * 2018-01-11 2018-06-29 平安万家医疗投资管理有限责任公司 Method of printing, terminal device and storage medium based on HXML

Cited By (13)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110221790A (en) * 2019-05-28 2019-09-10 迈克医疗电子有限公司 Universal printing method and device, analysis instrument and storage medium
CN110221790B (en) * 2019-05-28 2023-02-21 迈克医疗电子有限公司 Universal printing method and apparatus, analyzer, and storage medium
CN110347989A (en) * 2019-07-04 2019-10-18 北京明略软件系统有限公司 The generation method and device of electrical form
CN110430022B (en) * 2019-08-19 2022-04-19 深圳市鹏海运电子数据交换有限公司 Data transmission method and device
CN110430022A (en) * 2019-08-19 2019-11-08 深圳市鹏海运电子数据交换有限公司 Data transmission method and device
CN111414141A (en) * 2020-03-17 2020-07-14 山东浪潮易云在线科技有限公司 Method and system for generating visual intelligent layout printing template based on SaaS mode
CN111596872A (en) * 2020-05-25 2020-08-28 上海泛微网络科技股份有限公司 Data printing method and data printing device
CN112000302A (en) * 2020-08-25 2020-11-27 上海合阔信息技术有限公司 Label generation method, template configuration method, device and storage medium
CN112068785A (en) * 2020-09-21 2020-12-11 山东浪潮通软信息科技有限公司 Report printing method and device and readable medium
CN113779952A (en) * 2021-09-28 2021-12-10 北京字跳网络技术有限公司 Text processing method and device and electronic equipment
CN113779952B (en) * 2021-09-28 2024-03-01 北京字跳网络技术有限公司 Text processing method and device and electronic equipment
CN114861623A (en) * 2022-05-09 2022-08-05 深圳市富途网络科技有限公司 Protocol template generation method and device, electronic equipment and storage medium
CN115270748A (en) * 2022-07-25 2022-11-01 中化现代农业有限公司 File generation method and device, electronic equipment and storage medium

Similar Documents

Publication Publication Date Title
CN109240625A (en) A kind of document structure tree method, apparatus and computer storage medium suitable for printing
US20130055071A1 (en) Systems and methods for creating a customized website
US10516791B2 (en) Information processing system, information processing apparatus, and information processing method for executing an iteration of one or more processes
CN111818175B (en) Enterprise service bus configuration file generation method, device, equipment and storage medium
WO2005019980A2 (en) Methods and systems for processing digital photography books
CN111399786B (en) Method and device for generating print file, terminal equipment and storage medium
US11977901B2 (en) Systems and methods of multi-stage configuration service for policy-driven transformation
US9904499B2 (en) Information processing system for dynamically adding a process to a sequence of processes and information processing method using same
JP6193406B2 (en) Serialization for differential encoding
US9928751B2 (en) Generic media covers
CN111399834B (en) Form style self-defining method, device, computer equipment and storage medium
CN112579013A (en) File filling-in printing method and device and storage medium
US8699058B2 (en) Method and apparatus for processing an electronic document file for printing using configuration data to dynamically mimic print parameter information used by different printer
JP2011233104A (en) Information processing system, information processor, information processing method, program, and recording medium
CN115134353A (en) Automatic file uploading method, file previewing method, device, medium and equipment
CN113436699A (en) Method, system, electronic device and storage medium for generating new corona nucleic acid detection report
CN114004211B (en) Document template generation method, processing method, device, computer equipment and medium
CN114004197A (en) Form processing method and device, electronic equipment and medium
US20070136226A1 (en) Jdf package management method
CN113741953A (en) Form processing method and device, electronic equipment and computer storage medium
JP2008123213A (en) Image outputting device and document processing method
CN112818642B (en) Method and device for converting PDF (Portable document Format) file into form file, computer equipment and storage medium
CN114489895B (en) Batch poster generation method, device, equipment and medium
CN114201538B (en) Data processing method and device, intelligent equipment and computer storage medium
JP2005085082A (en) Page change device and method

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
RJ01 Rejection of invention patent application after publication

Application publication date: 20190118

RJ01 Rejection of invention patent application after publication