📄 flow_top1.php
字号:
<?php
include_once( "inc/auth.php" );
include_once( "inc/utility_all.php" );
include_once( "../prcs_role.php" );
echo "\r\n<html>\r\n<head>\r\n<title>常用工作流程</title>\r\n<meta http-equiv=\"Content-Type\" content=\"text/html;charset=gb2312\">\r\n<script>\r\nfunction form_view(RUN_ID,FLOW_ID)\r\n{\r\n myleft=(screen.availWidth-800)/2;\r\n window.open(\"../list/print?RUN_ID=\"+RUN_ID+\"&FLOW_ID=\"+FLOW_ID,\"\",\"status=0,toolbar=no,menubar=no,width=800,height=600,location=no,scrollbars=yes,resizable=yes,left=\"+myleft+\",top=50\");\r\n}\r\n\r\n\r\nfunction flow_view(RUN_ID,FLOW_ID)\r\n{\r\n myleft=(screen.availWidth-600)/2;\r\n window.open(\"../list/flow_view.php?RUN_ID=\"+RUN_ID+\"&FLOW_ID=\"+FLOW_ID,\"flow_view\",\"status=0,toolbar=no,menubar=no,location=no,scrollbars=yes,resizable=yes,width=600,height=400,left=\"+myleft+\",top=100\");\r\n}\r\n\r\nfunction view_graph(FLOW_ID)\r\n{\r\n myleft=(screen.availWidth-800)/2;\r\n window.open(\"../list/view_graph?FLOW_ID=\"+FLOW_ID,\"flow_view\",\"status=0,toolbar=no,menubar=no,location=no,scrollbars=yes,resizable=yes,width=800,height=500,left=\"+myleft+\",top=50\");\r\n}\r\n\r\nfunction setCookie(name,value) {\r\n var today = new Date();\r\n var expires = new Date();\r\n expires.setTime(today.getTime() + 1000*60*60*24*2000);\r\n parent.document.cookie = name + \"=\" + escape(value) + \"; expires=\" + expires.toGMTString();\r\n}\r\nfunction checkNum(str)\r\n{\r\n var re=/\\D/;\r\n return str.match(re);\r\n}\r\n\r\nfunction SetNums()\r\n{\r\n\t\tCookieName=\"";
echo $LOGIN_USER_ID;
echo "_my_flow_top_nums\";\r\n\t\tCookieField=\"MODULE_NUM\";\r\n\t\tinfoArea=\"module_info\";\r\n var CookieValue=document.all(CookieField).value;\r\n if(CookieValue==\"\")\r\n {\r\n alert(\"请输入数值\");\r\n return;\r\n }\r\n if(checkNum(CookieValue))\r\n {\r\n alert(\"显示条数必须是数字\");\r\n return;\r\n }\r\n\r\n if(parseInt(CookieValue)<=0 || parseInt(CookieValue)>=5000)\r\n {\r\n alert(\"显示条数必须在1-5000之间\");\r\n return;\r\n }\r\n setCookie(CookieName, CookieValue);\r\n window.location.reload();\r\n}</script>\r\n</head>\r\n\r\n<body class=\"bodycolor\" topmargin=\"5\">\r\n\r\n<table border=\"0\" width=\"100%\" cellspacing=\"0\" cellpadding=\"3\" class=\"small\">\r\n <tr>\r\n <td class=\"Big\"><img src=\"/images/green_arrow.gif\" align=\"absmiddle\"><span class=\"big3\"> 常用工作流程</span> \r\n \t<span class=\"small1\"> 显示条数:<input type=\"input\" size=\"6\" class=\"SmallInput\" value=\"";
echo $_COOKIE[$LOGIN_USER_ID."_my_flow_top_nums"];
echo "\" name=\"MODULE_NUM\"> \r\n <input type=\"button\" value=\"设置\" class=\"SmallButton\" name=\"set\" title=\"保存设置\" onclick=\"SetNums();\"> </span> <br>\r\n </td>\r\n </tr>\r\n</table>\r\n<br>\r\n\r\n";
$MAX_COUNT = intval( $_COOKIE[$LOGIN_USER_ID."_my_flow_top_nums"] );
if ( $MAX_COUNT <= 0 || 5000 <= $MAX_COUNT )
{
$MAX_COUNT = 10;
}
$query = "SELECT * from FLOW_RUN order by RUN_ID desc";
$cursor = exequery( $connection, $query );
$FLOW_COUNT = 0;
do
{
$RUN_ID = $ROW['RUN_ID'];
$FLOW_ID = $ROW['FLOW_ID'];
$RUN_NAME = $ROW['RUN_NAME'];
if ( $Tmp_0 || find_id( $FLOW_ID_STR, $FLOW_ID ) )
{
continue;
}
$FLOW_ID_STR .= $FLOW_ID.",";
$PRCS_TIME = "";
$query1 = "SELECT PRCS_TIME from FLOW_RUN_PRCS WHERE RUN_ID=".$RUN_ID." AND PRCS_ID=1";
$cursor1 = exequery( $connection, $query1 );
if ( $ROW = mysql_fetch_array( $cursor1 ) )
{
$PRCS_TIME = $ROW['PRCS_TIME'];
}
else
{
$PRCS_TIME = "";
}
if ( !prcs_role( $FLOW_ID, 1 ) )
{
continue;
}
$query1 = "SELECT 1 from FLOW_RUN_PRCS WHERE RUN_ID=".$RUN_ID." AND USER_ID='{$LOGIN_USER_ID}' AND PRCS_ID=1";
$cursor1 = exequery( $connection, $query1 );
if ( !mysql_fetch_array( $cursor1 ) )
{
continue;
}
$query1 = "SELECT * from FLOW_TYPE where FLOW_ID=".$FLOW_ID;
$cursor1 = exequery( $connection, $query1 );
if ( $ROW = mysql_fetch_array( $cursor1 ) )
{
$FLOW_ID = $ROW['FLOW_ID'];
$FLOW_NAME = $ROW['FLOW_NAME'];
$FLOW_TYPE = $ROW['FLOW_TYPE'];
$FLOW_SORT = $ROW['FLOW_SORT'];
$FLOW_NAME = str_replace( "<", "<", $FLOW_NAME );
$FLOW_NAME = str_replace( ">", ">", $FLOW_NAME );
$FLOW_NAME = stripslashes( $FLOW_NAME );
}
$query = "SELECT SORT_NAME from FLOW_SORT WHERE SORT_ID=".$FLOW_SORT;
$cursor1 = exequery( $connection, $query );
if ( $ROW = mysql_fetch_array( $cursor1 ) )
{
$SORT_NAME = $ROW['SORT_NAME'];
}
if ( $FLOW_TYPE == "1" )
{
$FLOW_TYPE_DESC = "固定";
}
else
{
$FLOW_TYPE_DESC = "自由";
}
++$FLOW_COUNT;
if ( $FLOW_COUNT == 1 )
{
echo " <table border=\"0\" cellspacing=\"1\" width=\"100%\" class=\"small\" bgcolor=\"#000000\" cellpadding=\"3\" align=\"center\">\r\n <tr class=\"TableHeader\">\r\n <td align=\"center\">流程</td>\r\n <td align=\"center\">上次建立的工作</td>\r\n <td nowrap align=\"center\">操作</td>\r\n </tr>\r\n";
}
if ( $FLOW_COUNT % 2 == 1 )
{
$TableLine = "TableLine1";
}
else
{
$TableLine = "TableLine2";
}
echo " <tr class=\"";
echo $TableLine;
echo "\">\r\n <td title=\"流程分类:";
echo $SORT_NAME."\n";
echo "流程类型:";
echo $FLOW_TYPE_DESC;
echo "\" >\r\n \t<b><a href=\"javascript:view_graph(";
echo $FLOW_ID;
echo ");\">";
echo $FLOW_NAME;
echo "</a></b>\r\n </td>\r\n <td>\r\n \t<a href=\"javascript:form_view(";
echo $RUN_ID;
echo ",";
echo $FLOW_ID;
echo ");\">";
echo $RUN_NAME;
echo "</a><br>\r\n \t";
echo $PRCS_TIME;
echo " </td>\r\n <td nowrap align=\"center\">\r\n \t<input type=\"button\" value=\"快速新建\" class=\"SmallButton\" name=\"back\" onClick=\"parent.location='edit.php?FLOW_ID=";
echo $FLOW_ID;
echo "&AUTO_NEW=1';\">\r\n \t<input type=\"button\" value=\"新建向导\" class=\"SmallButton\" name=\"back\" onClick=\"location='edit.php?FLOW_ID=";
echo $FLOW_ID;
echo "';\">\r\n </td>\r\n </tr>\r\n";
} while ( !( 10 <= $FLOW_COUNT ) );
if ( 0 < $FLOW_COUNT )
{
echo " </table>\r\n";
}
else
{
message( "", "无常用工作流程" );
}
echo "\r\n</body>\r\n</html>";
?>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -