-- 用户备份表
DROP TABLE IF EXISTS `AR_USER_ALL_TEMPLATE`;
CREATE TABLE AR_USER_ALL_TEMPLATE
(
  `ID` varchar(32) NOT NULL,
  `USER_NAME` varchar(16) NOT NULL,
  `NATION` tinyint(2) NOT NULL DEFAULT '0',
  `REAL_NAME` varchar(128) NOT NULL,
  `ID_CARD` varchar(18) NOT NULL,
  `ID_TYPE` tinyint(1) NOT NULL DEFAULT '0',
  `MOBILE` varchar(11) DEFAULT '',
  `ADDRESS` varchar(2000) DEFAULT '',
  `ID_IMAGE` varchar(255) DEFAULT '',
  `OPEN_BANK` varchar(32) DEFAULT '',
  `BANK_ADDRESS` varchar(255) DEFAULT '',
  `BANK_NO` varchar(32) DEFAULT '',
  `BANK_PROVINCE` int(6) DEFAULT '0',
  `BANK_CITY` int(6) DEFAULT '0',
  `BANK_COUNTY` int(6) DEFAULT '0',
  `SPOUSE_NAME` varchar(16) DEFAULT '',
  `SPOUSE_IDCARD` varchar(18) DEFAULT '',
  `CREATED_AT` int(10) NOT NULL DEFAULT '0',
  `UPDATED_AT` int(10) NOT NULL DEFAULT '0',
  `STATUS` tinyint(1) NOT NULL DEFAULT '1',
  `DEC_CLOSED` tinyint(1) NOT NULL DEFAULT '0',
  `DEC_CLOSED_AT` int(10) NOT NULL DEFAULT '0',
  `DEC_LV` varchar(32) DEFAULT '',
  `EMP_LV` varchar(32) DEFAULT '',
  `PROVINCE` int(6) NOT NULL DEFAULT '0',
  `CITY` int(6) NOT NULL DEFAULT '0',
  `COUNTY` int(6) NOT NULL DEFAULT '0',
  `TEL` varchar(16) DEFAULT '',
  `LOGIN_TIMES` int(10) NOT NULL DEFAULT '0',
  `LOGIN_IP` varchar(15) DEFAULT '',
  `LOGIN_AT` int(10) NOT NULL DEFAULT '0',
  `PULL_MESSAGE_AT` int(10) NOT NULL DEFAULT '0',
  `SUB_COM_ID` varchar(32) DEFAULT '',
  `AVATAR` varchar(255) NOT NULL,
  `DELETED` tinyint(1) NOT NULL DEFAULT '0',
  `DELETED_AT` int(10) NOT NULL DEFAULT '0',
  `ALLOW_TRANSFER` tinyint(1) NOT NULL DEFAULT '1',
  `TRANSFER_PROP` float(10,2) NOT NULL DEFAULT '0.00',
  `IS_DEC` tinyint(1) NOT NULL DEFAULT '0',
  `DEC_ID` varchar(32) NOT NULL DEFAULT '1',
  `BIRTHDAY` date DEFAULT '1990-09-09',
  `DEC_ROLE_ID` varchar(32) DEFAULT '',
  `PERIOD_AT` int(10) NOT NULL DEFAULT '0',
  `DEC_PROVINCE` int(6) NOT NULL DEFAULT '0',
  `DEC_CITY` int(6) NOT NULL DEFAULT '0',
  `DEC_COUNTY` int(6) NOT NULL DEFAULT '0',
  `IS_UNION` tinyint(1) NOT NULL DEFAULT '0',
  `STATUS_AT` int(10) NOT NULL DEFAULT '0',
  `VERIFIED` tinyint(1) NOT NULL DEFAULT '0',
  `VERIFIED_AT` int(10) NOT NULL DEFAULT '0',
  `ALLOW_LOGIN` tinyint(1) NOT NULL DEFAULT '1',
  `NOT_OPERATING` tinyint(1) NOT NULL DEFAULT '0',
  `REG_FROM` tinyint(1) NOT NULL DEFAULT '1',
  `ID_CARD_PREFIX` varchar(32) DEFAULT '',
  `ALLOW_BONUS_LOGIN` tinyint(1) NOT NULL DEFAULT '1',
  `SEX` varchar(32) DEFAULT '',
  `DEC_ACCOUNT_OLD` varchar(64) DEFAULT '',
  `BANK_UPDATED_AT` int(10) NOT NULL DEFAULT '0',
  `IS_DIRECT_SELLER` tinyint(1) NOT NULL DEFAULT '0',
  `DEC_LV_UPDATED_AT` int(10) NOT NULL DEFAULT '0',
  `DEC_LV_UPDATED_PERIOD` int(10) NOT NULL DEFAULT '0',
  `DEC_ADDRESS` varchar(2000) DEFAULT '',
  `DEC_PHONE` varchar(32) DEFAULT '',
  `GUARANTOR` varchar(32) DEFAULT '',
  `GUARANTOR_NAME` varchar(64) DEFAULT '',
  `PART_FUNC_CLOSED` tinyint(1) NOT NULL DEFAULT '0',
  `LAST_DEC_LV_UPDATED_PERIOD` int(10) NOT NULL DEFAULT '0',
  `USER_CREATOR` varchar(32) DEFAULT '',
  `USER_UPDATER` varchar(32) DEFAULT '',
  `LAST_DEC_LV_UPDATED_AT` int(10) NOT NULL DEFAULT '0',
  `DEC_CREATED_AT` int(10) NOT NULL DEFAULT '0',
  `PART_FUNC_CLOSED_REMARK` text,
  `DEC_CREATED_PERIOD` int(10) NOT NULL DEFAULT '0',
  `PASSWORD_CHANGED` tinyint(1) NOT NULL DEFAULT '0',
  `SUB_COM_LEADER` tinyint(1) NOT NULL DEFAULT '0',
  `LOGIN_FAIL_TIMES` int(10) NOT NULL DEFAULT '0',
  `ZG_UPGRADE_PV` decimal(16,2) NOT NULL DEFAULT '0.00',
  `APP_CLIENT_ID` varchar(128) DEFAULT '',
  `READ_AGREEMENT` tinyint(1) NOT NULL DEFAULT '1',
  `LAST_DEC_LV` varchar(32) DEFAULT '',
  `BONUS_APP_CLIENT_ID` varchar(128) DEFAULT '',
  `IS_FIRST_OPEN` tinyint(1) DEFAULT '1',
	`USER_ID` varchar(32) NOT NULL,
  `ZC_PV` decimal(16,3) NOT NULL DEFAULT '0.000',
  `ZC_AMOUNT` decimal(16,3) NOT NULL DEFAULT '0.000',
  `CON_UID` varchar(32) NOT NULL,
  `REC_UID` varchar(32) NOT NULL,
  `CON_NUM` int(10) NOT NULL DEFAULT '0',
  `REC_NUM` int(10) NOT NULL DEFAULT '0',
  `NETWORK_DEEP` int(10) NOT NULL DEFAULT '0',
  `RELATION_DEEP` int(10) NOT NULL DEFAULT '0',
  `SYSTEM_ID` varchar(32) DEFAULT NULL,
  `IS_GROUP_LEADER` tinyint(1) NOT NULL DEFAULT '0',
  `IS_SYSTEM_LEADER` tinyint(1) NOT NULL DEFAULT '0',
  `IS_TEAM` tinyint(1) NOT NULL DEFAULT '0',
  `IS_BIND` tinyint(1) NOT NULL DEFAULT '0',
  `IS_TEAM_MAIN` tinyint(1) NOT NULL DEFAULT '0',
  `IS_BIND_MAIN` tinyint(1) NOT NULL DEFAULT '0',
  `IS_AUTO_WITHDRAW` tinyint(1) NOT NULL DEFAULT '0',
  `CLOSE_LOGIN` tinyint(1) NOT NULL DEFAULT '0',
  `REG_TYPE` varchar(32) NOT NULL DEFAULT '56D9181C0F5D428FA2DBD4CAB263BF2F',
  `SHOULD_REG_TYPE` varchar(32) DEFAULT '56D9181C0F5D428FA2DBD4CAB263BF2F',
  `REG_NAME` varchar(255) DEFAULT NULL,
  `CREDIT_CODE` varchar(255) DEFAULT NULL,
  `PREMISES` varchar(255) DEFAULT NULL,
  `LEGAL_PERSON` varchar(255) DEFAULT NULL,
  `REG_EXPIRES` int(10) DEFAULT NULL,
  `STORE_TYPE` tinyint(1) NOT NULL DEFAULT '0',
  `INVOICE_BALANCE` decimal(16,2) NOT NULL DEFAULT '0.00',
  `HIGHEST_EMP_LV` varchar(32) DEFAULT NULL,
  `CLOSE_LOGIN_AT` int(10) NOT NULL DEFAULT '0',
  `PULLED_AT` int(10) NOT NULL DEFAULT '0',
  `GROUP_LEADER_AT` int(10) NOT NULL DEFAULT '0',
  `ALLOW_RECONSUME_SMS` tinyint(1) NOT NULL DEFAULT '0',
  `ALLOW_RECONSUME_SMS_TO` int(10) NOT NULL DEFAULT '0',
  `HIGHEST_EMP_LV_PERIOD` int(10) NOT NULL DEFAULT '1',
  `LOGIN_NUMS` int(10) NOT NULL DEFAULT '0',
  `FAIL_NUMS` int(10) NOT NULL DEFAULT '0',
  `LAST_LOGIN_IP` varchar(16) NOT NULL DEFAULT '0.0.0.0',
  `LAST_LOGIN_AT` int(10) NOT NULL DEFAULT '0',
  `SHOW_EMP_LV` varchar(32) DEFAULT '',
    PRIMARY KEY (`ID`),
   UNIQUE KEY `USER_ID` (`USER_ID`) USING BTREE
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COMMENT='会员备份表';