zouxuan 5 سال پیش
والد
کامیت
b20f9430de

+ 1 - 1
codegen/src/main/java/com/yonge/crud/CodegenApplication.java

@@ -28,7 +28,7 @@ public class CodegenApplication {
 		 */
 
 		// "src/generateConfigration.xml"
-		GenerateConfiguration genConfig = toObject("src/main/resources/generateConfigration.xml", GenerateConfiguration.class);
+		GenerateConfiguration genConfig = toObject("codegen/src/main/resources/generateConfigration.xml", GenerateConfiguration.class);
 
 		Configuration config = genConfig.getDbConfiguration();
 

+ 2 - 0
mec-auth/mec-auth-server/src/main/java/com/ym/mec/auth/web/controller/TokenController.java

@@ -8,6 +8,7 @@ import com.ym.mec.common.controller.BaseController;
 import com.ym.mec.common.entity.HttpResponseResult;
 import com.ym.mec.common.security.AuthUser;
 import com.ym.mec.common.security.SecurityUtils;
+import io.swagger.annotations.Api;
 import org.apache.commons.lang3.StringUtils;
 import org.springframework.beans.factory.annotation.Autowired;
 import org.springframework.http.*;
@@ -29,6 +30,7 @@ import java.util.Base64;
 import java.util.Map;
 
 @RestController
+@Api(tags = "认证服务")
 public class TokenController extends BaseController {
 
 	@Autowired

+ 2 - 2
mec-auth/mec-auth-server/src/main/resources/config/mybatis/SysUserMapper.xml

@@ -146,10 +146,10 @@
     </select>
 
     <select id="queryByUsername" resultMap="SysUser">
-		select * from sys_user where username_ = #{username}
+		select * from sys_user where username_ = #{username} OR phone_ = #{username}
 	</select>
 
     <select id="queryByPhone" resultMap="SysUser">
-		select * from sys_user where phone_ = #{phone}
+		select * from sys_user where phone_ = #{phone} OR username_ = #{phone}
 	</select>
 </mapper>