Cross-platform payment method
By obtaining user identity information on the WeChat ordering interface and generating Alipay short string password, the problems of poor user experience and data security risks of existing cross-platform payment methods are solved, and the seamless connection between abnormal payments when placing an order by WeChat mini-programs is achieved, improving payment efficiency and user experience.
Patent Information
- Application Number
- CN202510522409.8
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-04-24
- Publication Date
- 2025-05-27
AI Technical Summary
The existing cross-platform payment methods have poor user experience, cumbersome operations, and have high error rates and data security risks.
By silently obtaining user identity information on the WeChat ordering interface, generating Alipay short string password, and jumping directly to Alipay through payment trigger link or app message notification, avoiding manual copy and pasting operations.
It realizes the seamless connection between abnormal payments when placing an order by WeChat mini program and Alipay payment, which improves payment efficiency and user experience, and reduces error rate and data security risks.
Smart Images

Figure CN120047144A_ABST
Abstract
Description
Technical Field
[0001] The present invention belongs to the technical field of network payment, and particularly relates to a cross-platform payment method. Background Art
[0002] In the scenario of user ordering and payment, users usually order and pay by scanning QR codes. Alipay users can sign up for automatic deduction through the main-scan scenario, that is, after the user confirms on the mobile device, they can enjoy the service first and then make the payment.
[0003] However, since the main traffic of user QR code scanning for ordering is on the WeChat side, and WeChat and Alipay are two independent payment platforms with their own independent payment systems, account systems, and technical architectures, and there is no direct interoperability between these two systems. Therefore, after scanning the QR code on WeChat for ordering, it is impossible to directly use Alipay for payment, resulting in an interoperability obstacle.
[0004] As competitors, WeChat and Alipay each have their own commercial interests and market strategies. They may be reluctant to open their payment systems for use by other competitors out of consideration for protecting their own market shares and user stickiness. In the current WeChat APP scenario, users cannot directly use Alipay to complete the confirmation and payment actions.
[0005] In addition, in some WeChat ordering and payment scenarios, more options can be popped up by clicking on the upper right corner, and then the payment link (or QR code) can be manually copied. The user then switches to the Alipay APP through operations, or opens a browser, and Alipay automatically recognizes the payment link for payment. This method has many disadvantages: First, poor user experience: users need to manually copy the payment link or QR code and switch to another APP for payment, which is a cumbersome operation.
[0006] Second, high error rate: errors are likely to occur during the manual copy and paste process, resulting in payment failure.
[0007] Third, low payment efficiency: the entire payment process takes a long time, reducing the payment efficiency.
[0008] Fourth, there is a data security risk: other APPs may have the permission to read the clipboard data, and manual copy and paste may increase the risk of data leakage. Summary of the Invention
[0009] In view of the above problems, the purpose of the present invention is to provide a cross-platform payment method, aiming to solve the technical problems of poor user experience, cumbersome operation, and high error rate in existing cross-platform payment methods.
[0010] The present invention adopts the following technical solutions: The cross-platform payment method includes the following steps: Step S1: After scanning the code to enter the WeChat meal ordering interface, locate the specific merchant name and store according to the configuration information, and silently obtain the user identity information, including the user's mobile phone number and the user's unique identifier OpenID on the WeChat side; Step S2: After completing the meal ordering selection and confirmation on the front-end page, generate business order information, which includes the user identity information, and upload it to the meal ordering system server. When a WeChat payment request is initiated, check whether there is a payment exception; Step S3: When payment exception information is captured, generate an Alipay short string password through the double-scale compression algorithm based on the current business order information, and locate whether there is an associated Alipay user binding and Alipay message authorization according to the member concatenation information; Step S41: If there is no associated binding and message authorization, generate a payment trigger link. After the user clicks it, the local Alipay application will be automatically opened for associated binding and message authorization, and then the Alipay short string password in it will be parsed, and the short string password will be further decrypted to restore the business order information, and at the same time, Alipay authorization will be completed; Step S42: If there is an associated binding and message authorization, send an app message notification through the Alipay message box. After the user receives the Alipay app message notification and clicks on the message notification, the local Alipay application will be automatically awakened and the Alipay short string password in it will be parsed, and then the short string password will be further decrypted to restore the business order information, and at the same time, Alipay authorization will be completed; Step S5: According to the merchant information corresponding to the current business order, judge whether there is a matching Alipay mini program; Step S6: If there is a matching Alipay mini program, call the Alipay mini program, import the business order information and generate a payment interface. After the user confirms the payment, complete the payment deduction by calling the Alipay cashier desk, and associate and store the user's mobile phone number, OpenID with the userid of the current user of the Alipay mini program in the marketing system; Step S7: On the Alipay side, automatically retrieve the business order information managed by the mobile phone number corresponding to the userid from the marketing system, and then update the user data accordingly; on the WeChat side, automatically retrieve the business order information managed by the mobile phone number corresponding to the OpenID from the marketing system, and also update the user data accordingly, so that the user data on the Alipay side and the WeChat side are synchronized and updated to be consistent; Step S8: If there is no matching Alipay mini program, directly jump to a neutral public simplified Alipay cashier desk page to display the collection amount. After the user confirms the payment, complete the payment deduction by calling the Alipay cashier desk, and the payment result is synchronously displayed on the Alipay interface, and at the same time, the payment information of the business order is asynchronously updated; Step S9: When the payment is completed on the Alipay side, the WeChat side will poll the payment result, and when the payment is completed on the Alipay side and the result is viewed on the WeChat side, the correct payment information will also be displayed. At the same time, after the payment is completed, the user data will be updated in the marketing system.
[0011] Further, the specific process of step S1 is as follows: S11: For first-time users, when scanning the code to order food, request authorization to obtain the user's mobile phone number information, and obtain the mobile phone number information after getting authorization; S12: Each time when scanning the WeChat code to order food, the order code contains the differentiated configuration information of the merchant and the store. After scanning the code, the specific merchant and store can be quickly located according to the differentiated configuration information and the content will be displayed; S13: When entering the food ordering interface, WeChat redirects to the specified callback uniform resource locator URL, with a temporary code parameter attached. The temporary code parameter is sent to the food ordering system server. According to the API interface provided by the server and the application number AppID and developer password appsecret of the food ordering applet, an access token access_token is generated, and finally the OpenID is obtained. At the same time, the OpenID is associated with the user's mobile phone number.
[0012] Further, the specific process of step S2 is as follows: S21: After the user selects and completes food ordering and confirmation on the front-end page, generate business order information and upload it to the food ordering system server in real time for pre-production of business transaction order information; S22: When selecting WeChat payment on the interface, initiate a payment request to the upstream WeChat payment system according to the order amount, type, merchant configuration and user identity information of the current business order information; S23: The WeChat payment system verifies the order information and order rationality and returns the necessary parameters required by the WeChat payment control; S24: When the WeChat payment system is processing, check whether there is a payment exception. Payment exceptions include mismatching of merchant number and AppID, mismatching of OpenID and AppID, non-binding relationship between the official account and the merchant number, WeChat not being authenticated, and insufficient balance. If a payment exception occurs, an exception code message will be returned.
[0013] Further, the specific process of step S3 is as follows: S31: Capture payment exception information by listening to the exception code message. When a payment exception is identified, the current business order information is generated into a short string password that can be recognized by Alipay in the format of an Alipay password using the double-scale compression algorithm. The short string password is unique and marked with an expiration time. When the expiration time is reached, the short string password will be automatically destroyed; S32. Check whether there is an associated Alipay user binding and Alipay message authorization for the current user on the WeChat side according to the member connection information in the marketing system.
[0014] Further, in step S41, if there is no associated binding and message authorization, then according to the message encapsulation rule, a payment trigger link is generated and displayed on the current page. The payment trigger link includes a short string password and a local Alipay payment call interface. After the user clicks the payment trigger link, the local Alipay application is automatically opened for the associated binding and message authorization operation.
[0015] Further, in step S42, if there is an associated binding and message authorization, then an app message notification containing the short string password is directly popped up at the top of the interface through the Alipay message box. When the user directly clicks on this app message notification on the interface, the local Alipay application is automatically awakened.
[0016] Further, after obtaining the Alipay authorization, extract the merchant information in the business order and combine it with the application number to identify whether there is also a matching Alipay mini program for the current merchant in Alipay.
[0017] Further, in step S6, the process of importing the business order information and generating the payment interface is as follows: Extract the order data from the business order information, including the dish name, quantity, unit price, total dish amount, and discount amount, and then perform data matching according to the Alipay order template to generate a new Alipay business order, and generate a payment interface containing the content of the Alipay business order according to a fixed display mode.
[0018] The beneficial effect of the present invention is that the present invention realizes seamless connection and optimization of the process of placing an order through a WeChat mini program and switching to Alipay payment when there is a payment exception.
[0019] In a specific solution, first, when WeChat Mini Program fails to perform WeChat payment after placing an order for food, a payment trigger link is generated in the form of a short string password or an app message notification is generated, without copying data to the clipboard, so as to avoid data security problems caused by third-party applications obtaining clipboard permissions; second, through the payment trigger link and app message notification, it is possible to directly jump to Alipay for payment processing, without the user having to go back to the desktop to open the Alipay application, making the operation simpler; third, when making an Alipay payment, according to whether the merchant has also opened the corresponding Alipay Mini Program in Alipay, the payment is divided into two methods. If there is a matching Mini Program, the payment can be directly completed in the Alipay Mini Program and the user data can be synchronized; if there is no matching Mini Program, only the neutral public simplified version of the Alipay cashier page displays the collection amount, completing the Alipay payment and data update; fourth, when both the WeChat side and the Alipay side have Mini Programs, by internally connecting the authorization links of WeChat and Alipay, different-step processing of orders, sharing and association of user data are realized, improving the user experience. BRIEF DESCRIPTION OF THE DRAWINGS
[0020] Figure 1 is a flowchart of the cross-platform payment method provided by an embodiment of the present invention. DETAILED DESCRIPTION OF THE EMBODIMENTS
[0021] In order to make the objectives, technical solutions and advantages of the present invention clearer, the present invention will be further described in detail below with reference to the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are only used to explain the present invention and are not used to limit the present invention.
[0022] In order to illustrate the technical solutions described in the present invention, the following will be described through specific embodiments.
[0023] As Figure 1 shown, the cross-platform payment method provided in this embodiment includes the following steps: Step S1: After scanning the code to enter the WeChat food ordering interface, locate the specific merchant name and store according to the configuration information, and at the same time silently obtain the user identity information, including the user's mobile phone number and the user's unique identifier OpenID on the WeChat side.
[0024] In the era of mobile payment, it has become a normal state for users to place orders for food in the WeChat APP. Generally, they scan the food ordering code with WeChat to enter the merchant's food ordering Mini Program to place orders for food and make payments. The problem solved by the embodiment of the present invention is how to make a payment through Alipay when there is a problem with WeChat payment after ordering food on WeChat. In order to ensure the accuracy of user identity and the subsequent association and update of user data, this step silently obtains the user's identity information. The specific process is as follows: S11. For first-time users, when scanning the code to place an order, request authorization to obtain the user's mobile phone number information, and obtain the mobile phone number information after getting authorization.
[0025] When a user places an order for the first time, WeChat needs to give permission. The mobile phone number is important information for the user's account. WeChat requires real-name authentication. The mobile phone number is associated with WeChat. When placing an order for the first time on the WeChat side, the mini-program will request authorization to obtain the user's mobile phone number information and use it as the membership identity of the current user in the merchant's order-taking mini-program to distinguish different users. The mobile phone number is also the basis for member association.
[0026] S12. Each time when scanning the WeChat code to place an order, the order-scanning code contains the differentiated configuration information of the merchant and the store. After scanning the code, quickly locate the specific merchant and store according to the differentiated configuration information and display the content.
[0027] When the user scans the code and enters the order-taking page, since the code contains the differentiated configuration information of the merchant and the store, it can quickly locate the specific merchant and store after scanning the code and display it on the interface. Subsequently, after the user selects the order-taking information on the mobile front-end page, the business order information will be transmitted to the order-taking system server in real time.
[0028] S13. When entering the order-taking interface, WeChat redirects to the specified callback uniform resource locator URL, with a temporary code parameter attached. Send the temporary code parameter to the order-taking system server, generate an access token access_token according to the API interface provided by the server, the application number AppID of the order-taking mini-program, and the developer password appsecret. Finally, obtain the OpenID, and at the same time associate the OpenID with the user's mobile phone number.
[0029] Each time the user uses it, the OpenID information within the WeChat system can be obtained through the WeChat temporary code. The OpenID is the unique identifier of the user in the official account or mini-program, used to identify the user's identity in a specific application. The same user will have different OpenIDs in different official accounts or mini-programs. Developers can obtain the user's OpenID through user authorization and use it in subsequent business logics.
[0030] The user needs to authorize the application to access their basic information in WeChat, which is achieved through an OAuth2.0 authorization process. After the user agrees to authorize, WeChat will redirect to the specified callback URL with a temporary code parameter attached. This temporary code parameter is sent to the server of the food ordering system. The server generates a unique appSecret (developer password) for each calling end and stores it on the server to generate an access token (access token), and then obtains the user's access token and OpenID. This realizes the association of the OpenID with the user's mobile phone number, facilitating subsequent user identification and services.
[0031] Step S2: After the user completes the food ordering selection and confirmation on the front-end page, generate business order information, which includes user identity information, and upload it to the server of the food ordering system. When a WeChat payment request is initiated, check whether there is a payment exception.
[0032] In actual operation, due to the complexity of merchant WeChat payment parameter configuration and the uncertainty of user balance, various exception errors may occur during the payment process. For example, the sub_mch_id (merchant number) does not match the sub_AppID (merchant's food ordering mini-program application number), the OpenID and AppID do not match, there is no binding relationship between the official account and the merchant number, WeChat is not authenticated, the balance is insufficient, etc. These problems not only affect the user's payment experience but also bring unnecessary troubles to the merchant. In this step, when receiving a WeChat payment request, check whether there is a payment exception. The specific process is as follows: S21: After the user selects, completes the food ordering, and confirms on the front-end page, generate business order information and upload it to the server of the food ordering system in real time for pre-generation of business transaction order information; S22: When selecting WeChat payment on the interface, initiate a payment request to the upstream WeChat payment system based on the order amount, type, merchant configuration, and user identity information of the current business order information; S23: The WeChat payment system verifies the order information and order rationality and returns the necessary parameters required by the WeChat payment control; S24: During the processing of the WeChat payment system, check whether there is a payment exception, such as the merchant number not matching the AppID, the OpenID not matching the AppID, there is no binding relationship between the official account and the merchant number, etc. If a payment exception occurs, return an exception code message.
[0033] Step S3: When capturing payment exception information, generate an Alipay short string password according to the current business order information through a double-scale compression algorithm, and locate whether there is an associated Alipay user binding and Alipay message authorization according to the member concatenation information.
[0034] If there is no payment anomaly, normal WeChat payment is carried out. When the user finds that the WeChat payment cannot be completed, the traditional way is to manually operate to enter more options, select to copy the link, copy the link data to the clipboard, and then manually switch the payment method to reopen the Alipay APP, and Alipay is used to identify the link content and guide the subsequent payment. If there is also a corresponding merchant mini-program in Alipay, it can also prompt to switch to Alipay to rescan the code and reselect the food and place an order again. The process is cumbersome and time-consuming.
[0035] This step introduces the Alipay password mechanism. When a payment anomaly is found, the business order information can be used to generate an Alipay short string password processed by the double-scale compression algorithm through the API of the server. It is not easily recognizable by a third party. This password is unique and set with an expiration time, which has uniqueness and security to ensure the security and accuracy of the payment process.
[0036] Specifically, the process of this step is as follows: S31. Capture payment anomaly information by listening to the anomaly code message. After identifying the payment anomaly, use the double-scale compression algorithm to generate an Alipay-recognizable short string password in the Alipay password format for the current business order information. The short string password is unique and marked with an expiration time. When the expiration time is reached, the short string password is automatically destroyed; S32. According to the member concatenation information of the marketing system, check whether there is an associated Alipay user binding and Alipay message authorization for the current user on the WeChat side.
[0037] The member concatenation information refers to the integration and association of user member information or resources in the marketing system in some ways to facilitate better management and utilization of this information. It is generally used for member management in the marketing system. By concatenating the basic information, consumption records, and points situation of members, etc., unified management and maintenance of members can be achieved. According to the member concatenation information, it can be known whether the current user has a bound Alipay and message authorization.
[0038] Step S41. If there is no associated binding and message authorization, generate a payment trigger link. After the user clicks it, the local Alipay application will be automatically opened for associated binding and message authorization, and then the Alipay short string password in it will be parsed, and the short string password will be further decrypted to restore the business order information, and at the same time, Alipay authorization will be completed.
[0039] Step S42: If there is associated binding and message authorization, send an app message notification through the Alipay message box. After the user receives the Alipay app message notification and clicks on the message notification, the local Alipay application will be automatically awakened and the Alipay short string password in it will be parsed. Then, the short string password will be further decrypted to restore the business order information, and at the same time, Alipay authorization will be completed.
[0040] In this step, if there is no associated binding and message authorization, according to the message encapsulation rule, a payment trigger link will be generated and displayed on the current page (for example, the payment trigger link will be displayed in the form of the Dynamic Island). The payment trigger link includes a short string password and the local Alipay payment call interface. After the user clicks on the payment trigger link, the local Alipay application will be automatically opened, and the user can perform subsequent associated binding and message authorization operations. Generally, when using this function for the first time, Alipay binding and authorization are required.
[0041] In this step, the action is executed in the form of a software plug-in to generate the payment trigger link, or an app message notification is sent in the form of the Alipay message box. The operation can be directly clicked without manual link copying. The display form of the payment trigger link is in the form of the Dynamic Island, and the app message notification is a horizontal notification message that pops up at the top of the interface. Therefore, the Alipay application can be called directly by clicking on the notification message or the Dynamic Island link, greatly simplifying the user's operation steps and improving the convenience of payment.
[0042] When the current front-end page is opened, the password is identified according to the algorithm, which is efficient and accurate. The short string password is parsed and decrypted, and the business order information will be restored. Alipay authorization will be completed when in use.
[0043] Step S5: According to the merchant information corresponding to the current business order, determine whether there is a matching Alipay mini program.
[0044] The matching Alipay mini program here refers to that the merchant has also published the same ordering mini program on the Alipay platform. After obtaining Alipay authorization, the merchant information in the business order is extracted and combined with the application number to identify whether there is also a matching Alipay mini program for the current merchant in Alipay.
[0045] Step S6: If there is a matching Alipay mini program, call the Alipay mini program, import the business order information and generate a payment interface. When the user confirms the payment, complete the payment deduction by calling the Alipay cashier desk, and associate and store the user's mobile phone number, OpenID with the userid of the current user of the Alipay mini program in the marketing system.
[0046] If there is a matching mini program, in this embodiment, the Alipay mini program is directly triggered, and the business order information is imported and a payment interface is generated, eliminating the need for the user to repeat the order placement, thus improving convenience. During operation, order data is extracted from the business order information, including the dish name, quantity, unit price, total dish amount, discount amount, etc. Then, data matching is performed according to the Alipay order template to generate a new Alipay business order, and a payment interface containing the content of the Alipay business order is generated according to a fixed display mode.
[0047] After the user completes the payment on the Alipay interface (if the user's mobile phone supports fingerprint or face recognition payment functions, the payment process will be more convenient and efficient), in order to synchronize the information with the WeChat side, the membership information of the mobile phone number corresponding to this order will be automatically detected, and the mobile phone number, OpenID, and userid will be stored in the marketing system. This realizes the interconnection and sharing of membership information and also provides the basic ability for subsequent sharing and mutual use of coupons and points among members.
[0048] It should be noted that OpenID is the user identification code in the WeChat ecosystem, and userid is the identification number in Alipay and some other platform systems, uniquely identifying the user. AppID is the unique identification code assigned by the third-party platform to the application, used to identify the application during the development process.
[0049] Step S7: On the Alipay side, automatically retrieve the business order information managed by the mobile phone number corresponding to the userid from the marketing system, and then correspondingly update the user data; on the WeChat side, automatically retrieve the business order information managed by the mobile phone number corresponding to the OpenID from the marketing system, and also correspondingly update the user data, so that the user data on the Alipay side and the WeChat side is synchronously updated and kept consistent.
[0050] The order information in the WeChat and Alipay scenarios needs to be synchronously updated with the support of the user membership information big data ability of the marketing system. The WeChat side will automatically retrieve the order information managed by the mobile phone number corresponding to the OpenID; if there is no order information managed by the mobile phone number, the order information with only the OpenID will be loaded. Similarly, the Alipay side will also automatically retrieve the order information managed by the mobile phone number corresponding to the userid; if there is no order information managed by the mobile phone number, the order information with only the userid will be loaded. This realizes the interconnection of membership information and the synchronous update of business orders in the WeChat and Alipay APPs at both ends, and also improves the user's payment experience and the business operation efficiency of merchants. During the peak dining period, this optimized process can significantly shorten the waiting time of users, increase the turnover rate of merchants, thereby reducing the business operation cost of merchants and increasing the transaction volume.
[0051] Step S8: If there is no matching Alipay mini program, directly jump to a neutral public simplified Alipay cashier page to display the collection amount. After the user confirms the payment, call the Alipay cashier to complete the payment deduction. The payment result is synchronously displayed on the Alipay interface, and at the same time, the payment information of the business order is asynchronously updated.
[0052] Step S9: When the payment is completed on the Alipay side, the WeChat side will poll the payment result, and when returning to the WeChat side to view after the payment is completed on the Alipay side, the correct payment information will also be displayed. At the same time, after the payment is completed, the user data is updated in the marketing system.
[0053] If there is no matching Alipay mini program, only open a neutral public simplified Alipay cashier page to display the collection amount, and the user can make an Alipay payment. Since there is a mutex lock between the business order payment behavior and the Alipay payment behavior in WeChat, they cannot be paid simultaneously. After the Alipay payment is successful, WeChat polls to obtain the payment result. When it is known that the payment is successful, the user data is updated in the marketing system, such as the user's points, consumption records, etc.
[0054] In summary, since the current traffic of online food ordering is mainly on the WeChat side, although some merchants have also launched food ordering mini programs on the Alipay side. When users scan the code to order food on WeChat and encounter payment exceptions, such as information mismatch, insufficient amount, or WeChat payment not enabled, WeChat generally gives corresponding reminders, and users need to switch to Alipay to re-order food, resulting in a very poor experience. For this problem in the present invention, through the form of generating a payment trigger link or an app message notification, clicking on it will automatically jump to Alipay. If there is a matching food ordering Alipay mini program, it can import the current business order into the Alipay food ordering mini program for payment and synchronize the user data, and the user does not need to place a new order, providing a better experience. Moreover, the data in the form of a password will not be copied to the clipboard, avoiding the risk of being read by a third-party application. In addition, if the same food ordering mini program is not launched on Alipay, a corresponding simplified payment interface can also be generated on the Alipay page, and the user can also make a payment with Alipay, providing a better experience.
[0055] The above are only the preferred embodiments of the present invention and are not intended to limit the present invention. Any modifications, equivalent replacements, and improvements made within the spirit and principle of the present invention shall be included in the protection scope of the present invention.
Claims
1. A cross-platform payment method, characterized in that: The method comprises the following steps: Step S1: After scanning the QR code to enter the WeChat ordering interface, locate the specific merchant name and store according to the configuration information, and silently obtain the user's identity information, including the user's mobile phone number and the user's unique identifier OpenID on the WeChat end; Step S2: After completing the order selection and confirmation on the front-end page, generate business order information, which includes user identity information, and upload it to the ordering system server. When initiating a WeChat payment request, check whether there is any payment anomaly; Step S3: when abnormal payment information is captured, generate an Alipay short string password based on the current business order information through a double-scale compression algorithm, and locate whether there is an associated Alipay user binding and Alipay message authorization based on the member serial information; Step S41: if there is no associated binding and message authorization, a payment trigger link is generated. After the user clicks it, the local Alipay application is automatically opened to perform associated binding and message authorization. Then, the Alipay short string password is parsed, the short string password is further decrypted, the business order information is restored, and the Alipay authorization is completed at the same time; Step S42: If there is associated binding and message authorization, an app message notification is sent through the Alipay message box. After receiving the Alipay app message notification, the user clicks the message notification, automatically waking up the local Alipay application and parsing the Alipay short string password, and then further decrypting the short string password to restore the business order information, and completing the Alipay authorization at the same time; Step S5: Determine whether there is a matching Alipay mini program based on the merchant information corresponding to the current business order; Step S6: If there is a matching Alipay applet, call the Alipay applet, import the business order information and generate a payment interface. When the user confirms the payment, complete the payment deduction by calling the Alipay cashier, and associate the user's mobile phone number, OpenID and the userid of the current user of the Alipay applet and store them in the marketing system; Step S7: On the Alipay side, the business order information managed by the mobile phone number corresponding to the userid is automatically retrieved from the marketing system, and then the user data is updated accordingly; on the WeChat side, the business order information managed by the mobile phone number corresponding to the OpenID is automatically retrieved from the marketing system, and the user data is also updated accordingly, so that the user data on the Alipay side and the WeChat side are updated synchronously and consistently; Step S8: If there is no matching Alipay applet, directly jump to a neutral public simplified version of the Alipay cashier page to display the amount to be paid. When the user confirms the payment, the payment is completed by calling the Alipay cashier. The payment result is synchronously displayed on the Alipay interface, and the business order payment information is asynchronously updated at the same time. Step S9: When the payment is completed on the Alipay side, the WeChat side will poll the payment result, and when the Alipay side returns to the WeChat side to view after the payment is completed, the correct payment information will be displayed. At the same time, after the payment is completed, the user data is updated in the marketing system.
2. The cross-platform payment method according to claim 1, characterized in that: The specific process of step S1 is as follows: S11. For first-time users, when scanning the QR code to order food, request authorization to obtain the user's mobile phone number information, and obtain the mobile phone number information after authorization; S12. Each time a meal is ordered by scanning a QR code on WeChat, the ordering code contains differentiated configuration information of merchants and stores. After scanning the QR code, the specific merchant and store is quickly located and the content is displayed based on the differentiated configuration information; S13. When entering the ordering interface, WeChat redirects to the specified callback uniform resource locator URL with a temporary code parameter, which is sent to the ordering system server. The access token access_token is generated based on the API interface provided by the server and the application ID AppID and developer password appsecret of the ordering applet. Finally, the OpenID is obtained and associated with the user's mobile phone number.
3. The cross-platform payment method according to claim 2, characterized in that: The specific process of step S2 is as follows: S21. After the user selects and completes the order and confirmation on the front-end page, the business order information is generated and uploaded to the ordering system server in real time to pre-produce the business flow order information; S22. When WeChat payment is selected in the interface, a payment request is initiated to the upstream WeChat payment system according to the order amount, type, merchant configuration and user identity information of the current business order information; S23, the WeChat payment system verifies the order information and order rationality, and returns the necessary parameters required by the WeChat payment control; S24. When the WeChat payment system is processing, check whether there are any payment anomalies. Payment anomalies include mismatch between merchant number and AppID, mismatch between OpenID and AppID, no binding relationship between the official account and the merchant number, WeChat is not authenticated, and insufficient balance. If a payment anomaly occurs, an exception code message is returned.
4. The cross-platform payment method according to claim 3, characterized in that: The specific process of step S3 is as follows: S31. Capture payment exception information by monitoring exception code messages. When a payment exception is identified, use a double-scale compression algorithm to generate a short string password recognizable by Alipay according to the Alipay password format. The short string password is unique and marked with an expiration time. When the expiration time is reached, the short string password is automatically destroyed; S32. Find out whether the current WeChat user has associated Alipay user binding and Alipay message authorization based on the member connection information of the marketing system.
5. The cross-platform payment method according to claim 4, characterized in that: In step S41, if there is no associated binding and message authorization, a payment trigger link is generated and displayed on the current page according to the message encapsulation rules. The payment trigger link includes a short string password and a local Alipay payment call interface. After the user clicks the payment trigger link, the local Alipay application is automatically opened to perform associated binding and message authorization operations.
6. The cross-platform payment method according to claim 5, characterized in that: In step S42, if there is associated binding and message authorization, an app message notification containing a short string password will pop up directly at the top of the interface through the Alipay message box, and the user can directly click on the app message notification on the interface to automatically wake up the local Alipay application.
7. The cross-platform payment method according to claim 6, characterized in that: In step S5, after obtaining the Alipay authorization, the merchant information in the business order is extracted and combined with the application number to identify whether the current merchant also has a matching Alipay mini program in Alipay.
8. The cross-platform payment method according to claim 7, characterized in that: In step S6, the process of importing business order information and generating a payment interface is as follows: extracting order data from the business order information, including dish name, quantity, unit price, total dish amount and discount amount, and then matching the data according to the Alipay order template to generate a new Alipay business order, and producing a payment interface containing the Alipay business order content according to a fixed display mode.
Citation Information
Patent Citations
Service consumption payment information processing method and system
CN106204000A
Meal ordering system
CN107993163A
Method and device for handling bill reconciliation abnormality
CN109214911A
Account number automatic login method and system, storage medium and server
CN110162943A
Payment proxy method and system, electronic equipment and storage medium
CN110348851A