阅读笔记(一)

  1. 
    通过Common.sink()来获取post和get提交值;
    int S_ID = (int)Common.sink("S_ID", MethodType.Get, 255, 0, DataType.Int);
    string CMD = (string)Common.sink("CMD", MethodType.Get, 50, 0, DataType.Str);
  2. 通过FrameWorkPermission.CheckPagePermission()来检查是否有权限操作
    Code

            /// <summary>
    /// 根据CMD检测权限
    /// </summary>
    /// <param name="CMD">CMD值</param>
    public static void CheckPagePermission(string CMD)
    {
    switch (CMD)
    {
    case "List":
    CheckPermissionVoid(PopedomType.List);
    break;
    case "New":
    CheckPermissionVoid(PopedomType.New);
    break;
    case "Edit":
    CheckPermissionVoid(PopedomType.Edit);
    break;
    case "OrderBy":
    CheckPermissionVoid(PopedomType.Edit);
    break;
    case "Move":
    CheckPermissionVoid(PopedomType.Delete);
    break;
    case "Delete":
    CheckPermissionVoid(PopedomType.Delete);
    break;
    }
    }

    
    
posted @ 2008-12-02 20:50  菜鸟老师  阅读(384)  评论(0编辑  收藏  举报