CN115857845B - Bill Bluetooth printing implementation method and system and computer storage medium - Google Patents

Bill Bluetooth printing implementation method and system and computer storage medium Download PDF

Info

Publication number
CN115857845B
CN115857845B CN202310195713.7A CN202310195713A CN115857845B CN 115857845 B CN115857845 B CN 115857845B CN 202310195713 A CN202310195713 A CN 202310195713A CN 115857845 B CN115857845 B CN 115857845B
Authority
CN
China
Prior art keywords
row
container
control
row container
space value
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.)
Active
Application number
CN202310195713.7A
Other languages
Chinese (zh)
Other versions
CN115857845A (en
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.)
CHANJET INFORMATION TECHNOLOGY CO LTD
Original Assignee
CHANJET INFORMATION 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 CHANJET INFORMATION TECHNOLOGY CO LTD filed Critical CHANJET INFORMATION TECHNOLOGY CO LTD
Priority to CN202310195713.7A priority Critical patent/CN115857845B/en
Publication of CN115857845A publication Critical patent/CN115857845A/en
Application granted granted Critical
Publication of CN115857845B publication Critical patent/CN115857845B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Landscapes

  • Accessory Devices And Overall Control Thereof (AREA)

Abstract

The invention relates to a method, a system and a computer storage medium for realizing bill Bluetooth printing, belonging to the field of information technology and software, wherein the method comprises the following steps: acquiring page specification information of printable paper; determining the maximum number of Row controls which can be placed in a Row container according to the page specification information; acquiring the size of a Row control pre-placed in a Row container, determining a space value of the Row control in the Row container according to the size of the Row control, and obtaining a residual space value corresponding to the Row container according to the space value; and acquiring the size of the next Row control pre-placed in the Row container, judging whether the next Row control pre-placed in the Row container can be accommodated according to the residual space value, converting the control in the container into UI metadata, receiving a printing instruction, and outputting printing. The user-defined design can be realized in the support range of the Bluetooth printer, the flexible combination of the control and the data source field can be realized, the control can flexibly bind the data source, and the actual use scene of a user is finally met.

Description

Bill Bluetooth printing implementation method and system and computer storage medium
Technical Field
The invention relates to the field of information technology and software, in particular to a method and a system for realizing bill Bluetooth printing and a computer storage medium.
Background
Because of the low cost of bluetooth printers, bluetooth tickets are widely used in sales activities as a type of consumption voucher or consumption record. Due to some limitations of the bluetooth printer, the visible print setting method has many limitations, for example, only line mode can be used, the font size only supports several fixed sizes, the picture two-dimensional code and the like can only monopolize one line, the straight line cannot be printed, the picture cannot be color printed, and the like.
At present, printing is usually performed according to preset template contents in the market, custom design cannot be performed, and specific components are provided for design. In the mode, firstly, due to the fact that the preset template content is single, flexible typesetting cannot be performed according to the actual scene, and the control cannot flexibly bind the data source field; the second provides a specific control for design, such as: the system comprises a mobile phone number control, a transaction time control, a store name control, an address control and the like, but the controls cannot be flexibly configured by being bound with a data source.
The technical means cannot simultaneously meet the use scene that a user can customize the design in the support range of the Bluetooth printer and can realize the flexible combination of the personalized control and the data source field.
Disclosure of Invention
Therefore, it is necessary to provide a method for implementing bluetooth printing of a ticket, aiming at the problems that the bluetooth printer cannot meet the custom design and cannot realize flexible combination of controls and data source fields.
A method for realizing bill Bluetooth printing comprises the following steps:
acquiring page specification information of printable paper;
determining the maximum number of Row controls which can be placed in an Row container according to the page specification information, wherein the Row container can be placed in a GridLayout container, and the DridLayout container is positioned on a preset canvas;
acquiring the size of a Row control pre-placed in the Row container, determining the space value of the Row control in the Row container according to the size of the Row control, and obtaining the residual space value corresponding to the Row container according to the space value of the Row container;
sequentially obtaining the size of the next Row control pre-placed in the Row container, judging whether the Row control pre-placed in the Row container can be accommodated in the Row container according to the residual space value of the Row container, if not, newly building the Row container, and placing the Row control pre-placed in the Row container in the newly built Row container;
and binding the Row control positioned in the Row container with a data source to form a data model, converting the data model into UI metadata, receiving a printing instruction, and outputting and printing the UI metadata based on the printing instruction.
In one preferred embodiment, the acquiring the page specification information of the printable paper includes:
the page specification information includes at least one page specification.
In one preferred embodiment, the determining the maximum number of Row controls that can be placed in the Row container according to the page specification information includes:
and when the page specification information comprises a plurality of page specifications, determining that the plurality of page specifications correspond to different page specification information and the maximum number of Row controls which can be accommodated by the corresponding Row container.
In one preferred embodiment, the obtaining a Row control size pre-placed in the Row container, determining a space value of the Row control in the Row container according to the Row control size, and obtaining a remaining space value corresponding to the Row container according to the space value of the Row container includes:
dividing the Row container into a plurality of unit cells with equal sizes, wherein the size of the Row control pre-placed in the Row container is obtained and is an integral multiple of the number of the unit cells;
determining the space value of the Row control in the Row container according to the number of the cells occupied by the Row control in the Row container;
and obtaining a residual space value corresponding to the Row container according to the space value of the Row container.
In one preferred embodiment, the dividing the Row container into a plurality of cells with equal size includes:
the number of the plurality of cells is the least common multiple of the page specification information included on the canvas.
The method for realizing the Bluetooth printing of the bill disclosed by the embodiment of the invention can simultaneously meet the use scene that a user can customize a design within the support range of the Bluetooth printer and can flexibly combine the control and the data source field, thereby meeting the requirement of the Bluetooth printer, and the control can flexibly bind the data source to finally meet the actual use scene of the user.
A ticket Bluetooth printing implementation system, comprising:
the page specification acquisition module is used for acquiring page specification information of the printable paper;
the Row control number determining module is used for determining the maximum number of Row controls which can be placed in an Row container according to the page specification information, wherein the Row container can be placed in a GridLayout container, and the DridLayout container is positioned on a preset canvas;
the Row space determining module is used for acquiring the size of a Row control which is pre-placed in the Row container, determining the space value of the Row control in the Row container according to the size of the Row control, and obtaining the residual space value corresponding to the Row container according to the space value of the Row container;
the Row control presetting module is used for sequentially acquiring the size of a next Row control which is pre-placed in the Row container, judging whether the Row container can accommodate the next Row control which is pre-placed in the Row container according to the residual space value of the Row container, if the Row container cannot accommodate the next Row control, newly building the Row container, and placing the next Row control which is pre-placed in the Row container in the newly built Row container;
and the output printing module is used for binding the Row control positioned in the Row container with a data source to form a data model, converting the data model into UI metadata, receiving a printing instruction and outputting and printing the UI metadata based on the printing instruction.
In one preferred embodiment, the page specification information includes at least one page specification.
In one preferred embodiment, the row control presetting module includes:
and the Row container accommodating and confirming unit is used for determining that the plurality of page specifications correspond to different page specification information and the maximum number of Row controls which can be accommodated by the corresponding Row container when the page specification information comprises the plurality of page specifications.
In one preferred embodiment, the Row space determining module includes:
the Row container dividing unit is used for dividing the Row container into a plurality of cells with equal size, and the space occupied by the acquired Row control pre-placed in the Row container is integral multiple of the number of the cells;
the Row control space determining unit is used for determining the space value of the Row control in the Row container according to the number of the cells occupied by the Row control in the Row container;
and the residual space determining unit is used for obtaining a residual space value corresponding to the Row container according to the space value of the Row container.
The bill Bluetooth printing implementation system disclosed by the embodiment of the invention can simultaneously meet the use scene that a user can customize a design within the support range of the Bluetooth printer and can flexibly combine the control and the data source field, so that the requirement of the Bluetooth printer is met, the control can flexibly bind the data source, and the actual use scene of the user is finally met.
A computer storage medium comprising a stored program, wherein the computer storage medium is controlled to execute the above-described ticket bluetooth printing implementation method on a device when the program is run.
By executing the method, the computer storage medium disclosed by the embodiment of the invention can simultaneously meet the use scene that a user can customize a design within the support range of the Bluetooth printer and can flexibly combine the control and the data source field, thereby meeting the requirement of the Bluetooth printer, and the control can flexibly bind the data source to finally meet the actual use scene of the user.
Drawings
Fig. 1 is a schematic flow chart of a method for implementing bluetooth printing of a ticket according to a first preferred embodiment of the present invention;
fig. 2 is a schematic diagram of a ticket bluetooth printing implementation method according to a first preferred embodiment of the present invention;
fig. 3 is a schematic diagram illustrating a subdivision step of step S30 of a method for implementing bluetooth ticket printing according to a first preferred embodiment of the present invention;
fig. 4 is a schematic block diagram of a ticket bluetooth printing implementation system according to a second preferred embodiment of the present invention;
fig. 5 is a schematic module diagram of a Row space determining module of a ticket bluetooth printing implementation system according to a second preferred embodiment of the present invention.
Detailed Description
In order to make the objects, technical solutions and advantages of the present invention more apparent, the present invention is described in further detail below with reference to the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are merely illustrative of the invention and are not intended to limit the invention.
It will be understood that when an element is referred to as being "disposed on" another element, it can be directly on the other element or intervening elements may also be present. When an element is referred to as being "connected" to another element, it can be directly connected to the other element or intervening elements may also be present. The terms "vertical," "horizontal," "left," "right," and the like as used herein are for illustrative purposes only and do not denote a single embodiment.
Unless defined otherwise, all technical and scientific terms used herein have the same meaning as commonly understood by one of ordinary skill in the art to which this invention belongs. The terminology used in the description of the invention herein is for the purpose of describing particular embodiments only and is not intended to be limiting of the invention. As used herein, the term "and/or" includes any and all combinations of one or more of the associated listed items.
As shown in fig. 1, a first preferred embodiment of the present invention discloses a method for implementing bluetooth ticket printing, which includes:
s10: acquiring page specification information of printable paper;
in this step, the page specification information includes at least one page specification. In other words, the page specification information may support one page specification, or may support two or more page specifications, and in the present embodiment, the page specification information supports 3 page specifications, and the page specifications in 3 are 58mm, 80mm, and 110mm, respectively. The above-mentioned 58mm, 80mm and 110mm generally refer to the width of the paper used for the bluetooth printer used in the present embodiment.
Specifically, before this step, the method may configure, by configuring meta-metadata (schema), which mainly configures available controls, properties of each control, and a presentation form of the controls, then analyze the configured meta-metadata, initialize a designer, and perform a visualization operation.
S20: and determining the maximum number of the Row controls which can be placed in an Row container according to the page specification information, wherein the Row container can be placed in a GridLayout container, and the DridLayout container is positioned on a preset canvas.
In the step, a GridLayout container can be automatically placed on the preset overall canvas, and the GridLayout container can be placed in a Row container.
According to the bluetooth ticket page specification information, it is determined how many Row controls can be placed at most in the Row container, and in this embodiment, for example, a Row with the page specification of 58 can support placing a Row controls at most, a Row with the page specification of 80 can support placing B Row controls at most, and a Row with the page specification of 110 can support placing C Row controls at most.
S30: acquiring the size of a Row control pre-placed in the Row container, determining the space value of the Row control occupied in the Row container according to the size of the Row control, and obtaining the residual space value corresponding to the Row container according to the space value of the Row container.
In this embodiment, as shown in fig. 1 and 3, the step S30 may specifically include the following steps:
s31: dividing the Row container into a plurality of unit cells with equal sizes, wherein the size of the Row control pre-placed in the Row container is obtained and is an integral multiple of the number of the unit cells.
In this subdivision step, the Row container capable of accommodating the Row controls is divided into a plurality of cells with equal size, the number of the plurality of cells is an integral multiple of the number of the controls occupied by the accommodated Row controls, when the Row container accommodates the least common multiple of the number of at least one kind of accommodated Row controls, in more detail, if the Row with the page specification of 58 can accommodate a number of controls at most, the Row with the page specification of 80 can accommodate B controls at most, the page specification of 110 can accommodate C controls at most, and A, B, C are positive integers, the number of the plurality of cells divided by the Row container is the least common multiple of A, B, C.
S32: and determining the space value of the Row control in the Row container according to the number of the cells occupied by the Row control in the Row container.
In this subdivision step, the S32 determines the occupied space value of the Row control Row container according to the number of cells occupied by the Row control in the Row container.
As discussed in the above embodiments, determining how many cell span each control needs to occupy at least), and using N to represent the number of cells, such as 58: n = M/a,80 case: n = M/B,110 case: n = M/C. The M is the number of occupied cells.
S33: and obtaining a residual space value corresponding to the Row container according to the space value of the Row container.
In more detail, in step S33, the remaining space value of the corresponding Row container may be adjusted in real time according to the size of the Row control, so as to form a step modification of the remaining space value. If the Row control is configured to have to occupy one Row individually in the Row container, the Row control is defined to occupy M cells.
S40: and sequentially obtaining the size of the Row control which is pre-placed in the Row container next, judging whether the Row control which is pre-placed in the Row container next can be accommodated in the Row container according to the residual space value of the Row container, if not, newly building the Row container, and placing the Row control which is pre-placed in the Row container next in the newly built Row container.
In this step, the size of the Row control in the Row container to be placed next in advance is obtained according to the remaining space value obtained after the previous Row control is placed in S30, and comprehensive judgment is performed according to the dragging position of the Row control, the attribute configuration of the control, and the existing remaining space value of the current Row container, so as to determine whether the Row control currently required to be inserted into the Row container can be inserted into the Row container, and if the Row control cannot be inserted into the Row container, the Row is automatically changed, the newly-built Row container is inserted, and the control is placed into the newly-built Row container.
S50: and binding the Row control positioned in the Row container with a data source to form a data model, converting the data model into UI metadata, receiving a printing instruction, and outputting and printing the UI metadata based on the printing instruction.
In this step, the row control on the interface is obtained, and flexible binding of the control and the data source field can be realized on the data source panel through modes of clicking, double clicking or dragging the data source node and the like. And then, collecting a data model, converting the data model into UI metadata, converting the UI metadata into a printing protocol, assembling the data and finally converting the assembled data into a Bluetooth printing instruction.
The method for realizing the Bluetooth printing of the bill, disclosed by the embodiment of the invention, can simultaneously meet the requirements that a user can customize a design within the support range of the Bluetooth printer and can realize a use scene of flexibly combining the control and the data source field, so that the requirements of the Bluetooth printer are further met, the control can flexibly bind the data source, and finally the actual use scene of the user is met.
As shown in fig. 4, a second preferred embodiment of the present invention discloses a bluetooth ticket printing implementation system 100, where the system 100 includes a page specification obtaining module 110, a line control quantity determining module 120, a Row space determining module 130, a line control presetting module 140, and an output printing module 150.
The page specification acquiring module 110 is configured to acquire page specification information of printable paper;
the page specification information obtained by the page specification obtaining module 110 includes at least one page specification. In other words, the page specification information may support one page specification, or may support two or more page specifications, and in the present embodiment, the page specification information supports 3 page specifications, and the page specifications in 3 are 58mm, 80mm, and 110mm, respectively. The above-mentioned 58mm, 80mm and 110mm generally refer to the width of the paper used for the bluetooth printer used in the present embodiment.
Specifically, the metadata (schema) can be configured, the metadata mainly configures the available controls, the properties of the controls and the presentation forms of the controls, and then the configured metadata is analyzed, the designer is initialized, and the visualization operation is performed.
The line control number determining module 120 is configured to determine the maximum number of line controls that can be placed in an Row container according to the page specification information, where the Row container can be placed in a gridllayout container, and the dridllayout container is located on a preset canvas.
In the above-mentioned line control quantity determining module 120, a GridLayout container may be automatically placed on a preset overall canvas, and a Row container may be placed in the GridLayout container.
According to the bluetooth ticket page specification information, it is determined how many controls can be placed in the Row container at most, in this embodiment, for example, a line with the page specification of 58 can support placing a at most Row controls, a line with the page specification of 80 can support placing B at most Row controls, and a line with the page specification of 110 can support placing C at most Row controls.
The Row space determining module 130 is configured to obtain a Row control size pre-placed in the Row container, determine a space value of the Row control occupied by the Row control according to the Row control size, and obtain a remaining space value corresponding to the Row container according to the space value of the Row container.
As shown in fig. 4 and 5, the Row space determining module 130 may specifically include a Row container dividing unit 131, a line control space determining unit 132, and a remaining space determining unit 133.
The Row container dividing unit 131 divides the Row container into a plurality of cells with equal size, and the size of the acquired Row control pre-placed in the Row container is an integral multiple of the number of the cells.
The Row container dividing unit 131 divides the Row container capable of accommodating the Row controls into a plurality of cells with equal size, where the number of the plurality of cells is an integral multiple of the number of the accommodated Row controls, and when the Row container accommodates the least common multiple of the number of at least one kind of accommodated Row controls, in more detail, if a Row with the page specification of 58 can accommodate a control at most, a Row with the page specification of 80 can accommodate B controls at most, a Row with the page specification of 110 can accommodate C controls at most, and A, B, C are positive integers, the number of the plurality of cells divided by the Row container is the least common multiple of A, B, C.
The line control space determining unit 132 determines the space value of the Row control Row container according to the number of the cells occupied by the line controls in the Row container.
The Row control space determining unit 132 determines the occupied space value of the Row control Row container according to the number of the cells occupied by the Row controls in the Row container. As discussed in the previous embodiments, the minimum number of cells (span) required for each control is determined, and is denoted by N, such as 58: n = M/a,80 case: n = M/B,110 case: n = M/C. The M is the number of occupied cells.
The remaining space determining unit 133 obtains a remaining space value corresponding to the Row container according to the space value of the Row container. If the Row control is configured to have to occupy one Row individually in the Row container, the Row control is defined to occupy M cells. In more detail, the remaining space determining unit 133 may adjust the remaining space value of the corresponding Row container in real time according to the size of the width adjusted by the Row control, so as to form a step modification of the remaining space value.
The Row control presetting module 140 is configured to sequentially obtain the size of a Row control to be placed in the Row container, and the Row container accommodation confirmation unit is configured to determine that the multiple page specifications correspond to different page specification information when the page specification information includes multiple page specifications, where the maximum number of Row controls can be accommodated in the corresponding Row container. And the Row container accommodating and confirming unit is used for determining that the plurality of page specifications correspond to different page specification information and the maximum number of Row controls which can be accommodated by the corresponding Row container when the page specification information comprises the plurality of page specifications.
And judging whether the Row control which is pre-placed in the Row container next time can be accommodated in the Row container or not according to the residual space value of the Row container, if not, newly building the Row container, and placing the Row control which is pre-placed in the Row container next time in the newly built Row container.
The Row control presetting module 140 obtains the size of the Row control in the Row control container to be placed next according to the remaining space value obtained after the previous Row control is placed, and comprehensively judges according to the dragging position of the Row control, the control attribute configuration and the existing remaining space value of the current Row container to obtain whether the Row control to be inserted currently can be inserted into the Row container, and if the Row control cannot be inserted, the Row control is automatically changed, a new Row container is inserted, and the control is placed into the Row container.
The output printing module 150 is configured to bind the control located in the Row container with a data source to form a data model, convert the data model into UI metadata, receive a printing instruction, and output and print the UI metadata based on the printing instruction.
The output printing module 150 obtains the line control on the interface, and can flexibly bind the control and the data source field on the data source panel through clicking, double clicking, dragging and the like on the data source node. And then, collecting a data model, converting the data model into UI metadata, converting the UI metadata into a printing protocol, assembling the data and finally converting the assembled data into a Bluetooth printing instruction.
The bill Bluetooth printing implementation system disclosed by the embodiment of the invention can simultaneously meet the use scene that a user can customize a design within the support range of the Bluetooth printer and can flexibly combine the control and the data source field, so that the requirement of the Bluetooth printer is met, the control can flexibly bind the data source, and the actual use scene of the user is finally met.
Another preferred embodiment of the present invention discloses a computer storage medium, which includes a stored program, wherein when the program runs, the storage medium is controlled to execute the above-mentioned method for implementing bluetooth ticket printing on a device.
By executing the method, the computer storage medium disclosed by the embodiment of the invention can simultaneously meet the use scene that a user can customize a design within the support range of the Bluetooth printer and can realize flexible combination of the control and the data source field, thereby meeting the requirement of the Bluetooth printer, and the control can flexibly bind the data source and finally meet the actual use scene of the user.
It should be noted that the computer storage media described above in this disclosure can be computer readable signal media or computer readable storage media or any combination of the two. A computer readable storage medium may be, for example, but not limited to, an electronic, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus, or device, or any combination of the foregoing. More specific examples of the computer readable storage medium may include, but are not limited to: an electrical connection having one or more wires, a portable computer diskette, a hard disk, a Random Access Memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disc read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the foregoing. In the present disclosure, a computer readable storage medium may be any tangible medium that can contain, or store a program for use by or in connection with an instruction execution system, apparatus, or device. In contrast, in the present disclosure, a computer readable signal medium may comprise a propagated data signal with computer readable program code embodied therein, either in baseband or as part of a carrier wave. Such a propagated data signal may take many forms, including, but not limited to, electro-magnetic, optical, or any suitable combination thereof. A computer readable signal medium may also be any computer readable medium that is not a computer readable storage medium and that can communicate, propagate, or transport a program for use by or in connection with an instruction execution system, apparatus, or device. Program code embodied on a computer readable medium may be transmitted using any appropriate medium, including but not limited to: electrical wires, optical cables, RF (radio frequency), etc., or any suitable combination of the foregoing.
In some embodiments, the clients, servers may communicate using any currently known or future developed network Protocol, such as HTTP (Hyper Text Transfer Protocol), and may interconnect with any form or medium of digital data communication (e.g., a communications network). Examples of communication networks include a local area network ("LAN"), a wide area network ("WAN"), the Internet (e.g., the Internet), and peer-to-peer networks (e.g., ad hoc peer-to-peer networks), as well as any currently known or future developed network.
The computer readable medium may be embodied in the electronic device; or may exist separately without being assembled into the electronic device.
The computer readable medium carries one or more programs which, when executed by the electronic device, cause the electronic device to:
the technical features of the above embodiments can be arbitrarily combined, and for the sake of brevity, all possible combinations of the technical features in the above embodiments are not described, but should be considered as the scope of the present specification as long as there is no contradiction between the combinations of the technical features.
The above-mentioned embodiments only express several embodiments of the present invention, and the description thereof is specific and detailed, but not to be understood as limiting the scope of the invention. It should be noted that, for a person skilled in the art, several variations and modifications can be made without departing from the inventive concept, which falls within the scope of the present invention. Therefore, the protection scope of the present patent shall be subject to the appended claims.

Claims (10)

1. A method for realizing bill Bluetooth printing is characterized by comprising the following steps:
acquiring page specification information of printable paper;
determining the maximum number of the Row controls which can be placed in a Row container according to the page specification information, wherein the Row container can be placed in a GridLayout container which is positioned on a preset canvas;
acquiring the size of a Row control pre-placed in the Row container, determining the space value of the Row control in the Row container according to the size of the Row control, and obtaining the residual space value corresponding to the Row container according to the space value of the Row container;
sequentially obtaining the size of the next Row control pre-placed in the Row container, judging whether the Row control pre-placed in the Row container can be accommodated in the Row container according to the residual space value of the Row container, if not, newly building the Row container, and placing the Row control pre-placed in the Row container in the newly built Row container;
and binding the Row control positioned in the Row container with a data source to form a data model, converting the data model into UI metadata, receiving a printing instruction, and outputting and printing the UI metadata based on the printing instruction.
2. The method for implementing bluetooth ticket printing according to claim 1, wherein the acquiring page specification information of the printable paper comprises:
the page specification information includes at least one page specification.
3. The method for implementing bluetooth ticket printing according to claim 2, wherein the determining the maximum number of Row controls that can be placed in a Row container according to the page specification information comprises:
and when the page specification information comprises a plurality of page specifications, determining that the plurality of page specifications correspond to different page specification information and the maximum number of Row controls which can be accommodated by the corresponding Row container.
4. The method for realizing bluetooth ticket printing according to claim 3, wherein the obtaining of the size of the Row control pre-placed in the Row container, determining the space value of the Row control in the Row container according to the size of the Row control, and obtaining the remaining space value corresponding to the Row container according to the space value of the Row container comprises:
dividing the Row container into a plurality of unit cells with equal sizes, wherein the size of the Row control pre-placed in the Row container is obtained and is an integral multiple of the number of the unit cells;
determining the space value of the Row control in the Row container according to the number of the cells occupied by the Row control in the Row container;
and obtaining a residual space value corresponding to the Row container according to the space value of the Row container.
5. The ticket bluetooth printing implementation method of claim 4, wherein the dividing the Row container into a plurality of cells with equal size comprises:
the number of the plurality of cells is the least common multiple of the page specification information included on the canvas.
6. The utility model provides a bill bluetooth prints implementation system which characterized in that includes:
the page specification acquisition module is used for acquiring page specification information of the printable paper;
the Row control number determining module is used for determining the maximum number of Row controls which can be placed in an Row container according to the page specification information, wherein the Row container can be placed in a GridLayout container, and the GridLayout container is positioned on a preset canvas;
the Row space determining module is used for acquiring the size of a Row control which is pre-placed in the Row container, determining the space value of the Row control in the Row container according to the size of the Row control, and obtaining the residual space value corresponding to the Row container according to the space value of the Row container;
the Row control presetting module is used for sequentially acquiring the size of a next Row control which is pre-placed in the Row container, judging whether the Row container can accommodate the next Row control which is pre-placed in the Row container according to the residual space value of the Row container, if the Row container cannot accommodate the next Row control, newly building the Row container, and placing the next Row control which is pre-placed in the Row container in the newly built Row container;
and the output printing module is used for binding the Row control positioned in the Row container with a data source to form a data model, converting the data model into UI metadata, receiving a printing instruction and outputting and printing the UI metadata based on the printing instruction.
7. The system of claim 6, wherein the page specification information includes at least one page specification.
8. The system of claim 7, wherein the line control presetting module comprises:
and the Row container accommodating and confirming unit is used for determining that the plurality of page specifications correspond to different page specification information and the maximum number of Row controls which can be accommodated by the corresponding Row container when the page specification information comprises the plurality of page specifications.
9. The ticket bluetooth printing implementation system of claim 8, wherein the Row space determination module comprises:
the Row container dividing unit is used for dividing the Row container into a plurality of cells with equal size, and the space occupied by the acquired Row control pre-placed in the Row container is integral multiple of the number of the cells;
the Row control space determining unit is used for determining the space value of the Row control in the Row container according to the number of the cells occupied by the Row control in the Row container;
and the residual space determining unit is used for obtaining a residual space value corresponding to the Row container according to the space value of the Row container.
10. A computer storage medium comprising a stored program, wherein the computer storage medium is controlled to execute the ticket bluetooth print implementation method of any one of claims 1-5 on a device when the program is run.
CN202310195713.7A 2023-03-03 2023-03-03 Bill Bluetooth printing implementation method and system and computer storage medium Active CN115857845B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202310195713.7A CN115857845B (en) 2023-03-03 2023-03-03 Bill Bluetooth printing implementation method and system and computer storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202310195713.7A CN115857845B (en) 2023-03-03 2023-03-03 Bill Bluetooth printing implementation method and system and computer storage medium

Publications (2)

Publication Number Publication Date
CN115857845A CN115857845A (en) 2023-03-28
CN115857845B true CN115857845B (en) 2023-04-18

Family

ID=85659829

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202310195713.7A Active CN115857845B (en) 2023-03-03 2023-03-03 Bill Bluetooth printing implementation method and system and computer storage medium

Country Status (1)

Country Link
CN (1) CN115857845B (en)

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN107229398A (en) * 2017-04-27 2017-10-03 广州慧扬健康科技有限公司 Electronic health record form controls linked system
CN112230870A (en) * 2020-12-08 2021-01-15 中博信息技术研究院有限公司 Method and device for printing form data based on line printing style
WO2021108020A1 (en) * 2019-11-25 2021-06-03 Hewlett-Packard Development Company, L.P. Print jobs execution based on print content sizes

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN107229398A (en) * 2017-04-27 2017-10-03 广州慧扬健康科技有限公司 Electronic health record form controls linked system
WO2021108020A1 (en) * 2019-11-25 2021-06-03 Hewlett-Packard Development Company, L.P. Print jobs execution based on print content sizes
CN112230870A (en) * 2020-12-08 2021-01-15 中博信息技术研究院有限公司 Method and device for printing form data based on line printing style

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
儿茶i."Android学习|布局--GridLayout表格布局-(可行、列合并)".《https://blog.csdn.net/weixin_52551903/article/details/123121367》.2022,第1-10. *

Also Published As

Publication number Publication date
CN115857845A (en) 2023-03-28

Similar Documents

Publication Publication Date Title
US9753888B2 (en) Information processing device and conference system
CN108037920A (en) Client customizing form generation method, storage medium
US20120117629A1 (en) Relay apparatus, communication apparatus and relay method
US20180091370A1 (en) Information processing system and report creation method
CN107463348B (en) Method and system for realizing Web end custom format printing based on B/S architecture
CN108964968A (en) Service access management method and system under a kind of container cloud environment
US8881973B2 (en) Connection setting method using barcode pattern, connection setting system and user equipment thereof
CN102422257A (en) System and method for printing via virtual machines
CN104050525B (en) Information processing equipment, information processing method and distribution system
CN103562845B (en) The irrelevant driver of usage platform prints
CN107391277A (en) Information processing method and device
CN107092634A (en) The implementation method and device of page preview
CN110045933A (en) A kind of printing data generating method, device, equipment and storage medium
US9733786B2 (en) System and method of capturing and sharing media
CN108132923A (en) The generation method and system of business paper
CN104038654B (en) Relay, client terminal device and method
CN115857845B (en) Bill Bluetooth printing implementation method and system and computer storage medium
CN110135940A (en) Kitchen order display device and method afterwards
CN109697281A (en) The online method, apparatus and electronic equipment for merging document
CN108733841B (en) Automatic book and periodical cataloguing system at mobile terminal
CN103631540A (en) Method for sharing equipment printing machine
CN104954599A (en) Information processing apparatus, image reading system, and information processing method
CN107888772A (en) A kind of method, apparatus and storage medium for determining configuration information
CN101146123B (en) A mobile phone reading system and its method
CN114064169A (en) Data display method and device and storage medium

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
GR01 Patent grant
GR01 Patent grant