A method and device for processing a lease contract
By calculating the virtual end date and payment period, the problem of errors in calculation of lease contracts is solved, and the accurate payment ledger and lease balance sheet are generated is achieved, ensuring the accuracy and consistency of calculations.
Patent Information
- Application Number
- CN202110336862.1
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2021-03-29
- Publication Date
- 2024-11-26
- Estimated Expiration
- 2041-03-29
AI Technical Summary
The prior art has errors in calculating the end date and lease period of the lease contract, which leads to inaccurate calculation results, and cannot verify each other, and the situation of special dates cannot be correctly handled, resulting in errors in the calculation of payment ledger and lease balance sheet.
By calculating the virtual end date and deriving the correct end date, calculating the payment ledger based on the start date and the lease period, using the date calculation module, the interval month calculation module and the comparison module, ensure that the lease contract is signed correctly, and the payment is calculated based on the payment frequency. Number of periods, generate accurate payment ledgers and lease balance sheets.
It realizes accurate calculation of the end date and payment ledger of the lease contract, ensures that the calculation results of the lease contract are consistent, conform to the contract signing habits, and improves the accuracy and reliability of the calculation.
Smart Images

Figure CN112927051B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of big data, and in particular to a method and device for processing a lease contract. Background Art
[0002] The lease management system needs to calculate the lease term based on the start and end dates in the lease contract. For contracts with regular payments, the payment ledger, including the number of payment periods and the planned payment month for each period, must be calculated based on the payment frequency, the first payment date, and the end date of the contract. Finally, the lease balance sheet of the lease contract is calculated based on the payment ledger and the discount rate. Therefore, the payment ledger is the key data for calculating the lease balance sheet.
[0003] The specific manual calculation method is: the planned payment date of the first period of the payment ledger is the first payment date, and the subsequent planned payment dates are determined in sequence according to the planned payment date of the previous period + the payment frequency. Due to performance limitations during technical implementation, it is necessary to first calculate the number of periods in the payment ledger, which is the number of periods = lease period (month) / frequency (month), rounded down to an integer. In the process of calculating the payment ledger, the following two problems need to be solved: 1) Calculate the end date based on the start date and lease period of the lease contract. 2) Calculate the lease period based on the start date and end date of the lease contract.
[0004] In the process of implementing the present invention, the inventors found that the existing method has the following defects:
[0005] 1) When calculating the end date, if the calculated date does not exist or does not correspond to a date, it will be unified to the last day of the month, i.e. 28th (non-leap year), 29th (leap year), 30th, 31st, which does not conform to the custom of counting the beginning but not the end in contract signing.
[0006] 2) When encountering special dates, since the two derivation methods are logically inconsistent, calculation differences will occur and they cannot verify each other. Or there will be a situation where the start date is different but the end date is the same. Summary of the invention
[0007] In view of this, an embodiment of the present invention provides a method and device for processing a lease contract, which can at least solve the problem of different calculation results in the prior art.
[0008] To achieve the above objective, according to one aspect of an embodiment of the present invention, a method for processing a lease contract is provided, comprising:
[0009] Calculate the end date based on the start date and lease term in the lease contract, and determine the projection date of the start date in the month of the end date;
[0010] In the case where the projection date is before the end date, calculating the interval month between the month parameter of the projection date and the month parameter of the start date;
[0011] If the values of the interval month and the month parameter in the lease period are the same, it is determined that the lease contract is signed correctly.
[0012] Optionally, the end date is calculated based on the start date and lease term in the lease contract, including:
[0013] Calculate a virtual end date based on the start date and lease term in the lease contract, and determine whether the virtual end date actually exists;
[0014] If it exists, move the virtual end date forward one day to obtain the end date; or
[0015] If it does not exist, the number of days between the start date and the end of the month is calculated, so as to obtain the end date by adding the number of days from the end of the month to the preset value in the month where the virtual end date is located.
[0016] Optionally, determining the projection date of the start date in the month in which the end date is located includes:
[0017] Combine the year parameter and the month parameter in the end date and the day parameter in the start date to obtain a new date, and determine whether the new date actually exists;
[0018] If it exists, move the new date forward one day to obtain the projected date of the start date in the month of the end date; or
[0019] If it does not exist, calculate the number of days between the start date and the end of the month, and in the month where the new date is located, push the number of days + the preset value from the end of the month forward to obtain the projected date of the start date in the month where the end date is located.
[0020] Optionally, the preset value is 1.
[0021] Optionally, before combining the year parameter and the month parameter in the end date and the day parameter in the start date, the method further includes:
[0022] If the day parameter in the start date is a preset parameter, the month parameter in the end date is pushed back one month to obtain a new month parameter, and the year parameter is updated.
[0023] Optionally, the preset parameter is 1.
[0024] Optionally, after determining the projection date of the start date in the month where the end date is located, the method further includes:
[0025] If the projection date is after the end date, the month parameter in the end date is dialed back by one month to obtain a new month parameter, and the year parameter is updated;
[0026] Repeat the above steps of combining, judging and processing the date until the calculated projection date is before the end date.
[0027] Optionally, the lease period only includes a month parameter.
[0028] Optionally, the lease period includes a month parameter and a day parameter.
[0029] Optionally, the calculating the interval month between the monthly parameter of the projection date and the monthly parameter of the start date further includes: calculating the interval day between the projection date and the end date;
[0030] If the values of the interval month and the month parameter in the lease period are the same, then determining that the lease contract is correctly signed includes:
[0031] If the values of the month parameter in the interval month and the lease period are the same, and the values of the day parameter in the interval day and the lease period are the same, it is determined that the lease contract is signed correctly.
[0032] Optionally, after determining that the lease contract is correctly signed, the method further includes:
[0033] Determine the payment frequency and first payment date in the lease contract, and calculate the payment ledger of the lease contract in combination with the start date and the end date.
[0034] Optionally, determining the payment frequency and the first payment date in the lease contract, and calculating the payment ledger of the lease contract in combination with the start date and the end date, includes:
[0035] Determine the payment frequency and first payment date in the lease contract, and calculate the number of payment periods based on the interval month and the payment frequency;
[0036] Starting from the first payment date, the payment is accumulated step by step according to the payment frequency to obtain the payment ledgers for the number of payment periods;
[0037] Determine whether the date of the last payment account is greater than the end date. If it is less than or equal to the end date, no processing is performed. Otherwise, the year parameter and month parameter in the end date are used as the year parameter and month parameter of the last payment account.
[0038] Optionally, the calculating the number of payment periods according to the interval month and the payment frequency includes:
[0039] The quotient of the interval month and the payment frequency is calculated, and the quotient is rounded up to obtain the number of payment periods.
[0040] Optionally, after calculating the payment account of the lease contract, the method further includes:
[0041] Calculate the lease liability sheet for the lease contract based on the payment ledger and the current discount rate.
[0042] Optionally, the lease contract is a bank lease contract.
[0043] To achieve the above object, according to another aspect of an embodiment of the present invention, a lease contract processing device is provided, comprising:
[0044] A date calculation module, used to calculate the end date according to the start date and lease term in the lease contract, and determine the projection date of the start date in the month of the end date;
[0045] An interval month calculation module, used for calculating the interval month between the monthly parameter of the projection date and the monthly parameter of the start date when the projection date is before the end date;
[0046] The comparison module is used to determine that the lease contract is correctly signed if the values of the monthly parameters in the interval month and the lease period are the same.
[0047] Optionally, the date calculation module is used to:
[0048] Calculate a virtual end date based on the start date and lease term in the lease contract, and determine whether the virtual end date actually exists;
[0049] If it exists, move the virtual end date forward one day to obtain the end date; or
[0050] If it does not exist, the number of days between the start date and the end of the month is calculated, so as to obtain the end date by adding the number of days from the end of the month to the preset value in the month where the virtual end date is located.
[0051] Optionally, the date calculation module is used to:
[0052] Combine the year parameter and the month parameter in the end date and the day parameter in the start date to obtain a new date, and determine whether the new date actually exists;
[0053] If it exists, move the new date forward one day to obtain the projected date of the start date in the month of the end date; or
[0054] If it does not exist, calculate the number of days between the start date and the end of the month, and in the month where the new date is located, push the number of days + the preset value from the end of the month forward to obtain the projected date of the start date in the month where the end date is located.
[0055] Optionally, the preset value is 1.
[0056] Optionally, the date calculation module is further used to:
[0057] If the day parameter in the start date is a preset parameter, the month parameter in the end date is pushed back one month to obtain a new month parameter, and the year parameter is updated.
[0058] Optionally, the preset parameter is 1.
[0059] Optionally, a date callback module is also included for:
[0060] If the projection date is after the end date, the month parameter in the end date is dialed back by one month to obtain a new month parameter, and the year parameter is updated;
[0061] Repeat the above steps of combining, judging and processing the date until the calculated projection date is before the end date.
[0062] Optionally, the lease period only includes a month parameter.
[0063] Optionally, the lease period includes a month parameter and a day parameter.
[0064] Optionally, the interval month calculation module is further used to: calculate the interval day between the projection date and the end date;
[0065] The comparison module is used for:
[0066] If the values of the month parameter in the interval month and the lease period are the same, and the values of the day parameter in the interval day and the lease period are the same, it is determined that the lease contract is signed correctly.
[0067] Optionally, it also includes a ledger calculation module for:
[0068] Determine the payment frequency and first payment date in the lease contract, and calculate the payment ledger of the lease contract in combination with the start date and the end date.
[0069] Optionally, the ledger calculation module is used to:
[0070] Determine the payment frequency and first payment date in the lease contract, and calculate the number of payment periods based on the interval month and the payment frequency;
[0071] Starting from the first payment date, the payment is accumulated step by step according to the payment frequency to obtain the payment ledgers for the number of payment periods;
[0072] Determine whether the date of the last payment account is greater than the end date. If it is less than or equal to the end date, no processing is performed. Otherwise, the year parameter and month parameter in the end date are used as the year parameter and month parameter of the last payment account.
[0073] Optionally, the ledger calculation module is used to:
[0074] The quotient of the interval month and the payment frequency is calculated, and the quotient is rounded up to obtain the number of payment periods.
[0075] Optionally, a liability sheet calculation module is also included to:
[0076] Calculate the lease liability sheet for the lease contract based on the payment ledger and the current discount rate.
[0077] Optionally, the lease contract is a bank lease contract.
[0078] To achieve the above objective, according to another aspect of an embodiment of the present invention, a lease contract processing electronic device is provided.
[0079] The electronic device of an embodiment of the present invention includes: 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 any of the above-mentioned lease contract processing methods.
[0080] To achieve the above objective, according to another aspect of an embodiment of the present invention, there is provided a computer-readable medium on which a computer program is stored, and when the program is executed by a processor, any of the above-mentioned lease contract processing methods is implemented.
[0081] According to the scheme provided by the present invention, an embodiment of the above invention has the following advantages or beneficial effects: the calculation of the payment ledger needs to be judged according to the contract end date, and the calculation of the lease balance sheet depends on the payment ledger and the lease period. This scheme calculates the lease period by the start date and end date and calculates the end date by the start date and lease period, so as to accurately calculate the lease contract payment ledger and the lease balance sheet.
[0082] 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
[0083] The accompanying drawings are used to better understand the present invention and do not constitute an improper limitation of the present invention.
[0084] Figure 1 is a schematic diagram of the main flow of a method for calculating an end date according to an embodiment of the present invention;
[0085] Figure 2 This is a schematic diagram of the main process of a method for processing a lease contract according to an embodiment of the present invention;
[0086] Figure 3 is a flowchart of a specific method for processing a lease contract according to an embodiment of the present invention;
[0087] Figure 4 is a flowchart of an optional leasing contract processing method according to an embodiment of the present invention;
[0088] Figure 5 is a schematic diagram of main modules of a lease contract processing device according to an embodiment of the present invention;
[0089] Figure 6 is an exemplary system architecture diagram to which embodiments of the present invention may be applied;
[0090] Figure 7 It is a schematic diagram of the structure of a computer system of a mobile device or a server suitable for implementing an embodiment of the present invention. DETAILED DESCRIPTION
[0091] 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.
[0092] Here is a detailed description of the existing calculation method:
[0093] 1) Existing functions calculate the end date based on the start date and lease term (number of months) of the lease contract. For example, the EDATE function of EXCEL: when 1 < start date (day) ≤ 28th, directly push to the corresponding date of a certain month based on the lease term (month), that is, the end date; when the start date (day) > 28th, and push to a certain month based on the lease term (month), it is found that there is no such day in that month, then the end date is the last day of that month, that is, 28th (non-leap year), 29th (leap year), 30th, 31st.
[0094] Table 1 Date table
[0095]
[0096]
[0097] A. The calculated end date actually exists, as shown in Table 2 below:
[0098] Table 2
[0099]
[0100] B. The calculated end date does not exist. As shown in Table 3 below, existing functions such as add_months in oralce, Calendar.add(Calendar.MONTH,5) in java, and EDATE function in xls cannot calculate an end date that meets the requirements:
[0101] Table 3
[0102]
[0103] 2) Existing functions calculate the lease term (month) based on the start date and end date of the lease contract. For example, the DATEDIF function of EXCEL: when the start date (day) ≤ the end date (day), the lease term (month) = (end date (year) - start date (year)) * 12 + end date (month) - start date (month); when the start date (day) > the end date (day), the lease term (month) = (end date (year) - start date (year)) * 12 + end date (month) - start date (month) - 1. Only when the year, month and day are matched, the calculation result is a whole month, otherwise it is only a number of days, as shown in Table 4 below:
[0104] Table 4 Calculation results of lease term
[0105]
[0106] Since the number of days in each month is different, it is not possible to use existing functions to calculate the number of months from the number of days.
[0107] Table 5
[0108]
[0109] As shown in Table 5 above, when the start date is 2019 / 1 / 29, 2019 / 1 / 30 or 2019 / 1 / 31 and the lease period is 1 month, the calculated end date is 2019 / 2 / 28. However, when the start date is 2019 / 1 / 29, 2019 / 1 / 30 or 2019 / 1 / 31 and the end date is 2019 / 2 / 28, the calculated lease period is 0 months. It can be seen that the derivation methods of methods 2) and 1) are logically inconsistent, resulting in calculation differences and cannot be verified with each other.
[0110] 3) When the start dates are different, the end dates may be the same, as shown in Table 6 below:
[0111] Table 6
[0112]
[0113] See also Figure 1 , which shows a main flow chart of calculating an end date provided by an embodiment of the present invention, including the following steps:
[0114] S101: Calculate a virtual end date based on the start date and lease term in the lease contract, and determine whether the virtual end date actually exists;
[0115] S102: If it exists, move the virtual end date forward by one day to obtain the end date;
[0116] S103: If it does not exist, calculate the number of days between the start date and the end of the month;
[0117] S104: In the month where the virtual end date is located, the number of days + 1 is incremented from the end of the month to obtain the end date.
[0118] In the above implementation, for steps S101 to S104, in actual operation, the lease period may only include monthly parameters, for example, 4 months and 3 days rounded up to 5 months or rounded down to 4 months, but in some cases it may include monthly parameters and daily parameters, such as 4 months and 3 days. Both methods are applicable to this solution.
[0119] Calculate the virtual end date based on the start date and lease term of the lease contract to determine whether the virtual end date actually exists:
[0120] 1. If the virtual end date actually exists, just push it forward one day to get the end date:
[0121] ① 2018 / 1 / 1, the lease period is 1 month, first calculate the virtual end date 2018 / 2 / 1, and one day earlier is 2018 / 1 / 31;
[0122] ②2019 / 2 / 28, the lease period is 1 month. First calculate the virtual end date 2019 / 3 / 28, and one day earlier is 2019 / 3 / 27. The result is in line with the contract signing practice, as shown in Table 2;
[0123] ③2018 / 3 / 30, the lease period is 1 month, first calculate the virtual end date 2018 / 4 / 30, and move forward one day to 2018 / 4 / 29.
[0124] 2. If the virtual end date does not exist, then move forward X+1 days from the end of the month in which it is located (X = the end of the month of the start date (day) - the start date (day):
[0125] ① On January 30, 2018, the lease term is 1 month. First, the virtual end date 2018 / 2 / 30 is calculated. If it does not exist, it is pushed back 2 days from the 28th day of the month (X=1=31-30) to 2018 / 2 / 26 (26=28-2). The result is the same as the contract signing practice, as shown in Table 3;
[0126] ②2018 / 3 / 31, the lease period is 1 month. First calculate the virtual end date 2018 / 4 / 31. If it does not exist, move forward one day from the 30th of the month (X=0=31-31) to 2018 / 4 / 29 (29=30-1);
[0127] As shown in Table 6, the results calculated by this solution are:
[0128] Table 7
[0129]
[0130] It should be noted that the end date calculated above is only for the subsequent calculation of the lease term and to verify whether the lease term is used correctly. It is different from the actual end date signed in the lease contract. For example, the start date of the contract is 2019 / 1 / 29 and the actual end date is 2019 / 2 / 28, but the end date calculated by this solution is 2019 / 2 / 25.
[0131] The method provided by the above embodiment not only has one-to-one corresponding dates at the beginning and middle of the month, but also can find corresponding dates at the end of the month. All end dates are evenly dispersed and aligned, which conforms to the habit of counting the beginning but not the end when signing a contract, and when the start date is different, the end date is also different.
[0132] See also Figure 2 , shows a schematic diagram of a lease contract processing method according to an embodiment of the present invention, including the following steps:
[0133] S201: Calculate the end date according to the start date and lease term in the lease contract, and determine the projection date of the start date in the month where the end date is located;
[0134] S202: When the projection date is before the end date, calculate the interval month between the month parameter of the projection date and the month parameter of the start date;
[0135] S203: If the values of the interval month and the month parameter in the lease period are the same, it is determined that the lease contract is signed correctly.
[0136] In the above embodiment, for step S201, according to Figure 1 After the logic shown calculates to the end date, it first determines whether the day parameter in the start date is the 1st:
[0137] 1) If yes, push the month parameter in the end date back one month and update the year parameter to get a new end year and month. For example, 2019 / 1 / 1-2019 / 12 / 3, because the start date is the 1st, the end year and month will be postponed to 2020 / 1;
[0138] When calculating the end date based on the contract start date and the lease period, the 1st plus any number of months will equal the 1st, and there may be a situation where the month spans. Therefore, when calculating the lease period, if the start date is the 1st, the end date needs to be extended, that is, pushed back one month.
[0139] 2) If not or after a new end year and month is obtained, combine the year parameter and month parameter in the end date and the day parameter in the start date to obtain a new date. For example, the number 1 in the above 2019 / 1 / 1 is combined with the postponed 2020 / 1 to obtain the new date 2020 / 1 / 1.
[0140] Determine whether the new date actually exists:
[0141] If it does exist, move the new date forward one day to get the projected date of the start date in the month of the end date. For example, move the above 2020 / 1 / 1 forward one day to get the projected date 2019 / 12 / 31;
[0142] If II does not exist, calculate the number of days from the start date to the end of the month, and in the month of the new date, push forward the number of days from the end of the month + 1 to get the projected date of the start date in the month of the end date. For example, 2019 / 1 / 29-2019 / 2 / 28, because the start date is not the 1st, the new date 2019 / 2 / 29 is an illegal date. 1 / 29 is 2 days away from the end of the month 1 / 31, so push forward (2+1) days from 2 / 28 to get the projected date 2019 / 2 / 25.
[0143] For step S202, before calculating the interval month between the month parameter of the projection date and the month parameter of the start date, it is necessary to determine whether the projection date is after the end date:
[0144] 1) If it is, dial back the month parameter in the end date by one month to obtain a new month parameter, and update the year parameter, and then repeat the above steps until the calculated projection date is before the end date;
[0145] 2) If it is not located or the operation is repeated multiple times to meet the requirements, calculate the interval month between the month parameter of the projection date and the month parameter of the start date.
[0146] For example, 2019 / 1 / 1-2019 / 12 / 3, because the start date is the 1st, the end year and month is postponed to 2020 / 1, and the new date is 2020 / 1 / 1. 2020 / 1 / 1 is pushed forward one day to get the projected date 2019 / 12 / 31, which exceeds the end date 2019 / 12 / 3, so the end date 2019 / 12 is dialed back one month to get 2019 / 11. Continuing the above processing steps, because the start date is the 1st, 2019 / 11 is postponed to 2019 / 12, and the new date is 2019 / 12 / 1. 2019 / 12 / 1 is pushed forward one day to get the projected date 2019 / 11 / 30, which does not exceed the end date 2019 / 12 / 3. The difference between the projected date 2019 / 11 / 30 and the start date 2019 / 1 / 1 is 11 months.
[0147] For example, 2019 / 1 / 29-2019 / 2 / 28, because the start date is not the 1st, the new date 2019 / 2 / 29 is an illegal date. 1 / 29 is 2 days away from the end of the month 1 / 31, so push forward (2+1) days from 2 / 28 to get the projected date 2019 / 2 / 25, which does not exceed the end date 2019 / 2 / 28. The projected date 2019 / 2 / 25 and the start date 2019 / 1 / 29 differ by 1 month.
[0148] In addition, the above steps only consider the monthly parameters of the lease period, for example, 2019 / 1 / 1-2019 / 12 / 3, the calculated lease period is 11 months. In actual operation, both monthly and daily parameters can be considered at the same time, and no rounding up or down will be performed. For example, 2019 / 1 / 1-2019 / 12 / 3, the calculated lease period is 11 months and 3 days, where the 3 days are the interval between the projection date 2019 / 11 / 30 and the end date 2019 / 12 / 3.
[0149] For step S203, this solution is to calculate the lease term based on the start date and end date of the lease contract. Figure 1 The logic shown is reversed to determine whether the calculated lease term is the same as the original lease term in the contract. If they are the same, the subsequent calculation steps can be continued. For details, see Figure 4 shown.
[0150] The method provided in the above embodiment maps a certain number of months from the start date to the month of the end date, and corrects special circumstances to obtain the final lease period. Unlike the addition operation for calculating the end date, a subtraction operation is performed here, and the calculation results of the two remain consistent.
[0151] See also Figure 3 , shows a schematic diagram of a specific leasing contract processing method according to an embodiment of the present invention, including the following steps:
[0152] S301: Calculate the end date according to the start date and lease term in the lease contract, and determine whether the day parameter in the start date is 1;
[0153] S302: If yes, push the month parameter in the end date back one month to obtain a new month parameter, and update the year parameter;
[0154] S303: Combine the year parameter and the month parameter in the end date and the day parameter in the start date to obtain a new date, and determine whether the new date actually exists;
[0155] S304: If it exists, move the new date forward one day to obtain the projection date of the start date in the month where the end date is located;
[0156] S305: If it does not exist, calculate the number of days from the start date to the end of the month, and in the month where the new date is located, push the number of days + 1 from the end of the month to obtain the projected date of the start date in the month where the end date is located;
[0157] S306: Determine whether the projection date is after the end date;
[0158] S307: If yes, dial back the month parameter in the end date by one month to obtain a new month parameter, and update the year parameter, and repeat the above steps until the calculated projection date is before the end date;
[0159] S308: When the projection date is before the end date, calculate the interval month between the month parameter of the projection date and the month parameter of the start date;
[0160] S309: If the values of the interval month and the month parameter in the lease period are the same, it is determined that the lease contract is signed correctly.
[0161] See also Figure 4 , shows a schematic flow chart of an optional leasing contract processing method according to an embodiment of the present invention, comprising the following steps:
[0162] S401: Calculate the end date according to the start date and lease term in the lease contract, and determine the projection date of the start date in the month where the end date is located;
[0163] S402: When the projection date is before the end date, calculate the interval month between the month parameter of the projection date and the month parameter of the start date;
[0164] S403: If the values of the interval month and the month parameter in the lease period are the same, it is determined that the lease contract is signed correctly;
[0165] S404: Determine the payment frequency and the first payment date in the lease contract, calculate the quotient of the lease term and the payment frequency, and round up the quotient to obtain the number of payment periods;
[0166] S405: Starting from the first payment date, the payment frequency is accumulated step by step to obtain the payment ledgers for the number of payment periods;
[0167] S406: Determine whether the date of the last payment account is greater than the end date. If it is less than or equal to the end date, no processing is performed;
[0168] S407: Otherwise, the year parameter and month parameter in the end date are used as the year parameter and month parameter of the last payment account.
[0169] In the above implementation, for steps S401 to S403, reference may be made to the description of steps S201 to S203, which will not be repeated here.
[0170] In the above implementation, for steps S404 to S407, the payment frequency is 12 months for annual payment, 6 months for semi-annual payment, 3 months for quarterly payment, 1 month for monthly payment, and the frequency of other (regular) months is a positive integer entered by the user.
[0171] In actual operation, the quotient of lease term / payment frequency may not be an integer. For example, lease term is 11 months / quarterly payment is 3 months = 3.6. Round it up to get the number of payment periods N = 4. First, calculate 4 payment records:
[0172] The planned payment year and month of the first account = the year and month of the first payment date, and the amount excluding tax = the payment amount per period;
[0173] The planned payment year and month of the second account = the planned payment year and month of the previous account + the frequency, excluding tax amount = the payment amount per period;
[0174] …
[0175] The planned payment year and month of the 4th ledger = the planned payment year and month of the previous ledger + the frequency, and the amount excluding tax = the payment amount per period.
[0176] Determine whether the planned payment year and month of the last account is greater than the year and month of the end date. If so, set the year and month of the end date to the planned payment year and month of the last account. For example, if the end date is 2022 / 2 / 24 and the planned payment year and month calculated for the last account is 2022 / 3, then set the planned payment year and month of the last account to 2022 / 2.
[0177] For example, the start date in the lease contract is 2021 / 2 / 1, the end date is 2022 / 2 / 24, the payment frequency is quarterly, the first rent payment amount after the contract takes effect is 1,000 yuan, and the first payment date is 2021 / 3 / 18. The generated ledger details are:
[0178] Table 8
[0179]
[0180] It can be seen that when calculating the lease contract payment ledger, it is necessary to calculate the lease coverage period (end) based on the lease coverage period (start) + payment frequency. The lease coverage period (start) of the first ledger is the contract start date, and the next lease coverage period (start) = the previous lease coverage period (end) + 1 day. The lease coverage period (start / end) and planned payment year and month of the payment ledger must be between the contract start date and end date, that is, the term of the payment ledger is consistent with the lease period.
[0181] The method provided in the above embodiment calculates the payment ledger according to the start date and payment frequency in the lease contract until the planned payment year and month of a certain item exceeds the contract period, thereby obtaining multiple more reasonable payment ledgers.
[0182] The method provided in the embodiment of the present invention calculates the payment ledger based on the contract end date, while the calculation of the lease balance sheet depends on the payment ledger and the lease period. This solution calculates the lease period by the start date and the end date and calculates the end date by the start date and the lease period, thereby realizing accurate calculation of the lease contract payment ledger and the lease balance sheet.
[0183] See also Figure 5 , which shows a schematic diagram of main modules of a lease contract processing device 500 provided in an embodiment of the present invention, including:
[0184] The date calculation module 501 is used to calculate the end date according to the start date and the lease period in the lease contract, and determine the projection date of the start date in the month where the end date is located;
[0185] An interval month calculation module 502, for calculating the interval month between the month parameter of the projection date and the month parameter of the start date when the projection date is before the end date;
[0186] The comparison module 503 is used to determine that the lease contract is correctly signed if the values of the interval month and the month parameter in the lease period are the same.
[0187] In the device of the embodiment of the present invention, the date calculation module 501 is used to:
[0188] Calculate a virtual end date based on the start date and lease term in the lease contract, and determine whether the virtual end date actually exists;
[0189] If it exists, move the virtual end date forward one day to obtain the end date; or
[0190] If it does not exist, the number of days between the start date and the end of the month is calculated, so as to obtain the end date by adding the number of days from the end of the month to the preset value in the month where the virtual end date is located.
[0191] In the device of the embodiment of the present invention, the date calculation module 501 is used to:
[0192] Combine the year parameter and the month parameter in the end date and the day parameter in the start date to obtain a new date, and determine whether the new date actually exists;
[0193] If it exists, move the new date forward one day to obtain the projected date of the start date in the month of the end date; or
[0194] If it does not exist, calculate the number of days between the start date and the end of the month, and in the month where the new date is located, push the number of days + the preset value from the end of the month forward to obtain the projected date of the start date in the month where the end date is located.
[0195] In the device of the embodiment of the present invention, the preset value is 1.
[0196] In the device of the embodiment of the present invention, the date calculation module 501 is further used for:
[0197] If the day parameter in the start date is a preset parameter, the month parameter in the end date is pushed back one month to obtain a new month parameter, and the year parameter is updated.
[0198] In the device of the embodiment of the present invention, the preset parameter is No. 1.
[0199] The device of the embodiment of the present invention further includes a date callback module 504 (not shown in the figure), which is used to:
[0200] If the projection date is after the end date, the month parameter in the end date is dialed back by one month to obtain a new month parameter, and the year parameter is updated;
[0201] Repeat the above steps of combining, judging and processing the date until the calculated projection date is before the end date.
[0202] In the device of the embodiment of the present invention, the lease period only includes a monthly parameter.
[0203] In the device of the embodiment of the present invention, the lease period includes a monthly parameter and a daily parameter.
[0204] In the device of the embodiment of the present invention, the interval month calculation module 502 is further used to: calculate the interval day between the projection date and the end date;
[0205] The comparison module 503 is used to determine that the lease contract is correctly signed if the values of the month parameter in the interval month and the lease period are the same, and the values of the day parameter in the interval day and the lease period are the same.
[0206] In the device of the embodiment of the present invention, the ledger calculation module is used to:
[0207] Determine the payment frequency and first payment date in the lease contract, and calculate the payment ledger of the lease contract in combination with the start date and the end date.
[0208] In the device of the embodiment of the present invention, the ledger calculation module is used to:
[0209] Determine the payment frequency and first payment date in the lease contract, and calculate the number of payment periods based on the interval month and the payment frequency;
[0210] Starting from the first payment date, the payment is accumulated step by step according to the payment frequency to obtain the payment ledgers for the number of payment periods;
[0211] Determine whether the date of the last payment account is greater than the end date. If it is less than or equal to the end date, no processing is performed. Otherwise, the year parameter and month parameter in the end date are used as the year parameter and month parameter of the last payment account.
[0212] In the device of the embodiment of the present invention, the ledger calculation module is used to:
[0213] The quotient of the interval month and the payment frequency is calculated, and the quotient is rounded up to obtain the number of payment periods.
[0214] The device of the embodiment of the present invention further includes a liability sheet calculation module, which is used to:
[0215] Calculate the lease liability sheet for the lease contract based on the payment ledger and the current discount rate.
[0216] In the device of the embodiment of the present invention, the lease contract is a bank lease contract.
[0217] In addition, the specific implementation content of the device described in the embodiment of the present invention has been described in detail in the method described above, so the repeated content will not be described again here.
[0218] Figure 6 An exemplary system architecture 600 is shown in which embodiments of the present invention may be applied.
[0219] like Figure 6 As shown, the system architecture 600 may include terminal devices 601, 602, 603, a network 604 and a server 605 (just an example). The network 604 is used to provide a medium for communication links between the terminal devices 601, 602, 603 and the server 605. The network 604 may include various connection types, such as wired, wireless communication links or optical fiber cables, etc.
[0220] The user can use the terminal devices 601, 602, 603 to interact with the server 605 through the network 604 to receive or send messages, etc. Various communication client applications can be installed on the terminal devices 601, 602, 603.
[0221] The terminal devices 601, 602, 603 may be various electronic devices having display screens and supporting web browsing, and the server 605 may be a server providing various services.
[0222] It should be noted that the method provided in the embodiment of the present invention is generally executed by the server 605 , and accordingly, the device is generally set in the server 605 .
[0223] It should be understood that Figure 6 The number of terminal devices, networks and servers in the embodiment is only for illustration. Any number of terminal devices, networks and servers may be provided according to implementation requirements.
[0224] Reference below Figure 7 , which shows a schematic diagram of the structure of a computer system 700 of a terminal device suitable for implementing an embodiment of the present invention. Figure 7 The terminal 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.
[0225] like Figure 7 As shown, the computer system 700 includes a central processing unit (CPU) 701, which can perform various appropriate actions and processes according to a program stored in a read-only memory (ROM) 702 or a program loaded from a storage part 708 into a random access memory (RAM) 703. In the RAM 703, various programs and data required for the operation of the system 700 are also stored. The CPU 701, the ROM 702, and the RAM 703 are connected to each other via a bus 704. An input / output (I / O) interface 705 is also connected to the bus 704.
[0226] The following components are connected to the I / O interface 705: an input section 706 including a keyboard, a mouse, etc.; an output section 707 including a cathode ray tube (CRT), a liquid crystal display (LCD), etc., and a speaker, etc.; a storage section 708 including a hard disk, etc.; and a communication section 709 including a network interface card such as a LAN card, a modem, etc. The communication section 709 performs communication processing via a network such as the Internet. A drive 710 is also connected to the I / O interface 705 as needed. A removable medium 711, such as a magnetic disk, an optical disk, a magneto-optical disk, a semiconductor memory, etc., is installed on the drive 710 as needed, so that a computer program read therefrom is installed into the storage section 708 as needed.
[0227] In particular, according to the embodiments disclosed in the present invention, the process described above with reference to the flowchart 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 flowchart. In such an embodiment, the computer program can be downloaded and installed from the network through the communication part 709, and / or installed from the removable medium 711. When the computer program is executed by the central processing unit (CPU) 701, the above-mentioned functions defined in the system of the present invention are executed.
[0228] 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.
[0229] 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.
[0230] The modules involved in the embodiments of the present invention may be implemented by software or hardware. The modules described may also be set in a processor, for example, it may be described as: a processor includes a date calculation module, an interval month calculation module, and a comparison module. The names of these modules do not constitute a limitation on the modules themselves in some cases, for example, the date calculation module may also be described as an "end date and projection date calculation module".
[0231] As another aspect, the present invention further provides a computer-readable medium, which may be included in the device described in the above embodiment; or 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:
[0232] Calculate the end date based on the start date and lease term in the lease contract, and determine the projection date of the start date in the month of the end date;
[0233] In the case where the projection date is before the end date, calculating the interval month between the month parameter of the projection date and the month parameter of the start date;
[0234] If the values of the interval month and the month parameter in the lease period are the same, it is determined that the lease contract is signed correctly.
[0235] According to the technical solution of the embodiment of the present invention, the calculation of the payment ledger needs to be determined based on the contract end date, while the calculation of the lease balance sheet depends on the payment ledger and the lease period. This solution calculates the lease period through the start date and end date and calculates the end date through the start date and lease period, thereby realizing the accurate calculation of the lease contract payment ledger and the lease balance sheet.
[0236] 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 method for processing a lease contract, characterized in that: include: The end date is calculated based on the start date and lease period in the lease contract, and the projection date of the start date in the month where the end date is located is determined; wherein, the end date is calculated based on the start date and lease period in the lease contract, including: according to the start date and lease period in the lease contract, a virtual end date is calculated, and whether the virtual end date actually exists; wherein the virtual end date is the sum of the start date and the lease period; if it exists, the virtual end date is pushed forward by one day to obtain the end date; if it does not exist, the number of days from the start date to the end of the month is calculated, so as to push the number of days + a preset value forward from the end of the month in the month where the virtual end date is located to obtain the end date; The determining of the projected date of the start date in the month where the end date is located includes: combining the year parameter and the month parameter in the end date and the day parameter in the start date to obtain a new date, and judging whether the new date actually exists; if it does, pushing the new date forward by one day to obtain the projected date of the start date in the month where the end date is located; if it does not exist, calculating the number of days from the start date to the end of the month where the start date is located, so as to push the number of days + a preset value forward from the end of the month where the new date is located to obtain the projected date of the start date in the month where the end date is located; In the case where the projection date is before the end date, calculating the interval month between the month parameter of the projection date and the month parameter of the start date; If the values of the interval month and the month parameter in the lease period are the same, it is determined that the lease contract is signed correctly.
2. The method according to claim 1, characterized in that The preset value is 1.
3. The method according to claim 1, characterized in that Before combining the year parameter and the month parameter in the end date and the day parameter in the start date, the method further includes: If the day parameter in the start date is a preset parameter, the month parameter in the end date is pushed back one month to obtain a new month parameter, and the year parameter is updated.
4. The method according to claim 3, characterized in that The preset parameter is No.
1.
5. The method according to claim 1, characterized in that After determining the projection date of the start date in the month where the end date is located, the method further includes: If the projection date is after the end date, the month parameter in the end date is dialed back by one month to obtain a new month parameter, and the year parameter is updated; Repeat the above steps of combining, judging and processing the date until the calculated projection date is before the end date.
6. The method according to claim 1, characterized in that The lease period contains only month parameters.
7. The method according to claim 1, characterized in that The lease period includes a month parameter and a day parameter.
8. The method according to claim 7, characterized in that The calculating the interval month between the monthly parameter of the projection date and the monthly parameter of the start date further comprises: calculating the interval day between the projection date and the end date; If the values of the interval month and the month parameter in the lease period are the same, then determining that the lease contract is correctly signed includes: If the values of the month parameter in the interval month and the lease period are the same, and the values of the day parameter in the interval day and the lease period are the same, it is determined that the lease contract is signed correctly.
9. The method according to claim 1, characterized in that: After determining that the lease contract is correctly signed, the method further includes: Determine the payment frequency and first payment date in the lease contract, and calculate the payment ledger of the lease contract in combination with the start date and the end date.
10. The method according to claim 9, characterized in that The determining of the payment frequency and the first payment date in the lease contract, and the calculation of the payment ledger of the lease contract in combination with the start date and the end date, includes: Determine the payment frequency and first payment date in the lease contract, and calculate the number of payment periods based on the interval month and the payment frequency; Starting from the first payment date, the payment is accumulated step by step according to the payment frequency to obtain the payment ledgers for the number of payment periods; Determine whether the date of the last payment account is greater than the end date. If it is less than or equal to the end date, no processing is performed. Otherwise, the year parameter and month parameter in the end date are used as the year parameter and month parameter of the last payment account.
11. The method according to claim 9, characterized in that The step of calculating the number of payment periods according to the interval month and the payment frequency includes: The quotient of the interval month and the payment frequency is calculated, and the quotient is rounded up to obtain the number of payment periods.
12. The method according to claim 9, characterized in that After calculating the payment account of the lease contract, the method further includes: Calculate the lease liability sheet for the lease contract based on the payment ledger and the current discount rate.
13. The method according to claim 1, characterized in that The lease contract is a bank lease contract.
14. A lease contract processing device, characterized in that: include: A date calculation module, for calculating the end date according to the start date and lease period in the lease contract, and determining the projection date of the start date in the month where the end date is located; wherein, the calculation of the end date according to the start date and lease period in the lease contract includes: calculating a virtual end date according to the start date and lease period in the lease contract, and judging whether the virtual end date actually exists; wherein the virtual end date is the sum of the start date and the lease period; if it exists, the virtual end date is pushed forward by one day to obtain the end date; if it does not exist, the number of days from the start date to the end of the month is calculated, so as to push the number of days + a preset value forward from the end of the month in the month where the virtual end date is located to obtain the end date; The determining of the projected date of the start date in the month where the end date is located includes: combining the year parameter and the month parameter in the end date and the day parameter in the start date to obtain a new date, and judging whether the new date actually exists; if it does, pushing the new date forward by one day to obtain the projected date of the start date in the month where the end date is located; if it does not exist, calculating the number of days from the start date to the end of the month where the start date is located, so as to push the number of days + a preset value forward from the end of the month where the new date is located to obtain the projected date of the start date in the month where the end date is located; An interval month calculation module, used for calculating the interval month between the monthly parameter of the projection date and the monthly parameter of the start date when the projection date is before the end date; The comparison module is used to determine that the lease contract is correctly signed if the values of the monthly parameters in the interval month and the lease period are the same.
15. 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.
16. 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
Business processing method, device and equipment, and readable medium
CN107038552A
Charging method and device based on combined office space, calculation equipment
CN107093105A
Vehicle lease data processing method and device based on block chain and storage medium
CN110597883A
Time period division method and system, electronic equipment and readable storage medium
CN111260358A
Contract information auditing method and device, electronic equipment and storage medium
CN111292068A
