添加两新组织建表SQL
This commit is contained in:
parent
e0a694ac2b
commit
2f6ba96579
@ -7,6 +7,7 @@ import ink.wgink.exceptions.UpdateException;
|
||||
import cn.com.tenlion.usercenter.pojo.bos.enterprise.EnterpriseBO;
|
||||
import cn.com.tenlion.usercenter.pojo.pos.enterprise.EnterprisePO;
|
||||
import cn.com.tenlion.usercenter.pojo.dtos.enterprise.EnterpriseDTO;
|
||||
import ink.wgink.interfaces.init.IInitBaseTable;
|
||||
import org.springframework.stereotype.Repository;
|
||||
|
||||
import java.util.List;
|
||||
@ -20,7 +21,7 @@ import java.util.Map;
|
||||
* @Version: 3.0
|
||||
**/
|
||||
@Repository
|
||||
public interface IEnterpriseDao {
|
||||
public interface IEnterpriseDao extends IInitBaseTable {
|
||||
|
||||
/**
|
||||
* 新增非公有制经济组织
|
||||
|
@ -7,6 +7,7 @@ import ink.wgink.exceptions.UpdateException;
|
||||
import cn.com.tenlion.usercenter.pojo.bos.enterprisegridmember.EnterpriseGridMemberBO;
|
||||
import cn.com.tenlion.usercenter.pojo.pos.enterprisegridmember.EnterpriseGridMemberPO;
|
||||
import cn.com.tenlion.usercenter.pojo.dtos.enterprisegridmember.EnterpriseGridMemberDTO;
|
||||
import ink.wgink.interfaces.init.IInitBaseTable;
|
||||
import org.springframework.stereotype.Repository;
|
||||
|
||||
import java.util.List;
|
||||
@ -20,7 +21,7 @@ import java.util.Map;
|
||||
* @Version: 3.0
|
||||
**/
|
||||
@Repository
|
||||
public interface IEnterpriseGridMemberDao {
|
||||
public interface IEnterpriseGridMemberDao extends IInitBaseTable {
|
||||
|
||||
/**
|
||||
* 新增企业网格员
|
||||
|
@ -7,6 +7,7 @@ import ink.wgink.exceptions.UpdateException;
|
||||
import cn.com.tenlion.usercenter.pojo.bos.organization.OrganizationBO;
|
||||
import cn.com.tenlion.usercenter.pojo.pos.organization.OrganizationPO;
|
||||
import cn.com.tenlion.usercenter.pojo.dtos.organization.OrganizationDTO;
|
||||
import ink.wgink.interfaces.init.IInitBaseTable;
|
||||
import org.springframework.stereotype.Repository;
|
||||
|
||||
import java.util.List;
|
||||
@ -20,7 +21,7 @@ import java.util.Map;
|
||||
* @Version: 3.0
|
||||
**/
|
||||
@Repository
|
||||
public interface IOrganizationDao {
|
||||
public interface IOrganizationDao extends IInitBaseTable {
|
||||
|
||||
/**
|
||||
* 新增社会组织
|
||||
|
@ -7,6 +7,7 @@ import ink.wgink.exceptions.UpdateException;
|
||||
import cn.com.tenlion.usercenter.pojo.bos.organizationgridmember.OrganizationGridMemberBO;
|
||||
import cn.com.tenlion.usercenter.pojo.pos.organizationgridmember.OrganizationGridMemberPO;
|
||||
import cn.com.tenlion.usercenter.pojo.dtos.organizationgridmember.OrganizationGridMemberDTO;
|
||||
import ink.wgink.interfaces.init.IInitBaseTable;
|
||||
import org.springframework.stereotype.Repository;
|
||||
|
||||
import java.util.List;
|
||||
@ -20,7 +21,7 @@ import java.util.Map;
|
||||
* @Version: 3.0
|
||||
**/
|
||||
@Repository
|
||||
public interface IOrganizationGridMemberDao {
|
||||
public interface IOrganizationGridMemberDao extends IInitBaseTable {
|
||||
|
||||
/**
|
||||
* 新增社会组织网格员
|
||||
|
@ -25,6 +25,21 @@
|
||||
<result column="creator" property="creator"/>
|
||||
</resultMap>
|
||||
|
||||
<!-- 建表 -->
|
||||
<update id="createTable">
|
||||
CREATE TABLE IF NOT EXISTS `org_enterprise_grid_member` (
|
||||
`id` bigint(20) unsigned NOT NULL AUTO_INCREMENT,
|
||||
`enterprise_grid_member_id` char(36) DEFAULT NULL COMMENT '企业网格员ID',
|
||||
`enterprise_id` char(36) DEFAULT NULL COMMENT '企业ID',
|
||||
`user_id` char(36) DEFAULT NULL COMMENT '用户ID',
|
||||
`gmt_create` datetime DEFAULT NULL COMMENT '创建时间',
|
||||
`creator` char(36) DEFAULT NULL COMMENT '创建人',
|
||||
PRIMARY KEY (`id`),
|
||||
KEY `enterprise_id` (`enterprise_id`),
|
||||
KEY `user_id` (`user_id`)
|
||||
) ENGINE=InnoDB AUTO_INCREMENT=3 DEFAULT CHARSET=utf8 COMMENT='企业网格员';
|
||||
</update>
|
||||
|
||||
<!-- 新增企业网格员 -->
|
||||
<insert id="save" parameterType="map">
|
||||
INSERT INTO org_enterprise_grid_member(
|
||||
|
@ -169,6 +169,72 @@
|
||||
<result column="is_delete" property="isDelete"/>
|
||||
</resultMap>
|
||||
|
||||
<!-- 建表 -->
|
||||
<update id="createTable">
|
||||
CREATE TABLE IF NOT EXISTS `org_enterprise` (
|
||||
`id` bigint(20) unsigned NOT NULL AUTO_INCREMENT,
|
||||
`enterprise_id` char(36) DEFAULT NULL COMMENT '主键',
|
||||
`enterprise_name` varchar(255) DEFAULT NULL COMMENT '名称',
|
||||
`enterprise_type_id` char(36) DEFAULT NULL COMMENT '类型ID',
|
||||
`enterprise_type_name` varchar(255) DEFAULT NULL COMMENT '类型名称',
|
||||
`enterprise_address` varchar(255) DEFAULT NULL COMMENT '地址',
|
||||
`enterprise_tel` varchar(255) DEFAULT NULL COMMENT '联系方式',
|
||||
`business_reg_no` varchar(255) DEFAULT NULL COMMENT '组织机构代码',
|
||||
`business_license` varchar(255) DEFAULT NULL COMMENT '营业执照',
|
||||
`business_license_start_date` varchar(10) DEFAULT NULL COMMENT '营业执照开始时间',
|
||||
`business_license_end_date` varchar(10) DEFAULT NULL COMMENT '营业执照结束时间',
|
||||
`total_person` int(11) DEFAULT NULL COMMENT '员工数',
|
||||
`legal_person_id_card_code` char(36) DEFAULT NULL COMMENT '法人证件代码',
|
||||
`legal_person_id_card_code_name` varchar(255) DEFAULT NULL COMMENT '法人证件代码名称',
|
||||
`legal_person_id_card` varchar(255) DEFAULT NULL COMMENT '法人证件号码',
|
||||
`legal_person_name` varchar(255) DEFAULT NULL COMMENT '法人姓名',
|
||||
`legal_person_phone` varchar(255) DEFAULT NULL COMMENT '法人联系方式',
|
||||
`legal_person_id_card_front` varchar(255) DEFAULT NULL COMMENT '法人证件正面',
|
||||
`legal_person_id_card_back` varchar(255) DEFAULT NULL COMMENT '法人证件背面',
|
||||
`security_person_name` varchar(255) DEFAULT NULL COMMENT '治保负责人姓名',
|
||||
`security_person_phone` varchar(255) DEFAULT NULL COMMENT '治保负责人联系方式',
|
||||
`master_name` varchar(255) DEFAULT NULL COMMENT '负责人姓名',
|
||||
`master_phone` varchar(255) DEFAULT NULL COMMENT '负责人联系方式',
|
||||
`master_id_card` varchar(255) DEFAULT NULL COMMENT '负责人身份证号码',
|
||||
`master_id_card_front` varchar(255) DEFAULT NULL COMMENT '负责人身份证正面',
|
||||
`master_id_card_back` varchar(255) DEFAULT NULL COMMENT '负责人身份证背面',
|
||||
`is_danger` int(1) DEFAULT '0' COMMENT '是否危化企业',
|
||||
`hidden_danger_type_id` char(36) DEFAULT NULL COMMENT '安全隐患类型ID',
|
||||
`hidden_danger_type_name` varchar(255) DEFAULT NULL COMMENT '安全隐患类型名称',
|
||||
`degree_of_concern_id` char(36) DEFAULT NULL COMMENT '关注度ID',
|
||||
`degree_of_concern_name` varchar(255) DEFAULT NULL COMMENT '关注度名称',
|
||||
`can_establish_party_org` int(1) DEFAULT '0' COMMENT '是否具备建立中共党组织条件',
|
||||
`has_party_org` int(1) DEFAULT '0' COMMENT '是否有党组织',
|
||||
`party_org_total_person` int(11) DEFAULT NULL COMMENT '中共党员数量',
|
||||
`has_labour_union` int(1) DEFAULT '0' COMMENT '是否有工会',
|
||||
`labour_union_total_person` int(11) DEFAULT NULL COMMENT '工会会员数量',
|
||||
`has_communist_youth_league` int(1) DEFAULT '0' COMMENT '是否有共青团',
|
||||
`communist_youth_league_total_person` int(11) DEFAULT NULL COMMENT '共青团团员数量',
|
||||
`has_women_federation` int(1) DEFAULT '0' COMMENT '是否有妇联',
|
||||
`women_total_person` int(11) DEFAULT NULL COMMENT '妇女数量',
|
||||
`enterprise_lng` varchar(255) DEFAULT NULL COMMENT '企业经度',
|
||||
`enterprise_lat` varchar(255) DEFAULT NULL COMMENT '企业纬度',
|
||||
`area_code` varchar(255) DEFAULT NULL COMMENT '地区编码',
|
||||
`area_name` varchar(255) DEFAULT NULL COMMENT '地区名称',
|
||||
`grid_code` varchar(255) DEFAULT NULL COMMENT '网格编码',
|
||||
`grid_name` varchar(255) DEFAULT NULL COMMENT '网格名称',
|
||||
`is_log_off` int(1) DEFAULT '0' COMMENT '是否注销',
|
||||
`remarks` varchar(255) DEFAULT NULL COMMENT '备注',
|
||||
`facade_photos` varchar(255) DEFAULT NULL COMMENT '门面照片',
|
||||
`workplace_photos` varchar(255) DEFAULT NULL COMMENT '工作场所照片',
|
||||
`gmt_create` datetime DEFAULT NULL COMMENT '创建时间',
|
||||
`creator` char(36) DEFAULT NULL COMMENT '创建人',
|
||||
`gmt_modified` datetime DEFAULT NULL COMMENT '修改时间',
|
||||
`modifier` char(36) DEFAULT NULL COMMENT '修改人',
|
||||
`is_delete` int(1) DEFAULT '0' COMMENT '是否删除',
|
||||
PRIMARY KEY (`id`),
|
||||
UNIQUE KEY `enterprise_id` (`enterprise_id`),
|
||||
UNIQUE KEY `business_reg_no` (`business_reg_no`),
|
||||
KEY `area_code` (`area_code`),
|
||||
KEY `grid_code` (`grid_code`)
|
||||
) ENGINE=InnoDB AUTO_INCREMENT=9 DEFAULT CHARSET=utf8 COMMENT='非公有制经济组织';
|
||||
</update>
|
||||
|
||||
<!-- 新增非公有制经济组织 -->
|
||||
<insert id="save" parameterType="map">
|
||||
INSERT INTO org_enterprise(
|
||||
|
@ -26,6 +26,21 @@
|
||||
<result column="creator" property="creator"/>
|
||||
</resultMap>
|
||||
|
||||
<!-- 建表 -->
|
||||
<update id="createTable">
|
||||
CREATE TABLE IF NOT EXISTS `org_organization_grid_member` (
|
||||
`id` bigint(20) unsigned NOT NULL AUTO_INCREMENT,
|
||||
`organization_grid_member_id` char(36) DEFAULT NULL COMMENT '社会组织网格员ID',
|
||||
`organization_id` char(36) DEFAULT NULL COMMENT '社会组织ID',
|
||||
`user_id` char(36) DEFAULT NULL COMMENT '用户ID',
|
||||
`gmt_create` datetime DEFAULT NULL COMMENT '创建时间',
|
||||
`creator` char(36) DEFAULT NULL COMMENT '创建人',
|
||||
PRIMARY KEY (`id`),
|
||||
KEY `organization_id` (`organization_id`),
|
||||
KEY `user_id` (`user_id`)
|
||||
) ENGINE=InnoDB AUTO_INCREMENT=3 DEFAULT CHARSET=utf8 COMMENT='社会组织网格员';
|
||||
</update>
|
||||
|
||||
<!-- 新增社会组织网格员 -->
|
||||
<insert id="save" parameterType="map">
|
||||
INSERT INTO org_organization_grid_member(
|
||||
|
@ -163,6 +163,70 @@
|
||||
<result column="is_delete" property="isDelete"/>
|
||||
</resultMap>
|
||||
|
||||
<!-- 建表 -->
|
||||
<update id="createTable">
|
||||
CREATE TABLE IF NOT EXISTS `org_organization` (
|
||||
`id` bigint(20) unsigned NOT NULL AUTO_INCREMENT,
|
||||
`organization_id` char(36) DEFAULT NULL COMMENT '主键',
|
||||
`organization_name` varchar(255) DEFAULT NULL COMMENT '组织名称',
|
||||
`organization_type_id` char(36) DEFAULT NULL COMMENT '组织类型ID',
|
||||
`organization_type_name` varchar(255) DEFAULT NULL COMMENT '组织类型名称',
|
||||
`organization_status` int(1) DEFAULT NULL COMMENT '组织状态',
|
||||
`organization_summary` text COMMENT '组织简介',
|
||||
`business_reg_no` varchar(255) DEFAULT NULL COMMENT '统一社会信用代码',
|
||||
`business_license` varchar(255) DEFAULT NULL COMMENT '营业执照',
|
||||
`business_license_start_date` varchar(10) DEFAULT NULL COMMENT '营业执照开始时间',
|
||||
`business_license_end_date` varchar(10) DEFAULT NULL COMMENT '营业执照结束时间',
|
||||
`registration_no` varchar(255) DEFAULT NULL COMMENT '登记证号',
|
||||
`registration_authority_no` varchar(255) DEFAULT NULL COMMENT '登记管理机关代码',
|
||||
`legal_person_name` varchar(255) DEFAULT NULL COMMENT '法人姓名',
|
||||
`residence` varchar(255) DEFAULT NULL COMMENT '住所',
|
||||
`approval_date` varchar(10) DEFAULT NULL COMMENT '批准日期',
|
||||
`master_name` varchar(255) DEFAULT NULL COMMENT '负责人姓名',
|
||||
`master_phone` varchar(255) DEFAULT NULL COMMENT '负责人联系方式',
|
||||
`master_id_card_code` char(36) DEFAULT NULL COMMENT '负责人证件代码',
|
||||
`master_id_card_code_name` varchar(255) DEFAULT NULL COMMENT '负责人证件代码名称',
|
||||
`master_id_card` varchar(255) DEFAULT NULL COMMENT '负责人证件号码',
|
||||
`master_id_card_front` varchar(255) DEFAULT NULL COMMENT '负责人证件正面',
|
||||
`master_id_card_back` varchar(255) DEFAULT NULL COMMENT '负责人证件背面',
|
||||
`office_address` varchar(255) DEFAULT NULL COMMENT '办公地址',
|
||||
`security_person_name` varchar(255) DEFAULT NULL COMMENT '治保负责人姓名',
|
||||
`security_person_phone` varchar(255) DEFAULT NULL COMMENT '治保负责人联系方式',
|
||||
`degree_of_concern_id` char(36) DEFAULT NULL COMMENT '关注度ID',
|
||||
`degree_of_concern_name` varchar(255) DEFAULT NULL COMMENT '关注度名称',
|
||||
`can_establish_party_org` int(1) DEFAULT '0' COMMENT '是否具备建立中共党组织条件',
|
||||
`has_party_org` int(1) DEFAULT '0' COMMENT '是否有党组织',
|
||||
`party_org_total_person` int(11) DEFAULT NULL COMMENT '中共党员数量',
|
||||
`has_labour_union` int(1) DEFAULT '0' COMMENT '是否有工会',
|
||||
`labour_union_total_person` int(11) DEFAULT NULL COMMENT '工会会员数量',
|
||||
`has_communist_youth_league` int(1) DEFAULT '0' COMMENT '是否有共青团',
|
||||
`communist_youth_league_total_person` int(11) DEFAULT NULL COMMENT '共青团团员数量',
|
||||
`has_women_federation` int(1) DEFAULT '0' COMMENT '是否有妇联',
|
||||
`women_total_person` int(11) DEFAULT NULL COMMENT '妇女数量',
|
||||
`source_of_funds` varchar(255) DEFAULT NULL COMMENT '资金来源',
|
||||
`has_overseas_background` int(1) DEFAULT '0' COMMENT '是否有境外背景',
|
||||
`organization_lng` varchar(255) DEFAULT NULL COMMENT '组织经度',
|
||||
`organization_lat` varchar(255) DEFAULT NULL COMMENT '组织维度',
|
||||
`area_code` varchar(255) DEFAULT NULL COMMENT '地区编码',
|
||||
`area_name` varchar(255) DEFAULT NULL COMMENT '地区名称',
|
||||
`grid_code` varchar(255) DEFAULT NULL COMMENT '网格编码',
|
||||
`grid_name` varchar(255) DEFAULT NULL COMMENT '网格名称',
|
||||
`remarks` varchar(255) DEFAULT NULL COMMENT '备注',
|
||||
`facade_photos` varchar(255) DEFAULT NULL COMMENT '门面照片',
|
||||
`workplace_photos` varchar(255) DEFAULT NULL COMMENT '工作场所照片',
|
||||
`gmt_create` datetime DEFAULT NULL COMMENT '创建时间',
|
||||
`creator` char(36) DEFAULT NULL COMMENT '创建人',
|
||||
`gmt_modified` datetime DEFAULT NULL COMMENT '修改时间',
|
||||
`modifier` char(36) DEFAULT NULL COMMENT '修改人',
|
||||
`is_delete` int(1) DEFAULT '0' COMMENT '是否删除',
|
||||
PRIMARY KEY (`id`),
|
||||
UNIQUE KEY `organization_id` (`organization_id`),
|
||||
UNIQUE KEY `bussiness_reg_no` (`business_reg_no`),
|
||||
KEY `area_code` (`area_code`),
|
||||
KEY `grid_code` (`grid_code`)
|
||||
) ENGINE=InnoDB AUTO_INCREMENT=4 DEFAULT CHARSET=utf8 COMMENT='社会组织';
|
||||
</update>
|
||||
|
||||
<!-- 新增社会组织 -->
|
||||
<insert id="save" parameterType="map">
|
||||
INSERT INTO org_organization(
|
||||
|
Loading…
Reference in New Issue
Block a user