⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 popedom_mdy.asp

📁 一个很好的asp cms管理系统
💻 ASP
字号:
<%
Option Explicit
'----------------------------------------------------------------------------------
'本页:
'	权限编辑页面
'说明:
'
'----------------------------------------------------------------------------------
%>
<!--#include file="inc/Config.class.asp"-->
<!--#include file="inc/DBControl.class.asp"-->
<!--#include file="inc/FunctionLib.class.asp"-->
<!--#include file="inc/Manager.class.asp"-->
<%
Dim Cfg, Db, FLib, Admin
Set Cfg = New Config
Set Db = New DBControl
Set FLib = New FunctionLib
Set Admin = New Manager

If Not Admin.Logined Then
    FLib.Alert "对不起,你已经超时或未登录","./",1
    Response.End
End If

If Not Admin.CheckPopedom("TSYS_GROUP3_POPEDOM") Then
    FLib.Alert "权限不足", "BACK", 0
    Response.End
ENd If

Db.Open()

Dim Parent, Work
    Parent = FLib.SafeSql(Request("Parent"))
    Work = Request("Work")
If Parent = "" Or Not IsNumeric(Parent) Then
    Parent = 0
End If
%>
<html>
<head>
<title>Untitled Document</title>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<link rel="stylesheet" href="inc/style.css" type="text/css">
<SCRIPT LANGUAGE="JavaScript" src="inc/FunctionLib.js"></script>
<SCRIPT LANGUAGE="JavaScript">
<!--
function chkForm_AddReco(obj)
{
    if(obj.parent.value == "")
    {
        obj.parent.focus();
        alert("请确定[上级权限]Id");
        return false;
    }
    if(obj.title.value == "")
    {
        obj.title.focus();
        alert("请确定[权限名称]");
        return false;
    }
    if(obj.pope_key.value == "")
    {
        obj.pope_key.focus();
        alert("请确定[权限标识]");
        return false;
    }else{
        if(!Check_PopedomKey(obj.pope_key.value))
        {
            obj.pope_key.focus();
            alert("[权限标识]格式有误");
            return false;
        }
    }

    return true;
}

function chkForm_MdyReco(obj)
{
    if(obj.parent.value == "")
    {
        obj.parent.focus();
        alert("请确定[上级权限]Id");
        return false;
    }
    if(obj.title.value == "")
    {
        obj.title.focus();
        alert("请确定[权限名称]");
        return false;
    }
    if(obj.pope_key.value == "")
    {
        obj.pope_key.focus();
        alert("请确定[权限标识]");
        return false;
    }else{
        if(!Check_PopedomKey(obj.pope_key.value))
        {
            obj.pope_key.focus();
            alert("[权限标识]格式有误");
            return false;
        }
    }

    return true;
}
//-->
</SCRIPT>
</head>

<body bgcolor="#FFFFFF" text="#000000">
<%
Select Case Work
    Case "MdyReco"
        MdyReco()
    Case "AddReco"
        AddReco()
    Case Else
End Select

Function AddReco()
	Dim PKey
		PKey = Request("PKey")
%>
<table width="100%" border="0" cellspacing="0" cellpadding="0" class="tabTitleBar">
  <tr> 
    <td>系统管理 &gt; 权限管理 &gt; 增加权限</td>
  </tr>
</table>
<form name="form1" method="post" action="Popedom_Process.asp" onsubmit="return chkForm_AddReco(this)">
  <table width="700" border="0" cellspacing="0" cellpadding="3">
    <tr> 
      <td width="25%" align="right">当前位置:</td>
      <td width="75%"><%=FLib.Path_PopedomList(Parent, "Popedom_List.asp?")%> </td>
    </tr>
    <tr> 
      <td width="25%" align="right">上级权限:</td>
      <td width="75%"> <input name="parent" type="text" class="input_text" value="<%=Parent%>"> 
      </td>
    </tr>
    <tr> 
      <td width="25%" align="right">权限名称:</td>
      <td width="75%"> <input name="title" type="text" class="input_text"> </td>
    </tr>
    <tr> 
      <td width="25%" align="right">权限标识:</td>
      <td width="75%"> <input name="pope_key" type="text" class="input_text" value="<%If PKey <> "" Then Response.Write PKey & "_" End If%>"> 
        <span class="txtNote">必须为[a-z、0-9和下划线]的组合</span> </td>
    </tr>
    <tr> 
      <td width="25%" align="right">备注:</td>
      <td width="75%"> <input name="remark" type="text" class="input_text" size="60"> </td>
    </tr>
    <tr> 
      <td width="25%" align="right" valign="top">是否显示:</td>
      <td width="75%"> <input type="radio" name="show" value="1" checked>
        <input type="radio" name="show" value="0">
        否</td>
    </tr>
    <tr> 
      <td align="right" valign="top">显示优先:</td>
      <td> 
        <input name="show_order" type="text" class="input_text" id="show_order" value="0" size="6">
         <span class="txtNote"> 
        (值越大显示越靠前)</span></td>
    </tr>
    <tr> 
      <td width="25%" align="right" valign="top">&nbsp;</td>
      <td width="75%">&nbsp;</td>
    </tr>
    <tr> 
      <td width="25%" align="right" valign="top">&nbsp;</td>
      <td width="75%"> <input name="Submit43" type="submit" class="input_button" value="提  交"> <input name="Submit223" type="reset" class="input_button" value="复位"> 
        <input name="Submit323" type="button" class="input_button" onClick="window.history.back()" value="返回"> 
        <input type="hidden" name="Work" value="AddReco"> </td>
    </tr>
  </table>
</form>
<%
End Function

Function MdyReco()

    Dim rId
        rId = FLib.SafeSql(Request("rId"))
    Dim Sql, Rs
        Sql = "SELECT * FROM popedom_list WHERe id=" & rId
    Set Rs = Db.ExeCute(Sql)

    If Rs.Eof And Rs.Bof Then
        Rs.Close
        Set Rs = Nothing
        FLib.Alert "记录不存在", "BACK", 0
        Response.End
    End If
%>
<table width="100%" border="0" cellspacing="0" cellpadding="0" class="tabTitleBar">
  <tr> 
    <td>系统管理 &gt; 权限管理 &gt; 修改权限</td>
  </tr>
</table>
<form name="form1" method="post" action="Popedom_Process.asp" onsubmit="return chkForm_MdyReco(this)">
  <table width="700" border="0" cellspacing="0" cellpadding="3">
    <tr> 
      <td width="25%" align="right">当前位置:</td>
      <td width="75%"><%=FLib.Path_PopedomList(Parent, "Popedom_List.asp?")%> </td>
    </tr>
    <tr> 
      <td width="25%" align="right">上级权限:</td>
      <td width="75%"> <input name="parent" type="text" class="input_text" value="<%=Rs("parent")%>"> 
      </td>
    </tr>
    <tr> 
      <td width="25%" align="right">权限名称:</td>
      <td width="75%"> <input name="title" type="text" class="input_text" value="<%=Rs("title")%>"> 
      </td>
    </tr>
    <tr> 
      <td width="25%" align="right" valign="top">权限标识:</td>
      <td width="75%"> <input name="pope_key" type="text" class="input_text" value="<%=Rs("pope_key")%>"> 
        <span class="txtNote">必须为[a-z、0-9和下划线]的组合</span> </td>
    </tr>
    <tr> 
      <td width="25%" align="right" valign="top">备注:</td>
      <td width="75%"> <input name="remark" type="text" class="input_text" value="<%=Rs("remark")%>" size="60"> 
      </td>
    </tr>
    <tr> 
      <td width="25%" align="right" valign="top">是否显示:</td>
      <td width="75%"> <input type="radio" name="show" value="1" <%If Rs("show")=1 Then Response.Write "checked"End If%>>
        <input type="radio" name="show" value="0" <%If Rs("show")=0 Then Response.Write "checked"End If%>>
        否</td>
    </tr>
    <tr> 
      <td align="right" valign="top">显示优先:</td>
      <td> 
        <input name="show_order" type="text" class="input_text" id="show_order" value="<%=Rs("show_order")%>" size="6"> 
        <span class="txtNote"> (值越大显示越靠前)</span></td>
    </tr>
    <tr> 
      <td width="25%" align="right" valign="top">&nbsp;</td>
      <td width="75%">&nbsp;</td>
    </tr>
    <tr> 
      <td width="25%" align="right" valign="top">&nbsp;</td>
      <td width="75%"> <input name="Submit43" type="submit" class="input_button" value="提  交" <%If Rs("owner") = 1 Then Response.Write "disabled" End If%>> 
        <input name="Submit223" type="reset" class="input_button" value="复位"> <input name="Submit323" type="button" class="input_button" onClick="window.history.back()" value="返回"> 
        <input type="hidden" name="Work" value="MdyReco"> <input type="hidden" name="rId" value="<%=rId%>"> 
      </td>
    </tr>
  </table>
</form>
<%
End Function
%>

</body>
</html>

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -