public AddAutoApprovalViewModel(
            IList <Entities.DocType> docTypes, IList <Entities.SubDocType> subDocTypes, IList <Entities.ManCo> manCos)
        {
            DocTypesViewModel    = new DocTypesViewModel();
            SubDocTypesViewModel = new SubDocTypesViewModel(docTypes);
            ManCosViewModel      = new ManCosViewModel();

            DocTypesViewModel.AddDocTypes(docTypes);
            SubDocTypesViewModel.AddSubDocTypes(subDocTypes);
            ManCosViewModel.AddMancos(manCos);
        }
        public AddAutoApprovalViewModel(
            IList <Entities.DocType> docTypes, IList <Entities.SubDocType> subDocTypes, int manCoId)
        {
            DocTypesViewModel    = new DocTypesViewModel();
            SubDocTypesViewModel = new SubDocTypesViewModel(docTypes);
            ManCosViewModel      = new ManCosViewModel();

            DocTypesViewModel.AddDocTypes(docTypes);
            SubDocTypesViewModel.AddSubDocTypes(subDocTypes);
            ManCoId = manCoId;
        }
예제 #3
0
        public ActionResult Index()
        {
            var subDocTypes = _subDocTypeService.GetSubDocTypes();
            var docTypes    = _docTypeService.GetDocTypes();

            var subDocTypesViewModel = new SubDocTypesViewModel(docTypes);

            subDocTypesViewModel.AddSubDocTypes(subDocTypes);

            return(View(subDocTypesViewModel));
        }