Start of the wireless ordering program

Source: Internet
Author: User
Tags version control system

Wireless ordering Project launch recently, in cooperation with the university training, did a small project, wireless ordering system. The system is mainly used for learning purposes, integrated with javaweb development of the underlying technology, using the JSP+SERVLET+MYSQL database to achieve development, although this development model in the current development has been rarely used, but for beginners, Learning Javaweb Bottom-level technology is still a certain help. The project uses the MVC idea to carry on the project development, is suitable for the entry level Javaweb friends, the great god please skip. The first blog post I wrote today was mainly about the start of the project, the background of the project, the technology used in the project, the software, and so on. Don't say much, let's read the blog first.
Wireless ordering Platform Project Combat course

Release Notes

Rev

Date

By

Comment

V1.0

2014-11-18

Leo Chen

Document creation

V2.0

2014-11-30

Leo Chen

Document Perfection

1,Pre-Project 1.1ProjectBackground

With the rapid development of China's national economy, people's living standards continue to improve, the pace of life has prompted more and more people to go out to order meals. Traditional catering industry, is generally the restaurant attendant manual completion, the process for customers to sit down after the restaurant, the waiter order, and then the menu to the chef, the chef began to cook, the process in a small restaurant can, the big restaurant is not. China's traditional catering industry due to its poor service quality and complex ordering procedures, the need for information transformation. Through the means of information can not only improve the service quality and efficiency of the catering industry, but also reduce costs and increase revenue. Wireless ordering platform includes the management of restaurant administrator, Customer Self-service, kitchen order management, online restaurant service and other subsystems. Main functions include: cuisine management, food management, table management, membership management, order management, customer ordering, checkout, online restaurant services.

1.2Demand Analysis

Demand analysis is the analysis of the needs of software users is what.If you invest a lot of manpower, material resources,Financial,Time,the software was developed and no one wanted to,all the input was futile..if it took a lot of energy,Develop a software,Finally, it doesn't meet the user's requirements.,to be re-developed.,This kind of rework is bitterly. (I believe we all have a feeling)like,users need aFor Linuxof Software,and you ignored the software's operating environment in the early stages of software development .,forgot to ask the user this question,and take it for granted that developmentFor windowsof Software,when you make the most of your development and commit to the user, you only find the problem.,At that time you were crying and no tears.,can't wait to find a piece of tofu to die.

Demand analysis is important because he has a decision-making , directional , strategic role , He plays a pivotal role in the software development process . we must have enough attention to the demand analysis . in the development of a large-scale software system , His role is far greater than the programming .

The demand analysis of the wireless Food Platform project see: Wireless ordering requirements Documentation . doc

2.Development2.1Technology, skills analysis2.1.1technical skill points in the project

①jsp/servlet(java EE technology)

② Reflection technology for Web application Architecture decoupling

③ Food image upload (file upload)

④MySql Database technology

⑤ Restaurant orders, online ordering, the realization of dining car

⑥SVN Project Project Management

2.1.2technology and software used in the project

Number

Tools

Version

Description

1.

Servlet

2.2

As a web Controller

2.

Jsp

2.2

displaying page data information

3.

C3p0

0.9.2

Manage Database connections

4.

Dbutils

1.4

Perform database persistence operations

5.

Apache FileUpload

1.2.1

File Upload Tool

6.

Junit

4.0

Unit Test

7.

Mysql

5.5.X

Number of stored data

8.

Svn

1.6

Developing version control software

2.2Development Environment

Operating system

Windows 7

Development tools

MyEclipse 2014

Database

Mysql-5.5.67-win32

Web container

Tomcat 7.0

Jdk

1.7

Browser

Firefox

2.3Development Conventions2.3.1about encoding

Project, page, database encoding unified code for UTF-8

Windowàpreferencesàgeneralàworkspace You can modify the default code for the workspace

2.3.2Package Structure Naming conventions

Company Name + project name + use name specific named as follows:

Package Name

Description

Cn.wirelessplatform.dao

DAO interface

cn. Wirelessplatform.dao.impl

DAO's implementation class

cn. Wirelessplatform.service

Service Interface

cn. Wirelessplatform.service.impl

Implementation class for service

Cn.wirelessplatform.web.controller

Servlet controllers in the Web

Cn.wirelessplatform.web.listener

Web Listener

Cn.wirelessplatform.util

Storage Tool Class

Cn.itcast.wirelessplatform.model

Entity class

2.3.3Page Related

L JSP, CSS, JS file separate, named the same

L do not embed any JS code in the HTML code

L Admin Background page suggest to put the page under Web-inf

L user page recommended to WebRoot , through the anti-theft chain to solve security problems

2.3.4Database Related

Notes on establishing a table note:

1. If MySQL is the green version, first set the MySQL encoding, the encoding is a UTF8

2. The database does not recommend setting custom constraints, and non-null constraints, which may inconvenience development and testing, and when really put into use, data non-null constraints rely on foreground and background validation to implement, the database is only responsible for storage

3. database data should not be deleted as far as possible , You can add a status column , so as to facilitate later recovery of data

4. in software development , in order to improve table performance , try not to set foreign keys , table relationship is more flexible

5. When writing SQL statements, it is best to write the full syntax (column name, column name) values (values, values) are useful for maintenance, otherwise the statements in front of the late increment field will not be used

2.4.software three-tier architecture review andMVCDevelopment Model2.4.1three-layer architecture pattern diagram


Layering considerations:

1. Call the DAO below, that is, view call Service,service.

2. Interface between layers and layers. You cannot use a class or interface that is unique to another layer other than the defined interface.

3. Using entities as DTOs (data Transfer object, data transfer objects)

4. In order to replace any layer, the other layers will not be affected.

2.4.2 MVCDevelopment pattern Profiling:

The full name of MVC is the model Viewcontroller, which is models -View -Controller (Controller) abbreviation, a model of software design, a business logic, data, interface display separation method to organize the code, the business logic into a part, in the improvement and personalization interface and user interaction, while There is no need to rewrite business logic. MVC is uniquely developed to map the traditional input, processing, and output functions in a logical graphical user interface structure. the MVC programming model is detailed in the following:MVC Development pattern . doc

3.Project Development Environment Construction3.1installationJDK

When we do Java Programming, we need to provide a compilation and runtime environment for Java programs, and then we need to use the JDK( java Development Kit)Java SDK, the version we are using is 1.7. "Installation Tutorial reference:JDK1.7 installation tutorial . doc"

3.2Installing development toolsMyEclipse2014

The development of the project program requires the use of professional integrated development tools, we use myeclipse, the current version is the Edition. "Installation Tutorial reference:MyEclipse2014 installation tutorial . doc"

3.3installationWebServerTomcat

When our program is developed, we need to provide the program to the outside world, so how to provide access to the outside world? At this point we need a server, we use Tomcat, the version is 7.

The installation of Tomcat is simple and can be extracted directly.

3.4Installing the database serverMySQL

Where is our data stored when the program is developed? In the software industry there is a sentence called "Data is priceless", then where is the data good? This is when we need to use the MySQL database server to store the data. "Installation Tutorial reference:MySQL installation Diagram . doc"

3.5installationMySQLDatabase Administration Toolssqlyogent

The program can be extracted directly.

3.6To install the Project version Control toolSVN(Learning project development can not be installed)

Svnis aSubversionis an open source version control system, compared toRCS,CVS, it uses the branch management system, its design goal is to replaceCVS. Many version control services on the internet have beenCVSMigrating toSubversion. Using SVN in project developmentco-development as a team and project version control"Installation Tutorial Reference:SVNserver-side installation instructions. doc,MyEclipseinstallationSVNplug -in methods. doc"

4.in theMyEclipsein-building projects4.1ModifyMyEclipseof theWorkspaceCoding

Windowàpreferencesàgeneralàworkspace You can modify the default code for the workspace

4.2New Project

The project name is: Wirelessplatform

Fileànewàweb Project new Web Project

Click Next to enter the next configuration:

Click Next next to configure

The last configuration to note:

Red box up to tick, let it generate the Web. XML configuration file, click Finish to build the project.

4.3required to add a projectJarPackage

For installation tutorials such as development software used in the project, please click here to download

Please click here to download the jar package used in the project.


Start of the wireless ordering program

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.