CN109558063A - A kind of offline storage method and device of electronic invoice - Google Patents

A kind of offline storage method and device of electronic invoice Download PDF

Info

Publication number
CN109558063A
CN109558063A CN201710875447.7A CN201710875447A CN109558063A CN 109558063 A CN109558063 A CN 109558063A CN 201710875447 A CN201710875447 A CN 201710875447A CN 109558063 A CN109558063 A CN 109558063A
Authority
CN
China
Prior art keywords
offline storage
storage block
electronic
offline
electronic invoices
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
CN201710875447.7A
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.)
Aisino Corp
Original Assignee
Aisino Corp
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 Aisino Corp filed Critical Aisino Corp
Priority to CN201710875447.7A priority Critical patent/CN109558063A/en
Publication of CN109558063A publication Critical patent/CN109558063A/en
Pending legal-status Critical Current

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/06Digital input from, or digital output to, record carriers, e.g. RAID, emulated record carriers or networked record carriers
    • G06F3/0601Interfaces specially adapted for storage systems
    • G06F3/0668Interfaces specially adapted for storage systems adopting a particular infrastructure
    • G06F3/067Distributed or networked storage systems, e.g. storage area networks [SAN], network attached storage [NAS]
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L63/00Network architectures or network communication protocols for network security
    • H04L63/12Applying verification of the received information
    • H04L63/123Applying verification of the received information received data contents, e.g. message integrity
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/06Digital input from, or digital output to, record carriers, e.g. RAID, emulated record carriers or networked record carriers
    • G06F3/0601Interfaces specially adapted for storage systems
    • G06F3/0602Interfaces specially adapted for storage systems specifically adapted to achieve a particular effect
    • G06F3/062Securing storage systems
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/06Digital input from, or digital output to, record carriers, e.g. RAID, emulated record carriers or networked record carriers
    • G06F3/0601Interfaces specially adapted for storage systems
    • G06F3/0602Interfaces specially adapted for storage systems specifically adapted to achieve a particular effect
    • G06F3/0626Reducing size or complexity of storage systems
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/06Digital input from, or digital output to, record carriers, e.g. RAID, emulated record carriers or networked record carriers
    • G06F3/0601Interfaces specially adapted for storage systems
    • G06F3/0628Interfaces specially adapted for storage systems making use of a particular technique
    • G06F3/0638Organizing or formatting or addressing of data
    • G06F3/0643Management of files
    • 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
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L9/00Cryptographic mechanisms or cryptographic arrangements for secret or secure communications; Network security protocols
    • H04L9/32Cryptographic mechanisms or cryptographic arrangements for secret or secure communications; Network security protocols including means for verifying the identity or authority of a user of the system or for message authentication, e.g. authorization, entity authentication, data integrity or data verification, non-repudiation, key authentication or verification of credentials
    • H04L9/3236Cryptographic mechanisms or cryptographic arrangements for secret or secure communications; Network security protocols including means for verifying the identity or authority of a user of the system or for message authentication, e.g. authorization, entity authentication, data integrity or data verification, non-repudiation, key authentication or verification of credentials using cryptographic hash functions
    • H04L9/3239Cryptographic mechanisms or cryptographic arrangements for secret or secure communications; Network security protocols including means for verifying the identity or authority of a user of the system or for message authentication, e.g. authorization, entity authentication, data integrity or data verification, non-repudiation, key authentication or verification of credentials using cryptographic hash functions involving non-keyed hash functions, e.g. modification detection codes [MDCs], MD5, SHA or RIPEMD
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L9/00Cryptographic mechanisms or cryptographic arrangements for secret or secure communications; Network security protocols
    • H04L9/32Cryptographic mechanisms or cryptographic arrangements for secret or secure communications; Network security protocols including means for verifying the identity or authority of a user of the system or for message authentication, e.g. authorization, entity authentication, data integrity or data verification, non-repudiation, key authentication or verification of credentials
    • H04L9/3297Cryptographic mechanisms or cryptographic arrangements for secret or secure communications; Network security protocols including means for verifying the identity or authority of a user of the system or for message authentication, e.g. authorization, entity authentication, data integrity or data verification, non-repudiation, key authentication or verification of credentials involving time stamps, e.g. generation of time stamps
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L9/00Cryptographic mechanisms or cryptographic arrangements for secret or secure communications; Network security protocols
    • H04L9/50Cryptographic mechanisms or cryptographic arrangements for secret or secure communications; Network security protocols using hash chains, e.g. blockchains or hash trees
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L63/00Network architectures or network communication protocols for network security
    • H04L63/08Network architectures or network communication protocols for network security for authentication of entities
    • H04L63/0823Network architectures or network communication protocols for network security for authentication of entities using certificates

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Computer Security & Cryptography (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Human Computer Interaction (AREA)
  • Business, Economics & Management (AREA)
  • Development Economics (AREA)
  • Economics (AREA)
  • Marketing (AREA)
  • Strategic Management (AREA)
  • Finance (AREA)
  • General Business, Economics & Management (AREA)
  • Accounting & Taxation (AREA)
  • Computing Systems (AREA)
  • Computer Hardware Design (AREA)
  • Storage Device Security (AREA)

Abstract

The invention discloses a kind of offline storage method and devices of electronic invoice, and when receiving electronic invoice store instruction, the electronic invoice received is divided at least one set;For any group of electronic invoice, the present offline memory block of offline storage block chain corresponding with this group of electronic invoice is determined;According to this group of electronic invoice and the present offline memory block, an offline storage block is created;By the offline storage block chaining to the present offline memory block, and using the offline storage block as new present offline memory block.Compared with the prior art, in embodiments of the present invention, the offline storage of electronic invoice can be realized by the block chain technology based on common recognition algorithm, without occupying the local disk of enterprise-wide computer, without requiring enterprise etc. to have or buy electronic invoice service platform, thus reduce cost of implementation;And block chain technology has the characteristics of cannot modifying and can not deleting, thus can also ensure that the safety of electronic invoice.

Description

Offline storage method and device for electronic invoices
Technical Field
The invention relates to the technical field of electronic invoices, in particular to an off-line storage method and device of an electronic invoice.
Background
At present, according to the provision of the accounting electronic document, the storage time of the electronic invoice can not be less than 30 years, and when the electronic invoice is stored by an enterprise and the like, especially when the electronic invoice is stored off line, the electronic invoice can be stored in two ways:
first, local storage, i.e., in the local disks of computers within an enterprise. However, this method requires a large storage space, and thus may cause a problem of high storage cost;
and secondly, storing the data in different places, namely storing the data in an electronic invoice service platform. The electronic invoice service platform can be an electronic invoice service platform owned by an enterprise and the like, or an electronic invoice service platform purchased from a third party. However, this approach still has the problem of high storage cost; in addition, when the electronic invoice service platform is an electronic invoice service platform purchased by a third party, such as an enterprise, the security may be low.
That is to say, the existing offline storage method of the electronic invoice has the problems of high cost and low safety.
Disclosure of Invention
The embodiment of the invention provides an offline storage method and device of an electronic invoice, which are used for solving the problems of higher cost and lower safety of the conventional offline storage method of the electronic invoice.
The embodiment of the invention provides an off-line storage method of an electronic invoice, which comprises the following steps:
when an electronic invoice storage instruction is received, dividing the received electronic invoices into at least one group;
aiming at any group of electronic invoices, determining a current offline storage block of an offline storage block chain corresponding to the group of electronic invoices; the current offline storage block refers to the last offline storage block of the offline storage block chain at the current moment;
creating an offline storage block according to the group of electronic invoices and the current offline storage block; the offline storage block is a set for recording invoice information of the group of electronic invoices and the link relation of the offline storage block;
and linking the offline storage block to the current offline storage block, and taking the offline storage block as a new current offline storage block.
Specifically, dividing the received electronic invoices into at least one group, including:
dividing the issued electronic invoices into at least one group according to the receiving time; or,
dividing the issued electronic invoices into at least one group according to the receiving objects; or,
and dividing the issued electronic invoices into at least one group according to the service type.
Optionally, the offline storage block includes a block hash value, a pointer pointing to a previous offline storage block of the offline storage block in the offline storage block chain, an invoice number of the group of electronic invoices, and an image file of the group of electronic invoices.
Optionally, the offline storage block further includes a time identifier for creating the offline storage block.
Further, the offline storage method of the electronic invoice further comprises the following steps:
and displaying the invoice number of the electronic invoice in the offline storage area blockchain.
Further, the offline storage method of the electronic invoice further comprises the following steps:
when a query instruction is received, determining an invoice number corresponding to the query instruction;
and displaying the electronic invoice corresponding to the invoice number and/or the offline storage block where the electronic invoice is located.
Correspondingly, the embodiment of the invention also provides an offline storage device of the electronic invoice, which comprises:
the system comprises a dividing module, a storage module and a processing module, wherein the dividing module is used for dividing the received electronic invoices into at least one group when receiving an electronic invoice storage instruction;
the determining module is used for determining the current offline storage block of the offline storage block chain corresponding to any group of electronic invoices; the current offline storage block refers to the last offline storage block of the offline storage block chain at the current moment;
the creating module is used for creating an offline storage block according to the group of electronic invoices and the current offline storage block; the offline storage block is a set for recording invoice information of the group of electronic invoices and the link relation of the offline storage block;
and the linking module is used for linking the offline storage block to the current offline storage block and taking the offline storage block as a new current offline storage block.
Specifically, the dividing module is specifically configured to divide the issued electronic invoices into at least one group according to the receiving time; or, dividing the issued electronic invoices into at least one group according to the receiving objects; or, the issued electronic invoices are divided into at least one group according to the service type.
Optionally, the offline storage block includes a block hash value, a pointer pointing to a previous offline storage block of the offline storage block in the offline storage block chain, an invoice number of the group of electronic invoices, and an image file of the group of electronic invoices.
Optionally, the offline storage block further includes a time identifier for creating the offline storage block.
Further, the offline storage device of the electronic invoice further comprises:
and the display module is used for displaying the invoice number of the electronic invoice in the offline storage area block chain.
Further, the display module is further configured to determine an invoice number corresponding to the query instruction when the query instruction is received; and displaying the electronic invoice corresponding to the invoice number and/or the offline storage block where the electronic invoice is located.
Accordingly, an embodiment of the present invention provides a computing device, including a memory and a processor, wherein:
the memory to store program instructions;
the processor is used for calling the program instructions stored in the memory and executing the offline storage method of the electronic invoice in the embodiment of the invention according to the obtained program.
In addition, the embodiment of the present invention further provides a computer storage medium, where the computer storage medium stores computer-executable instructions, and the computer-executable instructions are used to enable the computer to execute the offline storage method for electronic invoices in the embodiment of the present invention.
The invention has the following beneficial effects:
the embodiment of the invention provides an off-line storage method and device of electronic invoices, wherein when an electronic invoice storage instruction is received, the received electronic invoices are divided into at least one group; aiming at any group of electronic invoices, determining a current offline storage block of an offline storage block chain corresponding to the group of electronic invoices; the current offline storage block refers to the last offline storage block of the offline storage block chain at the current moment; creating an offline storage block according to the group of electronic invoices and the current offline storage block; the offline storage block is a set for recording invoice information of the group of electronic invoices and the link relation of the offline storage block; and linking the offline storage block to the current offline storage block, and taking the offline storage block as a new current offline storage block. Compared with the prior art, in the embodiment of the invention, the off-line storage of the electronic invoice can be realized by a block chain technology based on a consensus algorithm, without occupying a local disk of a computer in an enterprise, without requiring the enterprise and the like to have a corresponding electronic invoice service platform, and without purchasing the electronic invoice service platform from a third party, so that the realization cost is reduced; moreover, the block chain technology has the characteristics of incapability of modification and incapability of deletion, so that the safety of the stored electronic invoices can be ensured.
Drawings
In order to more clearly illustrate the technical solutions in the embodiments of the present invention, the drawings needed to be used in the description of the embodiments will be briefly introduced below, and it is obvious that the drawings in the following description are only some embodiments of the present invention, and it is obvious for those skilled in the art to obtain other drawings based on these drawings without creative efforts.
Fig. 1 is a schematic flow chart illustrating a method for offline storing an electronic invoice according to an embodiment of the present invention;
fig. 2 is a schematic structural diagram of a first offline storage block according to a first embodiment of the present invention;
fig. 3 is a schematic structural diagram of a second offline storage block according to a first embodiment of the present invention;
fig. 4 is a schematic structural diagram illustrating an offline storage device for electronic invoices according to a second embodiment of the present invention;
fig. 5 is a schematic structural diagram of a computing device provided in the third embodiment of the present invention.
Detailed Description
In order to make the objects, technical solutions and advantages of the present invention clearer, the present invention will be described in further detail with reference to the accompanying drawings, and it is apparent that the described embodiments are only a part of the embodiments of the present invention, not all of the embodiments. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present invention.
The first embodiment is as follows:
in order to solve the problems of high cost and low security of the existing offline storage method for electronic invoices, an embodiment of the present invention provides an offline storage method for electronic invoices, as shown in fig. 1, which is a schematic flow diagram of the offline storage method for electronic invoices in the embodiment of the present invention. Specifically, as can be seen from fig. 1, the offline storage method of the electronic invoice may include the following steps:
step 101: when an electronic invoice storage instruction is received, dividing the received electronic invoices into at least one group;
step 102: aiming at any group of electronic invoices, determining a current offline storage block of an offline storage block chain corresponding to the group of electronic invoices; the current offline storage block refers to the last offline storage block of the offline storage block chain at the current moment;
step 103: creating an offline storage block according to the group of electronic invoices and the current offline storage block; the offline storage block is a set for recording invoice information of the group of electronic invoices and the link relation of the offline storage block;
step 104: and linking the offline storage block to the current offline storage block, and taking the offline storage block as a new current offline storage block.
That is, in the embodiment of the present invention, when an electronic invoice storage instruction is received, the received electronic invoices are divided into at least one group; aiming at any group of electronic invoices, determining a current offline storage block of an offline storage block chain corresponding to the group of electronic invoices; the current offline storage block refers to the last offline storage block of the offline storage block chain at the current moment; creating an offline storage block according to the group of electronic invoices and the current offline storage block; the offline storage block is a set for recording invoice information of the group of electronic invoices and the link relation of the offline storage block; and linking the offline storage block to the current offline storage block, and taking the offline storage block as a new current offline storage block. Compared with the prior art, in the embodiment of the invention, the off-line storage of the electronic invoice can be realized by a block chain technology based on a consensus algorithm, without occupying a local disk of a computer in an enterprise, without requiring the enterprise and the like to have a corresponding electronic invoice service platform, and without purchasing the electronic invoice service platform from a third party, so that the realization cost is reduced; moreover, the block chain technology has the characteristics of incapability of modification and incapability of deletion, so that the safety of the stored electronic invoices can be ensured.
In the embodiment of the invention, the execution subject of the offline storage method of the electronic invoice can be an offline storage device of the electronic invoice of the invoicing party of the electronic invoice or an offline storage device of the electronic invoice of the invoiced party. The off-line storage device of the electronic invoice can be an integrated device which is integrated in a corresponding computer, such as a magnetic disk, a hard disk and the like, no matter the invoice issuer or the invoice acquirer; or an independent device arranged independently, such as a U disk, a mobile hard disk and the like. Certainly, the offline storage device of the electronic invoice can also be a cloud disk, a cloud space and the like, which is not described in detail herein.
Specifically, the electronic invoice storage instruction is an instruction for instructing a invoicing party to perform an electronic invoice posting operation, the electronic invoice storage instruction may be generally triggered automatically, and the triggering conditions may generally include the following:
the time interval from the last trigger is not less than the set time interval threshold; or,
the number of the received electronic invoices is not less than a set number threshold value; or,
and receiving an updating instruction.
The time interval threshold and the number threshold may be flexibly set according to actual conditions, for example, the time interval threshold may be set to 1 day, 1h (hour), 1min (minute), or 1s (second), and the number threshold may be set to 1000 sheets, 100 sheets, 10 sheets, or 1 sheet, as long as actual requirements can be met, which is not limited in this embodiment of the present invention.
It should be noted that the received electronic invoice described herein may be an electronic invoice that has not been stored yet after the last storage, and for an electronic invoice that has been stored before, nothing is done here.
Optionally, dividing the received electronic invoices into at least one group may include:
dividing the issued electronic invoices into at least one group according to the receiving time; or,
dividing the issued electronic invoices into at least one group according to the receiving objects; or,
and dividing the issued electronic invoices into at least one group according to the service type.
The receiving object can be a invoicing party or a ticketing party of the electronic invoice generally, and when the executing main body of the offline storage method of the electronic invoice is the invoicing party, the receiving object can be a corresponding ticketing party; when the execution main body of the offline storage method for the electronic invoice is the invoice receiver, the receiving object can be the corresponding invoice issuer, which is not described in detail herein.
In the embodiment of the present invention, the receiving time, the receiving object, and the receiving type of the electronic invoice may be collectively referred to as attribute information of the electronic invoice, and of course, the attribute information of the electronic invoice may also include other information, such as a number segment of the electronic invoice, and details thereof are not described herein.
For example, the electronic invoice received No. 1 may be divided into group 1, the electronic invoice received No. 2 may be divided into group 2, the electronic invoice received No. 30 may be divided into group 30, and so on; or, the electronic invoices received from 0 point to 8 points can be divided into the 1 st group, the electronic invoices received from 8 points to 16 points are divided into the 2 nd group, the electronic invoices received from 16 points to 24 points are divided into the 3 rd group and the like; for another example, the electronic invoice received from the invoicer a may be divided into group 1, the electronic invoice received from the invoicer B may be divided into group 2, the electronic invoice received from the invoicer C may be divided into group 3, and so on; or, the electronic invoice issued to the invoicer A is divided into the 1 st group, the electronic invoice issued to the invoicer B is divided into the 2 nd group, the electronic invoice issued to the invoicer C is divided into the 3 rd group, and the like; for another example, the received electronic invoices for accommodation may be divided into group 1, the received electronic invoices for catering may be divided into group 2, the received electronic invoices for clothing may be divided into group 3, and so on.
It should be noted that the service types may include other types besides the service types such as dining, lodging or clothes, for example, office supplies, automobile accessories, transportation, services, and the like. Further, for any electronic invoice, the type of business involved in the electronic invoice can be determined through the transaction information on the electronic invoice. The transaction information may include a transaction object, transaction details, transaction time, transaction number, and regional information of the invoicing party, as long as the corresponding service type can be determined accordingly. For example, assuming that there are 3 electronic invoices, and the transaction information on the invoice is 200 yuan for eating, 30 yuan for driving and 5000 yuan for a hotel, respectively, it can be determined that the service types of the 3 electronic invoices can be catering, transportation and office supplies, respectively, and the embodiment of the present invention is not limited thereto.
That is to say, in the embodiment of the present invention, before determining the current offline storage block of the offline storage block chain, the received electronic invoice may be further divided into at least one group of electronic invoices according to the attribute information of the electronic invoice, so as to correspond to each offline storage block chain of the current node (invoicing party or invoiced party), and then, the current offline storage block in each offline storage block chain may be determined, so that the use experience of the user can be improved, and the practicability can be improved.
Optionally, as shown in fig. 2, it is a schematic structural diagram of a first offline storage block in the embodiment of the present invention. Specifically, as shown in fig. 2, the first offline storage block may include a block hash value, a pointer pointing to a previous offline storage block in the offline storage block chain, an invoice number of the group of electronic invoices, and an image file of the group of electronic invoices.
The image files of the set of electronic invoices can be PDF files, photos and the like of the electronic invoices generally, and are not described herein any more as long as the images are not easy to be modified.
Alternatively, in the embodiment of the present invention, the offline storage block may be generally established by:
establishing a pointer pointing to a previous offline storage block of the offline storage block in the offline storage block chain;
hashing the invoice number of the group of electronic invoices, the pointer and the image file of the group of electronic invoices to obtain a block hash value;
signing the block hash value based on a preset digital certificate;
and creating the offline storage block according to the pointer, the invoice number of the group of electronic invoices, the image file of the group of electronic invoices and the signed block hash value.
The digital certificate can be an authentication certificate which is generally distributed by a tax bureau node for each subordinate enterprise node and can uniquely identify each enterprise node; in general, the digital certificate is in one-to-one correspondence with the unified social organization code of the corresponding enterprise node, and after the digital certificate is damaged or lost, a new digital certificate can be received according to the unified social organization code, and a corresponding relationship can be established between the new digital certificate and the unified social organization code; the digital certificate may be a hardware certificate, such as a U shield or a cipher, or a software certificate, such as a security plug-in, as long as the digital certificate can uniquely identify a corresponding enterprise node and ensure the security of information, which is not limited in this embodiment of the present invention.
Further, for a first offline storage block in any offline storage block chain, a previous offline storage block of the offline storage blocks may be:
if the off-line storage block chain has a starting block, the previous off-line storage block can be the starting block;
if there is no starting block in the offline storage block chain, the previous offline storage block may be the last offline storage block of the offline storage block chain corresponding to the electronic invoice in the offline storage block in the previous time period, the last offline storage block of the offline storage block chain, or the last offline storage block of the offline storage block chain itself, or empty. When the data is empty, the pointer pointing to the previous block in the offline storage block may be an empty pointer, which is not described herein.
Similarly, in the embodiment of the present invention, the offline storage block may also be established by:
establishing a pointer pointing to a previous offline storage block of the offline storage block in the offline storage block chain;
signing each electronic invoice based on a preset digital certificate to obtain at least one signed electronic invoice;
hashing the at least one signature electronic invoice, the pointer, the invoice number of the group of electronic invoices and the image file of the group of electronic invoices to obtain a block hash value;
and creating the offline storage block according to the pointer, the invoice number of the group of electronic invoices, the image file of the group of electronic invoices and the block hash value.
As can be seen from the above, in the embodiment of the present invention, the establishment manner of the offline storage block may be divided into two ways according to the difference of the signature manner, the first way may be to sign the hashed value after hashing, the second way may be to sign the entire ticket surface of each electronic invoice, and then hash the signed value, the two ways may be selected according to the actual situation, as long as the security and non-repudiation of the information in the offline storage block can be ensured, which is not described herein again.
Optionally, as shown in fig. 3, it is a schematic structural diagram of a second offline storage block in the embodiment of the present invention. Specifically, as can be seen from fig. 3, the second offline storage block may further include a time identifier for creating the offline storage block.
It should be noted that the time identifier, that is, the timestamp, generally refers to the time for creating the offline storage block, and the time may be time information such as year, month, date, time, minute, or second, for example, 18 minutes 36 seconds at 24/13/08/2017/13/23/08/01 (23 minutes at 13/1/13/8), and the details of this embodiment of the present invention are not repeated.
In general, when the offline storage block includes a time identifier, the offline storage blocks in the offline storage block chain may be linked in sequence according to creation time; when the offline storage blocks do not include the time identifiers, the offline storage blocks in the offline storage block chain can be linked in sequence according to the invoice numbers of the electronic invoices in the offline storage blocks. Of course, each offline storage block in the offline storage block chain may also be linked according to other sequences, such as an operator number, which is not described in detail in this embodiment of the present invention.
Further, the offline storage method of the electronic invoice can further comprise the following steps:
and displaying the invoice number of the electronic invoice in the offline storage area blockchain.
In general, in the embodiment of the present invention, the invoice number of the electronic invoice in the offline storage area block chain may be displayed through a corresponding electronic display screen, for example, all numbers of the electronic invoice in the offline storage area block chain, or a tail number, or a start number and a stop number of the invoice number, or only a stop number may be displayed, which is not described in detail in the embodiment of the present invention.
Further, the offline storage method of the electronic invoice can further comprise the following steps:
when a query instruction is received, determining an invoice number corresponding to the query instruction;
and displaying the electronic invoice corresponding to the invoice number and/or the offline storage block where the electronic invoice is located.
It should be noted that the query instruction can be sent by pressing a corresponding key, touching a corresponding area, sending corresponding information, and the like; if the query instruction is that a corresponding key is pressed, the invoice number corresponding to the query instruction can be determined by selecting the corresponding invoice number; if the query instruction touches the corresponding area, the invoice number corresponding to the query instruction can be determined by selecting the corresponding invoice number; if the query instruction is that corresponding information is received, the invoice number corresponding to the query instruction can be carried in the information, that is, can be determined by the information, and details are not repeated.
The embodiment of the invention provides an off-line storage method of electronic invoices, which can create an off-line storage block when at least one electronic invoice is received; determining a current offline storage block of the offline storage block chain; the current offline storage block refers to the last offline storage block of the offline storage block chain at the current moment; and linking the offline storage block to the current offline storage block, and using the offline storage block as a new current offline storage block. Compared with the prior art, in the embodiment of the invention, the offline storage of the electronic invoice can be realized by a block chain technology without occupying a local disk of a computer in an enterprise, requiring the enterprise and the like to have a corresponding electronic invoice service platform, and further needing no electronic invoice service platform purchased from a third party, so that the realization cost is reduced; moreover, the block chain technology has the characteristics of incapability of modification and incapability of deletion, so that the safety of the stored electronic invoices can be ensured.
Example two:
based on the same inventive concept as the first embodiment of the present invention, the second embodiment of the present invention provides an offline storage device for electronic invoices, as shown in fig. 4, which is a schematic structural diagram of the offline storage device for electronic invoices in the first embodiment of the present invention. Specifically, as can be seen from fig. 4, the offline storage device for the electronic invoice may include:
the dividing module 41 is configured to, when receiving an electronic invoice storage instruction, divide the received electronic invoices into at least one group;
a determining module 42, configured to determine, for any group of electronic invoices, a current offline storage block of the offline storage block chain corresponding to the group of electronic invoices; the current offline storage block refers to the last offline storage block of the offline storage block chain at the current moment;
a creating module 43, configured to create an offline storage block according to the set of electronic invoices and the current offline storage block; the offline storage block is a set for recording invoice information of the group of electronic invoices and the link relation of the offline storage block;
a linking module 44, configured to link the offline storage block to the current offline storage block, and use the offline storage block as a new current offline storage block.
That is to say, in the embodiment of the present invention, the offline storage device for electronic invoices may include a dividing module configured to divide the received electronic invoices into at least one group when receiving an electronic invoice storage instruction, a determining module configured to determine, for any group of electronic invoices, a current offline storage block of an offline storage block chain corresponding to the group of electronic invoices, a creating module configured to create an offline storage block according to the group of electronic invoices and the current offline storage block, and a linking module configured to link the offline storage block to the current offline storage block and use the offline storage block as a new current offline storage block. Compared with the prior art, in the embodiment of the invention, the offline storage of the electronic invoice can be realized by a block chain technology without occupying a local disk of a computer in an enterprise, requiring the enterprise and the like to have a corresponding electronic invoice service platform, and further needing no electronic invoice service platform purchased from a third party, so that the realization cost is reduced; moreover, the block chain technology has the characteristics of incapability of modification and incapability of deletion, so that the safety of the stored electronic invoices can be ensured.
Specifically, the dividing module 41 may be specifically configured to divide the electronic invoices issued into at least one group according to the receiving time; or, dividing the issued electronic invoices into at least one group according to the receiving objects; or, the issued electronic invoices are divided into at least one group according to the service type.
Optionally, the offline storage block may include a block hash value, a pointer pointing to a previous offline storage block of the offline storage block in the offline storage block chain, an invoice number of the group of electronic invoices, and an image file of the group of electronic invoices.
Further, the offline storage block may also include a time identification of when the offline storage block was created.
Further, the offline storage device of the electronic invoice may further include:
and the display module 45 may be configured to display the invoice number of the electronic invoice in the offline storage block chain.
Further, the display module 45 may be further configured to determine, when receiving the query instruction, an invoice number corresponding to the query instruction; and displaying the electronic invoice corresponding to the invoice number and/or the offline storage block where the electronic invoice is located.
The second embodiment of the invention provides an offline storage device for electronic invoices, which can comprise a dividing module used for dividing the received electronic invoices into at least one group when an electronic invoice storage instruction is received, a determining module used for determining a current offline storage block of an offline storage block chain corresponding to any group of electronic invoices aiming at any group of electronic invoices, a creating module used for creating an offline storage block according to the group of electronic invoices and the current offline storage block, and a linking module used for linking the offline storage block to the current offline storage block and taking the offline storage block as a new current offline storage block. Compared with the prior art, in the embodiment of the invention, the offline storage of the electronic invoice can be realized by a block chain technology without occupying a local disk of a computer in an enterprise, requiring the enterprise and the like to have a corresponding electronic invoice service platform, and further needing no electronic invoice service platform purchased from a third party, so that the realization cost is reduced; moreover, the block chain technology has the characteristics of incapability of modification and incapability of deletion, so that the safety of the stored electronic invoices can be ensured.
Example three:
a third embodiment of the present invention provides a computing device, as shown in fig. 5, which is a schematic structural diagram of the computing device in the third embodiment of the present invention. The computing device may be specifically a desktop computer, a portable computer, a smart phone, a tablet computer, a Personal Digital Assistant (PDA), and the like. Specifically, the computing device described in the embodiment of the present invention may include a Central Processing Unit (CPU) 501, a memory 502, an input device 503, an output device 504, and the like, where the input device 503 may include a keyboard, a mouse, a touch screen, and the like, and the output device 504 may include a Display device, such as a Liquid Crystal Display (LCD), a Cathode Ray Tube (CRT), and the like.
The memory 502 may include a Read Only Memory (ROM) and a Random Access Memory (RAM), and provides the central processor 501 with program instructions and data stored in the memory 502. In an embodiment of the present invention, the memory 502 may be used to store a program of an offline storage method of an electronic invoice.
The central processing unit 501, by calling the program instructions stored in the memory 502, can be used to execute the following steps according to the obtained program instructions: when an electronic invoice storage instruction is received, dividing the received electronic invoices into at least one group; aiming at any group of electronic invoices, determining a current offline storage block of an offline storage block chain corresponding to the group of electronic invoices; the current offline storage block refers to the last offline storage block of the offline storage block chain at the current moment; creating an offline storage block according to the group of electronic invoices and the current offline storage block; the offline storage block is a set for recording invoice information of the group of electronic invoices and the link relation of the offline storage block; and linking the offline storage block to the current offline storage block, and taking the offline storage block as a new current offline storage block.
Example four:
a fourth embodiment of the present invention provides a computer storage medium, configured to store computer program instructions for the computing device, where the computer program instructions include a program for executing the offline storage method for electronic invoices.
The computer storage media may be any available media or data storage device that can be accessed by a computer, including, but not limited to, magnetic memory (e.g., floppy disks, hard disks, magnetic tape, magneto-optical disks (MOs), etc.), optical memory (e.g., CDs, DVDs, BDs, HVDs, etc.), and semiconductor memory (e.g., ROMs, EPROMs, EEPROMs, non-volatile memory (NAND FLASH), Solid State Disks (SSDs)), etc.
As will be appreciated by one skilled in the art, embodiments of the present invention may be provided as a method, apparatus (device), or computer program product. Accordingly, the present invention may take the form of an entirely hardware embodiment, an entirely software embodiment or an embodiment combining software and hardware aspects. Furthermore, the present invention may take the form of a computer program product embodied on one or more computer-usable storage media (including, but not limited to, disk storage, CD-ROM, optical storage, and the like) having computer-usable program code embodied therein.
The present invention has been described with reference to flowchart illustrations and/or block diagrams of methods, apparatus (devices) and computer program products according to embodiments of the invention. It will be understood that each flow and/or block of the flow diagrams and/or block diagrams, and combinations of flows and/or blocks in the flow diagrams and/or block diagrams, can be implemented by computer program instructions. These computer program instructions may be provided to a processor of a general purpose computer, special purpose computer, embedded processor, or other programmable data processing apparatus to produce a machine, such that the instructions, which execute via the processor of the computer or other programmable data processing apparatus, create means for implementing the functions specified in the flowchart flow or flows and/or block diagram block or blocks.
These computer program instructions may also be stored in a computer-readable memory that can direct a computer or other programmable data processing apparatus to function in a particular manner, such that the instructions stored in the computer-readable memory produce an article of manufacture including instruction means which implement the function specified in the flowchart flow or flows and/or block diagram block or blocks.
These computer program instructions may also be loaded onto a computer or other programmable data processing apparatus to cause a series of operational steps to be performed on the computer or other programmable apparatus to produce a computer implemented process such that the instructions which execute on the computer or other programmable apparatus provide steps for implementing the functions specified in the flowchart flow or flows and/or block diagram block or blocks.
While preferred embodiments of the present invention have been described, additional variations and modifications in those embodiments may occur to those skilled in the art once they learn of the basic inventive concepts. Therefore, it is intended that the appended claims be interpreted as including preferred embodiments and all such alterations and modifications as fall within the scope of the invention.
It will be apparent to those skilled in the art that various changes and modifications may be made in the present invention without departing from the spirit and scope of the invention. Thus, if such modifications and variations of the present invention fall within the scope of the claims of the present invention and their equivalents, the present invention is also intended to include such modifications and variations.

Claims (14)

1. An off-line storage method of electronic invoices, which is characterized by comprising the following steps:
when an electronic invoice storage instruction is received, dividing the received electronic invoices into at least one group;
aiming at any group of electronic invoices, determining a current offline storage block of an offline storage block chain corresponding to the group of electronic invoices; the current offline storage block refers to the last offline storage block of the offline storage block chain at the current moment;
creating an offline storage block according to the group of electronic invoices and the current offline storage block; the offline storage block is a set for recording invoice information of the group of electronic invoices and the link relation of the offline storage block;
and linking the offline storage block to the current offline storage block, and taking the offline storage block as a new current offline storage block.
2. The offline storage method of electronic invoices according to claim 1, wherein the dividing of the received electronic invoices into at least one group comprises:
dividing the issued electronic invoices into at least one group according to the receiving time; or,
dividing the issued electronic invoices into at least one group according to the receiving objects; or,
and dividing the issued electronic invoices into at least one group according to the service type.
3. The offline storage method for electronic invoices according to claim 1 or 2, wherein the offline storage block comprises a block hash value, a pointer pointing to a previous offline storage block of the offline storage block in the offline storage block chain, an invoice number of the set of electronic invoices and an image file of the set of electronic invoices.
4. The method of offline storage of electronic invoices according to claim 3 wherein the offline storage block further comprising creating a time stamp for the offline storage block.
5. The method for offline storage of electronic invoices according to claim 1, further comprising:
and displaying the invoice number of the electronic invoice in the offline storage area blockchain.
6. The method for offline storage of electronic invoices according to claim 1, further comprising:
when a query instruction is received, determining an invoice number corresponding to the query instruction;
and displaying the electronic invoice corresponding to the invoice number and/or the offline storage block where the electronic invoice is located.
7. An off-line storage device for electronic invoices, comprising:
the system comprises a dividing module, a storage module and a processing module, wherein the dividing module is used for dividing the received electronic invoices into at least one group when receiving an electronic invoice storage instruction;
the determining module is used for determining the current offline storage block of the offline storage block chain corresponding to any group of electronic invoices; the current offline storage block refers to the last offline storage block of the offline storage block chain at the current moment;
the creating module is used for creating an offline storage block according to the group of electronic invoices and the current offline storage block; the offline storage block is a set for recording invoice information of the group of electronic invoices and the link relation of the offline storage block;
and the linking module is used for linking the offline storage block to the current offline storage block and taking the offline storage block as a new current offline storage block.
8. The off-line storage of electronic invoices according to claim 7 wherein,
the dividing module is specifically used for dividing the issued electronic invoices into at least one group according to the receiving time; or, dividing the issued electronic invoices into at least one group according to the receiving objects; or, the issued electronic invoices are divided into at least one group according to the service type.
9. The offline storage device for electronic invoices according to claim 7 or 8, wherein the offline storage block comprises a block hash value, a pointer to a previous offline storage block of the offline storage block in the offline storage block chain, an invoice number of the set of electronic invoices and an image file of the set of electronic invoices.
10. The offline storage of electronic invoices according to claim 9 wherein the offline storage block further comprising a time stamp to create the offline storage block.
11. The offline storage of electronic invoices according to claim 7 wherein said offline storage of electronic invoices further comprising:
and the display module is used for displaying the invoice number of the electronic invoice in the offline storage area block chain.
12. The off-line storage of electronic invoices according to claim 1 wherein,
the display module is further used for determining an invoice number corresponding to the query instruction when the query instruction is received; and displaying the electronic invoice corresponding to the invoice number and/or the offline storage block where the electronic invoice is located.
13. A computing device comprising a memory and a processor, wherein:
the memory to store program instructions;
the processor is used for calling the program instructions stored in the memory and executing the offline storage method of the electronic invoice, which is disclosed by any one of claims 1 to 6, according to the obtained program.
14. A computer storage medium storing computer-executable instructions for causing a computer to perform the offline storage method of electronic invoices according to any one of claims 1 to 6.
CN201710875447.7A 2017-09-25 2017-09-25 A kind of offline storage method and device of electronic invoice Pending CN109558063A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201710875447.7A CN109558063A (en) 2017-09-25 2017-09-25 A kind of offline storage method and device of electronic invoice

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201710875447.7A CN109558063A (en) 2017-09-25 2017-09-25 A kind of offline storage method and device of electronic invoice

Publications (1)

Publication Number Publication Date
CN109558063A true CN109558063A (en) 2019-04-02

Family

ID=65862066

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201710875447.7A Pending CN109558063A (en) 2017-09-25 2017-09-25 A kind of offline storage method and device of electronic invoice

Country Status (1)

Country Link
CN (1) CN109558063A (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN111062059A (en) * 2019-11-06 2020-04-24 支付宝(杭州)信息技术有限公司 Method and device for service processing

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN106412037A (en) * 2016-09-19 2017-02-15 中国银联股份有限公司 Security electronic file processing system and method based on block link structure
CN106569749A (en) * 2016-11-09 2017-04-19 百望金赋科技有限公司 Method and system for storing tax-control data
CN106598549A (en) * 2016-12-08 2017-04-26 天津米游科技有限公司 Intelligent agreement system based on block chain and implementation method
US20170134937A1 (en) * 2015-11-06 2017-05-11 SWFL, Inc., d/b/a "Filament" Systems and methods for secure and private communications
CN106952124A (en) * 2017-03-16 2017-07-14 北京牛链科技有限公司 Electronic bill management system and method based on distribution book keeping operation

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20170134937A1 (en) * 2015-11-06 2017-05-11 SWFL, Inc., d/b/a "Filament" Systems and methods for secure and private communications
CN106412037A (en) * 2016-09-19 2017-02-15 中国银联股份有限公司 Security electronic file processing system and method based on block link structure
CN106569749A (en) * 2016-11-09 2017-04-19 百望金赋科技有限公司 Method and system for storing tax-control data
CN106598549A (en) * 2016-12-08 2017-04-26 天津米游科技有限公司 Intelligent agreement system based on block chain and implementation method
CN106952124A (en) * 2017-03-16 2017-07-14 北京牛链科技有限公司 Electronic bill management system and method based on distribution book keeping operation

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
方燕儿等: "区块链技术在商业银行产业链金融中的发展探索", 《新金融》 *

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN111062059A (en) * 2019-11-06 2020-04-24 支付宝(杭州)信息技术有限公司 Method and device for service processing

Similar Documents

Publication Publication Date Title
US11328093B1 (en) Protecting sensitive data
US8719280B1 (en) Person-based information aggregation
CN108805632B (en) Charging method and device
US11087371B2 (en) Blockchain-based invoice creation method apparatus, and electronic device
WO2020220740A1 (en) Blockchain-based invoice creation method, apparatus and electronic device
CN108400868B (en) Seed key storage method and device and mobile terminal
CN107798579B (en) Method for generating protocol file and terminal thereof
CN110738477A (en) reconciliation method, device, computer equipment and storage medium
US9773245B1 (en) Acquiring items using gestures on a touchscreen
CN111563098A (en) Structured and unstructured data query method, device, storage medium and device
EP2905739A1 (en) Electronic bills management system and electronic bills management method
CN113222724B (en) Bill processing method and device
US20230244680A1 (en) Systems and methods for expedited large file processing
CN110599273B (en) Data processing method, data processing device, node equipment and storage medium
CN109559176A (en) A kind of bookkeeping methods and device of electronic invoice
CN109558063A (en) A kind of offline storage method and device of electronic invoice
CN109525485B (en) Message leaving method and terminal equipment
CN108985758B (en) Data processing method, data processing system and terminal equipment
CN116562860A (en) Account separating and settling system, method and device, server and medium
US12001400B2 (en) Method and apparatus for synchronizing file
CN109559115A (en) A kind of method for building up, method of commerce and the relevant apparatus of intelligence contract
US9678748B2 (en) Methods, systems and computer-readable media for managing a local stack
CN110019972A (en) The restoration methods and electronic device of the storage method of electronic invoice, chain of keeping accounts
JP2014531628A (en) Method and system for capturing and authenticating a signature using a mobile device
CN112613932A (en) Billing method and device, storage medium and electronic equipment

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

RJ01 Rejection of invention patent application after publication