Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Z
zbgl
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
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
马超
zbgl
Commits
cf3d69c2
Commit
cf3d69c2
authored
Sep 09, 2022
by
马超
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
值班管理
parent
0ec9be32
Changes
8
Hide whitespace changes
Inline
Side-by-side
Showing
8 changed files
with
66 additions
and
152 deletions
+66
-152
web/jsp/zbgl/pbgl/action.jsp
web/jsp/zbgl/pbgl/action.jsp
+3
-3
web/jsp/zbgl/pbgl/list-t.jsp
web/jsp/zbgl/pbgl/list-t.jsp
+1
-1
web/jsp/zbgl/pbgl/selectUser-t.jsp
web/jsp/zbgl/pbgl/selectUser-t.jsp
+49
-67
web/jsp/zbgl/pbgl/viewUser-t.jsp
web/jsp/zbgl/pbgl/viewUser-t.jsp
+2
-2
web/jsp/zbgl/pbmx/action.jsp
web/jsp/zbgl/pbmx/action.jsp
+0
-51
web/jsp/zbgl/pbmx/edit-t.jsp
web/jsp/zbgl/pbmx/edit-t.jsp
+2
-9
web/jsp/zbgl/pbmx/list-t.jsp
web/jsp/zbgl/pbmx/list-t.jsp
+1
-1
web/jsp/zbgl/pbmx/right_list.jsp
web/jsp/zbgl/pbmx/right_list.jsp
+8
-18
No files found.
web/jsp/zbgl/pbgl/action.jsp
View file @
cf3d69c2
...
...
@@ -178,9 +178,9 @@
int
startIndex
=
startIndexBefore
;
StringBuffer
sql1
=
new
StringBuffer
(
"insert into zb_user_gl (year,zb_type,zb_user,order_num,add_user,add_time) values (?,?,?,?,?,?)"
);
Vector
zb_type_list
=
cf
.
doQuery
(
conn
,
"select * from zb_type where mx_id=? order by order_num asc"
,
null
,
new
Object
[]{
mxId
});
for
(
int
a
=
0
;
a
<
selectDay
;
a
++)
{
if
(
zb_type_list
!=
null
&&
zb_type_list
.
size
()
>
0
)
{
for
(
int
i
=
0
;
i
<
zb_type_list
.
size
();
i
++)
{
if
(
zb_type_list
!=
null
&&
zb_type_list
.
size
()
>
0
)
{
for
(
int
i
=
0
;
i
<
zb_type_list
.
size
();
i
++
)
{
for
(
int
a
=
0
;
a
<
selectDay
;
a
++)
{
Hashtable
ht
=
(
Hashtable
)
zb_type_list
.
get
(
i
);
String
ren_num
=
pub
.
trimNull
((
String
)
ht
.
get
(
"ren_num"
));
String
zb_type
=
pub
.
trimNull
((
String
)
ht
.
get
(
"zb_type"
));
...
...
web/jsp/zbgl/pbgl/list-t.jsp
View file @
cf3d69c2
...
...
@@ -103,7 +103,7 @@
}
function
viewUser
(
year
,
month
,
day
)
{
var
url
=
'
./viewUser-t.jsp?year=
'
+
year
+
'
&month=
'
+
month
+
'
&day=
'
+
day
;
viewDeptOrUserInfo
(
year
+
'
年
'
+
month
+
'
月
'
+
day
+
'
日值班表
'
,
url
,
'
1
000
'
,
'
50
0
'
);
viewDeptOrUserInfo
(
year
+
'
年
'
+
month
+
'
月
'
+
day
+
'
日值班表
'
,
url
,
'
1
100
'
,
'
55
0
'
);
}
function
changeZb
()
{
var
url
=
'
./changeZb-t.jsp
'
;
...
...
web/jsp/zbgl/pbgl/selectUser-t.jsp
View file @
cf3d69c2
<%--
Created by IntelliJ IDEA.
User: Administrator
Date: 2020/9/11
Time: 12:54
To change this template use File | Settings | File Templates.
--%>
<%@ page
contentType=
"text/html;charset=UTF-8"
language=
"java"
%>
<%@ page
import=
"java.sql.Connection"
%>
<%@ page
import=
"java.util.*"
%>
...
...
@@ -24,13 +15,9 @@
if
(
""
.
equals
(
login_id
))
{
System
.
out
.
println
(
"当前没有用户信息"
);
}
String
page_number
=
pub
.
trimNull
(
request
.
getParameter
(
"page_number"
));
String
year
=
pub
.
trimNull
(
request
.
getParameter
(
"year"
));
String
zb_type
=
pub
.
trimNull
(
request
.
getParameter
(
"zb_type"
));
String
action
=
pub
.
trimNull
(
request
.
getParameter
(
"action"
));
if
(
""
.
equals
(
page_number
))
page_number
=
"1"
;
String
page_size
=
pub
.
trimNull
(
request
.
getParameter
(
"page_size"
));
if
(
""
.
equals
(
page_size
))
page_size
=
"10"
;
StringBuffer
sql
=
new
StringBuffer
();
List
list
=
new
ArrayList
();
sql
.
append
(
"select * from zb_user order by id asc"
);
...
...
@@ -59,7 +46,7 @@
}
conn
.
commit
();
}
v_list
=
cf
.
do
PageQueryWithCount
(
conn
,
sql
.
toString
(),
page_number
,
page_size
,
null
,
list
.
toArray
());
v_list
=
cf
.
do
Query
(
conn
,
sql
.
toString
(),
null
,
list
.
toArray
());
if
(
v_list
==
null
)
{
out
.
println
(
"查询用户出错"
);
return
;
...
...
@@ -77,60 +64,55 @@
确定
</a>
</div>
<form
action=
"selectUser-t.jsp"
method=
"post"
id=
"groupUser"
name=
"groupUser"
>
<input
type=
"hidden"
name=
"action"
id=
"action"
value=
"update"
>
<input
type=
"hidden"
name=
"year"
id=
"year"
value=
"
<%=
year
%>
"
>
<input
type=
"hidden"
name=
"zb_type"
id=
"zb_type"
value=
"
<%=
zb_type
%>
"
>
<table
class=
"table table-border table-bordered table-hover table-bg table-sort"
>
<thead>
<tr
class=
"text-c"
>
<th
width=
"30"
>
序号
</th>
<th
width=
"30"
>
<input
id=
"checkboxAll"
type=
"checkbox"
onclick=
"checkAll(this);"
></input>
</th>
<th
width=
"100"
>
人员姓名
</th>
<th
width=
"100"
>
联系电话
</th>
<th
width=
"100"
>
工号
</th>
</tr>
</thead>
<tbody
id=
"groupUserInfo"
>
<%
Hashtable
ht_1
=
null
;
if
(
v_list
!=
null
&&
v_list
.
size
()
>
0
)
{
for
(
int
i
=
1
;
i
<
v_list
.
size
();
i
++)
{
Hashtable
ht
=
(
Hashtable
)
v_list
.
get
(
i
);
String
user_name
=
pub
.
trimNull
((
String
)
ht
.
get
(
"user_name"
));
String
tel
=
pub
.
trimNull
((
String
)
ht
.
get
(
"tel"
));
String
gh
=
pub
.
trimNull
((
String
)
ht
.
get
(
"gh"
));
%>
<tr
class=
"text-c"
>
<td><%=
i
%>
</td>
<td
>
<input
type=
"checkbox"
class=
"info"
id=
"userids"
name=
"userids"
value=
"
<%=
user_name
%>
"
<%
if
(
user_names
.
indexOf
(
user_name
)
>
=
0
){
%>
checked=
"checked"
<%
}
%>/>
</td>
<td><%=
user_name
%>
</td>
<td><%=
tel
%>
</td>
<td><%=
gh
%>
</td>
</tr>
<%
<div
style=
"width:100%;height:90%;overflow-y: auto"
>
<form
action=
"selectUser-t.jsp"
method=
"post"
id=
"groupUser"
name=
"groupUser"
>
<input
type=
"hidden"
name=
"action"
id=
"action"
value=
"update"
>
<input
type=
"hidden"
name=
"year"
id=
"year"
value=
"
<%=
year
%>
"
>
<input
type=
"hidden"
name=
"zb_type"
id=
"zb_type"
value=
"
<%=
zb_type
%>
"
>
<table
class=
"table table-border table-bordered table-hover table-bg table-sort"
>
<thead>
<tr
class=
"text-c"
>
<th
width=
"30"
>
序号
</th>
<th
width=
"30"
>
<input
id=
"checkboxAll"
type=
"checkbox"
onclick=
"checkAll(this);"
></input>
</th>
<th
width=
"100"
>
人员姓名
</th>
<th
width=
"100"
>
联系电话
</th>
<th
width=
"100"
>
工号
</th>
</tr>
</thead>
<tbody
id=
"groupUserInfo"
>
<%
Hashtable
ht_1
=
null
;
if
(
v_list
!=
null
&&
v_list
.
size
()
>
0
)
{
for
(
int
i
=
0
;
i
<
v_list
.
size
();
i
++)
{
Hashtable
ht
=
(
Hashtable
)
v_list
.
get
(
i
);
String
user_name
=
pub
.
trimNull
((
String
)
ht
.
get
(
"user_name"
));
String
tel
=
pub
.
trimNull
((
String
)
ht
.
get
(
"tel"
));
String
gh
=
pub
.
trimNull
((
String
)
ht
.
get
(
"gh"
));
%>
<tr
class=
"text-c"
>
<td><%=
i
+
1
%>
</td>
<td
>
<input
type=
"checkbox"
class=
"info"
id=
"userids"
name=
"userids"
value=
"
<%=
user_name
%>
"
<%
if
(
user_names
.
indexOf
(
user_name
)
>
=
0
){
%>
checked=
"checked"
<%
}
%>/>
</td>
<td><%=
user_name
%>
</td>
<td><%=
tel
%>
</td>
<td><%=
gh
%>
</td>
</tr>
<%
}
}
}
%>
</tbody>
</table>
</form>
<link
rel=
"stylesheet"
href=
"
<%=
request
.
getContextPath
()
%>
/css/pagination.css"
>
<script
type=
"text/javascript"
src=
"
<%=
request
.
getContextPath
()
%>
/js/jquery.pagination.js"
></script>
<jsp:include
page=
"/common/page_ajax.jsp"
>
<jsp:param
name=
"page_number"
value=
"<%=page_number%>"
/>
<jsp:param
name=
"rowCnt"
value=
"<%=rowCnt%>"
/>
<jsp:param
name=
"page_size"
value=
"<%=page_size%>"
/>
</jsp:include>
%>
</tbody>
</table>
</form>
</div>
<script
type=
"text/javascript"
>
var
checkAll
=
function
(
checkbox
)
{
$
(
"
.info
"
).
prop
(
"
checked
"
,
checkbox
.
checked
);
...
...
web/jsp/zbgl/pbgl/viewUser-t.jsp
View file @
cf3d69c2
...
...
@@ -80,7 +80,7 @@
<div
class=
""
>
<form
class=
"form form-horizontal"
method=
"post"
id=
"form1"
name=
"form1"
action=
"export_query.jsp"
>
<input
type=
"hidden"
value=
"
<%=
year
+
month
+
day
%>
"
name=
"exportDate"
id=
"exportDate"
>
<div
id=
"content"
class=
"cl pd-5 bk-gray divOverflow"
style=
"overflow:hidden;margin-bottom: 20px;"
>
<div
id=
"content"
class=
"cl pd-5 bk-gray divOverflow"
style=
"overflow:hidden;margin-bottom: 20px;
height: 400px;
"
>
<%
if
(
v_list
.
size
()
>
0
){
for
(
int
i
=
0
;
i
<
v_list
.
size
();
i
++){
...
...
@@ -90,7 +90,7 @@
String
time
=
getZbTyTime
(
cf
,
conn
,
mxId
,
zb_type
);
%>
<div
style=
"width:
9
00px;height:120px;float:left;margin-left: 50px;border:0.5px solid #000;position:relative;"
>
<div
style=
"width:
10
00px;height:120px;float:left;margin-left: 50px;border:0.5px solid #000;position:relative;"
>
<div
style=
"width:140px;height:120px;float:left;border-right:0.5px solid #000;text-align: center;line-height: 80px;"
>
<p
style=
"height:30px;"
>
<%=
zb_type
%></p>
<p
style=
"height:30px;"
>
(
<%=
time
%>
)
</p>
...
...
web/jsp/zbgl/pbmx/action.jsp
View file @
cf3d69c2
...
...
@@ -122,30 +122,9 @@
conn
.
rollback
();
return
;
}
for
(
int
n
=
0
;
n
<
mxDay
;
n
++){
userNames
=
getUserNames
(
cf
,
conn
,
startIndex
,
Integer
.
parseInt
(
ren_num
));
if
(!
""
.
equals
(
userNames
)){
startIndex
=
Integer
.
parseInt
(
userNames
.
substring
(
0
,
userNames
.
indexOf
(
"_"
)));
userNames
=
userNames
.
substring
(
userNames
.
indexOf
(
"_"
)+
1
,
userNames
.
length
()-
1
);
}
is_oper
=
cf
.
executeUpdate
(
conn
,
"insert into zb_mx_day(mx_id,zb_type,user_name,day,add_user,add_time) values (?,?,?,?,?,?)"
,
new
Object
[]{
mx_id
,
zb_type_id
,
userNames
,
n
+
1
,
add_user
,
add_time
});
if
(!
is_oper
)
{
System
.
out
.
println
(
"新增zb_mx_day表出错了"
+
cf
.
getMsg
());
conn
.
rollback
();
return
;
}
}
}
}
else
if
(
"delete"
.
equals
(
action
)){
action_msg
=
"删除"
;
is_oper
=
cf
.
executeUpdate
(
conn
,
"delete from zb_mx_day where mx_id=?"
,
new
Object
[]{
mx_id
});
if
(!
is_oper
)
{
conn
.
rollback
();
System
.
out
.
println
(
"删除zb_mx_day表出错了"
+
cf
.
getMsg
());
return
;
}
is_oper
=
cf
.
executeUpdate
(
conn
,
"delete from zb_type where mx_id=?"
,
new
Object
[]{
mx_id
});
if
(!
is_oper
)
{
conn
.
rollback
();
...
...
@@ -185,21 +164,6 @@
conn
.
rollback
();
return
;
}
for
(
int
n
=
0
;
n
<
mxDay
;
n
++){
userNames
=
getUserNames
(
cf
,
conn
,
startIndex
,
Integer
.
parseInt
(
ren_num
));
if
(!
""
.
equals
(
userNames
)){
startIndex
=
Integer
.
parseInt
(
userNames
.
substring
(
0
,
userNames
.
indexOf
(
"_"
)));
userNames
=
userNames
.
substring
(
userNames
.
indexOf
(
"_"
)+
1
,
userNames
.
length
()-
1
);
}
is_oper
=
cf
.
executeUpdate
(
conn
,
"update zb_mx_day set user_name=?,update_user=?,update_time=? where mx_id=? and zb_type=? and day=?"
,
new
Object
[]{
userNames
,
add_user
,
add_time
,
mx_id
,
zb_type_id
,
n
+
1
});
if
(!
is_oper
)
{
System
.
out
.
println
(
"修改b_mx_day表出错了"
+
cf
.
getMsg
());
conn
.
rollback
();
return
;
}
}
}
else
{
String
new_id
=
UUID
.
randomUUID
().
toString
().
trim
().
replaceAll
(
"-"
,
""
);
is_oper
=
cf
.
executeUpdate
(
conn
,
"insert into zb_type(id,mx_id,zb_type,b_time,e_time,ren_num,add_user,add_time) values (?,?,?,?,?,?,?,?)"
...
...
@@ -209,20 +173,6 @@
conn
.
rollback
();
return
;
}
for
(
int
n
=
0
;
n
<
mxDay
;
n
++){
userNames
=
getUserNames
(
cf
,
conn
,
startIndex
,
Integer
.
parseInt
(
ren_num
));
if
(!
""
.
equals
(
userNames
)){
startIndex
=
Integer
.
parseInt
(
userNames
.
substring
(
0
,
userNames
.
indexOf
(
"_"
)));
userNames
=
userNames
.
substring
(
userNames
.
indexOf
(
"_"
)+
1
,
userNames
.
length
()-
1
);
}
is_oper
=
cf
.
executeUpdate
(
conn
,
"insert into zb_mx_day(mx_id,zb_type,user_name,day,add_user,add_time) values (?,?,?,?,?,?)"
,
new
Object
[]{
mx_id
,
new_id
,
userNames
,
n
+
1
,
add_user
,
add_time
});
if
(!
is_oper
)
{
System
.
out
.
println
(
"新增zb_mx_day表出错了"
+
cf
.
getMsg
());
conn
.
rollback
();
return
;
}
}
}
if
(!
is_oper
)
{
System
.
out
.
println
(
"修改zb_type表出错了"
+
cf
.
getMsg
());
...
...
@@ -255,7 +205,6 @@
return
;
}
}*/
is_oper
=
cf
.
executeUpdate
(
conn
,
"update zb_mx set name=? where id=?"
,
new
Object
[]{
mx_name
,
mx_id
});
if
(!
is_oper
)
{
conn
.
rollback
();
...
...
web/jsp/zbgl/pbmx/edit-t.jsp
View file @
cf3d69c2
...
...
@@ -74,6 +74,7 @@
<input
type=
"hidden"
value=
"
<%=
action
%>
"
name=
"action"
id=
"action"
>
<input
type=
"hidden"
value=
"
<%=
mx_id
%>
"
name=
"mx_id"
id=
"mx_id"
>
<input
type=
"hidden"
id=
"input_count"
name=
"input_count"
value=
"
<%=
listSize
%>
"
/>
<input
type=
"hidden"
name=
"mx_day"
id=
"mx_day"
value=
"30"
>
<div
id=
"content"
class=
"cl pd-5 bk-gray divOverflow"
style=
"overflow:hidden;margin-bottom: 20px;"
>
<div
class=
"row cl"
>
<label
class=
"form-label col-xs-4 col-sm-2"
>
...
...
@@ -83,14 +84,6 @@
<input
type=
"text"
class=
"input-text"
name=
"mx_name"
id=
"mx_name"
value=
"
<%=
pub
.
trimNull
((
String
)
ht
.
get
(
"name"
))
%>
"
>
</div>
</div>
<div
class=
"row cl"
>
<label
class=
"form-label col-xs-4 col-sm-2"
>
<span
class=
"c-red"
>
*
</span>
天数
:
</label>
<div
class=
"formControls col-xs-8 col-sm-10"
>
<input
<%
if
(
"update"
.
equals
(
action
)){
%>
readonly=
"readonly"
<%
}
%>
type=
"text"
class=
"input-text"
name=
"mx_day"
id=
"mx_day"
value=
"
<%=
pub
.
trimNull
((
String
)
ht
.
get
(
"day"
))
%>
"
>
</div>
</div>
<div
class=
"row cl"
id=
"zb_type_div"
>
<label
class=
"form-label col-xs-4 col-sm-2"
>
<span
class=
"c-red"
>
*
</span>
时间段
:
...
...
@@ -231,7 +224,7 @@
layer
.
msg
(
'
操作成功!
'
,
{
icon
:
1
,
time
:
1000
},
function
()
{
//parent.searchModel();
$
(
"
#check_mx_id
"
).
val
(
mx_id
)
;
parent
.
document
.
getElementById
(
"
check_mx_id
"
).
value
=
mx_id
;
var
index
=
parent
.
layer
.
getFrameIndex
(
window
.
name
);
parent
.
layer
.
close
(
index
);
});
...
...
web/jsp/zbgl/pbmx/list-t.jsp
View file @
cf3d69c2
...
...
@@ -119,7 +119,7 @@
maxmin
:
true
,
end
:
function
()
{
searchModel
();
searchModel1
(
$
(
"
#check_mx_id
"
).
val
());
openLi
(
$
(
"
#check_mx_id
"
).
val
(),
$
(
"
#check_mx_day
"
).
val
());
}
});
//layer.full(abc);
...
...
web/jsp/zbgl/pbmx/right_list.jsp
View file @
cf3d69c2
...
...
@@ -24,7 +24,7 @@
}
String
mx_id
=
pub
.
trimNull
(
request
.
getParameter
(
"mx_id"
));
String
Mxday
=
pub
.
trimNull
(
request
.
getParameter
(
"day"
));
int
divCount
=
8
;
int
divCount
=
30
;
if
(!
""
.
equals
(
Mxday
)){
divCount
=
Integer
.
parseInt
(
Mxday
);
}
...
...
@@ -48,7 +48,6 @@
String
zb_type
=
pub
.
trimNull
((
String
)
ht
.
get
(
"zb_type"
));
String
b_time
=
pub
.
trimNull
((
String
)
ht
.
get
(
"b_time"
));
String
e_time
=
pub
.
trimNull
((
String
)
ht
.
get
(
"e_time"
));
v_list_day
=
cf
.
doQuery
(
conn
,
sql_day
.
toString
(),
null
,
new
Object
[]{
mx_id
,
id
});
%>
<%
if
(
i
==
0
){
%>
...
...
@@ -56,16 +55,12 @@
<div
style=
"width:140px;height:40px;float:left;border:0.5px solid #000;"
>
</div>
<%
if
(
v_list_day
!=
null
&&
v_list_day
.
size
()
>
0
){
for
(
int
n
=
0
;
n
<
v_list_day
.
size
();
n
++){
Hashtable
ht1
=
(
Hashtable
)
v_list_day
.
get
(
n
);
String
day
=
pub
.
trimNull
((
String
)
ht1
.
get
(
"day"
));
for
(
int
n
=
0
;
n
<
30
;
n
++){
%>
<div
style=
"width:140px;height:40px;line-height:40px;text-align:center;color:#fff;float:left;border:0.5px solid #000;background-color: #00b7ee"
>
<%=
day
%>
<%=
n
+
1
%>
</div>
<%
}
}
%>
<%
}
%>
</div>
<%
}
%>
...
...
@@ -75,21 +70,16 @@
<p
style=
"height:30px;"
>
(
<%=
b_time
%>
-
<%=
e_time
%>
)
</p>
</div>
<%
if
(
v_list_day
!=
null
&&
v_list_day
.
size
()
>
0
){
for
(
int
n
=
0
;
n
<
v_list_day
.
size
();
n
++){
Hashtable
ht1
=
(
Hashtable
)
v_list_day
.
get
(
n
);
String
day_id
=
pub
.
trimNull
((
String
)
ht1
.
get
(
"id"
));
String
user_name
=
pub
.
trimNull
((
String
)
ht1
.
get
(
"user_name"
));
user_name
=
user_name
.
replace
(
","
,
"
</
br
>"
);
for
(
int
n
=
0
;
n
<
30
;
n
++){
%>
<div
style=
"text-align:center;width:140px;height:160px;float:left;border:0.5px solid #000;position: relative"
>
<p
style=
"height:10px;display:none;"
>
<%=
user_name
%>
</p>
<button
class=
"btn btn-success"
onclick=
"editUser('
<%=
day_id
%>
','
<%=
mx_id
%>
');"
style=
"display:none;text-align:center;position:absolute; right:0; bottom:0;"
>
<button
class=
"btn btn-success"
style=
"display:none;text-align:center;position:absolute; right:0; bottom:0;"
>
修改
</button>
</div>
<%
}
}
%>
<%
}
%>
</div>
<%
}
%>
</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