Пример #1
0
 /// <summary>
 /// Initializes a new instance of the <see cref="DashboardViewModel" /> class.
 /// </summary>
 /// <param name="parent">The parent.</param>
 /// <param name="board">The board.</param>
 public DashboardViewModel(object parent, Board board)
     : base(parent)
 {
     _board = board;
     Issues = new ObservableCollection<IssueViewModel>();
     _isCustomRoot = true;
 }
Пример #2
0
 /// <summary>
 /// Initializes a new instance of the <see cref="ShowIssueViewModel" /> class.
 /// </summary>
 /// <param name="parent">The parent.</param>
 /// <param name="board">The board.</param>
 public ShowIssueViewModel(INavigatePage parent, Board board)
     : base(parent)
 {
     _board = board;
     Parents = new ObservableCollection<IssueViewModel>();
     Children = new ObservableCollection<IssueViewModel>();
     Attachments = new ObservableCollection<AttachmentViewModel>();
     Links = new ObservableCollection<LinkViewModel>();
     IsActiveChildren = true;
     IsRootChildren = true;
 }
Пример #3
0
 /// <summary>
 /// Initializes a new instance of the <see cref="IssuesViewModel" /> class.
 /// </summary>
 /// <param name="parent">The parent.</param>
 /// <param name="board">The board.</param>
 public IssuesViewModel(object parent, Board board)
     : base(parent)
 {
     _board = board;
     Filter = new FilterViewModel(this);
     PageNumbers = new ObservableCollection<PageNumberViewModel>();
     Issues = new ObservableCollection<IssueViewModel>();
     AllIssues = new ObservableCollection<IssueViewModel>();
     Filter.SetModel(board.GetFullFilter(), board.GetDefaultFilter());
     AsyncSearch();
 }
        public EditIssueViewModelBase(INavigatePage parent, Board board)
            : base(parent)
        {
            _parent = parent;
            _board = board;
            Attachments = new ObservableCollection<AttachmentViewModel>();
            Links = new ObservableCollection<LinkViewModel>();
            FilePaths = new Dictionary<string, string>();
            SubmitHeader = "Submit";

            ParentsViewModel = new EditRelationViewModel();
            ChildrenViewModel = new EditRelationViewModel();

            ParentsViewModel.AddCommand = new DelegateCommand<IssueViewModel>(AddParent, ParentsViewModel.CanAdd);
            ParentsViewModel.RemoveCommand = new DelegateCommand<IssueViewModel>(RemoveParent);
            ParentsViewModel.SearchCommand = new DelegateCommand(ParentSearch);

            ChildrenViewModel.AddCommand = new DelegateCommand<IssueViewModel>(AddChild, ChildrenViewModel.CanAdd);
            ChildrenViewModel.RemoveCommand = new DelegateCommand<IssueViewModel>(RemoveChild);
            ChildrenViewModel.SearchCommand = new DelegateCommand(ChildSearch);
        }
Пример #5
0
 /// <summary>
 /// Initializes a new instance of the <see cref="MainViewModel" /> class.
 /// </summary>
 /// <param name="board">The board.</param>
 public MainViewModel(Board board)
 {
     _board = board;
     Dashboard = new DashboardViewModel(this, board);
     Issues = new IssuesViewModel(this, board);
     Configuration = new ConfigurationViewModel(this, board);
     CreateIssue = new CreateIssueViewModel(this, board);
     EditIssue = new EditIssueViewModel(this, board);
     ShowIssue = new ShowIssueViewModel(this, board);
     _current = Dashboard;
     _backPage = Dashboard;
     _current.IsNavigated = true;
 }
Пример #6
0
 /// <summary>
 /// Initializes a new instance of the <see cref="EditIssueViewModel" /> class.
 /// </summary>
 /// <param name="parent">The parent.</param>
 /// <param name="board">The board.</param>
 public EditIssueViewModel(INavigatePage parent, Board board)
     : base(parent, board)
 {
     SubmitHeader = (string) Application.Current.FindResource("EditHeader");
 }
Пример #7
0
 /// <summary>
 /// Initializes a new instance of the <see cref="EditIssueViewModelBase" /> class.
 /// </summary>
 /// <param name="parent">The parent.</param>
 /// <param name="board">The board.</param>
 public EditIssueViewModelBase(INavigatePage parent, Board board)
     : base(parent)
 {
     _parent = parent;
     _board = board;
     Issues = new ObservableCollection<IssueViewModel>();
     ParentIssues = new ObservableCollection<IssueViewModel>();
     Attachments = new ObservableCollection<AttachmentViewModel>();
     Links = new ObservableCollection<LinkViewModel>();
     FilePaths = new Dictionary<string, string>();
     SubmitHeader = "Submit";
 }
 /// <summary>
 /// Initializes a new instance of the <see cref="ConfigurationViewModel" /> class.
 /// </summary>
 /// <param name="parent">The parent.</param>
 /// <param name="board">The board.</param>
 public ConfigurationViewModel(object parent, Board board)
     : base(parent)
 {
     _board = board;
     ConfigDisplay = new ConfigDisplayViewModel();
 }