Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
8
8timerapiv200
Overview
Overview
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
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
8timerv2
8timerapiv200
Commits
0bf4ba3e
Commit
0bf4ba3e
authored
Jun 11, 2020
by
dengshichuan
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'dsc' into 'develop'
Dsc See merge request 8timerv2/8timerapiv200!168
parents
9c91041f
42e860c0
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
11 additions
and
5 deletions
+11
-5
src/main/java/cn/timer/api/controller/crm/CrmController.java
+11
-5
No files found.
src/main/java/cn/timer/api/controller/crm/CrmController.java
View file @
0bf4ba3e
...
@@ -8,6 +8,8 @@
...
@@ -8,6 +8,8 @@
package
cn
.
timer
.
api
.
controller
.
crm
;
package
cn
.
timer
.
api
.
controller
.
crm
;
import
java.util.ArrayList
;
import
java.util.ArrayList
;
import
java.util.Collections
;
import
java.util.Comparator
;
import
java.util.Date
;
import
java.util.Date
;
import
java.util.HashMap
;
import
java.util.HashMap
;
import
java.util.List
;
import
java.util.List
;
...
@@ -426,6 +428,7 @@ public class CrmController {
...
@@ -426,6 +428,7 @@ public class CrmController {
.
eq
(
status
!=
null
&&
status
>=
0
,
CrmClientData:
:
getClientStatus
,
status
)
.
eq
(
status
!=
null
&&
status
>=
0
,
CrmClientData:
:
getClientStatus
,
status
)
.
like
(!
StrUtil
.
isBlank
(
like
),
CrmClientData:
:
getClientName
,
like
).
or
()
.
like
(!
StrUtil
.
isBlank
(
like
),
CrmClientData:
:
getClientName
,
like
).
or
()
.
like
(!
StrUtil
.
isBlank
(
like
),
CrmClientData:
:
getClientCellphone
,
like
));
.
like
(!
StrUtil
.
isBlank
(
like
),
CrmClientData:
:
getClientCellphone
,
like
));
if
(
crmClientData
!=
null
)
myCrmClientAssociates
.
add
(
crmClientData
);
myCrmClientAssociates
.
add
(
crmClientData
);
}
}
return
myCrmClientAssociates
;
return
myCrmClientAssociates
;
...
@@ -462,10 +465,11 @@ public class CrmController {
...
@@ -462,10 +465,11 @@ public class CrmController {
Integer
empNum
=
getEmpNum
(
userBean
);
Integer
empNum
=
getEmpNum
(
userBean
);
Integer
orgCode
=
getOrgCode
(
userBean
);
Integer
orgCode
=
getOrgCode
(
userBean
);
List
<
CrmClientData
>
crmClientDatas
=
null
;
List
<
CrmClientData
>
crmClientDatas
=
null
;
if
(
type
==
null
||
type
==
0
)
// 全部客户(去重)
if
(
type
==
null
||
type
==
0
)
{
// 全部客户(去重)
crmClientDatas
=
CheckUtil
.
distinct
(
getMyCilent
(
empNum
,
orgCode
,
groupId
,
status
,
like
),
List
<
CrmClientData
>
myClient
=
getMyCilent
(
empNum
,
orgCode
,
groupId
,
status
,
like
);
getMyAssociateCilent
(
empNum
,
orgCode
,
groupId
,
status
,
like
),
true
);
List
<
CrmClientData
>
myAsso
=
getMyAssociateCilent
(
empNum
,
orgCode
,
groupId
,
status
,
like
);
else
if
(
type
==
1
)
// 我负责的客户
crmClientDatas
=
CheckUtil
.
distinct
(
myClient
,
myAsso
,
true
);
}
else
if
(
type
==
1
)
// 我负责的客户
crmClientDatas
=
getMyCilent
(
empNum
,
orgCode
,
groupId
,
status
,
like
);
crmClientDatas
=
getMyCilent
(
empNum
,
orgCode
,
groupId
,
status
,
like
);
else
if
(
type
==
2
)
// 我协作的客户
else
if
(
type
==
2
)
// 我协作的客户
crmClientDatas
=
getMyAssociateCilent
(
empNum
,
orgCode
,
groupId
,
status
,
like
);
crmClientDatas
=
getMyAssociateCilent
(
empNum
,
orgCode
,
groupId
,
status
,
like
);
...
@@ -476,7 +480,7 @@ public class CrmController {
...
@@ -476,7 +480,7 @@ public class CrmController {
else
else
return
ResultUtil
.
error
(
"查询失败"
);
return
ResultUtil
.
error
(
"查询失败"
);
// TODO 排序
// TODO 排序
//
Collections.sort(crmClientDatas, Comparator.comparing(CrmClientData::getCreateTime).reversed()); // 按时间降序排序
Collections
.
sort
(
crmClientDatas
,
Comparator
.
comparing
(
CrmClientData:
:
getCreateTime
).
reversed
());
// 按时间降序排序
return
ResultUtil
.
data
(
crmClientDatas
,
"查询成功"
);
return
ResultUtil
.
data
(
crmClientDatas
,
"查询成功"
);
}
}
...
@@ -986,4 +990,6 @@ public class CrmController {
...
@@ -986,4 +990,6 @@ public class CrmController {
return
map
;
return
map
;
}
}
// TODO 导入客户
}
}
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