Batch deduction method and device
By determining transaction scenarios and matching rules in the bank loan system, batch automatic deductions are realized, which solves the problems of misoperation and low efficiency in online repayment of customers, and improves repayment efficiency and management reusability.
Patent Information
- Application Number
- CN202110338735.5
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2021-03-30
- Publication Date
- 2024-08-23
- Estimated Expiration
- 2041-03-30
AI Technical Summary
In the existing technology, there is a lack of guidance for customers to make online repayments, which is prone to misoperations, and the efficiency of each repayment is low, making it impossible to achieve batch repayments.
By determining the transaction scenario of the balance change message, matching the loan account based on the set matching rules, generating deduction data, and realizing batch automatic deduction operations.
It improves repayment efficiency, simplifies unified deduction management in different transaction scenarios, has good reusability, and ensures the correctness and efficiency of deduction operations by regularly querying and updating repayment status.
Smart Images

Figure CN112927066B
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of automatic program design, and in particular to a batch deduction method and device. Background Art
[0002] There are many kinds of bank loan businesses, and the repayment methods of different loan businesses are different, such as one-time principal and interest repayment, early principal repayment, monitoring third-party account transfer repayment, monitoring customer account payment, etc. In the existing technology, customers log in to the bank system independently, query loan information, and repay online.
[0003] In the process of implementing the present invention, there are at least the following problems in the prior art:
[0004] Due to lack of guidance, customers are prone to making mistakes when repaying online, which can lead to abnormal repayments. At the same time, repayments can only be made one by one, which makes repayment efficiency low. Summary of the invention
[0005] In view of this, an embodiment of the present invention provides a batch deduction method and device, which determines the transaction scenario of the balance change message, matches the loan account for the balance change message based on the matching rules set for the transaction scenario, and then generates deduction data to realize batch automatic deduction operations with high repayment efficiency.
[0006] To achieve the above objective, according to one aspect of an embodiment of the present invention, a batch deduction method is provided.
[0007] A batch deduction method according to an embodiment of the present invention includes: obtaining a balance change message of at least one transaction account, obtaining a balance change message set, and determining a transaction scenario of the balance change message in the balance change message set; matching the corresponding loan account for the balance change message according to a matching rule set for the transaction scenario; batch generating deduction data according to the loan account and the transaction amount of the balance change message; using the deduction data as an interface input parameter, and calling a deduction interface corresponding to the loan product type of the loan account to perform a batch deduction operation.
[0008] Optionally, the balance change message includes a payment account, a receiving account, a transaction summary and a balance change type; matching the corresponding loan account for the balance change message according to the matching rule set for the transaction scenario includes: determining that the balance change type of the balance change message is the balance change type indicated by the matching rule corresponding to the transaction scenario, and the transaction summary is the transaction summary specified by the matching rule; traversing the loan application information of the loan application record; wherein the loan application information includes a loan account, a repayment account, an incoming payment account and a loan status; taking the loan application information in which the repayment account is the receiving account, the incoming payment account is the payment account, and the loan status is an unsettled loan as the target loan information; and taking the loan account of the target loan information as the loan account that matches the balance change message.
[0009] Optionally, the transaction scenario includes any one or more of transferring money from a public account to a single public account, transferring money from a public account to multiple public accounts, and transferring money from a public account to a private account.
[0010] Optionally, the matching rules set for the transaction scenario include: if the transaction scenario is a transfer from a public account to a single public account, the balance change type in the matching rule is an income type, and the transaction summary is a first identifier associated with the loan; if the transaction scenario is a transfer from a public account to multiple public accounts, the balance change type in the matching rule is an income type, and the transaction summary is a second identifier associated with the loan; if the transaction scenario is a transfer from a public account to a private account, the balance change type in the matching rule is an expenditure type, and the transaction summary is a third identifier associated with the loan.
[0011] Optionally, there are multiple target loan information; taking the loan account of the target loan information as the loan account that matches the balance change message includes: sorting the loan account of the multiple target loan information in order from early to late according to the repayment time of the multiple target loan information; and taking the sorted loan account as the loan account that matches the balance change message.
[0012] Optionally, determining the transaction scenario of the balance change message in the balance change message set includes: traversing the balance change messages in the balance change message set; determining the transaction scenario of the current balance change message according to the payment account and the receiving account of the traversed current balance change message, until the traversal is completed.
[0013] Optionally, the transaction scenario of the current balance change message is determined based on the payment account and the receiving account of the traversed current balance change message, including: if the payment account of the current balance change message is the account number of the first public account, and the receiving account is the account number of a second public account, then the transaction scenario of the current balance change message is determined to be the transfer from the public account to a single public account; if the payment account of the current balance change message is the account number of the first public account, and the receiving account is the account number of multiple second public accounts, then the transaction scenario of the current balance change message is determined to be the transfer from the public account to multiple public accounts; if the payment account of the current balance change message is the account number of the first public account, and the receiving account is the account number of a private account, then the transaction scenario of the current balance change message is determined to be the transfer from the public account to the private account.
[0014] Optionally, batch generating deduction data according to the loan account number and the transaction amount of the balance change message includes: traversing the balance change messages in the balance change message set; determining the deduction data corresponding to the current balance change message according to the loan account number and transaction amount of the traversed current balance change message, until the traversal is completed; wherein the deduction data includes the loan account number, repayment account number, repayment amount and repayment status.
[0015] Optionally, before the step of calling the deduction interface corresponding to the loan product type of the loan account to perform batch deduction operations, the method also includes: assigning a serial number to the deduction data corresponding to the balance change message; using the serial number and the set repayment status as interface input parameters, calling a query interface, and extracting the deduction data; using the deduction data as interface input parameters includes: using the extracted deduction data as interface input parameters.
[0016] Optionally, the method further includes: determining that the deduction operation is successful, and updating the repayment status and the remaining amount.
[0017] Optionally, obtaining the balance change message of at least one transaction account to obtain the balance change message set includes: regularly calling a query interface to query the balance change message of at least one transaction account; and adding the balance change message obtained by the current call to the balance change message set.
[0018] Optionally, the method further includes: judging whether the loan of the transaction account has been settled according to the deduction result information; and determining the transaction account that needs to obtain the balance change message again according to the judgment result and the transaction scenario.
[0019] Optionally, the transaction account for which the balance change message needs to be obtained again is determined based on the judgment result and the transaction scenario, including: if the judgment result is that the loan has been settled and the transaction scenario is a transfer from a corporate account to a single corporate account, then the balance change message of the transaction account needs to be obtained again; if the judgment result is that the loan has not been settled, then the balance change message of the transaction account needs to be obtained again.
[0020] To achieve the above objective, according to another aspect of an embodiment of the present invention, a batch deduction device is provided.
[0021] A batch deduction device according to an embodiment of the present invention comprises: an acquisition module, which is used to acquire balance change messages of at least one transaction account, obtain a balance change message set, and determine the transaction scenario of the balance change message in the balance change message set; a matching module, which is used to match the corresponding loan account for the balance change message according to the matching rule set for the transaction scenario; a generation module, which is used to batch generate deduction data according to the loan account and the transaction amount of the balance change message; and a deduction module, which is used to use the deduction data as an interface input parameter and call the deduction interface corresponding to the loan product type of the loan account to perform batch deduction operations.
[0022] Optionally, the balance change message includes a payment account, a receiving account, a transaction summary and a balance change type; the matching module is further used to determine that the balance change type of the balance change message is the balance change type indicated by the matching rule corresponding to the transaction scenario, and the transaction summary is the transaction summary specified by the matching rule; traverse the loan application information of the loan application record; wherein the loan application information includes a loan account, a repayment account, an incoming account and a loan status; use the loan application information in which the repayment account is the receiving account, the incoming account is the payment account, and the loan status is an unsettled loan as the target loan information; and use the loan account of the target loan information as the loan account that matches the balance change message.
[0023] Optionally, the transaction scenario includes any one or more of transferring money from a public account to a single public account, transferring money from a public account to multiple public accounts, and transferring money from a public account to a private account.
[0024] Optionally, the device also includes: a rule configuration module, which is used for, if the transaction scenario is a transfer from a public account to a single public account, the balance change type in the matching rule is an income type, and the transaction summary is a first identifier associated with the loan; if the transaction scenario is a transfer from a public account to multiple public accounts, the balance change type in the matching rule is an income type, and the transaction summary is a second identifier associated with the loan; if the transaction scenario is a transfer from a public account to a private account, the balance change type in the matching rule is an expenditure type, and the transaction summary is a third identifier associated with the loan.
[0025] Optionally, there are multiple target loan information; the matching module is further used to sort the loan account numbers of the multiple target loan information according to the repayment time of the multiple target loan information and in the order of the repayment time from early to late; and use the sorted loan account number as the loan account number that matches the balance change message.
[0026] Optionally, the acquisition module is further used to traverse the balance change messages in the balance change message set; determine the transaction scenario of the current balance change message according to the payment account and receiving account of the traversed current balance change message until the traversal is completed.
[0027] Optionally, the acquisition module is also used to determine that the transaction scenario of the current balance change message is a transfer from a public account to a single public account if the payment account of the current balance change message is the account of a first public account and the receiving account is the account of a second public account; if the payment account of the current balance change message is the account of the first public account and the receiving account is the account of multiple second public accounts, then the transaction scenario of the current balance change message is determined to be a transfer from a public account to multiple public accounts; if the payment account of the current balance change message is the account of the first public account and the receiving account is the account of a private account, then the transaction scenario of the current balance change message is determined to be a transfer from a public account to a private account.
[0028] Optionally, the generation module is also used to traverse the balance change messages in the balance change message set; determine the deduction data corresponding to the current balance change message according to the loan account and transaction amount of the traversed current balance change message until the traversal is completed; wherein the deduction data includes the loan account, repayment account, repayment amount and repayment status.
[0029] Optionally, the device also includes: a query module, used to assign a serial number to the deduction data corresponding to the balance change message; using the serial number and the set repayment status as interface input parameters, calling the query interface, and extracting the deduction data; the deduction module is also used to use the extracted deduction data as interface input parameters.
[0030] Optionally, the device further includes: an updating module, configured to determine that the deduction operation is successful, and to update the repayment status and the remaining amount.
[0031] Optionally, the acquisition module is further used to periodically call the query interface to query the balance change message of at least one transaction account; and add the balance change message obtained by the current call to the balance change message set.
[0032] Optionally, the device further comprises: an account determination module, configured to determine whether the loan of the transaction account has been settled according to the deduction result information; and to determine the transaction account for which the balance change message needs to be obtained again according to the determination result and the transaction scenario.
[0033] Optionally, the account determination module is also used to obtain the balance change message of the transaction account again if the judgment result is that the loan has been settled and the transaction scenario is a transfer from a public account to a single public account; if the judgment result is that the loan has not been settled, the balance change message of the transaction account needs to be obtained again.
[0034] To achieve the above objective, according to another aspect of an embodiment of the present invention, an electronic device is provided.
[0035] An electronic device according to an embodiment of the present invention includes: one or more processors; a storage device for storing one or more programs, and when the one or more programs are executed by the one or more processors, the one or more processors implement a batch deduction method according to an embodiment of the present invention.
[0036] To achieve the above objective, according to another aspect of the embodiments of the present invention, a computer readable medium is provided.
[0037] A computer-readable medium according to an embodiment of the present invention stores a computer program, which, when executed by a processor, implements a batch deduction method according to an embodiment of the present invention.
[0038] One embodiment of the above invention has the following advantages or beneficial effects: by determining the transaction scenario of the balance change message, matching the loan account for the balance change message based on the matching rules set for the transaction scenario, and then generating deduction data, batch automatic deduction operations are realized, and repayment efficiency is high. Balance change messages are filtered based on matching rules, and loan accounts are matched for the filtered balance change messages, thereby realizing unified deductions for different transaction scenarios, facilitating management, and having good reusability. When adding a new transaction scenario, it is only necessary to develop a processing flow for matching loan accounts for balance change messages, and the existing repayment method can be reused.
[0039] By sorting multiple loan accounts, priority is given to loan accounts with earlier repayment dates. Based on the characteristics of transaction scenarios, the payment account and the receiving account in the balance change message are used as factors for determining the transaction scenario, which facilitates the determination of the transaction scenario of each balance change message. By processing each balance change message in a centralized manner and generating batch deduction data, batch deduction operations can be performed later to improve repayment efficiency.
[0040] By extracting the deduction data of the set repayment status, it is ensured that the deduction operation is performed on the data of the specified repayment status. By updating the repayment status and the remaining amount, the correctness of the subsequent deduction operation is ensured. By regularly querying the balance change message, the automatic acquisition of the balance change message is realized, reducing the pressure on the server. According to the judgment result of whether the loan is settled and the transaction scenario, it is determined whether the balance change message of the transaction account needs to be obtained again, realizing the on-demand acquisition of the balance change message and saving network resources.
[0041] The further effects of the above-mentioned non-conventional optional manner will be described below in conjunction with the specific implementation manner. BRIEF DESCRIPTION OF THE DRAWINGS
[0042] The accompanying drawings are used to better understand the present invention and do not constitute an improper limitation of the present invention.
[0043] Figure 1 is a schematic diagram of the main steps of a batch deduction method according to an embodiment of the present invention;
[0044] Figure 2 is a schematic diagram of the main process of a batch deduction method according to another embodiment of the present invention;
[0045] Figure 3 It is a schematic diagram of a system flow of a batch deduction method for implementing another embodiment of the present invention;
[0046] Figure 4 is a schematic diagram of main modules of a batch deduction device according to an embodiment of the present invention;
[0047] Figure 5 is an exemplary system architecture diagram to which embodiments of the present invention may be applied;
[0048] Figure 6 It is a schematic diagram of the structure of a computer device suitable for implementing the electronic device of the embodiment of the present invention. DETAILED DESCRIPTION
[0049] The following is a description of exemplary embodiments of the present invention in conjunction with the accompanying drawings, including various details of the embodiments of the present invention to facilitate understanding, which should be considered as merely exemplary. Therefore, it should be recognized by those of ordinary skill in the art that various changes and modifications may be made to the embodiments described herein without departing from the scope and spirit of the present invention. Similarly, for clarity and conciseness, the description of well-known functions and structures is omitted in the following description.
[0050] Figure 1 FIG. 1 is a schematic diagram of the main steps of a batch deduction method according to an embodiment of the present invention. Figure 1 As shown, the batch deduction method of the embodiment of the present invention mainly includes the following steps:
[0051] Step S101: Obtain the balance change message of at least one transaction account, obtain a balance change message set, and determine the transaction scenario of the balance change message in the balance change message set. The transaction account refers to a collection account or a payment account related to a loan business. The balance change message refers to a message generated due to a change in the balance of the transaction account. In the embodiment, by calling a query interface, querying the balance change message of at least one transaction account, the balance change message queried in the current call is added to the balance change message set.
[0052] After obtaining the balance change message set, the balance change messages in the balance change message set are traversed, and the transaction scenario of the current balance change message is determined according to the payment account and the receiving account of the traversed current balance change message until the traversal is completed. In the embodiment, the transaction scenario refers to the repayment scenario of the loan business, such as a transfer from a public account to a single public account, a transfer from a public account to multiple public accounts, a transfer from a public account to a private account, etc.
[0053] Step S102: Match the corresponding loan account number for the balance change message according to the matching rule set for the transaction scenario. Different transaction scenarios are set with corresponding matching rules, which are used to indicate the balance change type and transaction summary content of different transaction scenarios, and then match the corresponding loan account number for the balance change message. The balance change message may include the payment account number, the collection account number, the transaction summary and the balance change type. The balance change type includes income type and expenditure type.
[0054] In this step, first determine whether the balance change type of the current balance change message is consistent with the balance change type indicated by the matching rule corresponding to its transaction scenario, and whether the transaction summary is consistent with the transaction summary specified by the matching rule. If any of the two is inconsistent, delete the current balance change message from the balance change message set, and continue to process the next balance change message in the deleted balance change message set.
[0055] If both are consistent, the loan application information of the loan application record is traversed, and the loan application information includes the loan account, repayment account, incoming account and loan status; then the loan application information with the repayment account as the receiving account, the incoming account as the payment account, and the loan status as unsettled is used as the target loan information, and the loan account of the target loan is the loan account that matches the current balance change message.
[0056] Step S103: Batch generate deduction data according to the loan account and the transaction amount of the balance change message. The deduction data is the data required to realize loan repayment, and may include the loan account, repayment account, repayment amount and repayment status. This step traverses the balance change messages in the balance change message set after deletion; according to the loan account and transaction amount of the current balance change message traversed, the deduction data corresponding to the current balance change message is determined until the traversal is completed.
[0057] Step S104: The deduction data is used as an interface input parameter, and the deduction interface corresponding to the loan product type of the loan account is called to perform batch deduction operations. After the deduction data is generated, the deduction data is used as an interface input parameter, and the deduction interface corresponding to the loan product type of the loan account is called to perform batch deduction operations. Thus, batch automatic loan repayment of loan businesses with different repayment methods is realized, and the repayment efficiency is high.
[0058] Figure 2 FIG. 2 is a schematic diagram of the main flow of a batch deduction method according to another embodiment of the present invention. Figure 2 As shown, the batch deduction method of the embodiment of the present invention mainly includes the following steps:
[0059] Step S201: Call the query interface regularly to query the balance change message of at least one transaction account. In the embodiment, the query interface can be called at set intervals (such as 5 minutes) to query the latest balance change message, and the queried balance change message is saved to the database. The balance change message may include global serial number, transaction time, payment account, transaction amount, balance change type, payee name, payment account, transaction summary and other information.
[0060] In an optional embodiment, the date, loan system name, and incremented batch number are used as query conditions, and the batch number is incremented each time the query interface is called to distinguish the balance change messages queried in different time periods.
[0061] Step S202: Add the balance change message queried in the current call to the balance change message set, and determine the transaction scenario of each balance change message in the balance change message set. Taking the transaction scenarios of a public account transfer to a single public account (such as a transfer from one enterprise to another enterprise), a public account transfer to multiple public accounts (such as a transfer from one enterprise to multiple other enterprises), and a public account transfer to a private account (such as a transfer from one enterprise to an individual) as examples, the transaction scenario determination process of each balance change message is as follows:
[0062] If the payment account of the current balance change message is the account of the first public account, and the payment account is the account of a second public account, it is determined that the transaction scenario of the current balance change message is a transfer from a public account to a single public account.
[0063] If the payment account of the current balance change message is the account of the first public account, and the payment account is the account of multiple second public accounts, it is determined that the transaction scenario of the current balance change message is the transfer of funds from the public account to multiple public accounts.
[0064] If the payment account of the current balance change message is the account of the first public account, and the payment receiving account is the account of the private account, it is determined that the transaction scenario of the current balance change message is a transfer from the public account to the private account.
[0065] It can be understood that this embodiment lists three transaction scenarios. In actual application, other transaction scenarios can be added as needed, and based on the characteristics of the transaction scenarios, factors for determining the transaction scenarios are selected to further determine the transaction scenarios of the balance change messages.
[0066] Step S203: According to the matching rules set for the transaction scenario, the corresponding loan accounts are matched for each balance change message. Still taking the transaction scenarios of transferring from a public account to a single public account, transferring from a public account to multiple public accounts, and transferring from a public account to a private account as examples, the matching rules are explained as follows:
[0067] If the transaction scenario is a transfer from a public account to a single public account, it is necessary to obtain the income balance change message of the receiving account and associate the corresponding loan by annotating the first identifier (such as the loan account number) in the transaction summary. In the matching rule, the balance change type is the income type, and the transaction summary is the first identifier associated with the loan.
[0068] If the transaction scenario is a transfer from a public account to multiple public accounts, it is necessary to obtain the income balance change message of the receiving account and associate the corresponding loan by annotating the second identifier in the transaction summary. In the matching rule, the balance change type is the income type, and the transaction summary is the second identifier associated with the loan.
[0069] If the transaction scenario is a transfer from a public account to a personal account, it is necessary to obtain the expenditure balance change message of the payment account and associate the corresponding loan by annotating the third identifier in the transaction summary. In the matching rule, the balance change type is the expenditure type, and the transaction summary is the third identifier associated with the loan.
[0070] According to the above matching rules, the implementation process of matching the loan account number for the current balance change message is as follows:
[0071] Determine whether the balance change type of the current balance change message is consistent with the balance change type indicated by the matching rule corresponding to its transaction scenario, and whether the transaction summary is consistent with the transaction summary specified by the matching rule. If any of the two is inconsistent, delete the current balance change message from the balance change message set, and continue to process the next balance change message in the deleted balance change message set.
[0072] If both are consistent, the loan application record is obtained according to the date and branch number, and the loan application information of the loan application record is traversed, and the loan application information includes the loan account, repayment account, incoming account and loan status; then the repayment account is used as the receiving account, the incoming account is used as the payment account, and the loan status is not settled as the screening conditions, and the loan application information that meets the screening conditions is screened out as the target loan information. The loan account of the target loan is the loan account that matches the current balance change message.
[0073] There may be one or more loan application information that meets the screening criteria. If there is only one, it means that the current balance change message is associated with one loan; if there are multiple, it means that the current balance change message is associated with multiple loans.
[0074] In the case where the current balance change message is associated with multiple loans, the loan accounts of the multiple target loan information need to be sorted according to the repayment time of the multiple target loan information, in order from the earliest to the latest repayment time; the sorted loan account is used as the loan account that matches the current balance change message. This process can give priority to repaying the earliest due loan. After the first loan is repaid, if there is a remaining transaction amount, the second loan will be repaid, and so on.
[0075] Step S204: Generate deduction data corresponding to each transaction account in batches according to the loan account and the transaction amount of the balance change message. This step is used to determine the loan account, repayment account, repayment type (such as early repayment, normal repayment, settlement), remaining amount, return account of the remaining amount, repayment date, repayment status, repayment serial number, transaction channel and other deduction data required for repayment according to the loan account matched for each balance change message and the transaction amount of each balance change message.
[0076] Among them, the remaining amount is the difference between the transaction amount and the current repayment amount. It is used when one balance change message corresponds to multiple loan repayments. Every time a loan is successfully repaid, the remaining amount of this balance change message is updated.
[0077] In this embodiment, the deduction data includes the repayment status, which is convenient for updating the repayment status of the loan. For example, if an enterprise transfers money to another enterprise and requires that the money be used for a specific purpose, that is, it can only be used to repay the enterprise, then the repayment status of the receiving account can be set to "only receive but not pay" before the deduction operation, and it can be removed during the deduction operation, and reset to "only receive but not pay" after the deduction operation.
[0078] It is understandable that the data fields included in the above deduction data are only examples. They can be adjusted according to needs. In the embodiment, in addition to the deduction operation, some loan products also need to perform other processing, such as unfreezing the transaction account, notifying the customer of the deduction result information by SMS after the transaction is successful, generating an early warning message when the repayment fails, etc. Therefore, the deduction data may also include the customer's name, customer phone number, handling bank, account manager number, account manager mobile phone number, etc.
[0079] Step S205: Take the deduction data as an interface input parameter, and call the deduction interface corresponding to the loan product type of the loan account to perform batch deduction operations. In the embodiment, a designated serial number is assigned to the deduction data corresponding to each transaction account, and then the date and serial number can be used as query conditions to query the deduction data with the date, the serial number, and the repayment status as unprocessed. The query here is used to extract the unprocessed deduction data under the date.
[0080] According to the loan account, repayment method, repayment amount, repayment account, repayment date and branch number in the queried deduction data, the deduction interface corresponding to the loan product type of the loan account is called to request a deduction operation and save the deduction result information. In an optional embodiment, the deduction result information can also be sent to relevant personnel by SMS, email, etc.
[0081] The deduction result information includes transaction time, repayment status, failure description, balance change serial number, loan account number, repayment amount, repayment account number, serial number, etc. In a preferred embodiment, if the repayment is successful, the repayment status needs to be updated from unprocessed to processed, and the remaining amount needs to be updated.
[0082] Step S206: According to the deduction result information, determine whether the loan of each transaction account has been settled. If the loan has been settled, execute step S207; if the loan has not been settled, execute step S201. If the repayment status in the deduction result information is processed, it means that the loan has been settled. Among them, for the case where a balance change message corresponds to multiple loan repayments, when all associated loans of the same repayment account have been settled, it means that the loan has been settled. If the loan has not been settled, it is necessary to continue to obtain the balance change message of the transaction account.
[0083] Step S207: According to the transaction scenario corresponding to the settled transaction account, determine whether it is necessary to obtain the balance change message of the transaction account again. If it is necessary to obtain it again, execute step S201; otherwise, end this process. If the transaction scenario is a transfer from a public account to a single public account, it is still necessary to obtain the balance change message of the transaction account even if the loan has been settled. In other transaction scenarios, if the loan has been settled, it is no longer necessary to obtain the balance change message of the transaction account.
[0084] Figure 3 1 is a schematic diagram of a system flow chart for implementing a batch deduction method according to another embodiment of the present invention. Figure 3 As shown, the batch deduction system of the embodiment of the present invention includes a public deposit component, an agent component and a batch deduction component (i.e., a batch deduction device), and the entire deduction operation is triggered based on a balance change message.
[0085] The public deposit component is the producer of balance change messages and is used to provide an interface for the proxy component to subscribe to balance change messages.
[0086] The proxy component is a subscriber to the balance change message. It is used to provide an interface for the batch deduction component to pay attention to the balance change message. It is also used to persist the balance change message pushed by the public deposit component and provide an interface for the batch deposit component to query the balance change message.
[0087] The batch deduction component is a user of the balance change message. This component is used to implement the batch deduction method, which specifically includes querying the balance change message of the proxy component (i.e. step S201), matching the relevant loan account (see step S202-step S203), generating deduction data (i.e. step S204), calling the deduction interface to perform the deduction operation (i.e. step S205), judging whether the loan is settled (i.e. step S206), and judging whether it is necessary to query the balance change message again (i.e. step S207).
[0088] The following is an explanation of the information interaction process between the components in the batch deduction system. The processing flow of the batch deduction system in the embodiment of the present invention includes:
[0089] Step 1: The corporate deposit component monitors the balance changes of at least one transaction account, generates the corresponding balance change message, and pushes the balance change message to the proxy component. When a customer signs a loan, the loan system subscribes to the balance change message of the corporate or personal account by requesting the interface provided by the proxy component. When the balance of the transaction account changes, the corporate deposit component automatically pushes the balance change information to the proxy component through the message queue.
[0090] Step 2: The proxy component saves the balance change message.
[0091] Step 3: The batch deduction component periodically calls the query interface of the proxy component to query the balance change message of at least one transaction account. The batch deduction component schedules the query interface provided by the proxy component every 5 minutes to query the latest balance change message.
[0092] Step 4: The batch deduction component implements the batch deduction operation by executing steps S202 to S207. For a transaction account that does not need to obtain balance change messages again, the proxy component can unsubscribe from the balance change messages of the transaction account, and the public deposit component can cancel monitoring the balance changes of the transaction account.
[0093] In this embodiment, through componentized design, when a new transaction scenario needs to be added, it is only necessary to develop a processing flow for matching the balance change message with the loan, so that the existing repayment method can be reused, and all repayment records can be uniformly monitored and managed.
[0094] Figure 4 Schematic diagram of main modules of a batch deduction device according to an embodiment of the present invention.
[0095] like Figure 4 As shown, the batch deduction device 400 of the embodiment of the present invention mainly includes:
[0096] The acquisition module 401 is used to obtain the balance change message of at least one transaction account, obtain the balance change message set, and determine the transaction scenario of the balance change message in the balance change message set. The transaction account refers to a collection account or a payment account related to the loan business. The balance change message refers to a message generated due to a change in the balance of the transaction account. In the embodiment, by calling the query interface, the balance change message of at least one transaction account is queried, and the balance change message queried in the current call is added to the balance change message set.
[0097] After obtaining the balance change message set, the balance change messages in the balance change message set are traversed, and the transaction scenario of the current balance change message is determined according to the payment account and the receiving account of the traversed current balance change message until the traversal is completed. In the embodiment, the transaction scenario refers to the repayment scenario of the loan business, such as a transfer from a public account to a single public account, a transfer from a public account to multiple public accounts, a transfer from a public account to a private account, etc.
[0098] The matching module 402 is used to match the corresponding loan account for the balance change message according to the matching rules set for the transaction scenario. Different transaction scenarios are set with corresponding matching rules, which are used to indicate the balance change type and transaction summary content of different transaction scenarios, and then match the corresponding loan account for the balance change message. The balance change message may include the payment account, the collection account, the transaction summary and the balance change type. The balance change type includes income type and expenditure type.
[0099] In this module, first determine whether the balance change type of the current balance change message is consistent with the balance change type indicated by the matching rule corresponding to its transaction scenario, and whether the transaction summary is consistent with the transaction summary specified by the matching rule. If any of the two is inconsistent, delete the current balance change message from the balance change message set, and continue to process the next balance change message in the deleted balance change message set.
[0100] If both are consistent, the loan application information of the loan application record is traversed, and the loan application information includes the loan account, repayment account, incoming account and loan status; then the loan application information with the repayment account as the receiving account, the incoming account as the payment account, and the loan status as unsettled is used as the target loan information, and the loan account of the target loan is the loan account that matches the current balance change message.
[0101] The generation module 403 is used to batch generate deduction data according to the loan account and the transaction amount of the balance change message. The deduction data is the data required to realize loan repayment, and may include the loan account, repayment account, repayment amount and repayment status. This module traverses the balance change messages in the balance change message set after deletion; according to the loan account and transaction amount of the current balance change message traversed, it determines the deduction data corresponding to the current balance change message until the traversal is completed.
[0102] The deduction module 404 is used to use the deduction data as an interface input parameter, and call the deduction interface corresponding to the loan product type of the loan account to perform batch deduction operations. After the deduction data is generated, the deduction data is used as an interface input parameter, and the deduction interface corresponding to the loan product type of the loan account is called to perform batch deduction operations. Thus, batch automatic loan repayment of loan businesses with different repayment methods is realized, and the repayment efficiency is high.
[0103] In addition, the batch deduction device 400 of the embodiment of the present invention may also include: a rule configuration module, a query module, an update module and an account determination module ( Figure 4 ). The rule configuration module is used for, if the transaction scenario is a transfer from a public account to a single public account, the balance change type in the matching rule is an income type, and the transaction summary is a first identifier associated with a loan; if the transaction scenario is a transfer from a public account to multiple public accounts, the balance change type in the matching rule is an income type, and the transaction summary is a second identifier associated with a loan; if the transaction scenario is a transfer from a public account to a private account, the balance change type in the matching rule is an expenditure type, and the transaction summary is a third identifier associated with a loan.
[0104] The query module is used to assign a serial number to the deduction data corresponding to the balance change message; the serial number and the set repayment status are used as interface input parameters, the query interface is called, and the deduction data is extracted. The update module is used to determine that the deduction operation is successful and update the repayment status and the remaining amount.
[0105] The account determination module is used to determine whether the loan of the transaction account has been settled according to the deduction result information; and determine the transaction account that needs to obtain the balance change message again according to the determination result and the transaction scenario.
[0106] From the above description, it can be seen that by determining the transaction scenario of the balance change message, the loan account is matched for the balance change message based on the matching rules set for the transaction scenario, and then the deduction data is generated to realize batch automatic deduction operations and high repayment efficiency.
[0107] Figure 5 An exemplary system architecture 500 is shown to which the batch deduction method or batch deduction apparatus according to the embodiment of the present invention can be applied.
[0108] like Figure 5 As shown, system architecture 500 may include servers 501, 503, 505, networks 502 and 504. Network 502 is used to provide a medium for a communication link between server 501 and server 503. Network 504 is used to provide a medium for a communication link between server 503 and server 505. Networks 502 and 504 may include various connection types, such as wired, wireless communication links or optical fiber cables, etc.
[0109] Servers 501, 503, and 505 may be servers that provide various services. For example, server 501 provides a subscription interface for balance change messages, monitors balance changes, generates balance change messages, and pushes balance change messages to server 503. Server 503 provides a query interface for balance change messages and saves balance change messages. Server 505 obtains balance change messages and performs batch automatic deduction operations based on the balance change messages.
[0110] It should be noted that the batch deduction method provided in the embodiment of the present application is generally executed by the server 505, and accordingly, the batch deduction device is generally set in the server 505.
[0111] It should be understood that Figure 5 The number of networks and servers in the embodiment is only for illustration. Any number of networks and servers may be provided as required.
[0112] According to an embodiment of the present invention, the present invention also provides an electronic device and a computer-readable medium.
[0113] The electronic device of the present invention comprises: one or more processors; a storage device for storing one or more programs, and when the one or more programs are executed by the one or more processors, the one or more processors implement a batch deduction method of an embodiment of the present invention.
[0114] The computer-readable medium of the present invention stores a computer program thereon, and when the program is executed by a processor, a batch deduction method of an embodiment of the present invention is implemented.
[0115] Reference below Figure 6 , which shows a schematic diagram of the structure of a computer system 600 suitable for implementing an electronic device of an embodiment of the present invention. Figure 6 The electronic device shown is only an example and should not bring any limitation to the functions and scope of use of the embodiments of the present invention.
[0116] like Figure 6 As shown, the computer system 600 includes a central processing unit (CPU) 601, which can perform various appropriate actions and processes according to a program stored in a read-only memory (ROM) 602 or a program loaded from a storage part 608 into a random access memory (RAM) 603. In the RAM 603, various programs and data required for the operation of the computer system 600 are also stored. The CPU 601, the ROM 602, and the RAM 603 are connected to each other via a bus 604. An input / output (I / O) interface 605 is also connected to the bus 604.
[0117] The following components are connected to the I / O interface 605: an input section 606 including a keyboard, a mouse, etc.; an output section 607 including a cathode ray tube (CRT), a liquid crystal display (LCD), etc., and a speaker, etc.; a storage section 608 including a hard disk, etc.; and a communication section 609 including a network interface card such as a LAN card, a modem, etc. The communication section 609 performs communication processing via a network such as the Internet. A drive 610 is also connected to the I / O interface 605 as needed. A removable medium 611, such as a magnetic disk, an optical disk, a magneto-optical disk, a semiconductor memory, etc., is installed on the drive 610 as needed, so that a computer program read therefrom is installed into the storage section 608 as needed.
[0118] In particular, according to the embodiments disclosed in the present invention, the process described in the main step diagram above can be implemented as a computer software program. For example, the embodiments disclosed in the present invention include a computer program product, which includes a computer program carried on a computer-readable medium, and the computer program includes a program code for executing the method shown in the main step diagram. In such an embodiment, the computer program can be downloaded and installed from the network through the communication part 609, and / or installed from the removable medium 611. When the computer program is executed by the central processing unit (CPU) 601, the above-mentioned functions defined in the system of the present invention are executed.
[0119] It should be noted that the computer-readable medium shown in the present invention may be a computer-readable signal medium or a computer-readable storage medium or any combination of the above two. The computer-readable storage medium may be, for example, but not limited to, an electrical, magnetic, optical, electromagnetic, infrared, or semiconductor system, device or device, or any combination of the above. More specific examples of computer-readable storage media may include, but are not limited to: an electrical connection with one or more wires, a portable computer 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 disk read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the above. In the present invention, a computer-readable storage medium may be any tangible medium containing or storing a program that can be used by or in combination with an instruction execution system, device or device. In the present invention, a computer-readable signal medium may include a data signal propagated in a baseband or as part of a carrier wave, which carries a computer-readable program code. This propagated data signal may take a variety of forms, including but not limited to electromagnetic signals, optical signals, or any suitable combination of the above. Computer-readable signal media may also be any computer-readable medium other than computer-readable storage media, which may send, propagate or transmit a program for use by or in conjunction with an instruction execution system, apparatus or device. The program code contained on the computer-readable medium may be transmitted using any appropriate medium, including but not limited to: wireless, wire, optical cable, RF, etc., or any suitable combination of the above.
[0120] The flow chart and block diagram in the accompanying drawings illustrate the possible architecture, function and operation of the system, method and computer program product according to various embodiments of the present invention. In this regard, each box in the flow chart or block diagram can represent a module, a program segment, or a part of a code, and the above-mentioned module, program segment, or a part of a code contains one or more executable instructions for realizing the specified logical function. It should also be noted that in some alternative implementations, the functions marked in the box can also occur in a different order from the order marked in the accompanying drawings. For example, two boxes represented in succession can actually be executed substantially in parallel, and they can sometimes be executed in the opposite order, depending on the functions involved. It should also be noted that each box in the block diagram or flow chart, and the combination of the boxes in the block diagram or flow chart can be implemented with a dedicated hardware-based system that performs a specified function or operation, or can be implemented with a combination of dedicated hardware and computer instructions.
[0121] The modules involved in the embodiments of the present invention may be implemented in software or hardware. The modules described may also be set in a processor, for example, they may be described as: a processor including an acquisition module, a matching module, a generation module and a deduction module. The names of these modules do not constitute a limitation on the modules themselves in some cases. For example, the acquisition module may also be described as "a module for acquiring a balance change message of at least one transaction account, obtaining a balance change message set, and determining a transaction scenario of a balance change message in the balance change message set".
[0122] As another aspect, the present invention also provides a computer-readable medium, which may be included in the device described in the above embodiment; or it may exist independently without being assembled into the device. The above computer-readable medium carries one or more programs, and when the above one or more programs are executed by a device, the device includes: obtaining a balance change message of at least one transaction account, obtaining a balance change message set, and determining a transaction scenario of the balance change message in the balance change message set; matching the corresponding loan account for the balance change message according to the matching rule set for the transaction scenario; batch generating deduction data according to the loan account and the transaction amount of the balance change message; using the deduction data as an interface input parameter, calling the deduction interface corresponding to the loan product type of the loan account to perform batch deduction operations.
[0123] According to the technical solution of the embodiment of the present invention, by determining the transaction scenario of the balance change message, the loan account is matched for the balance change message based on the matching rules set for the transaction scenario, and then the deduction data is generated to realize batch automatic deduction operations with high repayment efficiency.
[0124] The above product can execute the method provided by the embodiment of the present invention, and has the functional modules and beneficial effects corresponding to the execution method. For technical details not described in detail in this embodiment, please refer to the method provided by the embodiment of the present invention.
[0125] The above specific implementations do not constitute a limitation on the protection scope of the present invention. It should be understood by those skilled in the art that various modifications, combinations, sub-combinations and substitutions may occur depending on design requirements and other factors. Any modification, equivalent substitution and improvement made within the spirit and principle of the present invention shall be included in the protection scope of the present invention.
Claims
1. A batch deduction method, characterized in that: include: Acquire a balance change message of at least one transaction account, obtain a balance change message set, and determine a transaction scenario of the balance change message in the balance change message set; Match the corresponding loan account for the balance change message according to the matching rule set for the transaction scenario; whether the balance change type of the current balance change message is consistent with the balance change type indicated by the matching rule corresponding to the transaction scenario, and whether the transaction summary is consistent with the transaction summary specified by the matching rule; if any one of the two is inconsistent, delete the current balance change message from the balance change message set, and continue to process the next balance change message in the deleted balance change message set; if both are consistent, traverse the loan application information of the loan application record, the loan application information includes the loan account number and the loan status, and use the loan account number corresponding to the loan application information with the loan status of unsettled as the loan account number matching the current balance change message; Generating deduction data in batches according to the loan account number and the transaction amount of the balance change message; The deduction data is used as an interface input parameter, and a deduction interface corresponding to the loan product type of the loan account is called to perform batch deduction operations.
2. The method according to claim 1, characterized in that The balance change message includes the payment account, the receiving account, the transaction summary and the balance change type; The matching the corresponding loan account number for the balance change message according to the matching rule set for the transaction scenario includes: Determining that the balance change type of the balance change message is the balance change type indicated by the matching rule corresponding to the transaction scenario, and the transaction summary is the transaction summary specified by the matching rule; Traversing the loan application information of the loan application record; wherein the loan application information includes the loan account number, repayment account number, incoming payment account number and loan status; The loan application information in which the repayment account is the receiving account, the incoming account is the paying account, and the loan status is unsettled is used as the target loan information; The loan account number of the target loan information is used as the loan account number that matches the balance change message.
3. The method according to claim 2, characterized in that The transaction scenarios include any one or more of transferring money from a public account to a single public account, transferring money from a public account to multiple public accounts, and transferring money from a public account to a private account.
4. The method according to claim 3, characterized in that The matching rules set for the transaction scenario include: If the transaction scenario is a transfer from a public account to a single public account, the balance change type in the matching rule is income, and the transaction summary is the first identifier associated with the loan; If the transaction scenario is a transfer from a public account to multiple public accounts, the balance change type in the matching rule is income, and the transaction summary is a second identifier associated with the loan; If the transaction scenario is a transfer from a public account to a personal account, the balance change type in the matching rule is an expenditure type, and the transaction summary is a third identifier associated with the loan.
5. The method according to claim 2, characterized in that: The target loan information is multiple; The step of using the loan account number of the target loan information as the loan account number that matches the balance change message includes: According to the repayment time of the plurality of target loan information, the loan account numbers of the plurality of target loan information are sorted in the order of the repayment time from earliest to latest; The sorted loan account number is used as the loan account number that matches the balance change message.
6. The method according to claim 1, characterized in that The determining of the transaction scenario of the balance change message in the balance change message set includes: Traversing the balance change messages in the balance change message set; According to the payment account and the payment receiving account of the traversed current balance change message, the transaction scenario of the current balance change message is determined until the traversal is completed.
7. The method according to claim 6, characterized in that The determining of the transaction scenario of the current balance change message according to the payment account and the payment receiving account of the traversed current balance change message includes: If the payment account of the current balance change message is the account of the first public account, and the payment receiving account is the account of a second public account, it is determined that the transaction scenario of the current balance change message is a transfer from a public account to a single public account; If the payment account of the current balance change message is the account of the first public account, and the payment account is the account of multiple second public accounts, it is determined that the transaction scenario of the current balance change message is a transfer from a public account to multiple public accounts; If the payment account of the current balance change message is the account of the first public account and the receiving account is the account of the personal account, it is determined that the transaction scenario of the current balance change message is a transfer from a public account to a personal account.
8. The method according to claim 1, characterized in that The step of batch-generating deduction data according to the loan account number and the transaction amount of the balance change message includes: Traversing the balance change messages in the balance change message set; According to the loan account number and transaction amount of the traversed current balance change message, the deduction data corresponding to the current balance change message is determined until the traversal is completed; wherein the deduction data includes the loan account number, repayment account number, repayment amount and repayment status.
9. The method according to claim 1, characterized in that: Before the step of calling the deduction interface corresponding to the loan product type of the loan account to perform batch deduction operations, the method further includes: Assigning a sequence number to the deduction data corresponding to the balance change message; Using the serial number and the set repayment status as interface input parameters, calling the query interface, and extracting the deduction data; The taking the deduction data as an interface input parameter comprises: taking the extracted deduction data as an interface input parameter.
10. The method according to claim 8, characterized in that The method further comprises: Confirm that the deduction operation is successful, and update the repayment status and remaining amount.
11. The method according to claim 1, characterized in that: The step of obtaining a balance change message of at least one transaction account to obtain a balance change message set includes: Call the query interface regularly to query the balance change information of at least one trading account; Add the balance change message queried in the current call to the balance change message set.
12. The method according to any one of claims 1 to 11, characterized in that: The method further comprises: Determine whether the loan of the transaction account has been settled based on the deduction result information; According to the judgment result and the transaction scenario, the transaction account for which the balance change message needs to be obtained again is determined.
13. The method according to claim 12, characterized in that The determining, based on the judgment result and the transaction scenario, of the transaction account for which the balance change message needs to be obtained again includes: If the judgment result is that the loan has been settled, and the transaction scenario is a transfer from a public account to a single public account, it is necessary to obtain the balance change message of the transaction account again; If the judgment result is that the loan has not been settled, it is necessary to obtain the balance change information of the transaction account again.
14. A device for batch deduction, characterized in that: include: An acquisition module, configured to acquire a balance change message of at least one transaction account, obtain a balance change message set, and determine a transaction scenario of the balance change message in the balance change message set; A matching module is used to match the corresponding loan account for the balance change message according to the matching rule set for the transaction scenario; wherein, whether the balance change type of the current balance change message is consistent with the balance change type indicated by the matching rule corresponding to the transaction scenario, and whether the transaction summary is consistent with the transaction summary specified by the matching rule; if any one of the two is inconsistent, the current balance change message is deleted from the balance change message set, and the next balance change message of the deleted balance change message set is processed; if both are consistent, the loan application information of the loan application record is traversed, and the loan application information includes a loan account number and a loan status, and the loan account number corresponding to the loan application information with an outstanding loan status is used as the loan account number matched with the current balance change message; A generation module, used for batch generating deduction data according to the loan account number and the transaction amount of the balance change message; The deduction module is used to take the deduction data as an interface input parameter and call the deduction interface corresponding to the loan product type of the loan account to perform batch deduction operations.
15. The device according to claim 14, characterized in that The balance change message includes the payment account, the receiving account, the transaction summary and the balance change type; The matching module is further configured to determine that the balance change type of the balance change message is the balance change type indicated by the matching rule corresponding to the transaction scenario, and the transaction summary is the transaction summary specified by the matching rule; Traversing the loan application information of the loan application record; wherein the loan application information includes the loan account number, repayment account number, incoming payment account number and loan status; The loan application information in which the repayment account is the receiving account, the incoming account is the payment account, and the loan status is unsettled is used as the target loan information; and The loan account number of the target loan information is used as the loan account number that matches the balance change message.
16. An electronic device, characterized in that: include: one or more processors; a storage device for storing one or more programs, When the one or more programs are executed by the one or more processors, the one or more processors implement the method according to any one of claims 1 to 13.
17. A computer readable medium having a computer program stored thereon, characterized in that: When the program is executed by a processor, the method according to any one of claims 1 to 13 is implemented.
Citation Information
Patent Citations
Bank account generation method and device
CN108256994A
Batch deduction processing method and device based on on-line mode
CN109064311A
Post-loan service processing method and device, equipment and storage medium
CN110415112A
Repayment monitoring method and device
CN110428326A
Data processing method and apparatus, computer device and storage medium
CN110490563A
