Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
S
sunac_report
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
java-sunac-report
sunac_report
Commits
d8c18c66
Commit
d8c18c66
authored
Sep 22, 2017
by
Java-李昕颖
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
转为文档、发邮件,以及各种改终极版
parent
5f12e018
Show whitespace changes
Inline
Side-by-side
Showing
13 changed files
with
705 additions
and
67 deletions
+705
-67
pom.xml
pom.xml
+12
-0
ReportDao.java
src/main/java/com/ejweb/modules/report/dao/ReportDao.java
+2
-1
ReportService.java
src/main/java/com/ejweb/modules/report/service/ReportService.java
+23
-1
ReportController.java
src/main/java/com/ejweb/modules/report/web/ReportController.java
+16
-21
ReportToPdfController.java
src/main/java/com/ejweb/modules/report/web/ReportToPdfController.java
+241
-0
Position.java
src/main/java/com/ejweb/modules/sys/entity/Position.java
+26
-0
User.java
src/main/java/com/ejweb/modules/sys/entity/User.java
+5
-5
ReportDao.xml
src/main/resources/mappings/modules/report/ReportDao.xml
+5
-4
reportDeliver.jsp
src/main/webapp/WEB-INF/views/modules/report/reportDeliver.jsp
+303
-0
reportDetail.jsp
src/main/webapp/WEB-INF/views/modules/report/reportDetail.jsp
+1
-1
reportForm.jsp
src/main/webapp/WEB-INF/views/modules/report/reportForm.jsp
+0
-9
reportList.jsp
src/main/webapp/WEB-INF/views/modules/report/reportList.jsp
+27
-2
reportTrack.jsp
src/main/webapp/WEB-INF/views/modules/report/reportTrack.jsp
+44
-23
No files found.
pom.xml
View file @
d8c18c66
...
...
@@ -615,6 +615,18 @@
<artifactId>
jfreechart
</artifactId>
<version>
1.0.13
</version>
</dependency>
<!-- https://mvnrepository.com/artifact/com.itextpdf/itextpdf -->
<dependency>
<groupId>
com.itextpdf
</groupId>
<artifactId>
itextpdf
</artifactId>
<version>
5.5.10
</version>
</dependency>
<!-- https://mvnrepository.com/artifact/com.itextpdf/itext-asian -->
<dependency>
<groupId>
com.itextpdf
</groupId>
<artifactId>
itext-asian
</artifactId>
<version>
5.2.0
</version>
</dependency>
<!-- 自定义jar依赖包
<dependency>
...
...
src/main/java/com/ejweb/modules/report/dao/ReportDao.java
View file @
d8c18c66
...
...
@@ -6,6 +6,7 @@ import com.ejweb.modules.report.entity.ReportAttachmentEntity;
import
com.ejweb.modules.report.entity.ReportEntity
;
import
com.ejweb.modules.report.entity.ReportExchangeHistory
;
import
com.ejweb.modules.sys.entity.Office
;
import
com.ejweb.modules.sys.entity.Position
;
import
com.ejweb.modules.sys.entity.User
;
import
com.ejweb.modules.workbench.Bean.WorkbenchBean
;
import
com.ejweb.modules.workbench.entity.ReportNotice
;
...
...
@@ -85,7 +86,7 @@ public interface ReportDao extends CrudDao<ReportEntity> {
* 查询职位列表
* @return
*/
public
List
<
User
>
getPositionList
();
public
List
<
Position
>
getPositionList
();
/**
* 根据reportId查询消息表中是否已存在该条记录
...
...
src/main/java/com/ejweb/modules/report/service/ReportService.java
View file @
d8c18c66
...
...
@@ -9,6 +9,8 @@ import com.ejweb.modules.report.entity.ReportAttachmentEntity;
import
com.ejweb.modules.report.entity.ReportEntity
;
import
com.ejweb.modules.report.entity.ReportExchangeHistory
;
import
com.ejweb.modules.sys.entity.Office
;
import
com.ejweb.modules.sys.entity.Position
;
import
com.ejweb.modules.sys.entity.Role
;
import
com.ejweb.modules.sys.entity.User
;
import
com.ejweb.modules.sys.utils.UserUtils
;
import
com.ejweb.modules.workbench.entity.ReportNotice
;
...
...
@@ -190,6 +192,7 @@ public class ReportService extends CrudService<ReportDao, ReportEntity> {
* @return
*/
public
Page
<
User
>
findUserPage
(
Page
<
User
>
page
,
User
user
){
page
.
setFuncParam
(
"1"
);
//标记为用户分页
user
.
setPage
(
page
);
page
.
setList
(
reportDao
.
findUser
(
user
));
return
page
;
...
...
@@ -215,7 +218,7 @@ public class ReportService extends CrudService<ReportDao, ReportEntity> {
* 查询职位列表
* @return
*/
public
List
<
User
>
getPositionList
(){
public
List
<
Position
>
getPositionList
(){
return
reportDao
.
getPositionList
();
}
...
...
@@ -380,4 +383,23 @@ public class ReportService extends CrudService<ReportDao, ReportEntity> {
this
.
addRecord
(
reportEntity
,
"2"
);
}
}
/**
* 判断当前用户是否为管理员
* @param user
* @return
*/
public
boolean
checkRole
(
User
user
)
{
boolean
isAdmin
=
false
;
List
<
Role
>
roleList
=
UserUtils
.
getRoleList
();
if
(
roleList
!=
null
&&
roleList
.
size
()
!=
0
){
for
(
Role
role
:
roleList
){
if
(
role
.
getName
().
equals
(
"系统管理员"
)){
isAdmin
=
true
;
break
;
}
}
}
return
isAdmin
;
}
}
src/main/java/com/ejweb/modules/report/web/ReportController.java
View file @
d8c18c66
package
com
.
ejweb
.
modules
.
report
.
web
;
import
com.alibaba.fastjson.JSONObject
;
import
com.ejweb.core.base.BaseController
;
import
com.ejweb.core.persistence.Page
;
import
com.ejweb.core.utils.DateUtils
;
...
...
@@ -10,6 +9,7 @@ import com.ejweb.modules.report.entity.ReportAttachmentEntity;
import
com.ejweb.modules.report.entity.ReportEntity
;
import
com.ejweb.modules.report.service.ReportService
;
import
com.ejweb.modules.sys.entity.Office
;
import
com.ejweb.modules.sys.entity.Position
;
import
com.ejweb.modules.sys.entity.User
;
import
com.ejweb.modules.sys.utils.UserUtils
;
import
org.apache.shiro.authz.annotation.RequiresPermissions
;
...
...
@@ -63,12 +63,9 @@ public class ReportController extends BaseController {
public
String
list
(
ReportEntity
reportEntity
,
String
flag
,
HttpServletRequest
request
,
HttpServletResponse
response
,
Model
model
)
{
//判断登录人的角色
User
user
=
UserUtils
.
getUser
();
String
roleName
=
reportService
.
findRole
(
user
);
if
(
StringUtils
.
isNotBlank
(
roleName
)){
if
(!
roleName
.
equals
(
"系统管理员"
)){
if
(!
reportService
.
checkRole
(
user
)){
reportEntity
.
setExchangeAfterUser
(
user
.
getId
());
}
}
//判断标签状态 flag为空,跳转到核查中举报列表 flag为0,跳转到未处理举报列表 flag为1,跳转到举报列表
if
(
StringUtils
.
isNotBlank
(
flag
)){
if
(
flag
.
equals
(
"0"
)){
...
...
@@ -151,27 +148,23 @@ public class ReportController extends BaseController {
*/
@RequestMapping
(
value
=
"track"
)
public
String
track
(
ReportEntity
reportEntity
,
HttpServletRequest
request
,
HttpServletResponse
response
,
Model
model
)
{
//判断登录人的角色
User
user
=
UserUtils
.
getUser
();
String
roleName
=
reportService
.
findRole
(
user
);
String
transferFlag
=
"0"
;
if
(
roleName
.
equals
(
"系统管理员"
)){
transferFlag
=
"1"
;
}
boolean
isAdmin
=
reportService
.
checkRole
(
user
);
List
<
Office
>
companyList
=
reportService
.
getCompanyList
();
List
<
Office
>
officeList
=
reportService
.
getOfficeList
();
List
<
User
>
positionList
=
reportService
.
getPositionList
();
Page
<
User
>
page
=
reportService
.
findUserPage
(
new
Page
<
User
>(
request
,
response
),
user
);
List
<
Position
>
positionList
=
reportService
.
getPositionList
();
User
userEntity
=
new
User
();
Page
<
User
>
userP
age
=
reportService
.
findUserPage
(
new
Page
<
User
>(
request
,
response
),
userEntity
);
Page
<
User
>
p
age
=
reportService
.
findUserPage
(
new
Page
<
User
>(
request
,
response
),
userEntity
);
model
.
addAttribute
(
"page"
,
page
);
model
.
addAttribute
(
"user"
,
userEntity
);
model
.
addAttribute
(
"userName"
,
user
.
getName
());
model
.
addAttribute
(
"currentUser"
,
user
.
getName
());
model
.
addAttribute
(
"transferFlag"
,
transferFlag
);
model
.
addAttribute
(
"report"
,
reportEntity
);
model
.
addAttribute
(
"companyList"
,
companyList
);
model
.
addAttribute
(
"officeList"
,
officeList
);
model
.
addAttribute
(
"positionList"
,
positionList
);
model
.
addAttribute
(
"
userPage"
,
userPage
);
model
.
addAttribute
(
"
isAdmin"
,
isAdmin
);
return
"modules/report/reportTrack"
;
}
...
...
@@ -189,7 +182,7 @@ public class ReportController extends BaseController {
}
reportService
.
saveTrack
(
reportEntity
);
if
(
StringUtils
.
isNotBlank
(
reportEntity
.
getExchangeAfterUser
())){
reportService
.
addNotice
(
reportEntity
,
"trans
g
er"
);
reportService
.
addNotice
(
reportEntity
,
"trans
f
er"
);
reportService
.
addRecord
(
reportEntity
,
"1"
);
}
if
(
StringUtils
.
isNotBlank
(
reportEntity
.
getDealResult
())){
...
...
@@ -247,7 +240,11 @@ public class ReportController extends BaseController {
html
.
append
(
" <td>"
+
(
userEntity
.
getMobile
()
==
null
?
""
:
userEntity
.
getMobile
())
+
"</td>"
);
html
.
append
(
" <td>"
+
(
userEntity
.
getCompany
()
==
null
?
""
:
userEntity
.
getCompany
().
getName
())
+
"</td>"
);
html
.
append
(
" <td>"
+
(
userEntity
.
getOffice
()
==
null
?
""
:
userEntity
.
getOffice
().
getName
())
+
"</td>"
);
html
.
append
(
" <td>"
+
(
userEntity
.
getPositionName
()
==
null
?
""
:
userEntity
.
getPositionName
())
+
"</td>"
);
if
(
userEntity
.
getPosition
()
!=
null
){
html
.
append
(
" <td>"
+
(
userEntity
.
getPosition
().
getName
()
==
null
?
""
:
userEntity
.
getPosition
().
getName
())
+
"</td>"
);
}
else
{
html
.
append
(
" <td></td>"
);
}
}
else
if
(
flag
.
equals
(
"2"
)){
html
.
append
(
" <td><input type='radio' value='"
+
userEntity
.
getId
()
+
"' onclick='chooseRen(this);'></td>"
);
html
.
append
(
" <td>"
+
i
+
"</td>"
);
...
...
@@ -302,12 +299,9 @@ public class ReportController extends BaseController {
public
String
deliverList
(
ReportEntity
reportEntity
,
HttpServletRequest
request
,
HttpServletResponse
response
,
Model
model
)
{
//判断登录人的角色
User
user
=
UserUtils
.
getUser
();
String
roleName
=
reportService
.
findRole
(
user
);
if
(
StringUtils
.
isNotBlank
(
roleName
)){
if
(!
roleName
.
equals
(
"系统管理员"
)){
if
(!
reportService
.
checkRole
(
user
)){
reportEntity
.
setExchangeAfterUser
(
user
.
getId
());
}
}
Page
<
ReportEntity
>
page
=
reportService
.
getChooseReportPage
(
new
Page
<
ReportEntity
>(
request
,
response
),
reportEntity
);
User
userEntity
=
new
User
();
Page
<
User
>
userPage
=
reportService
.
findUserPage
(
new
Page
<
User
>(
request
,
response
),
userEntity
);
...
...
@@ -336,4 +330,5 @@ public class ReportController extends BaseController {
out
.
write
(
result
);
out
.
close
();
}
}
src/main/java/com/ejweb/modules/report/web/ReportToPdfController.java
0 → 100644
View file @
d8c18c66
package
com
.
ejweb
.
modules
.
report
.
web
;
import
com.ejweb.core.base.BaseController
;
import
com.ejweb.core.utils.StringUtils
;
import
com.ejweb.modules.report.entity.ReportEntity
;
import
com.ejweb.modules.report.service.ReportService
;
import
com.itextpdf.text.*
;
import
com.itextpdf.text.pdf.BaseFont
;
import
com.itextpdf.text.pdf.PdfPCell
;
import
com.itextpdf.text.pdf.PdfPTable
;
import
com.itextpdf.text.pdf.PdfWriter
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.stereotype.Controller
;
import
org.springframework.web.bind.annotation.ModelAttribute
;
import
org.springframework.web.bind.annotation.RequestMapping
;
import
org.springframework.web.bind.annotation.RequestParam
;
import
org.springframework.web.servlet.mvc.support.RedirectAttributes
;
import
javax.servlet.http.HttpServletRequest
;
import
javax.servlet.http.HttpServletResponse
;
import
java.io.FileOutputStream
;
import
java.io.IOException
;
import
java.io.PrintWriter
;
/**
* 举报转为文档Controller
* @author lixy
* @version 2017-09-21
*/
@Controller
@RequestMapping
(
value
=
"${adminPath}/report"
)
public
class
ReportToPdfController
extends
BaseController
{
@Autowired
private
ReportService
reportService
;
@ModelAttribute
public
ReportEntity
get
(
@RequestParam
(
required
=
false
)
String
id
)
{
if
(
StringUtils
.
isNotBlank
(
id
))
{
return
reportService
.
get
(
id
);
}
else
{
return
new
ReportEntity
();
}
}
@RequestMapping
(
value
=
"document"
)
public
void
document
(
ReportEntity
reportEntity
,
String
flag
,
HttpServletRequest
request
,
HttpServletResponse
response
,
RedirectAttributes
redirectAttributes
)
throws
IOException
,
DocumentException
{
Document
document
=
new
Document
(
PageSize
.
A4
,
30
,
30
,
30
,
30
);
BaseFont
bfChinese
=
BaseFont
.
createFont
(
"STSongStd-Light"
,
"UniGB-UCS2-H"
,
BaseFont
.
NOT_EMBEDDED
);
Font
title
=
new
Font
(
bfChinese
,
16
,
Font
.
BOLD
);
//文字加粗
Font
textfont
=
new
Font
(
bfChinese
,
14
,
Font
.
NORMAL
);
//正常文字
//document是创建的文档,FileOutputStream是向文档中输入
PdfWriter
.
getInstance
(
document
,
new
FileOutputStream
(
"C:/举报详情.pdf"
));
//打开文档
document
.
open
();
Paragraph
pt1
=
new
Paragraph
(
"举报内容"
,
title
);
pt1
.
setAlignment
(
0
);
//设置文字居中 0靠左 1,居中 2,靠右
document
.
add
(
pt1
);
Paragraph
blankRow1
=
new
Paragraph
(
18
f
,
" "
,
textfont
);
document
.
add
(
blankRow1
);
PdfPTable
table1
=
new
PdfPTable
(
2
);
table1
.
setTotalWidth
(
new
float
[]
{
5
,
10
});
//设置表头列宽
PdfPCell
reportProject
=
new
PdfPCell
(
new
Paragraph
(
"被举报项目:"
,
textfont
));
reportProject
.
setBorderWidth
(
0
);
table1
.
addCell
(
reportProject
);
PdfPCell
reportProject1
=
new
PdfPCell
(
new
Paragraph
(
reportEntity
.
getReportProject
()==
null
?
""
:
reportEntity
.
getReportProject
(),
textfont
));
reportProject1
.
setBorderWidth
(
0
);
table1
.
addCell
(
reportProject1
);
PdfPCell
reportCity
=
new
PdfPCell
(
new
Paragraph
(
"所在城市:"
,
textfont
));
reportCity
.
setBorderWidth
(
0
);
table1
.
addCell
(
reportCity
);
PdfPCell
reportCity1
=
new
PdfPCell
(
new
Paragraph
(
reportEntity
.
getReportCity
()==
null
?
""
:
reportEntity
.
getReportCity
(),
textfont
));
reportCity1
.
setBorderWidth
(
0
);
table1
.
addCell
(
reportCity1
);
PdfPCell
reportTime
=
new
PdfPCell
(
new
Paragraph
(
"举报时间:"
,
textfont
));
reportTime
.
setBorderWidth
(
0
);
table1
.
addCell
(
reportTime
);
PdfPCell
reportTime1
=
new
PdfPCell
(
new
Paragraph
(
reportEntity
.
getReportTime
()==
null
?
""
:
reportEntity
.
getReportTime
(),
textfont
));
reportTime1
.
setBorderWidth
(
0
);
table1
.
addCell
(
reportTime1
);
PdfPCell
reportContent
=
new
PdfPCell
(
new
Paragraph
(
"内容:"
,
textfont
));
reportContent
.
setBorderWidth
(
0
);
table1
.
addCell
(
reportContent
);
PdfPCell
reportContent1
=
new
PdfPCell
(
new
Paragraph
(
reportEntity
.
getReportContent
()==
null
?
""
:
reportEntity
.
getReportContent
(),
textfont
));
reportContent1
.
setBorderWidth
(
0
);
table1
.
addCell
(
reportContent1
);
PdfPCell
reportAttachment
=
new
PdfPCell
(
new
Paragraph
(
"附件:"
,
textfont
));
reportAttachment
.
setBorderWidth
(
0
);
table1
.
addCell
(
reportAttachment
);
PdfPCell
reportAttachment1
=
new
PdfPCell
(
new
Paragraph
(
reportEntity
.
getReportProject
()==
null
?
""
:
reportEntity
.
getReportProject
(),
textfont
));
reportAttachment1
.
setBorderWidth
(
0
);
table1
.
addCell
(
reportAttachment1
);
document
.
add
(
table1
);
Paragraph
pt2
=
new
Paragraph
(
"举报人信息"
,
title
);
pt2
.
setAlignment
(
0
);
//设置文字居中 0靠左 1,居中 2,靠右
document
.
add
(
pt2
);
Paragraph
blankRow2
=
new
Paragraph
(
18
f
,
" "
,
textfont
);
document
.
add
(
blankRow2
);
PdfPTable
table2
=
new
PdfPTable
(
2
);
table2
.
setTotalWidth
(
new
float
[]
{
5
,
10
});
//设置表头列宽
PdfPCell
reportPersonName
=
new
PdfPCell
(
new
Paragraph
(
"姓名:"
,
textfont
));
reportPersonName
.
setBorderWidth
(
0
);
table2
.
addCell
(
reportPersonName
);
PdfPCell
reportPersonName1
=
new
PdfPCell
(
new
Paragraph
(
reportEntity
.
getReportPersonName
()==
null
?
""
:
reportEntity
.
getReportPersonName
(),
textfont
));
reportPersonName1
.
setBorderWidth
(
0
);
table2
.
addCell
(
reportPersonName1
);
PdfPCell
reportPersonTel
=
new
PdfPCell
(
new
Paragraph
(
"手机号:"
,
textfont
));
reportPersonTel
.
setBorderWidth
(
0
);
table2
.
addCell
(
reportPersonTel
);
PdfPCell
reportPersonTel1
=
new
PdfPCell
(
new
Paragraph
(
reportEntity
.
getReportPersonTel
()==
null
?
""
:
reportEntity
.
getReportPersonTel
(),
textfont
));
reportPersonTel1
.
setBorderWidth
(
0
);
table2
.
addCell
(
reportPersonTel1
);
PdfPCell
reportPersonEmail
=
new
PdfPCell
(
new
Paragraph
(
"Email:"
,
textfont
));
reportPersonEmail
.
setBorderWidth
(
0
);
table2
.
addCell
(
reportPersonEmail
);
PdfPCell
reportPersonEmail1
=
new
PdfPCell
(
new
Paragraph
(
reportEntity
.
getReportPersonEmail
()==
null
?
""
:
reportEntity
.
getReportPersonEmail
(),
textfont
));
reportPersonEmail1
.
setBorderWidth
(
0
);
table2
.
addCell
(
reportPersonEmail1
);
PdfPCell
reportSource
=
new
PdfPCell
(
new
Paragraph
(
"举报途径:"
,
textfont
));
reportSource
.
setBorderWidth
(
0
);
table1
.
addCell
(
reportSource
);
String
report_source
=
reportEntity
.
getReportSource
();
if
(
StringUtils
.
isNotBlank
(
report_source
)){
if
(
report_source
.
equals
(
"web"
)){
report_source
=
"官网"
;
}
else
if
(
report_source
.
equals
(
"oa"
)){
report_source
=
"融创OA系统"
;
}
else
if
(
report_source
.
equals
(
"supplier"
)){
report_source
=
"供应商系统"
;
}
else
if
(
report_source
.
equals
(
"wechat"
)){
report_source
=
"微信公众号"
;
}
else
if
(
report_source
.
equals
(
"sunacE"
)){
report_source
=
"融E"
;
}
else
if
(
report_source
.
equals
(
"offline"
)){
report_source
=
"线下扫码"
;
}
else
if
(
report_source
.
equals
(
"tel"
)){
report_source
=
"电话"
;
}
else
if
(
report_source
.
equals
(
"email"
)){
report_source
=
"邮件"
;
}
else
if
(
report_source
.
equals
(
"visit"
)){
report_source
=
"来访"
;
}
}
else
{
report_source
=
""
;
}
PdfPCell
reportSource1
=
new
PdfPCell
(
new
Paragraph
(
report_source
,
textfont
));
reportSource1
.
setBorderWidth
(
0
);
table1
.
addCell
(
reportSource1
);
document
.
add
(
table2
);
Paragraph
pt3
=
new
Paragraph
(
"举报信息补充"
,
title
);
pt3
.
setAlignment
(
0
);
//设置文字居中 0靠左 1,居中 2,靠右
document
.
add
(
pt3
);
Paragraph
blankRow3
=
new
Paragraph
(
18
f
,
" "
,
textfont
);
document
.
add
(
blankRow3
);
PdfPTable
table3
=
new
PdfPTable
(
2
);
table3
.
setTotalWidth
(
new
float
[]
{
5
,
10
});
//设置表头列宽
PdfPCell
supplementTitle
=
new
PdfPCell
(
new
Paragraph
(
"标题:"
,
textfont
));
supplementTitle
.
setBorderWidth
(
0
);
table3
.
addCell
(
supplementTitle
);
PdfPCell
supplementTitle1
=
new
PdfPCell
(
new
Paragraph
(
reportEntity
.
getSupplementTitle
()==
null
?
""
:
reportEntity
.
getSupplementTitle
(),
textfont
));
supplementTitle1
.
setBorderWidth
(
0
);
table3
.
addCell
(
supplementTitle1
);
PdfPCell
supplementCompany
=
new
PdfPCell
(
new
Paragraph
(
"被举报公司:"
,
textfont
));
supplementCompany
.
setBorderWidth
(
0
);
table3
.
addCell
(
supplementCompany
);
PdfPCell
supplementCompany1
=
new
PdfPCell
(
new
Paragraph
(
reportEntity
.
getSupplementCompany
()==
null
?
""
:
reportEntity
.
getSupplementCompany
(),
textfont
));
supplementCompany1
.
setBorderWidth
(
0
);
table3
.
addCell
(
supplementCompany1
);
PdfPCell
supplementDepartment
=
new
PdfPCell
(
new
Paragraph
(
"被举报部门:"
,
textfont
));
supplementDepartment
.
setBorderWidth
(
0
);
table3
.
addCell
(
supplementDepartment
);
PdfPCell
supplementDepartment1
=
new
PdfPCell
(
new
Paragraph
(
reportEntity
.
getSupplementDepartment
()==
null
?
""
:
reportEntity
.
getSupplementDepartment
(),
textfont
));
supplementDepartment1
.
setBorderWidth
(
0
);
table3
.
addCell
(
supplementDepartment1
);
PdfPCell
supplementInformant
=
new
PdfPCell
(
new
Paragraph
(
"被举报人:"
,
textfont
));
supplementInformant
.
setBorderWidth
(
0
);
table3
.
addCell
(
supplementInformant
);
PdfPCell
supplementInformant1
=
new
PdfPCell
(
new
Paragraph
(
reportEntity
.
getSupplementInformant
()==
null
?
""
:
reportEntity
.
getSupplementInformant
(),
textfont
));
supplementInformant1
.
setBorderWidth
(
0
);
table3
.
addCell
(
supplementInformant1
);
PdfPCell
supplementType
=
new
PdfPCell
(
new
Paragraph
(
"业务类型:"
,
textfont
));
supplementType
.
setBorderWidth
(
0
);
table3
.
addCell
(
supplementType
);
String
supplement_type
=
reportEntity
.
getSupplementType
();
if
(
StringUtils
.
isNotBlank
(
supplement_type
)){
if
(
supplement_type
.
equals
(
"1"
)){
supplement_type
=
"营销"
;
}
else
if
(
supplement_type
.
equals
(
"2"
)){
supplement_type
=
"工程"
;
}
else
if
(
supplement_type
.
equals
(
"3"
)){
supplement_type
=
"成本"
;
}
else
if
(
supplement_type
.
equals
(
"4"
)){
supplement_type
=
"招采"
;
}
else
if
(
supplement_type
.
equals
(
"5"
)){
supplement_type
=
"人力"
;
}
else
if
(
supplement_type
.
equals
(
"6"
)){
supplement_type
=
"物业"
;
}
else
if
(
supplement_type
.
equals
(
"7"
)){
supplement_type
=
"投诉"
;
}
}
else
{
supplement_type
=
""
;
}
PdfPCell
supplementType1
=
new
PdfPCell
(
new
Paragraph
(
supplement_type
,
textfont
));
supplementType1
.
setBorderWidth
(
0
);
table3
.
addCell
(
supplementType1
);
PdfPCell
supplementArea
=
new
PdfPCell
(
new
Paragraph
(
"被举报区域:"
,
textfont
));
supplementArea
.
setBorderWidth
(
0
);
table3
.
addCell
(
supplementArea
);
PdfPCell
supplementArea1
=
new
PdfPCell
(
new
Paragraph
(
reportEntity
.
getSupplementArea
()==
null
?
""
:
reportEntity
.
getSupplementArea
(),
textfont
));
supplementArea1
.
setBorderWidth
(
0
);
table3
.
addCell
(
supplementArea1
);
PdfPCell
supplementProject
=
new
PdfPCell
(
new
Paragraph
(
"被举报项目:"
,
textfont
));
supplementProject
.
setBorderWidth
(
0
);
table3
.
addCell
(
supplementProject
);
PdfPCell
supplementProject1
=
new
PdfPCell
(
new
Paragraph
(
reportEntity
.
getSupplementProject
()==
null
?
""
:
reportEntity
.
getSupplementProject
(),
textfont
));
supplementProject1
.
setBorderWidth
(
0
);
table3
.
addCell
(
supplementProject1
);
PdfPCell
supplementContent
=
new
PdfPCell
(
new
Paragraph
(
"内容:"
,
textfont
));
supplementContent
.
setBorderWidth
(
0
);
table3
.
addCell
(
supplementContent
);
PdfPCell
supplementContent1
=
new
PdfPCell
(
new
Paragraph
(
reportEntity
.
getSupplementContent
()==
null
?
""
:
reportEntity
.
getSupplementContent
(),
textfont
));
supplementContent1
.
setBorderWidth
(
0
);
table3
.
addCell
(
supplementContent1
);
PdfPCell
supplementAttachment
=
new
PdfPCell
(
new
Paragraph
(
"附件:"
,
textfont
));
supplementAttachment
.
setBorderWidth
(
0
);
table3
.
addCell
(
supplementAttachment
);
PdfPCell
supplementAttachment1
=
new
PdfPCell
(
new
Paragraph
(
reportEntity
.
getSupplementAttachment
()==
null
?
""
:
reportEntity
.
getSupplementAttachment
(),
textfont
));
supplementAttachment1
.
setBorderWidth
(
0
);
table3
.
addCell
(
supplementAttachment1
);
document
.
add
(
table3
);
document
.
close
();
PrintWriter
out
=
response
.
getWriter
();
response
.
setContentType
(
"application/json;charset=utf-8"
);
out
.
write
(
"C:/举报详情.pdf"
);
out
.
close
();
// return "redirect:" + adminPath + "/report/list/?repage&flag="+flag;
}
}
src/main/java/com/ejweb/modules/sys/entity/Position.java
0 → 100644
View file @
d8c18c66
package
com
.
ejweb
.
modules
.
sys
.
entity
;
import
com.ejweb.core.persistence.DataEntity
;
public
class
Position
extends
DataEntity
<
Position
>
{
private
static
final
long
serialVersionUID
=
1L
;
private
String
name
;
private
String
code
;
public
String
getName
()
{
return
name
;
}
public
void
setName
(
String
name
)
{
this
.
name
=
name
;
}
public
String
getCode
()
{
return
code
;
}
public
void
setCode
(
String
code
)
{
this
.
code
=
code
;
}
}
src/main/java/com/ejweb/modules/sys/entity/User.java
View file @
d8c18c66
...
...
@@ -53,7 +53,7 @@ public class User extends DataEntity<User> {
private
List
<
Role
>
roleList
=
Lists
.
newArrayList
();
// 拥有角色列表
private
String
positionName
;
//职位
private
Position
position
;
//职位
public
User
()
{
super
();
...
...
@@ -311,12 +311,12 @@ public class User extends DataEntity<User> {
}
}
public
String
getPositionName
()
{
return
position
Name
;
public
Position
getPosition
()
{
return
position
;
}
public
void
setPosition
Name
(
String
positionName
)
{
this
.
position
Name
=
positionName
;
public
void
setPosition
(
Position
position
)
{
this
.
position
=
position
;
}
/**
...
...
src/main/resources/mappings/modules/report/ReportDao.xml
View file @
d8c18c66
...
...
@@ -221,7 +221,7 @@
su.mobile AS "mobile",
so1.`name` AS "company.name",
so2.`name` AS "office.name",
sp.position_name AS "position
N
ame",
sp.position_name AS "position
.n
ame",
sr.`name` AS "role.name"
FROM
sys_user su
...
...
@@ -257,8 +257,8 @@
<if
test=
"office != null and office.id != null and office.id != ''"
>
AND so2.id = #{office.id}
</if>
<if
test=
"position
Name != null and positionN
ame != ''"
>
AND sp.position_name = #{position
N
ame}
<if
test=
"position
!= null and position.name != null and position.n
ame != ''"
>
AND sp.position_name = #{position
.n
ame}
</if>
<if
test=
"loginName != null and loginName != ''"
>
AND su.login_name LIKE
...
...
@@ -286,8 +286,9 @@
WHERE so.type = '1'
</select>
<select
id=
"getPositionList"
resultType=
"
User
"
>
<select
id=
"getPositionList"
resultType=
"
Position
"
>
SELECT
position_code AS "id",
position_name AS "positionName"
FROM sys_position
</select>
...
...
src/main/webapp/WEB-INF/views/modules/report/reportDeliver.jsp
0 → 100644
View file @
d8c18c66
<
%@
page
contentType=
"text/html;charset=UTF-8"
%
>
<
%@
include
file=
"/WEB-INF/views/include/taglib.jsp"
%
>
<html>
<head>
<title>
举报管理
</title>
<meta
name=
"decorator"
content=
"default"
/>
<script
type=
"text/javascript"
>
$
(
document
).
ready
(
function
()
{
//弹出隐藏层
$
(
"#btnDistribute"
).
click
(
function
()
{
$
(
"#chooseDiv"
).
show
();
$
(
"#fade"
).
show
();
$
(
"#fade"
).
style
.
width
=
document
.
body
.
scrollWidth
;
$
(
"#fade"
).
height
(
$
(
document
).
height
());
});
//关闭隐藏层
$
(
"#btnClose"
).
click
(
function
()
{
$
(
"#chooseDiv"
).
hide
();
$
(
"#fade"
).
hide
();
});
//选中用户并关闭
$
(
"#btnConfirm"
).
click
(
function
()
{
var
reportIds
=
new
Array
();
$
(
"input:checkbox:checked"
).
each
(
function
(){
reportIds
.
push
(
$
(
this
).
val
());
});
var
userId
=
$
(
"input:radio:checked"
).
val
();
$
.
ajax
({
url
:
"${ctx}/report/deliver"
,
dataType
:
"json"
,
data
:
{
"reportIds"
:
reportIds
,
"userId"
:
userId
},
traditional
:
true
,
//这里设置为true
cache
:
false
,
success
:
function
(
result
)
{
//登录成功后返回的数据
if
(
result
==
"1"
){
$
(
"#searchForm"
).
submit
();
}
},
error
:
function
(){
alert
(
"数据错误!"
);
}
});
$
(
"#chooseDiv"
).
hide
();
$
(
"#fade"
).
hide
();
});
});
function
page
(
n
,
s
){
$
(
"#pageNo"
).
val
(
n
);
$
(
"#pageSize"
).
val
(
s
);
$
(
"#searchForm"
).
attr
(
"action"
,
"${ctx}/report/deliverList"
);
$
(
"#searchForm"
).
submit
();
return
false
;
}
function
resetPageNo
()
{
$
(
"#pageNo"
).
val
(
0
);
}
</script>
<style
type=
"text/css"
>
.black_overlay
{
display
:
none
;
position
:
absolute
;
top
:
0%
;
left
:
0%
;
width
:
100%
;
height
:
100%
;
z-index
:
1001
;
-moz-opacity
:
0.8
;
opacity
:
.80
;
filter
:
alpha
(
opacity
=
80
);
}
.white_content
{
display
:
none
;
position
:
absolute
;
top
:
10%
;
left
:
10%
;
width
:
80%
;
height
:
80%
;
border
:
1px
solid
;
background-color
:
white
;
z-index
:
1002
;
overflow
:
auto
;
}
#chooseContent
{
margin
:
20px
20px
20px
20px
;
}
</style>
</head>
<body>
<ul
class=
"nav nav-tabs"
>
<li
class=
"active"
><a
href=
"${ctx}/report/deliverList"
>
工作转交
</a></li>
</ul>
<form:form
id=
"searchForm"
modelAttribute=
"report"
action=
"${ctx}/report/deliverList"
method=
"post"
class=
"breadcrumb form-search"
>
<input
id=
"pageNo"
name=
"pageNo"
type=
"hidden"
value=
"${page.pageNo}"
/>
<input
id=
"pageSize"
name=
"pageSize"
type=
"hidden"
value=
"${page.pageSize}"
/>
<ul
class=
"ul-form"
>
<li><label>
处理人:
</label><form:input
onchange=
"resetPageNo();"
path=
"dealPersonName"
htmlEscape=
"false"
maxlength=
"50"
class=
"input-small"
/></li>
<li
class=
"btns"
>
<label
style=
"width:auto;"
><input
id=
"btnSubmit"
class=
"btn btn-primary"
type=
"submit"
value=
"筛选"
/>
</label>
</li>
<li
class=
"clearfix"
></li>
</ul>
</form:form>
<li
class=
"btns"
>
<label
style=
"width:auto;"
><input
id=
"btnDistribute"
class=
"btn btn-primary"
type=
"button"
value=
"分配"
/>
</label>
</li>
<sys:message
content=
"${message}"
/>
<table
id=
"contentTable"
class=
"table table-striped table-bordered table-condensed"
>
<thead>
<tr>
<th>
选择
</th>
<th>
ID
</th>
<th>
标题
</th>
<th>
业务类型
</th>
<th>
被举报项目
</th>
<th>
举报人
</th>
<th>
举报人电话
</th>
<th>
举报时间
</th>
<th>
状态
</th>
<th>
处理结论
</th>
<th>
处理人
</th>
<th>
转交给
</th>
<th>
操作
</th>
</tr>
</thead>
<tbody>
<c:if
test=
"${page.list.size()>0}"
>
<c:forEach
items=
"${page.list}"
var=
"report"
varStatus=
"vs"
>
<tr>
<td><input
type=
"checkbox"
value=
"${report.id}"
></td>
<td>
${vs.count}
</td>
<td>
${report.supplementTitle}
</td>
<td>
<c:if
test=
"${report.supplementType eq '1'}"
>
营销
</c:if>
<c:if
test=
"${report.supplementType eq '2'}"
>
工程
</c:if>
<c:if
test=
"${report.supplementType eq '3'}"
>
成本
</c:if>
<c:if
test=
"${report.supplementType eq '4'}"
>
招采
</c:if>
<c:if
test=
"${report.supplementType eq '5'}"
>
人力
</c:if>
<c:if
test=
"${report.supplementType eq '6'}"
>
物业
</c:if>
<c:if
test=
"${report.supplementType eq '7'}"
>
投诉
</c:if>
</td>
<td>
${report.reportProject}
</td>
<td>
${report.reportPersonName}
</td>
<td>
${report.reportPersonTel}
</td>
<td>
${report.reportTime}
</td>
<td>
<c:if
test=
"${report.reportStatus eq '0'}"
>
未处理
</c:if>
<c:if
test=
"${report.reportStatus eq '1'}"
>
核查中
</c:if>
<c:if
test=
"${report.reportStatus eq '2'}"
>
已处理
</c:if>
</td>
<td>
<c:if
test=
"${report.dealResult eq null}"
>
--
</c:if>
<c:if
test=
"${report.dealResult eq '1'}"
>
投诉
</c:if>
<c:if
test=
"${report.dealResult eq '2'}"
>
举报无效
</c:if>
<c:if
test=
"${report.dealResult eq '3'}"
>
举报属实
</c:if>
</td>
<td><c:if
test=
"${report.dealResult eq null}"
>
--
</c:if>
<c:if
test=
"${report.dealResult ne null}"
>
${report.dealPersonName}
</c:if>
</td>
<td>
${report.exchangeAfterUser}
</td>
<td>
<a
href=
"${ctx}/report/view?id=${report.id}"
>
查看
</a>
</td>
</tr>
</c:forEach>
</c:if>
</tbody>
</table>
<c:if
test=
"${page.list.size()=='0'}"
>
<span
style=
"color: #999999;margin: 20px 0 70px 20px;display: block;"
>
未查询到相关内容
</span>
</c:if>
<c:if
test=
"${page.list.size()>0}"
>
<div
class=
"pagination"
>
${page}
</div>
</c:if>
<div
id=
"fade"
class=
"black_overlay"
></div>
<div
id=
"chooseDiv"
class=
"white_content"
>
<div
id=
"chooseContent"
>
<script
type=
"text/javascript"
>
$
(
document
).
ready
(
function
()
{
$
(
"#btnSearch"
).
click
(
function
()
{
$
.
ajax
({
url
:
"${ctx}/report/viewTransfer?flag=2"
,
dataType
:
"html"
,
data
:
$
(
'#searchForm1'
).
serialize
(),
cache
:
false
,
beforeSend
:
function
()
{
// 禁用按钮防止重复提交
$
(
"#btnSearch"
).
attr
({
disabled
:
"disabled"
});
},
success
:
function
(
data
)
{
//登录成功后返回的数据
$
(
"#userList"
).
empty
();
$
(
"#userList"
).
html
(
$
(
data
));
},
error
:
function
(){
alert
(
"数据错误!"
);
},
complete
:
function
()
{
$
(
"#btnSearch"
).
removeAttr
(
"disabled"
);
}
});
});
$
(
"input:radio"
).
click
(
function
()
{
$
(
"input:radio"
).
attr
(
"checked"
,
false
);
$
(
"#chooseItem"
).
empty
();
$
(
this
).
attr
(
"checked"
,
true
);
$
(
"#chooseItem"
).
html
(
"已选择 "
+
$
(
"input:radio:checked"
).
parent
().
next
().
next
().
next
().
html
()
+
"<span onclick='remove();'><font size='5'> ×</font></span>"
);
});
});
function
chooseRen
(
obj
)
{
$
(
"input:radio"
).
attr
(
"checked"
,
false
);
$
(
"#chooseItem"
).
empty
();
obj
.
checked
=
true
;
$
(
"#chooseItem"
).
html
(
"已选择 "
+
$
(
"input:radio:checked"
).
parent
().
next
().
next
().
next
().
html
()
+
"<span onclick='remove();'><font size='5'> ×</font></span>"
);
}
function
remove
(){
$
(
"input:radio"
).
attr
(
"checked"
,
false
);
$
(
"#chooseItem"
).
empty
();
}
function
page
(
n
,
s
,
l
){
$
(
"#userPageNo"
).
val
(
n
);
$
(
"#userPageSize"
).
val
(
s
);
$
.
ajax
({
url
:
"${ctx}/report/viewTransfer?flag=2"
,
dataType
:
"html"
,
data
:
$
(
'#searchForm1'
).
serialize
(),
cache
:
false
,
success
:
function
(
data
)
{
//登录成功后返回的数据
$
(
"#userList"
).
empty
();
$
(
"#userList"
).
html
(
$
(
data
));
},
error
:
function
(){
alert
(
"数据错误!"
);
}
});
return
false
;
}
function
resetUserPageNo
()
{
$
(
"#pageNo"
).
val
(
0
);
}
</script>
<span
class=
"title"
>
选择移交人员
</span>
<form:form
id=
"searchForm1"
modelAttribute=
"user"
action=
"#"
method=
"post"
class=
"breadcrumb form-search"
>
<input
id=
"userPageNo"
name=
"pageNo"
type=
"hidden"
value=
"${userPage.pageNo}"
/>
<input
id=
"userPageSize"
name=
"pageSize"
type=
"hidden"
value=
"${userPage.pageSize}"
/>
<ul
class=
"ul-form"
>
<li><label>
用户名:
</label><form:input
onchange=
"resetUserPageNo();"
path=
"loginName"
htmlEscape=
"false"
maxlength=
"50"
class=
"input-small"
/></li>
<li><label>
姓名:
</label><form:input
onchange=
"resetUserPageNo();"
path=
"name"
htmlEscape=
"false"
maxlength=
"50"
class=
"input-small"
/></li>
<li><label>
手机号码:
</label><form:input
onchange=
"resetUserPageNo();"
path=
"mobile"
htmlEscape=
"false"
maxlength=
"50"
class=
"input-small"
/></li>
<li
class=
"btns"
>
<label
style=
"width:auto;"
><input
id=
"btnSearch"
class=
"btn btn-primary"
type=
"button"
value=
"筛选"
/>
</label>
</li>
<li
class=
"clearfix"
></li>
</ul>
</form:form>
<div
id=
"userList"
>
<table
id=
"contentTable"
class=
"table table-striped table-bordered table-condensed"
>
<thead>
<tr>
<th>
选择
</th>
<th>
ID
</th>
<th>
用户名
</th>
<th>
姓名
</th>
<th>
组织
</th>
<th>
手机号码
</th>
<th>
角色
</th>
</tr>
</thead>
<tbody>
<c:if
test=
"${userPage.list.size()>0}"
>
<c:forEach
items=
"${userPage.list}"
var=
"user"
varStatus=
"vs"
>
<tr>
<td
id=
"radioBtn"
><input
type=
"radio"
value=
"${user.id}"
></td>
<td>
${vs.count}
</td>
<td>
${user.loginName}
</td>
<td>
${user.name}
</td>
<td></td>
<td>
${user.mobile}
</td>
<td>
${user.role.name}
</td>
</tr>
</c:forEach>
</c:if>
</tbody>
</table>
<span
id=
"chooseItem"
></span>
<c:if
test=
"${userPage.list.size()=='0'}"
>
<span
style=
"color: #999999;margin: 20px 0 70px 20px;display: block;"
>
未查询到相关内容
</span>
</c:if>
<c:if
test=
"${userPage.list.size()>0}"
>
<div
class=
"pagination"
>
${userPage}
</div>
</c:if>
</div>
<li
class=
"btns"
>
<label
style=
"width:auto;"
><input
id=
"btnConfirm"
class=
"btn btn-primary"
type=
"button"
value=
"确定"
/>
<input
id=
"btnClose"
class=
"btn btn-primary"
type=
"button"
value=
"关闭"
/></label>
</li>
</div>
</div>
</body>
</html>
\ No newline at end of file
src/main/webapp/WEB-INF/views/modules/report/reportDetail.jsp
View file @
d8c18c66
...
...
@@ -12,7 +12,7 @@
window
.
location
.
href
=
"${ctx}/report/track?id=${report.id}"
;
});
$
(
"#btnDocument"
).
click
(
function
()
{
$
(
"#inputForm"
).
attr
(
"action"
,
"${ctx}/report/document"
);
$
(
"#inputForm"
).
attr
(
"action"
,
"${ctx}/report/document
?id=${report.id}
"
);
$
(
"#inputForm"
).
submit
();
});
});
...
...
src/main/webapp/WEB-INF/views/modules/report/reportForm.jsp
View file @
d8c18c66
...
...
@@ -9,20 +9,13 @@
$
(
document
).
ready
(
function
()
{
$
(
"#inputForm"
).
validate
({
submitHandler
:
function
(
form
)
{
if
(
$
(
"#nameFile"
).
val
().
length
==
0
)
{
$
(
"#checkFile"
).
show
();
}
else
if
(
$
(
"#reportContent"
).
val
()
==
""
){
top
.
$
.
jBox
.
tip
(
'请填写内容'
,
'warning'
);
}
else
{
submitCount
+=
1
;
if
(
submitCount
==
1
){
$
(
"#checkFile"
).
hide
();
loading
(
'正在提交,请稍等...'
);
form
.
submit
();
}
else
{
return
false
;
}
}
},
errorContainer
:
"#messageBox"
,
errorPlacement
:
function
(
error
,
element
)
{
...
...
@@ -69,7 +62,6 @@
<label
class=
"control-label"
>
内容:
</label>
<div
class=
"controls"
>
<form:textarea
id=
"reportContent"
htmlEscape=
"true"
path=
"reportContent"
rows=
"4"
maxlength=
"500"
class=
"input-xxlarge"
/>
<span
class=
"help-inline"
><font
color=
"red"
>
*
</font>
</span>
</div>
</div>
</div>
...
...
@@ -80,7 +72,6 @@
maxlength=
"255"
class=
"input-xlarge"
/>
<sys:ckfinder
input=
"nameFile"
type=
"files"
uploadPath=
"/file"
selectMultiple=
"true"
maxWidth=
"100"
maxHeight=
"100"
/>
<label
id=
"checkFile"
class=
"error"
style=
"display: none;"
>
必填信息
</label>
</div>
</div>
<span
class=
"title"
>
举报人信息
</span>
...
...
src/main/webapp/WEB-INF/views/modules/report/reportList.jsp
View file @
d8c18c66
...
...
@@ -5,11 +5,12 @@
<title>
举报管理
</title>
<meta
name=
"decorator"
content=
"default"
/>
<script
type=
"text/javascript"
>
var
requestFlag
=
true
;
$
(
document
).
ready
(
function
()
{
$
(
"#btnExport"
).
click
(
function
(){
top
.
$
.
jBox
.
confirm
(
"确认要导出数据吗?"
,
"系统提示"
,
function
(
v
,
h
,
f
){
if
(
v
==
"ok"
){
$
(
"#searchForm"
).
attr
(
"action"
,
"${ctx}/report/export
?
"
);
$
(
"#searchForm"
).
attr
(
"action"
,
"${ctx}/report/export"
);
$
(
"#searchForm"
).
submit
();
}
},{
buttonsFocus
:
1
});
...
...
@@ -37,6 +38,30 @@
function
resetPageNo
()
{
$
(
"#pageNo"
).
val
(
0
);
}
function
openDownloadDialog
(){
if
(
requestFlag
==
true
){
$
.
ajax
({
url
:
"${ctx}/report/document?id=${report.id}"
,
dataType
:
"text"
,
traditional
:
true
,
//这里设置为true
cache
:
false
,
beforeSend
:
function
()
{
requestFlag
=
false
;
},
success
:
function
(
url
)
{
//登录成功后返回的数据
window
.
location
.
href
=
url
;
},
error
:
function
(){
alert
(
"数据错误!"
);
},
complete
:
function
()
{
requestFlag
=
true
;
}
});
}
else
{
top
.
$
.
jBox
.
tip
(
'正在加载,请稍等'
,
'warning'
);
}
}
</script>
</head>
<body>
...
...
@@ -136,7 +161,7 @@
<td>
<a
href=
"${ctx}/report/view?id=${report.id}"
>
查看
</a>
<c:if
test=
"${report.reportStatus ne '2'}"
><a
href=
"${ctx}/report/track?id=${report.id}"
>
跟踪
</a></c:if>
<a
href=
"
${ctx}/report/document?id=${report.id}
"
>
转为文档
</a>
<a
href=
"
#"
onclick=
"openDownloadDialog()
"
>
转为文档
</a>
</td>
</tr>
</c:forEach>
...
...
src/main/webapp/WEB-INF/views/modules/report/reportTrack.jsp
View file @
d8c18c66
...
...
@@ -9,18 +9,13 @@
$
(
document
).
ready
(
function
()
{
$
(
"#inputForm"
).
validate
({
submitHandler
:
function
(
form
)
{
if
(
$
(
"#nameFile"
).
val
().
length
==
0
)
{
$
(
"#checkFile"
).
show
();
}
else
{
submitCount
+=
1
;
if
(
submitCount
==
1
){
$
(
"#checkFile"
).
hide
();
loading
(
'正在提交,请稍等...'
);
form
.
submit
();
}
else
{
return
false
;
}
}
},
errorContainer
:
"#messageBox"
,
errorPlacement
:
function
(
error
,
element
)
{
...
...
@@ -51,6 +46,16 @@
$
(
"#chooseDiv"
).
hide
();
$
(
"#fade"
).
hide
();
});
//发邮件
$
(
"#btnMail"
).
click
(
function
()
{
var
supplementType
=
$
(
"#supplementType"
).
find
(
"option:selected"
).
text
();
var
supplementInformant
=
$
(
"#supplementInformant"
).
val
();
var
path
=
"mailto:?subject=举报核查-"
+
supplementType
+
"-"
+
supplementInformant
+
"违规操作"
;
path
+=
"&body=Dear,<br/>附件是举报核查-"
+
supplementType
+
"-"
+
supplementInformant
+
"违规操作,请核实是否属实。<br/>谢谢!"
;
//path += "
<
br
/><
br
/><
br
/>%
0
D
%
0
A$
{
userName
}
";
window.location.href = path;
});
});
</script>
...
...
@@ -115,7 +120,7 @@
<div
class=
"control-group"
>
<label
class=
"control-label"
>
被举报人:
</label>
<div
class=
"controls"
>
<form:input
path=
"supplementInformant"
htmlEscape=
"false"
maxlength=
"200"
class=
"input-xlarge required"
/>
<form:input
id=
"supplementInformant"
path=
"supplementInformant"
htmlEscape=
"false"
maxlength=
"200"
class=
"input-xlarge required"
/>
<span
class=
"help-inline"
><font
color=
"red"
>
*
</font>
</span>
</div>
</div>
...
...
@@ -129,7 +134,7 @@
<div
class=
"control-group"
>
<label
class=
"control-label"
>
业务类型:
</label>
<div
class=
"controls"
>
<form:select
path=
"supplementType"
class=
"input-small required"
>
<form:select
id=
"supplementType"
path=
"supplementType"
class=
"input-small required"
>
<form:option
value=
" "
>
请选择
</form:option>
<form:options
items=
"${fns:getDictList('supplement_type')}"
itemLabel=
"label"
itemValue=
"value"
htmlEscape=
"false"
/></form:select>
...
...
@@ -156,7 +161,6 @@
<label
class=
"control-label"
>
内容:
</label>
<div
class=
"controls"
>
<form:textarea
id=
"supplementContent"
htmlEscape=
"true"
path=
"supplementContent"
rows=
"4"
maxlength=
"500"
class=
"input-xxlarge"
/>
<span
class=
"help-inline"
><font
color=
"red"
>
*
</font>
</span>
</div>
</div>
<div
class=
"control-group"
>
...
...
@@ -166,7 +170,6 @@
maxlength=
"255"
class=
"input-xlarge"
/>
<sys:ckfinder
input=
"nameFile"
type=
"files"
uploadPath=
"/file"
selectMultiple=
"true"
maxWidth=
"100"
maxHeight=
"100"
/>
<label
id=
"checkFile"
class=
"error"
style=
"display: none;"
>
必填信息
</label>
</div>
</div>
<span
class=
"title"
>
处理结果
</span>
...
...
@@ -194,7 +197,6 @@
<form:option
value=
" "
>
请选择
</form:option>
<form:options
items=
"${fns:getDictList('deal_result')}"
itemLabel=
"label"
itemValue=
"value"
htmlEscape=
"false"
/></form:select>
<span
class=
"help-inline"
><font
color=
"red"
>
*
</font>
</span>
</div>
</div>
<span
class=
"title"
>
移交他人处理
</span>
...
...
@@ -202,11 +204,12 @@
<label
class=
"control-label"
>
移交:
</label>
<div
class=
"controls"
>
<form:hidden
id=
"userId"
path=
"exchangeAfterUser"
value=
""
/>
<input
id=
"chooseUser"
type=
"text"
value=
"选择移交人员"
htmlEscape=
"false"
maxlength=
"200"
class=
"input-xlarge"
/>
<input
id=
"chooseUser"
type=
"text"
value=
"选择移交人员"
<
c:if
test=
"${isAdmin eq false}"
>
disabled="true"
</c:if>
htmlEscape="false" maxlength="200" class="input-xlarge"/>
</div>
</div>
<div
class=
"form-actions"
>
<input
id=
"btnSubmit"
class=
"btn btn-primary"
type=
"submit"
value=
"提交"
/>
<input
id=
"btnMail"
class=
"btn btn-primary"
type=
"button"
value=
"发邮件"
/>
</div>
</form:form>
<div
id=
"fade"
class=
"black_overlay"
></div>
...
...
@@ -220,12 +223,19 @@
dataType
:
"html"
,
data
:
$
(
'#searchForm'
).
serialize
(),
cache
:
false
,
beforeSend
:
function
()
{
// 禁用按钮防止重复提交
$
(
"#btnSearch"
).
attr
({
disabled
:
"disabled"
});
},
success
:
function
(
data
)
{
//登录成功后返回的数据
$
(
"#userList"
).
empty
();
$
(
"#userList"
).
html
(
$
(
data
));
},
error
:
function
(){
alert
(
"数据错误!"
);
},
complete
:
function
()
{
$
(
"#btnSearch"
).
removeAttr
(
"disabled"
);
}
});
});
...
...
@@ -251,8 +261,19 @@
function
page
(
n
,
s
){
$
(
"#pageNo"
).
val
(
n
);
$
(
"#pageSize"
).
val
(
s
);
$
(
"#searchForm"
).
attr
(
"action"
,
"${ctx}/report/viewTransfer?flag=1"
);
$
(
"#searchForm"
).
submit
();
$
.
ajax
({
url
:
"${ctx}/report/viewTransfer?flag=1"
,
dataType
:
"html"
,
data
:
$
(
'#searchForm'
).
serialize
(),
cache
:
false
,
success
:
function
(
data
)
{
//登录成功后返回的数据
$
(
"#userList"
).
empty
();
$
(
"#userList"
).
html
(
$
(
data
));
},
error
:
function
(){
alert
(
"数据错误!"
);
}
});
return
false
;
}
function
resetPageNo
()
{
...
...
@@ -261,8 +282,8 @@
</script>
<span
class=
"title"
>
选择移交人员
</span>
<form:form
id=
"searchForm"
modelAttribute=
"user"
action=
"#"
method=
"post"
class=
"breadcrumb form-search"
>
<input
id=
"pageNo"
name=
"pageNo"
type=
"hidden"
value=
"${
userP
age.pageNo}"
/>
<input
id=
"pageSize"
name=
"pageSize"
type=
"hidden"
value=
"${
userP
age.pageSize}"
/>
<input
id=
"pageNo"
name=
"pageNo"
type=
"hidden"
value=
"${
p
age.pageNo}"
/>
<input
id=
"pageSize"
name=
"pageSize"
type=
"hidden"
value=
"${
p
age.pageSize}"
/>
<ul
class=
"ul-form"
>
<li><label>
员工号:
</label><form:input
onchange=
"resetPageNo();"
path=
"no"
htmlEscape=
"false"
maxlength=
"50"
class=
"input-small"
/></li>
<li><label>
姓名:
</label><form:input
onchange=
"resetPageNo();"
path=
"name"
htmlEscape=
"false"
maxlength=
"50"
class=
"input-small"
/></li>
...
...
@@ -275,9 +296,9 @@
<li><label>
部门:
</label><form:select
onchange=
"resetPageNo();"
path=
"office.id"
class=
"input-small"
>
<form:option
value=
" "
>
请选择
</form:option>
<form:options
items=
"${officeList}"
itemLabel=
"name"
itemValue=
"id"
htmlEscape=
"false"
/></form:select></li>
<li><label>
职位:
</label><form:select
onchange=
"resetPageNo();"
path=
"position
N
ame"
class=
"input-small"
>
<form:option
value=
" "
>
请选择
</form:option>
<form:options
items=
"${positionList}"
itemLabel=
"
positionName"
itemValue=
"positionName
"
htmlEscape=
"false"
/></form:select></li>
<li><label>
职位:
</label><form:select
onchange=
"resetPageNo();"
path=
"position
.n
ame"
class=
"input-small"
>
<form:option
value=
" "
selected=
"selected"
>
请选择
</form:option>
<form:options
items=
"${positionList}"
itemLabel=
"
name"
itemValue=
"id
"
htmlEscape=
"false"
/></form:select></li>
<li
class=
"btns"
>
<label
style=
"width:auto;"
><input
id=
"btnSearch"
class=
"btn btn-primary"
type=
"button"
value=
"筛选"
/>
</label>
</li>
...
...
@@ -300,8 +321,8 @@
</thead>
<tbody>
<c:if
test=
"${
userP
age.list.size()>0}"
>
<c:forEach
items=
"${
userP
age.list}"
var=
"user"
varStatus=
"vs"
>
<c:if
test=
"${
p
age.list.size()>0}"
>
<c:forEach
items=
"${
p
age.list}"
var=
"user"
varStatus=
"vs"
>
<tr>
<td
id=
"radioBtn"
><input
type=
"radio"
value=
"${user.id}"
></td>
<td>
${vs.count}
</td>
...
...
@@ -310,17 +331,17 @@
<td>
${user.mobile}
</td>
<td>
${user.company.name}
</td>
<td>
${user.office.name}
</td>
<td>
${user.position
N
ame}
</td>
<td>
${user.position
.n
ame}
</td>
</tr>
</c:forEach>
</c:if>
</tbody>
</table>
<span
id=
"chooseItem"
></span>
<c:if
test=
"${
userP
age.list.size()=='0'}"
>
<c:if
test=
"${
p
age.list.size()=='0'}"
>
<span
style=
"color: #999999;margin: 20px 0 70px 20px;display: block;"
>
未查询到相关内容
</span>
</c:if>
<c:if
test=
"${
userP
age.list.size()>0}"
>
<c:if
test=
"${
p
age.list.size()>0}"
>
<div
class=
"pagination"
>
${page}
</div>
</c:if>
</div>
...
...
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