Beispiel #1
0
        /// <summary>
        /// 操作信息
        /// </summary>
        /// <returns></returns>
        protected void OperationInfo(string adviceID)
        {
            try
            {
                AdviceReply adviceReply = new AdviceReply();
                adviceReply.AdviceID = adviceID;
                adviceReply.Content  = ReplayContent.InnerHtml;
                adviceReply.UserID   = AccountID;
                adviceReply.Title    = EmailTitleLabel.Text;
                adviceReply.MailBody = InfoRawManage.InnerText;
                AdviceReplyHelper.AddAdviceReply(adviceReply);
                AdviceHelper.UpdateAdviceType(adviceID, (int)AdviceState.Finished);

                Advice a = AdviceHelper.GetAdvice(adviceID);
                if (a.State == (int)AdviceState.Checking)
                {
                    AdviceHelper.UpdateAdviceProcess(adviceID, "1", AdviceState.Checking);
                    Processing ap = ProcessHelper.CreateAdviceProcess(adviceID, AccountID);
                    ProcessHelper.UpdateAdviceProcess(ap, a);
                    InsertArticleProcessHistory(adviceID);
                }
                else if (a.State == (int)AdviceState.Checking && a.ProcessState == ((int)ProcessStates.Unaudit).ToString())
                {
                    AdviceHelper.UpdateAdviceProcess(adviceID, ((int)ProcessStates.FirstAudit).ToString(), AdviceState.Checking);
                    Processing ap = ProcessHelper.GetAdviceProcess(a);
                    ap.CurLayerNO       = "1";
                    ap.ProcessAccountID = AccountID;
                    ap.ProcessDirection = "1";
                    ap.Remark           = ReplayContent.InnerText;
                    ProcessHelper.UpdateAdviceProcess(ap, a);
                    InsertArticleProcessHistory(adviceID);
                }
            }
            catch (Exception)
            {
                Messages.ShowMessage(" :( 信息操作失败!");
            }
        }