Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
A
AmosBankPatrolRoot
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
1
Merge Requests
1
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
bank
AmosBankPatrolRoot
Commits
24df0c3d
Commit
24df0c3d
authored
Aug 26, 2020
by
xinglei
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
修改bug
parent
41234d0f
Hide whitespace changes
Inline
Side-by-side
Showing
8 changed files
with
203 additions
and
170 deletions
+203
-170
CheckInputBo.java
.../amos/patrol/service/business/bo/patrol/CheckInputBo.java
+9
-0
CheckController.java
...s/patrol/service/business/controller/CheckController.java
+14
-54
PlanTaskController.java
...atrol/service/business/controller/PlanTaskController.java
+74
-68
CheckServiceImpl.java
...atrol/service/business/service/impl/CheckServiceImpl.java
+39
-36
PlanTaskServiceImpl.java
...ol/service/business/service/impl/PlanTaskServiceImpl.java
+39
-0
XJConstant.java
...com/yeejoin/amos/patrol/service/constants/XJConstant.java
+9
-0
StringUtil.java
...com/yeejoin/amos/patrol/service/core/util/StringUtil.java
+6
-3
dbTemplate_check.xml
...olStart/src/main/resources/db/mapper/dbTemplate_check.xml
+13
-9
No files found.
AmosBankPatrolService/src/main/java/com/yeejoin/amos/patrol/service/business/bo/patrol/CheckInputBo.java
View file @
24df0c3d
...
...
@@ -21,6 +21,7 @@ public class CheckInputBo {
private
String
orgCode
;
private
String
checkDate
;
private
String
planTaskId
;
private
String
beginTime
;
/**
* 开始时间字符串
...
...
@@ -235,6 +236,14 @@ public class CheckInputBo {
this
.
checkDate
=
checkDate
;
}
public
String
getPlanTaskId
()
{
return
planTaskId
;
}
public
void
setPlanTaskId
(
String
planTaskId
)
{
this
.
planTaskId
=
planTaskId
;
}
public
String
getBeginTime
()
{
return
beginTime
;
}
...
...
AmosBankPatrolService/src/main/java/com/yeejoin/amos/patrol/service/business/controller/CheckController.java
View file @
24df0c3d
package
com
.
yeejoin
.
amos
.
patrol
.
service
.
business
.
controller
;
import
cn.afterturn.easypoi.excel.ExcelExportUtil
;
import
cn.afterturn.easypoi.excel.entity.TemplateExportParams
;
import
com.alibaba.fastjson.JSON
;
import
com.alibaba.fastjson.JSONObject
;
import
com.yeejoin.amos.feign.privilege.model.AgencyUserModel
;
//import com.yeejoin.amos.op.core.common.query.DaoCriteria;
//import com.yeejoin.amos.op.core.common.response.CommonResponse;
//import com.yeejoin.amos.op.core.util.CommonResponseUtil;
import
com.yeejoin.amos.patrol.common.core.request.CommonPageable
;
import
com.yeejoin.amos.patrol.common.core.request.CommonRequest
;
import
com.yeejoin.amos.patrol.common.core.response.AppPointCheckRespone
;
import
com.yeejoin.amos.patrol.common.core.response.GraphInitDataResponse
;
import
com.yeejoin.amos.patrol.common.entity.CheckShot
;
import
com.yeejoin.amos.patrol.common.entity.CommonResponse
;
import
com.yeejoin.amos.patrol.common.entity.CommonResponseUtil
;
import
com.yeejoin.amos.patrol.common.entity.DaoCriteria
;
import
com.yeejoin.amos.patrol.common.entity.PlanTask
;
import
com.yeejoin.amos.patrol.common.entity.Point
;
import
com.yeejoin.amos.patrol.common.enums.ExcelEnum
;
import
com.yeejoin.amos.patrol.common.entity.*
;
import
com.yeejoin.amos.patrol.common.enums.PlanTaskFinishStatusEnum
;
import
com.yeejoin.amos.patrol.service.business.dto.CheckDto
;
import
com.yeejoin.amos.patrol.service.business.param.CheckImgParam
;
import
com.yeejoin.amos.patrol.service.business.param.CheckInfoPageParam
;
import
com.yeejoin.amos.patrol.service.business.param.CheckInputParam
;
import
com.yeejoin.amos.patrol.service.business.param.CheckRecordParam
;
import
com.yeejoin.amos.patrol.service.business.param.CheckStatisticalParam
;
import
com.yeejoin.amos.patrol.service.business.param.*
;
import
com.yeejoin.amos.patrol.service.business.service.impl.TaskReportServiceImpl
;
import
com.yeejoin.amos.patrol.service.business.service.intfc.ICheckService
;
import
com.yeejoin.amos.patrol.service.business.service.intfc.IPlanTaskService
;
...
...
@@ -43,61 +28,36 @@ import com.yeejoin.amos.patrol.service.core.util.DateUtil;
import
com.yeejoin.amos.patrol.service.framework.ReginParams
;
import
com.yeejoin.amos.patrol.service.remote.RemoteWebSocketServer
;
import
com.yeejoin.amos.patrol.service.remote.feign.AmosBankFeign
;
//import com.yeejoin.amos.security.common.authorization.Authorization;
//import com.yeejoin.amos.security.common.model.UserModel;
import
io.swagger.annotations.Api
;
import
io.swagger.annotations.ApiOperation
;
import
io.swagger.annotations.ApiParam
;
//import org.apache.commons.httpclient.NameValuePair;
import
org.apache.commons.io.IOUtils
;
import
org.apache.http.client.entity.UrlEncodedFormEntity
;
import
org.apache.http.client.methods.CloseableHttpResponse
;
import
org.apache.http.client.methods.HttpPost
;
import
org.apache.http.entity.StringEntity
;
import
org.apache.http.impl.client.CloseableHttpClient
;
import
org.apache.http.impl.client.HttpClients
;
import
org.apache.http.message.BasicNameValuePair
;
import
org.apache.poi.ss.usermodel.Workbook
;
import
org.slf4j.Logger
;
import
org.slf4j.LoggerFactory
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.beans.factory.annotation.Value
;
import
org.springframework.data.domain.Page
;
import
org.springframework.util.*
;
import
org.springframework.web.bind.annotation.PathVariable
;
import
org.springframework.web.bind.annotation.PostMapping
;
import
org.springframework.web.bind.annotation.RequestBody
;
import
org.springframework.web.bind.annotation.RequestMapping
;
import
org.springframework.web.bind.annotation.RequestMethod
;
import
org.springframework.web.bind.annotation.RequestParam
;
import
org.springframework.web.bind.annotation.RestController
;
import
org.springframework.util.Assert
;
import
org.springframework.util.CollectionUtils
;
import
org.springframework.util.ObjectUtils
;
import
org.springframework.web.bind.annotation.*
;
import
org.springframework.web.multipart.MultipartFile
;
import
javax.servlet.http.HttpServletResponse
;
import
javax.xml.transform.Result
;
import
javax.xml.transform.Source
;
import
javax.xml.transform.Transformer
;
import
javax.xml.transform.TransformerException
;
import
javax.xml.transform.TransformerFactory
;
import
javax.xml.transform.*
;
import
javax.xml.transform.stream.StreamResult
;
import
javax.xml.transform.stream.StreamSource
;
import
java.io.ByteArrayInputStream
;
import
java.io.File
;
import
java.io.FileInputStream
;
import
java.io.IOException
;
import
java.io.InputStream
;
import
java.io.*
;
import
java.text.SimpleDateFormat
;
import
java.util.*
;
import
java.util.stream.Collectors
;
import
org.apache.http.client.methods.HttpGet
;
import
org.apache.http.client.utils.URIBuilder
;
import
org.apache.http.entity.ContentType
;
import
org.apache.http.util.EntityUtils
;
//import com.yeejoin.amos.op.core.common.query.DaoCriteria;
//import com.yeejoin.amos.op.core.common.response.CommonResponse
;
//import com.yeejoin.amos.op.core.util.CommonResponseUtil
;
//import com.yeejoin.amos.security.common.authorization.Authorization
;
//import com.yeejoin.amos.security.common.model.UserModel;
//import org.apache.commons.httpclient.NameValuePair
;
@RestController
@RequestMapping
(
value
=
"/api/check"
)
...
...
AmosBankPatrolService/src/main/java/com/yeejoin/amos/patrol/service/business/controller/PlanTaskController.java
View file @
24df0c3d
...
...
@@ -2,6 +2,7 @@ package com.yeejoin.amos.patrol.service.business.controller;
//import com.yeejoin.amos.op.core.common.response.CommonResponse;
//import com.yeejoin.amos.op.core.util.CommonResponseUtil;
import
com.yeejoin.amos.patrol.common.core.request.CommonPageable
;
import
com.yeejoin.amos.patrol.common.core.request.CommonRequest
;
import
com.yeejoin.amos.patrol.common.core.response.AppPointCheckRespone
;
...
...
@@ -14,6 +15,7 @@ import com.yeejoin.amos.patrol.common.enums.PlanTaskDetailStatusEnum;
import
com.yeejoin.amos.patrol.common.enums.PlanTaskFinishStatusEnum
;
import
com.yeejoin.amos.patrol.common.enums.TaskIsOrderEnum
;
import
com.yeejoin.amos.patrol.service.business.param.PlanTaskPageParam
;
import
com.yeejoin.amos.patrol.service.business.service.impl.PlanTaskServiceImpl
;
import
com.yeejoin.amos.patrol.service.business.service.intfc.IPlanService
;
import
com.yeejoin.amos.patrol.service.business.service.intfc.IPlanTaskService
;
import
com.yeejoin.amos.patrol.service.business.service.intfc.IPointService
;
...
...
@@ -56,6 +58,9 @@ import java.util.Date;
import
java.util.HashMap
;
import
java.util.List
;
import
java.util.Map
;
import
java.util.stream.Collectors
;
import
static
com
.
yeejoin
.
amos
.
patrol
.
service
.
constants
.
XJConstant
.*;
@RestController
@RequestMapping
(
value
=
"/api/planTask"
)
...
...
@@ -71,6 +76,7 @@ public class PlanTaskController extends BaseController {
private
IRouteService
routeService
;
@Autowired
private
IPlanService
planService
;
/**
* 计划执行查询
*
...
...
@@ -89,7 +95,7 @@ public class PlanTaskController extends BaseController {
HashMap
<
String
,
Object
>
paramMap
=
buildMybatisDaoCriterias
(
loginOrgCode
,
roleTypeName
);
PlanTaskPageParam
params
=
new
PlanTaskPageParam
();
PlanTaskPageParamUtil
.
fillChkInfoParam
(
queryRequests
,
commonPageable
,
params
,
paramMap
);
Page
<
HashMap
<
String
,
Object
>>
list
=
planTaskService
.
getPlanTaskInfo
(
getToken
(),
getProduct
(),
getAppKey
(),
params
);
Page
<
HashMap
<
String
,
Object
>>
list
=
planTaskService
.
getPlanTaskInfo
(
getToken
(),
getProduct
(),
getAppKey
(),
params
);
return
CommonResponseUtil
.
success
(
list
);
}
...
...
@@ -113,11 +119,11 @@ public class PlanTaskController extends BaseController {
throw
new
YeeException
(
"结束日期不能为空"
);
}
String
endTime
=
(
String
)
param
.
get
(
"endDate"
);
if
(
judgingTime
(
endTime
))
{
throw
new
YeeException
(
"计划结束时间应在当前时间以后"
);
if
(
judgingTime
(
endTime
))
{
throw
new
YeeException
(
"计划结束时间应在当前时间以后"
);
}
if
(
param
.
get
(
"changeFlag"
)
==
null
)
{
throw
new
YeeException
(
"是否记为合格不能为空"
);
}
...
...
@@ -126,8 +132,8 @@ public class PlanTaskController extends BaseController {
return
CommonResponseUtil
.
success
();
}
catch
(
Exception
e
)
{
log
.
error
(
e
.
getMessage
(),
e
);
if
(
"1"
.
equals
(
e
.
getMessage
()))
{
return
CommonResponseUtil
.
failure
(
"计划已停用"
);
if
(
"1"
.
equals
(
e
.
getMessage
()))
{
return
CommonResponseUtil
.
failure
(
"计划已停用"
);
}
return
CommonResponseUtil
.
failure
(
"计划执行重做失败"
);
}
...
...
@@ -182,7 +188,7 @@ public class PlanTaskController extends BaseController {
HashMap
<
String
,
Object
>
paramMap
=
buildMybatisDaoCriterias
(
loginOrgCode
,
roleTypeName
);
PlanTaskPageParam
params
=
new
PlanTaskPageParam
();
PlanTaskPageParamUtil
.
fillChkInfoParam
(
queryRequests
,
null
,
params
,
paramMap
);
List
<
PlanTaskVo
>
list
=
planTaskService
.
planTaskReport
(
getToken
(),
getProduct
(),
getAppKey
(),
params
);
List
<
PlanTaskVo
>
list
=
planTaskService
.
planTaskReport
(
getToken
(),
getProduct
(),
getAppKey
(),
params
);
String
fileName
=
"计划执行"
+
new
Date
().
getTime
();
FileHelper
.
exportExcel
(
list
,
"计划执行"
,
"计划执行"
,
PlanTaskVo
.
class
,
fileName
+
".xls"
,
response
);
}
catch
(
Exception
e
)
{
...
...
@@ -195,7 +201,7 @@ public class PlanTaskController extends BaseController {
public
void
exportSelectPlanTask
(
@ApiParam
(
value
=
"查询条件"
,
required
=
false
)
@RequestParam
(
required
=
false
)
Long
[]
ids
,
HttpServletResponse
response
)
{
List
<
PlanTaskVo
>
list
=
planTaskService
.
getPlanTaskListByIds
(
getToken
(),
getProduct
(),
getAppKey
(),
ids
);
List
<
PlanTaskVo
>
list
=
planTaskService
.
getPlanTaskListByIds
(
getToken
(),
getProduct
(),
getAppKey
(),
ids
);
String
fileName
=
"巡检记录"
+
new
Date
().
getTime
();
FileHelper
.
exportExcel
(
list
,
"计划执行"
,
"计划执行"
,
PlanTaskVo
.
class
,
fileName
+
".xls"
,
response
);
}
...
...
@@ -208,7 +214,7 @@ public class PlanTaskController extends BaseController {
@RequestMapping
(
value
=
"/queryOmission"
,
method
=
RequestMethod
.
GET
,
produces
=
"application/json;charset=UTF-8"
)
public
CommonResponse
pushCarData
()
{
try
{
log
.
error
(
"定时任务开始生成巡检计划=================================="
);
log
.
error
(
"定时任务开始生成巡检计划=================================="
);
planTaskService
.
taskExecution
(
null
);
log
.
error
(
"定时任务生成巡检计划成功===================================="
);
return
CommonResponseUtil
.
success
();
...
...
@@ -251,10 +257,10 @@ public class PlanTaskController extends BaseController {
@ApiParam
(
value
=
"参数"
,
required
=
true
)
@RequestParam
(
required
=
true
)
String
serial
,
@ApiParam
(
value
=
"参数"
,
required
=
false
)
@RequestParam
(
required
=
false
)
Long
planTaskId
)
{
try
{
HashMap
<
String
,
Object
>
params
=
new
HashMap
<
String
,
Object
>();
HashMap
<
String
,
Object
>
params
=
new
HashMap
<
String
,
Object
>();
ReginParams
reginParams
=
getSelectedOrgInfo
();
//String loginOrgCode = getLoginOrgCode(reginParams);
String
loginOrgCode
=
reginParams
.
getCompany
().
getOrgCode
();
String
loginOrgCode
=
reginParams
.
getCompany
().
getOrgCode
();
params
.
put
(
"orgCode"
,
loginOrgCode
);
String
pointNo
=
serial
;
params
.
put
(
"pointNo"
,
pointNo
);
...
...
@@ -292,8 +298,8 @@ public class PlanTaskController extends BaseController {
}
}
}
return
CommonResponseUtil
.
success
(
point
);
}
catch
(
Exception
e
)
{
log
.
error
(
e
.
getMessage
(),
e
);
...
...
@@ -364,8 +370,8 @@ public class PlanTaskController extends BaseController {
Point
point
=
pointService
.
queryPointById
(
pointId
);
List
<
PointInputItemVo
>
inputItems
=
pointService
.
queryPointClassInputItem
(
pointId
);
Point2
point1
=
new
Point2
();
point1
.
setId
(
point
.
getId
());
Point2
point1
=
new
Point2
();
point1
.
setId
(
point
.
getId
());
point1
.
setCatalogId
(
point
.
getCatalogId
());
point1
.
setCreatorId
(
point
.
getCreatorId
());
point1
.
setDistance
(
point
.
getDistance
());
...
...
@@ -373,30 +379,30 @@ public class PlanTaskController extends BaseController {
point1
.
setIsFixed
(
point
.
getIsFixed
());
point1
.
setIsScore
(
point
.
getIsScore
());
point1
.
setLevel
(
point
.
getLevel
());
point1
.
setName
(
point
.
getName
());
point1
.
setName
(
point
.
getName
());
point1
.
setOffline
(
point
.
getOffline
());
point1
.
setOrgCode
(
point
.
getOrgCode
());
point1
.
setPointNo
(
point
.
getPointNo
());
point1
.
setPointNo
(
point
.
getPointNo
());
point1
.
setSaveGps
(
point
.
getSaveGps
());
point1
.
setShotMaxNumber
(
point
.
getShotMaxNumber
());
point1
.
setShotMinNumber
(
point
.
getShotMaxNumber
());
point1
.
setIsDelete
(
point
.
getIsDelete
());
point1
.
setStatus
(
point
.
getStatus
());
point1
.
setStatus
(
point
.
getStatus
());
point1
.
setFloor
(
point
.
getFloor
());
point1
.
setIsIndoor
(
point
.
getIsIndoor
());
point1
.
setOriginalId
(
point
.
getOriginalId
());
point1
.
setAddress
(
point
.
getAddress
())
;
point1
.
setCoordinates
(
point
.
getCoordinates
())
;
point1
.
setExtendJson
(
point
.
getExtendJson
())
;
point1
.
setLastUpdateTime
(
point
.
getLastUpdateTime
())
;
point1
.
setLatitude
(
point
.
getLatitude
())
;
point1
.
setRemark
(
point
.
getRemark
())
;
point1
.
setRouteId
(
point
.
getRouteId
())
;
point1
.
setRouteName
(
point
.
getRouteName
())
;
point1
.
setUsuallyShot
(
point
.
getUsuallyShot
())
;
point1
.
setChargeDeptId
(
point
.
getChargeDeptId
())
;
point1
.
setChargePersonId
(
point
.
getChargePersonId
())
;
point1
.
setAddress
(
point
.
getAddress
())
;
point1
.
setCoordinates
(
point
.
getCoordinates
())
;
point1
.
setExtendJson
(
point
.
getExtendJson
());
point1
.
setLastUpdateTime
(
point
.
getLastUpdateTime
())
;
point1
.
setLatitude
(
point
.
getLatitude
());
point1
.
setRemark
(
point
.
getRemark
())
;
point1
.
setRouteId
(
point
.
getRouteId
())
;
point1
.
setRouteName
(
point
.
getRouteName
())
;
point1
.
setUsuallyShot
(
point
.
getUsuallyShot
())
;
point1
.
setChargeDeptId
(
point
.
getChargeDeptId
())
;
point1
.
setChargePersonId
(
point
.
getChargePersonId
())
;
response
.
put
(
"checkItem"
,
inputItems
);
List
<
PointClassify
>
catalogs
=
new
ArrayList
<>();
...
...
@@ -406,7 +412,7 @@ public class PlanTaskController extends BaseController {
return
CommonResponseUtil
.
success
(
response
);
}
}
catch
(
Exception
e
)
{
e
.
printStackTrace
();
e
.
printStackTrace
();
return
CommonResponseUtil
.
failure
(
e
.
getMessage
());
}
}
...
...
@@ -423,6 +429,7 @@ public class PlanTaskController extends BaseController {
return
CommonResponseUtil
.
failure
(
"该计划已刷新,请重新选择!!!"
);
}
List
points
=
planTaskService
.
getPlanTaskPoints
(
planTaskId
);
task
=
PlanTaskServiceImpl
.
setColor
(
task
,
points
);
response
.
put
(
"planTask"
,
task
);
response
.
put
(
"points"
,
points
);
return
CommonResponseUtil
.
success
(
response
);
...
...
@@ -445,13 +452,13 @@ public class PlanTaskController extends BaseController {
String
roleTypeName
=
getRoleTypeName
(
reginParams
);
params
=
PlanTaskPageParamUtil
.
fillPlanTask
(
queryRequests
,
params
);
if
(
XJConstant
.
CCPC_PERSONAL
.
equals
(
roleTypeName
))
{
//一线技术,一线业务只能看自己的
//一线技术,一线业务只能看自己的
params
.
put
(
"userId"
,
getUserId
());
params
.
put
(
"orgCode"
,
loginOrgCode
);
}
else
{
//二线技术
//二线技术
params
.
put
(
"orgCode"
,
loginOrgCode
);
}
params
.
put
(
"pageSize"
,
pageable
.
getPageSize
());
...
...
@@ -473,7 +480,7 @@ public class PlanTaskController extends BaseController {
// }
// params.put("ids", ids);
// }
Page
page
=
planTaskService
.
getPlanTasks
(
getToken
(),
getProduct
(),
getAppKey
(),
params
);
Page
page
=
planTaskService
.
getPlanTasks
(
getToken
(),
getProduct
(),
getAppKey
(),
params
);
return
CommonResponseUtil
.
success
(
page
);
}
catch
(
Exception
e
)
{
log
.
error
(
"根据用户条件查询所有计划任务异常"
,
e
);
...
...
@@ -526,7 +533,7 @@ public class PlanTaskController extends BaseController {
// if (XJConstant.ROLE_NAME_PERSON.equals(roleTypeName)) {
// return CommonResponseUtil.success(resp);
// }
if
(
XJConstant
.
CCPC_PERSONAL
.
equals
(
roleTypeName
))
{
return
CommonResponseUtil
.
success
(
resp
);
}
...
...
@@ -556,7 +563,7 @@ public class PlanTaskController extends BaseController {
@ApiParam
(
value
=
"巡检计划任务ID"
,
required
=
true
)
@RequestParam
(
required
=
true
)
Long
planTaskId
,
@ApiParam
(
value
=
"巡检点ID"
,
required
=
true
)
@RequestParam
(
required
=
true
)
Long
pointId
)
{
try
{
AppPointCheckRespone
result
=
planTaskService
.
queryPointPlanTaskDetail
(
getToken
(),
getProduct
(),
getAppKey
(),
planTaskId
,
pointId
);
AppPointCheckRespone
result
=
planTaskService
.
queryPointPlanTaskDetail
(
getToken
(),
getProduct
(),
getAppKey
(),
planTaskId
,
pointId
);
if
(
ObjectUtils
.
isEmpty
(
result
))
{
return
CommonResponseUtil
.
failure
(
"该计划巡检点已更新,请退回重新选择"
);
}
...
...
@@ -570,7 +577,7 @@ public class PlanTaskController extends BaseController {
/**
* 离线同步计划
*/
// @Authorization(ingore = true)
// @Authorization(ingore = true)
@ApiOperation
(
value
=
"获取离线巡检数据"
,
notes
=
"取离线巡检数据"
)
@RequestMapping
(
value
=
"/queryLeavePlanTask"
,
produces
=
"application/json;charset=UTF-8"
,
method
=
RequestMethod
.
GET
)
public
CommonResponse
queryLeavePlanTask
()
{
...
...
@@ -579,54 +586,53 @@ public class PlanTaskController extends BaseController {
String
loginOrgCode
=
getLoginOrgCode
(
reginParams
);
HashMap
<
String
,
Object
>
params
=
new
HashMap
<
String
,
Object
>();
params
.
put
(
"userId"
,
userId
);
params
.
put
(
"orgCode"
,
loginOrgCode
+
"%"
);
List
<
LeavePlanTaskVo
>
list
=
planTaskService
.
queryLeavePlanTask
(
params
);
params
.
put
(
"orgCode"
,
loginOrgCode
+
"%"
);
List
<
LeavePlanTaskVo
>
list
=
planTaskService
.
queryLeavePlanTask
(
params
);
return
CommonResponseUtil
.
success
(
list
);
}
// @Authorization(ingore = true)
// @Authorization(ingore = true)
@ApiOperation
(
value
=
"计划暂停"
,
notes
=
"计划暂停"
)
@RequestMapping
(
value
=
"/endPlan"
,
produces
=
"application/json;charset=UTF-8"
,
method
=
RequestMethod
.
POST
)
public
CommonResponse
endPlan
(
@ApiParam
(
value
=
"巡检计划ID"
,
required
=
true
)
@RequestBody
String
[]
ids
)
{
public
CommonResponse
endPlan
(
@ApiParam
(
value
=
"巡检计划ID"
,
required
=
true
)
@RequestBody
String
[]
ids
)
{
try
{
List
<
String
>
resultList
=
new
ArrayList
<>(
Arrays
.
asList
(
ids
));
planService
.
endPlan
(
resultList
);
return
CommonResponseUtil
.
success
();
}
catch
(
Exception
e
)
{
return
CommonResponseUtil
.
failure
();
try
{
List
<
String
>
resultList
=
new
ArrayList
<>(
Arrays
.
asList
(
ids
));
planService
.
endPlan
(
resultList
);
return
CommonResponseUtil
.
success
();
}
catch
(
Exception
e
)
{
return
CommonResponseUtil
.
failure
();
}
}
}
//@Authorization(ingore = true)
@ApiOperation
(
value
=
"计划启用"
,
notes
=
"计划启用"
)
@RequestMapping
(
value
=
"/startplan"
,
produces
=
"application/json;charset=UTF-8"
,
method
=
RequestMethod
.
POST
)
public
CommonResponse
startplan
(
@ApiParam
(
value
=
"巡检计划ID"
,
required
=
true
)
@RequestBody
String
[]
ids
)
{
try
{
List
<
String
>
resultList
=
new
ArrayList
<>(
Arrays
.
asList
(
ids
));
planTaskService
.
startplan
(
resultList
);
public
CommonResponse
startplan
(
@ApiParam
(
value
=
"巡检计划ID"
,
required
=
true
)
@RequestBody
String
[]
ids
)
{
try
{
List
<
String
>
resultList
=
new
ArrayList
<>(
Arrays
.
asList
(
ids
));
planTaskService
.
startplan
(
resultList
);
return
CommonResponseUtil
.
success
();
}
catch
(
Exception
e
)
{
return
CommonResponseUtil
.
failure
();
return
CommonResponseUtil
.
success
();
}
catch
(
Exception
e
)
{
return
CommonResponseUtil
.
failure
();
}
}
}
/**
* 判断结束时间是否在当前时间以前
*
@param endTime
*
* @return
*/
private
boolean
judgingTime
(
String
endData
)
{
LocalDate
endOfFeb
=
LocalDate
.
parse
(
endData
);
return
endOfFeb
.
isBefore
(
LocalDate
.
now
());
LocalDate
endOfFeb
=
LocalDate
.
parse
(
endData
);
return
endOfFeb
.
isBefore
(
LocalDate
.
now
());
}
}
AmosBankPatrolService/src/main/java/com/yeejoin/amos/patrol/service/business/service/impl/CheckServiceImpl.java
View file @
24df0c3d
...
...
@@ -122,7 +122,7 @@ public class CheckServiceImpl implements ICheckService {
//deptMap = deptList.stream().collect(Collectors.toMap(DepartmentModel::getSequenceNbr, DepartmentModel::getDepartmentName));
for
(
int
i
=
0
;
i
<
deptList
.
size
();
i
++)
{
deptMap
.
put
(
String
Util
.
toString
(
deptList
.
get
(
i
).
get
(
"sequenceNbr"
)),
StringUtil
.
toString
(
deptList
.
get
(
i
).
get
(
"departmentName"
)));
deptMap
.
put
(
String
.
valueOf
(
deptList
.
get
(
i
).
get
(
"sequenceNbr"
)),
String
.
valueOf
(
deptList
.
get
(
i
).
get
(
"departmentName"
)));
}
...
...
@@ -167,11 +167,11 @@ public class CheckServiceImpl implements ICheckService {
planTask
=
planTaskDao
.
findById
(
requestParam
.
getPlanTaskId
()).
get
();
// routeParam.put("routeId", planTask.getRouteId());
// routeParam.put("pointId", requestParam.getPointId());
check
.
setPlanTaskDetailId
(
Long
.
parseLong
(
String
Util
.
toString
(
detail
.
get
(
"planTaskDetailId"
))));
check
.
setRouteId
(
Long
.
parseLong
(
String
Util
.
toString
(
detail
.
get
(
"routeId"
))));
check
.
setPlanTaskDetailId
(
Long
.
parseLong
(
String
.
valueOf
(
detail
.
get
(
"planTaskDetailId"
))));
check
.
setRouteId
(
Long
.
parseLong
(
String
.
valueOf
(
detail
.
get
(
"routeId"
))));
check
.
setPlanTaskId
(
requestParam
.
getPlanTaskId
());
check
.
setPlanId
(
planTask
.
getPlanId
());
check
.
setDepId
(
String
Util
.
toString
(
detail
.
get
(
"depId"
)));
check
.
setDepId
(
String
.
valueOf
(
detail
.
get
(
"depId"
)));
}
}
else
{
planTask
=
new
PlanTask
();
...
...
@@ -1014,8 +1014,8 @@ public class CheckServiceImpl implements ICheckService {
//新安全
checkAnalysisVos
.
forEach
(
s
->
{
listd
.
forEach
(
s1
->
{
if
(
s
.
getName
().
equals
(
String
Util
.
toString
(
s1
.
get
(
"sequenceNbr"
))))
{
s
.
setName
(
String
Util
.
toString
(
s1
.
get
(
"departmentName"
)));
if
(
s
.
getName
().
equals
(
String
.
valueOf
(
s1
.
get
(
"sequenceNbr"
))))
{
s
.
setName
(
String
.
valueOf
(
s1
.
get
(
"departmentName"
)));
}
});
});
...
...
@@ -1042,20 +1042,20 @@ public class CheckServiceImpl implements ICheckService {
faildRate
+=
Double
.
parseDouble
(
checkAnalysisVo
.
getFaildRate
());
}
countVo
.
setName
(
"合计"
);
countVo
.
setPlanTaskCount
(
String
Util
.
toString
(
planTaskCount
));
countVo
.
setCheckCount
(
String
Util
.
toString
(
checkCount
));
countVo
.
setOk
(
String
Util
.
toString
(
ok
));
countVo
.
setFaild
(
String
Util
.
toString
(
faild
));
countVo
.
setMissed
(
String
Util
.
toString
(
missed
));
countVo
.
setPlanTaskCount
(
String
.
valueOf
(
planTaskCount
));
countVo
.
setCheckCount
(
String
.
valueOf
(
checkCount
));
countVo
.
setOk
(
String
.
valueOf
(
ok
));
countVo
.
setFaild
(
String
.
valueOf
(
faild
));
countVo
.
setMissed
(
String
.
valueOf
(
missed
));
if
(
size
==
0
)
{
countVo
.
setScore
(
"0"
);
countVo
.
setMissedRate
(
"0"
);
countVo
.
setFaildRate
(
"0"
);
}
else
{
countVo
.
setScore
(
String
Util
.
toString
(
score
/
size
));
countVo
.
setMissedRate
(
String
Util
.
toString
(
missedRate
/
size
));
countVo
.
setFaildRate
(
String
Util
.
toString
(
faildRate
/
size
));
countVo
.
setScore
(
String
.
valueOf
(
score
/
size
));
countVo
.
setMissedRate
(
String
.
valueOf
(
missedRate
/
size
));
countVo
.
setFaildRate
(
String
.
valueOf
(
faildRate
/
size
));
}
checkAnalysisVos
.
add
(
countVo
);
return
checkAnalysisVos
;
...
...
@@ -1091,8 +1091,8 @@ public class CheckServiceImpl implements ICheckService {
//新安全
checkAnalysisVos
.
forEach
(
s
->
{
listd
.
forEach
(
s1
->
{
if
(!
ObjectUtils
.
isEmpty
(
s
.
getName
())
&&
s
.
getName
().
equals
(
String
Util
.
toString
(
s1
.
get
(
"sequenceNbr"
))))
{
s
.
setName
(
DeptEnum
.
getEnumCode
(
String
Util
.
toString
(
s1
.
get
(
"departmentName"
))));
if
(!
ObjectUtils
.
isEmpty
(
s
.
getName
())
&&
s
.
getName
().
equals
(
String
.
valueOf
(
s1
.
get
(
"sequenceNbr"
))))
{
s
.
setName
(
DeptEnum
.
getEnumCode
(
String
.
valueOf
(
s1
.
get
(
"departmentName"
))));
}
});
});
...
...
@@ -1249,6 +1249,7 @@ public class CheckServiceImpl implements ICheckService {
}
PoiUtil
.
export
(
wb
,
response
);
//PoiUtil.exportLocal(wb, "D:/upload", "机构客户信息表.xls");
}
private
Map
<
String
,
Object
>
getStateMap
(
String
idState
)
{
...
...
@@ -1292,15 +1293,16 @@ public class CheckServiceImpl implements ICheckService {
boolean
flag3
=
true
;
for
(
int
i
=
0
;
i
<
checkInfoList
.
size
();
i
++)
{
String
checkDate
=
checkInfoList
.
get
(
i
).
getCheckDate
();
String
pointName
=
checkInfoList
.
get
(
i
).
getPointName
();
String
classifyName
=
checkInfoList
.
get
(
i
).
getClassifyName
();
CheckInputBo
checkInputBo
=
checkInfoList
.
get
(
i
);
String
pointName
=
StringUtil
.
setStr
(
checkInputBo
.
getPlanTaskId
(),
checkInputBo
.
getPointName
());
String
classifyName
=
StringUtil
.
setStr
(
checkInputBo
.
getPlanTaskId
(),
checkInputBo
.
getClassifyName
());
String
beginTime
=
checkInputBo
.
getBeginTime
();
if
(
flag1
)
{
lastDate
=
checkDat
e
;
lastDate
=
beginTim
e
;
flag1
=
false
;
}
if
(
i
!=
0
&&
lastDate
.
equals
(
checkDate
))
{
if
(
i
!=
0
&&
(
null
==
lastDate
?
null
==
beginTime
:
lastDate
.
equals
(
beginTime
)))
{
endRow1
++;
}
else
{
//两者不相同时,融合之前相同的行
...
...
@@ -1309,7 +1311,7 @@ public class CheckServiceImpl implements ICheckService {
}
startRow1
=
temNum1
;
endRow1
=
startRow1
;
lastDate
=
checkDat
e
;
lastDate
=
beginTim
e
;
}
temNum1
++;
if
(
i
==
checkInfoList
.
size
()
-
1
&&
startRow1
!=
endRow1
)
{
...
...
@@ -1360,10 +1362,10 @@ public class CheckServiceImpl implements ICheckService {
}
row
=
sheet
.
createRow
(
i
+
3
);
HSSFCell
cell
=
row
.
createCell
(
0
);
if
(
ObjectUtils
.
isEmpty
(
checkIn
foList
.
get
(
i
)
.
getBeginTime
()))
{
cell
.
setCellValue
(
DateUtil
.
splitDate
(
checkIn
foList
.
get
(
i
)
.
getCheckDate
()));
if
(
ObjectUtils
.
isEmpty
(
checkIn
putBo
.
getBeginTime
()))
{
cell
.
setCellValue
(
DateUtil
.
splitDate
(
checkIn
putBo
.
getCheckDate
()));
}
else
{
cell
.
setCellValue
(
DateUtil
.
splitDate
(
checkIn
foList
.
get
(
i
)
.
getBeginTime
()));
cell
.
setCellValue
(
DateUtil
.
splitDate
(
checkIn
putBo
.
getBeginTime
()));
}
cell
.
setCellStyle
(
contentStyle
);
HSSFCell
cell1
=
row
.
createCell
(
1
);
...
...
@@ -1404,8 +1406,9 @@ public class CheckServiceImpl implements ICheckService {
boolean
flag2
=
true
;
for
(
int
i
=
0
;
i
<
checkInfoList
.
size
();
i
++)
{
String
pointName
=
StringUtil
.
toString
(
checkInfoList
.
get
(
i
).
get
(
"pointName"
));
String
classifyName
=
StringUtil
.
toString
(
checkInfoList
.
get
(
i
).
get
(
"classifyName"
));
Map
<
String
,
Object
>
map
=
checkInfoList
.
get
(
i
);
String
pointName
=
String
.
valueOf
(
map
.
get
(
"pointName"
));
String
classifyName
=
StringUtil
.
setStr
(
String
.
valueOf
(
map
.
get
(
"pointId"
)),
String
.
valueOf
(
map
.
get
(
"classifyName"
)));
if
(
flag1
)
{
lastPointName
=
pointName
;
flag1
=
false
;
...
...
@@ -1450,16 +1453,16 @@ public class CheckServiceImpl implements ICheckService {
}
row
=
sheet
.
createRow
(
i
+
3
);
HSSFCell
cell
=
row
.
createCell
(
0
);
cell
.
setCellValue
(
String
Util
.
toString
(
checkInfoList
.
get
(
i
)
.
get
(
"pointName"
)));
cell
.
setCellValue
(
String
.
valueOf
(
map
.
get
(
"pointName"
)));
cell
.
setCellStyle
(
contentStyle
);
HSSFCell
cell1
=
row
.
createCell
(
1
);
cell1
.
setCellValue
(
String
Util
.
toString
(
checkInfoList
.
get
(
i
)
.
get
(
"classifyName"
)));
cell1
.
setCellValue
(
String
.
valueOf
(
map
.
get
(
"classifyName"
)));
cell1
.
setCellStyle
(
contentStyle
);
HSSFCell
cell2
=
row
.
createCell
(
2
);
cell2
.
setCellStyle
(
contentStyle
);
cell2
.
setCellValue
(
String
Util
.
toString
(
checkInfoList
.
get
(
i
)
.
get
(
"inputItemName"
)));
cell2
.
setCellValue
(
String
.
valueOf
(
map
.
get
(
"inputItemName"
)));
for
(
int
j
=
0
;
j
<
sp
.
length
;
j
++)
{
Map
<
String
,
Object
>
checkInfoMap
=
checkInfoList
.
get
(
i
)
;
Map
<
String
,
Object
>
checkInfoMap
=
map
;
HSSFCell
cellA
=
row
.
createCell
(
3
+
j
);
cellA
.
setCellValue
(
checkInfoMap
.
get
(
sp
[
j
]).
toString
());
cellA
.
setCellStyle
(
alignLeftStyle
);
...
...
@@ -1476,9 +1479,9 @@ public class CheckServiceImpl implements ICheckService {
children
.
forEach
(
y
->
{
Map
<
String
,
Object
>
map
=
new
HashMap
<>();
String
key
=
DeptEnum
.
getEnumCode
(
String
Util
.
toString
(
y
.
get
(
"departmentName"
)));
String
key
=
DeptEnum
.
getEnumCode
(
String
.
valueOf
(
y
.
get
(
"departmentName"
)));
map
.
put
(
"key"
,
key
);
map
.
put
(
"label"
,
String
Util
.
toString
(
y
.
get
(
"departmentName"
)));
map
.
put
(
"label"
,
String
.
valueOf
(
y
.
get
(
"departmentName"
)));
list
.
add
(
map
);
}
);
...
...
@@ -1510,7 +1513,7 @@ public class CheckServiceImpl implements ICheckService {
Collection
<
Map
>
children
=
x
.
getChildren
();
children
.
forEach
(
y
->
{
String
key
=
DeptEnum
.
getEnumCode
(
String
Util
.
toString
(
y
.
get
(
"departmentName"
)));
String
key
=
DeptEnum
.
getEnumCode
(
String
.
valueOf
(
y
.
get
(
"departmentName"
)));
List
<
CheckAnalysisVo
>
collect
=
checkAnalysisVos
.
stream
().
filter
(
z
->
key
.
equals
(
z
.
getName
())
&&
z
.
getCheckTime
().
equals
(
day
)).
collect
(
Collectors
.
toList
());
String
plantaskCount
=
getCount
(
collect
,
PLANTASK_COUNT
);
String
checkCount
=
getCount
(
collect
,
CHECK_COUNT
);
...
...
@@ -1563,7 +1566,7 @@ public class CheckServiceImpl implements ICheckService {
private
void
getTotal
(
Map
<
String
,
Object
>
totalMap
,
String
type
,
String
key
,
Long
num
)
{
long
total
=
0
;
if
(!
ObjectUtils
.
isEmpty
(
totalMap
.
get
(
type
+
key
)))
{
total
=
Long
.
valueOf
(
String
Util
.
toString
(
totalMap
.
get
(
type
+
key
)));
total
=
Long
.
valueOf
(
String
.
valueOf
(
totalMap
.
get
(
type
+
key
)));
}
num
+=
total
;
totalMap
.
put
(
type
+
key
,
num
.
toString
());
...
...
AmosBankPatrolService/src/main/java/com/yeejoin/amos/patrol/service/business/service/impl/PlanTaskServiceImpl.java
View file @
24df0c3d
...
...
@@ -71,6 +71,8 @@ import java.util.Optional;
import
java.util.Set
;
import
java.util.stream.Collectors
;
import
static
com
.
yeejoin
.
amos
.
patrol
.
service
.
constants
.
XJConstant
.*;
@Service
(
"planTaskService"
)
public
class
PlanTaskServiceImpl
implements
IPlanTaskService
{
private
final
Logger
log
=
LoggerFactory
.
getLogger
(
PlanTaskServiceImpl
.
class
);
...
...
@@ -556,6 +558,15 @@ public class PlanTaskServiceImpl implements IPlanTaskService {
return
new
PageImpl
<>(
content
,
pageParam
,
total
);
}
content
=
planTaskMapper
.
getPlanTasks
(
params
);
content
.
forEach
(
x
->
{
List
list
=
new
ArrayList
();
if
(
Integer
.
valueOf
(
String
.
valueOf
(
x
.
get
(
"finishStatus"
)))
==
2
)
{
list
=
planTaskMapper
.
getPlanTaskPoints
(
Long
.
valueOf
(
String
.
valueOf
(
x
.
get
(
"planTaskId"
))));
}
setColor
(
x
,
list
);
}
);
if
(!
CollectionUtils
.
isEmpty
(
content
))
{
Set
<
String
>
userIds
=
Sets
.
newHashSet
();
content
.
forEach
(
e
->
{
...
...
@@ -839,4 +850,32 @@ public class PlanTaskServiceImpl implements IPlanTaskService {
}
return
date
;
}
/**
* 设置显示颜色
*
* @return
*/
public
static
Map
setColor
(
Map
task
,
List
<
Map
>
points
)
{
Integer
finishStatus
=
Integer
.
valueOf
(
String
.
valueOf
(
task
.
get
(
"finishStatus"
)));
task
.
put
(
TASK_FIELD
,
STATUS_NORMAL
);
switch
(
finishStatus
)
{
case
0
:
task
.
put
(
TASK_FIELD
,
STATUS_NOTSTART
);
break
;
case
1
:
task
.
put
(
TASK_FIELD
,
STATUS_UNDERWAY
);
break
;
case
2
:
List
<
Map
>
list
=
points
.
stream
().
filter
(
x
->
!
ObjectUtils
.
isEmpty
(
x
)
&&
"2"
.
equals
(
x
.
get
(
"status"
))).
collect
(
Collectors
.
toList
());
if
(
list
.
size
()
>
0
)
{
task
.
put
(
TASK_FIELD
,
STATUS_UNNORMAL
);
}
break
;
case
3
:
task
.
put
(
TASK_FIELD
,
STATUS_OVERTIME
);
break
;
}
return
task
;
}
}
AmosBankPatrolService/src/main/java/com/yeejoin/amos/patrol/service/constants/XJConstant.java
View file @
24df0c3d
...
...
@@ -410,4 +410,13 @@ public class XJConstant {
public
static
final
String
CHECK_COUNT
=
"checkCount"
;
public
static
final
String
MISSED
=
"missed"
;
public
static
final
String
FAILD
=
"faild"
;
public
static
final
String
JOINT
=
"-"
;
public
static
final
String
TASK_FIELD
=
"showColor"
;
public
static
final
String
STATUS_NORMAL
=
"normal"
;
//正常
public
static
final
String
STATUS_UNNORMAL
=
"unnormal"
;
//异常
public
static
final
String
STATUS_NOTSTART
=
"notstart"
;
//未开始
public
static
final
String
STATUS_UNDERWAY
=
"underway"
;
//进行中
public
static
final
String
STATUS_OVERTIME
=
"overtime"
;
//超时
}
AmosBankPatrolService/src/main/java/com/yeejoin/amos/patrol/service/core/util/StringUtil.java
View file @
24df0c3d
package
com
.
yeejoin
.
amos
.
patrol
.
service
.
core
.
util
;
import
org.springframework.util.Assert
;
import
java.math.BigDecimal
;
import
java.util.regex.Matcher
;
import
java.util.regex.Pattern
;
import
org.springframework.util.Assert
;
import
static
com
.
yeejoin
.
amos
.
patrol
.
service
.
constants
.
XJConstant
.
JOINT
;
/**
* 字符串工具类
...
...
@@ -155,7 +157,8 @@ public class StringUtil {
}
}
public
static
String
toString
(
Object
str
){
return
str
+
""
;
public
static
String
setStr
(
String
str1
,
String
str2
)
{
String
str
=
str1
+
JOINT
+
str2
;
return
str
;
}
}
AmosBankPatrolStart/src/main/resources/db/mapper/dbTemplate_check.xml
View file @
24df0c3d
...
...
@@ -166,16 +166,19 @@
'%Y-%m-%d %H:%i:%s'
) AS `checkDate`,
pt.id planTaskId,
pt.begin_time beginTime,
date_format(
pt.begin_time,
'%Y-%m-%d %H:%i:%s'
) AS `beginTime`,
ci.id checkInputId,
ci.input_id inputId,
ci.input_value AS InputValue,
(
CASE ci.is_ok
WHEN 1 THEN
'
合格
'
'
正常
'
WHEN 2 THEN
'
不合格
'
'
异常
'
WHEN 3 THEN
'漏检'
END
...
...
@@ -233,9 +236,9 @@
(
CASE ci.is_ok
WHEN 1 THEN
'
合格
'
'
正常
'
WHEN 2 THEN
'
不合格
'
'
异常
'
WHEN 3 THEN
'漏检'
END
...
...
@@ -264,7 +267,7 @@
<select
id=
"getCheckInfoGroupCheckDate"
resultMap=
"checkInputResultMap"
>
SELECT
GROUP_CONCAT(DISTINCT a.begin_Time order by a.begin_Time
de
sc) as beginTimeStr
GROUP_CONCAT(DISTINCT a.begin_Time order by a.begin_Time
a
sc) as beginTimeStr
FROM
p_plan_task_detail b
LEFT JOIN p_plan_task a ON a.id = b.task_no
...
...
@@ -928,6 +931,7 @@
<result
property=
"pointName"
column=
"pointName"
/>
<result
property=
"orgCode"
column=
"orgCode"
/>
<result
property=
"checkDate"
column=
"checkDate"
/>
<result
property=
"planTaskId"
column=
"planTaskId"
/>
<result
property=
"beginTime"
column=
"beginTime"
/>
<result
property=
"beginTimeStr"
column=
"beginTimeStr"
/>
<result
property=
"idStateStr"
column=
"idStateStr"
/>
...
...
@@ -1897,9 +1901,9 @@
p_plan_task_detail ptd
LEFT JOIN p_plan_task pnt ON pnt.id = ptd.task_no
LEFT JOIN p_plan p ON p.id = pnt.plan_id
LEFT JOIN p_point pt ON pt.id = ptd.id
LEFT JOIN p_point pt ON pt.id = ptd.
point_
id
LEFT JOIN p_route r ON r.id = pnt.route_id
LEFT JOIN p_check c ON c.plan_task_
id = pnt
.id
LEFT JOIN p_check c ON c.plan_task_
detail_id = ptd
.id
WHERE pnt.org_code LIKE CONCAT(#{orgCode}, '%')
<if
test=
"startTime !=null and startTime!= '' "
>
<![CDATA[ AND pnt.check_date >= #{startTime} ]]>
</if>
<if
test=
"endTime !=null and endTime!='' "
>
<![CDATA[AND pnt.check_date <= #{endTime} ]]>
</if>
...
...
@@ -1955,7 +1959,7 @@
0
END missed,
CASE
WHEN
(pnt.finish_status = 1 or pnt.finish_status = 2)
THEN
WHEN
pnt.finish_status = 2
THEN
1
ELSE
0
...
...
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