CN107958398A - A kind of method and system to issue invoice - Google Patents

A kind of method and system to issue invoice Download PDF

Info

Publication number
CN107958398A
CN107958398A CN201610896120.3A CN201610896120A CN107958398A CN 107958398 A CN107958398 A CN 107958398A CN 201610896120 A CN201610896120 A CN 201610896120A CN 107958398 A CN107958398 A CN 107958398A
Authority
CN
China
Prior art keywords
invoice
subsystem
warehouse
content
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
CN201610896120.3A
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 Jingdong Century Trading Co Ltd
Beijing Jingdong Shangke Information Technology Co Ltd
Original Assignee
Beijing Jingdong Century Trading Co Ltd
Beijing Jingdong Shangke 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 Beijing Jingdong Century Trading Co Ltd, Beijing Jingdong Shangke Information Technology Co Ltd filed Critical Beijing Jingdong Century Trading Co Ltd
Priority to CN201610896120.3A priority Critical patent/CN107958398A/en
Publication of CN107958398A publication Critical patent/CN107958398A/en
Pending legal-status Critical Current

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06QINFORMATION AND COMMUNICATION TECHNOLOGY [ICT] SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES; SYSTEMS OR METHODS SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES, NOT OTHERWISE PROVIDED FOR
    • G06Q30/00Commerce
    • G06Q30/04Billing or invoicing
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06QINFORMATION AND COMMUNICATION TECHNOLOGY [ICT] SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES; SYSTEMS OR METHODS SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES, NOT OTHERWISE PROVIDED FOR
    • G06Q30/00Commerce
    • G06Q30/06Buying, selling or leasing transactions
    • G06Q30/0601Electronic shopping [e-shopping]
    • G06Q30/0633Lists, e.g. purchase orders, compilation or processing
    • G06Q30/0635Processing of requisition or of purchase orders

Abstract

The invention discloses a kind of method to issue invoice, this method includes:Sequence information is synchronized to invoice subsystem by order subsystem by message queue MQ;Invoice information under invoice subsystem is corresponded to according to the warehouse title of sequence information and advance typing determines the corresponding invoiced amount of the order and every invoice content, and by every invoice content by being transmitted to warehouse subsystem under MQ;Warehouse subsystem is according to the every invoice content passed down, and itself corresponding warehouse of subsystem minimum invoice number is made out an invoice personnel, sequentially prints the corresponding every invoice of the order, completes issuing when time invoice.The invention also discloses a kind of system to issue invoice.It can be reduced because of influence of the system exception to issuing invoice using the present invention.

Description

A kind of method and system to issue invoice
Technical field
The present invention relates to tax service technical field, more particularly to a kind of method and system to issue invoice.
Background technology
Value-added tax common invoice carries very important role in e-commerce:
1st, invoice is to be engaged in production, the enterprises and institutions managed and individual, and in merchandising or dutiable service is provided with it And it is object to be engaged in the taxable income obtained during other business activities, the paying voucher issued to paying party.User can be used for selling Afterwards, the shopping voucher of reimbursement.
2nd, invoice is the carrier for recording economic activity content, is the important tool of financial management;
3rd, invoice is that the tax authority controls the source of tax revenue, the important evidence of collection of tax;Invoice is government supervision economic activity, dimension Economic order is protected, protects the important means of national wealth safety.
Value-added tax common invoice is typically all to give client, the side of prior art invoice issuing with goods in e-commerce Case can be:
S1, the invoice information under invoice subsystem typing warehouse title correspondence, and be each warehouse drawer in the warehouse Member distributes corresponding invoice number section;
Invoice subsystem calls each warehouse in the warehouse corresponding invoice number section of personnel assignment of making out an invoice by WS interfaces It is sent to warehouse subsystem.
S2, warehouse subsystem be verified as each warehouse make out an invoice personnel assignment minimum invoice number and warehouse drawer Whether minimum invoice number is consistent in the paper invoice that member obtains, if unanimously, it is determined that initialization invoice passes through.
After the completion of S3, initialization, warehouse subsystem is called logical according to the correspondence of commodity and order number by WS interfaces Know that the corresponding sequence information of the order number is synchronized to invoice subsystem by order subsystem.
S4, after sequence information synchronization, invoice subsystem according to sequence information and invoice information determine invoice quantity and Every invoice content, and it is transmitted to storehouse under the unique mark generated for every invoice and every invoice content are called by WS interfaces Storehouse subsystem.
S5, warehouse subsystem complete issuing for invoice according to the every invoice of every invoice dump passed down.And record The unique mark of every invoice and the correspondence of invoice number.
S6, warehouse subsystem call the unique mark of every invoice of passback and the correspondence of invoice number by WS interfaces To invoice subsystem.
S7, invoice subsystem have issued invoice according to the correspondence renewal of the unique mark and invoice number of every invoice State.
Before every volume invoice issuing, invoice subsystem repeats step by WS interface call notifications warehouse subsystem S2, carries out issuing for next curly hair ticket.
From the above, it is seen that existing invoice issuing includes:Invoice typing distribution, the initialization of warehouse invoice, sequence information Passed under synchronous, invoice information, the link such as warehouse invoice issuing and warehouse invoice passback.Problem of the prior art is:
1st, interaction is excessive between subsystems, and heavy dependence WS interfaces call, after invoice subsystem typing is allocated successfully, Warehouse subsystem could carry out invoice initialization operation, if initialization unsuccessfully may result in and can not issue invoice;Order subsystem After sequence information is synchronized to invoice subsystem by system, invoice subsystem could pass invoice content down and give warehouse subsystem, if together Step unsuccessfully may result in and can not be passed under invoice;The success of invoice content is passed under warehouse subsystem initialization operation and invoice subsystem Afterwards, issuing for invoice could be carried out;After warehouse subsystem returns to the success of invoice subsystem, invoice subsystem could update itself The newest invoice status of subsystem, lower a roll of invoice initialization could succeed, if invoice returns, unsuccessfully may result in can not Carry out next volume initialization operation, etc..
2nd, WS interfaces call the information content sent every time less.Data volume causes processing time-out greatly in order to prevent, needs Data are transmitted several times for fractionation in very important person, seriously affect work efficiency.
Once the 3rd, WS interfaces malloc failure malloc, it is necessary to after processing invoice information success by hand, can just continue invoice Issue, influence very much to make out an invoice and order production efficiency.It is single call that WS interfaces, which call, once failure, it is necessary to manually it is situated between Enter, it is time-consuming and laborious.
The content of the invention
It is an object of the invention to provide a kind of method and system to issue invoice, can reduce because system exception is to issuing The influence of invoice.
For achieving the above object, the present invention provides a kind of method to issue invoice, this method to include:
Sequence information is synchronized to invoice subsystem by order subsystem by message queue MQ;
Invoice subsystem is ordered according to determining the invoice information under sequence information and the warehouse title correspondence of advance typing Single corresponding invoiced amount and every invoice content, and by every invoice content by being transmitted to warehouse subsystem under MQ;
Warehouse subsystem is according to the every invoice content passed down, and itself corresponding warehouse of subsystem minimum invoice number Make out an invoice personnel, sequentially prints the corresponding every invoice of the order, completes issuing when time invoice.
For achieving the above object, present invention also offers a kind of system to issue invoice, the system to include:
Order subsystem, invoice subsystem is synchronized to by sequence information by message queue MQ;
Invoice subsystem, is ordered according to determining the invoice information under sequence information and the warehouse title correspondence of advance typing Single corresponding invoiced amount and every invoice content, and by every invoice content by being transmitted to warehouse subsystem under MQ;
Warehouse subsystem, according to the every invoice content passed down, and itself corresponding storehouse of subsystem minimum invoice number Make out an invoice personnel in storehouse, sequentially prints the corresponding every invoice of the order, completes issuing when time invoice.
In conclusion the method and system provided by the invention to issue invoice, invoice information correspond to specific warehouse and are entered into In invoice subsystem, and warehouse subsystem is sent to using MQ, the warehouse in the warehouse personnel that make out an invoice voluntarily are claimed in invoice information Respective invoice number section, rather than determine invoice subsystem would not so occur and distribute to storehouse by the distribution of invoice subsystem Storehouse is made out an invoice the inconsistent situation of invoice that the invoice of personnel and warehouse are made out an invoice in personnel's hand, and such warehouse subsystem is just without carrying out Initialization operation.Order subsystem can give invoice subsystem using MQ synchronizations sequence information at any time, without as the prior art that After the completion of sample has to rely on warehouse subsystem initialization operation, order subsystem could synchronous sequence information.Invoice subsystem profit After the success of invoice content is passed under MQ, warehouse subsystem can be carried out issuing for invoice, without the warehouse as the prior art After the success of invoice content is passed under subsystem initialization operation and invoice subsystem, issuing for invoice could be carried out.Warehouse of the present invention Subsystem can be unified to return, it is not necessary to be required for returning after each invoice issuing as the prior art.Therefore, it is of the invention Scheme compared with prior art, by MQ asynchronous process, reduces the direct interaction between system, reduces because system exception is split Has the influence of invoice.
Brief description of the drawings
Fig. 1 is the method flow schematic diagram that the present invention issues invoice.
Fig. 2 is the flow diagram of one managing bill of the embodiment of the present invention.
Fig. 3 is the system structure diagram that the present invention issues invoice.
Embodiment
For the objects, technical solutions and advantages of the present invention are more clearly understood, develop simultaneously embodiment referring to the drawings, right Scheme of the present invention is described in further detail.
Invoice issuing process of the present invention is changed offline by the form of MQ, asynchronization, without worry malloc failure malloc or processing The problems such as overtime, effectively reduce the probability of system exception.Order subsystem of the present invention can be believed using MQ synchronizations order at any time Cease and give invoice subsystem, after the completion of warehouse subsystem initialization operation is had to rely on as the prior art, order subsystem System could synchronous sequence information.That is, before order subsystem synchronization sequence information, it is not necessary to have friendship with warehouse subsystem Mutually.Warehouse subsystem of the present invention can be unified to return, it is not necessary to be required for returning after each invoice issuing as the prior art. That is, the invoice repeatedly issued can disposably be returned to invoice subsystem by warehouse subsystem of the present invention, compared to existing Have for technology, when passback is less with interacting for invoice subsystem.Interaction between system is lacked, and also effectively reduces system exception Probability, so as to reduce because of influence of the system exception to issuing invoice.On the other hand, it is monitored by detecting subsystem, once MQ is abnormal, then using caching, as degradation schemes, scheduling and the supplement of data is carried out, without manpower intervention.
Message queue (MQ) is a kind of communication means of application program to application program.Message transmission is referred between program Communicated by sending data in the message, rather than communicated by directly invoking each other, directly invoked and be typically used for The technology of such as remote procedure call.So the communication between subsystem of the present invention is carried out by MQ, MQ has High Availabitity, height Performance, without worry malloc failure malloc or handles the problems such as overtime.Business procedure is changed offline by MQ, asynchronization, ensure hair Ticket is issued unaffected.
The method flow schematic diagram that the present invention issues invoice is as shown in Figure 1:
Sequence information is synchronized to invoice subsystem by step 11, order subsystem by message queue (MQ);
The sequence information includes:Invoice affiliated area, new line, content of good, goods amount, commodity number.
Step 12, invoice subsystem are determined according to the invoice information under sequence information and the warehouse title correspondence of advance typing The corresponding invoiced amount of order and every invoice content, and by every invoice content by being transmitted to warehouse subsystem under MQ;
Invoice information under the warehouse title corresponds to includes:Invoice affiliated area, invoice codes, invoice are originated to termination Number, Taxpayer Identification Number, invoice height and width, the height of invoice head and tail, and every invoice highest amount issued.
Wherein, the invoice information under invoice subsystem is corresponded to according to the warehouse title of sequence information and advance typing determines institute The corresponding invoiced amount of order and every invoice content are stated, including:
According to invoice height and width, and the height of invoice head and tail, the height that every invoice can print content is obtained;
It can print the height of content according to the detailed occupancy height of each commodity and every invoice, it is most to obtain every invoice Issue commodity number;
Commodity number and every invoice issuing Maximum Amount are at most issued according to every invoice, by the commodity in sequence information Layout is split on multiple invoices.
Step 13, warehouse subsystem are according to the every invoice content passed down, and itself subsystem minimum invoice number pair Make out an invoice personnel in the warehouse answered, and sequentially prints the corresponding every invoice of the order, completes issuing when time invoice.
Every invoice of the printing includes:Invoice affiliated area, new line, content of good, goods amount, commodity number, Make out an invoice personnel for invoice codes, invoice number, Taxpayer Identification Number, warehouse.
Before in warehouse, subsystem prints every invoice, this method further includes:
Invoice information under invoice subsystem corresponds to the warehouse title of institute's typing is sent to warehouse subsystem by MQ;Storehouse Storehouse subsystem confirms that the invoice number section that each warehouse personnel of making out an invoice in the warehouse are distributed is present in the corresponding invoice letter in the warehouse In breath.
Preferably, invoice subsystem by every invoice content by being transmitted to warehouse subsystem under MQ while, will be every Warehouse subsystem is transmitted under the unique mark of invoice generation;
Warehouse subsystem is further included when printing issues invoice:Record when the every invoice that time issue unique mark and The correspondence of invoice number;After the issuing of multiple invoice is completed, uniformly return uniquely marking for every invoice repeatedly issuing Know and the correspondence of invoice number is to invoice subsystem, unique mark by invoice subsystem according to the every invoice repeatedly issued Know and the correspondence of invoice number updates the state to have issued invoice.
Further, even if MQ have High Availabitity, high performance characteristic, but still may there are MQ clusters occur net Network or other problems, cause the disabled situations of MQ, therefore the present invention further detects MQ automatically, to data content Automatically recovered:This method further includes:Detect subsystem timing and send detection MQ message, determine currently to hand over when sending failure Mutual MQ sends abnormal;And timing is detected in data content and MQ receiving terminal local data bases in MQ transmitting terminal cache databases Data content it is whether consistent, if it is inconsistent, by MQ transmitting terminal cache databases data content scheduling add to MQ In receiving terminal local data base.
Embodiment one
Fig. 2 is the flow diagram of one managing bill of the embodiment of the present invention.
S21, typing invoice information to specific warehouse
The corresponding invoice informations of warehouse A of typing in invoice subsystem are 10,000 invoices, volume totally 50, ticket 200 of often perming , invoice initial number is 00001, and the termination number of invoice is 10000, invoice affiliated area A, invoice codes 12345678, Taxpayer Identification Number NSR123, invoice height H1, invoice width W1, every invoice highest amount issued 20,000, invoice head and tail Highly it is H1/3.
A corresponding invoice informations in warehouse are sent to warehouse subsystem by invoice subsystem by MQ.
It should be noted that the present invention sends invoice information by MQ, called unlike the prior art by WS interfaces Invoice information is sent, WS interfaces call the information content sent every time less, and data volume causes processing time-out greatly in order to prevent, Need artificially to split and data are transmitted several times.Therefore the present invention need not split and repeatedly call because invoice amount is big, improve manually behaviour Make efficiency.
S22, the warehouse personnel of making out an invoice claim invoice number
Warehouse A has two warehouses to make out an invoice personnel, and the warehouse personnel 1 that make out an invoice claim invoice number 00001-05000, in warehouse Typing number segment in system, and verify that the number segment is present in the corresponding invoice information in the warehouse.The warehouse personnel 2 that make out an invoice recognize Invoice number 05001-10000, and typing number segment in warehouse subsystem are led, and verifies that the number segment is present in the warehouse In corresponding invoice information.
As described above, the warehouse of warehouse A is made out an invoice personnel 1 and warehouse make out an invoice personnel 2 voluntarily claim it is respective in invoice information Making out an invoice, would not so occur invoice subsystem and distribute to warehouse in invoice number section, rather than determined by the distribution of invoice subsystem The invoice of the personnel situation inconsistent with the invoice that warehouse is made out an invoice in personnel's hand, such warehouse subsystem need not just be initialized Operation.
S23, synchronization
Sequence information is synchronized to invoice subsystem by order subsystem by MQ.Sequence information includes:Invoice affiliated area A, new line, content of good, goods amount, commodity number.
It should be noted that in the present invention before order subsystem synchronization sequence information, it is not necessary to have friendship with warehouse subsystem Mutually.Order subsystem can give invoice subsystem using MQ synchronizations sequence information at any time, without must be according to as the prior art After the completion of relying warehouse subsystem initialization operation, order subsystem could synchronous sequence information.
S24, pass down
Invoice subsystem determines this quantity to issue invoice and every invoice content according to sequence information and invoice information, And by the unique mark generated for every invoice and every invoice content by being transmitted to warehouse subsystem under MQ.
Wherein, invoice subsystem determines this quantity to issue invoice and every invoice according to sequence information and invoice information Content, including:
According to invoice height H1 and invoice width W1, remove the invoice head and tail H1/3 of current region, obtain every invoice Printable content is highly:(H1*2)/3;
It is highly S1 to be taken according to each commodity detail, and every invoice can print content height (H1*2)/3, calculate It is (H1*2)/3S1 to go out the commodity number that every invoice at most prints;Assuming that (H1*2)/3S1=6;
Commodity number 6, and every invoice issuing Maximum Amount 20,000 at most are issued according to every, by sequence information All commodity split layout on multiple invoices.
Under be transmitted to every invoice content of warehouse subsystem and include:Invoice affiliated area, new line, content of good, commodity gold Volume, commodity number, invoice codes, Taxpayer Identification Number.Every invoice contents and distribution is transmitted to warehouse subsystem above and below the page Issued etc. to be printed.
S25, printing
Warehouse subsystem is printed according to the every invoice content passed down, completes invoice issuing.
It should be noted that the invoice number issued in warehouse subsystem will not occur again, so, current minimum hair Ticket number seeks to the invoice number issued.At this time, warehouse subsystem shows the minimum invoice number currently to be printed and storehouse Make out an invoice personnel in storehouse, and warehouse subsystem records the invoice of the minimum invoice number as the invoice in printed invoice on invoice Number, and record the warehouse and make out an invoice personnel.Therefore, the every invoice content finally printed includes:Invoice affiliated area, new line, Make out an invoice personnel for content of good, goods amount, commodity number, invoice codes, Taxpayer Identification Number, invoice number, warehouse.
While printing, the unique mark of every invoice and the correspondence of invoice number are recorded.
S26, unified passback
After multiple invoice issuing, warehouse subsystem uniformly returns the unique mark and invoice number of every invoice by MQ Correspondence to invoice subsystem.
It should be noted that warehouse subsystem of the present invention can be unified to return, it is not necessary to be sent out every time as the prior art Ticket is required for returning after issuing.That is, warehouse subsystem of the present invention can disposably return to the invoice repeatedly issued Invoice subsystem, compared with the prior art for, when passback, is less with interacting for invoice subsystem.
S27, renewal
Invoice subsystem has issued invoice according to the unique mark of every invoice and the correspondence renewal of invoice number State.
Particularly as being that will return to the invoice number of invoice subsystem, mark out and in invoice information, be labeled as having opened Tool.
Thus, the invoice management method of the present invention is completed.After the updating, order subsystem can carry out order again The synchronization of information, continues above-mentioned flow, completes the management of invoice.Invoice information corresponds to specific warehouse and is entered into invoice subsystem In, and it is sent to warehouse subsystem using MQ, the warehouse in the warehouse personnel that make out an invoice voluntarily claim respective invoice in invoice information Making out an invoice personnel, would not so occur invoice subsystem and distribute to warehouse in number segment, rather than determined by the distribution of invoice subsystem The inconsistent situation of the invoice made out an invoice in personnel's hand of invoice and warehouse, such warehouse subsystem need not just carry out initialization behaviour Make.Order subsystem can give invoice subsystem using MQ synchronizations sequence information at any time, without must be according to as the prior art After the completion of relying warehouse subsystem initialization operation, order subsystem could synchronous sequence information.Invoice subsystem utilizes to be passed under MQ After the success of invoice content, warehouse subsystem can be carried out issuing for invoice, without at the beginning of the warehouse subsystem as the prior art After the success of invoice content is passed under beginningization operation and invoice subsystem, issuing for invoice could be carried out.
Embodiment two
Even if MQ message have High Availabitity, high performance characteristic, but still may there are MQ clusters occur network or Person's other problems, cause the disabled situation of MQ message.Therefore, the present invention is further monitored by detecting subsystem, and one Denier MQ is abnormal, then using caching, as degradation schemes, scheduling and the supplement of data is carried out, without manpower intervention.The present invention Quartz detection scheduling is utilized in embodiment.
Quartz be one completely by the job scheduling frame of increasing income of written in Java, to be made in java application Industry scheduling provides simple powerful mechanism.Quartz allows developer according to time interval come schedule job.
For the present invention in embodiment one, the interaction between subsystem is all that the subsystem that MQ is sent by MQ is referred to as MQ hairs Sending end, the subsystem for receiving MQ are referred to as MQ receiving terminals.When MQ transmitting terminals are to MQ receiving terminals transmission MQ, the data content of transmission is delayed There are in cache database.Therefore, Quartz timings send detection MQ message, and the MQ hairs currently interacted are determined when sending and failing Send exception;And timing is detected in the data in data content and MQ receiving terminal local data bases in MQ transmitting terminal cache databases Whether appearance is consistent, if it is inconsistent, the data content scheduling in MQ transmitting terminal cache databases is added to MQ receiving terminal sheets In ground database.
Citing one, the corresponding invoice informations of invoice subsystem Redia caching warehouses A are 10,000 invoices, volume totally 50, are often rolled up Invoice 200 is opened, and invoice initial number is 00001, and the termination number of invoice is 10000, invoice affiliated area A, invoice codes 12345678, Taxpayer Identification Number NSR123, invoice height H1, invoice width W1, every invoice highest amount issued 20,000, hair The height of ticket head and tail is H1/3.
A corresponding invoice informations in warehouse are sent to warehouse subsystem by invoice subsystem by MQ.
In data content and warehouse subsystem local data base in Quartz timing detection invoice subsystem Redia cachings Data content it is whether consistent, if inconsistent, illustrate MQ exception, then by invoice subsystem Redia cache in data content Scheduling is added in warehouse subsystem local data base.
Citing two, order subsystem Redia caching sequence informations, sequence information include:Invoice affiliated area A, new line, business Product content, goods amount, commodity number.
Sequence information is synchronized to invoice subsystem by order subsystem by MQ.
In data content and invoice subsystem local data base in Quartz timing detection order subsystem Redia cachings Data content it is whether consistent, if inconsistent, illustrate MQ exception, then by order subsystem Redia cache in data content Scheduling is added in invoice subsystem local data base.
Citing three, invoice subsystem Redia cache every invoice content of unique mark and correspondence of every invoice.
Invoice subsystem will be held in the unique mark of every invoice and corresponding every invoice by MQ and be transmitted to warehouse subsystem System.
In data content and warehouse subsystem local data base in Quartz timing detection invoice subsystem Redia cachings Data content it is whether consistent, if inconsistent, illustrate MQ exception, then by invoice subsystem Redia cache in data content Scheduling is added in warehouse subsystem local data base.
Citing four, warehouse subsystem Redia cache the unique mark of every invoice and the correspondence of invoice number.
Warehouse subsystem uniformly returns the unique mark of every invoice and the correspondence of invoice number by MQ to invoice Subsystem.
In data content and invoice subsystem local data base in Quartz timing detection warehouse subsystem Redia cachings Data content it is whether consistent, if inconsistent, illustrate MQ exception, then by warehouse subsystem Redia cache in data content Scheduling is added in invoice subsystem local data base.
Embodiment three
Based on same inventive concept, present invention also offers a kind of system to issue invoice, structure diagram such as Fig. 3 institutes Show, which includes:
Order subsystem 301, invoice subsystem is synchronized to by sequence information by message queue MQ;
Invoice subsystem 302, the invoice information under being corresponded to according to the warehouse title of sequence information and advance typing determine institute The corresponding invoiced amount of order and every invoice content are stated, and by every invoice content by being transmitted to warehouse subsystem under MQ;
Warehouse subsystem 303, according to the every invoice content passed down, and itself subsystem minimum invoice number is corresponding Make out an invoice personnel in warehouse, sequentially prints the corresponding every invoice of the order, completes issuing when time invoice.
Before in warehouse, subsystem prints every invoice,
The invoice subsystem 302, the invoice information being additionally operable under the warehouse title of institute's typing is corresponded to are sent by MQ Give warehouse subsystem;
The warehouse subsystem 303, is additionally operable to confirm the invoice number section that each warehouse personnel of making out an invoice in the warehouse are distributed It is present in the corresponding invoice information in the warehouse.
The invoice subsystem 302 by every invoice content by being transmitted to warehouse subsystem 303 under MQ while, will be every Open and be transmitted to warehouse subsystem 303 under the unique mark of invoice generation;
The warehouse subsystem 303 is additionally operable to record and works as the unique of the secondary every invoice issued when printing issues invoice The correspondence of mark and invoice number;After the issuing of multiple invoice is completed, every invoice repeatedly issuing uniformly is returned The correspondence of unique mark and invoice number is to invoice subsystem, by invoice subsystem according to the every invoice repeatedly issued The state that the renewal of the correspondence of unique mark and invoice number has issued invoice.
When MQ transmitting terminals are to MQ receiving terminals transmission MQ, the data content of transmission is buffered in cache database;
The system also includes detection subsystem 304, sends detection MQ message for timing, determines to work as when sending failure The MQ of preceding interaction sends abnormal;And timing detects the data content and MQ receiving terminal local datas in MQ transmitting terminal cache databases Whether the data content in storehouse is consistent, if it is inconsistent, the data content in MQ transmitting terminal cache databases is dispatched supplement Into MQ receiving terminal local data bases.
The method to issue invoice of the present invention, can bring following benefit:
First, the method to issue invoice of the invention, reduces the direct interaction between system, reduces because of system exception pair The influence of normal invoice issuing.
2nd, by MQ message asynchronous process, the direct interaction between system is further reduced, is reduced because of system exception Influence to normal invoice issuing.
3rd, by MQ message asynchronous process, data processing amount is improved, the redundant work for manually splitting and bringing is reduced, carries High workload efficiency.
4th, by detecting automatic recovery automatically, realize without manpower intervention, it is intelligentized note abnormalities, handle it is abnormal.
The foregoing is only a preferred embodiment of the present invention, is not intended to limit the scope of the present invention.It is all Within the spirit and principles in the present invention, any modification, equivalent replacement, improvement and so on, should be included in the protection of the present invention Within the scope of.

Claims (10)

  1. A kind of 1. method to issue invoice, it is characterised in that this method includes:
    Sequence information is synchronized to invoice subsystem by order subsystem by message queue MQ;
    Invoice information under invoice subsystem is corresponded to according to the warehouse title of sequence information and advance typing determines the order pair The invoiced amount answered and every invoice content, and by every invoice content by being transmitted to warehouse subsystem under MQ;
    Warehouse subsystem is according to the every invoice content passed down, and itself corresponding warehouse of subsystem minimum invoice number is made out an invoice Personnel, sequentially print the corresponding every invoice of the order, complete issuing when time invoice.
  2. 2. the method as described in claim 1, it is characterised in that before subsystem prints every invoice in warehouse, this method is also Including:
    Invoice information under invoice subsystem corresponds to the warehouse title of institute's typing is sent to warehouse subsystem by MQ;
    It is corresponding that warehouse subsystem confirms that the invoice number section that each warehouse personnel of making out an invoice in the warehouse are distributed is present in the warehouse In invoice information.
  3. 3. the method as described in claim 1, it is characterised in that invoice subsystem is by every invoice content by being transmitted to storehouse under MQ While the subsystem of storehouse, warehouse subsystem is transmitted under the unique mark that will be generated for every invoice;
    Warehouse subsystem is further included when printing issues invoice:Record is when the unique mark and invoice of the secondary every invoice issued The correspondence of number;After the issuing of multiple invoice is completed, uniformly return the unique mark of the every invoice repeatedly issued with The correspondence of invoice number to invoice subsystem, by invoice subsystem according to the unique mark for the every invoice repeatedly issued and The state that the correspondence renewal of invoice number has issued invoice.
  4. 4. the method as described in claim 1,2 or 3, it is characterised in that when MQ transmitting terminals are to MQ receiving terminals transmission MQ, will send Data content be buffered in cache database;This method further includes:Detect subsystem timing and send detection MQ message, sending The MQ for determining currently to interact during failure sends abnormal;And periodically the data content in detection MQ transmitting terminal cache databases and MQ connect Whether the data content in receiving end local data base is consistent, if it is inconsistent, by the data in MQ transmitting terminal cache databases Content scheduling is added in MQ receiving terminal local data bases.
  5. 5. the method as described in claim 1, it is characterised in that
    The sequence information includes:Invoice affiliated area, new line, content of good, goods amount, commodity number;
    Invoice information under the warehouse title corresponds to includes:Invoice affiliated area, invoice codes, invoice are originated to termination number Code, Taxpayer Identification Number, invoice height and width, the height of invoice head and tail, and every invoice highest amount issued;
    Every invoice of the printing includes:Invoice affiliated area, new line, content of good, goods amount, commodity number, invoice Make out an invoice personnel for code, invoice number, Taxpayer Identification Number, warehouse.
  6. 6. method as claimed in claim 5, it is characterised in that the invoice subsystem is according to sequence information and advance typing Invoice information under warehouse title corresponds to determines the corresponding invoiced amount of the order and every invoice content, including:
    According to invoice height and width, and the height of invoice head and tail, the height that every invoice can print content is obtained;
    It can print the height of content according to the detailed occupancy height of each commodity and every invoice, obtain every invoice and at most issue Commodity number;
    Commodity number and every invoice issuing Maximum Amount are at most issued according to every invoice, the commodity in sequence information are split Layout is on multiple invoices.
  7. 7. a kind of system to issue invoice, it is characterised in that the system includes:
    Order subsystem, invoice subsystem is synchronized to by sequence information by message queue MQ;
    Invoice subsystem, the invoice information under being corresponded to according to the warehouse title of sequence information and advance typing determine the order pair The invoiced amount answered and every invoice content, and by every invoice content by being transmitted to warehouse subsystem under MQ;
    Warehouse subsystem, according to the every invoice content passed down, and itself corresponding warehouse of subsystem minimum invoice number is opened Ticket personnel, sequentially print the corresponding every invoice of the order, complete issuing when time invoice.
  8. 8. system as claimed in claim 7, it is characterised in that before in warehouse, subsystem prints every invoice,
    The invoice subsystem, the invoice information being additionally operable under the warehouse title of institute's typing is corresponded to are sent to warehouse by MQ System;
    The warehouse subsystem, is additionally operable to confirm that the invoice number section that each warehouse personnel of making out an invoice in the warehouse are distributed is present in this In the corresponding invoice information in warehouse.
  9. 9. system as claimed in claim 7, it is characterised in that the invoice subsystem is by every invoice content by being passed under MQ While to warehouse subsystem, warehouse subsystem is transmitted under the unique mark that will be generated for every invoice;
    The warehouse subsystem is additionally operable to record when the unique mark and hair of the secondary every invoice issued when printing issues invoice The correspondence of ticket number;After the issuing of multiple invoice is completed, the unique mark for the every invoice repeatedly issued uniformly is returned Correspondence with invoice number is to invoice subsystem, the unique mark by invoice subsystem according to the every invoice repeatedly issued The state that correspondence renewal with invoice number has issued invoice.
  10. 10. the system as described in claim 7,8 or 9, it is characterised in that when MQ transmitting terminals are to MQ receiving terminals transmission MQ, will send out The data content sent is buffered in cache database;
    The system also includes detection subsystem, sends detection MQ message for timing, current interaction is determined when sending failure MQ send it is abnormal;And timing is detected in data content and MQ receiving terminal local data bases in MQ transmitting terminal cache databases Whether data content is consistent, is connect if it is inconsistent, the data content scheduling in MQ transmitting terminal cache databases is added to MQ In receiving end local data base.
CN201610896120.3A 2016-10-14 2016-10-14 A kind of method and system to issue invoice Pending CN107958398A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201610896120.3A CN107958398A (en) 2016-10-14 2016-10-14 A kind of method and system to issue invoice

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201610896120.3A CN107958398A (en) 2016-10-14 2016-10-14 A kind of method and system to issue invoice

Publications (1)

Publication Number Publication Date
CN107958398A true CN107958398A (en) 2018-04-24

Family

ID=61953149

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201610896120.3A Pending CN107958398A (en) 2016-10-14 2016-10-14 A kind of method and system to issue invoice

Country Status (1)

Country Link
CN (1) CN107958398A (en)

Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101051405A (en) * 2007-03-14 2007-10-10 浪潮齐鲁软件产业有限公司 Automatic data collecting and making out invoice method for tax controller to oil filler
CN101894398A (en) * 2010-07-28 2010-11-24 浪潮齐鲁软件产业有限公司 Method for automatically issuing invoices through connecting tax control machine by POS machine
CN101901504A (en) * 2010-06-24 2010-12-01 深圳市泰海科技有限公司 Method, system and device for printing invoice
CN102779132A (en) * 2011-05-12 2012-11-14 阿里巴巴集团控股有限公司 Data updating method, system and database server
CN104463647A (en) * 2014-12-26 2015-03-25 浪潮软件集团有限公司 Electronic invoice-based electronic posting method and system and electronic invoice client
CN104679596A (en) * 2013-12-02 2015-06-03 航天信息股份有限公司 Message processing method and system for improving concurrence performance of server-side

Patent Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101051405A (en) * 2007-03-14 2007-10-10 浪潮齐鲁软件产业有限公司 Automatic data collecting and making out invoice method for tax controller to oil filler
CN101901504A (en) * 2010-06-24 2010-12-01 深圳市泰海科技有限公司 Method, system and device for printing invoice
CN101894398A (en) * 2010-07-28 2010-11-24 浪潮齐鲁软件产业有限公司 Method for automatically issuing invoices through connecting tax control machine by POS machine
CN102779132A (en) * 2011-05-12 2012-11-14 阿里巴巴集团控股有限公司 Data updating method, system and database server
CN104679596A (en) * 2013-12-02 2015-06-03 航天信息股份有限公司 Message processing method and system for improving concurrence performance of server-side
CN104463647A (en) * 2014-12-26 2015-03-25 浪潮软件集团有限公司 Electronic invoice-based electronic posting method and system and electronic invoice client

Similar Documents

Publication Publication Date Title
CN107665460A (en) Accounting method and device based on real-time deal
JPS58112155A (en) Business system
CN102841927A (en) Method and device for data interaction among a plurality of databases and distributed data interaction system
CN101877099A (en) Day-end processing module based on bank preposing service platforms and application method thereof
CN102004989A (en) Electric power business service system
CN204740627U (en) System is ordered to film ticket
CN111400344A (en) Electronic bill printing method, device, equipment and storage medium
CN111724046B (en) Electricity purchase management system
CN114118921B (en) System and method for realizing integration of material allocation based on ERP system
CN109961359A (en) A kind of fund management method and capital management platform
CN101452586A (en) Intelligent queuing machine system and method for auto distributing counter according to service kinds for bank
CN106600193A (en) TPS system
CN107247715A (en) The synchronous method of WMS systems and ERP system
CN107958398A (en) A kind of method and system to issue invoice
CN101140647A (en) Invoices processing method of network tax control system
WO1991007725A2 (en) Point of sale system
WO2003079140A2 (en) Revenue recognition system and method for efficiently performing business-related processing and storing of event information related to a transaction
CN105512829A (en) Web service protocol-based card value multidimensional cost accumulation method
CN113254835B (en) Intelligent scenic spot server architecture and data processing method thereof
CN105488891B (en) A kind of queuing processing system
CN109544272A (en) A kind of order management system based on e-commerce platform
CN101916484A (en) Tax fund monitoring system and method for large-scale supermarket and marketplace
CN103914514B (en) The method and system of the control business voucher way of output
CN106707935A (en) Data exchange monitoring device and data exchange monitoring method based on host platform
CN103067901A (en) Billing early warning method and billing early warning system

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: 20180424

RJ01 Rejection of invention patent application after publication