MINISTRY OF EDUCATION AND TRAINING HO CHI MINH CITY UNIVERSITY OF TECHNOLOGY AND EDUCATION FACULTY FOR HIGH QUALITY TRAINING CAPSTONE PROJECT INFORMATION TECHNOLOGY SOURCE CODE GENERATOR FOR WEB APPLICATION BASED ON THE EXISTING DATABASE LECTURERMSc. NGUYEN DUC KHOAN 6TUDENT PHAN SON HUYNH QUOC HOANG VUONG S K L0 0 8 0 9 0 Ho Chi Minh City, July 2021 HO CHI MINH CITY UNIVERSITY OF TECHNOLOGY AND EDUCATION FACULTY FOR HIGH QUALITY TRAINING GRADUATION THESIS SOURCE CODE GENERATOR FOR WEB APPLICATION BASED ON THE EXISTING DATABASE Advisor: NGUYEN DUC KHOAN, MSc. Student Name: Student ID: PHAN SON 17110216 HUYNH QUOC HOANG VUONG 17110256 Course: 2017 Ho Chi Minh City, July 2021 THE SOCIALIST REPUBLIC OF VIETNAM Independence – Freedom– Happiness -------- Ho Chi Minh City, July 20, 2021 GRADUATION PROJECT ASSIGNMENT Student name: PHAN SON Student ID: 17110216 Student name: HUYNH QUOC HOANG VUONG Student ID: 17110256 Major: INFORMATION TECHNOLOGY Class: 17110CLST Advisor: MSc. NGUYEN DUC KHOAN.
Phone number: Date of assignment: 15/03/2021 Date of submission: 19/07/2021 1. Project title: SOURCE CODE GENERATOR FOR WEB APPLICATION BASED ON THE EXISTING DATABASE. Initial materials provided by the advisor: Implementation using, ASP.1, Python Flask, SQL Server, MEAN Stack. Content of the project: Easy Web is an Open-Source website that allows users to register their database.
From there, the system will analyze the entities in the user's database. Go through the steps of registering the user's database and adjusting the entities in the Easy Web system. Finally, Easy Web will return to the user. From there the end-user can use it based on the instructions that Easy Web.
Final product: Web application that includes both front-end and back-end. CHAIR OF THE PROGRAM ADVISOR (Sign with full name) (Sign with full name) i THE SOCIALIST REPUBLIC OF VIETNAM Independence – Freedom– Happiness -------- Ho Chi Minh City, July 20, 2021 GRADUATION PROJECT ASSIGNMENT Student name: PHAN SON Student ID: 17110216 Student name: HUYNH QUOC HOANG VUONG Student ID: 17110256 Major: INFORMATION TECHNOLOGY Class: 17110CLST Project title: SOURCE CODE GENERATOR FOR WEB APPLICATION BASED ON THE EXISTING DATABASE. Advisor: NGUYEN DUC KHOAN, MSc. Content of the project: …………………………………………………………………………………… …………………………………………………………………………………… 2.
Approval for oral defense? (Approved or denied) …………………………………………………………………………………… …………………………………………………………………………………… 5.in words: …………………………………………… Ho Chi Minh City, July 2021 ADVISOR (Sign with full name) ii THE SOCIALIST REPUBLIC OF VIETNAM Independence – Freedom– Happiness -------- Ho Chi Minh City, July 20, 2021 PRE-DEFENSE EVALUATION SHEET Student name: PHAN SON Student ID: 17110216 Student name: HUYNH QUOC HOANG VUONG Student ID: 17110256 Major: INFORMATION TECHNOLOGY Class: 17110CLST Project title: SOURCE CODE GENERATOR FOR WEB APPLICATION BASED ON THE EXISTING DATABASE. Name of Reviewer: NGUYEN DUC KHOAN, MSc. Content of the project:. Approval for oral defense? (Approved or denied) .) Ho Chi Minh City, July 2021.
REVIEWER (Sign with full name) iii ACKNOWLEDGEMENTS First, the team would like to sincerely thank the teachers, departments, and related people in the high-quality training department and the University of Technology and Education in general. Thanks to that, the team could approach, learn, and explore and apply the acquired knowledge. The team was very sincere to Mr. Nguyen Duc Khoan who played the role of both a lecturer and a mentor during the process of this graduating session.
His enthusiastic guidance helped the team a lot in posing problems and solving problems that the group encountered. Finally helped the team complete this Easy-Web web application. iv TABLE OF CONTENTS CHAPTER 1. Review current solutions……………………………………………….
Visual Studio’s MVC Web Application Generator.5 Microsoft SQL Server 2019…………………………………………. Actor of system. Use case diagram. Use case specification.
Use case description. Unauthorized user - Use case description. Authorized user - Use case description. Non-functional requirement.
Entity Relationship diagram. SYSTEM DESIGN AND IMPLEMENTATION. Source code generator framework. The process to create a website from an existed database.
Class diagram for Easy-Web’s System. Class diagram description for class User. Class diagram description for class BaseEntity. Class diagram description for class UserDatabaseInfo.
Class diagram description for class WebGeneratedHistory. Class diagram use for Source code generates framework system. Class diagram description for class BaseEntity. Class diagram description for class SystemMasterConfig.
Class diagram description for class SystemTableConfig. Class diagram description for class SystemTableColumnConfig. Class diagram description for class SystemTableForeignKeyConfig. Generate a website from an existed database.
Back-end source code generator. Front-end source code generator. Website source code generator framework. User interface design………………………………………………….
System - UI for the unauthenticated user. SCA_017 Homepage system – Easy-Web Blog. SCA_014 Register database connection string. SCA_13 Configure tables.
SCA_015 Configure Columns. SCA_016 Fill out Information & Preview. SCA_005 Login page. SCA_004 Register page.
SCA_003 View demo table management screen. SCA_001 Create data demo screen. Database Physical Diagram. Software development environment………………………………….
Source code management……………………………………………. Easy-Web web user interface. Website source code generates framework. User’s Generated website.
List of stages of testing. List of test types. Items to be tested. Features to be tested.
Test case of check login function. Test case register function. Test case register database connection string. Test case config table.
Test case config column. 91 TABLE OF TASKS. 92 ix LIST OF ABBREVIATIONS Table 1. List of Abbreviations.
Term Definition DB Database RQ Redis Queue API Application Programming Interface MEAN MongoDB, Express.js, Angular, NodeJS HTTP Hyper Text Transfer Protocol CMS Content Management System FE Front-end BE Back-end DBMS Database Management System CRUD Create – Read – Update - Delete IDE Integrated development environment NPM Node Package Manager VPS Virtual Private Server x LIST OF TABLES Table 1. List of Abbreviations. Use case specification. Use case uc_01.
Use case uc_02. Use case uc_03. Use case uc_04. Use case uc_05.
Use case uc_06. Use case uc_07. Use case uc_08. Use case uc_09.
Use case uc_10. Use case uc_11. Use case uc_12. Use case uc_13.
Use case uc_14. Use case uc_16. Description for class User. Description for class BaseEntity.
Description for class UserDatabaseInfo. Description for class WebGenetatedHistory. Description for class BaseEntity. Description for class SystemMasterConfig.
Description for class SystemTableConfig. Description for class SystemTableColumnConfig. Description for class SystemTableForeignKeyConfig. Screen flow description.
Homepage screen description. Blog screen description. Table register database screen connection. Configure table screen description.
Config columns screen. Generate website step 04 screen description. Demo Login page screen. Demo Register UI screen description.
View detail UI screen description. Create a new entity screen description. Description for tables of Web Application. Description for tables of Website generated.
Software development environment. Test case check login. Test case register function. Test case register database.
Test case config table. Test case config column. Team member tasks assignment and working schedule. 92 xii LIST OF FIGURES Figure 2.NET Core logo.
Python Flask logo. Microsoft SQL Server logo. Redis Queue model. MEAN Stack model.
Easy-Web – use case diagram. Use case register account. Use case login. Use case view demo login page.
View demo register page.6 Use case view demo page view detail. Use case view demo update page. View demo creates page create data. Use case view all websites generated.
Use case download source code generated. Use case view all tables fetched. Use case change table display name. Use case hide table.
Use case register database connection string. View all columns in the table. Use case hide column. ERD Diagram for EasyWeb Web Application.
ERD for generating websites. System architecture diagram. Web application Back-end component diagram. Web application Angular component diagram.
Source code generator component diagram. Activity diagram for creates a website from an existed database. Class diagram for Web Application.7 Class diagram for web generate. Sequence diagram for the login function.
Sequence diagram for generate website from an existed database. Sequence diagram for generate back-end of the web generated. Sequence diagram for generate front-end of the web generated. Sequence diagram for the web generator.
Screen flow Easy-Web. Homepage Easy-Web screen. Homepage Easy-Web Blog screen. Register database connection string steps 01 screens.
Generate website step 02 screen. Generate website step 03 screen. Generate website step 04 screen. Demo Login page screen.
Demo Register screen. Demo View detail screen. Create a new entity screen. Database physical diagram for Web Application.
Database physical diagram for a website generated. Generated website overview model. 82 xiv Graduation Thesis CHAPTER 1. Nowadays, with the rapid development of the information technology industry, to keep up with the demand, technology must change continuously.
Especially in the web application industry, which is growing stronger, but human resources are still limited. Programmers in general, especially website developers, when to have experience in creating a website, the same goes for other websites. When doing the same job repeatedly, can be boring and time-consuming. Because of that, the team decided to build Easy-Web to build a website automatically.
So, the team came up with an idea to shorten the time it takes to build a website. With Easy-Web, users can create a web management application automatically by registering their database in the system. Based on the database that the user has provided, the system will be able to read the tables, columns, and data contained in that database. After four steps of configuration, users will be able to get a website with full source code BE & FE.
Based on the source code of the generated website, it will have functions of a website based on the tables in the user's database, they can download and use it or customize the code inside. Review current solutions. Visual Studio’s MVC Web Application Generator. This is a build-in feature included with Visual Studio 2017 and after.
Using MVC, Entity Framework, and ASP.NET Scaffolding tool, we can create a web application that provides an interface to an existing database. • Function: o Create an MVC Web Application and Data model based on a user’s provided database. o Generate a view for each table of the existing database. • Advantages: o Since it’s a built-in feature of Visual Studio, users can easily access it.
o There are plenty of detailed instructions and manuals both from Microsoft and Internet’s author about how to use this. • Disadvantages: Chapter 01: Introduction. 1 Graduation Thesis o The user must have some base knowledge about .NET programming, Entity Framework command-line tool, and ASP.NET MVC Pattern. o Only generate MVC web applications.
o Need extra time and effort for fine-tuning and customizing generated Web Applications to the usable level. o Hard to deploy. o Hard to use. Through the survey of related products, the group draws out the required functions: ● User-friendly, minimal step and effort to create a website.
● No coding involved. ● Building an Ecosystem for users of Easy-Web. ● Let user customize their website: ○ Choose what table will be displayed and what name it will be called. ○ Choose what columns of a table will display and what name it will be called.
○ Choose what action (Create - Delete - Update) that the user can perform in a table. ○ Choose the name, logo, contact info of the website. ● Provide for the user a tool to instantly deploy the generated website to their server with minimum effort and setting. ● The website created must be responsive to a variety of screens.
The Easy-Web allows users to choose the databases to use in the system such as SQL Server, PostgreSQL, and MySQL. The team's current product is aimed at developers who have been building their websites according to the architecture including Angular, .NET Core, and SQL Server. Thanks to Easy Web, they can save time building a management website for themselves, they will focus full time on building the website on the client-side. Through the construction of Easy Web, the team also added new knowledge to apply including: ● Knowing basic progress to build an Open-Source product.
● Created, configured, and published the NPM library for reusable purposes. 2 Graduation Thesis ● Created both client and system UI with Angular, Bootstrap.NET Core ● Node.js The Easy-Web’s system has two main parts: ● Easy-Web’s website: ○ Front-end: Powered by Angular, where the user interacts with Easy-Web to create their website with a pre-existed database. ○ Backend: Powered by .