This commit is contained in:
高飞 2026-04-15 17:55:00 +08:00
parent b279647643
commit b78ce144a2
3 changed files with 10 additions and 8 deletions

View File

@ -17,8 +17,8 @@ namespace BLL
using (Model.SGGLDB db = new Model.SGGLDB(Funs.ConnString))
{
var getUser = db.Person_Persons.FirstOrDefault(x => (x.Account == userInfo.Account || x.Telephone == userInfo.Telephone || x.PersonName == userInfo.Account)
&& x.Password == Funs.EncryptionPassword(userInfo.Password) && (!x.IsPost.HasValue || x.IsPost == true)
&& (x.Account.Length > 1 || x.PersonId == Const.hfnbdId || x.PersonId == Const.sysglyId));
&& x.Password == Funs.EncryptionPassword(userInfo.Password) && (!x.IsPost.HasValue || x.IsPost == true));
/*&& (x.Account.Length > 1 || x.PersonId == Const.hfnbdId || x.PersonId == Const.sysglyId))*/
if (getUser != null)
{
Model.UserItem newItem = new Model.UserItem();

View File

@ -155,6 +155,8 @@
</f:RenderField>
<f:RenderField Hidden="true" Width="1px" HeaderText="培训次数" ColumnID="TrainCount1" DataField="TrainCount1">
</f:RenderField>
<f:RenderField Hidden="true" Width="1px" HeaderText="培训次数" ColumnID="TrainCount1" DataField="TrainCount2">
</f:RenderField>
</Columns>
<Listeners>
<f:Listener Event="beforerowcontextmenu" Handler="onRowContextMenu" />

View File

@ -244,7 +244,7 @@ Where ProjectId=@ProjectId ";
}
if (this.ckTrain.Checked)
{
strSql += " AND ((TrainCount =0 AND TrainCount1 =0) || TrainCount2=0)";
strSql += " AND (TrainCount =0 AND TrainCount1 =0 AND TrainCount2=0)";
}
if (this.ckIsUsed.Checked)
{
@ -272,8 +272,8 @@ Where ProjectId=@ProjectId ";
// string personId = Grid1.Rows[i].DataKeys[0].ToString();
var tCount = Grid1.Rows[i].Values[8].ToString();
var tCount1 = Grid1.Rows[i].Values[9].ToString();
if (tCount == "0" && tCount1 == "0") ////未参加过培训的人员
var tCount2 = Grid1.Rows[i].Values[10].ToString();
if (tCount == "0" && tCount1 == "0" && tCount2 == "0") ////未参加过培训的人员
{
Grid1.Rows[i].RowCssClass = "Red";
}
@ -731,7 +731,7 @@ Where ProjectId=@ProjectId ";
var getSitePerson = SitePerson_PersonService.GetSitePersonById(Grid1.SelectedRowID);
if (getSitePerson != null)
{
PageContext.RegisterStartupScript(Window1.GetShowReference(String.Format("../../Person/ProjectPersonView.aspx?SitePersonId={0}", this.SitePersonId, "查看 - ")));
PageContext.RegisterStartupScript(Window1.GetShowReference(String.Format("../../Person/ProjectPersonView.aspx?SitePersonId={0}", getSitePerson.SitePersonId, "查看 - ")));
}
}
@ -748,7 +748,7 @@ Where ProjectId=@ProjectId ";
foreach (int rowIndex in Grid1.SelectedRowIndexArray)
{
string rowID = Grid1.DataKeys[rowIndex][0].ToString();
var sitePerson = Funs.DB.SitePerson_Person.FirstOrDefault(x => x.SitePersonId == rowID);
var sitePerson = Funs.DB.SitePerson_Person.FirstOrDefault(x => x.SitePersonId == rowID);
var person = Funs.DB.Person_Persons.FirstOrDefault(x => x.IdentityCard == sitePerson.IdentityCard);
if (!string.IsNullOrEmpty(person.PhotoUrl))
{
@ -772,7 +772,7 @@ Where ProjectId=@ProjectId ";
protected void btnUpToYunMou_Click(object sender, EventArgs e)
{
var sitePerson = Funs.DB.SitePerson_Person.FirstOrDefault(x => x.SitePersonId == Grid1.SelectedRowID);
var person = Funs.DB.Person_Persons.FirstOrDefault(x => x.IdentityCard == sitePerson.IdentityCard);
var person = Funs.DB.Person_Persons.FirstOrDefault(x => x.IdentityCard == sitePerson.IdentityCard);
var token = YunMouHelper.getToken();
var res3 = YunMouHelper.updatePerson(person.IdentityCard, person.PersonName, string.IsNullOrEmpty(person.Telephone) ? "" : person.Telephone, person.PhotoUrl, token);
}