Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
A
amos-boot-biz
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
项目统一框架
amos-boot-biz
Commits
a42a9ec5
Commit
a42a9ec5
authored
Apr 03, 2024
by
tangwei
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
增加场站信息
parent
f6054a48
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
43 additions
and
0 deletions
+43
-0
HYGFMaintenanceTicketsServiceImpl.java
...f/biz/service/impl/HYGFMaintenanceTicketsServiceImpl.java
+43
-0
No files found.
amos-boot-system-jxiop/amos-boot-module-hygf-biz/src/main/java/com/yeejoin/amos/boot/module/hygf/biz/service/impl/HYGFMaintenanceTicketsServiceImpl.java
View file @
a42a9ec5
...
...
@@ -12,8 +12,11 @@ import com.github.pagehelper.PageHelper;
import
com.github.pagehelper.PageInfo
;
import
com.yeejoin.amos.boot.module.hygf.api.dto.*
;
import
com.yeejoin.amos.boot.module.hygf.api.entity.HYGFMaintenanceTickets
;
import
com.yeejoin.amos.boot.module.hygf.api.entity.JpStation
;
import
com.yeejoin.amos.boot.module.hygf.api.entity.TdHygfJpInverterWarn
;
import
com.yeejoin.amos.boot.module.hygf.api.mapper.HYGFMaintenanceTicketsMapper
;
import
com.yeejoin.amos.boot.module.hygf.api.mapper.JpStationMapper
;
import
com.yeejoin.amos.boot.module.hygf.api.mapper.MaintenanceMapper
;
import
com.yeejoin.amos.boot.module.hygf.api.service.IHYGFMaintenanceTicketsService
;
import
com.yeejoin.amos.boot.module.hygf.api.tdenginemapper.TdHygfJpInverterWarnMapper
;
import
lombok.extern.slf4j.Slf4j
;
...
...
@@ -40,6 +43,10 @@ public class HYGFMaintenanceTicketsServiceImpl extends BaseService<HYGFMaintenan
@Autowired
HYGFMaintenanceTicketsMapper
hygfMaintenanceTicketsMapper
;
@Autowired
JpStationMapper
jpStationMapper
;
@Autowired
MaintenanceMapper
maintenanceMapper
;
/**
* 分页查询
...
...
@@ -75,6 +82,42 @@ public class HYGFMaintenanceTicketsServiceImpl extends BaseService<HYGFMaintenan
public
void
sendMeassageToMcb
(
HYGFMaintenanceTicketsDto
hygfMaintenanceTicketsDto
)
{
if
(
hygfMaintenanceTicketsDto
.
getWarningId
()==
null
){
JpStation
jpStation
=
jpStationMapper
.
selectOne
(
new
QueryWrapper
<
JpStation
>().
eq
(
"third_station_id"
,
hygfMaintenanceTicketsDto
.
getStationId
()));
if
(
ObjectUtil
.
isEmpty
(
jpStation
))
{
jpStation
=
jpStationMapper
.
selectById
(
hygfMaintenanceTicketsDto
.
getStationId
());
}
if
(
ObjectUtil
.
isNotEmpty
(
jpStation
))
{
//场站名称
hygfMaintenanceTicketsDto
.
setStationName
(
jpStation
.
getName
());
//区域公司编码
hygfMaintenanceTicketsDto
.
setRegionalCompaniesCode
(
jpStation
.
getRegionalCompaniesCode
());
//经销商orgCode
hygfMaintenanceTicketsDto
.
setAmosCompanyCode
(
jpStation
.
getAmosCompanyCode
());
//地址
hygfMaintenanceTicketsDto
.
setStationAddress
(
jpStation
.
getAddress
());
//经度
hygfMaintenanceTicketsDto
.
setStationLongitude
(
jpStation
.
getLongitude
());
//纬度
hygfMaintenanceTicketsDto
.
setStationLatitude
(
jpStation
.
getLatitude
());
//电站联系人电话
hygfMaintenanceTicketsDto
.
setStationContactPhone
(
jpStation
.
getUserPhone
());
// 电站联系人
hygfMaintenanceTicketsDto
.
setStationContact
(
jpStation
.
getStationContact
());
//业主姓名
hygfMaintenanceTicketsDto
.
setOwnerName
(
jpStation
.
getUserName
());
if
(
ObjectUtil
.
isEmpty
(
hygfMaintenanceTicketsDto
.
getStationContact
()))
{
hygfMaintenanceTicketsDto
.
setStationContact
(
jpStation
.
getUserName
());
}
}
MaintenanceDto
maintenance
=
maintenanceMapper
.
selectOneById
(
Long
.
valueOf
(
hygfMaintenanceTicketsDto
.
getMaintenancePersonId
()));
if
(
ObjectUtil
.
isNotEmpty
(
maintenance
))
{
hygfMaintenanceTicketsDto
.
setMaintenancePersonName
(
maintenance
.
getName
());
hygfMaintenanceTicketsDto
.
setMaintenancePersonPhone
(
maintenance
.
getTelephone
());
}
HYGFMaintenanceTickets
fMaintenanceTickets
=
new
HYGFMaintenanceTickets
();
BeanUtils
.
copyProperties
(
hygfMaintenanceTicketsDto
,
fMaintenanceTickets
);
this
.
save
(
fMaintenanceTickets
);
...
...
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