web file monitoring system

Record learning every day, have a good mood every day. * ^ _ ^ *

Today records of the project is a web-based file monitoring system for information safety problems, this chapter is designed to monitor the file system to achieve file transfers of important real-time monitoring, to achieve the purpose of illegal transfer files securely to prevent theft. With very popular B / S architecture of current to develop as JAVA technology relying on SSM technical framework, mysql database to establish the system.
When doing a web-based file monitoring system, we need to use SSM (MYECLIPSE) framework, development tools choose the most adept MYECLIPSE.
Web-based document control system project is a project background.
When developing the system, needs analysis is an essential part. Log role of web-based file monitoring system has included the administrator.
Set the identity of each account, account number, password is essential, administrators are included in some of these login role of the field.

Summary drawn web file monitoring system based on all project data: administrator (admin), ad hoc description (tesemiaoshu), the monitoring system (jiankongxitong)

Table-based file monitoring systems administrator of the web

Field Name | Type | property | Description
id |  INT ( 11 ) |  PRIMARY  KEY  | administrator id
username |  VARCHAR ( 255 ) |  | account
password |  VARCHAR ( 255 ) |  | password
quanxian |  VARCHAR ( 255 ) |  | rights

 

Based on ad hoc file description of the monitoring system of the web

Field Name | Type | property | Description
id |  INT ( 11 ) |  PRIMARY  KEY  | Special Description id
wenjianjiami |  VARCHAR ( 255 ) |  | file encryption
wenjianchuanshu |  VARCHAR ( 255 ) |  | File Transfer
wenjiangenzong |  VARCHAR ( 255 ) |  | file tracking
wenjianjieshou |  VARCHAR ( 255 ) |  | documents received

 

File-based monitoring system of web monitoring of system tables

Field Name | Type | property | Description
id |  INT ( 11 ) |  PRIMARY  KEY  | file monitoring id
wenjianjiankong |  VARCHAR ( 255 ) |  | Document Control
wenjianhuifu |  VARCHAR ( 255 ) |  | File Recovery
yuanchengkongzhi |  VARCHAR ( 255 ) |  | Remote Control

 

 

SET FOREIGN_KEY_CHECKS=0;

-- ----------------------------

-- ----------------------------

-- Table structure for ggjywebdwjjkxt

-- ----------------------------

DROP TABLE IF EXISTS `t_admin`;

The CREATE  TABLE `t_admin` (` id` the INT ( . 11 ) the NOT  NULL the AUTO_INCREMENT the COMMENT " administrator ID ' ,` username` VARCHAR ( 255 ) the DEFAULT  NULL the COMMENT ' account number ' , `password` VARCHAR ( 255 ) the DEFAULT  NULL the COMMENT ' password ' , `quanxian` VARCHAR ( 255 ) the DEFAULT  NULL the COMMENT ' authority ' , a PRIMARY KEY (`id`)

) ENGINE = MyISAM the DEFAULT the CHARSET = UTF8 the COMMENT = " Administrator " ;

-- ----------------------------

DROP TABLE IF EXISTS `t_tesemiaoshu`;

The CREATE  TABLE `t_tesemiaoshu` (` id` the INT ( . 11 ) the NOT  NULL the AUTO_INCREMENT the COMMENT ' Ad Hoc described in ID ' , `wenjianjiami` VARCHAR ( 255 ) the DEFAULT  NULL the COMMENT ' File Encryption ' ,` wenjianchuanshu` VARCHAR ( 255 ) the DEFAULT  NULL the COMMENT ' file transfer ' , `wenjiangenzong` VARCHAR ( 255 ) the DEFAULT  NULL the COMMENT ' file tracking ', `wenjianjieshou` VARCHAR ( 255 ) the DEFAULT  NULL the COMMENT ' file reception ' , a PRIMARY  KEY (` id`)

) ENGINE = MyISAM the DEFAULT the CHARSET = UTF8 the COMMENT = ' Ad Hoc described ' ;

-- ----------------------------

DROP TABLE IF EXISTS `t_jiankongxitong`;

The CREATE  TABLE `t_jiankongxitong` (` id` the INT ( . 11 ) the NOT  NULL the AUTO_INCREMENT the COMMENT ' file monitoring ID ' , `wenjianjiankong` VARCHAR ( 255 ) the DEFAULT  NULL the COMMENT ' document control ' ,` wenjianhuifu` VARCHAR ( 255 ) the DEFAULT  NULL the COMMENT ' file recovery ' , `yuanchengkongzhi` VARCHAR ( 255 ) the DEFAULT  NULL the COMMENT ' remote control ',PRIMARY KEY (`id`)

) ENGINE = MyISAM the DEFAULT the CHARSET = UTF8 the COMMENT = ' monitoring system ' ;

 

Add Special description module:

From page via the post method, described in the ad hoc information passed to the server in the background, in tianjiatesemiaoshuact

Receiving, field includes file encryption, file transfer, document tracking, add data file using the insert receiving method, the data is synchronized to the

Database, add the operation is complete. Added successfully defined message, adding the ad hoc description successful, and stores the request code would read:

The ad hoc page described by the added transmission method tesemiaoshudao insert into the database tesemiaoshudao.insert (tesemiaoshu);

Add the ad hoc information describing success, to save the message request, the user is given prompt request.setAttribute in the page ( "message", "description add ad hoc success");

Returns the ad hoc management interface description

return "forward:/tianjiatesemiaoshu.action";

Ad hoc query module description:

Ad hoc query module implementation as described initiated tesemiaoshuguanli.action request page. By this request, the server response tesemiaoshuController class tesemiaoshuguanli, query data by selectByexample operation in the process. After all the description information of the ad hoc inquiry, the request stored in the tesemiaoshuall, on display in the page returned tesemiaoshuguanli.jsp, the portion of the core code is as follows:

Generating a sample type description of the ad hoc, query by example defined TesemiaoshuExample example = new TesemiaoshuExample ();

SelectByExample method by query of all ad hoc tesemiaoshudao description List tesemiaoshuall = tesemiaoshudao.selectByExample (example);

The ad hoc description information, stored in the request, on display request.setAttribute ( "tesemiaoshuall", tesemiaoshuall) foreach method by page;

Returns the ad hoc management interface description

return "forward:/tesemiaoshuguanli.action";

Ad hoc modification description module:

Click the Edit button, you can jump to the description of the ad hoc modification page. In the ad hoc modified page description, all of the information described in the initialization of the ad hoc, and the correspondence information corresponding to the edit field is filled. After editing the description of the ad hoc information page by encapsulating the data post method is described in an ad hoc entity, passed into the tesemiaoshuController. In xiugaitesemiaoshu the reception, after reception is completed, the call updateByPrimaryKeySelective method tesemiaoshuMapper modified. The part of the code as follows:

The ad hoc id corresponding modified by modifying the method described tesemiaoshudao tesemiaoshudao.updateByPrimaryKeySelective (tesemiaoshu);

The ad hoc modifications described the success of information, save the message request, the user is given prompt request.setAttribute in the page ( "message", "modify the description of a successful ad hoc");

Returns the ad hoc management interface description

return "forward:/tesemiaoshuguanli.action";

Delete ad hoc module description:

By a label on the page, shanchutesemiaoshu? Id = id will be passed to the background, the ad hoc reception by shanchutesemiaoshu description id. Use of deleteByid

Delete the ad hoc description, complete deletion. Delete the definition of a successful message, delete the ad hoc describe successful, and saved to the request, the part of the code is as follows:

Delete by deleting the corresponding methods described in the ad hoc id tesemiaoshudao according tesemiaoshudao.deleteByPrimaryKey (id);

Information will be deleted ad hoc describe success, to save the message request, the user is given prompt request.setAttribute in the page ( "message", "delete the ad hoc describe success");

Returns the ad hoc management interface description

return "forward:/tesemiaoshuguanli.action";

 

Source download

Guess you like

Origin www.cnblogs.com/hxlk/p/11666960.html