📄 edit.php
字号:
<?php
include_once( "inc/auth.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\r\n";
echo "<S";
echo "CRIPT language=javascript>\r\n\r\nfunction clear_content(OBJ)\r\n{\r\n OBJ.value=\"\";\r\n}\r\n\r\nfunction LoadWindow(form_name,table_id)\r\n{\r\n URL=\"field_select/?FORM_NAME=\"+form_name+\"&TABLE_ID=\"+table_id;\r\n loc_x=document.body.scrollLeft+event.clientX-event.offsetX-100;\r\n loc_y=document.body.scrollTop+event.clientY-event.offsetY+170;\r\n window.showModalDialog(URL,self,\"edge:raised;scroll:1;status:0;help:0;";
echo "resizable:1;dialogWidth:300px;dialogHeight:210px;dialogTop:\"+loc_y+\"px;dialogLeft:\"+loc_x+\"px\");\r\n}\r\n</SCRIPT>\r\n</head>\r\n\r\n<body class=\"bodycolor\" topmargin=\"5\">\r\n";
if ( $APP_ID != "" )
{
$TITLE = "编辑应用";
}
else
{
$TITLE = "新建应用";
}
echo "\r\n<table border=\"0\" width=\"100%\" cellspacing=\"0\" cellpadding=\"3\" class=\"small\">\r\n <tr>\r\n <td class=\"Big\"><img src=\"/images/edit.gif\" WIDTH=\"22\" HEIGHT=\"20\" align=\"absmiddle\">";
echo "<s";
echo "pan class=\"big3\"> ";
echo $TITLE;
echo "</span><br>\r\n </td>\r\n </tr>\r\n</table>\r\n\r\n";
$connection = openconnection( );
if ( $APP_ID != "" )
{
$query = "SELECT * from IK_APP where APP_ID={$APP_ID}";
$cursor = exequery( $connection, $query );
if ( $ROW = mysql_fetch_array( $cursor ) )
{
$APP_ID = $ROW['APP_ID'];
$FORM_ID = $ROW['FORM_ID'];
$APP_TYPE = $ROW['APP_TYPE'];
$APP_FLD_VIEW = $ROW['APP_FLD_VIEW'];
$APP_FLD_READONLY = $ROW['APP_FLD_READONLY'];
$APP_FLD_LIST = $ROW['APP_FLD_LIST'];
$APP_FLD_REPORT = $ROW['APP_FLD_REPORT'];
$APP_FLD_CTRL = $ROW['APP_FLD_CTRL'];
$APP_DESC = $ROW['APP_DESC'];
$APP_RETURN = $ROW['APP_RETURN'];
$FUNC_ID = $ROW['FUNC_ID'];
$EDIT_APP_ID = $ROW['EDIT_APP_ID'];
}
}
echo "\r\n<hr width=\"95%\" height=\"1\" align=\"left\" class=\"big1\">\r\n\r\n<table border=\"0\" width=\"450\" cellpadding=\"2\" cellspacing=\"1\" align=\"center\" bgcolor=\"#000000\" class=\"small\">\r\n <form action=\"";
if ( $APP_ID != "" )
{
echo "update";
}
else
{
echo "insert";
}
echo ".php\" method=\"post\" name=\"form1\">\r\n";
if ( $APP_ID != "" )
{
echo " <tr>\r\n <td nowrap class=TableData>应用编号:</td>\r\n <td class=\"TableData\">\r\n <input type=\"text\" name=\"APP_ID\" size=\"5\" class=\"BigStatic\" value=\"";
echo $APP_ID;
echo "\" readonly>\r\n </td>\r\n </tr>\r\n";
}
echo " <tr>\r\n <td nowrap class=\"TableData\">表单:</td>\r\n <td class=\"TableData\">\r\n ";
echo "<s";
echo "elect name=\"FORM_ID\" class=";
if ( $APP_ID == "" )
{
echo "BigSelect";
}
else
{
echo "BigStatic";
}
echo ">\r\n";
if ( $APP_ID == "" )
{
$query = "SELECT * from IK_FORM";
}
else
{
$query = "SELECT * from IK_FORM where FORM_ID={$FORM_ID}";
}
$cursor = exequery( $connection, $query );
while ( $ROW = mysql_fetch_array( $cursor ) )
{
$FORM_ID1 = $ROW['FORM_ID'];
$TABLE_ID = $ROW['TABLE_ID'];
$FORM_DESC = $ROW['FORM_DESC'];
echo " <option value=\"";
echo $FORM_ID1;
echo "\" ";
if ( $FORM_ID == $FORM_ID1 )
{
echo "selected";
}
echo ">";
echo $FORM_DESC;
echo "</option>\r\n";
}
echo " </select>\r\n </td>\r\n </tr>\r\n <tr>\r\n <td nowrap class=\"TableData\">应用类型:</td>\r\n <td class=\"TableData\">\r\n ";
echo "<s";
echo "elect name=\"APP_TYPE\" class=\"BigSelect\">\r\n <option value=\"1\" ";
if ( $APP_TYPE == "1" )
{
echo "selected";
}
echo ">新建单记录</option>\r\n <option value=\"2\" ";
if ( $APP_TYPE == "2" )
{
echo "selected";
}
echo ">新建多记录</option>\r\n <option value=\"3\" ";
if ( $APP_TYPE == "3" )
{
echo "selected";
}
echo ">修改</option>\r\n <option value=\"4\" ";
if ( $APP_TYPE == "4" )
{
echo "selected";
}
echo ">查询</option>\r\n </select>\r\n </td>\r\n </tr>\r\n <tr>\r\n <td nowrap class=\"TableContent\">应用描述:</td>\r\n <td class=\"TableData\">\r\n <input type=\"text\" name=\"APP_DESC\" size=\"30\" class=\"BigInput\" value=\"";
echo $APP_DESC;
echo "\">\r\n </td>\r\n </tr>\r\n <tr>\r\n <td nowrap class=TableContent>返回URL:</td>\r\n <td class=\"TableData\">\r\n <input type=\"text\" name=\"APP_RETURN\" size=\"50\" class=\"BigInput\" value=\"";
echo $APP_RETURN;
echo "\">\r\n </td>\r\n </tr>\r\n";
if ( $APP_ID != "" )
{
echo " <tr>\r\n <td nowrap class=\"TableData\">不显示字段:</td>\r\n <td class=\"TableData\">\r\n <input type=\"text\" name=\"APP_FLD_VIEW\" size=\"30\" class=\"BigStatic\" value=\"";
echo $APP_FLD_VIEW;
echo "\" readonly>\r\n <input type=\"button\" value=\"添 加\" class=\"SmallButton\" onClick=\"LoadWindow('APP_FLD_VIEW',";
echo $TABLE_ID;
echo ")\" title=\"添加可显示字段\" name=\"button\">\r\n <input type=\"button\" value=\"清 空\" class=\"SmallButton\" onClick=\"clear_content(document.form1.APP_FLD_VIEW)\" title=\"清空可显示字段\" name=\"button\">\r\n </td>\r\n </tr>\r\n <tr>\r\n <td nowrap class=\"TableData\">只读字段:</td>\r\n <td class=\"TableData\">\r\n <input type=\"text\" name=\"APP_FLD_READONLY\" size=\"30\" class=\"BigStatic\" value=\"";
echo $APP_FLD_READONLY;
echo "\" readonly>\r\n <input type=\"button\" value=\"添 加\" class=\"SmallButton\" onClick=\"LoadWindow('APP_FLD_READONLY',";
echo $TABLE_ID;
echo ")\" title=\"添加只读字段\" name=\"button\">\r\n <input type=\"button\" value=\"清 空\" class=\"SmallButton\" onClick=\"clear_content(document.form1.APP_FLD_READONLY)\" title=\"清空只读字段\" name=\"button\">\r\n </td>\r\n </tr>\r\n <tr>\r\n <td nowrap class=\"TableData\">默认列表字段(必填字段):</td>\r\n <td class=\"TableData\">\r\n <input type=\"text\" name=\"APP_FLD_LIST\" size=\"30\" class=\"BigStatic\" valu";
echo "e=\"";
echo $APP_FLD_LIST;
echo "\" readonly>\r\n <input type=\"button\" value=\"添 加\" class=\"SmallButton\" onClick=\"LoadWindow('APP_FLD_LIST',";
echo $TABLE_ID;
echo ")\" title=\"添加默认列表字段\" name=\"button\">\r\n <input type=\"button\" value=\"清 空\" class=\"SmallButton\" onClick=\"clear_content(document.form1.APP_FLD_LIST)\" title=\"清空默认列表字段\" name=\"button\">\r\n </td>\r\n </tr>\r\n <tr>\r\n <td nowrap class=\"TableData\">默认报表合计字段:</td>\r\n <td class=\"TableData\">\r\n <input type=\"text\" name=\"APP_FLD_REPORT\" size=\"30\" class=\"BigStatic\" value=";
echo "\"";
echo $APP_FLD_REPORT;
echo "\" readonly>\r\n <input type=\"button\" value=\"添 加\" class=\"SmallButton\" onClick=\"LoadWindow('APP_FLD_REPORT',";
echo $TABLE_ID;
echo ")\" title=\"添加默认表表字段\" name=\"button\">\r\n <input type=\"button\" value=\"清 空\" class=\"SmallButton\" onClick=\"clear_content(document.form1.APP_FLD_REPORT)\" title=\"清空默认表表字段\" name=\"button\">\r\n </td>\r\n </tr>\r\n <tr>\r\n <td nowrap class=\"TableData\">列表允许管理:</td>\r\n <td class=\"TableData\">\r\n ";
echo "<s";
echo "elect name=\"APP_FLD_CTRL\" class=\"BigSelect\">\r\n <option value=\"0\" ";
if ( $APP_FLD_CTRL == "0" )
{
echo "selected";
}
echo ">否</option>\r\n <option value=\"1\" ";
if ( $APP_FLD_CTRL == "1" )
{
echo "selected";
}
echo ">是</option>\r\n </select>\r\n </td>\r\n </tr>\r\n <tr>\r\n <td nowrap class=\"TableData\">关联应用编号:</td>\r\n <td class=\"TableData\">\r\n <input type=\"text\" name=\"EDIT_APP_ID\" size=\"10\" class=\"BigInput\" value=\"";
echo $EDIT_APP_ID;
echo "\">\r\n </td>\r\n </tr>\r\n <tr>\r\n <td nowrap class=\"TableContent\">模块编号:</td>\r\n <td class=\"TableData\">\r\n <input type=\"text\" name=\"FUNC_ID\" size=\"10\" class=\"BigInput\" value=\"";
echo $FUNC_ID;
echo "\">\r\n </td>\r\n </tr>\r\n";
}
echo " <tr align=\"center\" class=\"TableControl\">\r\n <td colspan=\"2\" nowrap>\r\n <input type=\"submit\" value=\"保存\" class=\"BigButton\" name=\"submit\"> \r\n <input type=\"button\" value=\"返回\" class=\"BigButton\" name=\"back\" onClick=\"history.back();\">\r\n </td>\r\n </tr>\r\n </form>\r\n</table>\r\n</body>\r\n</html>";
?>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -