Exemple #1
0
        public SwitcherViewModel(IScreen screen)
        {
            this.Log(false);

            HostScreen = screen;

            LeftViewModel  = new LeftViewModel(screen);
            RightViewModel = new RightViewModel(screen);
        }
Exemple #2
0
        public PartialViewResult Left(string currentPageName = "", int menuId = 0)
        {
            //左边导航菜单
            var leftModel = new LeftViewModel();

            leftModel.Menu            = _menuAppService.GetMenusByParentId(menuId);
            leftModel.CurrentPageName = currentPageName;
            return(PartialView("~/Views/Layout/_Left.cshtml", leftModel));
        }
Exemple #3
0
        public PartialViewResult Left(string currentPageName = "", int menuId = 0)
        {
            //左边导航菜单
            var         leftModel = new LeftViewModel();
            MenuListDto m         = _menuAppService.GetMenuById(new EntityDto <long> {
                Id = menuId
            });

            leftModel.MenuParentName  = m.MenuName;
            leftModel.Menu            = _menuAppService.GetMenusByParentId(menuId);
            leftModel.CurrentPageName = currentPageName;
            return(PartialView("~/Areas/Admin/Views/Layout/_Left.cshtml", leftModel));
        }
Exemple #4
0
 public MainViewModel()
 {
     Caption        = "MainViewModel";
     RightViewModel = new RightViewModel()
     {
         Caption = "RightViewModel"
     };
     ((ISupportParentViewModel)RightViewModel).ParentViewModel = this;
     LeftViewModel = new LeftViewModel()
     {
         Caption = "LeftViewModel"
     };
     ((ISupportParentViewModel)LeftViewModel).ParentViewModel = this;
     SplashScreenViewModel = new SplashScreenViewModel()
     {
         Caption = "SplashScreenViewModel"
     };
     ((ISupportParentViewModel)SplashScreenViewModel).ParentViewModel = this;
 }
 public ShellViewModel(LeftViewModel leftModel)
 {
Exemple #6
0
 /// <summary>
 /// Creates an instance of the object to test.
 /// To allow Ninja automatically create the unit tests
 /// this method should not be changed.
 /// </summary>
 public override void CreateTestableObject()
 {
     this.leftViewModel = new LeftViewModel();
 }
 public ShellViewModel(LeftViewModel left, RightViewModel right) {
     Left = left;
     Right = right;
 }