CN111127034A - Commodity tracing method and device, client and storage medium - Google Patents

Commodity tracing method and device, client and storage medium Download PDF

Info

Publication number
CN111127034A
CN111127034A CN201911216759.2A CN201911216759A CN111127034A CN 111127034 A CN111127034 A CN 111127034A CN 201911216759 A CN201911216759 A CN 201911216759A CN 111127034 A CN111127034 A CN 111127034A
Authority
CN
China
Prior art keywords
commodity
tracing
information
url
traceability
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
CN201911216759.2A
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 Haiyi Tongzhan Information Technology Co Ltd
Original Assignee
Beijing Haiyi Tongzhan 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 Haiyi Tongzhan Information Technology Co Ltd filed Critical Beijing Haiyi Tongzhan Information Technology Co Ltd
Priority to CN201911216759.2A priority Critical patent/CN111127034A/en
Publication of CN111127034A publication Critical patent/CN111127034A/en
Pending legal-status Critical Current

Links

Images

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/018Certifying business or products
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06KGRAPHICAL DATA READING; PRESENTATION OF DATA; RECORD CARRIERS; HANDLING RECORD CARRIERS
    • G06K17/00Methods or arrangements for effecting co-operative working between equipments covered by two or more of main groups G06K1/00 - G06K15/00, e.g. automatic card files incorporating conveying and reading operations
    • G06K17/0022Methods or arrangements for effecting co-operative working between equipments covered by two or more of main groups G06K1/00 - G06K15/00, e.g. automatic card files incorporating conveying and reading operations arrangements or provisious for transferring data to distant stations, e.g. from a sensing device
    • G06K17/0025Methods or arrangements for effecting co-operative working between equipments covered by two or more of main groups G06K1/00 - G06K15/00, e.g. automatic card files incorporating conveying and reading operations arrangements or provisious for transferring data to distant stations, e.g. from a sensing device the arrangement consisting of a wireless interrogation device in combination with a device for optically marking the record carrier

Abstract

The embodiment of the invention relates to a commodity tracing method, a commodity tracing device, a commodity client and a commodity storage medium, wherein the method comprises the following steps: acquiring a commodity two-dimensional code of a commodity; determining an initial Uniform Resource Locator (URL) corresponding to the commodity two-dimensional code; converting the initial URL into a target URL; obtaining the tracing information of the commodity from tracing nodes of a block chain based on the initial URL; and displaying a tracing interface carrying the tracing information corresponding to the target URL, ensuring that a client can access the tracing interface by converting the form of the URL, synchronizing the tracing information of the commodities stored in the Chinese article coding center into the tracing node of the block chain, ensuring the tracing information to be truly traceable by utilizing the openness and the information non-tamper property of the block chain, displaying the tracing information in the tracing interface, and realizing the effect that two-dimensional codes of commodities with different coding identifications and coding data structures can use a unified client to trace all commodities.

Description

Commodity tracing method and device, client and storage medium
Technical Field
The embodiment of the invention relates to the field of data processing, in particular to a commodity tracing method, a commodity tracing device, a commodity client and a commodity storage medium.
Background
With the popularization of smart phones and the development of mobile communication, scanning two-dimensional codes to access networks becomes a convenient way for people to obtain information. In order to select satisfactory products from the full-line merchandise, consumers need to obtain more complete enterprise information, product information and sales promotion information. Manufacturers also need to promote products and promotions in an on-line, off-line and three-dimensional manner to increase consumer acceptance and sales of products for the enterprise. The bottleneck of communication between the manufacturing enterprise and the consumer is urgent to break through. The advantages of the commodity bar code are more focused on settlement, and the two-dimensional code which bears more information, has error correction technology and can access the internet is obviously the best choice for connecting enterprises and consumers. The calling of the two-dimension code and the related standards of the commodity in the industry is stronger and stronger.
In this context, the two-dimensional code of the commodity made by the chinese article coding center comes from the beginning, and the standard stipulates that the two-dimensional code of the commodity should be made of the two-dimensional code of the national standard or international ISO standard with the GS1 or FNC1 mode.
However, the code identifiers of the two-dimensional codes of the commodities are not uniform, the code data structure is defined by each manufacturer or service provider, and different mobile phone software is needed for reading and analyzing, so that a plurality of two-dimensional codes appear on some products, and a consumer cannot start scanning the codes. Data among the systems cannot be shared, enterprises need to repeatedly input data, and the system is low in efficiency and high in cost.
Disclosure of Invention
In view of this, in order to solve the technical problems or some technical problems, embodiments of the present invention provide a method, an apparatus, a client and a storage medium for tracing a commodity.
In a first aspect, an embodiment of the present invention provides a commodity tracing method, including:
acquiring a commodity two-dimensional code of a commodity;
determining an initial Uniform Resource Locator (URL) corresponding to the commodity two-dimensional code;
converting the initial URL into a target URL;
obtaining the tracing information of the commodity from tracing nodes of a block chain based on the initial URL;
and displaying a source tracing interface carrying the source tracing information corresponding to the target URL.
In one possible embodiment, the obtaining the traceability information of the commodity from the traceability node of the blockchain based on the initial URL includes:
determining the type corresponding to the initial URL;
if the type is the first type, determining a serial number corresponding to the initial URL, and inquiring batch information corresponding to the initial URL based on the serial number;
inquiring whether the commodity is a qualified commodity from a tracing node of a block chain based on the batch information;
or the like, or, alternatively,
if the type is the second type, determining batch information corresponding to the initial URL;
and inquiring whether the commodity is qualified or not from the source tracing node of the block chain based on the batch information.
In a possible embodiment, the obtaining the traceability information of the commodity from the traceability node of the blockchain based on the initial URL further includes:
if the commodity is qualified, obtaining the traceability information of the commodity from a local cache;
if the traceability information is not stored in the local cache, obtaining the traceability information of the commodity from a local database;
and if the traceability information is not stored in the local database, obtaining the traceability information of the commodity from the traceability node of the block chain.
In one possible embodiment, the method further comprises:
and if the commodity is unqualified commodity, displaying a traceability interface which is corresponding to the target URL and carries unqualified commodity information.
In one possible embodiment, the method further comprises:
and if the tracing information is not stored in the local cache, storing the tracing information acquired from the tracing node of the local database or the block chain in the local cache.
In one possible embodiment, the method further comprises:
and if the tracing information is not stored in the local cache, the local cache and the tracing node of the block chain, displaying a prompt message that the tracing information is not inquired on the tracing interface.
In one possible embodiment, the tracing information includes at least one of:
item information, product information, enterprise information, process information, inspection information, or product flow information.
In a second aspect, an embodiment of the present invention provides a commodity tracing device, including:
the acquisition module is used for acquiring a commodity two-dimensional code of a commodity;
the determining module is used for determining an initial Uniform Resource Locator (URL) corresponding to the commodity two-dimensional code;
the conversion module is used for converting the initial URL into a target URL;
the obtaining module is further configured to obtain traceability information of the commodity from traceability nodes of a blockchain based on the initial URL;
and the display module is used for displaying the source tracing interface which carries the source tracing information and corresponds to the target URL.
In a third aspect, an embodiment of the present invention provides a client, including: the article tracing method includes a processor and a memory, wherein the processor is used for executing a tracing program of the article stored in the memory to realize the article tracing method of any one of the first aspect.
In a fourth aspect, an embodiment of the present invention provides a storage medium, where one or more programs are stored, and the one or more programs are executable by one or more processors to implement the article tracing method according to any one of the first aspects.
According to the commodity tracing method provided by the embodiment of the invention, the commodity two-dimensional code of the commodity is obtained through the client; determining an initial Uniform Resource Locator (URL) corresponding to the commodity two-dimensional code; converting the initial URL into a target URL; obtaining the tracing information of the commodity from tracing nodes of a block chain based on the initial URL; and displaying a tracing interface carrying the tracing information corresponding to the target URL, ensuring that a client can access the tracing interface by converting the form of the URL, synchronizing the tracing information of the commodities stored in the Chinese article coding center into the tracing node of the block chain, ensuring the tracing information to be truly traceable by utilizing the openness and the information non-tamper property of the block chain, displaying the tracing information in the tracing interface, and realizing the effect that two-dimensional codes of commodities with different coding identifications and coding data structures can use a unified client to trace all commodities.
Drawings
Fig. 1 is an application scenario diagram of a commodity tracing method according to an embodiment of the present invention;
fig. 2 is a schematic flow chart of a commodity tracing method according to an embodiment of the present invention;
fig. 3 is a schematic flow chart of another commodity tracing method according to an embodiment of the present invention;
FIG. 4 is a schematic diagram of a traceability interface according to an embodiment of the present invention;
fig. 5 is a schematic structural diagram of a commodity tracing device according to an embodiment of the present invention;
fig. 6 is a schematic structural diagram of a client according to an embodiment of the present invention.
Detailed Description
In order to make the objects, technical solutions and advantages of the embodiments of the present invention clearer, the technical solutions in the embodiments of the present invention will be clearly and completely described below with reference to the drawings in the embodiments of the present invention, and it is obvious that the described embodiments are some, but not all, embodiments of the present invention. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present invention.
For the convenience of understanding of the embodiments of the present invention, the following description will be further explained with reference to specific embodiments, which are not to be construed as limiting the embodiments of the present invention.
Fig. 1 is an application scenario diagram of a commodity tracing method according to an embodiment of the present invention, and as shown in fig. 1, the application scenario diagram specifically includes:
when the commodity is on line, the Chinese article coding center configures a commodity two-dimension code for the commodity, the traceability information corresponding to the commodity is stored in the Chinese article coding center node, and meanwhile, the traceability information is synchronized to the traceability nodes in the block chain, so that the storage operation of the traceability information is completed.
When a user acquires tracing information of a commodity, scanning the commodity two-dimensional code on the commodity through a client, converting an initial Uniform Resource Locator (URL) corresponding to the commodity two-dimensional code into a corresponding target URL by the client, wherein a display interface corresponding to the target URL is a tracing interface corresponding to the commodity, and the tracing information displayed in the tracing interface is acquired from a tracing node in a local or block chain of the client.
Fig. 2 is a schematic flow chart of a commodity tracing method according to an embodiment of the present invention, and as shown in fig. 2, the method specifically includes:
and S21, acquiring the commodity two-dimensional code of the commodity.
In this embodiment, the client serves as an execution subject of the commodity tracing method, and the client is associated with the tracing node of the block chain, so that the client can obtain the tracing information of the commodity from the tracing node.
Further, the client has a code scanning function, and the two-dimension code of the commodity is collected through the camera.
And S22, determining an initial Uniform Resource Locator (URL) corresponding to the commodity two-dimensional code.
And calling a tracing interface by the client to identify the obtained commodity two-dimensional code and determining an initial URL corresponding to the commodity two-dimensional code, wherein the initial URL is a URL configured for the commodity two-dimensional code by a Chinese article coding center.
And S23, converting the initial URL into a target URL.
In the existing scheme, the configuration of the URL for the two-dimensional code of the commodity by the coding center of the article in china is usually related to the sales platform corresponding to the commodity, for example, the initial URL corresponding to the two-dimensional code of the commodity of a certain treasure is limited to the case that the code is scanned by the APP of the certain treasure to access the interface corresponding to the initial URL, and other APPs cannot access the interface.
In this embodiment, the initial URL is converted into a target URL, so that the client can access an interface corresponding to the target URL.
And S24, obtaining the tracing information of the commodity from the tracing node of the blockchain based on the initial URL.
According to the commodity identification corresponding to the target URL, the tracing information corresponding to the commodity identification is inquired from the tracing node of the blockchain, and the tracing information of the commodity is obtained, wherein the tracing information can comprise: item information, product information, enterprise information, process information, inspection information, or product flow information.
And S25, displaying the source tracing interface carrying the source tracing information corresponding to the target URL.
And the client displays a tracing interface corresponding to the target URL and displays the tracing information acquired from the tracing node in the tracing interface.
According to the commodity tracing method provided by the embodiment of the invention, the commodity two-dimensional code of the commodity is obtained through the client; determining an initial Uniform Resource Locator (URL) corresponding to the commodity two-dimensional code; converting the initial URL into a target URL; obtaining the tracing information of the commodity from tracing nodes of a block chain based on the initial URL; and displaying a tracing interface carrying the tracing information corresponding to the target URL, ensuring that a client can access the tracing interface by converting the form of the URL, synchronizing the tracing information of the commodities stored in the Chinese article coding center into the tracing node of the block chain, ensuring the tracing information to be truly traceable by utilizing the openness and the information non-tamper property of the block chain, displaying the tracing information in the tracing interface, and realizing the effect that two-dimensional codes of commodities with different coding identifications and coding data structures can use a unified client to trace all commodities.
Fig. 3 is a schematic flow chart of another commodity tracing method according to an embodiment of the present invention, and as shown in fig. 3, the method specifically includes:
and S31, the client acquires the commodity two-dimensional code of the commodity.
And S32, determining an initial Uniform Resource Locator (URL) corresponding to the commodity two-dimensional code.
The client receives a code scanning operation of a user, calls the camera client to obtain a commodity two-dimensional code of the commodity, calls the traceability interface to identify the commodity two-dimensional code, determines whether the commodity two-dimensional code is distributed to the commodity for a Chinese article coding center, and obtains an initial URL corresponding to the commodity two-dimensional code.
In this embodiment, the client may be an application program, for example: certain east APP, certain treasure APP, etc.
And S33, converting the initial URL into a target URL.
And converting the initial URL into a target URL by adopting a regular expression form, wherein an interface corresponding to the target URL is an address which can be accessed by the client.
It should be noted that: in this embodiment, a specific manner of converting the initial URL into the target URL is not specifically limited, for example, the regular expression may be used for conversion, and any manner of conversion may be used for conversion first, so as to ensure that the converted target URL can be accessed by the client.
For example, the initial URL:
https://item.taobao.com/item.htm?spm=a217x.7279301.1997509585.2.714112c1GJyCuz&id=3831629823&scene=2953326180681728;
conversion to a target URL:
https://sy.jd.com/edi/ecr/2953326180681728?uniqueCodePrefix=06900000324554&uniqueCodeSuffix=2953326180681728。
and S34, determining the type corresponding to the initial URL.
In this embodiment, URLs corresponding to the two-dimensional codes of the commodities are divided into two types, where the URLs of the first type carry serial numbers of the commodities, and the URLs of the second type carry batch numbers of the commodities, where the URLs of the first type are divided into two types:
1. http:// webapi. chirality. org/app/? code 01 global trade item code 21 serial number.
Example (c): such as 06900000324554 for the global trade item code, serial number 2953326180681728
http://webapi.chinatrace.org/app/?code=0106900000324554212953326180681728;
2. http:// www.chinatrace.org/qstmp/gtin/global trade item code/ser/serial number
Example (c): such as 06900000324554 for the global trade item code, serial number 2953326180681728
http://www.chinatrace.org/qstmp/gtin/06900000324554/ser/2953326180681728。
The second type of URL is also classified into two types:
1. http:// webapi. chirality. org/app/? code 01 global trade item code 10 lot number.
Example (c): such as global trade item code 06900000004562, lot number 11
http://webapi.chinatrace.org/app/?code=01069000000045621011;
2. http:// www.chinatrace.org/qstmp/gtin/global trade item code/bat/batch number
Example (c): for example, the global trade item code is 06900000004562, lot number 011
http://www.chinatrace.org/qstmp/gtin/06900000004562/bat/11;
S35, if the type is the first type, determining a serial number corresponding to the initial URL, and inquiring batch information corresponding to the initial URL based on the serial number.
If the type of the initial URL is determined to be the first type, namely the initial URL carries a serial number of a commodity, inquiring batch information corresponding to the initial URL from a tracing node of the block chain according to the serial number.
And S36, if the type is the second type, determining the batch information corresponding to the initial URL.
And if the type of the initial URL is determined to be the second type, namely the initial URL carries the batch number of the commodity, directly acquiring batch information corresponding to the initial URL from the initial URL.
S37, inquiring whether the commodity is qualified commodity from the tracing node of the block chain based on the batch information.
If the commodity information returned by the tracing node is displayed as a qualified commodity, executing S38; if the goods information returned by the tracing node shows that the goods information is unqualified goods, S313 is executed.
Wherein, the tracing node may be a BAAS node in the block chain.
And S38, if the commodity is a qualified commodity, obtaining the traceability information of the commodity from a local cache.
And S39, if the traceability information is not stored in the local cache, obtaining the traceability information of the commodity from a local database.
And S310, if the traceability information is not stored in the local database, obtaining the traceability information of the commodity from the traceability node of the block chain.
In this embodiment, if it is determined that the commodity is a qualified commodity, a tracing step of the commodity information is performed, and the tracing information is sequentially queried according to the priority order of the local cache, the local database, and the tracing node.
Further, obtaining the traceability information of the commodity from a local cache, and if the traceability information is not stored in the local cache, obtaining the traceability information of the commodity from a local database; and if the traceability information is not stored in the local database, obtaining the traceability information of the commodity from the traceability node of the block chain.
In an alternative scheme of the embodiment of the invention, if the tracing information is not stored in the local cache, the tracing information acquired from the local database is stored in the local cache, so that the time for the user to acquire the commodity tracing information by scanning the code again is reduced, and the query efficiency is improved.
If the tracing information is not stored in the local database, the tracing information acquired from the tracing node is stored in the local database, format conversion is performed on the tracing information stored in the tracing node (for example, the tracing information acquired from the tracing node is uniformly converted into a JSON format), and the tracing information after format conversion is stored in the local database and the local cache.
In this embodiment, the source tracing information at least includes one of the following: item information, product information, enterprise information, process information, inspection information, or product flow information.
S311, displaying a source tracing interface carrying the source tracing information corresponding to the target URL.
Referring to fig. 4, a schematic diagram of a traceability interface of the present embodiment is shown, as shown in fig. 4, in which traceability information of the product "carbofuran beer" is included.
S312, if the tracing information is not stored in the local cache, the local cache and the tracing node of the block chain, displaying a prompt message that the tracing information is not inquired on the tracing interface.
And S313, if the commodity is unqualified, displaying a traceability interface which corresponds to the target URL and carries unqualified commodity information.
According to the commodity tracing method provided by the embodiment of the invention, the commodity two-dimensional code of the commodity is obtained through the client; determining an initial Uniform Resource Locator (URL) corresponding to the commodity two-dimensional code; converting the initial URL into a target URL; obtaining the tracing information of the commodity from tracing nodes of a block chain based on the initial URL; and displaying a tracing interface carrying the tracing information corresponding to the target URL, ensuring that a client can access the tracing interface by converting the form of the URL, synchronizing the tracing information of the commodities stored in the Chinese article coding center into the tracing node of the block chain, ensuring the tracing information to be truly traceable by utilizing the openness and the information non-tamper property of the block chain, displaying the tracing information in the tracing interface, and realizing the effect that two-dimensional codes of commodities with different coding identifications and coding data structures can use a unified client to trace all commodities.
Fig. 5 is a schematic structural diagram of a product tracing device according to an embodiment of the present invention, and as shown in fig. 5, the structure specifically includes:
the acquisition module 51 is used for acquiring a commodity two-dimensional code of a commodity;
a determining module 52, configured to determine an initial uniform resource locator URL corresponding to the two-dimensional code of the commodity;
a conversion module 53, configured to convert the initial URL into a target URL;
the obtaining module 51 is further configured to obtain traceability information of the commodity from traceability nodes of a blockchain based on the initial URL;
and a display module 54, configured to display a source tracing interface carrying the source tracing information corresponding to the target URL.
In a possible embodiment, the obtaining module 51 is specifically configured to determine a type corresponding to the initial URL; if the type is the first type, determining a serial number corresponding to the initial URL, and inquiring batch information corresponding to the initial URL based on the serial number; inquiring whether the commodity is a qualified commodity from a tracing node of a block chain based on the batch information; or, if the type is a second type, determining the batch information corresponding to the initial URL; and inquiring whether the commodity is qualified or not from the source tracing node of the block chain based on the batch information.
In a possible implementation manner, the obtaining module 51 is specifically configured to obtain the traceability information of the commodity from a local cache if the commodity is a qualified commodity; if the traceability information is not stored in the local cache, obtaining the traceability information of the commodity from a local database; and if the traceability information is not stored in the local database, obtaining the traceability information of the commodity from the traceability node of the block chain.
In a possible implementation manner, the display module 54 is further configured to display a source tracing interface corresponding to the target URL and carrying information of the unqualified commodity if the commodity is an unqualified commodity.
In a possible embodiment, the obtaining module 51 is further configured to store the tracing information obtained from the tracing node of the local database or the blockchain in a local cache if the tracing information is not stored in the local cache.
In a possible embodiment, the displaying module 54 is further configured to display a prompt message that the tracing information is not queried on the tracing interface if the tracing information is not stored in the local cache, and the tracing node of the blockchain.
In one possible embodiment, the tracing information includes at least one of: item information, product information, enterprise information, process information, inspection information, or product flow information.
The product tracing device provided in this embodiment may be a product tracing device as shown in fig. 5, and may perform all the steps of the product tracing method as shown in fig. 2 to 3, so as to achieve the technical effect of the product tracing method shown in fig. 2 to 3, and for brevity, reference is specifically made to the description of fig. 2 to 3, which is not described herein again.
Fig. 6 is a schematic structural diagram of a client according to an embodiment of the present invention, where the client 600 shown in fig. 6 includes: at least one processor 601, memory 602, at least one network interface 604, and other user interfaces 603. The various components in client 600 are coupled together by a bus system 605. It is understood that the bus system 605 is used to enable communications among the components. The bus system 605 includes a power bus, a control bus, and a status signal bus in addition to a data bus. For clarity of illustration, however, the various buses are labeled as bus system 605 in fig. 6.
The user interface 603 may include, among other things, a display, a keyboard, or a pointing device (e.g., a mouse, trackball, touch pad, or touch screen, among others.
It will be appreciated that the memory 602 in embodiments of the invention may be either volatile memory or nonvolatile memory, or may include both volatile and nonvolatile memory. The non-volatile memory may be a Read-only memory (ROM), a programmable Read-only memory (PROM), an erasable programmable Read-only memory (erasabprom, EPROM), an electrically erasable programmable Read-only memory (EEPROM), or a flash memory. The volatile memory may be a Random Access Memory (RAM) which functions as an external cache. By way of example, but not limitation, many forms of RAM are available, such as static random access memory (staticiram, SRAM), dynamic random access memory (dynamic RAM, DRAM), synchronous dynamic random access memory (syncronous DRAM, SDRAM), Double Data Rate Synchronous Dynamic Random Access Memory (DDRSDRAM), Enhanced synchronous SDRAM (ESDRAM), synchronous link SDRAM (SLDRAM), and direct memory bus SDRAM (DRRAM). The memory 602 described herein is intended to comprise, without being limited to, these and any other suitable types of memory.
In some embodiments, memory 602 stores the following elements, executable units or data structures, or a subset thereof, or an expanded set thereof: an operating system 6021 and application programs 6022.
The operating system 6021 includes various system programs, such as a framework layer, a core library layer, a driver layer, and the like, and is used for implementing various basic services and processing hardware-based tasks. The application program 6022 includes various application programs such as a media player (MediaPlayer), a Browser (Browser), and the like, and is used to implement various application services. A program implementing the method of an embodiment of the invention can be included in the application program 6022.
In the embodiment of the present invention, by calling a program or an instruction stored in the memory 602, specifically, a program or an instruction stored in the application program 6022, the processor 601 is configured to execute the method steps provided by the method embodiments, for example, including:
acquiring a commodity two-dimensional code of a commodity; determining an initial Uniform Resource Locator (URL) corresponding to the commodity two-dimensional code; converting the initial URL into a target URL; obtaining the tracing information of the commodity from tracing nodes of a block chain based on the initial URL; and displaying a source tracing interface carrying the source tracing information corresponding to the target URL.
In one possible implementation, determining a type corresponding to the initial URL; if the type is the first type, determining a serial number corresponding to the initial URL, and inquiring batch information corresponding to the initial URL based on the serial number; inquiring whether the commodity is a qualified commodity from a tracing node of a block chain based on the batch information; or, if the type is a second type, determining the batch information corresponding to the initial URL; and inquiring whether the commodity is qualified or not from the source tracing node of the block chain based on the batch information.
In a possible implementation manner, if the commodity is a qualified commodity, obtaining the traceability information of the commodity from a local cache; if the traceability information is not stored in the local cache, obtaining the traceability information of the commodity from a local database; and if the traceability information is not stored in the local database, obtaining the traceability information of the commodity from the traceability node of the block chain.
In a possible implementation manner, if the commodity is an unqualified commodity, a source tracing interface carrying unqualified commodity information corresponding to the target URL is displayed.
In a possible implementation manner, if the tracing information is not stored in the local cache, the tracing information obtained from the tracing node of the local database or the block chain is stored in the local cache.
In a possible implementation manner, if the tracing information is not stored in the local cache, the local cache and the tracing node of the block chain, a prompt message that the tracing information is not queried is displayed on the tracing interface.
In one possible embodiment, the tracing information includes at least one of: item information, product information, enterprise information, process information, inspection information, or product flow information.
The method disclosed by the above-mentioned embodiment of the present invention can be applied to the processor 601, or implemented by the processor 601. The processor 601 may be an integrated circuit chip having signal processing capabilities. In implementation, the steps of the above method may be performed by integrated logic circuits of hardware or instructions in the form of software in the processor 601. The processor 601 may be a general-purpose processor, a Digital Signal Processor (DSP), an Application Specific Integrated Circuit (ASIC), an off-the-shelf programmable gate array (FPGA) or other programmable logic device, discrete gate or transistor logic device, or discrete hardware components. The various methods, steps and logic blocks disclosed in the embodiments of the present invention may be implemented or performed. A general purpose processor may be a microprocessor or the processor may be any conventional processor or the like. The steps of the method disclosed in connection with the embodiments of the present invention may be directly implemented by a hardware decoding processor, or implemented by a combination of hardware and software elements in the decoding processor. The software elements may be located in ram, flash, rom, prom, or eprom, registers, among other storage media that are well known in the art. The storage medium is located in the memory 602, and the processor 601 reads the information in the memory 602 and completes the steps of the method in combination with the hardware thereof.
It is to be understood that the embodiments described herein may be implemented in hardware, software, firmware, middleware, microcode, or any combination thereof. For a hardware implementation, the processing units may be implemented within one or more Application Specific Integrated Circuits (ASICs), Digital Signal Processors (DSPs), Digital Signal Processing Devices (DSPDs), Programmable Logic Devices (PLDs), Field Programmable Gate Arrays (FPGAs), general purpose processors, controllers, micro-controllers, microprocessors, other electronic units configured to perform the functions described herein, or a combination thereof.
For a software implementation, the techniques described herein may be implemented by means of units performing the functions described herein. The software codes may be stored in a memory and executed by a processor. The memory may be implemented within the processor or external to the processor.
The client provided in this embodiment may be the client shown in fig. 6, and may execute all the steps of the commodity tracing method shown in fig. 2 to 3, so as to achieve the technical effect of the commodity tracing method shown in fig. 2 to 3, and for brevity, please refer to the description related to fig. 2 to 3, which is not described herein again.
The embodiment of the invention also provides a storage medium (computer readable storage medium). The storage medium herein stores one or more programs. Among others, the storage medium may include volatile memory, such as random access memory; the memory may also include non-volatile memory, such as read-only memory, flash memory, a hard disk, or a solid state disk; the memory may also comprise a combination of memories of the kind described above.
When one or more programs in the storage medium are executable by one or more processors, the article tracing method performed on the article tracing device side is realized.
The processor is used for executing the tracing program of the commodity stored in the memory so as to realize the following steps of the tracing method of the commodity executed on the tracing device side of the commodity:
acquiring a commodity two-dimensional code of a commodity; determining an initial Uniform Resource Locator (URL) corresponding to the commodity two-dimensional code; converting the initial URL into a target URL; obtaining the tracing information of the commodity from tracing nodes of a block chain based on the initial URL; and displaying a source tracing interface carrying the source tracing information corresponding to the target URL.
In one possible implementation, determining a type corresponding to the initial URL; if the type is the first type, determining a serial number corresponding to the initial URL, and inquiring batch information corresponding to the initial URL based on the serial number; inquiring whether the commodity is a qualified commodity from a tracing node of a block chain based on the batch information; or, if the type is a second type, determining the batch information corresponding to the initial URL; and inquiring whether the commodity is qualified or not from the source tracing node of the block chain based on the batch information.
In a possible implementation manner, if the commodity is a qualified commodity, obtaining the traceability information of the commodity from a local cache; if the traceability information is not stored in the local cache, obtaining the traceability information of the commodity from a local database; and if the traceability information is not stored in the local database, obtaining the traceability information of the commodity from the traceability node of the block chain.
In a possible implementation manner, if the commodity is an unqualified commodity, a source tracing interface carrying unqualified commodity information corresponding to the target URL is displayed.
In a possible implementation manner, if the tracing information is not stored in the local cache, the tracing information obtained from the tracing node of the local database or the block chain is stored in the local cache.
In a possible implementation manner, if the tracing information is not stored in the local cache, the local cache and the tracing node of the block chain, a prompt message that the tracing information is not queried is displayed on the tracing interface.
In one possible embodiment, the tracing information includes at least one of: item information, product information, enterprise information, process information, inspection information, or product flow information.
Those of skill would further appreciate that the various illustrative components and algorithm steps described in connection with the embodiments disclosed herein may be implemented as electronic hardware, computer software, or combinations of both, and that the various illustrative components and steps have been described above generally in terms of their functionality in order to clearly illustrate this interchangeability of hardware and software. Whether such functionality is implemented as hardware or software depends upon the particular application and design constraints imposed on the implementation. Skilled artisans may implement the described functionality in varying ways for each particular application, but such implementation decisions should not be interpreted as causing a departure from the scope of the present invention.
The steps of a method or algorithm described in connection with the embodiments disclosed herein may be embodied in hardware, a software module executed by a processor, or a combination of the two. A software module may reside in Random Access Memory (RAM), memory, Read Only Memory (ROM), electrically programmable ROM, electrically erasable programmable ROM, registers, hard disk, a removable disk, a CD-ROM, or any other form of storage medium known in the art.
The above-mentioned embodiments are intended to illustrate the objects, technical solutions and advantages of the present invention in further detail, and it should be understood that the above-mentioned embodiments are merely exemplary embodiments of the present invention, and are not intended to limit the scope of the present invention, and any modifications, equivalent substitutions, improvements and the like made within the spirit and principle of the present invention should be included in the scope of the present invention.

Claims (10)

1. A method for tracing a commodity, comprising:
acquiring a commodity two-dimensional code of a commodity;
determining an initial Uniform Resource Locator (URL) corresponding to the commodity two-dimensional code;
converting the initial URL into a target URL;
obtaining the tracing information of the commodity from tracing nodes of a block chain based on the initial URL;
and displaying a source tracing interface carrying the source tracing information corresponding to the target URL.
2. The method of claim 1, wherein obtaining the traceability information of the commodity from a traceability node of a blockchain based on the initial URL comprises:
determining the type corresponding to the initial URL;
if the type is the first type, determining a serial number corresponding to the initial URL, and inquiring batch information corresponding to the initial URL based on the serial number;
inquiring whether the commodity is a qualified commodity from a tracing node of a block chain based on the batch information;
or the like, or, alternatively,
if the type is the second type, determining batch information corresponding to the initial URL;
and inquiring whether the commodity is qualified or not from the source tracing node of the block chain based on the batch information.
3. The method of claim 2, wherein obtaining the traceability information of the commodity from a traceability node of a blockchain based on the initial URL further comprises:
if the commodity is qualified, obtaining the traceability information of the commodity from a local cache;
if the traceability information is not stored in the local cache, obtaining the traceability information of the commodity from a local database;
and if the traceability information is not stored in the local database, obtaining the traceability information of the commodity from the traceability node of the block chain.
4. The method of claim 2, further comprising:
and if the commodity is unqualified commodity, displaying a traceability interface which is corresponding to the target URL and carries unqualified commodity information.
5. The method of claim 3, further comprising:
and if the tracing information is not stored in the local cache, storing the tracing information acquired from the tracing node of the local database or the block chain in the local cache.
6. The method of claim 3, further comprising:
and if the tracing information is not stored in the local cache, the local cache and the tracing node of the block chain, displaying a prompt message that the tracing information is not inquired on the tracing interface.
7. The method according to any of claims 1-6, wherein the traceability information comprises at least one of:
item information, product information, enterprise information, process information, inspection information, or product flow information.
8. A traceability device of a commodity, comprising:
the acquisition module is used for acquiring a commodity two-dimensional code of a commodity;
the determining module is used for determining an initial Uniform Resource Locator (URL) corresponding to the commodity two-dimensional code;
the conversion module is used for converting the initial URL into a target URL;
the obtaining module is further configured to obtain traceability information of the commodity from traceability nodes of a blockchain based on the initial URL;
and the display module is used for displaying the source tracing interface which carries the source tracing information and corresponds to the target URL.
9. A client, comprising: a processor and a memory, wherein the processor is used for executing a tracing program of the commodity stored in the memory so as to realize the tracing method of the commodity according to any one of claims 1 to 7.
10. A storage medium storing one or more programs executable by one or more processors to implement a method for tracing a commodity according to any one of claims 1 to 7.
CN201911216759.2A 2019-12-02 2019-12-02 Commodity tracing method and device, client and storage medium Pending CN111127034A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201911216759.2A CN111127034A (en) 2019-12-02 2019-12-02 Commodity tracing method and device, client and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201911216759.2A CN111127034A (en) 2019-12-02 2019-12-02 Commodity tracing method and device, client and storage medium

Publications (1)

Publication Number Publication Date
CN111127034A true CN111127034A (en) 2020-05-08

Family

ID=70496884

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201911216759.2A Pending CN111127034A (en) 2019-12-02 2019-12-02 Commodity tracing method and device, client and storage medium

Country Status (1)

Country Link
CN (1) CN111127034A (en)

Cited By (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN111127140A (en) * 2019-12-10 2020-05-08 北京海益同展信息科技有限公司 Display method, device, client and storage medium
CN112348535A (en) * 2020-11-04 2021-02-09 新华中经信用管理有限公司 Traceability application method and system based on block chain technology
CN112465525A (en) * 2020-12-02 2021-03-09 无锡朝阳供应链科技股份有限公司 Farmer market commodity stocking traceability method, device and system
CN114185937A (en) * 2021-11-03 2022-03-15 王伟强 Big data tracing method and system based on digital finance
WO2022107336A1 (en) * 2020-11-20 2022-05-27 富士通株式会社 Information processing program, information processing method, and information processing device
CN114595795A (en) * 2022-03-08 2022-06-07 芯电智联(北京)科技有限公司 NFC tag source tracing data processing method

Citations (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN107766904A (en) * 2017-10-25 2018-03-06 上海中信信息发展股份有限公司 One kind retrospect scale merges printing traceability code method and device
CN108846081A (en) * 2018-06-08 2018-11-20 四川科库科技有限公司 A kind of commodity tracing information query method and system
CN109299955A (en) * 2018-09-14 2019-02-01 北京京东金融科技控股有限公司 Recording method, device, equipment and the computer readable storage medium of information
CN109377248A (en) * 2018-11-23 2019-02-22 微盟云谷股份有限公司 Method for anti-counterfeit and system
US20190121913A1 (en) * 2017-10-19 2019-04-25 Glu, Inc. System And Method For Grouping And Sharing Social Media Data
CN110288354A (en) * 2019-05-17 2019-09-27 西安立人科技股份有限公司 It is a kind of that realization method and system server, program storage device are traced based on the commodity counterfeit prevention anti-channeling hundred million of block chain and RFID
CN110428328A (en) * 2019-06-18 2019-11-08 广州中科易德科技有限公司 A kind of key right-safeguarding complaint system and method based on block chain technology
CN110458579A (en) * 2018-05-04 2019-11-15 上海安茁信息技术有限公司 A method of anti-fake retrospect is combined with social tool, map LBS

Patent Citations (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20190121913A1 (en) * 2017-10-19 2019-04-25 Glu, Inc. System And Method For Grouping And Sharing Social Media Data
CN107766904A (en) * 2017-10-25 2018-03-06 上海中信信息发展股份有限公司 One kind retrospect scale merges printing traceability code method and device
CN110458579A (en) * 2018-05-04 2019-11-15 上海安茁信息技术有限公司 A method of anti-fake retrospect is combined with social tool, map LBS
CN108846081A (en) * 2018-06-08 2018-11-20 四川科库科技有限公司 A kind of commodity tracing information query method and system
CN109299955A (en) * 2018-09-14 2019-02-01 北京京东金融科技控股有限公司 Recording method, device, equipment and the computer readable storage medium of information
CN109377248A (en) * 2018-11-23 2019-02-22 微盟云谷股份有限公司 Method for anti-counterfeit and system
CN110288354A (en) * 2019-05-17 2019-09-27 西安立人科技股份有限公司 It is a kind of that realization method and system server, program storage device are traced based on the commodity counterfeit prevention anti-channeling hundred million of block chain and RFID
CN110428328A (en) * 2019-06-18 2019-11-08 广州中科易德科技有限公司 A kind of key right-safeguarding complaint system and method based on block chain technology

Cited By (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN111127140A (en) * 2019-12-10 2020-05-08 北京海益同展信息科技有限公司 Display method, device, client and storage medium
CN112348535A (en) * 2020-11-04 2021-02-09 新华中经信用管理有限公司 Traceability application method and system based on block chain technology
CN112348535B (en) * 2020-11-04 2023-09-12 新华中经信用管理有限公司 Traceability application method and system based on blockchain technology
WO2022107336A1 (en) * 2020-11-20 2022-05-27 富士通株式会社 Information processing program, information processing method, and information processing device
CN112465525A (en) * 2020-12-02 2021-03-09 无锡朝阳供应链科技股份有限公司 Farmer market commodity stocking traceability method, device and system
CN114185937A (en) * 2021-11-03 2022-03-15 王伟强 Big data tracing method and system based on digital finance
CN114595795A (en) * 2022-03-08 2022-06-07 芯电智联(北京)科技有限公司 NFC tag source tracing data processing method
CN114595795B (en) * 2022-03-08 2022-09-09 芯电智联(北京)科技有限公司 NFC tag source tracing data processing method

Similar Documents

Publication Publication Date Title
CN111127034A (en) Commodity tracing method and device, client and storage medium
KR101645098B1 (en) Method and apparatus for providing search result
US20200296204A1 (en) Method and Apparatus for Processing Contact Information Using a Wireless Terminal
US9282424B2 (en) Method and system for logic-based uniform resource locator resolution
US20170163753A1 (en) Method and apparatus for controlling play device to play video
TW201913449A (en) Target image code recognition method and device
US20140358712A1 (en) Shopping guide system, shopping guide management device and method
CN105335132B (en) Method, device and system for customizing application program function
CN106547769B (en) DOI display method and device
CN110320378B (en) Method, apparatus, device and computer readable storage medium for applying for a quality control test
CN111506318A (en) Circuit board chip burning method, device, terminal and computer readable storage medium
WO2023284505A1 (en) Method and apparatus for code-scanning payment
CN111160895A (en) Service processing method and device based on graphic code, electronic equipment and storage medium
CN111222592A (en) Method and device for acquiring two-dimensional code of equipment
CN110704099B (en) Alliance chain construction method and device and electronic equipment
US20160094276A1 (en) Transmitting and Receiving Packets
CN109558186B (en) Page display method and device
US20200257664A1 (en) Node layout determining method and apparatus, computing device, and computer readable medium
EP3242223A1 (en) Information presentation method and apparatus
CN111127140A (en) Display method, device, client and storage medium
GB2496415A (en) An image data decoding method for decoding contact information and communication event related to a second user and implementing the communication event
CN113034248B (en) Commodity display system, method and device based on small program
CN111695936A (en) Information binding method, device and equipment
CN111652335A (en) Quality chain tracing method, equipment and medium based on NFC
CN110020906B (en) Order information detection method and device

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
CB02 Change of applicant information

Address after: 601, 6 / F, building 2, No. 18, Kechuang 11th Street, Daxing District, Beijing, 100176

Applicant after: Jingdong Technology Information Technology Co.,Ltd.

Address before: 601, 6 / F, building 2, No. 18, Kechuang 11th Street, Daxing District, Beijing, 100176

Applicant before: Jingdong Shuke Haiyi Information Technology Co.,Ltd.

Address after: 601, 6 / F, building 2, No. 18, Kechuang 11th Street, Daxing District, Beijing, 100176

Applicant after: Jingdong Shuke Haiyi Information Technology Co.,Ltd.

Address before: 601, 6 / F, building 2, No. 18, Kechuang 11th Street, Beijing Economic and Technological Development Zone, Beijing 100176

Applicant before: BEIJING HAIYI TONGZHAN INFORMATION TECHNOLOGY Co.,Ltd.

CB02 Change of applicant information
RJ01 Rejection of invention patent application after publication

Application publication date: 20200508

RJ01 Rejection of invention patent application after publication