예제 #1
0
        public async Task <Dialog> CreateDialog(User createdBy, User reciever, string message)
        {
            Dialog dialog = new Dialog
            {
                CreatedBy    = createdBy,
                Reciever     = reciever,
                CreatedDate  = DateTimeOffset.Now,
                LastActivity = DateTimeOffset.Now,
                LastMessage  = message
            };
            await _chatRepo.AddDialog(dialog);

            return(dialog);
        }