You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
58 lines
1.9 KiB
58 lines
1.9 KiB
11 months ago
|
using System.Web;
|
||
|
using System.Data;
|
||
|
|
||
|
namespace FangYar.WebUI.Handle
|
||
|
{
|
||
|
/// <summary>
|
||
|
/// VISGDT 的摘要说明 根据人证机设备编号 获取部门、人员Tree
|
||
|
/// </summary>
|
||
|
public class VIShostEmp : IHttpHandler
|
||
|
{
|
||
|
private FangYar.BLL.TBL.SysEmpBLL ebll = new FangYar.BLL.TBL.SysEmpBLL();
|
||
|
private FangYar.BLL.OA.TBL_EPUIP_ORG eobll = new FangYar.BLL.OA.TBL_EPUIP_ORG();
|
||
|
|
||
|
public void ProcessRequest(HttpContext context)
|
||
|
{
|
||
|
context.Response.ContentType = "text/plain";
|
||
|
string returnStr = "";
|
||
|
|
||
|
returnStr = ReceiveAlarmInfoPlate(context);
|
||
|
context.Response.Write(returnStr);
|
||
|
}
|
||
|
|
||
|
//硬件接口:
|
||
|
//根据人证机设备编号 获取Tree 本机构下-部门-员工(获取UID)
|
||
|
private string ReceiveAlarmInfoPlate(HttpContext context)
|
||
|
{
|
||
|
string returnstr = "";
|
||
|
try
|
||
|
{
|
||
|
//string EpuId = context.Request.Params["deviceNumber"];
|
||
|
string hostDeptId = context.Request.Params["hostDeptId"];
|
||
|
if (hostDeptId != null || hostDeptId != "")
|
||
|
{
|
||
|
returnstr = "{\"code\":200,\"msg\":\"success\",\"data\":";
|
||
|
DataTable data = ebll.deptIdGetEmpList(hostDeptId);
|
||
|
returnstr += FangYar.Common.JsonHelper.ToJson(data);
|
||
|
}
|
||
|
else
|
||
|
{
|
||
|
returnstr = "{\"code\":0,\"msg\":\"未查询到设备所属机构\",\"data\":[]}";
|
||
|
}
|
||
|
returnstr += "}";
|
||
|
}
|
||
|
catch
|
||
|
{
|
||
|
returnstr = "{\"code\":0,\"msg\":\"error\",\"count\":0,\"data\":[]}";
|
||
|
}
|
||
|
return returnstr;
|
||
|
}
|
||
|
public bool IsReusable
|
||
|
{
|
||
|
get
|
||
|
{
|
||
|
return false;
|
||
|
}
|
||
|
}
|
||
|
}
|
||
|
}
|