ssm / shiro / freemarker / boottstrap 로그 인
8885 단어 배우 면서 일 을 하 다
프로젝트 코드 디 렉 터 리 구조: maven + idea + ssm
데이터베이스 연결 탱크 는 아 리 의 druid 를 사용 합 니 다.
페이지 는 H + 프레임 워 크 를 사용 합 니 다.
홈 페이지 전시:http://www.zi-han.net/theme/hplus/
페이지 원본:http://download.csdn.net/download/m0_37499059/10253204
프로젝트 소스 코드:http://download.csdn.net/download/m0_37499059/10253208
죄송합니다. sql = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = =
/*
Navicat MySQL Data Transfer
Source Server : 11
Source Server Version : 50559
Source Database : teemo
Target Server Type : MYSQL
Target Server Version : 50559
File Encoding : 65001
Date: 2018-02-26 18:47:22
*/
SET FOREIGN_KEY_CHECKS=0;
-- ----------------------------
-- Table structure for sys_log
-- ----------------------------
DROP TABLE IF EXISTS `sys_log`;
CREATE TABLE `sys_log` (
`id` bigint(20) NOT NULL AUTO_INCREMENT COMMENT ' ',
`type` char(1) DEFAULT '1' COMMENT ' ',
`title` varchar(255) DEFAULT '' COMMENT ' ',
`content` varchar(1000) DEFAULT '' COMMENT ' ',
`create_by` varchar(32) DEFAULT NULL COMMENT ' ',
`create_date` datetime DEFAULT NULL COMMENT ' ',
`remote_addr` varchar(255) DEFAULT NULL COMMENT ' IP ',
`request_uri` varchar(255) DEFAULT NULL COMMENT ' URI',
`remark` varchar(255) DEFAULT NULL COMMENT ' ',
PRIMARY KEY (`id`),
KEY `sys_log_create_by` (`create_by`),
KEY `sys_log_request_uri` (`request_uri`)
) ENGINE=InnoDB AUTO_INCREMENT=2 DEFAULT CHARSET=utf8 COMMENT=' ';
-- ----------------------------
-- Records of sys_log
-- ----------------------------
INSERT INTO `sys_log` VALUES ('1', '1', '1', '1', '1', '2018-02-20 18:26:31', '192.168.1.1', '/user', null);
-- ----------------------------
-- Table structure for u_permission
-- ----------------------------
DROP TABLE IF EXISTS `u_permission`;
CREATE TABLE `u_permission` (
`id` bigint(20) NOT NULL AUTO_INCREMENT,
`name` varchar(255) DEFAULT NULL COMMENT ' ',
`url` varchar(64) DEFAULT NULL COMMENT 'url ',
`permission` varchar(256) DEFAULT NULL COMMENT ' ',
PRIMARY KEY (`id`)
) ENGINE=InnoDB AUTO_INCREMENT=4 DEFAULT CHARSET=utf8;
-- ----------------------------
-- Records of u_permission
-- ----------------------------
INSERT INTO `u_permission` VALUES ('1', ' ', '/admin', null);
INSERT INTO `u_permission` VALUES ('2', ' ', '/user', null);
INSERT INTO `u_permission` VALUES ('3', ' ', '/test', null);
-- ----------------------------
-- Table structure for u_role
-- ----------------------------
DROP TABLE IF EXISTS `u_role`;
CREATE TABLE `u_role` (
`id` bigint(20) NOT NULL AUTO_INCREMENT,
`name` varchar(32) DEFAULT NULL COMMENT ' ',
`type` varchar(10) DEFAULT NULL COMMENT ' ',
PRIMARY KEY (`id`)
) ENGINE=InnoDB AUTO_INCREMENT=4 DEFAULT CHARSET=utf8;
-- ----------------------------
-- Records of u_role
-- ----------------------------
INSERT INTO `u_role` VALUES ('1', 'admin', ' ');
INSERT INTO `u_role` VALUES ('2', 'user', ' ');
INSERT INTO `u_role` VALUES ('3', 'test', ' ');
-- ----------------------------
-- Table structure for u_role_permission
-- ----------------------------
DROP TABLE IF EXISTS `u_role_permission`;
CREATE TABLE `u_role_permission` (
`rid` bigint(20) DEFAULT NULL COMMENT ' ID',
`pid` bigint(20) DEFAULT NULL COMMENT ' ID'
) ENGINE=InnoDB DEFAULT CHARSET=utf8;
-- ----------------------------
-- Records of u_role_permission
-- ----------------------------
INSERT INTO `u_role_permission` VALUES ('1', '1');
INSERT INTO `u_role_permission` VALUES ('2', '2');
INSERT INTO `u_role_permission` VALUES ('3', '3');
-- ----------------------------
-- Table structure for u_user
-- ----------------------------
DROP TABLE IF EXISTS `u_user`;
CREATE TABLE `u_user` (
`id` bigint(20) NOT NULL AUTO_INCREMENT COMMENT ' ',
`realname` varchar(255) DEFAULT NULL COMMENT ' ',
`username` varchar(100) NOT NULL COMMENT ' ',
`portrait` varchar(250) DEFAULT NULL COMMENT ' ',
`password` varchar(100) DEFAULT NULL COMMENT ' ',
`email` varchar(20) DEFAULT NULL COMMENT ' ',
`phone` varchar(20) DEFAULT NULL COMMENT ' ',
`create_by` varchar(32) DEFAULT NULL COMMENT ' ',
`create_time` datetime DEFAULT NULL COMMENT ' ',
`last_login_time` datetime DEFAULT NULL COMMENT ' ',
`status` bigint(1) DEFAULT '1' COMMENT '1: ,0: ',
`remarks` varchar(255) DEFAULT NULL COMMENT 'openid',
`del_flag` char(1) DEFAULT '1',
PRIMARY KEY (`id`,`username`),
UNIQUE KEY `idx_u_user_username` (`username`),
UNIQUE KEY `idx_u_user_email` (`email`),
UNIQUE KEY `idx_u_user_phone` (`phone`)
) ENGINE=InnoDB AUTO_INCREMENT=10003 DEFAULT CHARSET=utf8;
-- ----------------------------
-- Records of u_user
-- ----------------------------
INSERT INTO `u_user` VALUES ('10000', ' ', 'admin', null, 'df655ad8d3229f3269fad2a8bab59b6c', '[email protected]', null, null, null, null, '1', 'B43738161A2026887D10C16FE5341F64', '1');
INSERT INTO `u_user` VALUES ('10001', ' ', 'user', null, '098d2c478e9c11555ce2823231e02ec1', null, null, null, null, null, '1', 'B0CA0ED3FD66F6E85EDC4A050A75DAC3', '1');
INSERT INTO `u_user` VALUES ('10002', ' ', 'test', null, '4292bb58be34c59d28a0dcbd11932d49', null, null, null, null, null, '1', null, '1');
-- ----------------------------
-- Table structure for u_user_role
-- ----------------------------
DROP TABLE IF EXISTS `u_user_role`;
CREATE TABLE `u_user_role` (
`id` int(10) NOT NULL AUTO_INCREMENT,
`uid` bigint(20) DEFAULT NULL COMMENT ' ID',
`rid` bigint(20) DEFAULT NULL COMMENT ' ID',
PRIMARY KEY (`id`)
) ENGINE=InnoDB AUTO_INCREMENT=4 DEFAULT CHARSET=utf8;
-- ----------------------------
-- Records of u_user_role
-- ----------------------------
INSERT INTO `u_user_role` VALUES ('1', '10000', '1');
INSERT INTO `u_user_role` VALUES ('2', '10001', '2');
INSERT INTO `u_user_role` VALUES ('3', '10002', '3');