gongdecai há 1 ano atrás
pai
commit
dc22aa2aae

+ 5 - 5
unimall-admin-api/src/main/java/com/iotechn/unimall/admin/api/admin/AdminServiceImpl.java

@@ -72,10 +72,10 @@ public class AdminServiceImpl implements AdminService {
 		if (CollectionUtils.isEmpty(adminDOS)) {
 			throw new AdminServiceException(ExceptionDefinition.ADMIN_NOT_EXIST);
 		}
-		if(adminDOS.get(0).getStatus()==0){
-			throw new AdminServiceException(ExceptionDefinition.ADMIN_NOT_JIHUO);
-
-		}
+//		if(adminDOS.get(0).getStatus()==0){
+//			throw new AdminServiceException(ExceptionDefinition.ADMIN_NOT_JIHUO);
+//
+//		}
 		AdminDO adminDO = adminDOS.get(0);
 		// 短信验证码
 //        String code = cacheComponent.getRaw(ADMIN_MSG_CODE+adminDO.getPhone() );
@@ -165,7 +165,7 @@ public class AdminServiceImpl implements AdminService {
 		adminDO.setStatus(AdminStatusType.ACTIVE.getCode());
 		adminDO.setLastLoginIp("0.0.0.0");
 		adminDO.setGmtLastLogin("1997-01-20 00:00:00");
-		adminDO.setStatus(0);
+//		adminDO.setStatus(0);
 		if (adminMapper.insert(adminDO) > 0) {
 			adminDTO.setId(adminDO.getId());
 			return adminDTO;

+ 54 - 54
unimall-data/src/main/resources/com/iotechn/unimall/data/mapper/tools/gen/GenTableColumnMapper.xml

@@ -3,59 +3,59 @@
 <mapper
 	namespace="com.iotechn.unimall.data.mapper.tools.gen.GenTableColumnMapper">
 
-	<resultMap type="GenTableColumn" id="GenTableColumnResult">
-		<id property="columnId" column="column_id" />
-		<result property="tableId" column="table_id" />
-		<result property="columnName" column="column_name" />
-		<result property="columnComment" column="column_comment" />
-		<result property="columnType" column="column_type" />
-		<result property="javaType" column="java_type" />
-		<result property="javaField" column="java_field" />
-		<result property="isPk" column="is_pk" />
-		<result property="isIncrement" column="is_increment" />
-		<result property="isRequired" column="is_required" />
-		<result property="isInsert" column="is_insert" />
-		<result property="isEdit" column="is_edit" />
-		<result property="isList" column="is_list" />
-		<result property="isQuery" column="is_query" />
-		<result property="queryType" column="query_type" />
-		<result property="htmlType" column="html_type" />
-		<result property="dictType" column="dict_type" />
-		<result property="sort" column="sort" />
-		<result property="createBy" column="create_by" />
-		<result property="createTime" column="create_time" />
-		<result property="updateBy" column="update_by" />
-		<result property="updateTime" column="update_time" />
-	</resultMap>
-	<sql id="selectDictTypeVo">
-		SELECT
-		table_id AS tableId,
-		`table_name` AS tableName,
-		table_comment AS tableComment,
-		class_name AS className,
-		tpl_category AS tplCategory,
-		package_name AS packageName,
-		module_name AS moduleName,
-		business_name AS businessName,
-		function_name AS functionName,
-		function_author AS functionAuthor,
-		create_by AS createBy,
-		create_time AS createTime,
-		update_by AS updateBy,
-		update_time AS updateTime,
-		`options`
-		FROM
-		sys_gen_table
-	</sql>
-	<select id="selectDbTableColumnsByName" parameterType="String" resultType="com.iotechn.unimall.data.domain.tools.gen.GenTableColumn">
-		select column_name as columnName, (case when (is_nullable = 'no' <![CDATA[ && ]]>
-		column_key != 'PRI') then '1' else null end) as isRequired, (case
-		when column_key = 'PRI' then '1' else '0' end) as isPk,
-		ordinal_position as sort, column_comment as columnComment, (case when extra =
-		'auto_increment' then '1' else '0' end) as isIncrement, column_type as columnType
-		from information_schema.columns where table_schema = (select
-		database()) and table_name = (#{tableName})
-		order by ordinal_position
-	</select>
+<!--	<resultMap type="GenTableColumn" id="GenTableColumnResult">-->
+<!--		<id property="columnId" column="column_id" />-->
+<!--		<result property="tableId" column="table_id" />-->
+<!--		<result property="columnName" column="column_name" />-->
+<!--		<result property="columnComment" column="column_comment" />-->
+<!--		<result property="columnType" column="column_type" />-->
+<!--		<result property="javaType" column="java_type" />-->
+<!--		<result property="javaField" column="java_field" />-->
+<!--		<result property="isPk" column="is_pk" />-->
+<!--		<result property="isIncrement" column="is_increment" />-->
+<!--		<result property="isRequired" column="is_required" />-->
+<!--		<result property="isInsert" column="is_insert" />-->
+<!--		<result property="isEdit" column="is_edit" />-->
+<!--		<result property="isList" column="is_list" />-->
+<!--		<result property="isQuery" column="is_query" />-->
+<!--		<result property="queryType" column="query_type" />-->
+<!--		<result property="htmlType" column="html_type" />-->
+<!--		<result property="dictType" column="dict_type" />-->
+<!--		<result property="sort" column="sort" />-->
+<!--		<result property="createBy" column="create_by" />-->
+<!--		<result property="createTime" column="create_time" />-->
+<!--		<result property="updateBy" column="update_by" />-->
+<!--		<result property="updateTime" column="update_time" />-->
+<!--	</resultMap>-->
+<!--	<sql id="selectDictTypeVo">-->
+<!--		SELECT-->
+<!--		table_id AS tableId,-->
+<!--		`table_name` AS tableName,-->
+<!--		table_comment AS tableComment,-->
+<!--		class_name AS className,-->
+<!--		tpl_category AS tplCategory,-->
+<!--		package_name AS packageName,-->
+<!--		module_name AS moduleName,-->
+<!--		business_name AS businessName,-->
+<!--		function_name AS functionName,-->
+<!--		function_author AS functionAuthor,-->
+<!--		create_by AS createBy,-->
+<!--		create_time AS createTime,-->
+<!--		update_by AS updateBy,-->
+<!--		update_time AS updateTime,-->
+<!--		`options`-->
+<!--		FROM-->
+<!--		sys_gen_table-->
+<!--	</sql>-->
+<!--	<select id="selectDbTableColumnsByName" parameterType="String" resultType="com.iotechn.unimall.data.domain.tools.gen.GenTableColumn">-->
+<!--		select column_name as columnName, (case when (is_nullable = 'no' <![CDATA[ && ]]>-->
+<!--		column_key != 'PRI') then '1' else null end) as isRequired, (case-->
+<!--		when column_key = 'PRI' then '1' else '0' end) as isPk,-->
+<!--		ordinal_position as sort, column_comment as columnComment, (case when extra =-->
+<!--		'auto_increment' then '1' else '0' end) as isIncrement, column_type as columnType-->
+<!--		from information_schema.columns where table_schema = (select-->
+<!--		database()) and table_name = (#{tableName})-->
+<!--		order by ordinal_position-->
+<!--	</select>-->
 
 </mapper>

+ 119 - 119
unimall-data/src/main/resources/com/iotechn/unimall/data/mapper/tools/gen/GenTableMapper.xml

@@ -2,124 +2,124 @@
 <!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
 <mapper namespace="com.iotechn.unimall.data.mapper.tools.gen.GenTableMapper">
 
-	<resultMap type="GenTable" id="GenTableResult">
-	    <id     property="tableId"        column="table_id"        />
-		<result property="tableName"      column="table_name"      />
-		<result property="tableComment"   column="table_comment"   />
-		<result property="className"      column="class_name"      />
-		<result property="tplCategory"    column="tpl_category"    />
-		<result property="packageName"    column="package_name"    />
-		<result property="moduleName"     column="module_name"     />
-		<result property="businessName"   column="business_name"   />
-		<result property="functionName"   column="function_name"   />
-		<result property="functionAuthor" column="function_author" />
-		<result property="options"        column="options"         />
-		<result property="createBy"       column="create_by"       />
-		<result property="createTime"     column="create_time"     />
-		<result property="updateBy"       column="update_by"       />
-		<result property="updateTime"     column="update_time"     />
-		<result property="remark"         column="remark"          />
-		<collection  property="columns"  javaType="java.util.List"  resultMap="GenTableColumnResult" />
-	</resultMap>
+<!--	<resultMap type="GenTable" id="GenTableResult">-->
+<!--	    <id     property="tableId"        column="table_id"        />-->
+<!--		<result property="tableName"      column="table_name"      />-->
+<!--		<result property="tableComment"   column="table_comment"   />-->
+<!--		<result property="className"      column="class_name"      />-->
+<!--		<result property="tplCategory"    column="tpl_category"    />-->
+<!--		<result property="packageName"    column="package_name"    />-->
+<!--		<result property="moduleName"     column="module_name"     />-->
+<!--		<result property="businessName"   column="business_name"   />-->
+<!--		<result property="functionName"   column="function_name"   />-->
+<!--		<result property="functionAuthor" column="function_author" />-->
+<!--		<result property="options"        column="options"         />-->
+<!--		<result property="createBy"       column="create_by"       />-->
+<!--		<result property="createTime"     column="create_time"     />-->
+<!--		<result property="updateBy"       column="update_by"       />-->
+<!--		<result property="updateTime"     column="update_time"     />-->
+<!--		<result property="remark"         column="remark"          />-->
+<!--		<collection  property="columns"  javaType="java.util.List"  resultMap="GenTableColumnResult" />-->
+<!--	</resultMap>-->
 
-	<resultMap type="GenTableColumn" id="GenTableColumnResult">
-        <id     property="columnId"       column="column_id"      />
-        <result property="tableId"        column="table_id"       />
-        <result property="columnName"     column="column_name"    />
-        <result property="columnComment"  column="column_comment" />
-        <result property="columnType"     column="column_type"    />
-        <result property="javaType"       column="java_type"      />
-        <result property="javaField"      column="java_field"     />
-        <result property="isPk"           column="is_pk"          />
-        <result property="isIncrement"    column="is_increment"   />
-        <result property="isRequired"     column="is_required"    />
-        <result property="isInsert"       column="is_insert"      />
-        <result property="isEdit"         column="is_edit"        />
-        <result property="isList"         column="is_list"        />
-        <result property="isQuery"        column="is_query"       />
-        <result property="queryType"      column="query_type"     />
-        <result property="htmlType"       column="html_type"      />
-        <result property="dictType"       column="dict_type"      />
-        <result property="sort"           column="sort"           />
-        <result property="createBy"       column="create_by"      />
-        <result property="createTime"     column="create_time"    />
-        <result property="updateBy"       column="update_by"      />
-        <result property="updateTime"     column="update_time"    />
-    </resultMap>
-	<sql id="selectDictTypeVo">
-		SELECT
-			table_id AS tableId,
-			`table_name` AS tableName,
-			table_comment AS tableComment,
-			class_name AS className,
-			tpl_category AS tplCategory,
-			package_name AS packageName,
-			module_name AS moduleName,
-			business_name AS businessName,
-			function_name AS functionName,
-			function_author AS functionAuthor,
-			create_by AS createBy,
-			create_time AS createTime,
-			update_by AS updateBy,
-			update_time AS updateTime,
-			`options`
-		FROM
-			sys_gen_table
-	</sql>
-	<select id="selectDbTableListByNames"  resultType="com.iotechn.unimall.data.domain.tools.gen.GenTable">
-		SELECT
-        table_name as tableName,
-        table_comment as tableComment,
-        create_time as createTime,
-        update_time as updateTime
-		FROM
-			information_schema.TABLES
-		WHERE
-			table_schema = ( SELECT DATABASE ( ) )
-			AND table_name NOT LIKE 'qrtz_%'
-			AND table_name NOT LIKE 'gen_%'
-			AND table_name NOT IN ( SELECT table_name FROM sys_gen_table )
-			AND table_name in
-			<foreach  item="item" collection="array" index="index"  open="(" separator="," close=")">
-			#{item}
-			</foreach>
-	</select>
-	<select id="selectDbTableList" parameterType="GenTable" resultType="com.iotechn.unimall.data.domain.tools.gen.GenTable">
-		SELECT
-			table_name as tableName,
-			table_comment as tableComment,
-			create_time as createTime,
-			update_time as updateTime
-		FROM
-			information_schema.TABLES
-		WHERE
-			table_schema = ( SELECT DATABASE ( ) )
-			AND table_name NOT LIKE 'qrtz_%'
-			AND table_name NOT LIKE 'gen_%'
-			AND table_name NOT IN ( SELECT table_name FROM sys_gen_table )
-		<if test="tableName != null and tableName != ''">
-			AND lower(table_name) like lower(concat('%', #{tableName}, '%'))
-		</if>
-		<if test="tableComment != null and tableComment != ''">
-			AND lower(table_comment) like lower(concat('%', #{tableComment}, '%'))
-		</if>
-	</select>
-	<select id="selectDbTableCount" parameterType="GenTable" resultType="java.lang.Integer">
-		SELECT
-			COUNT(*)
-		FROM
-			information_schema.TABLES
-		WHERE
-			table_schema = ( SELECT DATABASE ( ) )
-			AND table_name NOT LIKE 'qrtz_%'
-			AND table_name NOT LIKE 'gen_%'
-			AND table_name NOT IN ( SELECT table_name FROM sys_gen_table )
-		<if test="tableName != null and tableName != ''">
-			AND lower(table_name) like lower(concat('%', #{tableName}, '%'))
-		</if>
-		<if test="tableComment != null and tableComment != ''">
-			AND lower(table_comment) like lower(concat('%', #{tableComment}, '%'))
-		</if>
-	</select>
-	
+<!--	<resultMap type="GenTableColumn" id="GenTableColumnResult">-->
+<!--        <id     property="columnId"       column="column_id"      />-->
+<!--        <result property="tableId"        column="table_id"       />-->
+<!--        <result property="columnName"     column="column_name"    />-->
+<!--        <result property="columnComment"  column="column_comment" />-->
+<!--        <result property="columnType"     column="column_type"    />-->
+<!--        <result property="javaType"       column="java_type"      />-->
+<!--        <result property="javaField"      column="java_field"     />-->
+<!--        <result property="isPk"           column="is_pk"          />-->
+<!--        <result property="isIncrement"    column="is_increment"   />-->
+<!--        <result property="isRequired"     column="is_required"    />-->
+<!--        <result property="isInsert"       column="is_insert"      />-->
+<!--        <result property="isEdit"         column="is_edit"        />-->
+<!--        <result property="isList"         column="is_list"        />-->
+<!--        <result property="isQuery"        column="is_query"       />-->
+<!--        <result property="queryType"      column="query_type"     />-->
+<!--        <result property="htmlType"       column="html_type"      />-->
+<!--        <result property="dictType"       column="dict_type"      />-->
+<!--        <result property="sort"           column="sort"           />-->
+<!--        <result property="createBy"       column="create_by"      />-->
+<!--        <result property="createTime"     column="create_time"    />-->
+<!--        <result property="updateBy"       column="update_by"      />-->
+<!--        <result property="updateTime"     column="update_time"    />-->
+<!--    </resultMap>-->
+<!--	<sql id="selectDictTypeVo">-->
+<!--		SELECT-->
+<!--			table_id AS tableId,-->
+<!--			`table_name` AS tableName,-->
+<!--			table_comment AS tableComment,-->
+<!--			class_name AS className,-->
+<!--			tpl_category AS tplCategory,-->
+<!--			package_name AS packageName,-->
+<!--			module_name AS moduleName,-->
+<!--			business_name AS businessName,-->
+<!--			function_name AS functionName,-->
+<!--			function_author AS functionAuthor,-->
+<!--			create_by AS createBy,-->
+<!--			create_time AS createTime,-->
+<!--			update_by AS updateBy,-->
+<!--			update_time AS updateTime,-->
+<!--			`options`-->
+<!--		FROM-->
+<!--			sys_gen_table-->
+<!--	</sql>-->
+<!--	<select id="selectDbTableListByNames"  resultType="com.iotechn.unimall.data.domain.tools.gen.GenTable">-->
+<!--		SELECT-->
+<!--        table_name as tableName,-->
+<!--        table_comment as tableComment,-->
+<!--        create_time as createTime,-->
+<!--        update_time as updateTime-->
+<!--		FROM-->
+<!--			information_schema.TABLES-->
+<!--		WHERE-->
+<!--			table_schema = ( SELECT DATABASE ( ) )-->
+<!--			AND table_name NOT LIKE 'qrtz_%'-->
+<!--			AND table_name NOT LIKE 'gen_%'-->
+<!--			AND table_name NOT IN ( SELECT table_name FROM sys_gen_table )-->
+<!--			AND table_name in-->
+<!--			<foreach  item="item" collection="array" index="index"  open="(" separator="," close=")">-->
+<!--			#{item}-->
+<!--			</foreach>-->
+<!--	</select>-->
+<!--	<select id="selectDbTableList" parameterType="GenTable" resultType="com.iotechn.unimall.data.domain.tools.gen.GenTable">-->
+<!--		SELECT-->
+<!--			table_name as tableName,-->
+<!--			table_comment as tableComment,-->
+<!--			create_time as createTime,-->
+<!--			update_time as updateTime-->
+<!--		FROM-->
+<!--			information_schema.TABLES-->
+<!--		WHERE-->
+<!--			table_schema = ( SELECT DATABASE ( ) )-->
+<!--			AND table_name NOT LIKE 'qrtz_%'-->
+<!--			AND table_name NOT LIKE 'gen_%'-->
+<!--			AND table_name NOT IN ( SELECT table_name FROM sys_gen_table )-->
+<!--		<if test="tableName != null and tableName != ''">-->
+<!--			AND lower(table_name) like lower(concat('%', #{tableName}, '%'))-->
+<!--		</if>-->
+<!--		<if test="tableComment != null and tableComment != ''">-->
+<!--			AND lower(table_comment) like lower(concat('%', #{tableComment}, '%'))-->
+<!--		</if>-->
+<!--	</select>-->
+<!--	<select id="selectDbTableCount" parameterType="GenTable" resultType="java.lang.Integer">-->
+<!--		SELECT-->
+<!--			COUNT(*)-->
+<!--		FROM-->
+<!--			information_schema.TABLES-->
+<!--		WHERE-->
+<!--			table_schema = ( SELECT DATABASE ( ) )-->
+<!--			AND table_name NOT LIKE 'qrtz_%'-->
+<!--			AND table_name NOT LIKE 'gen_%'-->
+<!--			AND table_name NOT IN ( SELECT table_name FROM sys_gen_table )-->
+<!--		<if test="tableName != null and tableName != ''">-->
+<!--			AND lower(table_name) like lower(concat('%', #{tableName}, '%'))-->
+<!--		</if>-->
+<!--		<if test="tableComment != null and tableComment != ''">-->
+<!--			AND lower(table_comment) like lower(concat('%', #{tableComment}, '%'))-->
+<!--		</if>-->
+<!--	</select>-->
+<!--	-->
 </mapper>

+ 1 - 1
unimall-launcher/src/main/resources/application.properties

@@ -10,7 +10,7 @@ logging.level.root=info
 ###MySql (MySqlConfiguration)
 ########################################################
 spring.druid.driverClassName=com.mysql.jdbc.Driver
-spring.druid.url=jdbc:mysql://106.14.75.12/market?createDatabaseIfNotExist=true&characterEncoding=UTF-8&serverTimezone=Asia/Shanghai&allowMultiQueries=true&useSSL=false
+spring.druid.url=jdbc:mysql://106.14.75.12/bancai?createDatabaseIfNotExist=true&characterEncoding=UTF-8&serverTimezone=Asia/Shanghai&allowMultiQueries=true&useSSL=false
 spring.druid.username=root
 spring.druid.password=Ccj841968545
 spring.druid.maxActive=30