示例#1
0
        public string SetStatusTrRed()
        {
            var cTicket = _ticketBs.GetCronTicketSetRed();

            if (cTicket.Count != 0)
            {
                foreach (Ticket item in cTicket)
                {
                    if (item.NextCommenter == item.Responder)
                    {
                        //set red flag responder
                        item.ResponderFlag = 1;
                    }
                    else
                    {
                        //set red flag submiter
                        item.SubmiterFlag = 1;
                    }
                    _ticketBs.Edit(item);

                    //send email
                    if (WebConfigure.GetSendEmail())
                    {
                        Email.SendMailFlagRed(item.NextCommenter);
                    }
                }
                return("Flag Updated");
            }
            return("Already Updated");
        }