Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in / Register
Toggle navigation
D
data-server
Project
Project
Details
Activity
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
licc
data-server
Commits
aed47833
Commit
aed47833
authored
Mar 12, 2021
by
liqin
💬
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'master' of
http://111.203.232.171:8888/licc/shop-mall
into master
parents
c1806b24
b79d3b12
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
23 additions
and
18 deletions
+23
-18
AccountManager.java
...ain/java/cn/wisenergy/service/Manager/AccountManager.java
+1
-1
AccountServiceImpl.java
...ava/cn/wisenergy/service/app/impl/AccountServiceImpl.java
+10
-5
UserLevelServiceImpl.java
...a/cn/wisenergy/service/app/impl/UserLevelServiceImpl.java
+12
-12
No files found.
wisenergy-service/src/main/java/cn/wisenergy/service/Manager/AccountManager.java
View file @
aed47833
...
...
@@ -232,7 +232,7 @@ public class AccountManager {
//更新月收益
if
(!
CollectionUtils
.
isEmpty
(
accountInfoList
))
{
for
(
AccountInfo
accountInfo
:
accountInfoList
)
{
int
count
=
accountMapper
.
updateById
(
accountInfo
);
int
count
=
accountMapper
.
edit
(
accountInfo
);
if
(
count
==
0
)
{
return
false
;
}
...
...
wisenergy-service/src/main/java/cn/wisenergy/service/app/impl/AccountServiceImpl.java
View file @
aed47833
...
...
@@ -159,7 +159,13 @@ public class AccountServiceImpl extends ServiceImpl<AccountMapper, AccountInfo>
String
userId
=
entity
.
getKey
();
//1)、统计当前用户月度业绩
double
userCount
=
entity
.
getValue
();
tempMap
.
put
(
userId
,
userCount
);
if
(
tempMap
.
containsKey
(
entity
.
getKey
()))
{
double
teamMoney
=
userCount
+
tempMap
.
get
(
entity
.
getKey
());
tempMap
.
put
(
entity
.
getKey
(),
teamMoney
);
}
else
{
//key 不存在,加入集合 当前用户团队绩效
tempMap
.
put
(
entity
.
getKey
(),
userCount
);
}
//2)、获取当前用户的上级用户列表
List
<
User
>
userList
=
getByList
(
userId
);
...
...
@@ -171,11 +177,11 @@ public class AccountServiceImpl extends ServiceImpl<AccountMapper, AccountInfo>
//3)、统计当前用户的上级用户团队绩效
//key 存在 当前用户团队绩效 + 上级用户团队绩效
if
(
tempMap
.
containsKey
(
userInfo
.
getUserId
()))
{
double
teamMoney
=
userCount
+
m
ap
.
get
(
userInfo
.
getUserId
());
m
ap
.
put
(
userInfo
.
getUserId
(),
teamMoney
);
double
teamMoney
=
userCount
+
tempM
ap
.
get
(
userInfo
.
getUserId
());
tempM
ap
.
put
(
userInfo
.
getUserId
(),
teamMoney
);
}
else
{
//key 不存在,加入集合 当前用户团队绩效
m
ap
.
put
(
userInfo
.
getUserId
(),
userCount
);
tempM
ap
.
put
(
userInfo
.
getUserId
(),
userCount
);
}
}
}
...
...
@@ -196,7 +202,6 @@ public class AccountServiceImpl extends ServiceImpl<AccountMapper, AccountInfo>
performance
.
setMonthTeamPerformance
(
BigDecimal
.
valueOf
(
entity
.
getValue
()));
performance
.
setUserLevel
(
user
.
getUserLevel
());
performance
.
setYearMonth
(
yearMonth
);
teamPerformanceMapper
.
add
(
performance
);
addList
.
add
(
performance
);
}
else
{
teamPerformance
.
setMonthTeamPerformance
(
BigDecimal
.
valueOf
(
entity
.
getValue
()));
...
...
wisenergy-service/src/main/java/cn/wisenergy/service/app/impl/UserLevelServiceImpl.java
View file @
aed47833
...
...
@@ -607,7 +607,7 @@ public class UserLevelServiceImpl extends ServiceImpl<UsersMapper,User> implemen
BigDecimal
cultivatingPrize
=
cultivatingPrizeMapper
.
getcultivatingPrizeByUserLevel
(
level
).
getCultivatingPrize
();
if
(
1
!=
bronzeTree
)
{
//给上级用户
幼苗
等级培育奖
//给上级用户
青铜
等级培育奖
//1.上级用户本月收益 ++
AccountInfo
beIntivedUserAccount
=
accountMapper
.
getByUserId
(
inviteUserId
);
BigDecimal
earningsMonth
=
beIntivedUserAccount
.
getEarningsMonth
();
...
...
@@ -627,7 +627,7 @@ public class UserLevelServiceImpl extends ServiceImpl<UsersMapper,User> implemen
//3.修改培育奖记录状态 ==1
bronzeTree
=
1
;
cultivatingPrizeInfo
.
set
Seedling
(
bronzeTree
);
cultivatingPrizeInfo
.
set
BronzeTree
(
bronzeTree
);
cultivatingPrizeInfoMapper
.
updateById
(
cultivatingPrizeInfo
);
}
}
else
if
(
3
==
level
)
{
...
...
@@ -636,7 +636,7 @@ public class UserLevelServiceImpl extends ServiceImpl<UsersMapper,User> implemen
BigDecimal
cultivatingPrize
=
cultivatingPrizeMapper
.
getcultivatingPrizeByUserLevel
(
level
).
getCultivatingPrize
();
if
(
1
!=
silverTree
)
{
//给上级用户
幼苗
等级培育奖
//给上级用户
白银
等级培育奖
//1.上级用户本月收益 ++
AccountInfo
beIntivedUserAccount
=
accountMapper
.
getByUserId
(
inviteUserId
);
BigDecimal
earningsMonth
=
beIntivedUserAccount
.
getEarningsMonth
();
...
...
@@ -656,7 +656,7 @@ public class UserLevelServiceImpl extends ServiceImpl<UsersMapper,User> implemen
//3.修改培育奖记录状态 ==1
silverTree
=
1
;
cultivatingPrizeInfo
.
setS
eedling
(
silverTree
);
cultivatingPrizeInfo
.
setS
ilverTree
(
silverTree
);
cultivatingPrizeInfoMapper
.
updateById
(
cultivatingPrizeInfo
);
}
}
else
if
(
4
==
level
)
{
...
...
@@ -665,7 +665,7 @@ public class UserLevelServiceImpl extends ServiceImpl<UsersMapper,User> implemen
BigDecimal
cultivatingPrize
=
cultivatingPrizeMapper
.
getcultivatingPrizeByUserLevel
(
level
).
getCultivatingPrize
();
if
(
1
!=
goldTree
)
{
//给上级用户
幼苗
等级培育奖
//给上级用户
黄金
等级培育奖
//1.上级用户本月收益 ++
AccountInfo
beIntivedUserAccount
=
accountMapper
.
getByUserId
(
inviteUserId
);
BigDecimal
earningsMonth
=
beIntivedUserAccount
.
getEarningsMonth
();
...
...
@@ -685,7 +685,7 @@ public class UserLevelServiceImpl extends ServiceImpl<UsersMapper,User> implemen
//3.修改培育奖记录状态 ==1
goldTree
=
1
;
cultivatingPrizeInfo
.
set
Seedling
(
goldTree
);
cultivatingPrizeInfo
.
set
GoldTree
(
goldTree
);
cultivatingPrizeInfoMapper
.
updateById
(
cultivatingPrizeInfo
);
}
}
else
if
(
5
==
level
)
{
...
...
@@ -694,7 +694,7 @@ public class UserLevelServiceImpl extends ServiceImpl<UsersMapper,User> implemen
BigDecimal
cultivatingPrize
=
cultivatingPrizeMapper
.
getcultivatingPrizeByUserLevel
(
level
).
getCultivatingPrize
();
if
(
1
!=
farmer
)
{
//给上级用户
幼苗
等级培育奖
//给上级用户
农场主
等级培育奖
//1.上级用户本月收益 ++
AccountInfo
beIntivedUserAccount
=
accountMapper
.
getByUserId
(
inviteUserId
);
BigDecimal
earningsMonth
=
beIntivedUserAccount
.
getEarningsMonth
();
...
...
@@ -714,7 +714,7 @@ public class UserLevelServiceImpl extends ServiceImpl<UsersMapper,User> implemen
//3.修改培育奖记录状态 ==1
farmer
=
1
;
cultivatingPrizeInfo
.
set
Seedling
(
farmer
);
cultivatingPrizeInfo
.
set
Farmer
(
farmer
);
cultivatingPrizeInfoMapper
.
updateById
(
cultivatingPrizeInfo
);
}
}
else
if
(
6
==
level
)
{
...
...
@@ -723,7 +723,7 @@ public class UserLevelServiceImpl extends ServiceImpl<UsersMapper,User> implemen
BigDecimal
cultivatingPrize
=
cultivatingPrizeMapper
.
getcultivatingPrizeByUserLevel
(
level
).
getCultivatingPrize
();
if
(
1
!=
forestStart
)
{
//给上级用户
幼苗
等级培育奖
//给上级用户
森林之星
等级培育奖
//1.上级用户本月收益 ++
AccountInfo
beIntivedUserAccount
=
accountMapper
.
getByUserId
(
inviteUserId
);
BigDecimal
earningsMonth
=
beIntivedUserAccount
.
getEarningsMonth
();
...
...
@@ -743,7 +743,7 @@ public class UserLevelServiceImpl extends ServiceImpl<UsersMapper,User> implemen
//3.修改培育奖记录状态 ==1
forestStart
=
1
;
cultivatingPrizeInfo
.
set
Seedling
(
forestStart
);
cultivatingPrizeInfo
.
set
ForestStart
(
forestStart
);
cultivatingPrizeInfoMapper
.
updateById
(
cultivatingPrizeInfo
);
}
}
else
if
(
7
==
level
)
{
...
...
@@ -752,7 +752,7 @@ public class UserLevelServiceImpl extends ServiceImpl<UsersMapper,User> implemen
BigDecimal
cultivatingPrize
=
cultivatingPrizeMapper
.
getcultivatingPrizeByUserLevel
(
level
).
getCultivatingPrize
();
if
(
1
!=
partner
)
{
//给上级用户
幼苗
等级培育奖
//给上级用户
西田森合伙人
等级培育奖
//1.上级用户本月收益 ++
AccountInfo
beIntivedUserAccount
=
accountMapper
.
getByUserId
(
inviteUserId
);
BigDecimal
earningsMonth
=
beIntivedUserAccount
.
getEarningsMonth
();
...
...
@@ -772,7 +772,7 @@ public class UserLevelServiceImpl extends ServiceImpl<UsersMapper,User> implemen
//3.修改培育奖记录状态 ==1
partner
=
1
;
cultivatingPrizeInfo
.
set
Seedling
(
partner
);
cultivatingPrizeInfo
.
set
Partner
(
partner
);
cultivatingPrizeInfoMapper
.
updateById
(
cultivatingPrizeInfo
);
}
}
...
...
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