From 2f6ba965793dc991662fad28e3650fde7e01a862 Mon Sep 17 00:00:00 2001
From: wanggeng <450292408@qq.com>
Date: Sat, 6 Nov 2021 17:41:31 +0800
Subject: [PATCH] =?UTF-8?q?=E6=B7=BB=E5=8A=A0=E4=B8=A4=E6=96=B0=E7=BB=84?=
=?UTF-8?q?=E7=BB=87=E5=BB=BA=E8=A1=A8SQL?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
.../dao/enterprise/IEnterpriseDao.java | 3 +-
.../IEnterpriseGridMemberDao.java | 3 +-
.../dao/organization/IOrganizationDao.java | 3 +-
.../IOrganizationGridMemberDao.java | 3 +-
.../enterprise-grid-member-mapper.xml | 15 +++++
.../mapper/enterprise/enterprise-mapper.xml | 66 +++++++++++++++++++
.../organization-grid-member-mapper.xml | 15 +++++
.../organization/organization-mapper.xml | 64 ++++++++++++++++++
8 files changed, 168 insertions(+), 4 deletions(-)
diff --git a/src/main/java/cn/com/tenlion/usercenter/dao/enterprise/IEnterpriseDao.java b/src/main/java/cn/com/tenlion/usercenter/dao/enterprise/IEnterpriseDao.java
index 6ac8137..9773411 100644
--- a/src/main/java/cn/com/tenlion/usercenter/dao/enterprise/IEnterpriseDao.java
+++ b/src/main/java/cn/com/tenlion/usercenter/dao/enterprise/IEnterpriseDao.java
@@ -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 {
/**
* 新增非公有制经济组织
diff --git a/src/main/java/cn/com/tenlion/usercenter/dao/enterprisegridmember/IEnterpriseGridMemberDao.java b/src/main/java/cn/com/tenlion/usercenter/dao/enterprisegridmember/IEnterpriseGridMemberDao.java
index dcb3030..f4d15b6 100644
--- a/src/main/java/cn/com/tenlion/usercenter/dao/enterprisegridmember/IEnterpriseGridMemberDao.java
+++ b/src/main/java/cn/com/tenlion/usercenter/dao/enterprisegridmember/IEnterpriseGridMemberDao.java
@@ -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 {
/**
* 新增企业网格员
diff --git a/src/main/java/cn/com/tenlion/usercenter/dao/organization/IOrganizationDao.java b/src/main/java/cn/com/tenlion/usercenter/dao/organization/IOrganizationDao.java
index ca6dbdc..8d6a6bd 100644
--- a/src/main/java/cn/com/tenlion/usercenter/dao/organization/IOrganizationDao.java
+++ b/src/main/java/cn/com/tenlion/usercenter/dao/organization/IOrganizationDao.java
@@ -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 {
/**
* 新增社会组织
diff --git a/src/main/java/cn/com/tenlion/usercenter/dao/organizationgridmember/IOrganizationGridMemberDao.java b/src/main/java/cn/com/tenlion/usercenter/dao/organizationgridmember/IOrganizationGridMemberDao.java
index a257dd5..db6331a 100644
--- a/src/main/java/cn/com/tenlion/usercenter/dao/organizationgridmember/IOrganizationGridMemberDao.java
+++ b/src/main/java/cn/com/tenlion/usercenter/dao/organizationgridmember/IOrganizationGridMemberDao.java
@@ -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 {
/**
* 新增社会组织网格员
diff --git a/src/main/resources/mybatis/mapper/enterprise-grid-member/enterprise-grid-member-mapper.xml b/src/main/resources/mybatis/mapper/enterprise-grid-member/enterprise-grid-member-mapper.xml
index d239d36..7554433 100644
--- a/src/main/resources/mybatis/mapper/enterprise-grid-member/enterprise-grid-member-mapper.xml
+++ b/src/main/resources/mybatis/mapper/enterprise-grid-member/enterprise-grid-member-mapper.xml
@@ -25,6 +25,21 @@
+
+
+ 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='企业网格员';
+
+
INSERT INTO org_enterprise_grid_member(
diff --git a/src/main/resources/mybatis/mapper/enterprise/enterprise-mapper.xml b/src/main/resources/mybatis/mapper/enterprise/enterprise-mapper.xml
index 53d8b84..c4dbfbc 100644
--- a/src/main/resources/mybatis/mapper/enterprise/enterprise-mapper.xml
+++ b/src/main/resources/mybatis/mapper/enterprise/enterprise-mapper.xml
@@ -169,6 +169,72 @@
+
+
+ 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='非公有制经济组织';
+
+
INSERT INTO org_enterprise(
diff --git a/src/main/resources/mybatis/mapper/organization-grid-member/organization-grid-member-mapper.xml b/src/main/resources/mybatis/mapper/organization-grid-member/organization-grid-member-mapper.xml
index bf6a920..3695e48 100644
--- a/src/main/resources/mybatis/mapper/organization-grid-member/organization-grid-member-mapper.xml
+++ b/src/main/resources/mybatis/mapper/organization-grid-member/organization-grid-member-mapper.xml
@@ -26,6 +26,21 @@
+
+
+ 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='社会组织网格员';
+
+
INSERT INTO org_organization_grid_member(
diff --git a/src/main/resources/mybatis/mapper/organization/organization-mapper.xml b/src/main/resources/mybatis/mapper/organization/organization-mapper.xml
index 7501a97..b243a18 100644
--- a/src/main/resources/mybatis/mapper/organization/organization-mapper.xml
+++ b/src/main/resources/mybatis/mapper/organization/organization-mapper.xml
@@ -163,6 +163,70 @@
+
+
+ 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='社会组织';
+
+
INSERT INTO org_organization(