Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
C
cloud-platform
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
youjj
cloud-platform
Commits
154eedc7
Commit
154eedc7
authored
Aug 05, 2019
by
jiaorz
Browse files
Options
Browse Files
Download
Plain Diff
Merge remote-tracking branch 'origin/base-modify' into base-modify
parents
f8f0fea2
c0f19f8b
Changes
13
Hide whitespace changes
Inline
Side-by-side
Showing
13 changed files
with
57 additions
and
15 deletions
+57
-15
ReferralCodeUtil.java
...github/wxiaoqi/security/common/util/ReferralCodeUtil.java
+1
-1
AppUserDetailBiz.java
...m/github/wxiaoqi/security/admin/biz/AppUserDetailBiz.java
+5
-5
AppUserLoginBiz.java
...om/github/wxiaoqi/security/admin/biz/AppUserLoginBiz.java
+4
-0
AppUserDetailMapper.java
...ub/wxiaoqi/security/admin/mapper/AppUserDetailMapper.java
+1
-0
AppUserLoginMapper.java
...hub/wxiaoqi/security/admin/mapper/AppUserLoginMapper.java
+4
-0
AppUserLoginMapper.xml
...ce-admin/src/main/resources/mapper/AppUserLoginMapper.xml
+4
-0
BaseOrderBiz.java
...c/main/java/com/xxfc/platform/order/biz/BaseOrderBiz.java
+4
-3
ThirdFeign.java
...in/java/com/xxfc/platform/universal/feign/ThirdFeign.java
+3
-0
DictionaryBiz.java
...n/java/com/xxfc/platform/universal/biz/DictionaryBiz.java
+7
-0
DictionaryController.java
...c/platform/universal/controller/DictionaryController.java
+5
-0
pom.xml
xx-vehicle/xx-vehicle-server/pom.xml
+5
-0
VehicleApplication.java
...in/java/com/xxfc/platform/vehicle/VehicleApplication.java
+1
-1
VehicleJobHandler.java
...m/xxfc/platform/vehicle/jobhandler/VehicleJobHandler.java
+13
-5
No files found.
ace-common/src/main/java/com/github/wxiaoqi/security/common/util/ReferralCodeUtil.java
View file @
154eedc7
...
@@ -21,7 +21,7 @@ public class ReferralCodeUtil {
...
@@ -21,7 +21,7 @@ public class ReferralCodeUtil {
static
{
static
{
PERMUTATION
=
permutation
(
LEN
);
PERMUTATION
=
permutation
(
LEN
);
MAX_COMBINATION
=
combination
(
36
,
LEN
);
MAX_COMBINATION
=
combination
(
_stuffs
.
length
,
LEN
);
}
}
// public static void resetStuffs() {
// public static void resetStuffs() {
...
...
ace-modules/ace-admin/src/main/java/com/github/wxiaoqi/security/admin/biz/AppUserDetailBiz.java
View file @
154eedc7
...
@@ -7,16 +7,15 @@ import com.github.wxiaoqi.security.admin.mapper.AppUserDetailMapper;
...
@@ -7,16 +7,15 @@ import com.github.wxiaoqi.security.admin.mapper.AppUserDetailMapper;
import
com.github.wxiaoqi.security.admin.rpc.service.AppPermissionService
;
import
com.github.wxiaoqi.security.admin.rpc.service.AppPermissionService
;
import
com.github.wxiaoqi.security.admin.vo.AppUserVo
;
import
com.github.wxiaoqi.security.admin.vo.AppUserVo
;
import
com.github.wxiaoqi.security.common.biz.BaseBiz
;
import
com.github.wxiaoqi.security.common.biz.BaseBiz
;
import
com.github.wxiaoqi.security.common.util.ReferralCodeUtil
;
import
org.apache.commons.beanutils.BeanUtils
;
import
org.apache.commons.beanutils.BeanUtils
;
import
org.apache.commons.collections.CollectionUtils
;
import
org.apache.commons.collections.CollectionUtils
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.stereotype.Service
;
import
org.springframework.stereotype.Service
;
import
org.springframework.transaction.annotation.Transactional
;
import
org.springframework.transaction.annotation.Transactional
;
import
tk.mybatis.mapper.entity.Example
;
import
tk.mybatis.mapper.entity.Example
;
import
java.time.Instant
;
import
java.time.Instant
;
import
java.util.Collection
;
import
java.util.*
;
import
java.util.HashMap
;
import
java.util.List
;
import
java.util.Map
;
import
java.util.function.Function
;
import
java.util.function.Function
;
import
java.util.stream.Collectors
;
import
java.util.stream.Collectors
;
...
@@ -31,7 +30,8 @@ import java.util.stream.Collectors;
...
@@ -31,7 +30,8 @@ import java.util.stream.Collectors;
public
class
AppUserDetailBiz
extends
BaseBiz
<
AppUserDetailMapper
,
AppUserDetail
>
{
public
class
AppUserDetailBiz
extends
BaseBiz
<
AppUserDetailMapper
,
AppUserDetail
>
{
@Autowired
private
AppUserLoginBiz
appUserLoginBiz
;
@Override
@Override
@CacheClear
(
pre
=
"user{1.userid}"
)
@CacheClear
(
pre
=
"user{1.userid}"
)
...
...
ace-modules/ace-admin/src/main/java/com/github/wxiaoqi/security/admin/biz/AppUserLoginBiz.java
View file @
154eedc7
...
@@ -220,4 +220,8 @@ public class AppUserLoginBiz extends BaseBiz<AppUserLoginMapper, AppUserLogin> {
...
@@ -220,4 +220,8 @@ public class AppUserLoginBiz extends BaseBiz<AppUserLoginMapper, AppUserLogin> {
appUserLogin
.
setIsdel
(
0
);
appUserLogin
.
setIsdel
(
0
);
mapper
.
updateByPrimaryKeySelective
(
appUserLogin
);
mapper
.
updateByPrimaryKeySelective
(
appUserLogin
);
}
}
public
List
<
Integer
>
findAllExistUserIds
(){
return
mapper
.
selectAllExistUserIds
();
}
}
}
ace-modules/ace-admin/src/main/java/com/github/wxiaoqi/security/admin/mapper/AppUserDetailMapper.java
View file @
154eedc7
...
@@ -17,4 +17,5 @@ public interface AppUserDetailMapper extends Mapper<AppUserDetail> {
...
@@ -17,4 +17,5 @@ public interface AppUserDetailMapper extends Mapper<AppUserDetail> {
List
<
AppUserManageVo
>
selectAppUserManage
(
AppUserManageDTO
appUserManageDTO
);
List
<
AppUserManageVo
>
selectAppUserManage
(
AppUserManageDTO
appUserManageDTO
);
void
updateUserMemberStatusByUserId
(
@Param
(
"userId"
)
Integer
userId
,
@Param
(
"status"
)
Integer
status
);
void
updateUserMemberStatusByUserId
(
@Param
(
"userId"
)
Integer
userId
,
@Param
(
"status"
)
Integer
status
);
}
}
\ No newline at end of file
ace-modules/ace-admin/src/main/java/com/github/wxiaoqi/security/admin/mapper/AppUserLoginMapper.java
View file @
154eedc7
...
@@ -3,6 +3,7 @@ package com.github.wxiaoqi.security.admin.mapper;
...
@@ -3,6 +3,7 @@ package com.github.wxiaoqi.security.admin.mapper;
import
com.github.wxiaoqi.security.admin.entity.AppUserLogin
;
import
com.github.wxiaoqi.security.admin.entity.AppUserLogin
;
import
com.github.wxiaoqi.security.admin.entity.AppUserManage
;
import
com.github.wxiaoqi.security.admin.entity.AppUserManage
;
import
org.apache.ibatis.annotations.Param
;
import
org.apache.ibatis.annotations.Param
;
import
org.apache.ibatis.annotations.Select
;
import
org.apache.ibatis.annotations.Update
;
import
org.apache.ibatis.annotations.Update
;
import
tk.mybatis.mapper.additional.idlist.SelectByIdListMapper
;
import
tk.mybatis.mapper.additional.idlist.SelectByIdListMapper
;
import
tk.mybatis.mapper.common.Mapper
;
import
tk.mybatis.mapper.common.Mapper
;
...
@@ -24,4 +25,7 @@ public interface AppUserLoginMapper extends Mapper<AppUserLogin>, SelectByIdList
...
@@ -24,4 +25,7 @@ public interface AppUserLoginMapper extends Mapper<AppUserLogin>, SelectByIdList
List
<
AppUserLogin
>
selectbyPhones
(
@Param
(
"phones"
)
List
<
String
>
phones
);
List
<
AppUserLogin
>
selectbyPhones
(
@Param
(
"phones"
)
List
<
String
>
phones
);
int
bindOpenId
(
AppUserLogin
appUserLogin
);
int
bindOpenId
(
AppUserLogin
appUserLogin
);
List
<
Integer
>
selectAllExistUserIds
();
}
}
\ No newline at end of file
ace-modules/ace-admin/src/main/resources/mapper/AppUserLoginMapper.xml
View file @
154eedc7
...
@@ -12,4 +12,8 @@
...
@@ -12,4 +12,8 @@
<update
id=
"bindOpenId"
parameterType=
"com.github.wxiaoqi.security.admin.entity.AppUserLogin"
>
<update
id=
"bindOpenId"
parameterType=
"com.github.wxiaoqi.security.admin.entity.AppUserLogin"
>
UPDATE app_user_login SET wx_openid=#{wxOpenid},unionid=#{unionid},openid=#{openid} where id=#{id}
UPDATE app_user_login SET wx_openid=#{wxOpenid},unionid=#{unionid},openid=#{openid} where id=#{id}
</update>
</update>
<select
id=
"selectAllExistUserIds"
resultType=
"integer"
>
SELECT `id` FROM `app_user_login` WHERE `isdel`=0;
</select>
</mapper>
</mapper>
\ No newline at end of file
xx-order/xx-order-server/src/main/java/com/xxfc/platform/order/biz/BaseOrderBiz.java
View file @
154eedc7
...
@@ -341,12 +341,13 @@ public class BaseOrderBiz extends BaseBiz<BaseOrderMapper, BaseOrder> {
...
@@ -341,12 +341,13 @@ public class BaseOrderBiz extends BaseBiz<BaseOrderMapper, BaseOrder> {
AppUserDTO
appUserDTO
=
userFeign
.
userDetailById
(
baseOrder
.
getUserId
()).
getData
();
AppUserDTO
appUserDTO
=
userFeign
.
userDetailById
(
baseOrder
.
getUserId
()).
getData
();
//处理App用户提醒短信的发送
//处理App用户提醒短信的发送
orderMsgBiz
.
handelAppUserMsg
(
orvd
,
omd
,
baseOrder
,
appUserDTO
);
// orderMsgBiz.handelAppUserMsg(orvd, omd, baseOrder, appUserDTO);
orderMsgBiz
.
handelMsgPayNew
(
orvd
,
otd
,
omd
,
baseOrder
,
appUserDTO
);
//处理后台用户提醒短信的发送
//处理后台用户提醒短信的发送
orderMsgBiz
.
handelBgUserMsg4Pay
(
orvd
,
baseOrder
,
appUserDTO
,
OrderMsgBiz
.
RENT_PAY
);
//
orderMsgBiz.handelBgUserMsg4Pay(orvd, baseOrder, appUserDTO, OrderMsgBiz.RENT_PAY);
sendOrderMq
(
orvd
,
otd
,
omd
,
baseOrder
,
OrderMQDTO
.
ORDER_PAY
);
sendOrderMq
(
orvd
,
otd
,
omd
,
baseOrder
,
OrderMQDTO
.
ORDER_PAY
);
if
(
OrderTypeEnum
.
MEMBER
.
getCode
().
equals
(
baseOrder
.
getType
()))
{
if
(
OrderTypeEnum
.
MEMBER
.
getCode
().
equals
(
baseOrder
.
getType
()))
{
sendOrderMq
(
orvd
,
otd
,
omd
,
baseOrder
,
OrderMQDTO
.
ORDER_FINISH
);
sendOrderMq
(
orvd
,
otd
,
omd
,
baseOrder
,
OrderMQDTO
.
ORDER_FINISH
);
}
}
}
}
...
...
xx-universal/xx-universal-api/src/main/java/com/xxfc/platform/universal/feign/ThirdFeign.java
View file @
154eedc7
...
@@ -72,6 +72,9 @@ public interface ThirdFeign {
...
@@ -72,6 +72,9 @@ public interface ThirdFeign {
@RequestMapping
(
value
=
"/dictionary/getAll4Map"
,
method
=
RequestMethod
.
GET
)
@RequestMapping
(
value
=
"/dictionary/getAll4Map"
,
method
=
RequestMethod
.
GET
)
public
ObjectRestResponse
<
Map
<
String
,
Dictionary
>>
dictionaryGetAll4Map
();
public
ObjectRestResponse
<
Map
<
String
,
Dictionary
>>
dictionaryGetAll4Map
();
@PostMapping
(
"/dictionary/type_code"
)
public
Dictionary
findDictionaryByTypeAndCode
(
@RequestParam
(
value
=
"type"
)
String
type
,
@RequestParam
(
value
=
"code"
)
String
code
);
/***************************************** 违章 ********************************************/
/***************************************** 违章 ********************************************/
...
...
xx-universal/xx-universal-server/src/main/java/com/xxfc/platform/universal/biz/DictionaryBiz.java
View file @
154eedc7
...
@@ -147,4 +147,11 @@ public class DictionaryBiz extends BaseBiz<DictionaryMapper, Dictionary> {
...
@@ -147,4 +147,11 @@ public class DictionaryBiz extends BaseBiz<DictionaryMapper, Dictionary> {
}
}
return
dictionaryVoList
;
return
dictionaryVoList
;
}
}
public
Dictionary
findDictionaryByTypeAndCode
(
String
type
,
String
code
)
{
Dictionary
dictionary
=
new
Dictionary
();
dictionary
.
setType
(
type
);
dictionary
.
setCode
(
code
);
return
mapper
.
selectOne
(
dictionary
);
}
}
}
xx-universal/xx-universal-server/src/main/java/com/xxfc/platform/universal/controller/DictionaryController.java
View file @
154eedc7
...
@@ -56,6 +56,11 @@ public class DictionaryController {
...
@@ -56,6 +56,11 @@ public class DictionaryController {
return
ObjectRestResponse
.
succ
(
dictionaryBiz
.
getAll4Map
());
return
ObjectRestResponse
.
succ
(
dictionaryBiz
.
getAll4Map
());
}
}
@PostMapping
(
"/type_code"
)
public
Dictionary
findDictionaryByTypeAndCode
(
@RequestParam
(
value
=
"type"
)
String
type
,
@RequestParam
(
value
=
"code"
)
String
code
){
return
dictionaryBiz
.
findDictionaryByTypeAndCode
(
type
,
code
);
}
@GetMapping
(
value
=
"/app/unauth/clearCache"
)
@GetMapping
(
value
=
"/app/unauth/clearCache"
)
@ApiOperation
(
value
=
"清除缓存"
)
@ApiOperation
(
value
=
"清除缓存"
)
@IgnoreUserToken
@IgnoreUserToken
...
...
xx-vehicle/xx-vehicle-server/pom.xml
View file @
154eedc7
...
@@ -24,6 +24,11 @@
...
@@ -24,6 +24,11 @@
<scope>
compile
</scope>
<scope>
compile
</scope>
</dependency>
</dependency>
<dependency>
<groupId>
com.xxfc.platform
</groupId>
<artifactId>
xx-universal-api
</artifactId>
<version>
2.0-SNAPSHOT
</version>
</dependency>
</dependencies>
</dependencies>
<build>
<build>
...
...
xx-vehicle/xx-vehicle-server/src/main/java/com/xxfc/platform/vehicle/VehicleApplication.java
View file @
154eedc7
...
@@ -19,7 +19,7 @@ import org.springframework.scheduling.annotation.EnableScheduling;
...
@@ -19,7 +19,7 @@ import org.springframework.scheduling.annotation.EnableScheduling;
@EnableDiscoveryClient
@EnableDiscoveryClient
@EnableScheduling
@EnableScheduling
@EnableAceAuthClient
@EnableAceAuthClient
@EnableFeignClients
(
value
=
{
"com.github.wxiaoqi.security"
,
"com.xxfc.platform.
vehicle
.feign"
},
defaultConfiguration
=
HeaderConfig
.
class
)
@EnableFeignClients
(
value
=
{
"com.github.wxiaoqi.security"
,
"com.xxfc.platform.
*
.feign"
},
defaultConfiguration
=
HeaderConfig
.
class
)
@EnableAceCache
@EnableAceCache
@AddBasicConfiguration
@AddBasicConfiguration
@tk
.
mybatis
.
spring
.
annotation
.
MapperScan
(
basePackages
=
"com.xxfc.platform.vehicle.mapper"
)
@tk
.
mybatis
.
spring
.
annotation
.
MapperScan
(
basePackages
=
"com.xxfc.platform.vehicle.mapper"
)
...
...
xx-vehicle/xx-vehicle-server/src/main/java/com/xxfc/platform/vehicle/jobhandler/VehicleJobHandler.java
View file @
154eedc7
package
com
.
xxfc
.
platform
.
vehicle
.
jobhandler
;
package
com
.
xxfc
.
platform
.
vehicle
.
jobhandler
;
import
com.xxfc.platform.universal.entity.Dictionary
;
import
com.xxfc.platform.universal.feign.ThirdFeign
;
import
com.xxfc.platform.vehicle.biz.VehicleBiz
;
import
com.xxfc.platform.vehicle.biz.VehicleBiz
;
import
com.xxfc.platform.vehicle.biz.VehicleBookInfoBiz
;
import
com.xxfc.platform.vehicle.biz.VehicleBookInfoBiz
;
import
com.xxfc.platform.vehicle.entity.VehicleBookInfo
;
import
com.xxfc.platform.vehicle.entity.VehicleBookInfo
;
...
@@ -31,19 +33,25 @@ public class VehicleJobHandler extends IJobHandler {
...
@@ -31,19 +33,25 @@ public class VehicleJobHandler extends IJobHandler {
@Autowired
@Autowired
private
VehicleBookInfoBiz
vehicleBookInfoBiz
;
private
VehicleBookInfoBiz
vehicleBookInfoBiz
;
@Autowired
private
ThirdFeign
thirdFeign
;
private
static
final
String
DIC_VEHICLE_TYPE
=
"VEHICLE"
;
private
static
final
String
DIC_VEHICLE_CODE
=
"VEHICLE_JOB"
;
@Override
@Override
public
ReturnT
<
String
>
execute
(
String
s
)
throws
Exception
{
public
ReturnT
<
String
>
execute
(
String
s
)
throws
Exception
{
try
{
try
{
List
<
String
>
existVehicleIds
=
vehicleBiz
.
findExistVehicleIds
();
List
<
String
>
existVehicleIds
=
vehicleBiz
.
findExistVehicleIds
();
Dictionary
dictionary
=
thirdFeign
.
findDictionaryByTypeAndCode
(
DIC_VEHICLE_TYPE
,
DIC_VEHICLE_CODE
);
LocalDate
date
=
LocalDate
.
now
();
LocalDate
date
=
LocalDate
.
now
();
int
year
=
date
.
getYear
();
int
year
=
date
.
getYear
();
int
nowMonth
=
date
.
getMonthValue
();
int
nowMonth
=
date
.
getMonthValue
();
int
month
=
nowMonth
+
VehicleBookInfoBiz
.
MONTH_INTERVAL
>
12
?
(
VehicleBookInfoBiz
.
MONTH_INTERVAL
+
nowMonth
)
-
12
:
nowMonth
+
VehicleBookInfoBiz
.
MONTH_INTERVAL
;
int
betweenMonth
=
Integer
.
valueOf
(
dictionary
.
getDetail
()).
intValue
();
int
month
=
nowMonth
+
betweenMonth
>
12
?
(
betweenMonth
+
nowMonth
)
-
12
:
nowMonth
+
betweenMonth
;
year
=
month
>
nowMonth
?
year
:
year
+
1
;
year
=
month
>
nowMonth
?
year
:
year
+
1
;
if
(
"8"
.
equals
(
s
)
||
"9"
.
equals
(
s
)){
String
yearAndMonth
=
String
.
format
(
"%d-%s"
,
year
,
month
>
10
?
month:
"0"
+
month
);
month
=
Integer
.
valueOf
(
s
);
}
String
yearAndMonth
=
String
.
format
(
"%d-%d"
,
year
,
month
);
XxlJobLogger
.
log
(
"----查询到的车型ids:【{}】"
,
existVehicleIds
);
XxlJobLogger
.
log
(
"----查询到的车型ids:【{}】"
,
existVehicleIds
);
if
(
CollectionUtils
.
isNotEmpty
(
existVehicleIds
))
{
if
(
CollectionUtils
.
isNotEmpty
(
existVehicleIds
))
{
List
<
VehicleBookInfo
>
bookInfos
=
existVehicleIds
.
stream
().
map
(
vehicleId
->
{
List
<
VehicleBookInfo
>
bookInfos
=
existVehicleIds
.
stream
().
map
(
vehicleId
->
{
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment