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
c3a147f6
Commit
c3a147f6
authored
Jun 04, 2019
by
java-李谡
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
部门论证添加备注节点
parent
8ed37a7e
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
30 additions
and
28 deletions
+30
-28
SailingCommandService.java
src/com/ejweb/modules/sailing/service/SailingCommandService.java
+30
-28
No files found.
src/com/ejweb/modules/sailing/service/SailingCommandService.java
View file @
c3a147f6
...
@@ -39,6 +39,7 @@ import com.github.pagehelper.PageHelper;
...
@@ -39,6 +39,7 @@ import com.github.pagehelper.PageHelper;
import
com.github.pagehelper.PageInfo
;
import
com.github.pagehelper.PageInfo
;
import
freemarker.template.TemplateException
;
import
freemarker.template.TemplateException
;
import
org.apache.commons.lang3.StringUtils
;
import
org.apache.commons.lang3.StringUtils
;
import
org.apache.log4j.Logger
;
import
org.apache.poi.openxml4j.exceptions.InvalidFormatException
;
import
org.apache.poi.openxml4j.exceptions.InvalidFormatException
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.stereotype.Service
;
import
org.springframework.stereotype.Service
;
...
@@ -63,6 +64,8 @@ import java.util.regex.Pattern;
...
@@ -63,6 +64,8 @@ import java.util.regex.Pattern;
*/
*/
@Service
@Service
public
class
SailingCommandService
extends
CurdService
<
SailingCommandDao
,
SailingCommandEntity
>
{
public
class
SailingCommandService
extends
CurdService
<
SailingCommandDao
,
SailingCommandEntity
>
{
private
final
static
Logger
LOG
=
Logger
.
getLogger
(
SailingCommandService
.
class
);
@Autowired
@Autowired
private
AirlineVerifyDao
verifyDao
;
private
AirlineVerifyDao
verifyDao
;
@Autowired
@Autowired
...
@@ -370,11 +373,7 @@ public class SailingCommandService extends CurdService<SailingCommandDao, Sailin
...
@@ -370,11 +373,7 @@ public class SailingCommandService extends CurdService<SailingCommandDao, Sailin
if
(
"01"
.
equals
(
CommandStatus
)
&&
"01"
.
equals
(
bean
.
getCommandStatus
()))
{
if
(
"01"
.
equals
(
CommandStatus
)
&&
"01"
.
equals
(
bean
.
getCommandStatus
()))
{
return
false
;
return
false
;
}
}
if
(
"01"
.
equals
(
bean
.
getCommandStatus
())
||
"02"
.
equals
(
bean
.
getCommandStatus
()))
{
//commandStatus为’01’时,以verifId找到foc_airline_verify对应数据中的verif_status设置为02
bean
.
setVerifStatus
(
"02"
);
dao
.
updateVerifStatys
(
bean
);
}
if
(!
"00"
.
equals
(
bean
.
getCommandStatus
()))
{
if
(!
"00"
.
equals
(
bean
.
getCommandStatus
()))
{
// 该input标签不一定以 / 结尾
// 该input标签不一定以 / 结尾
Pattern
pattern
=
Pattern
.
compile
(
"(?<=routeNo\" value=\")(.+?)(?=\"/?>)"
);
Pattern
pattern
=
Pattern
.
compile
(
"(?<=routeNo\" value=\")(.+?)(?=\"/?>)"
);
...
@@ -394,7 +393,6 @@ public class SailingCommandService extends CurdService<SailingCommandDao, Sailin
...
@@ -394,7 +393,6 @@ public class SailingCommandService extends CurdService<SailingCommandDao, Sailin
bean
.
setRouteNo
(
routeNo
);
bean
.
setRouteNo
(
routeNo
);
// if(bean.getFormText()!=null&&!"".equals(bean.getFormText())){
// if(bean.getFormText()!=null&&!"".equals(bean.getFormText())){
try
{
// 完成审核通知置灰
// 完成审核通知置灰
NotifyAddBean
addbean
=
new
NotifyAddBean
();
NotifyAddBean
addbean
=
new
NotifyAddBean
();
addbean
.
setVerifId
(
bean
.
getVerifId
());
addbean
.
setVerifId
(
bean
.
getVerifId
());
...
@@ -540,7 +538,7 @@ public class SailingCommandService extends CurdService<SailingCommandDao, Sailin
...
@@ -540,7 +538,7 @@ public class SailingCommandService extends CurdService<SailingCommandDao, Sailin
sb
.
append
(
bean
.
getConRemarks
().
replaceAll
(
"<table"
,
"<table width=\"80%\" "
));
sb
.
append
(
bean
.
getConRemarks
().
replaceAll
(
"<table"
,
"<table width=\"80%\" "
));
// sb.append(bean.getConRemarks());
// sb.append(bean.getConRemarks());
/* sb.append("<br/><h2>开航指令:</h2>");
/* sb.append("<br/><h2>开航指令:</h2>");
sb.append(bean.getFormText());*/
sb.append(bean.getFormText());*/
sb
.
append
(
"<br/><h2>各部门论证单:</h2>"
);
sb
.
append
(
"<br/><h2>各部门论证单:</h2>"
);
...
@@ -595,42 +593,46 @@ public class SailingCommandService extends CurdService<SailingCommandDao, Sailin
...
@@ -595,42 +593,46 @@ public class SailingCommandService extends CurdService<SailingCommandDao, Sailin
sailingFileBean
.
setCreateBy
(
bean
.
getUserCode
());
sailingFileBean
.
setCreateBy
(
bean
.
getUserCode
());
//dao.deleteSailingFile(sailingFileBean);
//dao.deleteSailingFile(sailingFileBean);
dao
.
insertSailingFile
(
sailingFileBean
);
dao
.
insertSailingFile
(
sailingFileBean
);
}
catch
(
Exception
e
)
{
LOG
.
info
(
"添加开航指令文件完成"
);
// TODO: handle exception
}
dao
.
updateAirlineverify
(
bean
);
dao
.
updateAirlineverify
(
bean
);
LOG
.
info
(
"更新开航指令绑定完成"
);
// 获取论证全部参与部门
// 获取论证全部参与部门
List
<
String
>
lst
=
dao
.
getVerifDeparts
(
bean
.
getVerifId
());
List
<
String
>
lst
=
dao
.
getVerifDeparts
(
bean
.
getVerifId
());
for
(
String
departId
:
lst
)
{
for
(
String
departId
:
lst
)
{
NotifyAddBean
addbean
=
new
NotifyAddBean
();
NotifyAddBean
addbean
1
=
new
NotifyAddBean
();
StringBuffer
sb
=
new
StringBuffer
();
StringBuffer
sb
Content
=
new
StringBuffer
();
sb
.
append
(
"论证单号为"
).
append
(
map1
.
get
(
"verifNo"
))
sb
Content
.
append
(
"论证单号为"
).
append
(
map1
.
get
(
"verifNo"
))
.
append
(
map1
.
get
(
"verifType"
)).
append
(
map1
.
get
(
"depName"
)).
append
(
"的航线已生成开航指令。"
);
.
append
(
map1
.
get
(
"verifType"
)).
append
(
map1
.
get
(
"depName"
)).
append
(
"的航线已生成开航指令。"
);
StringBuffer
url
=
new
StringBuffer
();
StringBuffer
url
=
new
StringBuffer
();
url
.
append
(
"<<<a href='airway-argument-details.htm?verifId="
).
append
(
bean
.
getVerifId
());
url
.
append
(
"<<<a href='airway-argument-details.htm?verifId="
).
append
(
bean
.
getVerifId
());
url
.
append
(
"&verifNo="
).
append
(
map1
.
get
(
"verifNo"
));
url
.
append
(
"&verifNo="
).
append
(
map1
.
get
(
"verifNo"
));
url
.
append
(
"&sailingDate="
).
append
(
map1
.
get
(
"startTime"
));
url
.
append
(
"&sailingDate="
).
append
(
map1
.
get
(
"startTime"
));
url
.
append
(
"'>点击查看</a>"
);
url
.
append
(
"'>点击查看</a>"
);
addbean
.
setUrl
(
url
.
toString
());
addbean
1
.
setUrl
(
url
.
toString
());
addbean
.
setType
(
"14"
);
addbean
1
.
setType
(
"14"
);
addbean
.
setContent
(
sb
.
toString
());
addbean
1
.
setContent
(
sbContent
.
toString
());
addbean
.
setTitle
(
"开航指令下发完成提醒"
);
addbean
1
.
setTitle
(
"开航指令下发完成提醒"
);
addbean
.
setCreateBy
(
bean
.
getUserCode
());
addbean
1
.
setCreateBy
(
bean
.
getUserCode
());
addbean
.
setUpdateBy
(
bean
.
getUserCode
());
addbean
1
.
setUpdateBy
(
bean
.
getUserCode
());
addbean
.
setCreateDate
(
new
Date
());
addbean
1
.
setCreateDate
(
new
Date
());
addbean
.
setUpdateDate
(
new
Date
());
addbean
1
.
setUpdateDate
(
new
Date
());
addbean
.
setId
(
IdWorker
.
getNextId
());
addbean
1
.
setId
(
IdWorker
.
getNextId
());
addbean
.
setDepartId
(
departId
);
addbean
1
.
setDepartId
(
departId
);
addbean
.
setVerifId
(
bean
.
getVerifId
());
addbean
1
.
setVerifId
(
bean
.
getVerifId
());
addbean
.
setConId
(
bean
.
getVerifId
());
addbean
1
.
setConId
(
bean
.
getVerifId
());
notifyDao
.
saveNotify
(
addbean
);
notifyDao
.
saveNotify
(
addbean
1
);
}
}
}
}
dao
.
updateSailingCommand
(
bean
);
dao
.
updateSailingCommand
(
bean
);
LOG
.
info
(
"更新开航指令状态完成,已完成开航指令,开航指令状态:"
+
bean
.
getCommandStatus
());
if
(
"01"
.
equals
(
bean
.
getCommandStatus
())
||
"02"
.
equals
(
bean
.
getCommandStatus
()))
{
//commandStatus为’01’时,以verifId找到foc_airline_verify对应数据中的verif_status设置为02
bean
.
setVerifStatus
(
"02"
);
dao
.
updateVerifStatys
(
bean
);
LOG
.
info
(
"更新论证状态为论证成功"
);
}
return
true
;
return
true
;
}
}
...
...
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