CN114331398A - Fee settlement data processing method, device, equipment and storage medium - Google Patents

Fee settlement data processing method, device, equipment and storage medium Download PDF

Info

Publication number
CN114331398A
CN114331398A CN202111508196.1A CN202111508196A CN114331398A CN 114331398 A CN114331398 A CN 114331398A CN 202111508196 A CN202111508196 A CN 202111508196A CN 114331398 A CN114331398 A CN 114331398A
Authority
CN
China
Prior art keywords
settlement
data
statement
information
settlement data
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN202111508196.1A
Other languages
Chinese (zh)
Inventor
李庄
杨周龙
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Dongpu Software Co Ltd
Original Assignee
Dongpu Software Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Dongpu Software Co Ltd filed Critical Dongpu Software Co Ltd
Priority to CN202111508196.1A priority Critical patent/CN114331398A/en
Publication of CN114331398A publication Critical patent/CN114331398A/en
Pending legal-status Critical Current

Links

Images

Landscapes

  • Information Retrieval, Db Structures And Fs Structures Therefor (AREA)

Abstract

The invention relates to the technical field of computers, and discloses a method, a device, equipment and a storage medium for processing expense settlement data, wherein the method comprises the following steps: acquiring a plurality of settlement objects, starting a timing task according to each settlement object to acquire settlement data corresponding to the settlement object, and storing the settlement data into a csv file; traversing settlement data in the csv file, updating the settlement data into a settlement list, and determining index information; after the settlement statement is updated, pushing the settlement statement to a settlement terminal; receiving confirmation information of the settlement terminal, determining a settlement amount corresponding to a settlement object based on the settlement detail table, and performing automatic settlement to obtain a settlement result; generating a block by using the settlement object, uploading the block to a block chain, and writing a settlement result into the block chain; the invention effectively improves the efficiency and the accuracy of processing settlement data, improves the safety of the settlement data and improves the efficiency of inquiring the page report.

Description

Fee settlement data processing method, device, equipment and storage medium
Technical Field
The invention relates to the technical field of computers, in particular to a method, a device, equipment and a storage medium for processing expense settlement data.
Background
Express delivery, also known as express delivery, refers to a transportation mode in which a logistics enterprise (including a freight agent) delivers a file or a package entrusted by a user from a sender to a receiver quickly and safely through an independent network of the logistics enterprise or in a combined cooperation (i.e., networking) mode; with the development of science and technology, many self-service express cabinets have been derived, and a self-service express cabinet (intelligent express box) is a self-service device which is arranged in a public place and can be used for delivering and picking up express mails so as to prevent articles from being lost.
The logistics enterprise can cooperate with a plurality of third party express delivery cabinet companies (check, cloud cabinet, rich friend, rich nest) simultaneously, so the single volume is bigger, when the express delivery cabinet is used, certain fee is generated, the fee settlement is required to be carried out with different third party express delivery cabinet companies, the fee settlement is very complicated and disordered, the fee deduction detail query efficiency of the third party express delivery cabinet companies is low, the safety of settlement data is not high, and no compensation mechanism exists when a certain settlement order fails.
Disclosure of Invention
In view of the above, it is desirable to provide a fee settlement data processing method, device, apparatus, and storage medium for solving the problems of low query efficiency, low security of settlement data, and the like.
A fee settlement data processing method, comprising the steps of:
acquiring a plurality of settlement objects, starting a timing task according to each settlement object to acquire settlement data corresponding to the settlement object, and storing the settlement data into a csv file;
traversing settlement data in the csv file, updating the settlement data into a settlement list, and determining index information;
after the settlement statement is updated, pushing the settlement statement to the settlement terminal;
receiving confirmation information of the settlement terminal, determining a settlement amount corresponding to the settlement object based on the settlement statement, and performing automatic settlement to obtain a settlement result;
and generating a block by using the settlement object, uploading the block to a block chain, and writing the settlement result into the block chain.
In one embodiment, a plurality of settlement objects are obtained, and a settlement period corresponding to each settlement object is determined;
starting a timing task according to each settlement object, and determining the corresponding execution time of each timing task, wherein the timing task is used for acquiring settlement data in the settlement period during the execution;
sequencing the timing tasks based on the execution time to obtain a sequencing result;
and generating a distributed lock based on the sequencing result.
In one embodiment, a report generation request is received, and attribute information of keywords in the report generation request is determined;
determining corresponding target header data according to a pre-configured configuration information table based on the attribute information of the keywords;
generating a settlement statement according to the target header data and the configuration information table, wherein the settlement statement at least comprises date information, a settlement order number and a website code;
and generating a corresponding sql statement based on the target header data, wherein the sql statement is used for inquiring data corresponding to the target header data.
In one embodiment, a website code in each piece of settlement data is extracted, and a plurality of pieces of settlement data are classified according to the website codes to obtain a plurality of data sets, each data set corresponds to one website code, wherein each settlement object at least comprises one website code;
and configuring each piece of settlement data in the data set based on the website codes to generate a corresponding settlement order number.
In one embodiment, target header data in the settlement list is read, and the settlement data is updated to a corresponding data cell based on the target header data to generate a settlement list corresponding to the settlement object;
storing the settlement list into a redis cache layer and a query database, wherein the query database is constructed in advance;
acquiring date information in the settlement list, and dividing the settlement data into a plurality of partitions according to the date information, wherein the date information is a date for generating fees, and each partition at least comprises one piece of settlement data;
and using the date information as index information of the settlement data and associating the date information with the settlement data.
In one embodiment, if the settlement result is settlement failure, sending manual operation information to a manual interface, and screening out the settlement list number with settlement failure to prompt a user to perform manual settlement on the settlement list number with settlement failure.
A charge settlement data processing apparatus, comprising:
the starting module is used for acquiring a plurality of settlement objects, starting a timing task according to each settlement object to acquire settlement data corresponding to the settlement object, and storing the settlement data into a csv file;
the updating module is used for traversing settlement data in the csv file, updating the settlement data into a settlement list and determining index information;
the pushing module is used for pushing the settlement statement to the settlement terminal after the settlement statement is updated;
the settlement module is used for receiving the confirmation information of the settlement terminal, determining the settlement amount corresponding to the settlement object based on the settlement detail table, and performing automatic settlement to obtain a settlement result;
and the uploading module is used for generating a block by using the settlement object and uploading the block to a block chain, and writing the settlement result into the block chain.
In one embodiment, the update module includes:
the updating submodule is used for reading target header data in the settlement statement and updating the settlement data to a corresponding data cell based on the target header data so as to generate the settlement statement corresponding to the settlement object;
a storing submodule, configured to store the settlement list in a redis cache layer and a query database, where the query database is pre-constructed;
the dividing submodule is used for acquiring date information in the settlement list and dividing the settlement data into a plurality of subareas according to the date information, wherein the date information is the date for generating the expense, and each subarea at least comprises one piece of settlement data;
and the association submodule is used for associating the date information with the settlement data as the index information of the settlement data.
A charge settlement data processing apparatus, comprising: a memory having instructions stored therein and at least one processor, the memory and the at least one processor interconnected by a line; the at least one processor invokes the instructions in the memory to cause the charge settlement data processing apparatus to perform the steps of the charge settlement data processing method described above.
A computer-readable storage medium, on which a computer program is stored which, when being executed by a processor, carries out the steps of the charge settlement data processing method described above.
According to the expense settlement data processing method, the expense settlement data processing device, the expense settlement data processing equipment and the storage medium, a plurality of settlement objects are obtained, a timing task is started according to each settlement object, so that settlement data corresponding to the settlement objects are obtained, and the settlement data are stored in a csv file; traversing settlement data in the csv file, updating the settlement data into a settlement list, and determining index information; after the settlement statement is updated, pushing the settlement statement to the settlement terminal; receiving confirmation information of the settlement terminal, determining a settlement amount corresponding to the settlement object based on the settlement statement, and performing automatic settlement to obtain a settlement result; generating a block by using the settlement object, uploading the block to a block chain, and writing the settlement result into the block chain; the invention effectively improves the efficiency and accuracy of processing the settlement data; the settlement data are directly stored in the csv file, so that other personnel which are not working personnel are prevented from being in direct contact with the settlement data, and the safety of the settlement data is improved; the efficiency of inquiring the page report is improved through partitioning and indexing.
Drawings
Various other advantages and benefits will become apparent to those of ordinary skill in the art upon reading the following detailed description of the preferred embodiments. The drawings are only for purposes of illustrating the preferred embodiments and are not to be construed as limiting the invention.
FIG. 1 is a schematic view showing a first embodiment of the settlement data processing method of the present invention;
FIG. 2 is a schematic diagram of a second embodiment of the settlement data processing method of the present invention;
FIG. 3 is a schematic view of a first embodiment of the charge settlement data processing apparatus of the present invention;
FIG. 4 is a schematic view of a second embodiment of the charge settlement data processing apparatus of the present invention;
fig. 5 is a schematic view of an embodiment of the charge settlement data processing device of the present invention.
Detailed Description
In order to make the objects, technical solutions and advantages of the present invention more apparent, the present invention is described in further detail below with reference to the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are merely illustrative of the invention and are not intended to limit the invention.
As used herein, the singular forms "a", "an", "the" and "the" are intended to include the plural forms as well, unless the context clearly indicates otherwise. It will be further understood that the terms "comprises" and/or "comprising," when used in this specification, specify the presence of stated features, integers, steps, operations, elements, and/or components, but do not preclude the presence or addition of one or more other features, integers, steps, operations, elements, components, and/or groups thereof.
In order to make the objects, technical solutions and advantages of the present invention more apparent, the present invention is described in further detail below with reference to the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are merely illustrative of the invention and are not intended to limit the invention.
As used herein, the singular forms "a", "an", "the" and "the" include plural referents unless the context clearly dictates otherwise. It will be further understood that the terms "comprises" and/or "comprising," when used in this specification, specify the presence of stated features, integers, steps, operations, elements, and/or components, but do not preclude the presence or addition of one or more other features, integers, steps, operations, elements, components, and/or groups thereof.
As a preferred embodiment, as shown in fig. 1, a fee settlement data processing method for settlement of fees of a plurality of third party express cabinet companies includes the steps of:
step 101, acquiring a plurality of settlement objects, starting a timing task according to each settlement object to acquire settlement data corresponding to the settlement object, and storing the settlement data into a csv file;
in this embodiment, a logistics enterprise cooperates with a plurality of third-party express cabinet companies (grid, cloud cabinet, friend-rich, and rich nest), that is, the grid, cloud cabinet, friend-rich, and rich nest are settlement objects, and the grid, cloud cabinet, friend-rich, and rich nest are entered into the system, so that a user can obtain a corresponding settlement object according to an instruction; the user can indicate a specific settlement object through a mode of selection or input through an interactive interface or a mode of voice control and the like. The information of the settlement object can be stored in a memory in advance, and the memory can be in a local terminal data processing device or can be arranged in a cloud or a remote server; comma Separated Values (CSV, sometimes also called character Separated Values because the Separated characters may not be commas) whose file stores table data (numbers and text) in plain text form. Plain text means that the file is a sequence of characters, containing no data that must be interpreted like binary digits. CSV files are composed of any number of records, and the records are separated by a certain linefeed character; each record is made up of fields, and separators between fields are other characters or strings, most commonly commas or tabs; in the method, settlement data are acquired through the timing task and stored in the csv file, so that other personnel, which are not workers, can be prevented from directly contacting the data, and the data security is improved; in one embodiment, the timing task is as shown in steps 1011-1014.
Step 1011, acquiring a plurality of settlement objects and determining a settlement period corresponding to each settlement object;
specifically, the settlement period may be a monthly, semi-monthly or weekly settlement, and is not particularly limited, the settlement period is only a transaction time length, and since the express cabinet is frequently used at present, a large number of frequent transactions exist, if the express cabinet logistics enterprise performs settlement with a third party company once, the cost of both parties of the transaction is increased, and therefore, a settlement period is usually agreed; for example, when the fee of 10 months is settled, the fee of the express cabinet between 10 months and 1 day and 10 months and 31 days is settled once.
Step 1012, according to each settlement object, starting a timing task and determining the execution time corresponding to each timing task, wherein the timing task is used for acquiring settlement data in a settlement period during execution;
specifically, the timing task is to automatically complete some assigned tasks at a specific time, for example, a mobile phone alarm clock is a typical timing task. In software development, a large number of tasks which need to be executed regularly are possessed, such as regularly sending mails, regularly capturing data by a crawler and the like. (ii) a The method comprises the steps that a database is constructed in advance, settlement data of a settlement object in a settlement period are obtained through a timing task, the data are stored in the preset database after the data are obtained, csv interaction is carried out and stored in a csv file, the csv file interaction is adopted, when an express cabinet system is disconnected within one day, the data have no influence on a settlement system, the execution time can be T-1 day, T-2 day or T-3 day, the specific limitation is not required, the timing task is started in which time period, the timing task is automatically helped to obtain the data, and the setting and the definition can be removed; in order to ensure high availability of the settlement data system, a dual-active data center may be adopted, where dual-active is to enable both the main and standby data centers to simultaneously bear services of users, and at this time, the main and standby data centers back up each other and perform real-time backup, and generally, the load of the main data center may be more, for example, 60 to 70% of the services are shared, and the standby data center only shares 40 to 30% of the services; for example, if a service is disconnected and b service is online, the user may be good and bad when using the system. The solution is that f5 is configured with survival detection, bad nodes are automatically removed, when one service is bad, the flow is totally transmitted to the second service, and the user has no sense; this is repeated, although double-live, so a distributed lock is used on top of the timing task, ensuring that it is executed only once at the same time, as shown in steps 1013-1014.
1013, sequencing the timing tasks based on the execution time to obtain a sequencing result;
specifically, the server performs ranking according to the execution time of each timing task to obtain a ranking result.
Step 1014, generating a distributed lock based on the sorting result.
Specifically, when a timing task is added with a semaphore, the CAS executes the timing task, and if the semaphore is added, the CAS represents that no other node executes the timing task and executes the timing task; if the CAS fails, the delegate has already executed, and the task is not executed.
Step 102, traversing settlement data in the csv file, updating the settlement data into a settlement list, and determining index information;
in the embodiment, in order to better identify the settlement data, after traversing the settlement data in the csv file, the server configures a settlement order number for each piece of settlement data, wherein the settlement order number is a unique identifier and is used for distinguishing different settlement data; the server extracts a website code, for example, the website code is "250436", from each piece of settlement data, and since there are many pieces of settlement data for each settlement target, the server classifies the pieces of settlement data according to the website code to obtain a plurality of data sets. Putting settlement data belonging to the same website in a data set, wherein each data set corresponds to a website code, and each settlement object at least comprises a website code; configuring each piece of settlement data in the data set based on the website code to generate a corresponding settlement order number, for example, the settlement order number is '250436001'; the settlement list is pre-configured, and in one embodiment, the settlement data is updated into the settlement list and the index information is determined, as shown in steps 1021-1024.
Step 1021, reading target header data in the settlement statement, and updating the settlement data to a corresponding data cell based on the target header data to generate the settlement statement corresponding to the settlement object;
specifically, the server traverses settlement data in the csv file, reads the settlement data after traversing, starts from a first line, reads one line at a time, obtains target header data to which a certain parameter in the current settlement data belongs when reading the settlement data, compares the target header data with a certain parameter of the settlement data, judges whether the certain parameter is matched with the target header data, and stores the certain parameter in the settlement data into a data cell corresponding to the target header data if the certain parameter is matched, and executes the steps on each settlement data to complete importing the settlement data so as to generate a detail table corresponding to a settlement object.
Step 1022, storing the settlement list into a redis cache layer and a query database, wherein the query database is constructed in advance;
in particular, Redis is an open-source, in-memory data structure storage system that can be used as database, cache, and message middleware, which is a non-relational database based on high-performance Key-Value and providing APIs in multiple languages. However, different from the traditional database, the data of the redis is stored in the memory, so the memory writing speed is very high, the frequency of accessing the physical equipment by a user can be effectively reduced by using the cache, and the concurrent pressure is effectively reduced; for example, the settlement list shows that the database needs to be inquired, when the database is hung, no data exists, a redis cache layer is requested preferentially, and the disaster resistance is improved.
Step 1023, acquiring date information in the settlement list, and dividing the settlement data into a plurality of partitions according to the date information, wherein the date information is a date for generating the expense, and each partition at least comprises one piece of settlement data;
specifically, the settlement detail table is too large, so that the time consumption of inquiring and inserting the database is too long, the performance is low, if the condition of joint inquiry is involved, the performance is worse, and the table partitioning aims to reduce the burden of inquiring the database and improve the efficiency of the database; the partition is to store the data in a plurality of positions in a segmented manner, can be the same disk or different machines, and is also a table on the surface after the partition, but the data is hashed to a plurality of positions.
And step 1024, associating the date information with the settlement data as the index information of the settlement data.
Specifically, the index is a database structure related to a table, the index is used for quickly searching rows with specific column values, if no index exists, scanning and searching must be started from the first row, then full-table scanning is performed to find all required values, the larger the table is, the higher the cost is, the more the disks io are, the slower the speed is, and if the data to be searched can be quickly located through index searching, the data does not need to be completely scanned; the server stores the date information as index information of the settlement data, and the generated index information is associated with the settlement data and can be stored in the settlement list (such as a header or a settlement data part); the efficiency of the statement query of the settlement statement page can be improved by the partition of the step 1023 and the index of the step.
103, pushing the settlement statement to a settlement terminal after the settlement statement is updated;
in this embodiment, the server detects that the settlement data is stored completely, that is, the settlement statement is updated completely, and then the server pushes the settlement statement to the settlement terminal, where the settlement terminal may be a computer, and is not particularly limited.
Step 104, receiving confirmation information of the settlement terminal, determining a settlement amount corresponding to a settlement object based on the settlement statement, and performing automatic settlement to obtain a settlement result;
in the embodiment, when relevant workers check the settlement statement through the settlement terminal, the settlement data in the settlement statement is checked, if the check is correct, the relevant workers click the settlement terminal to confirm, the server receives confirmation information sent by the settlement terminal, the settlement amount corresponding to a settlement object is determined based on the settlement statement, and a payment system is called.
And 105, generating a block by using the settlement object, uploading the block to a block chain, and writing a settlement result into the block chain.
In this embodiment, the related data of the settlement object is uploaded to the block link network for storage, and the authenticity of the information is ensured due to the fact that the block link technology has non-tamper property, so that the accurate source of the information is confirmed, and the traceability of the related data of the settlement object is ensured.
In the embodiment of the invention, a timing task is started according to each settlement object by acquiring a plurality of settlement objects to acquire settlement data corresponding to the settlement objects, and the settlement data is stored in a csv file; traversing settlement data in the csv file, updating the settlement data into a settlement list, and determining index information; after the settlement statement is updated, pushing the settlement statement to a settlement terminal; receiving confirmation information of the settlement terminal, determining a settlement amount corresponding to a settlement object based on the settlement detail table, and performing automatic settlement to obtain a settlement result; generating a block by using the settlement object, uploading the block to a block chain, and writing a settlement result into the block chain; the invention effectively improves the efficiency and accuracy of processing the settlement data; the settlement data are directly stored in the csv file, so that other people who are not workers are prevented from being in direct contact with the settlement data, and the safety of the settlement data is improved; the efficiency of inquiring the page report is improved through partitioning and indexing.
Referring to fig. 2, a second embodiment of the method for processing fee settlement data according to the embodiment of the present invention includes:
step 201, receiving a report generation request, and determining attribute information of a keyword in the report generation request;
in this embodiment, the report generation request may refer to an instruction requesting generation of a report. Report parameter information related to the report requested to be generated can be contained in the report generation request; the server extracts the keywords in the report generation request according to the report parameter information and determines the attribute information of the keywords, wherein the attribute information of the keywords can be information such as 'settlement order number', 'expense generation time', 'single settlement amount', 'website code', and the like.
Step 202, determining corresponding target header data according to a pre-configured configuration information table based on the attribute information of the keywords;
in this embodiment, the preconfigured configuration information table may be divided into a physical table part, a parameter comparison table part, a data comparison table part, a report information table part, and an output information table part, where the physical table part may be used to store operation logic; the parameter comparison table part can be used for defining available parameter codes and fields corresponding to different data types; the data comparison table part can be used for defining a data table corresponding to the data type; the report information table part is an important component in the embodiment of the invention and can be used for storing the related information of the report; the output information table portion may be used to store information about the output data. Therefore, in the embodiment of the present invention, after the target identification information is acquired, the attribute information of the keyword may be utilized to determine the corresponding configuration information table in the pre-configured configuration information table, and based on the attribute information of the keyword, the target header data of the configuration information table may be generated, where the target header data at least includes "a settlement order number", "a fee generation time", "a single settlement amount", and "a website code".
Step 203, generating a settlement list according to the target header data and the configuration information table;
in the embodiment, the server generates a settlement list according to the target header data and the configuration information list, wherein the settlement list at least comprises date information, a settlement order number and a website code, and the date information is expense generating time; the settlement detail table is used for counting the settlement data corresponding to the settlement object in the settlement period, so that the settlement amount can be conveniently determined.
And step 204, generating a corresponding sql statement based on the target header data.
In this embodiment, the server may combine target header data in the settlement statement to generate an SQL statement, and create a new structural class of the SQL statement to store the SQL statement and parameters, and store the SQL statement and parameters in the cache, so as to directly obtain the SQL statement from the cache when the same operation is executed next time, thereby improving performance.
In the embodiment of the invention, a report generation request is received, the attribute information of a keyword in the report generation request is determined, corresponding target header data is determined according to a pre-configured configuration information table based on the attribute information of the keyword, a settlement detail table is generated according to the target header data and the configuration information table, and a corresponding sql statement is generated based on the target header data and is used for inquiring the data corresponding to the target header data; the invention improves the generation efficiency of the settlement statement, avoids the repeated development of similar functions, realizes the universality of the settlement statement and saves the development cost.
Referring to fig. 3, in one embodiment, a charge settlement data processing apparatus is provided, the charge settlement data processing apparatus including:
the starting module 301 is configured to obtain a plurality of settlement objects, start a timing task according to each settlement object to obtain settlement data corresponding to the settlement object, and store the settlement data in the csv file;
the updating module 302 is used for traversing settlement data in the csv file, updating the settlement data into a settlement list and determining index information;
the pushing module 303 is configured to push the settlement statement to the settlement terminal after the settlement statement is updated;
the settlement module 304 is configured to receive the confirmation information of the settlement terminal, determine a settlement amount corresponding to the settlement object based on the settlement statement, and perform automatic settlement to obtain a settlement result;
and an upload module 305, configured to generate a block using the settlement object and upload the block to the block chain, and write the settlement result into the block chain.
Referring to fig. 4, in a second embodiment of the fee settlement data processing apparatus according to the embodiment of the present invention, the update module 302 includes:
an update submodule 3021, configured to read target header data in the settlement statement, and update the settlement data into a corresponding data cell based on the target header data, so as to generate a settlement statement corresponding to the settlement target;
a storing submodule 3022, configured to store the settlement list in a redis cache layer and a query database, where the query database is pre-constructed;
a dividing submodule 3023, configured to obtain date information in the settlement list, and divide the settlement data into a plurality of partitions according to the date information, where the date information is a date on which the fee is generated, and each partition includes at least one piece of settlement data;
the association submodule 3024 is configured to associate the date information with the settlement data as index information of the settlement data.
In the embodiment of the invention, a timing task is started according to each settlement object by acquiring a plurality of settlement objects to acquire settlement data corresponding to the settlement objects, and the settlement data is stored in a csv file; traversing settlement data in the csv file, updating the settlement data into a settlement list, and determining index information; after the settlement statement is updated, pushing the settlement statement to a settlement terminal; receiving confirmation information of the settlement terminal, determining a settlement amount corresponding to a settlement object based on the settlement detail table, and performing automatic settlement to obtain a settlement result; generating a block by using the settlement object, uploading the block to a block chain, and writing a settlement result into the block chain; the invention effectively improves the efficiency and accuracy of processing the settlement data; the settlement data are directly stored in the csv file, so that other people who are not workers are prevented from being in direct contact with the settlement data, and the safety of the settlement data is improved; the efficiency of inquiring the page report is improved through partitioning and indexing.
Fig. 3 to 4 above describe the fee settlement data processing apparatus in the embodiment of the present invention in detail from the perspective of the modular functional entity, and the fee settlement data processing apparatus in the embodiment of the present invention is described in detail from the perspective of hardware processing.
Fig. 5 is a schematic structural diagram of a fee settlement data processing apparatus 500 according to an embodiment of the present invention, which may have a relatively large difference due to different configurations or performances, and may include one or more processors (CPUs) 510 (e.g., one or more processors) and a memory 520, and one or more storage media 530 (e.g., one or more mass storage devices) storing applications 533 or data 532. Memory 520 and storage media 530 may be, among other things, transient or persistent storage. The program stored in the storage medium 530 may include one or more modules (not shown), each of which may include a series of instruction operations in the charge settlement data processing apparatus 500. Further, the processor 510 may be configured to communicate with the storage medium 530, and execute a series of instruction operations in the storage medium 530 on the charge settlement data processing device 500.
The fee settlement data processing apparatus 500 may also include one or more power supplies 540, one or more wired or wireless network interfaces 550, one or more input-output interfaces 560, and/or one or more operating systems 531, such as Windows service, Mac OS X, Unix, Linux, FreeBSD, and the like. It will be understood by those skilled in the art that the charge settlement data processing device configuration shown in fig. 5 does not constitute a limitation of the charge settlement data processing device provided herein, and may include more or less components than those shown, or some components in combination, or a different arrangement of components.
A charge settlement data processing apparatus for realizing the following charge settlement data processing method, said charge settlement data processing method comprising the steps of: .
Acquiring a plurality of settlement objects, starting a timing task according to each settlement object to acquire settlement data corresponding to the settlement object, and storing the settlement data into a csv file;
traversing settlement data in the csv file, updating the settlement data into a settlement list, and determining index information;
after the settlement statement is updated, pushing the settlement statement to the settlement terminal;
receiving confirmation information of the settlement terminal, determining a settlement amount corresponding to the settlement object based on the settlement statement, and performing automatic settlement to obtain a settlement result;
and generating a block by using the settlement object, uploading the block to a block chain, and writing the settlement result into the block chain.
In one embodiment, a plurality of settlement objects are obtained, and a settlement period corresponding to each settlement object is determined;
starting a timing task according to each settlement object, and determining the corresponding execution time of each timing task, wherein the timing task is used for acquiring settlement data in the settlement period during the execution;
sequencing the timing tasks based on the execution time to obtain a sequencing result;
and generating a distributed lock based on the sequencing result.
In one embodiment, a report generation request is received, and attribute information of keywords in the report generation request is determined;
determining corresponding target header data according to a pre-configured configuration information table based on the attribute information of the keywords;
generating a settlement statement according to the target header data and the configuration information table, wherein the settlement statement at least comprises date information, a settlement order number and a website code;
and generating a corresponding sql statement based on the target header data, wherein the sql statement is used for inquiring data corresponding to the target header data.
In one embodiment, a website code in each piece of settlement data is extracted, and a plurality of pieces of settlement data are classified according to the website codes to obtain a plurality of data sets, each data set corresponds to one website code, wherein each settlement object at least comprises one website code;
and configuring each piece of settlement data in the data set based on the website codes to generate a corresponding settlement order number.
In one embodiment, target header data in the settlement list is read, and the settlement data is updated to a corresponding data cell based on the target header data to generate a settlement list corresponding to the settlement object;
storing the settlement list into a redis cache layer and a query database, wherein the query database is constructed in advance;
acquiring date information in the settlement list, and dividing the settlement data into a plurality of partitions according to the date information, wherein the date information is a date for generating fees, and each partition at least comprises one piece of settlement data;
and using the date information as index information of the settlement data and associating the date information with the settlement data.
In one embodiment, if the settlement result is settlement failure, manual operation information is sent to a manual interface, and the settlement sheet number with settlement failure is screened out, so that the user is prompted to perform manual settlement on the settlement sheet number with settlement failure.
The present invention also provides a computer-readable storage medium, which may be a non-volatile computer-readable storage medium, or a volatile computer-readable storage medium, wherein instructions are stored in the computer-readable storage medium, and when the instructions are executed on a computer, the instructions cause the computer to execute the following fee settlement data processing method, and the fee settlement data processing method specifically includes the following steps:
acquiring a plurality of settlement objects, starting a timing task according to each settlement object to acquire settlement data corresponding to the settlement object, and storing the settlement data into a csv file;
traversing settlement data in the csv file, updating the settlement data into a settlement list, and determining index information;
after the settlement statement is updated, pushing the settlement statement to the settlement terminal;
receiving confirmation information of the settlement terminal, determining a settlement amount corresponding to the settlement object based on the settlement statement, and performing automatic settlement to obtain a settlement result;
and generating a block by using the settlement object, uploading the block to a block chain, and writing the settlement result into the block chain.
In one embodiment, a plurality of settlement objects are obtained, and a settlement period corresponding to each settlement object is determined;
starting a timing task according to each settlement object, and determining the corresponding execution time of each timing task, wherein the timing task is used for acquiring settlement data in the settlement period during the execution;
sequencing the timing tasks based on the execution time to obtain a sequencing result;
and generating a distributed lock based on the sequencing result.
In one embodiment, a report generation request is received, and attribute information of keywords in the report generation request is determined;
determining corresponding target header data according to a pre-configured configuration information table based on the attribute information of the keywords;
generating a settlement statement according to the target header data and the configuration information table, wherein the settlement statement at least comprises date information, a settlement order number and a website code;
and generating a corresponding sql statement based on the target header data, wherein the sql statement is used for inquiring data corresponding to the target header data.
In one embodiment, a website code in each piece of settlement data is extracted, and a plurality of pieces of settlement data are classified according to the website codes to obtain a plurality of data sets, each data set corresponds to one website code, wherein each settlement object at least comprises one website code;
and configuring each piece of settlement data in the data set based on the website codes to generate a corresponding settlement order number.
In one embodiment, target header data in the settlement list is read, and the settlement data is updated to a corresponding data cell based on the target header data to generate a settlement list corresponding to the settlement object;
storing the settlement list into a redis cache layer and a query database, wherein the query database is constructed in advance;
acquiring date information in the settlement list, and dividing the settlement data into a plurality of partitions according to the date information, wherein the date information is a date for generating fees, and each partition at least comprises one piece of settlement data;
and using the date information as index information of the settlement data and associating the date information with the settlement data.
In one embodiment, if the settlement result is settlement failure, manual operation information is sent to a manual interface, and the settlement sheet number with settlement failure is screened out, so that the user is prompted to perform manual settlement on the settlement sheet number with settlement failure.
The block chain is a novel application mode of computer technologies such as distributed data storage, point-to-point transmission, a consensus mechanism, an encryption algorithm and the like. A block chain (Blockchain), which is essentially a decentralized database, is a series of data blocks associated by using a cryptographic method, and each data block contains information of a batch of network transactions, so as to verify the validity (anti-counterfeiting) of the information and generate a next block. The blockchain may include a blockchain underlying platform, a platform product service layer, an application service layer, and the like.
It can be clearly understood by those skilled in the art that, for convenience and brevity of description, the specific working processes of the above-described systems, apparatuses and units may refer to the corresponding processes in the foregoing method embodiments, and are not described herein again.
The integrated unit, if implemented in the form of a software functional unit and sold or used as a stand-alone product, may be stored in a computer readable storage medium. Based on such understanding, the technical solution of the present invention may be embodied in the form of a software product, which is stored in a storage medium and includes instructions for causing a computer device (which may be a personal computer, a server, or a network device) to execute all or part of the steps of the method according to the embodiments of the present invention. And the aforementioned storage medium includes: various media capable of storing program codes, such as a usb disk, a removable hard disk, a read-only memory (ROM), a Random Access Memory (RAM), a magnetic disk, or an optical disk.
The above-mentioned embodiments are only used for illustrating the technical solutions of the present invention, and not for limiting the same; although the present invention has been described in detail with reference to the foregoing embodiments, it will be understood by those of ordinary skill in the art that: the technical solutions described in the foregoing embodiments may still be modified, or some technical features may be equivalently replaced; and such modifications or substitutions do not depart from the spirit and scope of the corresponding technical solutions of the embodiments of the present invention.

Claims (10)

1. A charge settlement data processing method, characterized by comprising the steps of:
acquiring a plurality of settlement objects, starting a timing task according to each settlement object to acquire settlement data corresponding to the settlement object, and storing the settlement data into a csv file;
traversing settlement data in the csv file, updating the settlement data into a settlement list, and determining index information;
after the settlement statement is updated, pushing the settlement statement to the settlement terminal;
receiving confirmation information of the settlement terminal, determining a settlement amount corresponding to the settlement object based on the settlement statement, and performing automatic settlement to obtain a settlement result;
and generating a block by using the settlement object, uploading the block to a block chain, and writing the settlement result into the block chain.
2. The fee settlement data processing method according to claim 1, wherein the acquiring a plurality of settlement objects and starting a timing task for acquiring settlement data corresponding to the settlement objects according to each of the settlement objects, comprises:
acquiring a plurality of settlement objects and determining a settlement period corresponding to each settlement object;
starting a timing task according to each settlement object, and determining the corresponding execution time of each timing task, wherein the timing task is used for acquiring settlement data in the settlement period during the execution;
sequencing the timing tasks based on the execution time to obtain a sequencing result;
and generating a distributed lock based on the sequencing result.
3. The fee settlement data processing method according to claim 1, wherein before traversing the settlement data in the csv file, updating the settlement data into a settlement list, and determining the index information, the method further comprises:
receiving a report generation request, and determining attribute information of keywords in the report generation request;
determining corresponding target header data according to a pre-configured configuration information table based on the attribute information of the keywords;
generating a settlement statement according to the target header data and the configuration information table, wherein the settlement statement at least comprises date information, a settlement order number and a website code;
and generating a corresponding sql statement based on the target header data, wherein the sql statement is used for inquiring data corresponding to the target header data.
4. The fee settlement data processing method of claim 1, wherein traversing the settlement data in the csv file comprises:
extracting a website code in each piece of settlement data, classifying a plurality of pieces of settlement data according to the website codes to obtain a plurality of data sets, wherein each data set corresponds to one website code, and each settlement object at least comprises one website code;
and configuring each piece of settlement data in the data set based on the website codes to generate a corresponding settlement order number.
5. The fee settlement data processing method according to claim 1, wherein the updating the settlement data into a settlement list and determining index information includes:
reading target header data in the settlement statement, and updating the settlement data to a corresponding data cell based on the target header data to generate the settlement statement corresponding to the settlement object;
storing the settlement list into a redis cache layer and a query database, wherein the query database is constructed in advance;
acquiring date information in the settlement list, and dividing the settlement data into a plurality of partitions according to the date information, wherein the date information is a date for generating fees, and each partition at least comprises one piece of settlement data;
and using the date information as index information of the settlement data and associating the date information with the settlement data.
6. The fee settlement data processing method according to claim 1, further comprising, after generating a block by using the settlement object and uploading the block to a block chain and writing the settlement result to the block chain:
and if the settlement result is settlement failure, sending manual operation information to a manual interface, and screening out settlement ticket numbers with settlement failure so as to prompt a user to execute manual settlement on the settlement ticket numbers with settlement failure.
7. A charge settlement data processing apparatus, characterized by comprising:
the starting module is used for acquiring a plurality of settlement objects, starting a timing task according to each settlement object to acquire settlement data corresponding to the settlement object, and storing the settlement data into a csv file;
the updating module is used for traversing settlement data in the csv file, updating the settlement data into a settlement list and determining index information;
the pushing module is used for pushing the settlement statement to the settlement terminal after the settlement statement is updated;
the settlement module is used for receiving the confirmation information of the settlement terminal, determining the settlement amount corresponding to the settlement object based on the settlement detail table, and performing automatic settlement to obtain a settlement result;
and the uploading module is used for generating a block by using the settlement object and uploading the block to a block chain, and writing the settlement result into the block chain.
8. The charge settlement data processing device according to claim 7, wherein the update module includes:
the updating submodule is used for reading target header data in the settlement statement and updating the settlement data to a corresponding data cell based on the target header data so as to generate the settlement statement corresponding to the settlement object;
a storing submodule, configured to store the settlement list in a redis cache layer and a query database, where the query database is pre-constructed;
the dividing submodule is used for acquiring date information in the settlement list and dividing the settlement data into a plurality of subareas according to the date information, wherein the date information is the date for generating the expense, and each subarea at least comprises one piece of settlement data;
and the association submodule is used for associating the date information with the settlement data as the index information of the settlement data.
9. A charge settlement data processing apparatus characterized by comprising: a memory having instructions stored therein and at least one processor, the memory and the at least one processor interconnected by a line; the at least one processor invokes the instructions in the memory to cause the charge settlement data processing device to perform the steps of the charge settlement data processing method of any one of claims 1-6.
10. A computer-readable storage medium, on which a computer program is stored, which, when being executed by a processor, carries out the steps of the charge settlement data processing method according to any one of claims 1 to 6.
CN202111508196.1A 2021-12-10 2021-12-10 Fee settlement data processing method, device, equipment and storage medium Pending CN114331398A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202111508196.1A CN114331398A (en) 2021-12-10 2021-12-10 Fee settlement data processing method, device, equipment and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202111508196.1A CN114331398A (en) 2021-12-10 2021-12-10 Fee settlement data processing method, device, equipment and storage medium

Publications (1)

Publication Number Publication Date
CN114331398A true CN114331398A (en) 2022-04-12

Family

ID=81050220

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202111508196.1A Pending CN114331398A (en) 2021-12-10 2021-12-10 Fee settlement data processing method, device, equipment and storage medium

Country Status (1)

Country Link
CN (1) CN114331398A (en)

Similar Documents

Publication Publication Date Title
CN111459985B (en) Identification information processing method and device
Palm et al. Selective blockchain transaction pruning and state derivability
JP2019220195A (en) System and method for implementing data storage service
US9020949B2 (en) Method and system for centralized issue tracking
CN110737592B (en) Link abnormality identification method, server and computer readable storage medium
US20100241637A1 (en) Systems and methods for managing foreign key constraints
US11810191B2 (en) Systems and methods of creating order lifecycles via daisy chain linkage
CN103620601A (en) Joining tables in a mapreduce procedure
EP4137960A1 (en) Record matching system
US20230205755A1 (en) Methods and systems for improved search for data loss prevention
CN105320722A (en) Ensuring consistency of derived data in distributed storage system
CN111488614A (en) Digital identity storage method and device based on service data block chain
US11151088B2 (en) Systems and methods for verifying performance of a modification request in a database system
US11531666B1 (en) Indexing partitions using distributed bloom filters
CN116993523A (en) Configurable account checking method, device, equipment and storage medium
US8229946B1 (en) Business rules application parallel processing system
CN114331398A (en) Fee settlement data processing method, device, equipment and storage medium
US9652766B1 (en) Managing data stored in memory locations having size limitations
CN115098738A (en) Service data extraction method and device, storage medium and electronic equipment
CN115495620A (en) Data management method based on graph structure and related equipment
CN105550347B (en) Data processing method and device
US10558647B1 (en) High performance data aggregations
US7865518B2 (en) Systems and methods for managing identities in a database system
CN105843813A (en) Method and device for processing big data
CN117608795A (en) Task processing method and device in preemption mode

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination