通用权限管理系统组件 (GPM - General Permissions Manager) 中后一个登录的把前一个登录的踢掉功能的实现...
最近客户有需要,同一个帐户可以重复登录系统,但是后登录的账户需要把前面已经登录的账户踢掉,例如客户把电脑打开在别的电脑上然后换一个房间,或者换个办公楼想登录时就会遇到很多麻烦,遇到郁闷的情况就是死活无法登录系统,因为那个帐户已经在线了,或者2个帐户都登录了,最新消息提醒会乱套。
其实软件是否好用都是体现在能否经得起各种折磨上,有的软件把问题考虑得很充分,不管遇到什么麻烦事情都已经帮你处理好了,想得非常周到,下面我们看看通用权限管理系统里的处理方式。
1:首先系统里有设置,是否允许重复登录的选项,一般情况下默认配置是不用修改的
2:我们登录系统
3:登录到系统后的效果如下
4:每个用户登录系统后,都会产生一个新的OpenId,然后把这个OpenId保存到客户端。
5:再登录系统后,会产生新的 OpenId。
6:由于上一个登录的本地的OpenId与服务器上的OpenId不一样了,所以上一个登录系统的软件就被迫被下线了,什么烦恼都这么简单的解决了。
有了这个功能,客户就可以在任何电脑上,任何办公室,任何办公楼里都可以随时登录,不用有上一个已经登录的系统的烦恼了,爽歪歪,软件也好用了更加人性化了。
系统管理员也有能力想让那个用户下线就可以让哪个用户下线了又简单又好用了。
当前用户的信息如下:
// All Rights Reserved , Copyright (C) 2011 , Hairihan TECH, Ltd.
//-----------------------------------------------------------------
using System;
namespace DotNet.Utilities
{
/// <summary>
/// BaseUserInfo
/// 用户类
///
/// 修改纪录
///
/// 2011.09.12 JiRiGaLa 版本:2.1 公司名称、部门名称、工作组名称进行重构。
/// 2011.05.11 JiRiGaLa 版本:2.0 增加安全通讯用户名、密码。
/// 2008.08.26 JiRiGaLa 版本:1.2 整理主键。
/// 2006.05.03 JiRiGaLa 版本:1.1 添加到工程项目中。
/// 2006.01.21 JiRiGaLa 版本:1.0 远程传递参数用属性才可以。
///
/// 版本:2.1
///
/// <author>
/// <name>JiRiGaLa</name>
/// <date>2011.09.12</date>
/// </author>
/// </summary>
[Serializable]
public class BaseUserInfo
{
public BaseUserInfo()
{
this.GetUserInfo();
}
/// <summary>
/// 远程调用Service用户名(为了提高软件的安全性)
/// </summary>
private string serviceUserName = "Hairihan";
public string ServiceUserName
{
get
{
return this.serviceUserName;
}
set
{
this.serviceUserName = value;
}
}
/// <summary>
/// 远程调用Service密码(为了提高软件的安全性)
/// </summary>
private string servicePassword = "Hairihan";
public string ServicePassword
{
get
{
return this.servicePassword;
}
set
{
this.servicePassword = value;
}
}
/// <summary>
/// 单点登录唯一识别标识
/// </summary>
private string openId = string.Empty;
public string OpenId
{
get
{
return this.openId;
}
set
{
this.openId = value;
}
}
/// <summary>
/// 目标用户
/// </summary>
private string targetUserId = string.Empty;
public string TargetUserId
{
get
{
return this.targetUserId;
}
set
{
this.targetUserId = value;
}
}
/// <summary>
/// 用户主键
/// </summary>
private string id = string.Empty;
public string Id
{
get
{
return this.id;
}
set
{
this.id = value;
}
}
/// <summary>
/// 员工主键
/// </summary>
private string staffId = string.Empty;
public string StaffId
{
get
{
return this.staffId;
}
set
{
this.staffId = value;
}
}
/// <summary>
/// 用户用户名
/// </summary>
private string userName = string.Empty;
public string UserName
{
get
{
return this.userName;
}
set
{
this.userName = value;
}
}
/// <summary>
/// 用户姓名
/// </summary>
private string realName = string.Empty;
public string RealName
{
get
{
return this.realName;
}
set
{
this.realName = value;
}
}
/// <summary>
/// 编号
/// </summary>
private string code = string.Empty;
public string Code
{
get
{
return this.code;
}
set
{
this.code = value;
}
}
/// <summary>
/// 当前的组织结构公司主键
/// </summary>
private int? companyId = null;
public int? CompanyId
{
get
{
return this.companyId;
}
set
{
this.companyId = value;
}
}
/// <summary>
/// 当前的组织结构公司编号
/// </summary>
private string companyCode = string.Empty;
public string CompanyCode
{
get
{
return this.companyCode;
}
set
{
this.companyCode = value;
}
}
/// <summary>
/// 当前的组织结构公司名称
/// </summary>
private string companyName = string.Empty;
public string CompanyName
{
get
{
return this.companyName;
}
set
{
this.companyName = value;
}
}
/// <summary>
/// 当前的组织结构部门主键
/// </summary>
private int? departmentId = null;
public int? DepartmentId
{
get
{
return this.departmentId;
}
set
{
this.departmentId = value;
}
}
/// <summary>
/// 当前的组织结构部门编号
/// </summary>
private string departmentCode = string.Empty;
public string DepartmentCode
{
get
{
return this.departmentCode;
}
set
{
this.departmentCode = value;
}
}
/// <summary>
/// 当前的组织结构部门名称
/// </summary>
private string departmentName = string.Empty;
public string DepartmentName
{
get
{
return this.departmentName;
}
set
{
this.departmentName = value;
}
}
/// <summary>
/// 当前的组织结构工作组主键
/// </summary>
private int? workgroupId = null;
public int? WorkgroupId
{
get
{
return this.workgroupId;
}
set
{
this.workgroupId = value;
}
}
/// <summary>
/// 当前的组织结构工作组编号
/// </summary>
private string workgroupCode = string.Empty;
public string WorkgroupCode
{
get
{
return this.workgroupCode;
}
set
{
this.workgroupCode = value;
}
}
/// <summary>
/// 当前的组织结构工作组名称
/// </summary>
private string workgroupName = string.Empty;
public string WorkgroupName
{
get
{
return this.workgroupName;
}
set
{
this.workgroupName = value;
}
}
/// <summary>
/// 默认角色
/// </summary>
private int? roleId = null;
public int? RoleId
{
get
{
return this.roleId;
}
set
{
this.roleId = value;
}
}
/// <summary>
/// 安全级别
/// </summary>
private int securityLevel = 0;
public int SecurityLevel
{
get
{
return this.securityLevel;
}
set
{
this.securityLevel = value;
}
}
/// <summary>
/// 默认角色名称
/// </summary>
private string roleName = string.Empty;
public string RoleName
{
get
{
return this.roleName;
}
set
{
this.roleName = value;
}
}
/// <summary>
/// 是否超级管理员
/// </summary>
private bool isAdministrator = false;
public bool IsAdministrator
{
get
{
return this.isAdministrator;
}
set
{
this.isAdministrator = value;
}
}
/// <summary>
/// 密码
/// </summary>
private string password = string.Empty;
public string Password
{
get
{
return this.password;
}
set
{
this.password = value;
}
}
/// <summary>
/// IP地址
/// </summary>
private string ipAddress = string.Empty;
public string IPAddress
{
get
{
return this.ipAddress;
}
set
{
this.ipAddress = value;
}
}
/// <summary>
/// MAC地址
/// </summary>
private string macAddress = string.Empty;
public string MACAddress
{
get
{
return this.macAddress;
}
set
{
this.macAddress = value;
}
}
/// <summary>
/// 当前语言选择
/// </summary>
private string currentLanguage = string.Empty;
public string CurrentLanguage
{
get
{
return this.currentLanguage;
}
set
{
this.currentLanguage = value;
}
}
/// <summary>
/// 当前布局风格选择
/// </summary>
private string themes = string.Empty;
public string Themes
{
get
{
return this.themes;
}
set
{
this.themes = value;
}
}
/// <summary>
/// 描述
/// </summary>
private string description = string.Empty;
public string Description
{
get
{
return this.description;
}
set
{
this.description = value;
}
}
#region public void GetUserInfo()
/// <summary>
/// 获取信息
/// </summary>
public void GetUserInfo()
{
this.ServiceUserName = BaseSystemInfo.ServiceUserName;
this.ServicePassword = BaseSystemInfo.ServicePassword;
this.CurrentLanguage = BaseSystemInfo.CurrentLanguage;
this.Themes = BaseSystemInfo.Themes;
}
#endregion
}
}
通用权限管理系统组件 (GPM - General Permissions Manager) 中后一个登录的把前一个登录的踢掉功能的实现...相关推荐
- 通用权限管理系统组件 (GPM - General Permissions Manager) 中实现按部门组织机构设置权限...
政府性质的单位里很少有人员流动,一般对系统的权限要求都是相对固定一些,所以有时候会有对系统按所在部门进行配置的需求,而且很有说服力,我们通用权限管理系统组件里也同样可以权限按所在部门设置.可以灵活满足 ...
- 通用权限管理系统组件 (GPM - General Permissions Manager) 中及时通讯功能的改进
以前的通用权限管理系统的及时通讯只能按组织机构展示用户列表结构,现在不仅仅可以按组织机构展示,还可以按系统应用角色分组,用户自己的个性化通讯录分组进行展示用户数据了,用起来也应该更符合大家的习惯了. ...
- 通用权限管理系统组件 (GPM - General Permissions Manager) 中集成多系统的统一登录(数据库源码级)附源码...
眼前有20万行以上的代码时很多人都会眼花缭乱,不知道从哪里开始下手了,甚至不会去研究几下就直接放弃了.其实大多时候没有想象的那么复杂,代码里一大部分都是有重复的,有本质上差别的部分还是很少的. 春节期 ...
- 通用权限管理系统组件 (GPM - General Permissions Manager) 中实现系统参数配置保存,附源码...
其实GPM不仅仅是权限管理系统,其实更是一个灵活的轻量级快速.Net开发架构,他需要最短的学习时间,可以最快速入门,并不是通过玩技术来实现我们的日常需求.GPM中只要写一套代码,就可以实现在多种数据库 ...
- 通用权限管理系统组件 (GPM - General Permissions Manager) 给信息管理系统加一个初始化的功能,调用存储过程...
系统初始化的运行效果如下: 参数表是为了防止反复被初始化的,防止关键数据丢失. 其实很多人都提过希望有系统初始化的功能,最近稍微空一些,就给系统增加了一个初始化的功能,给大家参考一下. 首先写了一个存 ...
- 通用权限管理系统组件 (GPM - General Permissions Manager) - 支持请求
为什么80%的码农都做不了架构师?>>> 首先感谢您支持关注通用权限管理系统组件,若有什么我们可以帮助您的,可以在下面留言发表您的建议,我们会尽快与您联系. 转载于:https ...
- 通用权限管理系统组件 (GPM - General Permissions Manager) 不改数据库、甚至不写代码就集成铜墙铁壁权限管理组件...
为什么80%的码农都做不了架构师?>>> 越成熟的东西,越牛X的东西,越简单才对,简单才是硬道理,苹果的手机只有少数几个按键,苹果Ipad也很少的按钮,甚至连苹果的笔记本键盘都 ...
- 通用权限管理系统组件 (GPM - General Permissions Manager) 在跨国直销企业电子商务项目中的成功应用...
我所在是一家跨国家直销公司,在亚太某国家电子商务项目中,2011年底系统全面应用了通用权限数据访问层类库及工具类库,支持了每月万级会员加入.千万级订单:同时,在我们的项目开发过程中,完全由外包工程师来 ...
- 通用权限管理系统组件 (GPM - General Permissions Manager)
只开发一套业务管理系统,或者只维护一套业务管理系统是相对简单的事情,但是你要同时给多个客户开发多套系统,或者同时维护多个公司提供的多套系统时烦恼就来了,我们通用权限管理系统里有比较好的实现方式,有可以 ...
最新文章
- python3正则表达式符号和用法
- 安装Synchronization service (Project Server 2007) 时出现 MSMQ 错误的解决
- Serverless 工程实践 | 自建 Apache OpenWhisk 平台
- JDBC链接oracle已经mysql的测试
- Microsoft Visual Studio下编译缺少头文件unistd.h解决办法
- python资产管理系统_Python [5] IT资产管理(上)
- laravel 环境自编译过程
- 数据结构-单链表的正向排序
- 【python6】快递分拣小程序
- Modem2G/3G/4G/5G:吐血总结:30分钟掌握高通modem RFFE driver(射频驱动)配置方法(一)
- 控制反转和依赖注入的理解(通俗易懂)
- linux 安装pkg文件,Linux的pkg-config命令
- 第4章-模板引擎Jade和Handlebars-4.2.Jade的语法和特性
- 卫星过顶计算matlab,基于SGP4模型的卫星轨道计算.docx
- 使用JavaScript制作轮播
- CRC16 计算函数
- C#对serialport 类的封装
- Unity动态加载场景
- Android 12 新APP启动画面(SplashScreen API)简介源码分析
- 聊聊人工智能的神奇公式:贝叶斯公式
热门文章
- go run/ go install/ go build / go get的区别
- bootstrap简单登录界面
- 条件语句,while循环语句:完整的温度转换程序
- 【渣硕的数学笔记】数值分析
- 3.11课·········异常语句与for循环重复
- PHP-数据库长连接mysql_pconnect的细节
- HDU 1398 Square Coins
- 剑灵总显示服务器断开连接,求解一分钟“与服务器断开连接”问题
- tt桌球瞄准器手机版_新年换台新手机!各价位段哪些机型值得入手?
- 浙江大学计算机考研大纲,2018年浙江大学研究生入学考试《计算机学科专业基础》(878)考试大纲...