CN111506276A - Method and device for printing two-dimensional code label - Google Patents

Method and device for printing two-dimensional code label Download PDF

Info

Publication number
CN111506276A
CN111506276A CN202010316431.4A CN202010316431A CN111506276A CN 111506276 A CN111506276 A CN 111506276A CN 202010316431 A CN202010316431 A CN 202010316431A CN 111506276 A CN111506276 A CN 111506276A
Authority
CN
China
Prior art keywords
dimensional code
printing
instruction
code label
executing
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
CN202010316431.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.)
Beijing Yidiantao Network Technology Co ltd
Original Assignee
Beijing Yidiantao 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 Beijing Yidiantao Network Technology Co ltd filed Critical Beijing Yidiantao Network Technology Co ltd
Priority to CN202010316431.4A priority Critical patent/CN111506276A/en
Publication of CN111506276A publication Critical patent/CN111506276A/en
Pending legal-status Critical Current

Links

Images

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/1204Improving or facilitating administration, e.g. print management resulting in reduced user or operator actions, e.g. presetting, automatic actions, using hardware token storing data
    • 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/1242Image or content composition onto a page
    • G06F3/1243Variable data printing, e.g. document forms, templates, labels, coupons, advertisements, logos, watermarks, transactional printing, fixed content versioning
    • 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/1278Dedicated interfaces to print systems specifically adapted to adopt a particular infrastructure
    • G06F3/128Direct printing, e.g. sending document file, using memory stick, printing from a camera

Abstract

The embodiment of the invention provides a method and a device for printing a two-dimensional code label. The method comprises the following steps: receiving and executing an insertion instruction, and inserting a pre-drawn two-dimensional code label into a printing container in a page; and receiving and executing a printing instruction, and calling a printer to print the content in the container through the browser. According to the method and the device for printing the two-dimensional code label, the two-dimensional code label which is drawn in advance is inserted into the printing container in the page, the printer is called through the browser to print the content in the printing container, the two-dimensional code label is directly printed based on the browser, the steps of printing the two-dimensional code label can be simplified, and the method and the device are more convenient and flexible.

Description

Method and device for printing two-dimensional code label
Technical Field
The embodiment of the invention relates to the technical field of computers, in particular to a method and a device for printing a two-dimensional code label.
Background
With the popularization of the internet and the rise of two-dimensional codes, the intercommunication of online and offline data becomes more and more important, and the online data and the entity equipment can be associated together through the bridge of the two-dimensional codes. Each device can be assigned with a unique mark (two-dimensional code label) and attached to the entity device, then the code is scanned through a mobile phone, the relevant information of the device, such as data of a responsible person, the position and the like, can be acquired, and unified management is realized through data maintenance on a line. The two-dimensional code label printing method is a core link.
The main mode for printing the two-dimensional code label on the webpage is to preset a template with a specified label size, then write the dynamic two-dimensional code data into the template, generate a pdf file from the template, then open the pdf file, and select a printer for printing.
In general, since different printers support different label sizes, templates of various sizes are preset to fit various models of printers and various label sizes. At present, the types of printers sold by Internet e-commerce are hundreds, the size of a label is also five-flower eight-door, and the traditional printing mode cannot be compatible with all printers. The size content of the template needs to be debugged when each printer is matched, the maintenance cost is high, and the repeated work is large.
Disclosure of Invention
The embodiment of the invention provides a method and a device for printing a two-dimensional code label, which are used for solving or at least partially solving the defect of complex steps in the prior art.
In a first aspect, an embodiment of the present invention provides a method for printing a two-dimensional code label, including:
receiving and executing an insertion instruction, and inserting a pre-drawn two-dimensional code label into a printing container in a page;
and receiving and executing a printing instruction, and calling a printer to print the content in the container through a browser.
Preferably, the two-dimensional code label comprises a canvas background, a two-dimensional code and basic text information.
Preferably, before receiving and executing the insertion instruction, the method further includes:
receiving and executing a background drawing instruction, and drawing the canvas background;
receiving and executing a two-dimension code drawing instruction, and drawing the two-dimension code;
and receiving and executing a text drawing instruction, and drawing the basic text information.
Preferably, the receiving a background drawing instruction and executing, the drawing the canvas background specifically includes:
and drawing the canvas background according to the length and the width of the canvas background carried by the background drawing instruction and the page-break-after attribute value, and setting the page-break-after attribute value of the two-dimensional code label.
Preferably, the receiving and executing a two-dimensional code drawing instruction, and the specific step of drawing the two-dimensional code includes:
generating the two-dimensional code according to the two-dimensional code information and the parameters carried by the two-dimensional code drawing instruction;
and drawing the two-dimensional code to the specified position in the canvas background based on a drawing board tool of the browser according to the information of the specified position carried by the two-dimensional code drawing instruction.
Preferably, the receiving and executing a text drawing instruction, and the specific step of drawing the basic text information includes:
and setting the width of the basic text information according to the width proportion carried by the text drawing instruction, and drawing the basic text information in the canvas background in the area outside the two-dimensional code.
Preferably, the receiving and executing an insertion instruction, inserting a pre-drawn two-dimensional code label into a print container in a page, and invoking a printer to print between contents in the print container through a browser further include:
receiving and executing a preview instruction, and acquiring a printing preview result of the two-dimension code label;
and receiving and executing a page adjusting instruction input according to the printing preview result, and adjusting the layout of the page.
In a second aspect, an embodiment of the present invention provides an apparatus for printing a two-dimensional code label, including:
the inserting module is used for receiving and executing an inserting instruction and inserting a pre-drawn two-dimensional code label into a printing container in a page;
and the printing module is used for receiving and executing the printing instruction and calling the printer to print the content in the container through the browser.
In a third aspect, an embodiment of the present invention provides an electronic device, which includes a memory, a processor, and a computer program stored in the memory and executable on the processor, and when the computer program is executed, the steps of the method for printing a two-dimensional code label provided in any one of the various possible implementations of the first aspect are implemented.
In a fourth aspect, an embodiment of the present invention provides a non-transitory computer-readable storage medium, on which a computer program is stored, which, when being executed by a processor, implements the steps of the method for printing a two-dimensional code label as provided in any one of the various possible implementations of the first aspect.
According to the method and the device for printing the two-dimensional code label, the two-dimensional code label which is drawn in advance is inserted into the printing container in the page, the printer is called through the browser to print the content in the printing container, the two-dimensional code label is directly printed based on the browser, the steps of printing the two-dimensional code label can be simplified, and the method and the device are more convenient and flexible.
Drawings
In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the drawings used in the description of the embodiments or the prior art will be briefly described below, and it is obvious that the drawings in the following description are some embodiments of the present invention, and those skilled in the art can also obtain other drawings according to the drawings without creative efforts.
Fig. 1 is a schematic flow chart of a method for printing a two-dimensional code label according to an embodiment of the present invention;
fig. 2 is a schematic structural diagram of an apparatus for printing a two-dimensional code label according to an embodiment of the present invention;
fig. 3 is a schematic physical structure diagram of an electronic device according to an embodiment of the present invention.
Detailed Description
In order to make the objects, technical solutions and advantages of the embodiments of the present invention clearer, the technical solutions in the embodiments of the present invention will be clearly and completely described below with reference to the drawings in the embodiments of the present invention, and it is obvious that the described embodiments are some, but not all, embodiments of the present invention. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present invention.
Fig. 1 is a schematic flow chart of a method for printing a two-dimensional code label according to an embodiment of the present invention. As shown in fig. 1, the method includes: and S101, receiving and executing an insertion instruction, and inserting a pre-drawn two-dimensional code label into a printing container in a page.
It should be noted that, in the embodiment of the present invention, after the two-dimensional code label is not required to be saved as the pdf file, the two-dimensional code label is printed by downloading the pdf file, opening the pdf file, and clicking the pdf file for printing, but the pdf file is not required to be downloaded, and the two-dimensional code label is adapted to the label printer depending on the printing function of the browser itself, and the two-dimensional code label is not required to be encoded repeatedly, and a plurality of size templates are not required to be preset.
Specifically, the insertion instruction is used for inserting a pre-drawn two-dimensional code label into a print container (iframe) in the page. Iframe, a separate printing container.
The user may enter an insertion instruction based on the browser. For example, the insertion instruction may be input by clicking a button in the page and/or dragging, etc.
After receiving the insertion instruction based on the browser, the terminal executes the insertion instruction, so that the pre-drawn two-dimensional code label can be inserted into the printing container in the page.
The pre-drawn two-dimensional code label is a two-dimensional code label to be printed.
Preferably, the two-dimensional code label drawn in advance is a two-dimensional code label used for identity management.
And step S102, receiving and executing a printing instruction, and calling a printer to print the content in the container through the browser.
Specifically, a print instruction for printing the content in the print container.
The user may enter a print instruction based on the browser. For example, the print instruction may be input by clicking a button in a page or the like.
After the terminal receives the printing instruction based on the browser, the terminal executes the printing instruction, so that the printer can be called to print the page, and the content (namely the pre-drawn two-dimensional code label) in the printing container is printed.
According to the embodiment of the invention, the pre-drawn two-dimensional code label is inserted into the printing container in the page, the content in the printing container is called by the printer through the browser, and the two-dimensional code label is directly printed based on the browser, so that the steps of printing the two-dimensional code label can be simplified, and the method is more convenient and flexible.
Based on the content of the above embodiments, the two-dimensional code tag includes a canvas background, a two-dimensional code, and basic text information.
Specifically, the canvas background is used for bearing the size of the ground color and the size of the label.
The canvas background is usually white, and most label printers on the market are of a thermosensitive type, support black, white and gray colors and do not need color labels. Therefore, the embodiment of the invention can preferably draw based on the canvas background of the white background.
The two-dimensional code can bear abundant content. The content carried by the two-dimensional code is two-dimensional code information.
The pre-drawn two-dimensional code label is a two-dimensional code label for setting management. In the embodiment of the invention, a string of webpage links is borne in the two-dimensional code, and the links can be opened in a browser to acquire the data files of the entity equipment (namely the fixed assets) in the online system by scanning the code through a mobile phone or a tablet personal computer and the like.
And the basic text information is part or all of important information in the two-dimensional code information. The two-dimensional code information can be extracted from part or all of important information in the two-dimensional code information and arranged outside the two-dimensional code, so that the two-dimensional code information (such as data of equipment and the like) can be quickly browsed or positioned.
According to the embodiment of the invention, the two-dimension code label comprises the canvas background, the two-dimension code and the basic text information, so that the identification management based on the printed two-dimension code label can be more conveniently and efficiently carried out.
Based on the content of the above embodiments, before receiving and executing the insertion instruction, the method further includes: and receiving and executing a background drawing instruction, and drawing the canvas background.
Specifically, the canvas background, the two-dimensional code and the basic text information can be sequentially drawn by inputting corresponding instructions, so that the two-dimensional code label to be printed is drawn.
Background drawing instructions for drawing a canvas background.
The background drawing instruction may carry information such as the length and width of the canvas background and the page-break-after attribute value.
And receiving and executing a two-dimension code drawing instruction, and drawing the two-dimension code.
Specifically, the two-dimensional code drawing instruction is used for generating and drawing a two-dimensional code.
The two-dimensional code drawing instruction can carry information of the two-dimensional code, information of a specified position and the like.
And receiving and executing a text drawing instruction, and drawing basic text information.
Specifically, the text drawing instruction is used for drawing basic text information.
The text drawing command may carry information such as the length and width of the basic text information.
According to the embodiment of the invention, the drawing of the canvas background, the two-dimensional code and the basic text information is sequentially drawn through the corresponding instruction, so that the two-dimensional code label can be drawn more conveniently and rapidly.
Based on the content of the above embodiments, a background drawing instruction is received and executed, and the specific step of drawing the canvas background includes: and drawing the canvas background according to the length and the width of the canvas background carried by the background drawing instruction and the page-break-after attribute value, and setting the page-break-after attribute value of the two-dimensional code tag.
Specifically, the length and width of the canvas background are the reference length and width.
The reference length and width may be set in advance. The market research shows that the size of the label is mostly within 100mm, and the label can be set according to 50mm in terms of the length and width of the standard. The length and width parameters are exposed and set according to the size of the actual label.
It is also necessary to set a page-break-after attribute for each tag (which is provided by the browser), so that each two-dimensional code tag can be printed as an independent unit when creating a print job of multiple tags.
According to the embodiment of the invention, by drawing the canvas background and setting the page-break-after attribute values of the two-dimension code labels, each two-dimension code label can be used as an independent unit for printing, and the interference between the two-dimension code labels can be avoided.
Based on the content of the above embodiments, the method receives and executes a two-dimensional code drawing instruction, and the specific steps of drawing the two-dimensional code include: and generating the two-dimensional code according to the two-dimensional code information and the parameters carried by the two-dimensional code drawing instruction.
Specifically, the two-dimensional code may be generated using international standard rules, involving two-dimensional code information and two parameters. Two parameters include error correction level and margin.
The error correction Code (ErrorCorrection Code) functions to allow correct decoding even when an error within an allowable range occurs in data of the two-dimensional Code.
The error correction level may be set according to actual needs, and the error correction level is not particularly limited in this embodiment of the present invention, for example, the error correction level is L (7% error correction ratio)
The margin refers to a two-dimensional code generated according to a specified size, the size of the margin around the two-dimensional code is reserved, and the unit is a pixel.
The margin may be set according to actual needs, and the embodiment of the present invention is not particularly limited in this respect. For example, the margin is 10 pixels.
The two-dimensional code information is content contained (or carried) by the two-dimensional code, and may also be referred to as "content".
The two-dimensional code information may be set according to actual needs, which is not specifically limited in this embodiment of the present invention. For example, a string of information stored in the online system of the entity device may be converted into a web page link recognizable by a mobile phone browser, and the web page link is used as two-dimensional code information.
And drawing the two-dimensional code to the specified position in the canvas background based on a drawing board tool of a browser according to the information of the specified position carried by the two-dimensional code drawing instruction.
Specifically, after the generated two-dimensional code is generated, the two-dimensional code may be drawn to a specified position in the canvas background through a drawing board tool (canvas) provided by a browser.
According to the embodiment of the invention, the two-dimension code is generated and drawn to the specified position in the canvas background, so that the two-dimension code label can be drawn more conveniently and rapidly.
Based on the content of the above embodiments, a text drawing instruction is received and executed, and the specific step of drawing the basic text information includes: and setting the width of the basic text information according to the width proportion carried by the text drawing instruction, and drawing the basic text information in the region except the two-dimensional code in the canvas background.
Specifically, the width of the base text information may be set in percentage based on the width of the label. Therefore, the basic text information can be fully displayed on different sizes.
The height of the basic text information can be unnecessary to set, and line feed processing is required when the basic text content exceeds the width.
It will be appreciated that the underlying text information is also drawn in the canvas background, but does not overlap the two-dimensional code, i.e., is located in an area outside of the two-dimensional code.
According to the embodiment of the invention, the basic text information is drawn in the canvas background, so that the two-dimensional code label can be drawn more conveniently and rapidly.
Based on the content of each embodiment, receiving and executing an insertion instruction, inserting a pre-drawn two-dimensional code label into a print container in a page, receiving and executing the print instruction, and calling a printer through a browser to print the content in the container, further comprising: and receiving and executing a preview instruction, and acquiring a printing preview result of the two-dimensional code label.
Specifically, after inserting a pre-drawn two-dimensional code label into a print container in a page, a print preview may be performed on the two-dimensional code label.
And the preview instruction is used for printing and previewing the two-dimensional code label.
The user may enter preview instructions based on the browser. For example, the preview instruction may be input by clicking a button in the page or the like.
After the terminal receives the preview instruction based on the browser, the preview instruction is executed, and the print preview function of the browser is invoked, so that the print preview result of the two-dimensional code label is displayed for a user to check.
And receiving a page adjusting instruction input according to the printing preview result, executing the page adjusting instruction, and adjusting the layout of the page.
Specifically, the user can input a page adjustment instruction based on the browser according to the print preview result of the two-dimensional code label. For example, the page adjustment instruction may be input by clicking a button in the page and/or inputting a numerical value.
And the page adjusting instruction is used for adjusting the layout of the page.
The orientation (e.g., landscape or portrait), margins (e.g., none, minimum or custom, etc.), scaling (e.g., default or custom, etc.) may be adjusted.
Through the three parameters, after the optimal effect is achieved, a user can input a printing instruction to print the two-dimensional code label.
It can be understood that, for the two-dimensional code label that is used for setting up the management of distinguishing, if the two-dimensional code label is same type, above-mentioned three parameters only need set up once when printing this type of two-dimensional code label for the first time, when printing other two-dimensional code labels of this type, all can adopt this setting, and need not repeated setting.
It should be noted that, in a general pdf file printing mode, the two-dimensional code label is fixed, and cannot set a direction, a margin, scaling, and the like in the printing process, but the embodiment of the present invention can adjust at any time in the printing process.
The embodiment of the invention adapts to the label printer by adjusting three parameters of direction, margin and zooming, does not need to repeatedly encode, does not need to preset a plurality of size templates, can set the direction, margin and zooming at any time in the printing process, and can achieve the best printing effect.
Fig. 2 is a schematic structural diagram of an apparatus for printing a two-dimensional code label according to an embodiment of the present invention. Based on the content of the above embodiments, as shown in fig. 2, the apparatus includes an insertion module 201 and a printing module 202, wherein:
the inserting module 201 is used for receiving and executing an inserting instruction, and inserting a pre-drawn two-dimensional code label into a printing container in a page;
and the printing module 202 is used for receiving and executing the printing instruction, and calling the printer to print the content in the container through the browser.
Specifically, the insertion module 201 is electrically connected to the printing module 202.
After receiving the insertion instruction based on the browser, the insertion module 201 executes the insertion instruction, so that the pre-rendered two-dimensional code label can be inserted into the print container in the page.
The printing module 202 executes the printing instruction after receiving the printing instruction based on the browser, so that the printer can be invoked to print the page and print the content (i.e. the pre-rendered two-dimensional code label) in the print container.
The printing module 202 may also be configured to receive and execute a preview instruction, and obtain a print preview result of the two-dimensional code label; and receiving a page adjusting instruction input according to the printing preview result, executing the page adjusting instruction, and adjusting the layout of the page.
The specific method and process for implementing the corresponding function by each module included in the apparatus for printing the two-dimensional code label according to the embodiments of the present invention are described in the embodiments of the method for printing the two-dimensional code label, and are not described herein again.
The device for printing the two-dimensional code label is used for the method for printing the two-dimensional code label of the foregoing embodiments. Therefore, the description and definition in the method of printing the two-dimensional code label in the foregoing embodiments can be used for understanding each execution module in the embodiments of the present invention.
According to the embodiment of the invention, the pre-drawn two-dimensional code label is inserted into the printing container in the page, the content in the printing container is called by the printer through the browser, and the two-dimensional code label is directly printed based on the browser, so that the steps of printing the two-dimensional code label can be simplified, and the method is more convenient and flexible.
Fig. 3 is a schematic physical structure diagram of an electronic device according to an embodiment of the present invention. Based on the content of the above embodiment, as shown in fig. 3, the electronic device may include: a processor (processor)301, a memory (memory)302, and a bus 303; wherein, the processor 301 and the memory 302 complete the communication with each other through the bus 303; the processor 301 is configured to invoke computer program instructions stored in the memory 302 and executable on the processor 301 to perform the methods for printing two-dimensional code labels provided by the above-mentioned method embodiments, for example, including: receiving and executing an insertion instruction, and inserting a pre-drawn two-dimensional code label into a printing container in a page; and receiving and executing a printing instruction, and calling a printer to print the content in the container through the browser.
Another embodiment of the present invention discloses a computer program product, which includes a computer program stored on a non-transitory computer readable storage medium, the computer program includes program instructions, and when the program instructions are executed by a computer, the computer can execute the method for printing a two-dimensional code label provided by the above-mentioned method embodiments, for example, the method includes: receiving and executing an insertion instruction, and inserting a pre-drawn two-dimensional code label into a printing container in a page; and receiving and executing a printing instruction, and calling a printer to print the content in the container through the browser.
Furthermore, the logic instructions in the memory 302 may be implemented in software functional units and stored in a computer readable storage medium when sold or used as a stand-alone product. Based on such understanding, the technical solutions of the embodiments of the present invention may be essentially implemented or make a contribution to the prior art, or may be implemented in the form of a software product stored in a storage medium and including instructions for causing a computer device (which may be a personal computer, a server, or a network device) to execute all or part of the steps of the methods of the embodiments of the present invention. And the aforementioned storage medium includes: a U-disk, a removable hard disk, a Read-Only Memory (ROM), a Random Access Memory (RAM), a magnetic disk or an optical disk, and other various media capable of storing program codes.
Another embodiment of the present invention provides a non-transitory computer-readable storage medium, which stores computer instructions, where the computer instructions cause a computer to execute the method for printing a two-dimensional code label provided in the foregoing method embodiments, for example, the method includes: receiving and executing an insertion instruction, and inserting a pre-drawn two-dimensional code label into a printing container in a page; and receiving and executing a printing instruction, and calling a printer to print the content in the container through the browser.
The above-described embodiments of the apparatus are merely illustrative, and the units described as separate parts may or may not be physically separate, and the parts displayed as units may or may not be physical units, may be located in one place, or may be distributed on a plurality of network units. Some or all of the modules may be selected according to actual needs to achieve the purpose of the solution of the present embodiment. One of ordinary skill in the art can understand and implement it without inventive effort.
Through the above description of the embodiments, those skilled in the art will clearly understand that each embodiment can be implemented by software plus a necessary general hardware platform, and certainly can also be implemented by hardware. It is understood that the above-described technical solutions may be embodied in the form of a software product, which may be stored in a computer-readable storage medium, such as ROM/RAM, magnetic disk, optical disk, etc., and includes several instructions for enabling a computer device (which may be a personal computer, a server, or a network device, etc.) to execute the method of the above-described embodiments or some parts of the embodiments.
Finally, it should be noted that: the above examples are only intended to illustrate the technical solution of the present invention, but not to limit it; although the present invention has been described in detail with reference to the foregoing embodiments, it will be understood by those of ordinary skill in the art that: the technical solutions described in the foregoing embodiments may still be modified, or some technical features may be equivalently replaced; and such modifications or substitutions do not depart from the spirit and scope of the corresponding technical solutions of the embodiments of the present invention.

Claims (10)

1. A method for printing a two-dimensional code label is characterized by comprising the following steps:
receiving and executing an insertion instruction, and inserting a pre-drawn two-dimensional code label into a printing container in a page;
and receiving and executing a printing instruction, and calling a printer to print the content in the container through a browser.
2. The method of printing a two-dimensional code label according to claim 1, wherein the two-dimensional code label comprises a canvas background, a two-dimensional code, and basic text information.
3. The method for printing the two-dimensional code label according to claim 2, wherein before the receiving and executing the insertion instruction, the method further comprises:
receiving and executing a background drawing instruction, and drawing the canvas background;
receiving and executing a two-dimension code drawing instruction, and drawing the two-dimension code;
and receiving and executing a text drawing instruction, and drawing the basic text information.
4. The method for printing the two-dimensional code label according to claim 3, wherein the receiving the background drawing instruction and executing, and the drawing the canvas background comprises:
and drawing the canvas background according to the length and the width of the canvas background carried by the background drawing instruction and the page-break-after attribute value, and setting the page-break-after attribute value of the two-dimensional code label.
5. The method for printing the two-dimensional code label according to claim 3, wherein the receiving and executing the two-dimensional code drawing instruction, the specific step of drawing the two-dimensional code comprises:
generating the two-dimensional code according to the two-dimensional code information and the parameters carried by the two-dimensional code drawing instruction;
and drawing the two-dimensional code to the specified position in the canvas background based on a drawing board tool of the browser according to the information of the specified position carried by the two-dimensional code drawing instruction.
6. The method for printing the two-dimensional code label according to claim 3, wherein the receiving the text drawing instruction and executing, the step of drawing the basic text information comprises:
and setting the width of the basic text information according to the width proportion carried by the text drawing instruction, and drawing the basic text information in the canvas background in the area outside the two-dimensional code.
7. The method for printing the two-dimensional code label according to any one of claims 1 to 6, wherein the receiving and executing of the insertion instruction, the inserting of the two-dimensional code label which is drawn in advance into the printing container in the page, and the receiving and executing of the printing instruction, the calling of the printer through the browser to the content in the printing container further comprise:
receiving and executing a preview instruction, and acquiring a printing preview result of the two-dimension code label;
and receiving and executing a page adjusting instruction input according to the printing preview result, and adjusting the layout of the page.
8. An apparatus for printing a two-dimensional code label, comprising:
the inserting module is used for receiving and executing an inserting instruction and inserting a pre-drawn two-dimensional code label into a printing container in a page;
and the printing module is used for receiving and executing the printing instruction and calling the printer to print the content in the container through the browser.
9. An electronic device comprising a memory, a processor and a computer program stored on the memory and executable on the processor, characterized in that the processor implements the steps of the method of printing a two-dimensional code label according to any one of claims 1 to 7 when executing the program.
10. A non-transitory computer readable storage medium, on which a computer program is stored, which, when being executed by a processor, carries out the steps of the method of printing a two-dimensional code label according to any one of claims 1 to 7.
CN202010316431.4A 2020-04-21 2020-04-21 Method and device for printing two-dimensional code label Pending CN111506276A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202010316431.4A CN111506276A (en) 2020-04-21 2020-04-21 Method and device for printing two-dimensional code label

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202010316431.4A CN111506276A (en) 2020-04-21 2020-04-21 Method and device for printing two-dimensional code label

Publications (1)

Publication Number Publication Date
CN111506276A true CN111506276A (en) 2020-08-07

Family

ID=71872776

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202010316431.4A Pending CN111506276A (en) 2020-04-21 2020-04-21 Method and device for printing two-dimensional code label

Country Status (1)

Country Link
CN (1) CN111506276A (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113360106A (en) * 2021-06-30 2021-09-07 建信金融科技有限责任公司 Webpage printing method and device

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20130097483A1 (en) * 2010-07-16 2013-04-18 Canon Kabushiki Kaisha Information processing apparatus, web browser control method, and storage medium storing program thereof
CN108776824A (en) * 2018-06-27 2018-11-09 中国建设银行股份有限公司 Bar-code label generation method, device and electronic equipment
CN109976683A (en) * 2019-02-28 2019-07-05 广州达安临床检验中心有限公司 Method of printing, device, equipment and the storage medium of data

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20130097483A1 (en) * 2010-07-16 2013-04-18 Canon Kabushiki Kaisha Information processing apparatus, web browser control method, and storage medium storing program thereof
CN108776824A (en) * 2018-06-27 2018-11-09 中国建设银行股份有限公司 Bar-code label generation method, device and electronic equipment
CN109976683A (en) * 2019-02-28 2019-07-05 广州达安临床检验中心有限公司 Method of printing, device, equipment and the storage medium of data

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113360106A (en) * 2021-06-30 2021-09-07 建信金融科技有限责任公司 Webpage printing method and device

Similar Documents

Publication Publication Date Title
US6791707B2 (en) Automated, hosted prepress applications
US6353483B1 (en) Postscript to bitmap conversion of graphic image files
CN104281995B (en) The method and apparatus that picture adds watermark
US9824604B2 (en) Creating assessment model for educational assessment system
US8009313B2 (en) Online image customization and printing on merchandise
CN104508622A (en) Epos printing
CN110879937A (en) Method and device for generating webpage from document, computer equipment and storage medium
CN108776824A (en) Bar-code label generation method, device and electronic equipment
US9117314B2 (en) Information output apparatus, method, and recording medium for displaying information on a video display
US6633890B1 (en) Method for washing of graphic image files
US11155102B2 (en) Image to script converter
US6903839B1 (en) Apparatus for washing of graphic image files
CN111506276A (en) Method and device for printing two-dimensional code label
CN107766011B (en) Printing control method, device and system
CN110674437A (en) Method and device for converting webpage data into PDF (Portable document Format) attachment
CN111722815B (en) Printing control method and device for automatic typesetting and electronic equipment
JP3827998B2 (en) Printing apparatus and printing method
US11334302B1 (en) Methods and systems for indicating and replacing missing element(s) in print job files prior to printing
EP2310963B1 (en) Information output apparatus, information output method, and recording medium
CN110851883B (en) Equipment fingerprint generation method and device based on picture drawing
CN111914226A (en) Background picture generation method and device
KR101665660B1 (en) Terminal for automated printing and system comprising it
CN113448522B (en) Variable data printing output method and device, terminal equipment and readable storage medium
WO2022145343A1 (en) Architecture for digitalizing documents using multi-model deep learning, and document image processing program
US6556308B1 (en) Color separation of graphic image files

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