<%@ page contentType="text/html; charset=GBK"%>
<%@ page import="zr.zrpower.entity.sys.SessionUser"%>
<%@ page import="zr.zrpower.ejb.sys.UIService"%>

<%@ page import="zr.zrpower.flowengine.service.FlowConfig"%>
<%@ page import="java.lang.Object"%>
<%@ page import="java.util.*"%>


<%
	SessionUser user = (SessionUser) session.getAttribute("userinfo");
	UIService userUI = new UIService();
	FlowConfig Fconfig = new FlowConfig();
%>
<HTML>
	<HEAD>
		<TITLE></TITLE>
		<META HTTP-EQUIV="Pragma" CONTENT="no-cache">
		<META http-equiv="Content-Type" content="text/html; charset=GBK">
		<link REL="stylesheet" type="text/css"
			href="../../zrsysmanage/css/<%=user.getUserCSS()%>">
	</HEAD>
	<BODY bgcolor="#ffffff">
		<%
			String strFlowID = request.getParameter("FlowID");
			String strPackageID = Fconfig.GetFlowPackage(strFlowID); 
			String strUserID = user.getUserID();
			String strUnitID = user.getUnitID();
			String strID = strPackageID;
			String unitid = user.getUnitID().toString();
			Vector vec = new Vector();
			vec = Fconfig.CopyFlowPackage(strID, unitid, strUserID,strFlowID);
			int iSySize = vec.size(); //剩余记录
			int iDqSize = 0; //当前记录
			int iCs = 0; //循环次数

			if (iSySize - 100 > 0) {
				iDqSize = 100;
				iSySize = iSySize - 100;
			} else {
				iDqSize = iSySize;
				iSySize = 0;
			}
			//调用
			Fconfig.CopyFlowPublic(vec, iCs, iDqSize);
            if(vec.size()>0){
			response.sendRedirect("FlowShowDesign4.jsp?PackageID="
					+ strPackageID);
			}
		%>
	</BODY>
</HTML>
<%
	//清空相关对象
	user = null;
	userUI = null;
	Fconfig = null;
%>
