This commit is contained in:
夏菊 2025-08-12 16:57:17 +08:00
parent 8e4dec9037
commit f8ffd9d30d
5 changed files with 55 additions and 60 deletions

View File

@ -5,8 +5,6 @@ namespace BLL
{ {
public static class DepartService public static class DepartService
{ {
public static Model.CNPCDB db = Funs.DB;
/// <summary> /// <summary>
/// 根据主键获取信息 /// 根据主键获取信息
/// </summary> /// </summary>

View File

@ -12,7 +12,6 @@
overflow:scroll; overflow:scroll;
background:#f2f5f7; background:#f2f5f7;
color:#362b36; color:#362b36;
ov
} }
</style> </style>
</head> </head>

View File

@ -91,8 +91,7 @@
</f:Button> </f:Button>
<f:Button ID="btnPersonOut" ToolTip="批量出场" Icon="UserGo" runat="server" Hidden="true" OnClick="btnPersonOut_Click"> <f:Button ID="btnPersonOut" ToolTip="批量出场" Icon="UserGo" runat="server" Hidden="true" OnClick="btnPersonOut_Click">
</f:Button> </f:Button>
<f:Button ID="btnImport" ToolTip="导入" Icon="ApplicationGet" Hidden="true" runat="server" <f:Button ID="btnImport" ToolTip="导入" Icon="PackageIn" Hidden="true" runat="server" OnClick="btnImport_Click">
OnClick="btnImport_Click">
</f:Button> </f:Button>
<f:Button ID="btnOut" OnClick="btnOut_Click" runat="server" ToolTip="导出" Icon="FolderUp" <f:Button ID="btnOut" OnClick="btnOut_Click" runat="server" ToolTip="导出" Icon="FolderUp"
EnableAjax="false" DisableControlBeforePostBack="false"> EnableAjax="false" DisableControlBeforePostBack="false">

View File

@ -61,62 +61,61 @@ namespace FineUIPro.Web
{ {
if (Session["CurrUser"] == null && !Request.Path.Contains("/Login.aspx") && !Request.Path.Contains("DataShow")) if (Session["CurrUser"] == null && !Request.Path.Contains("/Login.aspx") && !Request.Path.Contains("DataShow"))
{ {
string ticket = Request.Params["ticket"]; //string ticket = Request.Params["ticket"];
if (!string.IsNullOrEmpty(ticket)) //if (!string.IsNullOrEmpty(ticket))
{
string jsonCameras = APIGetHttpService.Http("https://cas.china-tcc.com/cas/serviceValidate?service=https://tccsg.cntcc.cn:17001/sggl/indexProject.aspx&ticket=" + ticket);
XmlDocument xml = new XmlDocument();
xml.LoadXml(jsonCameras);
XmlElement root = xml.DocumentElement;
XmlNode node = root.ChildNodes[0];//遍历输出.
if (node.LocalName == "authenticationSuccess")
{
string user = node.ChildNodes[0].InnerText;//InnerText节点包合的所有文本内容
//if ("zyk" == user)
//{ //{
// user = "hfnbd"; // string jsonCameras = APIGetHttpService.Http("https://cas.china-tcc.com/cas/serviceValidate?service=https://tccsg.cntcc.cn:17001/sggl/indexProject.aspx&ticket=" + ticket);
//}
Model.Sys_User sysUser = (from y in Funs.DB.Sys_User
where (y.DomainAccount == user || y.Account ==user) && y.IsPost == true
select y).FirstOrDefault();
if (user != null)
{
string accValue = HttpUtility.UrlEncode(user);
FormsAuthentication.SetAuthCookie(accValue, false);
Page.Session[SessionName.CurrUser] = sysUser;
string url = "";
this.CurrUser.RoleType = RoleService.GetRoleTypeByRoleId(this.CurrUser.RoleId);
if (!this.CurrUser.LastIsOffice.HasValue)
{
this.CurrUser.LastIsOffice = this.CurrUser.IsOffice;
}
if (this.CurrUser.LastIsOffice == true)
{
this.CurrUser.LoginProjectId = null;
////本部菜单
url = "index.aspx";
}
else
{
this.CurrUser.LoginProjectId = this.CurrUser.LastProjectId;
//// 项目菜单
url = "indexProject.aspx?projectId=" + this.CurrUser.LastProjectId;
}
this.SysType = "GONGCHENG";
Response.Redirect(url);
}
else
{
Response.Redirect("Login.aspx");
}
}
}
else
{
Response.Redirect("https://cas.china-tcc.com/cas/login?service=https://tccsg.cntcc.cn:17001/sggl/indexProject.aspx");
} // XmlDocument xml = new XmlDocument();
// xml.LoadXml(jsonCameras);
// XmlElement root = xml.DocumentElement;
// XmlNode node = root.ChildNodes[0];//遍历输出.
// if (node.LocalName == "authenticationSuccess")
// {
// string user = node.ChildNodes[0].InnerText;//InnerText节点包合的所有文本内容
// //if ("zyk" == user)
// //{
// // user = "hfnbd";
// //}
// Model.Sys_User sysUser = (from y in Funs.DB.Sys_User
// where (y.DomainAccount == user || y.Account ==user) && y.IsPost == true
// select y).FirstOrDefault();
// if (user != null)
// {
// string accValue = HttpUtility.UrlEncode(user);
// FormsAuthentication.SetAuthCookie(accValue, false);
// Page.Session[SessionName.CurrUser] = sysUser;
// string url = "";
// this.CurrUser.RoleType = RoleService.GetRoleTypeByRoleId(this.CurrUser.RoleId);
// if (!this.CurrUser.LastIsOffice.HasValue)
// {
// this.CurrUser.LastIsOffice = this.CurrUser.IsOffice;
// }
// if (this.CurrUser.LastIsOffice == true)
// {
// this.CurrUser.LoginProjectId = null;
// ////本部菜单
// url = "index.aspx";
// }
// else
// {
// this.CurrUser.LoginProjectId = this.CurrUser.LastProjectId;
// //// 项目菜单
// url = "indexProject.aspx?projectId=" + this.CurrUser.LastProjectId;
// }
// this.SysType = "GONGCHENG";
// Response.Redirect(url);
// }
// else
// {
// Response.Redirect("Login.aspx");
// }
// }
//}
//else
//{
// Response.Redirect("https://cas.china-tcc.com/cas/login?service=https://tccsg.cntcc.cn:17001/sggl/indexProject.aspx");
//}
} }
var pm = PageManager.Instance; var pm = PageManager.Instance;
if (pm != null) if (pm != null)