示例#1
0
        public void AddMeeting()
        {
            var meeting = new Meeting
            {
                Date = DateTime.Now
            };

            _meetingsManager.AddMeeting(meeting);

            Assert.True(meeting.Id > 0);
        }
示例#2
0
        public IActionResult CreateMeeting([FromBody] Meeting meeting)
        {
            if (!IsAdmin())
            {
                return(Unauthorized());
            }

            _meetingsManager.AddMeeting(meeting);

            return(Json(meeting));
        }