Software retrieval classification processing system and method
Through the software search of the public code encapsulation and custom modules of the classification processing system, the problems of low development efficiency and code redundancy of traditional query functions are solved, and simplified development process and efficient query function support are achieved, meeting users' flexible needs.
Patent Information
- Application Number
- CN202411290728.2
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-09-14
- Publication Date
- 2024-12-31
AI Technical Summary
The development and maintenance of traditional query functions are inefficient, with code redundancy and high error rates, especially when complex query logic and database operations, resulting in long development cycles and complex maintenance.
A software search classification processing system was designed to encapsulate modules, custom modules and newly created query function modules through public codes, encapsulate front and back-end codes, provide a unified interface and configuration method, simplify the development process of query functions, and use abstract interfaces and Flexible configuration supports different query requirements.
It reduces redundant code and repetitive work, improves code reusability and maintainability, reduces development costs and technical requirements, meets users' flexible query needs, and supports personalized customization.
Smart Images

Figure CN119225697A_ABST
Abstract
Description
Technical Field
[0001] The present invention belongs to the technical field of software retrieval, and in particular relates to a software retrieval classification processing system and method. Background Art
[0002] With the rapid development of the Internet and the widespread use of applications, query functions have become an indispensable part of many applications. Whether in e-commerce, social media, data analysis or enterprise management, query functions play an important role.
[0003] Traditional query function implementation usually involves front-end and back-end code writing, as well as interaction with the database. However, due to factors such as the gradual increase in application scale, complex requirements, and collaborative development by multiple teams, the development and maintenance of query functions has become more challenging.
[0004] Existing relevant implementation solutions:
[0005] Backend development: Use ORM (object-relational mapping) framework to simplify database operations. However, ORM frameworks usually require complex configuration and learning, which may not be friendly enough for beginners and simple query scenarios.
[0006] Front-end development: Use the vue+element-ui framework to develop pages, at least <el-form> 、 <el-table> 、 <el-pagination>Three tags. However, these three tags require a large number of sub-tags and attributes.
[0007] Although the existing implementation scheme can meet the requirements of query functions, the following problems still exist:
[0008] Low development efficiency: Developers need to manually write a lot of code, including database connection, query statement construction, data parsing and rendering, which leads to a long development cycle.
[0009] Code redundancy: Since different query requirements may require similar code logic, manual writing can easily lead to code redundancy, increasing the complexity of maintenance.
[0010] High error rate: Manually written code is prone to errors, especially when dealing with complex query logic and database operations, which requires a lot of time to debug and modify. Summary of the invention
[0011] In view of the above problems, the present invention is proposed to provide a software retrieval classification processing system and method that overcomes the above problems or at least partially solves the above problems.
[0012] To achieve the above object, the present invention adopts the following technical solutions:
[0013] A software retrieval classification processing system, the system comprising:
[0014] Public code encapsulation module, used to encapsulate the public code of the query function;
[0015] Create a new query function module to create a new Java class to represent the query result type;
[0016] Custom modules are used to customize the front-end style and back-end query interface.
[0017] Optionally, the public code encapsulation module includes:
[0018] The front-end code encapsulation unit is developed using vue+element-ui and a new vue component is created;
[0019] The backend code encapsulation unit is developed in Java and implements three public interfaces and one annotation;
[0020] The table creation unit is used to create a new menu table, filter table and menu permission table in the database. The menu table is used to save the public settings of the query function, the filter table is used to save the query options of the query function, and the menu permission table is used to save the users who are allowed to use the query function.
[0021] Optionally, the front-end code encapsulation unit includes:
[0022] Form components, used to create and manage user input data;
[0023] Table component, a component used to display data lists;
[0024] Paging component, used to implement paging browsing of data.
[0025] Optionally, the three public interfaces include:
[0026] The first public interface is used to query the menu table and the menu permission table to determine whether the currently logged-in user is allowed to use this function;
[0027] The second public interface is used to query the filter table and obtain all query options supported by the query function;
[0028] The third public interface is called when you click the query button after selecting the query option. It will query the corresponding table in the database according to the selected query option and the name of the query table filled in the menu table, and convert the result into query result and then transmit it to the front end.
[0029] Optionally, the newly created query function module includes:
[0030] Create three new tables in the database and add corresponding data;
[0031] In the backend, create a new Java class and add annotations to the Java class;
[0032] In the front end, introduce custom vue components.
[0033] Optionally, the three forms include:
[0034] Menu table, used to add unique identifier;
[0035] Filters table, for adding query options;
[0036] Menu permission table, used to add usage permissions.
[0037] Optional, custom modules include:
[0038] Customize the front-end style and use CSS language to customize the style of query results;
[0039] Customize the backend query interface. When the user clicks the query button, the customized query interface is called.
[0040] The present invention also provides a software retrieval classification processing method, using the software retrieval classification processing system as described above, the method comprises the following steps:
[0041] S1. Based on the unique identifier of the referenced vue component, the front end calls the first public interface of the back end;
[0042] S2. In the first public interface, query the database to obtain the settings of the query function;
[0043] S3, the backend sends the query result obtained in the first public interface to the frontend;
[0044] S4. According to the unique identifier of the referenced vue component, the front end calls the second public interface of the back end;
[0045] S5. Second, in the public interface, query the database to obtain all query options of the query function;
[0046] S6. The back end sends the query result obtained in the second public interface to the front end;
[0047] S7: The front end performs page rendering according to the results obtained in step S3 and step S6 to obtain the page that the user sees;
[0048] S8. The user clicks a query button to call the third public interface or a custom interface to query the data required by the user;
[0049] S9. Display the queried data on the page.
[0050] In summary, due to the adoption of the above technical solution, the beneficial effects of the present invention are:
[0051] 1. The present invention reduces redundant code and repetitive work through the encapsulation of front-end and back-end codes, and improves the reusability and maintainability of the code; through a unified interface and configuration method, it simplifies the development process of the query function and reduces the technical requirements and development costs.
[0052] 2. The present invention realizes support for different query requirements through abstract interfaces and flexible configurations, meets the flexible query requirements of users, and the technical solution is flexible and configurable, and can be customized according to the personalized needs of users to meet the specific needs of various different users. BRIEF DESCRIPTION OF THE DRAWINGS
[0053] Figure 1 A schematic diagram of a software retrieval classification processing system provided in an embodiment of the present application;
[0054] Figure 2 A flowchart of a software retrieval classification processing method provided in an embodiment of the present application. DETAILED DESCRIPTION
[0055] In order to make the purpose, technical solutions and advantages of the embodiments of the present invention clearer, the technical solutions in the embodiments of the present invention will be clearly and completely described below in conjunction with the drawings in the present invention. Obviously, the described embodiments are part of the embodiments of the present invention, rather than all the embodiments. Based on the embodiments in the present invention, all other embodiments obtained by ordinary technicians in this field without making creative work are within the scope of protection of the present invention.
[0056] Embodiment 1:
[0057] See also Figure 1 This embodiment provides a software retrieval classification processing system, including:
[0058] The public code encapsulation module is used to encapsulate the public code of the query function.
[0059] The public code encapsulation modules include:
[0060] The front-end code encapsulation unit is developed using vue+element-ui and a new vue component is created.
[0061] The backend code encapsulation unit is developed using Java and implements three public interfaces and one annotation.
[0062] The table creation unit is used to create a new menu table, filter table and menu permission table in the database. The menu table is used to save the public settings of the query function, and at least seven fields are required: unique identifier, default style, default query option, default query result, query condition type, query result type, and the name of the queried table; the filter table is used to save the query options of the query function, and at least four fields are required: the unique identifier of the menu table, the type of query option, the field name of the query option, and the condition of the query option. The relationship between the menu table and the filter table is one-to-many; the menu permission table is used to save the users who are allowed to use the query function, and at least two fields are required: the unique identifier of the menu table and the user's id. The relationship between the menu table and the menu permission table is one-to-many.
[0063] The front-end code encapsulation unit includes:
[0064] Form components are used to create and manage user input data. <el-form-item>To define form fields, including input boxes, selectors, buttons, etc., and specify label text through the label attribute.
[0065] Table component, a component used to display data lists, can easily render complex data structures, such as multiple columns, paging, sorting, searching, row / column merging, tree structures, etc.
[0066] Paging component, used to implement paging browsing of data, often with <el-table>Used in combination. Provides functions such as previous page, next page, first page, last page, number of pages per page selection, jump to specified page, etc.
[0067] The three public interfaces include:
[0068] The first public interface is used to query the menu table and menu permission table according to the unique identifier of the front-end vue component, and determine whether the currently logged-in user is allowed to use the function. If allowed, the default style, default query options, and default query results are sent to the front-end. The front-end renders the default options in the query option part of the page according to the default query options, and selects which attributes are displayed in the query result part of the page according to the default query results. Other attributes are hidden. The default style is the overall style of the function page, such as: the entire page, sub-page.
[0069] The second public interface is used to query the filter table according to the unique identifier of the front-end vue component, and obtain all query options supported by the query function. The default query options should be a subset of these options. The query options in the front-end page are divided into two parts: default and all. The default part directly displays the Chinese name of the query condition and allows the symbol and value of the query condition to be selected; the all part allows users to select the Chinese name, symbol and value of the query condition.
[0070] The third public interface is called when you click the query button after selecting the query option. It will query the corresponding table in the database according to the selected query option and the name of the query table filled in the menu table, and convert the result into query result and then transmit it to the front end.
[0071] A new query function module is created to create a new Java class to represent the query result type.
[0072] New query function modules include:
[0073] Create three tables in the database and add the corresponding data. Before referencing the vue component, you need to add the corresponding data in the three tables in the database. In the menu table, add a unique identifier (this string needs to be placed in the properties of the component when referencing the vue component). In the filter table, add query options and add the options in the query option part of the query function. In the menu permission table, add query options and add the users allowed to use the function, such as: all users, users of a department, or a certain user.
[0074] In the backend, create a new java class and add annotations to the java class. These properties should be added to the filter table. Generally, the query condition type and query result type of the menu table are the full class name of the class.
[0075] In the front end, a custom vue component is introduced, and a unique identifier is added to the specified attribute. After the user clicks the query button, the query results will be displayed below the query options (note: in general, not all attributes in the query results will be displayed). At the same time, a selection bar is also provided, where users can display which fields to display and which fields to hide.
[0076] Custom modules are used to customize the front-end style and back-end query interface.
[0077] Custom modules include:
[0078] Customize the front-end style and use CSS language to customize the style of query results. For example, the default style is a table, which can display a row of data as a label box and customize the font size, color and relative position.
[0079] Customize the query interface of the backend, that is, when the user clicks the query button, the third public interface is not called, but the customized query interface is called. The default third public interface can complete the query function, but does not support functions such as caching. If you want to implement these functions, you can create a new interface and then configure it in the data.
[0080] This embodiment reduces redundant code and repetitive work by encapsulating the front-end and back-end codes, and improves the reusability and maintainability of the code; through a unified interface and configuration method, it simplifies the development process of the query function and reduces technical requirements and development costs.
[0081] This embodiment supports different query requirements through abstract interfaces and flexible configurations, and meets the flexible query requirements of users. Moreover, the technical solution is flexible and configurable, and can be customized according to the personalized needs of users to meet the specific needs of various different users.
[0082] Embodiment 2:
[0083] like Figure 2 As shown, Embodiment 2 provides a software retrieval classification processing method, using a software retrieval classification processing system provided by Embodiment 1, the method includes the following steps:
[0084] S1. Based on the unique identifier of the referenced vue component, the front end calls the first public interface of the back end.
[0085] S2. In the first public interface, query the database to obtain the settings of the query function.
[0086] S3. The backend sends the query result obtained in the first public interface to the frontend.
[0087] S4. According to the unique identifier of the referenced vue component, the front end calls the second public interface of the back end;
[0088] S5. Second, in the public interface, query the database to obtain all query options of the query function.
[0089] S6. The back end sends the result queried in the second public interface to the front end.
[0090] S7. The front end renders the page according to the results obtained in steps S3 and S6 to obtain the page that the user sees.
[0091] S8. The user clicks a query button to call the third public interface or a custom interface to query the data required by the user.
[0092] S9. Display the queried data on the page.
[0093] The above contents are further detailed descriptions of the present invention in combination with specific preferred embodiments, and it cannot be determined that the specific implementation of the present invention is limited to these descriptions. For ordinary technicians in the technical field to which the present invention belongs, several simple deductions or substitutions can be made without departing from the concept of the present invention, which should be regarded as falling within the protection scope of the present invention. < / el-table> < / el-form>
Claims
1. A software retrieval classification processing system, characterized in that: The system comprises: Public code encapsulation module, used to encapsulate the public code of the query function; Create a new query function module to create a new Java class to represent the query result type; Custom modules are used to customize the front-end style and back-end query interface.
2. A software retrieval classification processing system as claimed in claim 1, characterized in that: The public code encapsulation modules include: The front-end code encapsulation unit is developed using vue+element-ui and a new vue component is created; The backend code encapsulation unit is developed in Java and implements three public interfaces and one annotation; The table creation unit is used to create a new menu table, filter table and menu permission table in the database. The menu table is used to save the public settings of the query function, the filter table is used to save the query options of the query function, and the menu permission table is used to save the users who are allowed to use the query function.
3. A software retrieval classification processing system as claimed in claim 2, characterized in that: The front-end code encapsulation unit includes: Form components, used to create and manage user input data; Table component, a component used to display data lists; Paging component, used to implement paging browsing of data.
4. A software retrieval classification processing system as claimed in claim 2, characterized in that: The three public interfaces include: The first public interface is used to query the menu table and the menu permission table to determine whether the currently logged-in user is allowed to use this function; The second public interface is used to query the filter table and obtain all query options supported by the query function; The third public interface is called when you click the query button after selecting the query option. It will query the corresponding table in the database according to the selected query option and the name of the query table filled in the menu table, and convert the result into query result and then transmit it to the front end.
5. A software retrieval classification processing system as claimed in claim 1, characterized in that: New query function modules include: Create three new tables in the database and add corresponding data; In the backend, create a new Java class and add annotations to the Java class; In the front end, introduce custom vue components.
6. A software retrieval classification processing system as claimed in claim 5, characterized in that: The three forms include: Menu table, used to add unique identifier; Filters table, for adding query options; Menu permission table, used to add usage permissions.
7. A software retrieval classification processing system as claimed in claim 1, characterized in that: Custom modules include: Customize the front-end style and use CSS language to customize the style of query results; Customize the backend query interface. When the user clicks the query button, the customized query interface is called.
8. A software retrieval classification processing method, using a software retrieval classification processing system according to any one of claims 1 to 7, characterized in that: The method comprises the following steps: S1. Based on the unique identifier of the referenced vue component, the front end calls the first public interface of the back end; S2. In the first public interface, query the database to obtain the settings of the query function; S3, the back end sends the query result obtained in the first public interface to the front end; S4. According to the unique identifier of the referenced vue component, the front end calls the second public interface of the back end; S5. Second, in the public interface, query the database to obtain all query options of the query function; S6. The back end sends the query result obtained in the second public interface to the front end; S7: The front end performs page rendering according to the results obtained in step S3 and step S6 to obtain the page that the user sees; S8. The user clicks a query button to call the third public interface or a custom interface to query the data required by the user; S9. Display the queried data on the page.