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
9b643891
Commit
9b643891
authored
Jul 08, 2019
by
jiaorz
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
注册接口修改
parent
0c1a0c05
Changes
25
Hide whitespace changes
Inline
Side-by-side
Showing
25 changed files
with
803 additions
and
4 deletions
+803
-4
ObjectRestResponse.java
...ithub/wxiaoqi/security/common/msg/ObjectRestResponse.java
+0
-3
IntegralRule.java
.../java/com/xxfc/platform/activity/entity/IntegralRule.java
+128
-0
IntegralSignRecord.java
...com/xxfc/platform/activity/entity/IntegralSignRecord.java
+47
-0
IntegralUserRecord.java
...com/xxfc/platform/activity/entity/IntegralUserRecord.java
+64
-0
IntegralUserTotal.java
.../com/xxfc/platform/activity/entity/IntegralUserTotal.java
+47
-0
ActivityFeign.java
.../java/com/xxfc/platform/activity/feign/ActivityFeign.java
+1
-1
UserInfoBiz.java
...ain/java/com/xxfc/platform/activity/user/UserInfoBiz.java
+29
-0
IntegralRuleBiz.java
.../java/com/xxfc/platform/activity/biz/IntegralRuleBiz.java
+77
-0
IntegralSignRecordBiz.java
...com/xxfc/platform/activity/biz/IntegralSignRecordBiz.java
+13
-0
IntegralUserRecordBiz.java
...com/xxfc/platform/activity/biz/IntegralUserRecordBiz.java
+62
-0
IntegralUserTotalBiz.java
.../com/xxfc/platform/activity/biz/IntegralUserTotalBiz.java
+100
-0
IntegralRuleMapper.java
...com/xxfc/platform/activity/mapper/IntegralRuleMapper.java
+10
-0
IntegralSignRecordMapper.java
...fc/platform/activity/mapper/IntegralSignRecordMapper.java
+7
-0
IntegralUserRecordMapper.java
...fc/platform/activity/mapper/IntegralUserRecordMapper.java
+7
-0
IntegralUserTotalMapper.java
...xfc/platform/activity/mapper/IntegralUserTotalMapper.java
+11
-0
IntegralRuleController.java
...m/xxfc/platform/activity/rest/IntegralRuleController.java
+48
-0
IntegralSignRecordController.java
.../platform/activity/rest/IntegralSignRecordController.java
+17
-0
IntegralUserRecordController.java
.../platform/activity/rest/IntegralUserRecordController.java
+17
-0
IntegralUserTotalController.java
...c/platform/activity/rest/IntegralUserTotalController.java
+11
-0
IntegralRuleMapper.xml
...y-server/src/main/resources/mapper/IntegralRuleMapper.xml
+45
-0
IntegralSignRecordMapper.xml
...er/src/main/resources/mapper/IntegralSignRecordMapper.xml
+14
-0
IntegralUserRecordMapper.xml
...er/src/main/resources/mapper/IntegralUserRecordMapper.xml
+18
-0
IntegralUserTotalMapper.xml
...ver/src/main/resources/mapper/IntegralUserTotalMapper.xml
+26
-0
BaseOrderController.java
...ava/com/xxfc/platform/order/rest/BaseOrderController.java
+1
-0
VehicleLicenseController.java
.../xxfc/platform/vehicle/rest/VehicleLicenseController.java
+3
-0
No files found.
ace-common/src/main/java/com/github/wxiaoqi/security/common/msg/ObjectRestResponse.java
View file @
9b643891
...
@@ -16,9 +16,6 @@ public class ObjectRestResponse<T> extends BaseResponse {
...
@@ -16,9 +16,6 @@ public class ObjectRestResponse<T> extends BaseResponse {
private
static
final
Integer
WEB_CALL_RESULT_FAILED
=
ResultCode
.
FAILED_CODE
;
private
static
final
Integer
WEB_CALL_RESULT_FAILED
=
ResultCode
.
FAILED_CODE
;
private
static
final
String
RESULT_SUCCESS_MSG
=
"操作成功"
;
private
static
final
String
RESULT_SUCCESS_MSG
=
"操作成功"
;
private
static
final
String
RESULT_FAIL_MSG
=
"操作失败"
;
private
static
final
String
RESULT_FAIL_MSG
=
"操作失败"
;
private
static
final
String
PARAM_IS_EMPTY
=
"参数为空"
;
public
boolean
isRel
()
{
public
boolean
isRel
()
{
return
rel
;
return
rel
;
}
}
...
...
xx-activity/xx-activity-api/src/main/java/com/xxfc/platform/activity/entity/IntegralRule.java
0 → 100644
View file @
9b643891
package
com
.
xxfc
.
platform
.
activity
.
entity
;
import
lombok.Data
;
import
javax.persistence.Column
;
import
javax.persistence.Id
;
import
javax.persistence.Table
;
import
java.math.BigDecimal
;
@Table
(
name
=
"integral_rule"
)
@Data
public
class
IntegralRule
{
/**
* 主键id
*/
@Id
private
Integer
id
;
/**
* 周期单位:0-天,1-周;3-月;4-季;5-年
*/
private
Integer
period
;
/**
* 次数
*/
private
Integer
number
;
/**
* 积分
*/
private
Integer
point
;
/**
* 积分兑换:金额/分
*/
private
BigDecimal
price
;
/**
* 是否连续:0-不连续;1-连续
*/
@Column
(
name
=
"is_continuity"
)
private
Boolean
isContinuity
;
/**
* 多少天后连续算
*/
@Column
(
name
=
"finish_day"
)
private
Integer
finishDay
;
/**
* n天获取的积分
*/
@Column
(
name
=
"finish_point"
)
private
Integer
finishPoint
;
/**
* 是否启用:1-启用;0-停用
*/
private
Boolean
status
;
/**
* 创建时间
*/
@Column
(
name
=
"crt_time"
)
private
Long
crtTime
;
/**
* 是否删除:0-正常;1-删除
*/
private
Boolean
isdel
;
/**
* 规则开始时间
*/
@Column
(
name
=
"start_time"
)
private
Long
startTime
;
/**
* 规则结束时间
*/
@Column
(
name
=
"end_time"
)
private
Long
endTime
;
/**
* 更新时间
*/
@Column
(
name
=
"upd_time"
)
private
Long
updTime
;
/**
* 备注
*/
private
String
remarks
;
/**
* 描述
*/
private
String
desc
;
/**
* 规则图片
*/
private
String
img
;
/**
* 排序
*/
@Column
(
name
=
"order_id"
)
private
Integer
orderId
;
/**
* 规则名称
*/
private
String
name
;
/**
* 获取积分规则
*/
private
String
regulation
;
/**
* json字符串 如:[{"day":4,"integeral":8},{"day":4,"integeral":8}]
*/
@Column
(
name
=
"other_rule"
)
private
String
otherRule
;
}
\ No newline at end of file
xx-activity/xx-activity-api/src/main/java/com/xxfc/platform/activity/entity/IntegralSignRecord.java
0 → 100644
View file @
9b643891
package
com
.
xxfc
.
platform
.
activity
.
entity
;
import
lombok.Data
;
import
javax.persistence.Column
;
import
javax.persistence.Id
;
import
javax.persistence.Table
;
@Table
(
name
=
"integral_sign_record"
)
@Data
public
class
IntegralSignRecord
{
/**
* 主键id
*/
@Id
private
Integer
id
;
/**
* 用户id
*/
@Column
(
name
=
"user_id"
)
private
Integer
userId
;
/**
* 连续签到天数
*/
@Column
(
name
=
"sign_days"
)
private
Integer
signDays
;
/**
* 开始时间
*/
@Column
(
name
=
"start_time"
)
private
Long
startTime
;
/**
* 最后签到时间
*/
@Column
(
name
=
"last_time"
)
private
Long
lastTime
;
/**
* 是否删除:0-正常;1-删除
*/
private
Boolean
isdel
;
}
\ No newline at end of file
xx-activity/xx-activity-api/src/main/java/com/xxfc/platform/activity/entity/IntegralUserRecord.java
0 → 100644
View file @
9b643891
package
com
.
xxfc
.
platform
.
activity
.
entity
;
import
lombok.Data
;
import
javax.persistence.Column
;
import
javax.persistence.Id
;
import
javax.persistence.Table
;
@Table
(
name
=
"integral_user_record"
)
@Data
public
class
IntegralUserRecord
{
/**
* 主键id
*/
@Id
private
Integer
id
;
/**
* 用户id
*/
@Column
(
name
=
"user_id"
)
private
Integer
userId
;
/**
* 0-获取积分;1-抵扣积分
*/
private
Boolean
type
;
/**
* 积分数
*/
private
Integer
point
;
/**
* 积分规则id
*/
@Column
(
name
=
"integral_rule_id"
)
private
Integer
integralRuleId
;
/**
* 积分时间
*/
@Column
(
name
=
"crt_time"
)
private
Long
crtTime
;
/**
* 是否有效:1-有效;0-失效
*/
@Column
(
name
=
"is_valid"
)
private
Boolean
isValid
;
/**
* 是否删除:0-正常;1-删除
*/
private
Boolean
isdel
;
/**
* 获取积分的途径id:如订单id,评论id,签到记录id
*/
@Column
(
name
=
"channel_id"
)
private
Integer
channelId
;
}
\ No newline at end of file
xx-activity/xx-activity-api/src/main/java/com/xxfc/platform/activity/entity/IntegralUserTotal.java
0 → 100644
View file @
9b643891
package
com
.
xxfc
.
platform
.
activity
.
entity
;
import
lombok.Data
;
import
javax.persistence.Column
;
import
javax.persistence.Id
;
import
javax.persistence.Table
;
@Table
(
name
=
"integral_user_total"
)
@Data
public
class
IntegralUserTotal
{
/**
* 主键id
*/
@Id
private
Integer
id
;
/**
* 用户id
*/
@Column
(
name
=
"user_id"
)
private
Integer
userId
;
/**
* 总收益积分
*/
@Column
(
name
=
"total_point"
)
private
Integer
totalPoint
;
/**
* 剩余收益积分
*/
@Column
(
name
=
"rest_point"
)
private
Integer
restPoint
;
@Column
(
name
=
"crt_time"
)
private
Long
crtTime
;
@Column
(
name
=
"upd_time"
)
private
Long
updTime
;
/**
* 是否删除:0-正常;1-删除
*/
private
Boolean
isdel
;
}
\ No newline at end of file
xx-activity/xx-activity-api/src/main/java/com/xxfc/platform/activity/
F
eign/ActivityFeign.java
→
xx-activity/xx-activity-api/src/main/java/com/xxfc/platform/activity/
f
eign/ActivityFeign.java
View file @
9b643891
package
com
.
xxfc
.
platform
.
activity
.
F
eign
;
package
com
.
xxfc
.
platform
.
activity
.
f
eign
;
import
com.github.wxiaoqi.security.common.msg.ObjectRestResponse
;
import
com.github.wxiaoqi.security.common.msg.ObjectRestResponse
;
import
com.xxfc.platform.activity.vo.UserCouponVo
;
import
com.xxfc.platform.activity.vo.UserCouponVo
;
...
...
xx-activity/xx-activity-api/src/main/java/com/xxfc/platform/activity/user/UserInfoBiz.java
0 → 100644
View file @
9b643891
package
com
.
xxfc
.
platform
.
activity
.
user
;
import
com.github.wxiaoqi.security.admin.feign.UserFeign
;
import
com.github.wxiaoqi.security.admin.feign.dto.AppUserDTO
;
import
lombok.extern.slf4j.Slf4j
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.stereotype.Component
;
import
org.springframework.web.context.request.RequestContextHolder
;
import
org.springframework.web.context.request.ServletRequestAttributes
;
import
javax.servlet.http.HttpServletRequest
;
@Slf4j
@Component
public
class
UserInfoBiz
{
@Autowired
UserFeign
userFeign
;
public
AppUserDTO
getUserInfo
()
{
HttpServletRequest
request
=
((
ServletRequestAttributes
)
RequestContextHolder
.
getRequestAttributes
()).
getRequest
();
if
(
request
.
getHeader
(
"Authorization"
)
!=
null
)
{
return
userFeign
.
userDetailByToken
(
request
.
getHeader
(
"Authorization"
)).
getData
();
}
else
if
(
request
.
getHeader
(
"access_token"
)
!=
null
)
{
return
userFeign
.
userDetailByToken
(
request
.
getHeader
(
"access_token"
)).
getData
();
}
return
null
;
}
}
xx-activity/xx-activity-server/src/main/java/com/xxfc/platform/activity/biz/IntegralRuleBiz.java
0 → 100644
View file @
9b643891
package
com
.
xxfc
.
platform
.
activity
.
biz
;
import
cn.hutool.core.bean.BeanUtil
;
import
cn.hutool.core.bean.copier.CopyOptions
;
import
com.github.wxiaoqi.security.common.biz.BaseBiz
;
import
com.github.wxiaoqi.security.common.msg.ObjectRestResponse
;
import
com.xxfc.platform.activity.entity.IntegralRule
;
import
com.xxfc.platform.activity.mapper.IntegralRuleMapper
;
import
org.springframework.stereotype.Service
;
import
org.springframework.transaction.annotation.Transactional
;
import
java.util.List
;
@Service
@Transactional
public
class
IntegralRuleBiz
extends
BaseBiz
<
IntegralRuleMapper
,
IntegralRule
>
{
/**
* 添加、更新积分规则
* @param integralRule
* @return
*/
public
ObjectRestResponse
add
(
IntegralRule
integralRule
)
{
if
(
integralRule
==
null
)
{
return
ObjectRestResponse
.
paramIsEmpty
();
}
if
(
integralRule
.
getId
()
!=
null
)
{
//已存在,更新
IntegralRule
oldValue
=
mapper
.
selectByPrimaryKey
(
integralRule
.
getId
());
if
(
oldValue
==
null
)
{
return
ObjectRestResponse
.
createDefaultFail
();
}
BeanUtil
.
copyProperties
(
integralRule
,
oldValue
,
CopyOptions
.
create
().
setIgnoreNullValue
(
true
).
setIgnoreError
(
true
));
mapper
.
updateByPrimaryKeySelective
(
oldValue
);
return
ObjectRestResponse
.
succ
();
}
mapper
.
insertSelective
(
integralRule
);
return
ObjectRestResponse
.
succ
();
}
/**
* 删除积分规则
* @param id
* @return
*/
public
ObjectRestResponse
deleteOne
(
Integer
id
)
{
if
(
id
==
null
||
id
<
0
)
{
return
ObjectRestResponse
.
paramIsEmpty
();
}
IntegralRule
oldValue
=
mapper
.
selectByPrimaryKey
(
id
);
if
(
oldValue
==
null
)
{
return
ObjectRestResponse
.
createDefaultFail
();
}
oldValue
.
setIsdel
(
true
);
mapper
.
updateByPrimaryKeySelective
(
oldValue
);
return
ObjectRestResponse
.
succ
();
}
public
ObjectRestResponse
<
IntegralRule
>
getOne
(
IntegralRule
integralRule
)
{
if
(
integralRule
==
null
)
{
return
ObjectRestResponse
.
paramIsEmpty
();
}
IntegralRule
oldValue
=
mapper
.
selectByPrimaryKey
(
integralRule
.
getId
());
if
(
oldValue
==
null
)
{
return
ObjectRestResponse
.
createDefaultFail
();
}
return
ObjectRestResponse
.
succ
(
oldValue
);
}
public
ObjectRestResponse
<
List
<
IntegralRule
>>
getAll
(
IntegralRule
integralRule
)
{
List
<
IntegralRule
>
integralRules
=
mapper
.
selectAllByParam
(
integralRule
);
return
ObjectRestResponse
.
succ
(
integralRules
);
}
}
xx-activity/xx-activity-server/src/main/java/com/xxfc/platform/activity/biz/IntegralSignRecordBiz.java
0 → 100644
View file @
9b643891
package
com
.
xxfc
.
platform
.
activity
.
biz
;
import
com.github.wxiaoqi.security.common.biz.BaseBiz
;
import
com.xxfc.platform.activity.entity.IntegralSignRecord
;
import
com.xxfc.platform.activity.mapper.IntegralSignRecordMapper
;
import
org.springframework.stereotype.Service
;
import
org.springframework.transaction.annotation.Transactional
;
@Service
@Transactional
public
class
IntegralSignRecordBiz
extends
BaseBiz
<
IntegralSignRecordMapper
,
IntegralSignRecord
>
{
}
xx-activity/xx-activity-server/src/main/java/com/xxfc/platform/activity/biz/IntegralUserRecordBiz.java
0 → 100644
View file @
9b643891
package
com
.
xxfc
.
platform
.
activity
.
biz
;
import
com.github.wxiaoqi.security.admin.feign.dto.AppUserDTO
;
import
com.github.wxiaoqi.security.common.biz.BaseBiz
;
import
com.github.wxiaoqi.security.common.msg.ObjectRestResponse
;
import
com.xxfc.platform.activity.entity.IntegralUserRecord
;
import
com.xxfc.platform.activity.mapper.IntegralUserRecordMapper
;
import
com.xxfc.platform.activity.user.UserInfoBiz
;
import
lombok.extern.slf4j.Slf4j
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.stereotype.Service
;
import
org.springframework.transaction.annotation.Transactional
;
@Service
@Transactional
@Slf4j
public
class
IntegralUserRecordBiz
extends
BaseBiz
<
IntegralUserRecordMapper
,
IntegralUserRecord
>
{
@Autowired
UserInfoBiz
userInfoBiz
;
/**
* 添加用户积分记录
* @param integralUserRecord
* @return
*/
public
ObjectRestResponse
add
(
IntegralUserRecord
integralUserRecord
)
{
return
ObjectRestResponse
.
succ
();
}
/**
* 删除一个用户记录
* @param id
* @return
*/
public
ObjectRestResponse
deleteOne
(
Integer
id
)
{
if
(
id
==
null
||
id
<=
0
)
{
return
ObjectRestResponse
.
paramIsEmpty
();
}
IntegralUserRecord
integralUserRecord
=
mapper
.
selectByPrimaryKey
(
id
);
if
(
integralUserRecord
==
null
)
{
log
.
info
(
"删除的用户记录不存在,要删除的id ={}"
,
id
);
return
ObjectRestResponse
.
createDefaultFail
();
}
integralUserRecord
.
setIsdel
(
true
);
mapper
.
updateByPrimaryKeySelective
(
integralUserRecord
);
return
ObjectRestResponse
.
succ
();
}
/**
* 根据获取某个用户的列表
* @return
*/
public
ObjectRestResponse
<
IntegralUserRecord
>
getUserList
()
{
AppUserDTO
appUserDTO
=
userInfoBiz
.
getUserInfo
();
if
(
appUserDTO
==
null
)
{
return
ObjectRestResponse
.
createFailedResult
(
508
,
"token is null or invalid"
);
}
return
ObjectRestResponse
.
succ
();
}
}
xx-activity/xx-activity-server/src/main/java/com/xxfc/platform/activity/biz/IntegralUserTotalBiz.java
0 → 100644
View file @
9b643891
package
com
.
xxfc
.
platform
.
activity
.
biz
;
import
cn.hutool.core.bean.BeanUtil
;
import
cn.hutool.core.bean.copier.CopyOptions
;
import
com.github.wxiaoqi.security.admin.feign.dto.AppUserDTO
;
import
com.github.wxiaoqi.security.common.biz.BaseBiz
;
import
com.github.wxiaoqi.security.common.msg.ObjectRestResponse
;
import
com.xxfc.platform.activity.entity.IntegralUserTotal
;
import
com.xxfc.platform.activity.mapper.IntegralUserTotalMapper
;
import
com.xxfc.platform.activity.user.UserInfoBiz
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.stereotype.Service
;
import
org.springframework.transaction.annotation.Transactional
;
import
java.util.List
;
@Service
@Transactional
public
class
IntegralUserTotalBiz
extends
BaseBiz
<
IntegralUserTotalMapper
,
IntegralUserTotal
>
{
@Autowired
UserInfoBiz
userInfoBiz
;
/**
* 添加用户总积分
* @param integralUserTotal
* @return
*/
public
ObjectRestResponse
add
(
IntegralUserTotal
integralUserTotal
)
{
AppUserDTO
appUserDTO
=
userInfoBiz
.
getUserInfo
();
if
(
appUserDTO
==
null
)
{
return
ObjectRestResponse
.
createFailedResult
(
508
,
"token is null or invalid"
);
}
if
(
integralUserTotal
==
null
)
{
return
ObjectRestResponse
.
paramIsEmpty
();
}
integralUserTotal
.
setUserId
(
appUserDTO
.
getUserid
());
if
(
integralUserTotal
.
getId
()
!=
null
)
{
IntegralUserTotal
oldValue
=
mapper
.
selectByPrimaryKey
(
integralUserTotal
.
getId
());
if
(
oldValue
==
null
)
{
return
ObjectRestResponse
.
createDefaultFail
();
}
BeanUtil
.
copyProperties
(
integralUserTotal
,
oldValue
,
CopyOptions
.
create
().
setIgnoreNullValue
(
true
).
setIgnoreError
(
true
));
mapper
.
updateByPrimaryKeySelective
(
oldValue
);
return
ObjectRestResponse
.
succ
();
}
mapper
.
insertSelective
(
integralUserTotal
);
return
ObjectRestResponse
.
succ
();
}
/**
* 删除信息
* @param id
* @return
*/
public
ObjectRestResponse
deleteOne
()
{
AppUserDTO
appUserDTO
=
userInfoBiz
.
getUserInfo
();
if
(
appUserDTO
==
null
)
{
return
ObjectRestResponse
.
createFailedResult
(
508
,
"token is null or invalid"
);
}
IntegralUserTotal
integralUserTotal
=
new
IntegralUserTotal
();
integralUserTotal
.
setUserId
(
appUserDTO
.
getUserid
());
List
<
IntegralUserTotal
>
oldValue
=
mapper
.
selectAllByParam
(
integralUserTotal
);
if
(
oldValue
==
null
||
oldValue
.
size
()
<=
0
)
{
return
ObjectRestResponse
.
createDefaultFail
();
}
oldValue
.
get
(
0
).
setIsdel
(
true
);
mapper
.
updateByPrimaryKeySelective
(
oldValue
.
get
(
0
));
return
ObjectRestResponse
.
succ
();
}
/**
* 获取某个用户的积分信息
* @return
*/
public
ObjectRestResponse
<
IntegralUserTotal
>
getByUser
()
{
AppUserDTO
appUserDTO
=
userInfoBiz
.
getUserInfo
();
if
(
appUserDTO
==
null
)
{
return
ObjectRestResponse
.
createFailedResult
(
508
,
"token is null or invalid"
);
}
IntegralUserTotal
integralUserTotal
=
new
IntegralUserTotal
();
integralUserTotal
.
setUserId
(
appUserDTO
.
getUserid
());
List
<
IntegralUserTotal
>
oldValue
=
mapper
.
selectAllByParam
(
integralUserTotal
);
if
(
oldValue
==
null
||
oldValue
.
size
()
<=
0
)
{
return
ObjectRestResponse
.
createDefaultFail
();
}
return
ObjectRestResponse
.
succ
(
oldValue
.
get
(
0
));
}
/**
* 获取所有的信息
* @param integralUserTotal
* @return
*/
public
ObjectRestResponse
<
List
<
IntegralUserTotal
>>
getAll
(
IntegralUserTotal
integralUserTotal
)
{
List
<
IntegralUserTotal
>
integralUserTotals
=
mapper
.
selectAllByParam
(
integralUserTotal
);
return
ObjectRestResponse
.
succ
(
integralUserTotals
);
}
}
xx-activity/xx-activity-server/src/main/java/com/xxfc/platform/activity/mapper/IntegralRuleMapper.java
0 → 100644
View file @
9b643891
package
com
.
xxfc
.
platform
.
activity
.
mapper
;
import
com.xxfc.platform.activity.entity.IntegralRule
;
import
tk.mybatis.mapper.common.Mapper
;
import
java.util.List
;
public
interface
IntegralRuleMapper
extends
Mapper
<
IntegralRule
>
{
public
List
<
IntegralRule
>
selectAllByParam
(
IntegralRule
integralRule
);
}
\ No newline at end of file
xx-activity/xx-activity-server/src/main/java/com/xxfc/platform/activity/mapper/IntegralSignRecordMapper.java
0 → 100644
View file @
9b643891
package
com
.
xxfc
.
platform
.
activity
.
mapper
;
import
com.xxfc.platform.activity.entity.IntegralSignRecord
;
import
tk.mybatis.mapper.common.Mapper
;
public
interface
IntegralSignRecordMapper
extends
Mapper
<
IntegralSignRecord
>
{
}
\ No newline at end of file
xx-activity/xx-activity-server/src/main/java/com/xxfc/platform/activity/mapper/IntegralUserRecordMapper.java
0 → 100644
View file @
9b643891
package
com
.
xxfc
.
platform
.
activity
.
mapper
;
import
com.xxfc.platform.activity.entity.IntegralUserRecord
;
import
tk.mybatis.mapper.common.Mapper
;
public
interface
IntegralUserRecordMapper
extends
Mapper
<
IntegralUserRecord
>
{
}
\ No newline at end of file
xx-activity/xx-activity-server/src/main/java/com/xxfc/platform/activity/mapper/IntegralUserTotalMapper.java
0 → 100644
View file @
9b643891
package
com
.
xxfc
.
platform
.
activity
.
mapper
;
import
com.xxfc.platform.activity.entity.IntegralUserTotal
;
import
tk.mybatis.mapper.common.Mapper
;
import
java.util.List
;
public
interface
IntegralUserTotalMapper
extends
Mapper
<
IntegralUserTotal
>
{
List
<
IntegralUserTotal
>
selectAllByParam
(
IntegralUserTotal
integralUserTotal
);
}
\ No newline at end of file
xx-activity/xx-activity-server/src/main/java/com/xxfc/platform/activity/rest/IntegralRuleController.java
0 → 100644
View file @
9b643891
package
com
.
xxfc
.
platform
.
activity
.
rest
;
import
com.github.wxiaoqi.security.common.msg.ObjectRestResponse
;
import
com.xxfc.platform.activity.biz.IntegralRuleBiz
;
import
com.xxfc.platform.activity.entity.IntegralRule
;
import
io.swagger.annotations.Api
;
import
io.swagger.annotations.ApiOperation
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.web.bind.annotation.GetMapping
;
import
org.springframework.web.bind.annotation.PostMapping
;
import
org.springframework.web.bind.annotation.RequestMapping
;
import
org.springframework.web.bind.annotation.RestController
;
import
java.util.List
;
@RestController
@RequestMapping
(
value
=
"integralRule"
)
@Api
(
value
=
"积分规则"
)
public
class
IntegralRuleController
{
@Autowired
IntegralRuleBiz
integralRuleBiz
;
@PostMapping
(
value
=
"/add"
)
@ApiOperation
(
value
=
"添加积分规则"
)
public
ObjectRestResponse
add
(
IntegralRule
integralRule
)
{
return
integralRuleBiz
.
add
(
integralRule
);
}
@PostMapping
(
value
=
"/delete"
)
@ApiOperation
(
value
=
"删除积分规则"
)
public
ObjectRestResponse
deleteOne
(
Integer
id
)
{
return
integralRuleBiz
.
deleteOne
(
id
);
}
@GetMapping
(
value
=
"/one"
)
@ApiOperation
(
value
=
"根据id获取制定规则"
)
public
ObjectRestResponse
<
IntegralRule
>
getOne
(
IntegralRule
integralRule
)
{
return
integralRuleBiz
.
getOne
(
integralRule
);
}
@GetMapping
(
value
=
"/list"
)
@ApiOperation
(
value
=
"获取所有的规则"
)
public
ObjectRestResponse
<
List
<
IntegralRule
>>
getList
(
IntegralRule
integralRule
)
{
return
integralRuleBiz
.
getAll
(
integralRule
);
}
}
xx-activity/xx-activity-server/src/main/java/com/xxfc/platform/activity/rest/IntegralSignRecordController.java
0 → 100644
View file @
9b643891
package
com
.
xxfc
.
platform
.
activity
.
rest
;
import
com.xxfc.platform.activity.biz.IntegralSignRecordBiz
;
import
io.swagger.annotations.Api
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.web.bind.annotation.RequestMapping
;
import
org.springframework.web.bind.annotation.RestController
;
@RestController
@RequestMapping
(
value
=
"integralSignRecord"
)
@Api
(
value
=
"用户签到记录"
)
public
class
IntegralSignRecordController
{
@Autowired
IntegralSignRecordBiz
integralSignRecordBiz
;
}
xx-activity/xx-activity-server/src/main/java/com/xxfc/platform/activity/rest/IntegralUserRecordController.java
0 → 100644
View file @
9b643891
package
com
.
xxfc
.
platform
.
activity
.
rest
;
import
com.xxfc.platform.activity.biz.IntegralUserRecordBiz
;
import
io.swagger.annotations.Api
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.web.bind.annotation.RequestMapping
;
import
org.springframework.web.bind.annotation.RestController
;
@RestController
@RequestMapping
(
value
=
"integralUserRecord"
)
@Api
(
value
=
"用户积分记录"
)
public
class
IntegralUserRecordController
{
@Autowired
IntegralUserRecordBiz
integralUserRecordBiz
;
}
xx-activity/xx-activity-server/src/main/java/com/xxfc/platform/activity/rest/IntegralUserTotalController.java
0 → 100644
View file @
9b643891
package
com
.
xxfc
.
platform
.
activity
.
rest
;
import
io.swagger.annotations.Api
;
import
org.springframework.web.bind.annotation.RequestMapping
;
import
org.springframework.web.bind.annotation.RestController
;
@RestController
@RequestMapping
(
value
=
"integralUserTotal"
)
@Api
(
value
=
"用户总积分"
)
public
class
IntegralUserTotalController
{
}
xx-activity/xx-activity-server/src/main/resources/mapper/IntegralRuleMapper.xml
0 → 100644
View file @
9b643891
<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd" >
<mapper
namespace=
"com.xxfc.platform.activity.mapper.IntegralRuleMapper"
>
<resultMap
id=
"BaseResultMap"
type=
"com.xxfc.platform.activity.entity.IntegralRule"
>
<!--
WARNING - @mbg.generated
-->
<id
column=
"id"
property=
"id"
jdbcType=
"INTEGER"
/>
<result
column=
"period"
property=
"period"
jdbcType=
"BIT"
/>
<result
column=
"number"
property=
"number"
jdbcType=
"INTEGER"
/>
<result
column=
"point"
property=
"point"
jdbcType=
"INTEGER"
/>
<result
column=
"price"
property=
"price"
jdbcType=
"DECIMAL"
/>
<result
column=
"is_continuity"
property=
"isContinuity"
jdbcType=
"BIT"
/>
<result
column=
"finish_day"
property=
"finishDay"
jdbcType=
"INTEGER"
/>
<result
column=
"finish_point"
property=
"finishPoint"
jdbcType=
"INTEGER"
/>
<result
column=
"status"
property=
"status"
jdbcType=
"BIT"
/>
<result
column=
"crt_time"
property=
"crtTime"
jdbcType=
"BIGINT"
/>
<result
column=
"isdel"
property=
"isdel"
jdbcType=
"BIT"
/>
<result
column=
"start_time"
property=
"startTime"
jdbcType=
"BIGINT"
/>
<result
column=
"end_time"
property=
"endTime"
jdbcType=
"BIGINT"
/>
<result
column=
"upd_time"
property=
"updTime"
jdbcType=
"BIGINT"
/>
<result
column=
"remarks"
property=
"remarks"
jdbcType=
"VARCHAR"
/>
<result
column=
"desc"
property=
"desc"
jdbcType=
"VARCHAR"
/>
<result
column=
"img"
property=
"img"
jdbcType=
"VARCHAR"
/>
<result
column=
"order_id"
property=
"orderId"
jdbcType=
"INTEGER"
/>
<result
column=
"name"
property=
"name"
jdbcType=
"VARCHAR"
/>
<result
column=
"regulation"
property=
"regulation"
jdbcType=
"LONGVARCHAR"
/>
<result
column=
"other_rule"
property=
"otherRule"
jdbcType=
"LONGVARCHAR"
/>
</resultMap>
<select
id=
"selectAllByParam"
resultType=
"com.xxfc.platform.activity.entity.IntegralRule"
parameterType=
"com.xxfc.platform.activity.entity.IntegralRule"
>
select * from integral_rule
<where>
<if
test=
"id != null"
>
and id = #{id}
</if>
<if
test=
"name != null"
>
and name like concat("%", #{name}, "%")
</if>
</where>
order by order_id DESC ,crt_time DESC
</select>
</mapper>
\ No newline at end of file
xx-activity/xx-activity-server/src/main/resources/mapper/IntegralSignRecordMapper.xml
0 → 100644
View file @
9b643891
<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd" >
<mapper
namespace=
"com.xxfc.platform.activity.mapper.IntegralSignRecordMapper"
>
<resultMap
id=
"BaseResultMap"
type=
"com.xxfc.platform.activity.entity.IntegralSignRecord"
>
<!--
WARNING - @mbg.generated
-->
<id
column=
"id"
property=
"id"
jdbcType=
"INTEGER"
/>
<result
column=
"user_id"
property=
"userId"
jdbcType=
"INTEGER"
/>
<result
column=
"sign_days"
property=
"signDays"
jdbcType=
"INTEGER"
/>
<result
column=
"start_time"
property=
"startTime"
jdbcType=
"BIGINT"
/>
<result
column=
"last_time"
property=
"lastTime"
jdbcType=
"BIGINT"
/>
</resultMap>
</mapper>
\ No newline at end of file
xx-activity/xx-activity-server/src/main/resources/mapper/IntegralUserRecordMapper.xml
0 → 100644
View file @
9b643891
<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd" >
<mapper
namespace=
"com.xxfc.platform.activity.mapper.IntegralUserRecordMapper"
>
<resultMap
id=
"BaseResultMap"
type=
"com.xxfc.platform.activity.entity.IntegralUserRecord"
>
<!--
WARNING - @mbg.generated
-->
<id
column=
"id"
property=
"id"
jdbcType=
"INTEGER"
/>
<result
column=
"user_id"
property=
"userId"
jdbcType=
"INTEGER"
/>
<result
column=
"type"
property=
"type"
jdbcType=
"BIT"
/>
<result
column=
"point"
property=
"point"
jdbcType=
"INTEGER"
/>
<result
column=
"integral_rule_id"
property=
"integralRuleId"
jdbcType=
"INTEGER"
/>
<result
column=
"crt_time"
property=
"crtTime"
jdbcType=
"BIGINT"
/>
<result
column=
"is_valid"
property=
"isValid"
jdbcType=
"BIT"
/>
<result
column=
"isdel"
property=
"isdel"
jdbcType=
"BIT"
/>
<result
column=
"channel_id"
property=
"channelId"
jdbcType=
"INTEGER"
/>
</resultMap>
</mapper>
\ No newline at end of file
xx-activity/xx-activity-server/src/main/resources/mapper/IntegralUserTotalMapper.xml
0 → 100644
View file @
9b643891
<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd" >
<mapper
namespace=
"com.xxfc.platform.activity.mapper.IntegralUserTotalMapper"
>
<resultMap
id=
"BaseResultMap"
type=
"com.xxfc.platform.activity.entity.IntegralUserTotal"
>
<!--
WARNING - @mbg.generated
-->
<id
column=
"id"
property=
"id"
jdbcType=
"INTEGER"
/>
<result
column=
"user_id"
property=
"userId"
jdbcType=
"INTEGER"
/>
<result
column=
"total_point"
property=
"totalPoint"
jdbcType=
"INTEGER"
/>
<result
column=
"rest_point"
property=
"restPoint"
jdbcType=
"INTEGER"
/>
<result
column=
"crt_time"
property=
"crtTime"
jdbcType=
"BIGINT"
/>
<result
column=
"upd_time"
property=
"updTime"
jdbcType=
"BIGINT"
/>
</resultMap>
<select
id=
"selectAllByParam"
parameterType=
"com.xxfc.platform.activity.entity.IntegralUserTotal"
resultType=
"com.xxfc.platform.activity.entity.IntegralUserTotal"
>
select * from integral_user_total
<where>
<if
test=
"userId != null"
>
and user_id = #{userId}
</if>
</where>
order by upd_time DESC
</select>
</mapper>
\ No newline at end of file
xx-order/xx-order-server/src/main/java/com/xxfc/platform/order/rest/BaseOrderController.java
View file @
9b643891
...
@@ -121,6 +121,7 @@ public class BaseOrderController extends CommonBaseController {
...
@@ -121,6 +121,7 @@ public class BaseOrderController extends CommonBaseController {
@ResponseBody
@ResponseBody
@ApiOperation
(
value
=
"获取后台订单列表"
)
@ApiOperation
(
value
=
"获取后台订单列表"
)
@IgnoreClientToken
@IgnoreClientToken
@CrossOrigin
public
ObjectRestResponse
<
PageDataVO
<
OrderPageVO
>>
selectByUser
(
QueryOrderList
dto
)
{
public
ObjectRestResponse
<
PageDataVO
<
OrderPageVO
>>
selectByUser
(
QueryOrderList
dto
)
{
if
(
dto
.
getStartTime
()
!=
null
)
{
if
(
dto
.
getStartTime
()
!=
null
)
{
if
(
dto
.
getEndTime
()
==
null
)
{
if
(
dto
.
getEndTime
()
==
null
)
{
...
...
xx-vehicle/xx-vehicle-server/src/main/java/com/xxfc/platform/vehicle/rest/VehicleLicenseController.java
View file @
9b643891
...
@@ -2,6 +2,7 @@ package com.xxfc.platform.vehicle.rest;
...
@@ -2,6 +2,7 @@ package com.xxfc.platform.vehicle.rest;
import
com.github.wxiaoqi.security.admin.feign.dto.AppUserDTO
;
import
com.github.wxiaoqi.security.admin.feign.dto.AppUserDTO
;
import
com.github.wxiaoqi.security.auth.client.annotation.IgnoreClientToken
;
import
com.github.wxiaoqi.security.auth.client.annotation.IgnoreClientToken
;
import
com.github.wxiaoqi.security.auth.client.annotation.IgnoreUserToken
;
import
com.github.wxiaoqi.security.common.msg.ObjectRestResponse
;
import
com.github.wxiaoqi.security.common.msg.ObjectRestResponse
;
import
com.xxfc.platform.vehicle.biz.VehicleLicenseBiz
;
import
com.xxfc.platform.vehicle.biz.VehicleLicenseBiz
;
import
com.xxfc.platform.vehicle.common.RestResponse
;
import
com.xxfc.platform.vehicle.common.RestResponse
;
...
@@ -60,6 +61,8 @@ public class VehicleLicenseController extends VehicleBaseController<VehicleLicen
...
@@ -60,6 +61,8 @@ public class VehicleLicenseController extends VehicleBaseController<VehicleLicen
return
RestResponse
.
suc
(
baseBiz
.
getOneById
(
id
));
return
RestResponse
.
suc
(
baseBiz
.
getOneById
(
id
));
}
}
@RequestMapping
(
value
=
"/license/company/getOne"
,
method
=
RequestMethod
.
GET
)
@RequestMapping
(
value
=
"/license/company/getOne"
,
method
=
RequestMethod
.
GET
)
@IgnoreUserToken
@IgnoreClientToken
public
RestResponse
<
VehicleUserLicense
>
getOne
(
public
RestResponse
<
VehicleUserLicense
>
getOne
(
@RequestParam
(
value
=
"id"
,
defaultValue
=
"0"
)
Integer
id
)
throws
Exception
{
@RequestParam
(
value
=
"id"
,
defaultValue
=
"0"
)
Integer
id
)
throws
Exception
{
return
RestResponse
.
suc
(
baseBiz
.
getOneById
(
id
));
return
RestResponse
.
suc
(
baseBiz
.
getOneById
(
id
));
...
...
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