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
fa04140e
Commit
fa04140e
authored
Dec 19, 2023
by
chenyuefang
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
供应商合作记录
parent
bb685066
Changes
7
Show whitespace changes
Inline
Side-by-side
Showing
7 changed files
with
196 additions
and
1 deletion
+196
-1
CustomerInfoController.java
...java/com/dsk/cscec/controller/CustomerInfoController.java
+13
-1
CustomerCooperationBo.java
...n/java/com/dsk/cscec/domain/bo/CustomerCooperationBo.java
+44
-0
CustomerCooperationVo.java
...n/java/com/dsk/cscec/domain/vo/CustomerCooperationVo.java
+73
-0
DSubcontractMapper.java
...rc/main/java/com/dsk/cscec/mapper/DSubcontractMapper.java
+12
-0
ICustomerInfoService.java
...main/java/com/dsk/cscec/service/ICustomerInfoService.java
+10
-0
CustomerInfoServiceImpl.java
...a/com/dsk/cscec/service/impl/CustomerInfoServiceImpl.java
+15
-0
DSubcontractMapper.xml
...pi/src/main/resources/mapper/cscec/DSubcontractMapper.xml
+29
-0
No files found.
dsk-module/dsk-biz-api/src/main/java/com/dsk/cscec/controller/CustomerInfoController.java
View file @
fa04140e
...
...
@@ -7,9 +7,11 @@ import com.dsk.common.core.domain.R;
import
com.dsk.common.core.page.TableDataInfo
;
import
com.dsk.common.utils.poi.ExcelUtil
;
import
com.dsk.cscec.domain.bo.AdvisoryBodyBo
;
import
com.dsk.cscec.domain.bo.CustomerCooperationBo
;
import
com.dsk.cscec.domain.bo.CustomerInfoBo
;
import
com.dsk.cscec.domain.vo.AdvisoryBodyVo
;
import
com.dsk.cscec.domain.vo.CustomerApproveVo
;
import
com.dsk.cscec.domain.vo.CustomerCooperationVo
;
import
com.dsk.cscec.domain.vo.CustomerInfoVo
;
import
com.dsk.cscec.service.ICustomerInfoService
;
import
lombok.RequiredArgsConstructor
;
...
...
@@ -63,10 +65,20 @@ public class CustomerInfoController extends BaseController {
/**
* 合作记录-供应商准入情况
*/
@GetMapping
(
"/
getA
pproveInfo"
)
@GetMapping
(
"/
a
pproveInfo"
)
public
R
<
CustomerApproveVo
>
getApproveInfo
(
CustomerInfoBo
bo
)
{
return
R
.
ok
(
iCustomerInfoService
.
queryApproveByBo
(
bo
));
}
/**
* 内部合作-供应商合作记录
*/
@GetMapping
(
"/cooperationList"
)
public
TableDataInfo
<
CustomerCooperationVo
>
cooperationList
(
@Validated
CustomerCooperationBo
bo
,
PageQuery
query
)
{
return
iCustomerInfoService
.
queryCooperationList
(
bo
,
query
);
}
}
dsk-module/dsk-biz-api/src/main/java/com/dsk/cscec/domain/bo/CustomerCooperationBo.java
0 → 100644
View file @
fa04140e
package
com
.
dsk
.
cscec
.
domain
.
bo
;
import
lombok.Data
;
import
java.util.List
;
/**
* 供应商合作记录
*
* @author
* @since 2023-12-18
*/
@Data
public
class
CustomerCooperationBo
{
/**
* 签订单位ID
*/
private
String
signOrgId
;
/**
* 签订单位名称
*/
private
String
signOrgName
;
/**
* 供应商ID
*/
private
String
customerId
;
/**
* 供应商名称
*/
private
String
customerName
;
/**
* 区域名称
*/
private
List
<
String
>
areaName
;
/**
* 省份名称
*/
private
List
<
String
>
provinceName
;
/**
* 城市名称
*/
private
List
<
String
>
cityName
;
}
dsk-module/dsk-biz-api/src/main/java/com/dsk/cscec/domain/vo/CustomerCooperationVo.java
0 → 100644
View file @
fa04140e
package
com
.
dsk
.
cscec
.
domain
.
vo
;
import
lombok.Data
;
/**
* 供应商合作记录
*
* @author
* @since 2023-12-18
*/
@Data
public
class
CustomerCooperationVo
{
/**
* 分包合同主键
*/
private
Long
subcontractKey
;
/**
* 分包合同ID
*/
private
String
subcontractId
;
/**
* 项目名称
*/
private
String
projectName
;
/**
* 分包合同金额
*/
private
Double
subcontractValue
;
/**
* 签订单位ID
*/
private
String
signOrgId
;
/**
* 签订单位名称
*/
private
String
signOrgName
;
/**
* 合同签订日期
*/
private
String
signDate
;
/**
* 分包范围
*/
private
String
jobScope
;
/**
* 结算价
*/
private
Double
settleValue
;
/**
* 区域名称
*/
private
String
areaName
;
/**
* 省份名称
*/
private
String
provinceName
;
/**
* 城市名称
*/
private
String
cityName
;
/**
* 项目经理名称
*/
private
String
projectManagerName
;
/**
* 项目经理电话
*/
private
String
projectManagerPhone
;
/**
* 工程类型名称
*/
private
String
projectType2
;
}
dsk-module/dsk-biz-api/src/main/java/com/dsk/cscec/mapper/DSubcontractMapper.java
View file @
fa04140e
...
...
@@ -2,7 +2,12 @@ package com.dsk.cscec.mapper;
import
com.baomidou.mybatisplus.core.mapper.BaseMapper
;
import
com.baomidou.mybatisplus.core.metadata.IPage
;
import
com.baomidou.mybatisplus.extension.plugins.pagination.Page
;
import
com.dsk.cscec.domain.DSubcontract
;
import
com.dsk.cscec.domain.bo.CustomerCooperationBo
;
import
com.dsk.cscec.domain.vo.CustomerCooperationVo
;
import
org.apache.ibatis.annotations.Param
;
/**
* 分包分供合同(DSubcontract)表数据库访问层
...
...
@@ -16,5 +21,12 @@ public interface DSubcontractMapper extends BaseMapper<DSubcontract> {
Integer
selectProjectCountByCustomerId
(
String
customerId
);
/**
* 供应商合作记录
* @param build
* @param bo
* @return
*/
Page
<
CustomerCooperationVo
>
selectCooperationList
(
IPage
<
CustomerCooperationBo
>
build
,
@Param
(
"bo"
)
CustomerCooperationBo
bo
);
}
dsk-module/dsk-biz-api/src/main/java/com/dsk/cscec/service/ICustomerInfoService.java
View file @
fa04140e
...
...
@@ -5,9 +5,11 @@ import com.dsk.common.core.domain.PageQuery;
import
com.dsk.common.core.page.TableDataInfo
;
import
com.dsk.cscec.domain.DCustomer
;
import
com.dsk.cscec.domain.bo.AdvisoryBodyBo
;
import
com.dsk.cscec.domain.bo.CustomerCooperationBo
;
import
com.dsk.cscec.domain.bo.CustomerInfoBo
;
import
com.dsk.cscec.domain.vo.AdvisoryBodyVo
;
import
com.dsk.cscec.domain.vo.CustomerApproveVo
;
import
com.dsk.cscec.domain.vo.CustomerCooperationVo
;
import
com.dsk.cscec.domain.vo.CustomerInfoVo
;
/**
...
...
@@ -23,4 +25,12 @@ public interface ICustomerInfoService extends IService<DCustomer> {
CustomerApproveVo
queryApproveByBo
(
CustomerInfoBo
bo
);
TableDataInfo
<
AdvisoryBodyVo
>
queryAdvisoryList
(
AdvisoryBodyBo
bo
,
PageQuery
query
);
/**
* 供应商合作记录
* @param bo
* @param query
* @return
*/
TableDataInfo
<
CustomerCooperationVo
>
queryCooperationList
(
CustomerCooperationBo
bo
,
PageQuery
query
);
}
dsk-module/dsk-biz-api/src/main/java/com/dsk/cscec/service/impl/CustomerInfoServiceImpl.java
View file @
fa04140e
...
...
@@ -14,9 +14,11 @@ import com.dsk.common.core.page.TableDataInfo;
import
com.dsk.cscec.constant.QueryConstants
;
import
com.dsk.cscec.domain.DCustomer
;
import
com.dsk.cscec.domain.bo.AdvisoryBodyBo
;
import
com.dsk.cscec.domain.bo.CustomerCooperationBo
;
import
com.dsk.cscec.domain.bo.CustomerInfoBo
;
import
com.dsk.cscec.domain.vo.AdvisoryBodyVo
;
import
com.dsk.cscec.domain.vo.CustomerApproveVo
;
import
com.dsk.cscec.domain.vo.CustomerCooperationVo
;
import
com.dsk.cscec.domain.vo.CustomerInfoVo
;
import
com.dsk.cscec.mapper.AdvisoryBodyMapper
;
import
com.dsk.cscec.mapper.DCustomerMapper
;
...
...
@@ -48,6 +50,9 @@ public class CustomerInfoServiceImpl extends ServiceImpl<DCustomerMapper, DCusto
@Autowired
private
AdvisoryBodyMapper
advisoryBodyMapper
;
@Autowired
private
DSubcontractMapper
dSubcontractMapper
;
@Override
public
TableDataInfo
<
CustomerInfoVo
>
queryPageList
(
CustomerInfoBo
bo
,
PageQuery
query
)
{
if
(
"劳务分包"
.
equals
(
bo
.
getCustomerClass
())){
...
...
@@ -101,4 +106,14 @@ public class CustomerInfoServiceImpl extends ServiceImpl<DCustomerMapper, DCusto
Page
<
AdvisoryBodyVo
>
page
=
advisoryBodyMapper
.
queryListByBo
(
query
.
build
(),
bo
);
return
TableDataInfo
.
build
(
page
);
}
@Override
public
TableDataInfo
<
CustomerCooperationVo
>
queryCooperationList
(
CustomerCooperationBo
bo
,
PageQuery
query
)
{
if
(
StringUtil
.
isBlank
(
bo
.
getCustomerId
())
&&
StringUtil
.
isBlank
(
bo
.
getCustomerName
())){
Assert
.
isTrue
(
false
,
"供应商不能为空"
);
}
bo
.
setSignOrgId
(
QueryConstants
.
LEVEL1_COMPANY_ID
);
Page
<
CustomerCooperationVo
>
page
=
dSubcontractMapper
.
selectCooperationList
(
query
.
build
(),
bo
);
return
TableDataInfo
.
build
(
page
);
}
}
dsk-module/dsk-biz-api/src/main/resources/mapper/cscec/DSubcontractMapper.xml
View file @
fa04140e
...
...
@@ -17,4 +17,33 @@
) a
</select>
<select
id=
"selectCooperationList"
resultType=
"com.dsk.cscec.domain.vo.CustomerCooperationVo"
>
select ds.subcontract_key,ds.subcontract_id,ds.project_name,ds.sign_org_name,ds.sign_date,ds.subcontract_value,ds.settle_value,ds.job_scope,
dp.area_name,dp.province_name,dp.city_name,dp.project_manager_name,dp.project_manager_phone,dp.project_type2
from d_subcontract ds
left join d_project dp on dp.project_id = ds.project_id
<where>
<if
test=
"bo.signOrgId != null and bo.signOrgId != ''"
>
and ds.sign_org_id =#{bo.signOrgId}
</if>
<if
test=
"bo.signOrgName != null and bo.signOrgName != ''"
>
and ds.sign_org_name =#{bo.signOrgName}
</if>
<if
test=
"bo.customerId != null and bo.customerId != ''"
>
and ds.customer_id =#{bo.customerId}
</if>
<if
test=
"bo.customerName != null and bo.customerName != ''"
>
and ds.customer_name =#{bo.customerName}
</if>
<if
test=
"bo.areaName != null and bo.areaName.size > 0"
>
and (
ds.areaName in
<foreach
collection=
"bo.areaName"
item=
"areaName"
open=
"("
close=
")"
separator=
","
>
#{areaName}
</foreach>
)
</if>
</where>
order by ds.sign_date desc
</select>
</mapper>
\ No newline at end of file
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