Esempio n. 1
0
        public ActionResult AddNew()
        {
            var entity = CreateEmptyEntityOrGetFromTempData(TempDataKey_OrganizationController_Copy);

            Framework.UIAction uiAction = Framework.UIAction.Create;
            MSBuildExtensionPack.AspNetMvc40ViewModel.OrganizationItemVM vm = MSBuildExtensionPack.AspNetMvc40ViewModel.OrganizationItemVM.CreateNewViewModel(entity);
            vm.LoadExtraData(uiAction);

            return(View(vm));
        }
Esempio n. 2
0
        public static OrganizationItemVM CreateNewViewModel(MSBuildExtensionPack.DataSourceEntities.Organization.Default entity)
        {
            Framework.UIAction uiAction = Framework.UIAction.Create;
            OrganizationItemVM vm       = new OrganizationItemVM();

            vm.ContentData.Title   = Framework.Resx.UIStringResource.AddNew;
            vm.ContentData.Summary = MSBuildExtensionPack.Resx.UIStringResourcePerEntityOrganization.AddNew_Organization;
            vm.LoadExtraData(uiAction);

            vm.Item = entity;
            vm.UIActionStatusMessage = new Framework.UIActionStatusMessage(typeof(OrganizationItemVM).FullName, uiAction.ToString(), uiAction, Framework.UIActionStatus.Launch);

            return(vm);
        }