public void CommitEvent(object key) { PTStopMsg byId = new PTStopMsgService().GetById(key.ToString()); if (byId != null) { ProjectInfo.UpdatePrjState(byId.PrjGuid, "8"); } }
protected void BindProject() { ProjectInfo byId = ProjectInfo.GetById(this.prjId); this.txtPrjName.Text = byId.PrjName; this.hfldPrjGuid.Value = this.prjId; PTStopMsgService source = new PTStopMsgService(); PTStopMsg pTStopMsg = ( from stop in source where stop.PrjGuid == this.prjId select stop into list orderby list.InputDate descending select list).FirstOrDefault <PTStopMsg>(); if (pTStopMsg != null) { this.hfldStopMsgId.Value = pTStopMsg.StopMsgId; } }