using System; using System.Collections.Generic; using System.Linq; using System.Security; using System.Text; using System.Threading.Tasks; namespace Rs.MotionPlat.Commom { public enum EUserLevel { Vender, Op, Admin } public class GlobalUser { public static string UserName; public static EUserLevel UserLevel; public static bool IsNologin() { if (string.IsNullOrEmpty(UserName)) { return true; } return false; } public static bool IsOp() { if (!string.IsNullOrEmpty(UserName) && UserName == "操作员") { return true; } return false; } public static bool IsVender() { if (!string.IsNullOrEmpty(UserName) && UserName == "厂商") { return true; } return false; } public static bool IsSuper() { if(!string.IsNullOrEmpty(UserName) && UserName=="超级用户") { return true; } return false; } } }