Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Contribute to GitLab
Sign in / Register
Toggle navigation
D
dsk-operate-sys-cscec
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
fulixin
dsk-operate-sys-cscec
Commits
46c4cb04
Commit
46c4cb04
authored
Dec 12, 2023
by
lcl
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
u
parent
8647c2fb
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
26 additions
and
0 deletions
+26
-0
DCustomer.java
...biz-api/src/main/java/com/dsk/cscec/domain/DCustomer.java
+5
-0
DCustomerServiceImpl.java
...java/com/dsk/cscec/service/impl/DCustomerServiceImpl.java
+21
-0
No files found.
dsk-module/dsk-biz-api/src/main/java/com/dsk/cscec/domain/DCustomer.java
View file @
46c4cb04
...
@@ -541,5 +541,10 @@ public class DCustomer implements Serializable {
...
@@ -541,5 +541,10 @@ public class DCustomer implements Serializable {
*/
*/
@TableField
(
exist
=
false
)
@TableField
(
exist
=
false
)
private
Integer
projectCooperationCount
;
private
Integer
projectCooperationCount
;
/**
* jsk企业id
*/
@TableField
(
exist
=
false
)
private
Integer
companyId
;
}
}
dsk-module/dsk-biz-api/src/main/java/com/dsk/cscec/service/impl/DCustomerServiceImpl.java
View file @
46c4cb04
package
com
.
dsk
.
cscec
.
service
.
impl
;
package
com
.
dsk
.
cscec
.
service
.
impl
;
import
cn.hutool.core.bean.BeanUtil
;
import
cn.hutool.core.map.MapUtil
;
import
cn.hutool.core.util.ObjectUtil
;
import
com.baomidou.mybatisplus.core.toolkit.CollectionUtils
;
import
com.baomidou.mybatisplus.core.toolkit.CollectionUtils
;
import
com.baomidou.mybatisplus.extension.plugins.pagination.Page
;
import
com.baomidou.mybatisplus.extension.plugins.pagination.Page
;
import
com.baomidou.mybatisplus.extension.service.impl.ServiceImpl
;
import
com.baomidou.mybatisplus.extension.service.impl.ServiceImpl
;
...
@@ -10,12 +13,17 @@ import com.dsk.cscec.mapper.DCustomerMapper;
...
@@ -10,12 +13,17 @@ import com.dsk.cscec.mapper.DCustomerMapper;
import
com.dsk.cscec.domain.DCustomer
;
import
com.dsk.cscec.domain.DCustomer
;
import
com.dsk.cscec.mapper.DSubcontractMapper
;
import
com.dsk.cscec.mapper.DSubcontractMapper
;
import
com.dsk.cscec.service.IDCustomerService
;
import
com.dsk.cscec.service.IDCustomerService
;
import
com.dsk.search.service.BusinessOpportunityRadarService
;
import
lombok.extern.slf4j.Slf4j
;
import
org.springdoc.core.converters.models.PageableAsQueryParam
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.stereotype.Service
;
import
org.springframework.stereotype.Service
;
import
org.springframework.util.ObjectUtils
;
import
org.springframework.util.ObjectUtils
;
import
javax.annotation.Resource
;
import
javax.annotation.Resource
;
import
java.util.ArrayList
;
import
java.util.ArrayList
;
import
java.util.List
;
import
java.util.List
;
import
java.util.Map
;
/**
/**
* 组织维表(DCustomer)表服务实现类
* 组织维表(DCustomer)表服务实现类
...
@@ -23,11 +31,14 @@ import java.util.List;
...
@@ -23,11 +31,14 @@ import java.util.List;
* @author lcl
* @author lcl
* @since 2023-12-08 14:57:26
* @since 2023-12-08 14:57:26
*/
*/
@Slf4j
@Service
@Service
public
class
DCustomerServiceImpl
extends
ServiceImpl
<
DCustomerMapper
,
DCustomer
>
implements
IDCustomerService
{
public
class
DCustomerServiceImpl
extends
ServiceImpl
<
DCustomerMapper
,
DCustomer
>
implements
IDCustomerService
{
@Resource
@Resource
private
DSubcontractMapper
subcontractMapper
;
private
DSubcontractMapper
subcontractMapper
;
@Autowired
private
BusinessOpportunityRadarService
opportunityRadarService
;
@Override
@Override
public
TableDataInfo
<
DCustomer
>
allSearchList
(
DCustomerSearchBo
bo
,
PageQuery
query
)
{
public
TableDataInfo
<
DCustomer
>
allSearchList
(
DCustomerSearchBo
bo
,
PageQuery
query
)
{
...
@@ -39,6 +50,16 @@ public class DCustomerServiceImpl extends ServiceImpl<DCustomerMapper, DCustomer
...
@@ -39,6 +50,16 @@ public class DCustomerServiceImpl extends ServiceImpl<DCustomerMapper, DCustomer
customer
.
setEnterpriseCooperationCount
(
subcontractMapper
.
selectEnterpriseCountByCustomerId
(
customer
.
getCustomerId
()));
customer
.
setEnterpriseCooperationCount
(
subcontractMapper
.
selectEnterpriseCountByCustomerId
(
customer
.
getCustomerId
()));
//项目合作数量
//项目合作数量
customer
.
setProjectCooperationCount
(
subcontractMapper
.
selectProjectCountByCustomerId
(
customer
.
getCustomerId
()));
customer
.
setProjectCooperationCount
(
subcontractMapper
.
selectProjectCountByCustomerId
(
customer
.
getCustomerId
()));
try
{
Map
<
String
,
Object
>
map
=
opportunityRadarService
.
enterpriseByName
(
customer
.
getCustomerName
());
if
(!
ObjectUtils
.
isEmpty
(
map
.
get
(
"data"
)))
{
Map
<
String
,
Object
>
data
=
BeanUtil
.
beanToMap
(
map
.
get
(
"data"
));
Integer
companyId
=
MapUtil
.
getInt
(
data
,
"jskEid"
);
customer
.
setCompanyId
(
companyId
);
}
}
catch
(
Exception
e
){
//
}
}
}
}
}
return
TableDataInfo
.
build
(
page
);
return
TableDataInfo
.
build
(
page
);
...
...
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