Exemplo n.º 1
0
 //草稿箱
 public ActionResult Draft()
 {
     var user = Session["CurrentUser"] as UserAndRole;
     MessageListViewModel DraftView = new MessageListViewModel();
     DraftView.MessageList = GetHaveSentList(user.UserId, "Draft");
     return View(DraftView);
 }
Exemplo n.º 2
0
 //草稿箱消息详细
 public ActionResult DraftDetail(string ID)
 {
     var user = Session["CurrentUser"] as UserAndRole;
     MessageListViewModel DraftDetailView = new MessageListViewModel();
     DraftDetailView.MessageNo = ID;
     var MessageDetail = _ServicesSoapClient.GetMessageDetail(ID);
     if (MessageDetail != null)
     {
         DraftDetailView.Receiver = MessageDetail.RecieverName + "<" + MessageDetail.Reciever + ">;" + " ";
         DraftDetailView.Title = MessageDetail.Title;
         DraftDetailView.Content = MessageDetail.Content;
     }
     DraftDetailView.UserId = user.UserId;
     DraftDetailView.ModuleInfoList = GetModuleInfo();
     DraftDetailView.ContactsList = GetContactsById(DraftDetailView.UserId, DraftDetailView.ModuleInfoList);
     return View(DraftDetailView);
 }
Exemplo n.º 3
0
 //写信
 public ActionResult Write(MessageInfo Rei)
 {
     try
     {
         var user = Session["CurrentUser"] as UserAndRole;
         MessageListViewModel WriteView = new MessageListViewModel();
         if (Rei.SendByName != null)
         {
             WriteView.Receiver = Rei.SendByName + ";" + " ";
         }
         WriteView.UserId = user.UserId;
         WriteView.ModuleInfoList = GetModuleInfo();
         WriteView.ContactsList = GetContactsById(WriteView.UserId, WriteView.ModuleInfoList);
         return View(WriteView);
     }
     catch (Exception ex)
     {
         throw ex;
     }
 }
Exemplo n.º 4
0
 public ActionResult FastWriteFromPat(string SendBy)
 {
     try
     {
         var user = Session["CurrentUser"] as UserAndRole;
         MessageListViewModel WriteView = new MessageListViewModel();
         WriteView.UserId = user.UserId;
         WriteView.UserName = user.UserName;
         WriteView.ServerIP = _ServicesSoapClient.getLocalmachineIPAddress();//ServerIP
         WriteView.ModuleInfoList = GetModuleInfo();
         WriteView.ContactsList = GetContactsById(WriteView.UserId, WriteView.ModuleInfoList);
         return View(WriteView);
     }
     catch (Exception ex)
     {
         throw ex;
     }
 }
Exemplo n.º 5
0
 //收信
 public ActionResult Receive()
 {
     var user = Session["CurrentUser"] as UserAndRole;
     MessageListViewModel ReceiveView = new MessageListViewModel();
     ReceiveView.MessageList = GetReceiveList(user.UserId);
     return View(ReceiveView);
 }