Device running method, terminal device, storage medium, and order management system

WO2026176418A1PCT designated stage Publication Date: 2026-08-27ADVANCED NOVA TECH (SINGAPORE) HLDG PTE LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
PCT/IB2026/053159
Authority / Receiving Office
WO · WO
Patent Type
Applications
Current Assignee / Owner
Priority Date
2025-02-24
Filing Date
2026-03-31
Publication Date
2026-08-27

Smart Images

  • Figure IB2026053159_27082026_PF_FP_ABST
    Figure IB2026053159_27082026_PF_FP_ABST
Patent Text Reader

Abstract

Embodiments of this specification provide a device running method, a terminal device, a storage medium, and an order management system. In the method, a POS device in an order management system can determine a to-be-executed target action in response to an order management operation performed by an operator in an interaction interface of the POS device. The POS device determines a target execution mode adapted to hardware performance of the POS device in a plurality of execution modes of the target action, and executes the target action in the target execution mode. The POS device consumes different quantities of hardware resources when executing the target action in different execution modes.
Need to check novelty before this filing date? Find Prior Art

Description

DEVICE RUNNING METHOD, TERMINAL DEVICE, STORAGE MEDIUM, AND ORDER MANAGEMENT SYSTEM TECHNICAL FIELD

[0001] This specification relates to the field of Internet technologies, and in particular, to a device running method, a terminal device, a storage medium, and an order management system.BACKGROUND

[0002] Usually, a service development process of a merchant cannot do without a point of sale (POS) device. The POS device provides the merchant with rich order management functions, including but not limited to: generating orders, collecting cashes for orders, querying orders, summarizing orders, etc. The POS device greatly improves convenience of order management by the merchant.

[0003] The order management function provided by the POS device is usually implemented by order management software installed in the POS device. Usually, an order management service provider presets the order management software in hardware of the POS device. That is, the hardware and the software of the POS device are bundled for sale. In this case, the merchant can use a function of the order management software only when the hardware of the POS device is purchased. In some other cases, the order management service provider can sell the order management software separately. However, the order management software has a strict requirement on hardware performance, and needs to run on a hardware device that meets a specific performance requirement. In this case, while purchasing the order management software, the merchant needs to additionally purchase performance-adapted hardware of the POS device. In any of the above-mentioned cases, hardware costs of the merchant increases.

[0004] Further, the order management software is updated relatively frequently. When the merchant needs to update the order management software, the merchant needs to purchase performance-adapted hardware of the POS device again. This further increases the hardware costs of the merchant. Especially, for some small / micro merchants, an increase in the hardware costs brings some difficulties to the merchant.

[0005] Content of the background part is merely information learned of by the inventor, and neither means that the information has entered a public domain before an application date of the present disclosure, nor means that the information can become a conventional technology of the present disclosure.SUMMARY

[0006] This specification provides a device running method, a terminal device, a storage medium, and an order management system. The method can be implemented by order management software, and performed by a POS device installed with the order management software. When the POS device needs to execute a target action, the POS device can execute the target action by adaptively selecting an execution mode adapted to hardware performance of the POS device. Therefore, the order management software can run on any hardware device, so thata merchant does not need to replace the hardware device, thereby reducing hardware purchase costs.

[0007] According to a first aspect, this specification provides a device running method, applied to a POS device in an order management system. The method includes: determining a to-be-executed target action in response to an order management operation executed by an operator in an interaction interface of the POS device, where the target action corresponds to a plurality of execution modes, and the POS device consumes different quantities of hardware resources when executing the target action in different execution modes; and determining a target execution mode adapted to hardware performance of the POS device in the plurality of execution modes of the target action, and executing the target action in the target execution mode to respond to the order management operation.

[0008] According to a second aspect, this specification further provides a terminal device, serving as a POS device in an order management system, and including: at least one storage medium, storing at least one instruction set, to perform device running; and at least one processor, communicatively connected to the at least one storage medium. When running, the at least one processor reads the at least one instruction set, and performs the following operations based on an indication of the at least one instruction set: determining a to-be-executed target action in response to an order management operation executed by an operator in an interaction interface of the POS device, where the target action corresponds to a plurality of execution modes, and the POS device consumes different quantities of hardware resources when executing the target action in different execution modes; and determining a target execution mode adapted to hardware performance of the POS device in the plurality of execution modes of the target action, and executing the target action in the target execution mode to respond to the order management operation.

[0009] According to a third aspect, this specification further provides a computer-readable non-transitory storage medium. The computer-readable non-volatile storage medium stores at least one instruction set, and when the at least one instruction set is executed by at least one processor, the method according to any implementation of the first aspect is implemented.

[0010] According to a fourth aspect, this specification further provides an order management system, including: a POS device, configured to perform the method according to any implementation of the first aspect; and a service device, communicatively connected to the POS device, and configured to provide a service for the POS device.

[0011] Other functions of the device running method, the terminal device, the storage medium, and the order management system provided in this specification are partially listed in the following descriptions. Creative aspects of the device running method, the terminal device, the storage medium, and the order management system provided in this specification can be fully explained by practice or by using the methods, apparatuses, and combinations described in the following detailed examples.BRIEF DESCRIPTION OF DRAWINGS

[0012] To describe the technical solutions in the embodiments of this specification more clearly, the following briefly describes the accompanying drawings needed for describing theembodiments. Clearly, the accompanying drawings in the following descriptions show merely some embodiments of this specification, and a person of ordinary skill in the art can still derive other drawings from these accompanying drawings without creative efforts.

[0013] FIG. 1 is a schematic diagram of an application scenario of an order management system according to an embodiment of this specification;

[0014] FIG. 2 is a schematic diagram of another application scenario of an order management system according to an embodiment of this specification;

[0015] FIG. 3 is a schematic diagram of a hardware structure of a terminal device according to an embodiment of this specification;

[0016] FIG. 4 is a schematic flowchart of a device running method according to an embodiment of this specification;

[0017] FIG. 5 is a schematic diagram of a plurality of execution modes of a target action according to an embodiment of this specification;

[0018] FIG. 6 is a schematic diagram of a process in which a POS device performs cleaning according to an embodiment of this specification; and

[0019] FIG. 7 is a schematic diagram of another process in which a POS device performs cleaning according to an embodiment of this specification.DESCRIPTION OF EMBODIMENTS

[0020] Specific application scenarios and requirements of this specification are provided in the following descriptions, so that a person skilled in the art can manufacture and use content of this specification. For the person skilled in the art, various local modifications to the disclosed embodiments are clear, and the general principles defined herein can be applied to other embodiments and applications without departing from the spirit and scope of this specification. Therefore, this specification is not limited to the shown embodiments, but has a widest scope consistent with that of the claims.

[0021] The terms used herein are only intended to describe a particular example embodiment, but do not impose a limitation. For example, unless otherwise specified in the context, the singular forms "one", "a", and "the" used herein can also include a plural form. When used in this specification, the terms "include", "comprise", and / or "have" indicate / indicates existence of an associated integer, step, operation, element, and / or component, but does not exclude existence of one or more other features, integers, steps, operations, elements, components, and / or groups, or another feature, integer, step, operation, element, component, and / or group can be added to the system / method.

[0022] In consideration of the following descriptions, these and other features of this specification, operations and functions of related components of the structure, and economy of combination and manufacturing of components can be significantly improved. With reference to the accompanying drawings, all of these form a part of this specification. However, it should be clearly understood that the accompanying drawings are merely used for the purpose of illustration and description, and are not intended to limit the scope of this specification. It should be further understood that the accompanying drawings are not drawn to scale.

[0023] The flowchart used in this specification illustrates operations implemented by asystem in some embodiments of this specification. It should be clearly understood that operations in the flowchart can be implemented out of sequence. On the contrary, operations can be implemented reversely or simultaneously. In addition, one or more other operations can be added to the flowchart. One or more operations can be removed from the flowchart.

[0024] In this specification, "X includes at least one of A, B, or C" means that X includes at least A, or X includes at least B, or X includes at least C. In other words, X can include only any one of A, B, and C, or simultaneously include any combination of A, B, and C and other possible content / elements. Any combination of A, B, and C can be A, B, C, AB, AC, BC, or ABC.

[0025] In this specification, unless expressly stated, an association relationship generated between structures can be a direct association relationship or an indirect association relationship. For example, when "A is connected to B" is described, unless it is explicitly stated that A is directly connected to B, it should be understood as that A can be directly connected to B or can be indirectly connected to B. For another example, when "A is above B" is described, unless it is explicitly stated that A is directly above B (A is adjacent to B and A is above B), it should be understood as that A can be directly above B, or A can be indirectly above B (A is separated from B by another element and A is above B), and so on.

[0026] It should be noted that user data obtained in this specification is authorized by the user, and does not relate to user privacy.

[0027] It should be noted that, collection, storage, use, processing, transmission, provision, disclosure, etc. of related information of a user in the technical solutions in this specification all comply with related laws and regulations, and do not violate public order and good morals.

[0028] Embodiments described in this specification can be applied to an order management scenario of a merchant. The merchant can be merchants that provide various products or services, including but not limited to a catering merchant, a store, a supermarket, a fruit and vegetable store, a flower store, a bookstore, a hotel, a beauty salon, a dry cleaning store, a barber store, etc. The merchant can be a small / micro merchant, a large merchant, a chain store, etc. This is not limited in this specification.

[0029] In some embodiments, the merchant can be a merchant that performs service development on an offline channel (in a real store). In this case, an order of the merchant can include an offline order. In some embodiments, the merchant can alternatively be a merchant that performs service development on an online channel (Internet). In this case, an order of the merchant can include an online order. In some embodiments, the merchant can alternatively be a merchant that support service development on both an online channel and an offline channel. In this case, an order of the merchant can include an offline order and an online order.

[0030] In this specification, the online order is a product or service purchase request submitted by a consumer on the online channel (for example, a website or an application). The offline order is a product or service purchase request submitted by the consumer on the offline channel, for example, a product or service purchase request submitted by the consumer to a cashier in a face-to-face manner.

[0031] When the merchant needs to perform service development on the offline channel, the merchant needs to purchase a point of sale (POS) device, to manage the offline order. The POSdevice provides an interaction function, and can display a product or a service sold by the merchant. The cashier of the merchant can help the consumer select the product or service on the POS device and submit an order based on a purchase requirement of the consumer. The order is an offline order.

[0032] When the merchant performs service development on the online channel, the merchant can develop a store mini program, and dispose an access entry (for example, a two-dimensional code) of the store mini program in a store or any other possible location. The consumer accesses the store mini program through the access entry, and submits the order in the store mini program.

[0033] When the merchant performs service development on the online channel, the merchant can further cooperate with different network platforms. The network platform can include but is not limited to a delivery platform, a wallet platform, a social platform, etc. The merchant may be interconnected to different network platforms in different manners. For example, when cooperating with some platforms (for example, a delivery platform), the merchant can apply for opening an online store on these platforms, and place a product or a service of the merchant in the online store, so that a consumer places an order in the online store. For another example, when the merchant cooperates with some other platforms (for example, the wallet platform or the social platform), the store mini program can be placed on these platforms, so that the consumer places an order in the store mini program.

[0034] In an online service development scenario, the merchant usually needs to cooperate with a plurality of network platforms, to attract more consumers. Therefore, an interconnection between the merchant and the network platform needs to take a lot of effort. In particular, in some geographical areas, each network platform covers a small quantity of consumers, and there are a large quantity of network platforms, for example, there may be hundreds or even thousands of network platforms. In such geographical areas, a quantity of network platforms that need to be interconnected to the merchant is huge, and it needs to take huge effort.

[0035] A POS device used by the merchant for offline service development can only process receiving of an offline order, and cannot receive an online order. To normally accept an order on the network platform, the merchant needs to purchase a dedicated order acceptance device from the network platform. Sometimes, a plurality of network platforms are active in the market, but no network platform is in a market monopoly position. In other words, the plurality of network platforms cover different consumer groups. In this case, if the merchant wants to operate normally, the merchant is forced to cooperate with each of the plurality of network platforms. When the merchant cooperates with the plurality of network platforms, the merchant needs to purchase the order acceptance device from the plurality of network platforms. Consequently, purchase costs are relatively high. In particular, the purchase costs of the merchant are huge when a relatively large quantity of network platforms are interconnected. In addition, a counter of the merchant is crowded if these order acceptance devices are placed on the counter. In addition, in the face of so many order acceptance devices, the merchant tends to be distracted, and does not process an order in a timely manner. Consequently, experience of the consumer is affected.

[0036] Further, when the merchant cooperates with the plurality of network platforms, the merchant has a relatively large quantity of order sources. Orders generated on different network platforms are stored in servers corresponding to the network platforms. When the merchant manages the online order, the merchant needs to visit serving ends of different network platforms to perform order management (for example, an order query or order summary). The merchant cannot perform unified management of all orders. In addition, different network platforms may have different operation manners for order management. The merchant needs to be familiar with operation manners of different network platforms. Due to the above-mentioned factors, an order management workload of the merchant is relatively large, and order management efficiency is relatively low.

[0037] Based on at least one of the technical problems described above, this specification provides an order management system. The order management system can help a merchant implement one- stop order management. To help a reader better understand one- stop order management, the following describes the order management system with reference to FIG. 1.

[0038] FIG. 1 is a schematic diagram of an application scenario 100 of an order management system according to an embodiment of this specification. For ease of understanding, an example in which a catering scenario is taken for description in FIG. 1. As shown in FIG. 1, the order management system can include a point of sale (POS) device 110 (or referred to as a POS end or a front-end device) and a service device 120 (or referred to as a serving end, a server, or a back-end device).

[0039] The POS device 110 is a multi-functional terminal. The POS device 110 can be considered as a client of the order management system. In some embodiments, the POS device 110 can be a mobile device, for example, a handheld device. The POS device 110 can be carried by a worker of a merchant to different locations in a store for operation, and there is relatively high convenience. In some embodiments, POS device 110 can be a non-mobile device. In this case, the POS device 110 is usually placed on a checkout counter in an offline store of the merchant.

[0040] In this specification, the POS device 110 can receive an offline order and an online order of the merchant. The POS device 110 can further perform cash collection processing for the offline order. The POS device 110 can also be referred to as a cash collection device or a sales device, or referred to as an all-in-one POS device.

[0041] The POS device 110 is an electronic device with a specific computing capability. In some embodiments, the POS device 110 can include a hardware device with a data processing function and a necessary program needed for driving the hardware device to work. The POS device 110 can manage an order by driving the hardware device to execute the program. For example, the POS device 110 can be installed with order management software (or an order management program). The POS device 110 can manage the order by running the order management software. The order management software can correspond to an operating system installed in the POS device 110, or can correspond to an application (APP) or an instruction set installed in the POS device 110. The order management software can be software preset in the hardware device of the POS device 110 (for example, software built in the POS device 110 whenthe POS device 110 is delivered from a factory), or can be software that is later installed in the POS device 110 by the worker of the merchant. This is not limited in this specification.

[0042] In some embodiments, the POS device 110 can have a display, or the POS device 110 can be externally connected to a display. The POS device 110 can provide an interaction capability through the display. For example, the POS device 110 displays, on the display, a product or a service sold by the merchant, and generates an offline order based on a product or a service selected by an operator (the worker of the merchant or a consumer). The POS device 110 can further display a cash collection entry on the display, so that an operator performs a cash collection operation for the offline order.

[0043] When cash collection is performed for the order, the POS device 110 supports a plurality of payment manners, including but not limited to cash payment, card scanning payment, code scanning payment, biological recognition (for example, facial recognition) based payment, near field communication (NFC) based payment, etc.

[0044] In some embodiments, when the POS device 110 supports cash payment, the POS device 110 can be provided with a cash box to store cash.

[0045] In some embodiments, a card reading apparatus 111 can be built in or externally connected to the POS device 110 when the POS device 110 supports card scanning payment. When a built-in manner is used, the card reading apparatus 111 can be disposed at any possible location of the POS device 110. This is not limited in this specification. When an external connected manner is used, the POS device 110 can be connected to the card reading apparatus 111 in a wired or wireless manner. This is not limited in this specification. A wired connection manner can include but is not limited to a universal serial bus (USB) connection, an Ethernet connection, an optical fiber connection, etc. A wireless connection manner can include but is not limited to a Wi-Fi connection, a Bluetooth connection, etc.

[0046] The card reading apparatus 111 is an apparatus that can read card information of a payment card (for example, a debit card or a credit card) of the consumer according to a preset payment specification. When the consumer selects card scanning payment, the POS device 110 can control the card reading apparatus 111 to enter a card reading mode. The card reading apparatus 111 can read the card information of the payment card according to the preset payment specification in response to that the consumer places the payment card close to, attaches the payment card to, or inserts the payment card into the card reading apparatus.

[0047] In some embodiments, a code scanning apparatus 112 can be built in or externally connected to the POS device 110 when the POS device 110 supports code scanning payment. When a built-in manner is used, the code scanning apparatus 112 can be disposed at any possible location of the POS device 110. This is not limited in this specification. When an external connected manner is used, the POS device 110 can be connected to the code scanning apparatus 112 in a wired or wireless manner. This is not limited in this specification. The code scanning apparatus 112 is an apparatus with a code scanning capability. For example, the code scanning apparatus 112 can include a camera module. When the consumer chooses to pay the offline order by using a payment code, the POS device 110 can control the code scanning apparatus 112 to enter a scanning mode. In response to that the consumer aligns the payment code with the codescanning apparatus 112, the code scanning apparatus 112 scans code information of the payment code by using the camera module.

[0048] In some embodiments, a photographing apparatus (not shown in FIG. 1) can be built in or externally connected to the POS device 110 when the POS device 110 supports biological recognition based payment. When a built-in manner is used, the photographing apparatus can be disposed at any possible location of the POS device 110. This is not limited in this specification. When an external connected manner is used, the POS device 110 can be connected to the photographing apparatus in a wired or wireless manner. This is not limited in this specification. For example, when the consumer chooses to use facial scanning payment, the POS device 110 can control the photographing apparatus to enter a photographing mode. In response to that the consumer aligns a face with the photographing apparatus, the photographing apparatus photographs a face image of the consumer.

[0049] In some embodiments, a near field communication apparatus (not shown in FIG. 1) can be built in or externally connected to the POS device 110 when the POS device 110 supports near field communication based payment. The near field communication apparatus can be disposed at any possible location of the POS device 110. This is not limited in this specification. When the consumer selects near field communication based payment, the POS device 110 can control the near field communication apparatus to enter a communication mode. When the consumer places a terminal device with a near field communication component close to the near field communication apparatus, the near field communication apparatus communicates with the near field communication component in the terminal, to obtain payment information of the order.

[0050] In some embodiments, a printing apparatus 113 can be built in or externally connected to the POS device 110. When a built-in manner is used, the printing apparatus 113 can be disposed at any possible location of the POS device 110. This is not limited in this specification. When an external connected manner is used, the POS device 110 can be connected to the printing apparatus 113 in a wired or wireless manner. This is not limited in this specification. A printing paper or a label paper can be disposed in the printing apparatus 113. After the consumer successfully pays an order, the POS device 110 can control the printing apparatus 113 to print a receipt or an order label that is of the consumer and that corresponds to the order.

[0051] In some embodiments, the POS device 110 can further include an audio output apparatus (not shown in FIG. 1). The audio output apparatus can be, for example, a speaker. For example, when receiving an online order, the POS device 110 can output voice information by using the audio output apparatus, to remind the worker of the merchant to process the order in a timely manner. For another example, after the consumer performs a payment operation for an offline order by using the POS device 110, in response to that the POS device 110 receives a payment result of the order, the POS device 110 can output voice information by using the audio output apparatus, to indicate that the order is successfully paid or unsuccessfully paid.

[0052] Still as shown in FIG. 1, the service device 120 is a computing system with a specific computing capability. The service device 120 is communicatively connected to the POS device 110, and provides an order management service to the POS device 110. The service device 120can correspond to a single computing device, or can correspond to a computing cluster including a plurality of computing devices. The service device 120 can be deployed locally, or can be deployed remotely. For example, the service device 120 can be a cloud server. In some embodiments, the service device 120 can include a hardware device with a data processing function and a necessary program needed for driving the hardware device to work. The service device 120 can provide the order management service to the POS device by driving the hardware device to execute the program. In some embodiments, the service device 120 can provide the order management service to the POS device in a software as a service (SaaS) mode.

[0053] In some embodiments, when the service device 120 is deployed remotely, the service device 120 can be connected to POS devices 110 of a plurality of merchants, and provide the order management service to the POS devices 110 of the plurality of merchants. In this case, the service device 120 can perform isolated management on orders of different merchants by using various isolation technologies, to avoid mutual interference between order data of the different merchants, and improve security of the order data. A person skilled in the art can understand that content of the order management service provided by the service device 120 to the POS devices 110 of the different merchants is similar. In the descriptions of this specification, only an example in which the service device 120 provides the order management service to a POS device 110 of one merchant is taken for description.

[0054] A service provided by the service device 120 to the POS device 110 can include an order management service for an offline order, and can further include an order management service for an online order.

[0055] The following describes a working process of the order management system by using a catering scenario as an example.

[0056] With reference to FIG. 1, a catering store can include a front-of-house area and a back-of-house area. The front-of-house area is used to receive a consumer and is used by the consumer for dining. The front-of-house area can also be referred to as a reception area. The back-of-house area is an area in which a cook cooks dishes. The back-of-house area can also be referred to as a preparation area. The POS device 110 is usually located in the front-of-house area. The service device 120 can be located in the front-of-house area, or can be located in a cloud.

[0057] A process in which the order management system processes the offline order is follows: As shown in FIG. 1, a consumer A goes to a store to have a dinner. The consumer A notifies a cashier of a required dish. The cashier selects a corresponding dish on the POS device 110, and places an order. The POS device 110 generates an offline order in response to an order placing operation of the cashier. The POS device 110 sends the offline order to the service device 120, so that the service device 120 stores the offline order. The POS device 110 can perform cash collection processing for the offline order based on a payment mode selected by the consumer.

[0058] The order management system can receive online orders from a plurality of online channels. The following provides descriptions by using three cases as examples.

[0059] Case 1: As shown in FIG. 1, the service device 120 can be deployed with a store mini program. A two-dimensional code of the store mini program is disposed on a dining table (oranother location) of the store. A consumer B can scan the two-dimensional code by using a terminal device, to view a page of the store mini program. The consumer B selects a desired dish on the page of the mini program, and completes online payment. In this case, the service device 120 generates an online order, stores the online order, and then sends the online order to the POS device 110. Therefore, the POS device 110 receives the online order.

[0060] Case 2: As shown in FIG. 1, the merchant can place the store mini program on a network platform. The following provides descriptions by using an example in which the store mini program is placed on a wallet platform. When a consumer C uses the wallet platform, the consumer C accesses the store mini program on the wallet platform, selects a desired dish on the page of the mini program, and completes online payment. In this case, the wallet platform generates an online order, and sends the online order to the service device 120. After storing the online order, the service device 120 sends the online order to the POS device 110. Therefore, the POS device 110 receives the online order.

[0061] Case 3: As shown in FIG. 1, the merchant can open an online store on a network platform. The following provides descriptions by using an example in which the online store is opened on a delivery platform. When a consumer D uses the delivery platform, the consumer D accesses the online store of the merchant on the delivery platform, selects a required dish, and completes online payment. In this case, the delivery platform generates an online order, and sends the online order to the service device 120. After storing the online order, the service device 120 sends the online order to the POS device 110. Therefore, the POS device 110 receives the online order.

[0062] It can be learned from the above-mentioned descriptions that an offline order received by the merchant and online orders from all channels are stored in the service device 120. Therefore, the merchant can implement unified management of all orders on the service device 120. Compared with a manner in which the merchant respectively manages orders on different channels, the order management system provided in this specification can improve convenience of order management of the merchant and improve order management efficiency.

[0063] The catering scenario continues to be taken as an example. After receiving an order, the merchant needs to process and cook a dish in the order. In an actual application, after the POS device 110 receives an order (including an offline order and an online order), the POS device 110 can control the printing apparatus to print a kitchen order ticket that includes food content of the order, and the kitchen order ticket is manually transferred to a back-of-house area. The cook cooks a dish based on the dish content in the kitchen order ticket. In such a manner of manually transferring the kitchen order ticket, a dish is easily cooked wrongly in a peak period of dining, and efficiency is relatively low. Consequently, dining duration of the consumer increases.

[0064] Therefore, in some embodiments of this specification, as shown in FIG. 1, the order management system can further include one or more display devices 130. For example, in the catering scenario, the display device 130 can also be referred to as a kitchen display system (KDS). The display device 130 is disposed in the back-of-house area, and is communicatively connected to the POS device 110. The display device 130 can receive an order from the POS device 110, and display a to-be-cooked dish to the cook, to improve cooking efficiency of thecook and reduce a probability that the cook wrongly cooks. In some embodiments, after a dish is cooked, the cook can further send a dish cooking completion notification to the POS device 110 by using the display device 130, so that the POS device 110 knows an order processing progress.

[0065] In stores of some merchants, the back-of-house area include a plurality of ports. Different ports are equipped with different cooks who are responsible for cooking different types of dishes. With reference to FIG. 1, an example in which the back-of-house area includes a cold dish port and a hot dish port is used. A cook XI is responsible for cooking a cold dish and a cook X2 is responsible for cooking a hot dish. In this case, one display device 130 can be disposed in the cold dish port, and is configured to display, to the cook XI, the cold dish that needs to be cooked. One display device 130 can be disposed in the hot dish port, and is configured to display, to the cook X2, the hot dish that needs to be cooked. In this way, dish cooking in different ports does not interfere with each other, to further improve cooking efficiency.

[0066] It should be noted that the catering scenario is used as an example in FIG. 1. It can be understood by a person skilled in the art that when the order management system provided in this specification is applied to another scenario, an implementation solution and a technical effect of the order management system are similar to those of the catering scenario. Details of the another scenario are not described in this specification.

[0067] It can be learned from the above-mentioned descriptions that the merchant can implement one-stop order management by using the order management system provided in this specification. The one- stop order management is embodied in at least the following aspects: (1) The merchant can use one POS device 110 to implement processing of the offline order or implement processing of the online orders from the plurality of online channels. The merchant does not need to be interconnected to each of the plurality of online channels, thereby avoiding energy and time costs required for work docking. In addition, the merchant does not need to purchase an order acceptance device from each of the plurality of online channels, to reduce purchase costs of the merchant. (2) All orders received by the POS device 110 are sent to the display device 130 in the back-of-house area in real time, without a need to manually transfer the kitchen order ticket. This improves order processing efficiency. (3) All orders received by the merchant are stored in the service device 120, and the merchant can implement unified management such as order query or summary on all the orders on the service device 120. The merchant does not need to perform decentralized management on the orders on different network platforms, to improve order management efficiency.

[0068] With reference to the order management system shown in FIG. 1, the POS device 110 includes a hardware part and a software part (namely, order management software installed in the POS device). When the merchant needs to use the order management system that can implement one-stop order management as shown in FIG. 1, the POS device 110 described in FIG. 1 needs to be purchased, that is, both the hardware part and the software part of the POS device 110 are purchased. However, some small / micro merchants pay more attention to hardware costs. The small / micro merchants hopes that one-stop order management can still be implemented by installing the order management software based on an existing hardware device. In addition, there are a large quantity of small / micro merchants, and existing hardware devices of differentmerchants are usually different and diversified. Therefore, how to enable the order management software to run on various different hardware devices becomes a technical problem that needs to be resolved.

[0069] In view of this, the embodiments of this specification provides a device running method. The method can be implemented by order management software, and performed by a POS device installed with the order management software. Specifically, when generating the order management software, for an action that needs to be executed by the POS device, a developer designs a plurality of different execution modes of the action. The action can be executed in the plurality of different execution modes. However, the POS device consumes different hardware resources when executing the action in different execution modes. In this way, when running the order management software, the POS device determines a to-be-executed target action in response to an order management operation performed by an operator in an interaction interface of the POS device; and determines a target execution mode adapted to hardware performance of the POS device in the plurality of execution modes of the target action, and executes the target action in the target execution mode to respond to the order management operation.

[0070] In the above-mentioned solution, the order management software is implemented as follows: When executing an action, the POS device adaptively executes the action in a corresponding execution mode based on the hardware performance of the POS device, so that a quantity of hardware resources consumed by the action is adapted to the hardware performance of the POS device. This enables the order management software to support running on any hardware device. That is, the order management software can run on a hardware device with relatively high performance, or can run on a hardware device with relatively low performance. In this way, the merchant can use an order management service by installing the order management software on an existing hardware device. The merchant does not need to purchase a hardware device again, to reduce operating costs of the merchant. In addition, the above-mentioned solution further enables a one-stop order management service to be applied to more merchants, to improve application universality.

[0071] FIG. 2 is a schematic diagram of another application scenario of an order management system according to an embodiment of this specification. As shown in FIG. 2, the application scenario can include a plurality of POS devices, and hardware performance of the plurality of POS devices is different. For example, hardware performance of a POS device 110-1 is relatively low, hardware performance of a POS device 110-2 is medium, and hardware performance of a POS device 110-3 is relatively high. All of the above-mentioned three POS devices can implement one- stop order management by installing the order management software and performing the device running method provided in this specification under an indication of the order management software.

[0072] FIG. 3 is a schematic diagram of a hardware structure of a terminal device 200 according to an embodiment of this specification. The terminal device 200 can serve as the POS device 110 in FIG. 1.

[0073] As shown in FIG. 3, the terminal device 200 can include at least one storage medium230 and at least one processor 220. In some embodiments, the terminal device 200 can further include an internal communication bus 210. In some embodiments, the terminal device 200 can further include a communication port 250. In some embodiments, the terminal device 200 can further include an I / O component 260.

[0074] The internal communication bus 210 can be connected to different system components. For example, the internal communication bus 210 can be connected to the storage medium 230, the processor 220, the communication port 250, and the I / O component 260.

[0075] The I / O component 260 supports input / output between the terminal device 200 and other components.

[0076] The communication port 250 is used for data communication between the terminal device 200 and the outside. For example, the communication port 250 can be used for data communication between the terminal device 200 and a network. The communication port 250 can be a wired communication port, or can be a wireless communication port.

[0077] In some embodiments, the network can be any type of wired or wireless network, or a combination thereof. For example, the network can include a cable network, a wired network, an optical fiber network, a telecommunication network, the intranet, the internet, a local area network (LAN), a wide area network (WAN), a wireless local area network (WLAN), a metropolitan area network (MAN), a public switched telephone network (PSTN), a Bluetooth network™, a short-range wireless network (ZigBeeTM), a near field communication (NFC) network, or a similar network.

[0078] In some embodiments, the network can include one or more network access points. For example, the network can include a wired or wireless network access point, for example, a base station or an Internet switching point. Through the access point, one or more components in each device corresponding to the terminal device 200 can be connected to the network to exchange data or information.

[0079] The storage medium 230 can include a data storage apparatus. The data storage apparatus may be a non-transitory storage medium, or may be a transitory storage medium. For example, the data storage apparatus can include one or more of a disk 232, a read-only storage medium (ROM) 234, or a random access storage medium (RAM) 236. The storage medium 230 further includes at least one instruction set stored in the data storage apparatus. The instruction set can be computer program code. The computer program code can include a program, a routine, an object, a component, a data structure, a process, a module, etc. for performing the device running method provided in this specification.

[0080] The at least one processor 220 is communicatively connected to the at least one storage medium 230 through the internal communication bus 210. The at least one processor 220 is configured to execute the at least one instruction set. When the system 130 runs, the at least one processor 220 reads the at least one instruction set and performs, based on an indication of the at least one instruction set, the device running method provided in this specification.

[0081] The processor 220 can perform all steps included in the device running method. The processor 220 can be in a form of one or more processors. The processor 220 can send an execution instruction. The processor 220 can include one or more hardware processors, forexample, a microcontroller, a microprocessor, a reduced instruction set computer (RISC), an application- specific integrated circuit (ASIC), an application-specific instruction set processor (ASIP), a central processing unit (CPU), a graphics processing unit (GPU), a physical processing unit (PPU), a microcontroller unit, a digital signal processor (DSP), a field programmable gate array (FPGA), an advanced RISC machine (ARM), a programmable logic device (PLD), any circuit or processor that can perform one or more functions, or any combination thereof.

[0082] To merely describe a problem, only one processor 220 is shown in the terminal device 200 in the accompanying drawings of this specification. However, it should be noted that the terminal device 200 in this specification can further include a plurality of processors. Therefore, the operations and / or method steps disclosed in this specification can be performed by one processor or can be performed jointly by a plurality of processors, as described in this specification. For example, if the processor 220 in the terminal device 200 in this specification performs step A and step B, it should be understood as that step A and step B can be jointly or separately performed by two different processors 220 (for example, a first processor performs step A, and a second processor performs step B, or a first processor and a second processor jointly perform steps A and B).

[0083] FIG. 4 is a schematic flowchart of a device running method according to an embodiment of this specification. A device running method P300 can be performed by a POS device in an order management system. For example, a processor in the POS device executes the device running method P300 when reading an instruction set (namely, an instruction set corresponding to order management software) stored in a storage medium of the POS device. As shown in FIG. 4, the device running method P300 can include S310 to S33O.

[0084] S310: Determine a to-be-executed target action in response to an order management operation executed by an operator in an interaction interface of the POS device, where the target action corresponds to a plurality of execution modes, and the POS device consumes different quantities of hardware resources when executing the target action in different execution modes.

[0085] The order management operation can be any operation that the POS device allows the operator to perform. For example, the order management operation can include but is not limited to one or more of the following: an order placing operation, a cash collection operation, a daily settlement operation, a historical order query operation, etc.

[0086] When the operator performs an order management operation in the interaction interface of the POS device, the POS device performs an action corresponding to the order management operation to respond to the order management operation. The action herein is an operation or a series of operations performed by the POS device based on a preset rule or program logic after the POS device receives the order management operation.

[0087] For ease of description, an action corresponding to an order management operation currently received by the POS device is referred to as a target action. A person skilled in the art can understand that the target action determined by the POS device in S310 may change with the order management operation currently received by the POS device.

[0088] For example, when the order management operation is an order placing operation, the target action can include: generating order data, and storing order data. When the ordermanagement operation is a daily settlement operation, the target action can include: summarizing orders generated on a specified date. When the order management operation is a historical order query operation, the target action can include: querying, from a database based on a specified query condition, an order that meets a condition. It should be understood that the above-mentioned examples are merely example descriptions. The order management operation supported by the POS device and actions corresponding to all order management operations can be flexibly adjusted based on an actual situation, and are not limited to those provided in the above-mentioned embodiment.

[0089] In some embodiments, the plurality of execution modes corresponding to the target action include at least two of a first execution mode, a second execution mode, a third execution mode, and a fourth execution mode. FIG. 5 is a schematic diagram of a plurality of execution modes of a target action according to an embodiment of this specification. The following describes various execution modes with reference to FIG. 5.

[0090] The first execution mode represents that the POS device executes the target action. For example, as shown in FIG. 5, when the first execution mode is used, the POS device independently executes the target action locally, and does not need to request a service device to assist the POS device in executing the target action. For example, if the target action is placing an order and adding to cart, the POS device can directly execute an order placing action and an adding to cart action.

[0091] The second execution mode represents that the POS device executes a simplified action corresponding to the target action. The simplified action refers to a simplified version of the target action. An amount of data that needs to be processed (for example, an amount of data that needs to be collected or an amount of data that needs to be stored) when the POS device executes the simplified action is less than an amount of data that needs to be processed when the POS device executes the target action. For example, as shown in FIG. 5, when the second execution mode is used, the POS device independently executes the simplified action corresponding to the target action locally, and does not need to request the service device to assist the POS device in executing the target action.

[0092] For example, if the target action is storing order information of an order A, the simplified action corresponding to the target action can be storing key order information of the order A. The order information can include, for example, an order time, an order title, operator information, an order amount, an order number, and product details. The key order information can include only a part of the order information. For example, the key order information can include the order amount, the order number, and the product details.

[0093] The amount of data that needs to be processed when the POS device executes the simplified action corresponding to the target action is reduced. Compared with a case in which the POS device executes the target action, in this way, hardware resources that need to be consumed by the POS device are reduced to some extent. Therefore, a requirement for hardware performance in the second execution mode is lower than a requirement for hardware performance in the first execution mode.

[0094] A third execution mode represents that the service device executes the target action.That is, the POS device requests the service device to assist the POS device in executing the target action. For example, as shown in FIG. 5, when the third execution mode is used, the POS device sends an execution request corresponding to the target action to the service device. The service device executes the target action, and returns an execution result of the target action to the POS device. After receiving the execution result of the target action from the service device, the POS device displays the execution result of the target action in a display interface of the POS device.

[0095] For example, if the target action is viewing a historical order, the POS device can send an order query instruction to the service device, and the service device performs querying based on the order query instruction to obtain historical order data. Then, the service device sends the historical order data to the POS device. After receiving the historical order data from the service device, the POS device displays the historical order data in the display interface for viewing by the operator.

[0096] In the third execution mode, execution of the target action is transferred to a service device side. The POS device only needs to receive and display the execution result of the target action from the service device, and does not need to perform a large quantity of data operations. Compared with the first execution mode and the second execution mode, when the POS device executes the target action in the third execution mode, an amount of data that needs to be processed is greatly reduced, and less hardware resources need to be consumed. Therefore, a requirement for hardware performance in the third execution mode is lower than the requirement for hardware performance in the first execution mode, and is lower than the requirement for hardware performance in the second execution mode.

[0097] The fourth execution mode represents that the POS device executes a part of content of the target action, and the service device executes the other part of the target action. For example, as shown in FIG. 5, when the fourth execution mode is used, the POS device and the service device jointly execute the target action. After execution is completed, the POS device displays the execution result to the operator. It should be noted that this specification sets no limitation on a manner in which the POS device and the service device jointly execute the target action. For example, the POS device can first locally execute a first part of content, and the service device executes a second part of content based on an execution result of the first part of content. Alternatively, the POS device requests the service device to first execute a first part of content and then locally execute a second part of content based on an execution result of the first part of content. Alternatively, the POS device locally executes a first part of content and simultaneously requests the service device to execute a second part of content, that is, execute the first part of content and the second part of content in parallel.

[0098] In the fourth execution mode, the target action is split into two parts, which are separately executed by the POS device and the service device, so that the POS device does not need to independently undertake all computing amounts. Compared with the first execution mode, when the POS device executes the target action in the fourth execution mode, an amount of data that needs to be processed is reduced, and less hardware resources need to be consumed. Therefore, a requirement for hardware performance in the fourth execution mode is lower than arequirement for hardware performance in the first execution mode. Compared with the third execution mode, when the POS device executes the target action in the fourth execution mode, a relatively large quantity of hardware resources need to be consumed. Therefore, the requirement for hardware performance in the fourth execution mode is higher than the requirement for hardware performance in the third execution mode.

[0099] It should be noted that a plurality of execution modes corresponding to each of different actions are not limited in this specification. Execution modes corresponding to different actions can be the same, or can be different. For example, a plurality of execution modes corresponding to the first action can include the first execution mode and the third execution mode. A plurality of execution modes corresponding to the second action can include the second execution mode and the third execution mode. A plurality of execution modes corresponding to the third action can include the first execution mode, the second execution mode, and the third execution mode. A plurality of execution modes corresponding to the fourth action can include the first execution mode, the second execution mode, the third execution mode, and the fourth execution mode. Execution modes corresponding to different actions can be preset. A correspondence between each action and an execution mode corresponding to the action can be set according to an actual requirement.

[0100] S33O: Determine a target execution mode adapted to hardware performance of the POS device in the plurality of execution modes of the target action, and execute the target action in the target execution mode to respond to the order management operation.

[0101] It can be learned from the above-mentioned analysis that different execution modes have different requirements on the hardware performance of the POS device. Therefore, when the POS device needs to execute the target action, the POS device can execute the target action by selecting an execution mode adapted to the hardware performance.

[0102] That one execution mode is adapted to the hardware performance of the POS device means that the hardware performance of the POS device can support the execution mode. That is, when the hardware performance of the POS device can support running of an execution mode, it indicates that the execution mode is adapted to the hardware performance of the POS device. For ease of description, in this specification, an execution mode adapted to the hardware performance of the POS device in the plurality of execution modes of the target action is referred to as a target execution mode.

[0103] In some embodiments, the POS device can determine the target execution mode in the following manner.

[0104] (1) A hardware performance level of the POS device is obtained, and the lowest hardware performance level corresponding to each of the plurality of execution modes is obtained.

[0105] The lowest hardware performance level corresponding to each execution mode is used to indicate the lowest requirement of the target execution mode on the hardware performance of the POS device. Different execution modes have different requirements on the hardware performance of the POS device. For example, when the same target action is executed, the first execution mode has the highest requirement on the hardware performance of the POSdevice. The third execution mode has the lowest requirement on the hardware performance of the POS device. Requirements of the second execution mode and the fourth execution mode for the hardware performance of the POS device are between those of the first execution mode and the third execution mode, and the lowest requirement on the performance of the POS device is specifically determined based on the target action.

[0106] (2) The target execution mode adapted to the hardware performance of the POS device in the plurality of execution modes is determined based on the hardware performance level of the POS device and the lowest hardware performance level corresponding to each of the plurality of execution modes.

[0107] In the above-mentioned manner, the lowest hardware performance level of each execution mode and the hardware performance of the POS device are fully considered, so that the selected target execution mode is adapted to current hardware performance of the POS device. Therefore, regardless of the hardware performance of the POS device, the POS device can execute the target action in a proper execution mode, to respond to the order management operation. According to the above-mentioned manner, a problem that the target action cannot be successfully executed on the POS device because the target action has a high requirement on the hardware performance and the POS device has low hardware performance is avoided.

[0108] In some embodiments, the POS device can determine at least one candidate execution mode in the plurality of execution modes based on the hardware performance level of the POS device and the lowest hardware performance level corresponding to each of the plurality of execution modes. Further, the POS device determines the target execution mode in the at least one candidate execution mode. The lowest hardware performance level corresponding to the candidate execution mode is lower than or equal to the hardware performance level of the POS device.

[0109] For example, the plurality of execution modes corresponding to the target action include the first execution mode, the second execution mode, the third execution mode, and the fourth execution mode. It is assumed that the lowest hardware performance levels respectively corresponding to the plurality of execution modes are as follows: The lowest hardware performance level corresponding to the first execution mode is L4, the lowest hardware performance level corresponding to the second execution mode is L3, the lowest hardware performance level corresponding to the third execution mode is LI, and the lowest hardware performance level corresponding to the fourth execution mode is L2. Hardware performance requirements of the plurality of lowest hardware performance levels are sorted as L4>L3>L2>L1 in descending order.

[0110] When the hardware performance of the POS device is L3, based on the above-mentioned sorting, a requirement of the first execution mode on the hardware performance level exceeds a hardware performance level of the POS device, and the POS device cannot execute the target action in the first execution mode. A requirement of the second execution mode on the hardware performance level is consistent with the hardware performance level of the POS device, and the POS device can execute the target action in the second execution mode. Requirements of the third execution mode and the fourth execution mode on thehardware performance level are lower than the hardware performance level of the POS device, and the POS device can execute the target action in the third execution mode or the fourth execution mode. Therefore, the POS device can separately determine the second execution mode, the third execution mode, and the fourth execution mode in the plurality of execution modes as candidate execution modes.

[0111] In some embodiments, after determining the at least one candidate execution mode, the POS device can determine a candidate execution mode corresponding to the highest lowest hardware performance level in the at least one candidate execution mode as the target execution mode. The above-mentioned embodiments are still used as an example for description. When the hardware performance of the POS device is L3, in the plurality of candidate execution modes (the second execution mode, the third execution mode, and the fourth execution mode), the second execution mode has the highest requirement on the lowest hardware performance level, and the second execution mode can be determined as the target execution mode.

[0112] In some embodiments, after determining the at least one candidate execution mode, the POS device can determine a candidate execution mode corresponding to the lowest lowest hardware performance level in the at least one candidate execution mode as the target execution mode. The above-mentioned embodiments are still used as an example for description. When the hardware performance of the POS device is L3, in the plurality of candidate execution modes (the second execution mode, the third execution mode, and the fourth execution mode), the third execution mode has the lowest requirement on the lowest hardware performance level, and the third execution mode can be determined as the target execution mode.

[0113] In some embodiments, a manner of determining the target execution mode can also be preset by the merchant on the POS device. For example, the merchant can preset one of the following: using the candidate execution mode corresponding to the lowest hardware performance level in the candidate execution mode as the target execution mode; or using the candidate execution mode corresponding to the highest hardware performance level in the candidate execution mode as the target execution mode.

[0114] In some embodiments, the POS device can obtain hardware information of the POS device in response to that a start instruction is detected, and determine the hardware performance level of the POS device based on the hardware information.

[0115] In some embodiments, a to-be-cleaned object in the POS device is cleaned in response to that the POS device meets a preset trigger condition, to release hardware resource occupation of the POS device by the to-be-cleaned object.

[0116] In a running process of the POS device, various to-be-cleaned objects such as temporary files and cache data are generated. If these objects are continuously accumulated, a large quantity of hardware resources such as memory and storage space, are occupied are occupied. When too much memory is occupied, a running speed of the POS device decreases clearly. For example, when a large amount of transaction data is processed, a lack of memory causes a transaction processing delay, and stuttering of the POS device. These to-be-cleaned objects are cleared to release memory, so that a POS end processes a subsequent transaction more quickly, to avoid a problem that the POS device does not respond.

[0117] In some embodiments, the trigger condition can include: a preset time interval is reached from a previous cleaning moment. That is, the POS device can clean the to-be-cleaned object in the POS device at the preset time interval. The to-be-cleaned object can include an inactive object that occupies a memory resource and a useless object that occupies a hard disk resource. For example, the to-be-cleaned object can be cache data, a log file, a temporary file, a residual file of software of an old version, etc. Cleaning of the to-be-cleaned object does not affect normal use of the POS device.

[0118] In some embodiments, the trigger condition can include: a hardware resource occupation rate is higher than a preset value. The POS device can detect a hardware resource occupation status of the POS device based on the preset time interval, to obtain a detection result. The detection result includes a hardware resource occupation rate of the POS device and a hardware resource occupation status of each object in the POS device. Further, the POS device can determine the to-be-cleaned object based on the hardware resource occupation status of each object in the detection result, and clean the to-be-cleaned object.

[0119] In such a cleaning manner, objects that actually occupy too many hardware resources can be cleaned accurately. Therefore, hardware resources are released more effectively, and excessive cleaning is avoided. For example, frequent cleaning of some cache data may cause the POS device to re-generate these caches in a subsequent running process, which increases load of the POS device. However, in the above-mentioned cleaning manner, this case can be avoided. Cleaning is performed only when the hardware resource occupation rate is too high, to balance a relationship between resource release and subsequent running efficiency of the POS device, so that performance optimization of the POS device is more reasonable and effective.

[0120] FIG. 6 is a schematic diagram of a process in which a POS device performs cleaning according to an embodiment of this specification. As shown in FIG. 6, a main thread and a sub-thread can be pre-deployed on the POS device. The main thread is configured to respond to the order management operation. When it is detected that the operator performs the order management operation on the POS device, the main thread responds to the order management operation. The sub-thread is configured to: detect the hardware resource occupation status, and execute a cleaning action. The sub-thread can execute the cleaning action periodically. As shown in FIG. 6, for example, if an execution period of the cleaning action is T, a moment at which the sub-thread executes the cleaning action can include Tl, T2, T3, T4, .... When the preset time interval (namely, T) is reached from a current moment to an execution moment of a previous cleaning action, the POS device executes the cleaning action through the sub-thread.

[0121] That is, in the above-mentioned embodiment, the main thread and the sub-thread each have a corresponding specific division of labor, and the main thread and the sub-thread do not affect each other and perform parallel execution. In a process in which a user performs the order management operation, the main thread can respond to the order management operation, and the sub-thread can detect and clean the to-be-cleaned object in the POS device. Therefore, the detection and cleaning action does not affect normal use of the POS device by the user, and the user is not aware of the detection and cleaning action of the POS device.

[0122] In some embodiments, a range of the to-be-cleaned object, a hardware resourceoccupation rate threshold, the preset time interval, etc. can be preset by the operator on the POS device. The operator can customize the range of the to-be-cleaned object. For example, the operator can select a plurality of target to-be-cleaned objects from a plurality of preset to-be-cleaned objects. Alternatively, the operator can autonomously enter the plurality of to-be-cleaned objects. In a subsequent running process of the POS device, when detecting that the preset trigger condition is met, the POS device can clean a preset target to-be-cleaned object.

[0123] In some embodiments, the POS device can report statistical data such as an actual running status and the hardware resource occupation status of the POS device to the service device. After analyzing the statistical data, the service device determines a cleaning rule. The cleaning rule can represent the range of the to-be-cleaned object, the hardware resource occupation rate threshold, the preset time interval, etc. In this way, the POS device can execute the cleaning action based on the cleaning rule.

[0124] In some embodiments, for example, the service device can obtain the actual running status of the service device and a hardware resource occupation status in each time period periodically, for example, every day / every week / every month, and analyze and count the actual running status of the service device. Further, the service device determines, based on a statistical result, whether to update the cleaning rule. If the statistical result indicates that the cleaning rule needs to be updated, the service device delivers the updated cleaning rule to the POS device. If the statistical result indicates that the cleaning rule does not need to be updated, the service device does not need to send the cleaning rule to the POS device. The POS device performs cleaning based on a currently existing cleaning rule. In the above-mentioned manner, the service device determines a more reasonable cleaning rule for the POS device based on the actual running status of the POS device, so that a cleaning effect can be improved. In addition, the service device sends an updated cleaning rule to the POS device only when the cleaning rule is updated, to reduce resource occupation caused by repeatedly sending the cleaning rule.

[0125] In some embodiments, the trigger condition can include: the cleaning instruction is received from the service device. The cleaning instruction can include the to-be-cleaned object. In this case, the POS device can obtain the to-be-cleaned object from the cleaning instruction, and clean the to-be-cleaned object.

[0126] FIG. 7 is a schematic diagram of another process in which a POS device performs cleaning according to an embodiment of this specification. As shown in FIG. 7, the POS device can detect the hardware resource occupation status of the POS device in response to that a query instruction is received from the service device, to obtain the detection result. The detection result includes the hardware resource occupation rate of the POS device and the hardware resource occupation status of each object in the POS device. After receiving the detection result, the service device analyzes the detection result, to generate the cleaning instruction. If the service device determines, after analyzing the detection result, that the POS device currently needs to perform data cleaning, the service device sends the cleaning instruction to the POS device. After receiving the cleaning instruction, the POS device cleans the to-be-cleaned object based on the cleaning instruction. If the service device determines, after analyzing the detection result, that the POS device does not need to perform data cleaning currently, the service device can send, to thePOS device, an instruction indicating that data cleaning does not need to be performed, or does not send any instruction to the POS device.

[0127] In conclusion, the device running method provided in this specification can be implemented by order management software and performed by a POS device installed with the order management software. When detecting the order management operation, the POS device determines a to-be-executed target action, and executes the target action in the target execution mode adapted to the hardware performance of the POS device in the plurality of execution modes corresponding to the target action, to respond to the order management operation. The above-mentioned solution can reduce a requirement of the order management software on hardware performance of the POS device, so that the order management software can support running on any hardware device. That is, the order management software can run on a hardware device with relatively high performance, or can run on a hardware device with relatively low performance. In this way, the merchant can use an order management service by installing the order management software on an existing hardware device. The merchant does not need to purchase a hardware device again, to reduce operating costs of the merchant. In addition, the above-mentioned solution further enables a one- stop order management service to be applied to more merchants, to improve application universality.

[0128] Further, in the above-mentioned solution, the POS device can further clean the to-be-cleaned object of the POS device when detecting that the preset trigger condition is met, to ensure smoothness in a use process of the POS device. In this way, even if the order management software is installed on a POS device with relatively low hardware performance, the order management software can run normally, and has a relatively high operation procedural nature.

[0129] Another aspect of this specification provides a computer-readable non-transitory storage medium. The computer-readable non-transitory storage medium stores at least one instruction set. When the at least one instruction set is executed by a processor, the at least one instruction set instructs the processor to implement the steps of the device running method in this specification. In some possible implementations, aspects of this specification can further be implemented in a form of a program product, including program code. When the program product runs on the POS device, the program code is used to enable the POS device to perform the steps of the device running method described in this specification. The program product configured to implement the above-mentioned method can be a portable compact disc read-only memory (CD-ROM) that includes program code, and can run on the POS device. However, the program product in this specification is not limited thereto. In this specification, a readable storage medium can be any tangible medium that includes or stores a program, and the program can be used by or in combination with an instruction execution system. The program product can be any combination of one or more readable media. The readable medium can be a readable signal medium or a readable storage medium. The readable storage medium can be, for example, an electrical system, apparatus, or device, a magnetic system, apparatus, or device, an optical system, apparatus, or device, an electromagnetic system, apparatus, or device, an infrared system, apparatus, or device, or a semiconductor system, apparatus, or device, or any combination thereof. More specific examples of the readable storage medium include: an electrical connection1including one or more conducting wires, a portable disk, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disc read-only memory (CD-ROM), an optical storage component, a magnetic storage component, or any proper combination thereof. The computer-readable storage medium can include a data signal propagated in a baseband or as part of a carrier, and carries readable program code. The propagated data signal can be in a plurality of forms, and includes but is not limited to an electromagnetic signal, an optical signal, or any proper combination thereof. The readable storage medium can further be any readable medium other than the readable storage medium, and the readable medium can be used to send, propagate, or transmit a program used by or in combination with an instruction execution system, apparatus, or component. The program code included in the readable storage medium can be transmitted in any proper medium, including but not limited to a wireless medium, a wired medium, optical cable, an RF medium, or any proper combination thereof. Program code for performing an operation of this specification can be written in any combination of one or more program design languages. The program design language includes an object-oriented program design language, for example, Java or C++, and further includes a conventional procedural program design language, for example, "C" language, or a similar program design language.

[0130] Specific embodiments of this specification are described above. Other embodiments fall within the scope of the appended claims. In some cases, the actions or steps described in the claims can be performed in an order different from that in the embodiments, and the desired results can still be achieved. In addition, the process depicted in the accompanying drawings does not necessarily need a particular order or consecutive order to achieve the desired results. In some implementations, multitasking and parallel processing are possible or may be advantageous.

[0131] In conclusion, after reading the detailed disclosure, a person skilled in the art can understand that the detailed disclosure can be presented only in an example manner, and can impose no limitation. Although it is not explicitly stated here, a person skilled in the art can understand that the requirements of this specification include various proper changes, improvements, and modifications to the embodiments. These changes, improvements, and modifications are intended to be presented in this specification, and fall within the spirit and scope of the example embodiments of this specification.

[0132] In addition, some terms in this specification are used to describe the embodiments of this specification. For example, "one embodiment", "an embodiment", and / or "some embodiments" mean that particular features, structures, or characteristics described with reference to the embodiments can be included in at least one embodiment of this specification. Therefore, it can be emphasized and understood that two or more of "an embodiment", "one embodiment", or "alternative embodiments" referred in parts of this specification do not necessarily indicate the same embodiment. In addition, particular features, structures, or characteristics can be properly combined in one or more embodiments of this specification.

[0133] It should be understood that in the above-mentioned descriptions of the embodiments of this specification, to help understand a feature, for the purpose of simplifying thisspecification, various features are combined in a single embodiment, accompanying drawing, or description thereof in this specification. However, this does not mean that the combination of these features is necessary. It is entirely possible for a person skilled in the art to mark some devices and understand the devices as separate embodiments when reading this specification. In other words, the embodiments in this specification can also be understood as an integration of a plurality of secondary embodiments. Content of each secondary embodiment is also true when features are less than all features in one of the above-mentioned disclosed embodiments.

[0134] Each patent, patent application, publication of the patent application, and other materials, for example, articles, books, specification, publications, documents, literature, etc. (excluding any historical examination documents related thereto) that are cited in the present disclosure are incorporated by reference for all purposes related to the present disclosure, such as in the description and claims of the present disclosure. However, if there is any inconsistency or conflict between the description, definition, and / or term of the above-mentioned material and use of the description, definition, and / or term in the present disclosure, the description, definition, and / or terminology used in the present disclosure shall prevail.

[0135] Finally, it should be understood that the principles of the implementation solutions of this specification are described in the implementation solutions of the application disclosed in this specification. Other modified embodiments also fall within the scope of this specification. Therefore, the embodiments disclosed in this specification are merely examples and not limitations. A person skilled in the art can use an alternative configuration according to the embodiments of this specification to implement the application in this specification. Therefore, the embodiments of this specification are not limited to the embodiments accurately described in the application.

Claims

CLAIMSWhat is claimed is:

1. A device running method, applied to a POS device in an order management system, wherein the method comprises:determining a to-be-executed target action in response to an order management operation executed by an operator in an interaction interface of the POS device, wherein the target action corresponds to a plurality of execution modes, and the POS device consumes different quantities of hardware resources when executing the target action in different execution modes; and determining a target execution mode adapted to hardware performance of the POS device in the plurality of execution modes of the target action, and executing the target action in the target execution mode to respond to the order management operation.

2. The method according to claim 1, wherein the order management system further comprises a service device, and the plurality of execution modes comprise at least two of the following:a first execution mode, representing that the POS device executes the target action;a second execution mode, representing that the POS device executes a simplified action corresponding to the target action, wherein an amount of data that needs to be processed when the POS device executes the simplified action is less than an amount of data that needs to be processed when the POS device executes the target action;a third execution mode, representing that the service device executes the target action; and a fourth execution mode, representing that the POS device executes a part of content of the target action, and the service device executes the other part of the target action.

3. The method according to claim 1, wherein the determining a target execution mode adapted to hardware performance of the POS device in the plurality of execution modes of the target action comprises:obtaining a hardware performance level of the POS device, and obtaining a lowest hardware performance level corresponding to each of the plurality of execution modes; and determining the target execution mode adapted to the hardware performance of the POS device in the plurality of execution modes based on the hardware performance level of the POS device and the lowest hardware performance level corresponding to each of the plurality of execution modes.

4. The method according to claim 3, wherein the method further comprises:obtaining hardware information of the POS device in response to that a start instruction is detected, and determining the hardware performance level of the POS device based on the hardware information.

5. The method according to claim 3, wherein the determining the hardware performance level of the POS device based on the hardware information comprises:determining at least one candidate execution mode in the plurality of execution modes based on the hardware performance level of the POS device and the lowest hardware performance level corresponding to each of the plurality of execution modes, wherein a lowesthardware performance level corresponding to the candidate execution mode is lower than or equal to the hardware performance level of the POS device; anddetermining the target execution mode in the at least one candidate execution mode.

6. The method according to claim 5, wherein the determining the target execution mode in the at least one candidate execution mode comprises:determining a candidate execution mode corresponding to a highest lowest hardware performance level in the at least one candidate execution mode as the target execution mode.

7. The method according to claim 1, wherein the method further comprises:cleaning a to-be-cleaned object in the POS device in response to that the POS device meets a preset trigger condition, to release hardware resource occupation of the POS device by the to-be-cleaned object.

8. The method according to claim 7, wherein the method further comprises:detecting a hardware resource occupation status of the POS device based on a preset time interval, to obtain a detection result, wherein the detection result comprises a hardware resource occupation rate of the POS device and a hardware resource occupation status of each object in the POS device, whereinthe trigger condition comprises: the hardware resource occupation rate is higher than a preset value; andthe cleaning a to-be-cleaned object in the POS device comprises: determining the to-be-cleaned object based on the hardware resource occupation status of each object in the detection result, and cleaning the to-be-cleaned object.

9. The method according to claim 7, wherein a main thread and a sub-thread are deployed on the POS device, and the main thread is configured to respond to the order management operation; andthe cleaning a to-be-cleaned object in the POS device comprises: cleaning the to-be-cleaned object in the POS device through the sub-thread.

10. The method according to claim 7, wherein the to-be-cleaned object comprises at least an inactive object that occupies a memory resource and a useless object that occupies a hard disk resource.

11. The method according to claim 7, wherein the order management system further comprises a service device, the trigger condition comprises: a cleaning instruction is received from the service device, and the cleaning instruction comprises the to-be-cleaned object; and the cleaning a to-be-cleaned object in the POS device comprises: obtaining the to-be-cleaned object from the cleaning instruction, and cleaning the to-be-cleaned object.

12. The method according to claim 11, wherein the method further comprises: detecting a hardware resource occupation status of the POS device in response to that a query instruction is received from the service device, to obtain a detection result, wherein the detection result comprises a hardware resource occupation rate of the POS device and a hardware resource occupation status of each object in the POS device; andsending the detection result to the service device, so that the service device analyzes the detection result, to generate the cleaning instruction.

13. A terminal device, serving as a POS device in an order management system, and comprising:at least one storage medium, storing at least one instruction set, to perform device running; andat least one processor, communicatively connected to the at least one storage medium, wherein when running, the at least one processor reads the at least one instruction set, and performs the following operations based on an indication of the at least one instruction set:determining a to-be-executed target action in response to an order management operation executed by an operator in an interaction interface of the POS device, wherein the target action corresponds to a plurality of execution modes, and the POS device consumes different quantities of hardware resources when executing the target action in different execution modes; and determining a target execution mode adapted to hardware performance of the POS device in the plurality of execution modes of the target action, and executing the target action in the target execution mode to respond to the order management operation.

14. The terminal device according to claim 13, wherein the order management system further comprises a service device, and the plurality of execution modes comprise at least two of the following:a first execution mode, representing that the POS device executes the target action;a second execution mode, representing that the POS device executes a simplified action corresponding to the target action, wherein an amount of data that needs to be processed when the POS device executes the simplified action is less than an amount of data that needs to be processed when the POS device executes the target action;a third execution mode, representing that the service device executes the target action; and a fourth execution mode, representing that the POS device executes a part of content of the target action, and the service device executes the other part of the target action.

15. The terminal device according to claim 13, wherein to determine the target execution mode adapted to the hardware performance of the POS device in the plurality of execution modes of the target action, the at least one processor performs the following operations:obtaining a hardware performance level of the POS device, and obtaining a lowest hardware performance level corresponding to each of the plurality of execution modes; and determining the target execution mode adapted to the hardware performance of the POS device in the plurality of execution modes based on the hardware performance level of the POS device and the lowest hardware performance level corresponding to each of the plurality of execution modes.

16. The terminal device according to claim 15, wherein the at least one processor performs the following operations:obtaining hardware information of the POS device in response to that it is detected that the POS device is started upon startup, and determining the hardware performance level of the POS device based on the hardware information.

17. The terminal device according to claim 15, wherein to determine the target execution mode adapted to the hardware performance of the POS device in the plurality of executionmodes based on the hardware performance level of the POS device and the lowest hardware performance level corresponding to each of the plurality of execution modes, the at least one processor performs the following operations:determining at least one candidate execution mode in the plurality of execution modes based on the hardware performance level of the POS device and the lowest hardware performance level corresponding to each of the plurality of execution modes, wherein a lowest hardware performance level corresponding to the candidate execution mode is lower than or equal to the hardware performance level of the POS device; anddetermining the target execution mode in the at least one candidate execution mode.

18. The terminal device according to claim 17, wherein to determine the target execution mode in the at least one candidate execution mode, the at least one processor performs the following operation:determining a candidate execution mode corresponding to a highest lowest hardware performance level in the at least one candidate execution mode as the target execution mode.

19. A computer-readable non-transitory storage medium, wherein the computer-readable non-transitory storage medium stores at least one instruction set, and when the at least one instruction set is executed by at least one processor, the method according to any one of claims 1 to 12 is implemented.

20. An order management system, comprising:a POS device, configured to perform the method according to any one of claims 1 to 12; anda service device, communicatively connected to the POS device, and configured to provide a service for the POS device.