CN107133044B - Method and system for rapidly developing data maintenance type page - Google Patents

Method and system for rapidly developing data maintenance type page Download PDF

Info

Publication number
CN107133044B
CN107133044B CN201710313375.7A CN201710313375A CN107133044B CN 107133044 B CN107133044 B CN 107133044B CN 201710313375 A CN201710313375 A CN 201710313375A CN 107133044 B CN107133044 B CN 107133044B
Authority
CN
China
Prior art keywords
code
page
template
database
data maintenance
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.)
Active
Application number
CN201710313375.7A
Other languages
Chinese (zh)
Other versions
CN107133044A (en
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.)
Shanghai Ctrip Business Co Ltd
Original Assignee
Shanghai Ctrip Business 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 Shanghai Ctrip Business Co Ltd filed Critical Shanghai Ctrip Business Co Ltd
Priority to CN201710313375.7A priority Critical patent/CN107133044B/en
Publication of CN107133044A publication Critical patent/CN107133044A/en
Application granted granted Critical
Publication of CN107133044B publication Critical patent/CN107133044B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F8/00Arrangements for software engineering
    • G06F8/30Creation or generation of source code
    • G06F8/38Creation or generation of source code for implementing user interfaces
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/20Information retrieval; Database structures therefor; File system structures therefor of structured data, e.g. relational data
    • G06F16/21Design, administration or maintenance of databases

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • General Engineering & Computer Science (AREA)
  • Databases & Information Systems (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Software Systems (AREA)
  • Data Mining & Analysis (AREA)
  • Human Computer Interaction (AREA)
  • Information Retrieval, Db Structures And Fs Structures Therefor (AREA)
  • Information Transfer Between Computers (AREA)

Abstract

The invention discloses a method and a system for rapidly developing a data maintenance type page, wherein the method comprises the following steps: s1, creating a web application frame of the data maintenance type page, wherein the web application frame comprises a position of a code to be added; the code to be added comprises a page display layer code; s2, creating a first template aiming at the code to be added according to the structure of the table of the database, wherein the first template comprises a page display layer code template; s3, adding the first template to a code generation tool; s4, selecting the first template and a table of a database to be operated in the code generation tool to generate a target code; s5, adding the target code to the position of the code to be added in the web application framework; s6, compiling the web application framework to generate a data maintenance type page of the table of the database to be operated. The invention can effectively reduce the development workload of developers, improve the development efficiency and save the development cost.

Description

Method and system for rapidly developing data maintenance type page
Technical Field
The invention relates to the technical field of webpage development, in particular to a method and a system for rapidly developing a data maintenance type page.
Background
In the process of enterprise research and development, a plurality of cms (content management system) systems, configuration maintenance systems, information collection submission systems and the like are frequently encountered, the systems have a large amount of work of adding, deleting, changing, inquiring and the like of data of tables, data maintenance type pages need to be developed according to the requirement, the development modes of the data maintenance type pages have many similarities, and the data maintenance type pages are regular in the effect of program code realization and even page display and comprise a plurality of repeated mechanical code development works. The repeated mechanical code development work occupies too much development time of developers, the development efficiency of the data maintenance type page is seriously influenced, and the development cost is increased.
Disclosure of Invention
The invention aims to overcome the defects of long code development time, low efficiency and high development cost caused by repeated mechanical code development work in the development of a data maintenance type page in the prior art, and provides a method and a system for rapidly developing the data maintenance type page, which can reduce the development workload of developers, improve the development efficiency and save the development investment.
The invention solves the technical problems through the following technical scheme:
a method for rapidly developing a data maintenance type page is characterized by comprising the following steps:
s1, creating a web (global area network) application frame of the data maintenance type page, wherein the web application frame comprises a position of code to be added, and the code to be added is used for accessing a structure of a table of a database; the code to be added comprises a page display layer code, and the page display layer code is used for displaying a data maintenance type page in a browser;
s2, creating a first template aiming at the code to be added according to the structure of the table of the database, wherein the first template comprises a page display layer code template;
s3, adding the first template to a code generation tool;
s4, selecting the first template and the table of the database to be operated in the code generation tool, and generating target codes, wherein the target codes are used for realizing operations of adding, deleting, modifying, deleting in batches, modifying in batches, inquiring and/or paging display on the table of the database to be operated;
s5, adding the target code to the position of the code to be added in the web application framework;
s6, compiling the web application framework to generate a data maintenance type page of the table of the database to be operated.
In the scheme, the web application framework is a basic operation platform for generating the data maintenance type page, and comprises a code part to be added and common function codes of some pages. And after generating object codes of exclusive adding, deleting, changing, deleting in batches, changing in batches, inquiring and/or paging display operation for the tables in each database by using a code generation tool, adding the object codes into a web application framework, and compiling to generate a data maintenance type page of the table of the database to be operated.
In the scheme, the code generation tool can automatically generate target codes aiming at tables of different databases by selecting the tables of the different databases by using the same first template, then the target codes are added into the web application framework to generate data maintenance type pages aiming at the tables of the different databases, the development of codes according to the operation requirements of adding, deleting, modifying, batch deleting, batch modifying, inquiring and/or paging display of the tables of each database is avoided, the operation of the tables aiming at the databases does not need to be personalized on the page display style, namely, a part of repeated mechanical codes are included on the page display, so that the page display layer codes are generated by using one page display layer code template, and the generated codes are applied to the data maintenance type pages generated after the web application framework is compiled, but meets the operational requirements of the data maintenance type page. According to the scheme, the first template is used for the page display layer code to automatically generate the code of the data maintenance type page with the consistent page style, so that the development workload of developers is effectively reduced, the development efficiency is improved, and the development cost is saved.
Preferably, the code to be added further comprises DAL (data access layer) layer code and Model (physical class layer) layer code; the first template further comprises a DAL layer code template and a Model layer code template; the DAL layer code is used for realizing interaction with a database; the Model layer code is used for realizing entity classes corresponding to fields of tables of the database.
In the scheme, the DAL layer code template is used for realizing the interactive code with the database, so that the DAL layer code template can be divided into different templates according to different databases.
Preferably, the page display layer code includes a page effect display code and a page dynamic data display code.
In the scheme, the page effect presentation code is used for presenting the page effect in the browser, and the page dynamic data presentation code is used for presenting the dynamic data presented in the browser, for example, when the next page is clicked, new data loaded by the page needs to be taken from the server, when the next page is added or deleted, the new data needs to be sent to the server, and all interactions between the server and the page effect presentation code are transited by the code.
Preferably, the object code is also stored as a file or a code fragment in step S4.
In the scheme, based on a set of first templates of the code generation tool, the code file or the code segment can be automatically generated according to the structures of the first templates and the table of the database, and the generated code file or the generated code segment can be used in the web application framework as required.
Preferably, the code generation tool is a dynamic soft code generator.
In the scheme, the dynamic soft code generator is used for connecting the database, the target code can be automatically generated after the first template and the tables of the database are selected, and the dynamic soft code generator can also use the first template to generate the code in batches, namely the target code of the tables of several databases is generated simultaneously, so that the data maintenance pages of the tables of different databases are generated in batches.
This scheme still provides the quick development system of a data maintenance type page, and its characterized in that includes:
the frame creating module is used for creating a web application frame of the data maintenance type page, the web application frame comprises a position of a code to be added, and the code to be added is used for accessing a structure of a table of a database; the code to be added comprises a page display layer code, and the page display layer code is used for displaying a data maintenance type page in a browser;
the template creating module is used for creating a first template aiming at the code to be added according to the structure of the table of the database, and the first template comprises a page display layer code template;
a template adding module for adding the first template to a code generation tool;
the target code generation module is used for selecting the first template and a table of the database to be operated in the code generation tool to generate a target code, wherein the target code is used for realizing operations of adding, deleting, changing, deleting in batches, changing in batches, inquiring and/or paging display on the table of the database to be operated;
the code adding module is used for adding the target code to the position of the code to be added in the web application framework;
and the page generation module is used for compiling the web application framework to generate a data maintenance type page of the table of the database to be operated.
Preferably, the code to be added further comprises a DAL layer code and a Model layer code; the first template further comprises a DAL layer code template and a Model layer code template; the DAL layer code is used for realizing interaction with a database; the Model layer code is used for realizing entity classes corresponding to fields of tables of the database.
Preferably, the page display layer code includes a page effect display code and a page dynamic data display code.
Preferably, the object code generation module is further configured to store the object code as a file or a code fragment.
Preferably, the code generation tool is a dynamic soft code generator.
The positive progress effects of the invention are as follows: the rapid development method and the rapid development system for the data maintenance type page provided by the invention can automatically generate the maintenance page aiming at the table of the database, and the page functions comprise necessary addition, deletion, modification, batch deletion, batch modification, query and paging display. According to the invention, the codes of the data maintenance type page with consistent page style can be automatically generated by using the first template for the page presentation layer codes, so that the development workload of developers is effectively reduced, the development efficiency is improved and the development cost is saved.
Drawings
FIG. 1 is a flowchart illustrating a method for rapidly developing a data maintenance page according to a preferred embodiment of the present invention.
FIG. 2 is a diagram illustrating a system for rapidly developing a data maintenance page according to a preferred embodiment of the present invention.
FIG. 3 is a diagram illustrating a page generated by applying the method for rapidly developing a data maintenance page according to a preferred embodiment of the present invention.
Detailed Description
The invention is further illustrated by the following examples, which are not intended to limit the scope of the invention.
As shown in fig. 1, a method for rapidly developing a data maintenance type page includes the following steps:
step 101, creating a web application frame of the data maintenance type page, wherein the web application frame comprises a position of a code to be added, and the code to be added is used for accessing a table structure of a database; the code to be added comprises a page display layer code, a DAL layer code and a Model layer code, wherein the page display layer code is used for realizing the display of a data maintenance type page in a browser and comprises a page effect display code and a page dynamic data display code; the DAL layer code is used for realizing interaction with a database; the Model layer code is used for realizing entity classes corresponding to fields of tables of the database.
And 102, creating a first template aiming at the code to be added according to the structure of the table of the database, wherein the first template comprises a page display layer code template, a DAL layer code template and a Model layer code template.
And step 103, adding the first template to a dynamic soft code generator.
104, selecting the first template and a table of a database to be operated in the dynamic and soft code generator, and generating a target code, wherein the target code is used for realizing operations of adding, deleting, modifying, deleting in batches, modifying in batches, inquiring and/or paging display on the table of the database to be operated; the object code is stored as a code fragment.
Step 105, adding the target code to the position of the code to be added in the web application framework.
And 106, compiling the web application framework to generate a data maintenance type page of the table of the database to be operated.
As shown in fig. 2, a system for rapidly developing a data maintenance type page based on the method for rapidly developing a data maintenance type page shown in fig. 1 includes a frame creation module 1, a template creation module 2, a template addition module 3, an object code generation module 4, a code addition module 5, and a page generation module 6.
The frame creating module 1 is used for creating a web application frame of the data maintenance type page, wherein the web application frame comprises a code to be added, and the code to be added is used for accessing a table structure of a database; the code to be added comprises a page display layer code, a DAL layer code and a Model layer code, wherein the page display layer code is used for realizing the display of a data maintenance type page in a browser and comprises a page effect display code and a page dynamic data display code; the DAL layer code is used for realizing interaction with a database; the Model layer code is used for realizing entity classes corresponding to fields of tables of the database.
The template creating module 2 is configured to create a first template for the code to be added according to the structure of the table of the database, where the first template includes a page presentation layer code template, a DAL layer code template, and a Model layer code template.
The template adding module 3 is used for adding the first template to the dynamic soft code generator.
The target code generation module 4 is configured to select the first template and a table of the database to be operated in the dynamic and soft code generator, and generate a target code, where the target code is used to implement operations of adding, deleting, modifying, deleting in batches, modifying in batches, querying, and/or paging display on the table of the database to be operated; the object code generation module 4 is further configured to store the object code as a file or a code fragment.
The code adding module 5 is used for adding the target code to the position of the code to be added in the web application framework.
The page generation module 6 is configured to compile the web application framework to generate a data maintenance page of the table of the database to be operated.
The invention creates a set of first templates based on the dynamic soft code generator V2.77, and can automatically generate code files or code segments according to the structures of the first templates and tables of a database. The method and the system provided by the invention are suitable for the condition that the service relates to the table structure of more databases, and the maintenance page of the tables of the databases has simple and regular display effect requirement. When the dynamic soft code generator V2.77 is used, the database can be connected, and then the first template is selected to generate the target code, or the target code is generated in batch.
In the invention, each table of the codes generated by the Model layer code template corresponds to a file. The codes generated by other templates and corresponding codes of each form can be put together or can be used as a separate file.
Fig. 3 is a schematic diagram of a page generated by applying the rapid development method of the data maintenance-type page shown in fig. 1. Each table of the database can generate a page as shown in fig. 3, and the functions implemented by the page include addition, deletion, modification, addition after copying, batch deletion with multiple selections, batch modification with multiple selections, complex query with combined conditions, page display, and the like. The target codes generated by the invention and the codes applied to the web application framework can be continuously modified to realize the desired page effect. The requirement of complex customizability requires continuous development on the basis of the requirement. For example, the complex mother-child table linkage query and the like, the original generated codes are simply spliced and can be realized by slightly modifying. The requirement for a data maintenance page like that of fig. 3 can be directly achieved 100% without manual development. And the other types of requirements have high or low labor saving degree according to the matching degree.
The system applied by the invention has a large amount of work of adding, deleting, modifying, inquiring and the like aiming at the data of the table, a data maintenance type page needs to be developed aiming at the requirement, the development modes of the data maintenance type page have many similarities, the code realization and even page display effect of a program are regular, and the system comprises a plurality of repeated mechanical code development works. The invention adopts the mode of automatically generating codes to display the part of work of the page, and the page with consistent page style and meeting the increasing, deleting, changing and inquiring requirements of the user can be generated by using the same set of first template no matter how many tables are used, thereby effectively reducing the development workload of developers, improving the development efficiency and saving the development investment.
While specific embodiments of the invention have been described above, it will be appreciated by those skilled in the art that this is by way of example only, and that the scope of the invention is defined by the appended claims. Various changes and modifications to these embodiments may be made by those skilled in the art without departing from the spirit and scope of the invention, and these changes and modifications are within the scope of the invention.

Claims (10)

1. A method for rapidly developing a data maintenance type page is characterized by comprising the following steps:
s1, creating a web application frame of the data maintenance type page, wherein the web application frame comprises a position of a code to be added, and the code to be added is used for accessing a structure of a table of a database; the code to be added comprises a page display layer code, and the page display layer code is used for displaying a data maintenance type page in a browser;
s2, creating a first template aiming at the code to be added according to the structure of the table of the database, wherein the first template comprises a page display layer code template;
s3, adding the first template to a code generation tool;
s4, selecting the first template and a table of the database to be operated in the code generation tool to generate a target code, wherein the target code is used for realizing operations of adding, deleting, modifying, deleting in batches, modifying in batches, inquiring and/or paging display on the table of the database to be operated;
s5, adding the target code to the position of the code to be added in the web application frame;
and S6, compiling the web application framework to generate a data maintenance type page of the table of the database to be operated.
2. The method for rapid development of a data maintenance-type page according to claim 1, wherein the code to be added further comprises DAL-level code and Model-level code; the first template further comprises a DAL layer code template and a Model layer code template; the DAL layer code is used for realizing interaction with a database; the Model layer code is used for realizing entity classes corresponding to fields of tables of the database.
3. The method for rapidly developing a data maintenance type page according to claim 1 or 2, wherein the page presentation layer code includes a page effect presentation code and a page dynamic data presentation code.
4. The method for rapid development of a data maintenance-type page according to claim 1, wherein the object code is further stored as a file or a code fragment in step S4.
5. A method for rapid development of data maintenance type pages as claimed in claim 1 wherein said code generation tool is a dynamic soft code generator.
6. A system for rapid development of data maintenance pages, comprising:
the frame creating module is used for creating a web application frame of the data maintenance type page, the web application frame comprises a position of a code to be added, and the code to be added is used for accessing a structure of a table of a database; the code to be added comprises a page display layer code, and the page display layer code is used for displaying a data maintenance type page in a browser;
the template creating module is used for creating a first template aiming at the code to be added according to the structure of the table of the database, and the first template comprises a page display layer code template;
a template adding module for adding the first template to a code generation tool;
the target code generation module is used for selecting the first template and a table of the database to be operated in the code generation tool to generate a target code, wherein the target code is used for realizing operations of adding, deleting, changing, deleting in batches, changing in batches, inquiring and/or paging display on the table of the database to be operated;
the code adding module is used for adding the target code to the position of the code to be added in the web application framework;
and the page generation module is used for compiling the web application framework to generate a data maintenance type page of the table of the database to be operated.
7. The system for rapid development of data maintenance-type pages as claimed in claim 6, wherein said code to be added further comprises DAL-level code and Model-level code; the first template further comprises a DAL layer code template and a Model layer code template; the DAL layer code is used for realizing interaction with a database; the Model layer code is used for realizing entity classes corresponding to fields of tables of the database.
8. The system for rapid development of data maintenance-type pages according to claim 6 or 7, wherein the page presentation layer code comprises page effect presentation code and page dynamic data presentation code.
9. The system for rapid development of data maintenance-type pages of claim 6 in which the object code generation module is further to store the object code as a file or a piece of code.
10. A system for rapid development of data maintenance-type pages as claimed in claim 6 wherein said code generation tool is a dynamic soft code generator.
CN201710313375.7A 2017-05-05 2017-05-05 Method and system for rapidly developing data maintenance type page Active CN107133044B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201710313375.7A CN107133044B (en) 2017-05-05 2017-05-05 Method and system for rapidly developing data maintenance type page

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201710313375.7A CN107133044B (en) 2017-05-05 2017-05-05 Method and system for rapidly developing data maintenance type page

Publications (2)

Publication Number Publication Date
CN107133044A CN107133044A (en) 2017-09-05
CN107133044B true CN107133044B (en) 2021-01-05

Family

ID=59731466

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201710313375.7A Active CN107133044B (en) 2017-05-05 2017-05-05 Method and system for rapidly developing data maintenance type page

Country Status (1)

Country Link
CN (1) CN107133044B (en)

Families Citing this family (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110209798B (en) * 2017-12-22 2024-05-10 北京奇虎科技有限公司 Data display method and device of redis database
CN109582302A (en) * 2018-12-05 2019-04-05 江苏风云科技服务有限公司 Establishment of item system and automation projects creation method
CN109885294A (en) * 2019-01-21 2019-06-14 四川商通实业有限公司 A method of system code development efficiency is improved using system general character
EP4006721A4 (en) * 2019-08-27 2023-04-12 Siemens Aktiengesellschaft Application program development and deployment method and apparatus, and computer readable medium
CN112379880A (en) * 2020-12-01 2021-02-19 北京致远互联软件股份有限公司 Method for dynamically updating system page characters by zero codes
CN114217798A (en) * 2021-12-20 2022-03-22 中国农业银行股份有限公司 Code generation method and device for database form interface

Family Cites Families (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US7480698B2 (en) * 2003-12-18 2009-01-20 International Business Machines Corporation Updating event data on a page using code understood natively by a browser
CN101727324B (en) * 2009-12-17 2013-03-27 中国电力科学研究院 Code generation method and device
US8250478B2 (en) * 2010-01-28 2012-08-21 Microsoft Corporation State persistence and background initialization for post-back web applications
CN103617037B (en) * 2013-11-27 2017-12-08 邵寻 Development approach and web development system for web development system

Also Published As

Publication number Publication date
CN107133044A (en) 2017-09-05

Similar Documents

Publication Publication Date Title
CN107133044B (en) Method and system for rapidly developing data maintenance type page
CN109582909B (en) Webpage automatic generation method and device, electronic equipment and storage medium
CN115617327A (en) Low code page building system, method and computer readable storage medium
US9904522B2 (en) Web development system
RU2536390C2 (en) Automated report generation method
US9514115B2 (en) Method for creating form validation program and corresponding form interface according to result set metadata
CN103309806B (en) The device and method of a kind of quick development and testing
CN110705237B (en) Automatic document generation method, data processing device and storage medium
US20150066977A1 (en) Method and system for managing digital resources
CN102902558A (en) Project script file updating system and method as well as script file merging method and device
CN110609681A (en) System, method, device and medium for visually configuring and generating WEB application
CN110543303A (en) Visual business platform
CN108595681B (en) Method, device and system for displaying form
US20090037392A1 (en) Systems and methods for data retrieval, manipulation, and delivery
CN109213480A (en) A kind of method, storage medium, equipment and system for developing the back-stage management page
CN110750553A (en) Method for self-defining export of data in service management system
CN111367893A (en) Method and device for database version iteration
CN1542699A (en) GUI producing method and system
CN109284469B (en) Webpage development framework
CN103186365B (en) A kind of method and system generating steering order according to character contour change
CN103150391A (en) General database table webpage displaying method based on configuration files
CN103809915A (en) Read-write method and device of magnetic disk files
CN111435300A (en) Web system development method, device, equipment and storage medium
CN115510361A (en) Data chart page generation method based on visual configuration and related equipment
CN114780539A (en) Method, system and storage medium for generating report form in multiple dimensions

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
GR01 Patent grant
GR01 Patent grant