DotNet.WebApplication/Core/BasePage.User.cs
(开头部分) 6KB这里只显示每个文件的开头 60 行。登录后可以解锁完整代码。
//-----------------------------------------------------------------
// All Rights Reserved , Copyright (C) 2013 , Hairihan TECH, Ltd .
//-----------------------------------------------------------------
using System.Collections.Generic;
using System.Data;
using System.Web.UI.WebControls;
using DotNet.Business;
/// <remarks>
/// BasePage
/// 基础网页类
///
/// 修改纪录
///
/// 版本:1.0 2012.11.10 JiRiGaLa 整理代码。
///
/// 版本:1.0
/// <author>
/// <name>JiRiGaLa</name>
/// <date>2012.11.10</date>
/// </author>
/// </remarks>
public partial class BasePage : System.Web.UI.Page
{
/// <summary>
/// 获取用户列表
/// </summary>
/// <param name="organizeId">组织机构主键</param>
/// <param name="containSelf">是否包含自己</param>
/// <param name="securityLevel">安全级别</param>
/// <returns>数据表</returns>
protected DataTable GetUser(string organizeId = null, bool? containSelf = null, int? securityLevel = null)
{
DataTable dtUser = null;
BaseUserManager manager = new BaseUserManager(this.UserCenterDbHelper, this.UserInfo);
string sqlQuery = string.Empty;
sqlQuery = " SELECT * "
+ " FROM " + BaseUserEntity.TableName
+ " WHERE (" + BaseUserEntity.FieldDeletionStateCode + " = 0 "
+ " AND " + BaseUserEntity.FieldEnabled + " = 1 "
+ " AND " + BaseUserEntity.FieldIsVisible + " = 1 ";
if (!string.IsNullOrEmpty(organizeId))
{
sqlQuery += " AND " + BaseUserEntity.FieldDepartmentId + " = '" + organizeId + "' ";
}
if (securityLevel != null)
{
sqlQuery += " AND " + BaseUserEntity.FieldSecurityLevel + " < " + securityLevel + " ";
}
sqlQuery += " ) ";
if (containSelf.HasValue)
{
if (containSelf == true)
{
sqlQuery += " OR ( " + BaseUserEntity.FieldId + " = '" + this.UserInfo.Id + "'";
sqlQuery += " AND ( " + BaseUserEntity.FieldCompanyId + " = '" + organizeId + "'";
后面还有 112 行代码,购买后查看完整代码
24 小时内免费解锁 3 个项目,之后 1 积分/个。 规则说明
AI 解读
登录后可用,每次 10 积分,解读结果公开显示在下面。
还没有人解读过这个文件。
