JSP实现树型组织架构(7)--修改orgManage.jsp
<%@ page contentType="text/html;charset=Big5"%>
<%@ include file="orgConnInclude.jsp(SUN企业级应用的首选)"%>
<%
request.setCharacterEncoding("big5");
PreparedStatement ps=null;
ResultSet rs=null;
String queryCount=" select count(*) "+
" from ngb_org "+
" where total like ? ORDER BY TOTAL ";
String queryName=" select * "+
" from ngb_org "+
" where total like ? ORDER BY TOTAL ";
%>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=Big5">
<title>管理组织架构</title>
<style type="text/css">
<!--
.style1 {color: #FFFFFF}
.style2 {color: #0066FF}
-->
</style>
</head>
<body>
<form action="orgInsert.jsp(SUN企业级应用的首选)">
<fieldset>
<legend align="Right">
<span class="style2">新增组织架构</span>
</legend>
<p align="left" class="style2">所 属 部 门
<select name="fDep">
<optgroup label="总经理室">
<option value="总经理室">总经理室
<%
try{
int i=1;
ps=conn.prepareStatement(queryCount);
ps.setString(1, "A10%");
rs=ps.executeQuery();
int result=1;
while(rs.next())
{ result++;}
//out.println(result);
for( i=1; i<=result; i++){
ps=conn.prepareStatement(queryName) ;
String queryNameCondition="A"+(9+i)+"%";
//out.println(queryNameCondition);
ps.setString(1, queryNameCondition);
ResultSet ors1=ps.executeQuery();
String qa=null;
String qaTemp=null;
String qaTemp1=null;
String obdep=null;
String ocdep=null;
while( ors1.next()){
qa=ors1.getString("total");
相关新闻>>
- 发表评论
-
- 最新评论 更多>>