Esempio n. 1
0
        /// <summary>
        ///
        /// </summary>
        /// <param name="sender"></param>
        /// <param name="e"></param>
        private void AddBtn_Click(object sender, RoutedEventArgs e)
        {
            var window = new TaskEditView();

            window.SetTaskInfo(new TaskInfo(JobInfo, new Task()));

            var result = window.ShowDialog();

            if (result != true)
            {
                return;
            }

            JobInfo.AddTask(window.TaskInfo);
        }
Esempio n. 2
0
        /// <summary>
        ///
        /// </summary>
        /// <param name="sender"></param>
        /// <param name="e"></param>
        private void TaskItemComponent_OnEdit(object sender, TaskInfo e)
        {
            var window = new TaskEditView();

            window.SetTaskInfo(new TaskInfo(e.Source.Clone()));

            var submitResult = window.ShowDialog();

            if (submitResult != true)
            {
                return;
            }

            e.Name            = window.TaskInfo.Name;
            e.TaskLibraryPath = window.TaskInfo.TaskLibraryPath;
            e.TaskClassName   = window.TaskInfo.TaskClassName;
            JobInfo.Update();
        }