예제 #1
0
        private void Button_Click_1(object sender, RoutedEventArgs e)
        {
            MeetingViewModel m = new MeetingViewModel();
            m.TxtTitle = txtTitle.Text;
            m.TxtDescription = txtDescription.Text;
            TimeSpan starTime = ((DateTime)tpStarTime.Value).TimeOfDay;
            TimeSpan endTime = ((DateTime)tpEndTime.Value).TimeOfDay;
            m.TxtStarMeetingtDate = ((DateTime)dpstarMeetingTime.SelectedDate).Add(starTime).ToString();
            m.TxtEndMeetingDate = ((DateTime)dpEndMeetingTime.SelectedDate).Add(endTime).ToString();

            m.TxtMeetingTypeId = cbMeetingType.SelectedIndex.ToString();

            m.CreateEvent();

            this.Content = new MainView();
        }
예제 #2
0
        private void btnSave_Click(object sender, RoutedEventArgs e)
        {
            MeetingViewModel meetingViewModel = new MeetingViewModel();
            AssistControlModel ac = new AssistControlModel
            {
                PastorId = churchModel.Pastor.ID,
                CheckInTime = DateTime.Now,
                DepartTime = null,
                Comment = "",
                ObservationId = 1,
                MeetingId =MeetingId

            };

            meetingViewModel.LogAssistControl(ac);
        }