项目设计和框架搭建

在mac环境下使用的数据库连接软件:Sequel Pro.
mysql数据库默认的编码:utf8;
InnoDB:支持事务,行级锁;写的性能好
MYISAM:支持表级锁,读的性能高;

use o2o;
create table 'tb_area'(
  'area_id' int(2) NOT NULL AUTO_INCREMNET,
'area_name' varchar(200) NOT NULL,
'privority' int(2) NOT NULL DEFAULT '0',
'create_time' datetime DEFAULT NULL,
'last_edit_time' datetime DEFAULT NULL,
primary key ('area_id'),
unique key 'UK_AREA'('area_name'),
)ENGINE=InnoDB AUTO_INCREAMENT=1 DEFALUT CHARSET=utf8;
use o2o;
create table 'tb_wechat_auth'(
'wechat_auth_id' int(10) NOT NULL AUTO_INCREMENT,
'user_id' int(10) NOT NULL,
'open_id' varchar(1024) NOT NULL,
'create_time' datetime DEFAULT NULL,
primary key('wechat_auth_id'),
constraint 'fk_wechatauth_profile' foreign key('user_id') references 'tb_person_info'('user_id')
)ENGINE=InnoDB AUTO_INCREMENT=1 DEFAULT CHARSET=utf8;
增加唯一索引
alter table tb_wechat_auth add unique index(open_id);

头条实体类

店铺类别

public class ShopCategory{
    private Long shopCategoryId;
    private String shopCategoryName;
    private String shopCategoryDesc;
    private String shopCategoryImg;
    private Integer priority;
    private Date createTime;
    private Date lastEditTime;
    private ShopCategory parent;
}

©著作权归作者所有,转载或内容合作请联系作者
【社区内容提示】社区部分内容疑似由AI辅助生成,浏览时请结合常识与多方信息审慎甄别。
平台声明:文章内容(如有图片或视频亦包括在内)由作者上传并发布,文章内容仅代表作者本人观点,简书系信息发布平台,仅提供信息存储服务。

相关阅读更多精彩内容

友情链接更多精彩内容