Disclosure of Invention
The embodiment of the disclosure provides at least one order processing scheme, which can effectively prevent the problem of order failure caused by the loss of order numbers and improve the user experience.
In a first aspect, an embodiment of the present disclosure provides an order processing method, which is applied to a client, where the order processing method includes:
responding to a trigger operation of a user for a target virtual object, sending a target virtual object acquisition request to a supply server, and receiving target order information which is returned by the supply server and is established for the target virtual object, wherein the target order information comprises a target virtual object ID;
initiating a payment request for the target virtual object to a payment server based on the target virtual object ID;
after receiving a payment certificate returned by the payment server, updating the payment state in target order information associated with the target virtual object ID based on the target virtual object ID contained in the payment certificate;
and sending the target order information with the updated payment state to the supply server so as to acquire a target virtual object authorized by the supply server based on the target order information with the updated payment state.
In a possible implementation manner, after receiving target order information created for the target virtual object returned by the provisioning server, the order processing method further includes: storing the target order information in a local secure memory;
after receiving the payment credential returned by the payment server, before updating the payment status in the target order information associated with the target virtual object ID based on the target virtual object ID contained in the payment credential, the method further includes:
target order information associated with the target virtual object ID is extracted from the local secure storage.
In a possible implementation manner, the target order information includes creation time information, and the target order information is stored in the following manner:
after logging in the local secure memory based on a pre-stored memory login password, searching an order information list in the local secure memory;
and storing the target order information to the order information list based on the creation time information contained in the target order information and the creation time information corresponding to each piece of historical order information in the order information list.
In a possible implementation manner, after obtaining the target virtual object authorized by the provisioning server based on the target order information updated by the payment status, the order processing method further includes:
after logging in the local secure memory based on a pre-stored memory login password, searching the order information list in the local secure memory;
and deleting the target order information in the order information list.
In one possible embodiment, the local secure memory includes a key string.
In a possible implementation, the order processing method further includes:
and if the authorized target virtual object is not received after the preset time length is exceeded, sending information for indicating order fault.
In a second aspect, an embodiment of the present disclosure provides an order processing apparatus applied to a client, where the order processing method includes:
the order acquisition module is used for responding to the trigger operation of a user for a target virtual object, sending a target virtual object acquisition request to a supply server, and receiving target order information which is returned by the supply server and is established for the target virtual object, wherein the target order information comprises a target virtual object ID;
the order payment module is used for initiating a payment request aiming at the target virtual object to a payment server based on the ID of the target virtual object;
the order marking module is used for updating the payment state in the target order information associated with the target virtual object ID based on the target virtual object ID contained in the payment voucher after receiving the payment voucher returned by the payment server;
and the order confirmation module is used for sending the target order information with the updated payment state to the supply server so as to acquire a target virtual object authorized by the supply server based on the target order information with the updated payment state.
In a possible implementation manner, after receiving target order information created for the target virtual object returned by the provisioning server, the order obtaining module is further configured to: storing the target order information in a local secure memory;
after receiving the payment credential returned by the payment server, before updating the payment status in the target order information associated with the target virtual object ID based on the target virtual object ID included in the payment credential, the order marking module is further configured to:
target order information associated with the target virtual object ID is extracted from the local secure storage.
In a possible implementation manner, the target order information includes creation time information, and the order obtaining module stores the target order information specifically according to the following manner:
after logging in the local secure memory based on a pre-stored memory login password, searching an order information list in the local secure memory;
and storing the target order information to the order information list based on the creation time information contained in the target order information and the creation time information corresponding to each piece of historical order information in the order information list.
In a possible implementation manner, after obtaining the target virtual object authorized by the provisioning server based on the target order information updated by the payment status, the order confirmation module is further configured to:
after logging in the local secure memory based on a pre-stored memory login password, searching the order information list in the local secure memory;
and deleting the target order information in the order information list.
In one possible embodiment, the local secure memory includes a key string.
In one possible embodiment, the order confirmation module is further configured to:
and if the authorized target virtual object is not received after the preset time length is exceeded, sending information for indicating order fault.
In a third aspect, an embodiment of the present disclosure provides an electronic device, including: a processor, a memory and a bus, the memory storing machine-readable instructions executable by the processor, the processor and the memory communicating via the bus when the electronic device is running, the machine-readable instructions when executed by the processor performing the steps of the order processing method according to the first aspect.
In a fourth aspect, the disclosed embodiments provide a computer-readable storage medium having stored thereon a computer program, which, when executed by a processor, performs the steps of the order processing method according to the first aspect.
According to the order processing method provided by the embodiment of the disclosure, after the target order information which is returned by the supply server and created for the target virtual object is received, the target virtual object ID contained in the target order information is sent to the payment server to request payment, and after the payment certificate is received, the target order information which is associated with the target virtual object ID is changed into the payment state.
In order to make the aforementioned objects, features and advantages of the present disclosure more comprehensible, preferred embodiments accompanied with figures are described in detail below.
Detailed Description
In order to make the objects, technical solutions and advantages of the embodiments of the present disclosure more clear, the technical solutions of the embodiments of the present disclosure will be described clearly and completely with reference to the drawings in the embodiments of the present disclosure, and it is obvious that the described embodiments are only a part of the embodiments of the present disclosure, not all of the embodiments. The components of the embodiments of the present disclosure, generally described and illustrated in the figures herein, can be arranged and designed in a wide variety of different configurations. Thus, the following detailed description of the embodiments of the present disclosure, presented in the figures, is not intended to limit the scope of the claimed disclosure, but is merely representative of selected embodiments of the disclosure. All other embodiments, which can be derived by a person skilled in the art from the embodiments of the disclosure without making creative efforts, shall fall within the protection scope of the disclosure.
It should be noted that: like reference numbers and letters refer to like items in the following figures, and thus, once an item is defined in one figure, it need not be further defined and explained in subsequent figures.
For some mobile terminals using the iOS operating system, such as an apple cell phone, when a virtual product is purchased on the apple cell phone, a built-in purchase application program in the apple cell phone needs to be logged in, such as an application program store for purchase, after a target virtual product to be purchased is selected, an acquisition request of the target virtual product can be sent to a product supply server, so that after target order information returned by the supply server is received, a payment request can be sent to a payment server based on the target order information, when the payment request is sent, an order number related to the target virtual product contained in the target order information is written in an application username field, and for the apple cell phone, the application username field is not used for reserving the order number, so that the order number may be lost during the sending process or when the payment server fails, thus, even if the payment voucher is received and then sent to the supply server, the supply server cannot find the order number and cannot supply the target virtual product to be purchased by the client, namely, the problem of order failure caused by the loss of the order number occurs.
Based on the above research, the present disclosure provides an order processing method, where after receiving target order information created for a target virtual object returned by a provisioning server, a target virtual object ID included in the target order information is sent to a payment server to request payment, and after receiving a payment credential, the target order information associated with the target virtual object ID is changed into a payment state.
To facilitate understanding of the present embodiment, first, an order processing method disclosed in the embodiments of the present disclosure is described in detail, and an execution subject of the order processing method provided in the embodiments of the present disclosure is generally a client. In some possible implementations, the order processing method may be implemented by a processor calling computer readable instructions stored in a memory.
Referring to fig. 1, a flowchart of an order processing method provided in the embodiment of the present disclosure is a flowchart, where the order processing method is applied to a client, and specifically includes the following steps S101 to S104:
s101, responding to the trigger operation of the user for the target virtual object, sending a target virtual object acquisition request to the supply server, and receiving target order information which is returned by the supply server and is created for the target virtual object, wherein the target order information comprises a target virtual object ID.
A Client (Client), or called a user side, refers to a program corresponding to a server and providing local services for the Client, and is generally installed on a common Client and needs to cooperate with the server to operate, for example, some application apps.
The virtual object here includes a virtual product, such as video playing software, computer software, a network game, and the like, when a user needs to purchase a virtual product, the client may be opened, a target virtual product to be purchased is selected in the client to trigger a purchase request, and at this time, the client may send a target virtual object acquisition request to a provisioning server corresponding to the client, where the target virtual object acquisition request may include a target virtual object ID corresponding to the target virtual object, user information logged in the client, and the like.
The provisioning server, upon receiving the target virtual object acquisition request, may generate target order information regarding the current purchase of the target virtual object based on the target virtual object ID included in the target virtual object acquisition request and user information requesting the purchase of the target virtual object, and transmit the target order information to the client.
And S102, initiating a payment request aiming at the target virtual object to a payment server based on the ID of the target virtual object.
And after receiving the target order information returned by the supply server, the client initiates a payment request to a payment server for payment, wherein the target virtual object ID contained in the payment request is used for requesting the payment server for purchasing the target virtual object.
S103, after receiving the payment certificate returned by the payment server, updating the payment state in the target order information associated with the target virtual object ID based on the target virtual object ID contained in the payment certificate.
The payment server receives a payment request sent by the client, and after completing payment of the target virtual object, can return a payment certificate to the client, wherein the payment certificate can contain a payment success identifier of the target virtual object corresponding to the target virtual object ID.
After receiving the payment certificate returned by the payment server, the client finds the target order information associated with the target virtual object ID based on the target virtual object ID contained in the payment certificate, and updates the payment state in the target order information, for example, changes the payment state from unpaid or to-be-paid to paid.
And S104, sending the target order information with the updated payment state to a supply server to obtain a target virtual object authorized by the supply server based on the target order information with the updated payment state.
The client updates the payment state in the target order information, and then sends the target order information with the updated payment state to the providing server to request the providing server to deliver the goods, and for the target virtual object, the request for delivering the goods can be understood as requesting the providing server to authorize a client user to use the target virtual object, for example, for the target virtual object, a certain network game is used, and after the purchase is successful, the user can use the network game at a mobile phone terminal.
In summary, the processes of steps S101 to S104 above may be represented by a flowchart as shown in fig. 2, where the client sends a target virtual object acquisition request to the provisioning server, receives the target order information returned by the provisioning server, then sends a payment request including a target virtual object ID to the payment server, receives a payment credential returned by the payment server, updates the payment status in the target order information, then sends the target order information with the updated payment status to the provisioning server, and requests the provisioning server to authorize the target virtual object purchased by the client.
The order processing method provided for the above S101 to S104 is that after receiving the target order information created for the target virtual object returned by the provisioning server, the target virtual object ID included in the target order information is sent to the payment server to request payment, and after receiving the payment credential, the target order information associated with the target virtual object ID is changed into a payment state.
The above steps S101 to S104 will be specifically described with reference to specific embodiments.
For the above S101, that is, after receiving the target order information created for the target virtual object returned by the provisioning server, the order processing method provided in the embodiment of the present disclosure further includes:
the target order information is saved in a local secure memory.
The local secure storage can be a storage system for storing information on the mobile terminal, and the target order information is stored in the local secure storage, so that the payment state in the target order information can be updated after the payment certificate returned by the server is received.
Further, the local secure storage may be a key string, the key string is a password management system, the target order information is stored in the key string, the security of the target order information can be increased, and when the user uses the change mobile terminal and logs in the key string again, the information stored in the key string can still be found.
Specifically, the target order information further includes creation time information, and when the target order information is stored, the target order information may be stored in the following manner:
(1) after logging in a local secure memory based on a pre-stored memory login password, searching an order information list in the local secure memory;
(2) and storing the target order information into an order information list based on the creation time information contained in the target order information and the creation time information corresponding to each piece of historical order information in the order information list.
The pre-stored memory login password may be a login password stored by the client and set by the user, and when the local secure memory is a key string, the memory login password may be a login key of the key string.
The client can store the target order information returned by the supply server each time, because the client can purchase a plurality of target virtual objects, so that a plurality of target order information can be received correspondingly, in order to store the target order information in order, an order information list can be created in the local secure storage, and when each target order information is stored, the order information list can be stored in order according to the creation time information contained in the target order information, wherein the creation time information can be generated by the supply server when the target order information is created.
Of course, when the target order information is stored, the target order information may also be stored based on the receiving time information of the target order information and the receiving time information corresponding to each piece of historical order information in the order information list, which is not described herein again.
While the target order information is saved, a payment request may be initiated to the payment server based on the target virtual object ID included in the target order information, that is, in the process of S102, after the payment server determines that the payment for the target virtual object corresponding to the target virtual object ID is successful, a payment credential is returned, and then the client may update the payment status included in the target order information based on the payment credential.
Considering that the target order information is stored in the local secure memory, after receiving the payment credential returned by the payment server, before updating the payment status in the target order information associated with the target virtual object ID based on the target virtual object ID included in the payment credential, the order processing method provided by the embodiment of the present disclosure further includes:
target order information associated with the target virtual object ID is extracted from the local secure storage.
Specifically, when the target order information is extracted from the local secure storage, the target order information may be logged in the local secure storage through a pre-stored storage login password, and then the order information list is searched, the target order information associated with the target virtual order ID is extracted from the order information list, and after the target order information is extracted, the payment status included in the target order information may be updated, for example, the payment status may be changed to a paid status from a mark indicating unpaid or to-be-paid status.
For the above S104, after acquiring the target virtual object authorized by the provisioning server based on the target order information updated by the payment status, the order processing method further includes:
(1) after logging in a local secure memory based on a pre-stored memory login password, searching an order information list in the local secure memory;
(2) and deleting the target order information in the order information list.
After receiving the target virtual object authorized by the provisioning server, the client marks the end of the target order information about the target virtual object, and at this time, in order to release the usage space of the local secure storage, the target order information may be deleted from the order information list, so that the usage space occupied by the target order information in the secure storage may be released, and the specific deletion mode is not described herein again.
In addition, the order processing method provided by the embodiment of the disclosure may further include:
and if the authorized target virtual object is not received after the preset time length is exceeded, sending information for indicating order fault.
When the supply server cannot authorize the target virtual object or the authorization process is delayed, the client side can send information used for indicating order faults to the maintenance client side corresponding to the supply server to request manual processing.
In summary, according to the order processing method provided by the present disclosure, after receiving the target order information created for the target virtual object and returned by the provisioning server, the target virtual object ID included in the target order information is sent to the payment server to request payment, and after receiving the payment credential, the target order information associated with the target virtual object ID is changed into the payment state.
In addition, after receiving the target order information returned by the supply server, the embodiment of the disclosure can store the target order information in the local secure storage, thereby ensuring the storage security of the target order information and preventing the problem of order failure caused by the loss of the target order information.
It will be understood by those skilled in the art that in the method of the present invention, the order of writing the steps does not imply a strict order of execution and any limitations on the implementation, and the specific order of execution of the steps should be determined by their function and possible inherent logic.
Based on the same technical concept, an order processing apparatus corresponding to the order processing method is also provided in the embodiments of the present disclosure, and since the principle of the apparatus in the embodiments of the present disclosure for solving the problem is similar to the order processing method described above in the embodiments of the present disclosure, the implementation of the apparatus may refer to the implementation of the method, and repeated details are not described again.
Referring to fig. 3, a schematic diagram of an order processing apparatus 300 according to an embodiment of the present disclosure is shown, where the order processing apparatus is applied to a client, and specifically includes: an order acquisition module 301, an order payment module 302, an order marking module 303, and an order confirmation module 304.
An order obtaining module 301, configured to send a target virtual object obtaining request to a provisioning server in response to a trigger operation of a user for a target virtual object, and receive target order information created for the target virtual object and returned by the provisioning server, where the target order information includes a target virtual object ID;
an order payment module 302 for initiating a payment request for the target virtual object to a payment server based on the target virtual object ID;
the order marking module 303 is configured to update a payment state in the target order information associated with the target virtual object ID based on the target virtual object ID included in the payment credential after receiving the payment credential returned by the payment server;
and the order confirmation module 304 is configured to send the target order information with the updated payment status to the provisioning server, so as to obtain a target virtual object authorized by the provisioning server based on the target order information with the updated payment status.
In a possible implementation manner, after receiving the target order information created for the target virtual object returned by the provisioning server, the order obtaining module 301 is further configured to: storing the target order information in a local secure memory;
after receiving the payment credential returned by the payment server, before updating the payment status in the target order information associated with the target virtual object ID based on the target virtual object ID contained in the payment credential, the order marking module 303 is further configured to:
target order information associated with the target virtual object ID is extracted from the local secure storage.
In a possible implementation manner, the target order information includes creation time information, and the order obtaining module 301 stores the target order information specifically in the following manner:
after logging in a local secure memory based on a pre-stored memory login password, searching an order information list in the local secure memory;
and storing the target order information into an order information list based on the creation time information contained in the target order information and the creation time information corresponding to each piece of historical order information in the order information list.
In one possible implementation, after obtaining the target virtual object authorized by the provisioning server based on the target order information updated by the payment status, the order confirmation module 304 is further configured to:
after logging in a local secure memory based on a pre-stored memory login password, searching an order information list in the local secure memory;
and deleting the target order information in the order information list.
In one possible embodiment, the local secure storage includes a key string.
In one possible implementation, the order confirmation module 304 is further configured to:
and if the authorized target virtual object is not received after the preset time length is exceeded, sending information for indicating order fault.
The description of the processing flow of each module in the device and the interaction flow between the modules may refer to the related description in the above method embodiments, and will not be described in detail here.
Corresponding to the order processing method in fig. 1, an embodiment of the present disclosure further provides an electronic device 400, and as shown in fig. 4, a schematic structural diagram of the electronic device 400 provided in the embodiment of the present disclosure includes:
a processor 41, a memory 42, and a bus 43; the memory 42 is used for storing execution instructions and includes a memory 421 and an external memory 422; the memory 421 is also referred to as an internal memory, and is used for temporarily storing the operation data in the processor 41 and the data exchanged with the external memory 422 such as a hard disk, the processor 41 exchanges data with the external memory 422 through the memory 421, and when the electronic device 400 operates, the processor 41 communicates with the memory 42 through the bus 43, so that the processor 41 executes the following instructions: responding to the trigger operation of a user for a target virtual object, sending a target virtual object acquisition request to a supply server, and receiving target order information which is returned by the supply server and is established for the target virtual object, wherein the target order information comprises a target virtual object ID; initiating a payment request for the target virtual object to a payment server based on the target virtual object ID; after receiving a payment certificate returned by the payment server, updating the payment state in target order information associated with the target virtual object ID based on the target virtual object ID contained in the payment certificate; and sending the target order information with the updated payment state to a supply server so as to acquire a target virtual object authorized by the supply server based on the target order information with the updated payment state.
The embodiments of the present disclosure also provide a computer-readable storage medium, where a computer program is stored on the computer-readable storage medium, and when the computer program is executed by a processor, the computer program performs the steps of the order processing method in the above method embodiments. The storage medium may be a volatile or non-volatile computer-readable storage medium.
The computer program product of the order processing method provided in the embodiments of the present disclosure includes a computer-readable storage medium storing a program code, where instructions included in the program code may be used to execute steps of the order processing method in the above method embodiments, which may be referred to specifically in the above method embodiments, and are not described herein again.
The embodiments of the present disclosure also provide a computer program, which when executed by a processor implements any one of the methods of the foregoing embodiments. The computer program product may be embodied in hardware, software or a combination thereof. In an alternative embodiment, the computer program product is embodied in a computer storage medium, and in another alternative embodiment, the computer program product is embodied in a Software product, such as a Software Development Kit (SDK), or the like.
It is clear to those skilled in the art that, for convenience and brevity of description, the specific working processes of the system and the apparatus described above may refer to the corresponding processes in the foregoing method embodiments, and are not described herein again. In the several embodiments provided in the present disclosure, it should be understood that the disclosed system, apparatus, and method may be implemented in other ways. The above-described embodiments of the apparatus are merely illustrative, and for example, the division of the units is only one logical division, and there may be other divisions when actually implemented, and for example, a plurality of units or components may be combined or integrated into another system, or some features may be omitted, or not executed. In addition, the shown or discussed mutual coupling or direct coupling or communication connection may be an indirect coupling or communication connection of devices or units through some communication interfaces, and may be in an electrical, mechanical or other form.
The units described as separate parts may or may not be physically separate, and parts displayed as units may or may not be physical units, may be located in one place, or may be distributed on a plurality of network units. Some or all of the units can be selected according to actual needs to achieve the purpose of the solution of the embodiment.
In addition, functional units in the embodiments of the present disclosure may be integrated into one processing unit, or each unit may exist alone physically, or two or more units are integrated into one unit.
The functions, if implemented in the form of software functional units and sold or used as a stand-alone product, may be stored in a non-volatile computer-readable storage medium executable by a processor. Based on such understanding, the technical solution of the present disclosure may be embodied in the form of a software product, which is stored in a storage medium and includes several instructions for causing a computer device (which may be a personal computer, a server, or a network device) to execute all or part of the steps of the method according to the embodiments of the present disclosure. And the aforementioned storage medium includes: various media capable of storing program codes, such as a usb disk, a removable hard disk, a Read-only Memory (ROM), a Random Access Memory (RAM), a magnetic disk, or an optical disk.
Finally, it should be noted that: the above-mentioned embodiments are merely specific embodiments of the present disclosure, which are used for illustrating the technical solutions of the present disclosure and not for limiting the same, and the scope of the present disclosure is not limited thereto, and although the present disclosure is described in detail with reference to the foregoing embodiments, those skilled in the art should understand that: any person skilled in the art can modify or easily conceive of the technical solutions described in the foregoing embodiments or equivalent technical features thereof within the technical scope of the present disclosure; such modifications, changes or substitutions do not depart from the spirit and scope of the embodiments of the present disclosure, and should be construed as being included therein. Therefore, the protection scope of the present disclosure shall be subject to the protection scope of the claims.