Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
A
api
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
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
首航-临时账号
api
Commits
391f3fe5
Commit
391f3fe5
authored
Mar 30, 2020
by
Lenovo
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
调机修改
parent
1704adc1
Show whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
110 additions
and
26 deletions
+110
-26
VerifyFeedbackDao.xml
resources/mapper/modules/verify/VerifyFeedbackDao.xml
+38
-5
RouteVerifyDetailBean.java
src/com/ejweb/modules/route/bean/RouteVerifyDetailBean.java
+1
-1
RouteVerifyService.java
src/com/ejweb/modules/route/service/RouteVerifyService.java
+6
-7
VerifyFeedbackDetailBean.java
src/com/ejweb/modules/verify/bean/VerifyFeedbackDetailBean.java
+19
-1
VerifyFeedbackDao.java
src/com/ejweb/modules/verify/dao/VerifyFeedbackDao.java
+5
-0
VerifyFeedbackService.java
src/com/ejweb/modules/verify/service/VerifyFeedbackService.java
+41
-12
No files found.
resources/mapper/modules/verify/VerifyFeedbackDao.xml
View file @
391f3fe5
...
...
@@ -189,7 +189,7 @@
<if
test=
"aircraftType != null and aircraftType != ''"
>
AND a.aircraft_type = #{aircraftType}
</if>
group by a.id
</select>
<!-- 本部门论证条件评估列表 -->
...
...
@@ -236,18 +236,29 @@
<select
id=
"getDetail1"
resultType=
"com.ejweb.modules.verify.entity.VerifyFeedbackDetailEntity"
>
SELECT
'01' AS departType,
a.condition,
a.verif_id AS verifId,
a.verify_status AS verifyStatus,
s.verif_no AS verifNo,
a.depart_id AS departId
FROM foc_route_verify a
LEFT JOIN foc_airline_verify s ON a.verif_id=s.id
<choose>
<when
test=
"userDepartId !=null"
>
LEFT JOIN foc_verify_condition t ON a.id=t.route_id
LEFT JOIN foc_condition_feedback f ON t.id=f.condition_id
WHERE
a.del_flag = #{DEL_FLAG_NORMAL}
AND t.id = #{conditionId}
AND a.verif_id = #{verifId}
AND f.depart_id = #{userDepartId}
group by a.verif_id,f.depart_id
</when>
<otherwise>
WHERE
a.del_flag = #{DEL_FLAG_NORMAL}
AND a.verif_id = #{verifId}
AND a.depart_id = #{departId}
</otherwise>
</choose>
</select>
<select
id=
"getDetail2"
resultType=
"com.ejweb.modules.verify.entity.VerifyFeedbackDetailEntity"
>
SELECT
...
...
@@ -277,6 +288,28 @@
AND q.condition_id = #{conditionId}
</select>
<select
id=
"findByVerifyIdAndDepartId"
resultType=
"com.ejweb.modules.verify.data.ConditionDetailData"
>
select v.id as conditionId,
v.`condition`,
v.is_feed as feedStatus,
case WHEN v.is_feed!='0' THEN DATE_FORMAT(v.update_date, '%Y-%m-%d')
else '' end conditionDate
from foc_verify_condition v
<choose>
<when
test=
"userDepartId !=null"
>
left join foc_condition_feedback f on v.id=f.condition_id
where f.depart_id=#{userDepartId}
and v.verif_id=#{verifId}
group by v.id
</when>
<otherwise>
WHERE v.verif_id = #{verifId}
AND v.depart_id = #{departId}
</otherwise>
</choose>
</select>
<!-- 论证条件评估-修改各部门的反馈信息 -->
<update
id=
"updateFeedback"
>
UPDATE foc_condition_feedback
...
...
@@ -315,7 +348,7 @@
AND a.feedback_status = '00'
</select>
<select
id=
"checkRouteVerifyExist"
resultType=
"com.ejweb.modules.route.entity.FullRouteVerifyEntity"
>
<select
id=
"checkRouteVerifyExist"
resultType=
"com.ejweb.modules.route.entity.FullRouteVerifyEntity"
>
SELECT
id,
verif_id,
...
...
src/com/ejweb/modules/route/bean/RouteVerifyDetailBean.java
View file @
391f3fe5
...
...
@@ -17,7 +17,7 @@ public class RouteVerifyDetailBean extends GenericBean{
@NotEmpty
(
message
=
"verifId字段不能为空"
)
private
String
verifId
;
//论证单id
private
String
departId
;
//用户id
private
String
departId
;
private
String
userCode
;
//用户id
public
String
getVerifId
()
{
...
...
src/com/ejweb/modules/route/service/RouteVerifyService.java
View file @
391f3fe5
...
...
@@ -274,8 +274,6 @@ public class RouteVerifyService extends BaseService<RouteVerifyDao> {
// 论证意见为条件可行或不可行
if
(
"02"
.
equals
(
verifyStatus
)
||
"03"
.
equals
(
verifyStatus
))
{
for
(
FullVerifyConditionEntity
condition
:
bean
.
getConditions
())
{
String
cid
=
IdWorker
.
getNextId
();
condition
.
setId
(
cid
);
this
.
addVerifyCondition
(
fullRouteVerifyEntity
,
verifyStatus
,
bean
.
getUserCode
(),
condition
);
}
NotifyAddBean
addbean
=
new
NotifyAddBean
();
...
...
@@ -316,8 +314,6 @@ public class RouteVerifyService extends BaseService<RouteVerifyDao> {
routeFileBean
.
setId
(
IdWorker
.
getNextId
());
routeFileBean
.
setFileName
(
m
.
get
(
"fileName"
));
routeFileBean
.
setFilePath
(
m
.
get
(
"filePath"
));
routeFileBean
.
setFileSize
(
String
.
valueOf
(
m
.
get
(
"fileSize"
)));
routeFileBean
.
setRouteId
(
fullRouteVerifyEntity
.
getId
());
...
...
@@ -469,7 +465,6 @@ public class RouteVerifyService extends BaseService<RouteVerifyDao> {
}
private
void
addVerifyCondition
(
FullRouteVerifyEntity
routeVerifyEntity
,
String
verifuStatus
,
String
userCode
,
FullVerifyConditionEntity
conditionEntity
)
{
conditionEntity
.
setId
(
conditionEntity
.
getId
());
conditionEntity
.
setConditionStatus
(
verifuStatus
);
conditionEntity
.
setVerifId
(
routeVerifyEntity
.
getVerifId
());
conditionEntity
.
setCreateBy
(
userCode
);
...
...
@@ -480,7 +475,13 @@ public class RouteVerifyService extends BaseService<RouteVerifyDao> {
conditionEntity
.
setIsFeed
(
"0"
);
conditionEntity
.
setRouteId
(
routeVerifyEntity
.
getId
());
conditionEntity
.
setDepartId
(
dao
.
getDepartId
(
userCode
));
if
(
conditionEntity
.
getId
()
==
null
)
{
String
cid
=
IdWorker
.
getNextId
();
conditionEntity
.
setId
(
cid
);
verifyConditionDao
.
insert
(
conditionEntity
);
}
else
{
verifyConditionDao
.
updateByPrimaryKeySelective
(
conditionEntity
);
}
}
...
...
@@ -530,8 +531,6 @@ public class RouteVerifyService extends BaseService<RouteVerifyDao> {
// 论证意见为条件可行或不可行
if
(
"02"
.
equals
(
verifyStatus
)
||
"03"
.
equals
(
verifyStatus
))
{
for
(
FullVerifyConditionEntity
condition
:
bean
.
getConditions
())
{
String
cid
=
IdWorker
.
getNextId
();
condition
.
setId
(
cid
);
this
.
addVerifyCondition
(
fullRouteVerifyEntity
,
verifyStatus
,
bean
.
getUserCode
(),
condition
);
}
// String cid = IdWorker.getNextId();
...
...
src/com/ejweb/modules/verify/bean/VerifyFeedbackDetailBean.java
View file @
391f3fe5
...
...
@@ -19,8 +19,10 @@ public class VerifyFeedbackDetailBean extends GenericBean {
private
String
departType
;
@NotEmpty
(
message
=
"userCode不能为空"
)
private
String
userCode
;
@NotEmpty
(
message
=
"conditionId不能为空"
)
@NotEmpty
(
message
=
"departId不能为空"
)
private
String
departId
;
private
String
conditionId
;
private
String
userDepartId
;
public
String
getVerifId
()
{
return
verifId
;
}
...
...
@@ -39,12 +41,28 @@ public class VerifyFeedbackDetailBean extends GenericBean {
public
void
setUserCode
(
String
userCode
)
{
this
.
userCode
=
userCode
;
}
public
String
getDepartId
()
{
return
departId
;
}
public
void
setDepartId
(
String
departId
)
{
this
.
departId
=
departId
;
}
public
String
getConditionId
()
{
return
conditionId
;
}
public
void
setConditionId
(
String
conditionId
)
{
this
.
conditionId
=
conditionId
;
}
public
String
getUserDepartId
()
{
return
userDepartId
;
}
public
void
setUserDepartId
(
String
userDepartId
)
{
this
.
userDepartId
=
userDepartId
;
}
}
src/com/ejweb/modules/verify/dao/VerifyFeedbackDao.java
View file @
391f3fe5
...
...
@@ -12,8 +12,10 @@ import com.ejweb.modules.verify.bean.VerifyFeedbackBean;
import
com.ejweb.modules.verify.bean.VerifyFeedbackDetailBean
;
import
com.ejweb.modules.verify.bean.VerifyFeedbackStatusBean
;
import
com.ejweb.modules.verify.bean.VerifyFeedbackUpdateBean
;
import
com.ejweb.modules.verify.data.ConditionDetailData
;
import
com.ejweb.modules.verify.entity.VerifyFeedbackDetailEntity
;
import
com.ejweb.modules.verify.entity.VerifyFeedbackEntity
;
import
org.apache.ibatis.annotations.Param
;
/**
*
...
...
@@ -34,6 +36,9 @@ public interface VerifyFeedbackDao extends BaseDao{
VerifyFeedbackDetailEntity
getDetail2
(
VerifyFeedbackDetailBean
bean
);
List
<
Map
<
String
,
String
>>
getDetailList
(
VerifyFeedbackDetailBean
bean
);
List
<
ConditionDetailData
>
findByVerifyIdAndDepartId
(
VerifyFeedbackDetailBean
bean
);
// 更新反馈信息
int
updateFeedback
(
VerifyFeedbackUpdateBean
bean
);
// 全部反馈后,更新反馈状态
...
...
src/com/ejweb/modules/verify/service/VerifyFeedbackService.java
View file @
391f3fe5
...
...
@@ -6,13 +6,17 @@ package com.ejweb.modules.verify.service;
import
com.ejweb.core.base.BaseService
;
import
com.ejweb.core.base.PageEntity
;
import
com.ejweb.core.exception.RecordNotExistException
;
import
com.ejweb.modules.depart.dao.DepartDao
;
import
com.ejweb.modules.depart.entity.DepartEntity
;
import
com.ejweb.modules.route.entity.FullRouteVerifyEntity
;
import
com.ejweb.modules.verify.bean.VerifyFeedbackBean
;
import
com.ejweb.modules.verify.bean.VerifyFeedbackDetailBean
;
import
com.ejweb.modules.verify.bean.VerifyFeedbackStatusBean
;
import
com.ejweb.modules.verify.bean.VerifyFeedbackUpdateBean
;
import
com.ejweb.modules.verify.dao.AirlineVerifyDao
;
import
com.ejweb.modules.verify.dao.ConditionDao
;
import
com.ejweb.modules.verify.dao.VerifyFeedbackDao
;
import
com.ejweb.modules.verify.data.ConditionDetailData
;
import
com.ejweb.modules.verify.entity.VerifyFeedbackDetailEntity
;
import
com.ejweb.modules.verify.entity.VerifyFeedbackEntity
;
import
com.github.pagehelper.PageHelper
;
...
...
@@ -21,6 +25,7 @@ import org.apache.commons.lang3.StringUtils;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.stereotype.Service
;
import
org.springframework.transaction.annotation.Transactional
;
import
org.springframework.util.CollectionUtils
;
import
java.util.ArrayList
;
import
java.util.HashMap
;
...
...
@@ -39,25 +44,31 @@ import java.util.Map;
public
class
VerifyFeedbackService
extends
BaseService
<
VerifyFeedbackDao
>
{
@Autowired
AirlineVerifyDao
verifyDao
;
@Autowired
ConditionDao
conditionDao
;
@Autowired
DepartDao
departDao
;
public
PageEntity
<
VerifyFeedbackEntity
>
findList
(
VerifyFeedbackBean
bean
)
{
PageInfo
<
VerifyFeedbackEntity
>
pageInfo
=
null
;
PageInfo
<
VerifyFeedbackEntity
>
pageInfo
;
// 必须紧贴dao的查询方法
PageHelper
.
startPage
(
bean
.
getPageNo
(),
bean
.
getPageSize
());
if
(
StringUtils
.
isEmpty
(
bean
.
getSort
()))
{
PageHelper
.
orderBy
(
" verifNo DESC"
);
}
else
}
else
{
PageHelper
.
orderBy
(
bean
.
getSort
());
}
List
<
VerifyFeedbackEntity
>
list
=
dao
.
findlist3
(
bean
);
pageInfo
=
new
PageInfo
<
VerifyFeedbackEntity
>(
list
);
pageInfo
=
new
PageInfo
<>(
list
);
if
(
pageInfo
.
getPages
()
<
bean
.
getPageNo
())
{
// 页码大于总页数,则返回NULL
// 页码大于总页数,则返回NULL
if
(
pageInfo
.
getPages
()
<
bean
.
getPageNo
())
{
return
null
;
}
list
=
pageInfo
.
getList
();
if
(
list
==
null
||
list
.
size
()
==
0
)
{
// 如果没有数据则返回NULL
// 如果没有数据则返回NULL
if
(
list
==
null
||
list
.
size
()
==
0
)
{
return
null
;
}
for
(
VerifyFeedbackEntity
entity
:
list
)
{
...
...
@@ -75,9 +86,9 @@ public class VerifyFeedbackService extends BaseService<VerifyFeedbackDao> {
entity
.
setTypeList
(
verifyDao
.
getTypeList
(
entity
.
getVerifId
()));
entity
.
setDepName
(
verifyDao
.
getConnetList
(
entity
.
getVerifId
()));
String
typelist
=
verifyDao
.
getTypeList1
(
entity
.
getVerifId
());
if
(
StringUtils
.
isNoneBlank
(
typelist
))
if
(
StringUtils
.
isNoneBlank
(
typelist
))
{
entity
.
setAircraftName
(
entity
.
getAircraftName
()
+
":"
+
typelist
);
}
}
PageEntity
<
VerifyFeedbackEntity
>
page
=
new
PageEntity
<
VerifyFeedbackEntity
>();
page
.
setPageNo
(
pageInfo
.
getPageNum
());
...
...
@@ -99,11 +110,30 @@ public class VerifyFeedbackService extends BaseService<VerifyFeedbackDao> {
}
public
VerifyFeedbackDetailEntity
getDetailList
(
VerifyFeedbackDetailBean
bean
)
{
VerifyFeedbackDetailEntity
feed
=
dao
.
getDetail1
(
bean
);
DepartEntity
departEntity
=
departDao
.
getByUserCode
(
bean
.
getUserCode
());
VerifyFeedbackDetailEntity
feed
;
if
(
departEntity
==
null
)
{
return
null
;
}
//如果userCode所在部门为条件的发起部门,返回departId部门发起的条件,如果不相等,返回departId部门发起的条件中userCode参与评估的条件
if
(!
departEntity
.
getId
().
equals
(
bean
.
getDepartId
()))
{
bean
.
setUserDepartId
(
departEntity
.
getId
());
}
feed
=
dao
.
getDetail1
(
bean
);
if
(
feed
==
null
)
{
return
null
;
}
feed
.
setDepartIds
(
dao
.
getDetailList
(
bean
));
List
<
ConditionDetailData
>
conditions
=
dao
.
findByVerifyIdAndDepartId
(
bean
);
List
<
ConditionDetailData
>
conditionList
=
new
ArrayList
<>();
if
(!
CollectionUtils
.
isEmpty
(
conditions
))
{
for
(
ConditionDetailData
data
:
conditions
)
{
VerifyFeedbackDetailBean
verifyFeedbackDetailBean
=
new
VerifyFeedbackDetailBean
();
verifyFeedbackDetailBean
.
setConditionId
(
data
.
getConditionId
());
data
.
setDepartIds
(
dao
.
getDetailList
(
verifyFeedbackDetailBean
));
conditionList
.
add
(
data
);
}
}
feed
.
setConditions
(
conditionList
);
return
feed
;
}
...
...
@@ -148,9 +178,8 @@ public class VerifyFeedbackService extends BaseService<VerifyFeedbackDao> {
* @time 2016年10月7日
* @param bean
*/
@Transactional
(
readOnly
=
false
)
@Transactional
()
public
void
updateStatus
(
VerifyFeedbackStatusBean
bean
)
{
dao
.
updateStatus
(
bean
);
}
}
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