网络相册

网络相册登录注册界面

网络相册mysql数据库版本源码:

超级管理员表创建语句如下:


create table t_admin(
	id int primary key auto_increment comment '主键',
	username varchar(100) comment '超级管理员账号',
	password varchar(100) comment '超级管理员密码'
) comment '超级管理员';
insert into t_admin(username,password) values('admin','123456');

用户表创建语句如下:


create table t_customer(
	id int primary key auto_increment comment '主键',
	username varchar(100) comment '账号',
	password varchar(100) comment '密码',
	name varchar(100) comment '姓名',
	phone varchar(100) comment '手机',
	sex varchar(100) comment '性别',
	age varchar(100) comment '年龄',
	address varchar(100) comment '地点',
	idcard varchar(100) comment '工作方向',
	insertDate datetime comment '入库日期',
	headPic varchar(100) comment '头像',
	level varchar(100) comment '层级',
	isft varchar(100) comment '发帖权限',
	ispl varchar(100) comment '评论权限',
	mb1 varchar(100) comment '密保1',
	mb2 varchar(100) comment '密保2',
	mb3 varchar(100) comment '密保3',
	sj1 varchar(100) comment '',
	sj2 varchar(100) comment '',
	sj3 varchar(100) comment ''
) comment '用户';

留言表创建语句如下:


create table t_liuyan(
	id int primary key auto_increment comment '主键',
	customerId int comment '发起人',
	toId int comment '回复人',
	content varchar(100) comment '发起内容',
	insertDate datetime comment '发起日期',
	back varchar(100) comment '回复内容',
	backDate datetime comment '回复时间',
	status varchar(100) comment '状态'
) comment '留言';

相册表创建语句如下:


create table t_xc(
	id int primary key auto_increment comment '主键',
	customerId int comment '用户',
	title varchar(100) comment '标题',
	remark varchar(100) comment '备注',
	xcPic varchar(100) comment '100'
) comment '相册';

照片表创建语句如下:


create table t_zp(
	id int primary key auto_increment comment '主键',
	xcId int comment '相册',
	title varchar(100) comment '标题',
	pic varchar(100) comment '图片',
	remark varchar(100) comment '备注'
) comment '照片';

网络相册oracle数据库版本源码:

超级管理员表创建语句如下:


create table t_admin(
	id integer,
	username varchar(100),
	password varchar(100)
);
insert into t_admin(id,username,password) values(1,'admin','123456');
--超级管理员字段加注释
comment on column t_admin.id is '主键';
comment on column t_admin.username is '超级管理员账号';
comment on column t_admin.password is '超级管理员密码';
--超级管理员表加注释
comment on table t_admin is '超级管理员';

用户表创建语句如下:


create table t_customer(
	id integer,
	username varchar(100),
	password varchar(100),
	name varchar(100),
	phone varchar(100),
	sex varchar(100),
	age varchar(100),
	address varchar(100),
	idcard varchar(100),
	insertDate datetime,
	headPic varchar(100),
	level varchar(100),
	isft varchar(100),
	ispl varchar(100),
	mb1 varchar(100),
	mb2 varchar(100),
	mb3 varchar(100),
	sj1 varchar(100),
	sj2 varchar(100),
	sj3 varchar(100)
);
--用户字段加注释
comment on column t_customer.id is '主键';
comment on column t_customer.username is '账号';
comment on column t_customer.password is '密码';
comment on column t_customer.name is '姓名';
comment on column t_customer.phone is '手机';
comment on column t_customer.sex is '性别';
comment on column t_customer.age is '年龄';
comment on column t_customer.address is '地点';
comment on column t_customer.idcard is '工作方向';
comment on column t_customer.insertDate is '入库日期';
comment on column t_customer.headPic is '头像';
comment on column t_customer.level is '层级';
comment on column t_customer.isft is '发帖权限';
comment on column t_customer.ispl is '评论权限';
comment on column t_customer.mb1 is '密保1';
comment on column t_customer.mb2 is '密保2';
comment on column t_customer.mb3 is '密保3';
comment on column t_customer.sj1 is '';
comment on column t_customer.sj2 is '';
comment on column t_customer.sj3 is '';
--用户表加注释
comment on table t_customer is '用户';

留言表创建语句如下:


create table t_liuyan(
	id integer,
	customerId int,
	toId int,
	content varchar(100),
	insertDate datetime,
	back varchar(100),
	backDate datetime,
	status varchar(100)
);
--留言字段加注释
comment on column t_liuyan.id is '主键';
comment on column t_liuyan.customerId is '发起人';
comment on column t_liuyan.toId is '回复人';
comment on column t_liuyan.content is '发起内容';
comment on column t_liuyan.insertDate is '发起日期';
comment on column t_liuyan.back is '回复内容';
comment on column t_liuyan.backDate is '回复时间';
comment on column t_liuyan.status is '状态';
--留言表加注释
comment on table t_liuyan is '留言';

相册表创建语句如下:


create table t_xc(
	id integer,
	customerId int,
	title varchar(100),
	remark varchar(100),
	xcPic varchar(100)
);
--相册字段加注释
comment on column t_xc.id is '主键';
comment on column t_xc.customerId is '用户';
comment on column t_xc.title is '标题';
comment on column t_xc.remark is '备注';
comment on column t_xc.xcPic is '100';
--相册表加注释
comment on table t_xc is '相册';

照片表创建语句如下:


create table t_zp(
	id integer,
	xcId int,
	title varchar(100),
	pic varchar(100),
	remark varchar(100)
);
--照片字段加注释
comment on column t_zp.id is '主键';
comment on column t_zp.xcId is '相册';
comment on column t_zp.title is '标题';
comment on column t_zp.pic is '图片';
comment on column t_zp.remark is '备注';
--照片表加注释
comment on table t_zp is '照片';

oracle特有,对应序列如下:


create sequence s_t_customer;
create sequence s_t_liuyan;
create sequence s_t_xc;
create sequence s_t_zp;

网络相册sqlserver数据库版本源码:

超级管理员表创建语句如下:


--超级管理员
create table t_admin(
	id int identity(1,1) primary key not null,--主键
	username varchar(100),--超级管理员账号
	password varchar(100)--超级管理员密码
);
insert into t_admin(username,password) values('admin','123456');

用户表创建语句如下:


--用户表注释
create table t_customer(
	id int identity(1,1) primary key not null,--主键
	username varchar(100),--账号
	password varchar(100),--密码
	name varchar(100),--姓名
	phone varchar(100),--手机
	sex varchar(100),--性别
	age varchar(100),--年龄
	address varchar(100),--地点
	idcard varchar(100),--工作方向
	insertDate datetime,--入库日期
	headPic varchar(100),--头像
	level varchar(100),--层级
	isft varchar(100),--发帖权限
	ispl varchar(100),--评论权限
	mb1 varchar(100),--密保1
	mb2 varchar(100),--密保2
	mb3 varchar(100),--密保3
	sj1 varchar(100),--
	sj2 varchar(100),--
	sj3 varchar(100)--
);

留言表创建语句如下:


--留言表注释
create table t_liuyan(
	id int identity(1,1) primary key not null,--主键
	customerId int,--发起人
	toId int,--回复人
	content varchar(100),--发起内容
	insertDate datetime,--发起日期
	back varchar(100),--回复内容
	backDate datetime,--回复时间
	status varchar(100)--状态
);

相册表创建语句如下:


--相册表注释
create table t_xc(
	id int identity(1,1) primary key not null,--主键
	customerId int,--用户
	title varchar(100),--标题
	remark varchar(100),--备注
	xcPic varchar(100)--100
);

照片表创建语句如下:


--照片表注释
create table t_zp(
	id int identity(1,1) primary key not null,--主键
	xcId int,--相册
	title varchar(100),--标题
	pic varchar(100),--图片
	remark varchar(100)--备注
);

网络相册登录后主页

网络相册spring+springMVC+hibernate框架对象(javaBean,pojo)设计:

用户javaBean创建语句如下:


package project.model;
import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.GenerationType;
import javax.persistence.Id;
import javax.persistence.Table;
import java.util.Date;
@Entity

//用户
@Table(name = "t_customer")
public class Customer {
//主键
@Id
@Column(name = "id")
@GeneratedValue(strategy = GenerationType.IDENTITY)
private Integer id;
public Integer getId() {return id;}
public void setId(Integer id) {this.id = id;}
//账号
private String username;
//密码
private String password;
//姓名
private String name;
//手机
private String phone;
//性别
private String sex;
//年龄
private String age;
//地点
private String address;
//工作方向
private String idcard;
//入库日期
private Date insertDate;
//头像
private String headPic;
//层级
private String level;
//发帖权限
private String isft;
//评论权限
private String ispl;
//密保1
private String mb1;
//密保2
private String mb2;
//密保3
private String mb3;
//
private String sj1;
//
private String sj2;
//
private String sj3;
public String getUsername() {return username;}
public void setUsername(String username) {this.username = username;}
public String getPassword() {return password;}
public void setPassword(String password) {this.password = password;}
public String getName() {return name;}
public void setName(String name) {this.name = name;}
public String getPhone() {return phone;}
public void setPhone(String phone) {this.phone = phone;}
public String getSex() {return sex;}
public void setSex(String sex) {this.sex = sex;}
public String getAge() {return age;}
public void setAge(String age) {this.age = age;}
public String getAddress() {return address;}
public void setAddress(String address) {this.address = address;}
public String getIdcard() {return idcard;}
public void setIdcard(String idcard) {this.idcard = idcard;}
public Date getInsertDate() {return insertDate;}
public void setInsertDate(Date insertDate) {this.insertDate = insertDate;}
public String getHeadPic() {return headPic;}
public void setHeadPic(String headPic) {this.headPic = headPic;}
public String getLevel() {return level;}
public void setLevel(String level) {this.level = level;}
public String getIsft() {return isft;}
public void setIsft(String isft) {this.isft = isft;}
public String getIspl() {return ispl;}
public void setIspl(String ispl) {this.ispl = ispl;}
public String getMb1() {return mb1;}
public void setMb1(String mb1) {this.mb1 = mb1;}
public String getMb2() {return mb2;}
public void setMb2(String mb2) {this.mb2 = mb2;}
public String getMb3() {return mb3;}
public void setMb3(String mb3) {this.mb3 = mb3;}
public String getSj1() {return sj1;}
public void setSj1(String sj1) {this.sj1 = sj1;}
public String getSj2() {return sj2;}
public void setSj2(String sj2) {this.sj2 = sj2;}
public String getSj3() {return sj3;}
public void setSj3(String sj3) {this.sj3 = sj3;}
}

留言javaBean创建语句如下:


package project.model;
import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.GenerationType;
import javax.persistence.Id;
import javax.persistence.Table;
import java.util.Date;
@Entity

//留言
@Table(name = "t_liuyan")
public class Liuyan {
//主键
@Id
@Column(name = "id")
@GeneratedValue(strategy = GenerationType.IDENTITY)
private Integer id;
public Integer getId() {return id;}
public void setId(Integer id) {this.id = id;}
//发起人
private Integer customerId;
//回复人
private Integer toId;
//发起内容
private String content;
//发起日期
private Date insertDate;
//回复内容
private String back;
//回复时间
private Date backDate;
//状态
private String status;
public Integer getCustomerId() {return customerId;}
public void setCustomerId(Integer customerId) {this.customerId = customerId;}
public Integer getToId() {return toId;}
public void setToId(Integer toId) {this.toId = toId;}
public String getContent() {return content;}
public void setContent(String content) {this.content = content;}
public Date getInsertDate() {return insertDate;}
public void setInsertDate(Date insertDate) {this.insertDate = insertDate;}
public String getBack() {return back;}
public void setBack(String back) {this.back = back;}
public Date getBackDate() {return backDate;}
public void setBackDate(Date backDate) {this.backDate = backDate;}
public String getStatus() {return status;}
public void setStatus(String status) {this.status = status;}
}

相册javaBean创建语句如下:


package project.model;
import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.GenerationType;
import javax.persistence.Id;
import javax.persistence.Table;
import java.util.Date;
@Entity

//相册
@Table(name = "t_xc")
public class Xc {
//主键
@Id
@Column(name = "id")
@GeneratedValue(strategy = GenerationType.IDENTITY)
private Integer id;
public Integer getId() {return id;}
public void setId(Integer id) {this.id = id;}
//用户
private Integer customerId;
//标题
private String title;
//备注
private String remark;
//100
private String xcPic;
public Integer getCustomerId() {return customerId;}
public void setCustomerId(Integer customerId) {this.customerId = customerId;}
public String getTitle() {return title;}
public void setTitle(String title) {this.title = title;}
public String getRemark() {return remark;}
public void setRemark(String remark) {this.remark = remark;}
public String getXcPic() {return xcPic;}
public void setXcPic(String xcPic) {this.xcPic = xcPic;}
}

照片javaBean创建语句如下:


package project.model;
import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.GenerationType;
import javax.persistence.Id;
import javax.persistence.Table;
import java.util.Date;
@Entity

//照片
@Table(name = "t_zp")
public class Zp {
//主键
@Id
@Column(name = "id")
@GeneratedValue(strategy = GenerationType.IDENTITY)
private Integer id;
public Integer getId() {return id;}
public void setId(Integer id) {this.id = id;}
//相册
private Integer xcId;
//标题
private String title;
//图片
private String pic;
//备注
private String remark;
public Integer getXcId() {return xcId;}
public void setXcId(Integer xcId) {this.xcId = xcId;}
public String getTitle() {return title;}
public void setTitle(String title) {this.title = title;}
public String getPic() {return pic;}
public void setPic(String pic) {this.pic = pic;}
public String getRemark() {return remark;}
public void setRemark(String remark) {this.remark = remark;}
}

网络相册spring+springMVC+mybatis框架对象(javaBean,pojo)设计:

用户javaBean创建语句如下:


package project.model;
import org.springframework.format.annotation.DateTimeFormat;
import java.util.Date;

//用户
public class Customer  extends BaseBean{
//主键
private Integer id;
public Integer getId() {return id;}
public void setId(Integer id) {this.id = id;}
//账号
private String username;
//密码
private String password;
//姓名
private String name;
//手机
private String phone;
//性别
private String sex;
//年龄
private String age;
//地点
private String address;
//工作方向
private String idcard;
//入库日期
private Date insertDate;
//头像
private String headPic;
//层级
private String level;
//发帖权限
private String isft;
//评论权限
private String ispl;
//密保1
private String mb1;
//密保2
private String mb2;
//密保3
private String mb3;
//
private String sj1;
//
private String sj2;
//
private String sj3;
public String getUsername() {return username;}
public void setUsername(String username) {this.username = username;}
public String getPassword() {return password;}
public void setPassword(String password) {this.password = password;}
public String getName() {return name;}
public void setName(String name) {this.name = name;}
public String getPhone() {return phone;}
public void setPhone(String phone) {this.phone = phone;}
public String getSex() {return sex;}
public void setSex(String sex) {this.sex = sex;}
public String getAge() {return age;}
public void setAge(String age) {this.age = age;}
public String getAddress() {return address;}
public void setAddress(String address) {this.address = address;}
public String getIdcard() {return idcard;}
public void setIdcard(String idcard) {this.idcard = idcard;}
public Date getInsertDate() {return insertDate;}
public void setInsertDate(Date insertDate) {this.insertDate = insertDate;}
public String getHeadPic() {return headPic;}
public void setHeadPic(String headPic) {this.headPic = headPic;}
public String getLevel() {return level;}
public void setLevel(String level) {this.level = level;}
public String getIsft() {return isft;}
public void setIsft(String isft) {this.isft = isft;}
public String getIspl() {return ispl;}
public void setIspl(String ispl) {this.ispl = ispl;}
public String getMb1() {return mb1;}
public void setMb1(String mb1) {this.mb1 = mb1;}
public String getMb2() {return mb2;}
public void setMb2(String mb2) {this.mb2 = mb2;}
public String getMb3() {return mb3;}
public void setMb3(String mb3) {this.mb3 = mb3;}
public String getSj1() {return sj1;}
public void setSj1(String sj1) {this.sj1 = sj1;}
public String getSj2() {return sj2;}
public void setSj2(String sj2) {this.sj2 = sj2;}
public String getSj3() {return sj3;}
public void setSj3(String sj3) {this.sj3 = sj3;}
}

留言javaBean创建语句如下:


package project.model;
import org.springframework.format.annotation.DateTimeFormat;
import java.util.Date;

//留言
public class Liuyan  extends BaseBean{
//主键
private Integer id;
public Integer getId() {return id;}
public void setId(Integer id) {this.id = id;}
//发起人
private Integer customerId;
//回复人
private Integer toId;
//发起内容
private String content;
//发起日期
private Date insertDate;
//回复内容
private String back;
//回复时间
private Date backDate;
//状态
private String status;
public Integer getCustomerId() {return customerId;}
public void setCustomerId(Integer customerId) {this.customerId = customerId;}
public Integer getToId() {return toId;}
public void setToId(Integer toId) {this.toId = toId;}
public String getContent() {return content;}
public void setContent(String content) {this.content = content;}
public Date getInsertDate() {return insertDate;}
public void setInsertDate(Date insertDate) {this.insertDate = insertDate;}
public String getBack() {return back;}
public void setBack(String back) {this.back = back;}
public Date getBackDate() {return backDate;}
public void setBackDate(Date backDate) {this.backDate = backDate;}
public String getStatus() {return status;}
public void setStatus(String status) {this.status = status;}
}

相册javaBean创建语句如下:


package project.model;
import org.springframework.format.annotation.DateTimeFormat;
import java.util.Date;

//相册
public class Xc  extends BaseBean{
//主键
private Integer id;
public Integer getId() {return id;}
public void setId(Integer id) {this.id = id;}
//用户
private Integer customerId;
//标题
private String title;
//备注
private String remark;
//100
private String xcPic;
public Integer getCustomerId() {return customerId;}
public void setCustomerId(Integer customerId) {this.customerId = customerId;}
public String getTitle() {return title;}
public void setTitle(String title) {this.title = title;}
public String getRemark() {return remark;}
public void setRemark(String remark) {this.remark = remark;}
public String getXcPic() {return xcPic;}
public void setXcPic(String xcPic) {this.xcPic = xcPic;}
}

照片javaBean创建语句如下:


package project.model;
import org.springframework.format.annotation.DateTimeFormat;
import java.util.Date;

//照片
public class Zp  extends BaseBean{
//主键
private Integer id;
public Integer getId() {return id;}
public void setId(Integer id) {this.id = id;}
//相册
private Integer xcId;
//标题
private String title;
//图片
private String pic;
//备注
private String remark;
public Integer getXcId() {return xcId;}
public void setXcId(Integer xcId) {this.xcId = xcId;}
public String getTitle() {return title;}
public void setTitle(String title) {this.title = title;}
public String getPic() {return pic;}
public void setPic(String pic) {this.pic = pic;}
public String getRemark() {return remark;}
public void setRemark(String remark) {this.remark = remark;}
}

源代码下载点这里

评论