public PriorityLandscapesViewData(Person currentPerson, Models.Project project, ProposalSectionsStatus proposalSectionsStatus, EditProjectPriorityLandscapesViewData editProjectPriorityLandscapesViewData) : base(currentPerson, project, ProjectCreateSection.PriorityLandscapes.ProjectCreateSectionDisplayName, proposalSectionsStatus) { EditProjectPriorityLandscapesViewData = editProjectPriorityLandscapesViewData; }
public DNRUplandRegionsViewData(Person currentPerson, Models.Project project, ProposalSectionsStatus proposalSectionsStatus, EditProjectRegionsViewData editProjectRegionsViewData) : base(currentPerson, project, ProjectCreateSection.DNRUplandRegions.ProjectCreateSectionDisplayName, proposalSectionsStatus) { EditProjectRegionsViewData = editProjectRegionsViewData; }
public LocationSimpleViewData(Person currentPerson, Models.Project project, ProposalSectionsStatus proposalSectionsStatus, ProjectLocationSimpleViewData projectLocationSimpleViewData) : base(currentPerson, project, ProjectCreateSection.LocationSimple.ProjectCreateSectionDisplayName, proposalSectionsStatus) { ProjectLocationSimpleViewData = projectLocationSimpleViewData; }
public ExpectedPerformanceMeasureValuesViewData(Person currentPerson, Models.Project project, ProposalSectionsStatus proposalSectionsStatus, EditPerformanceMeasureExpectedViewData editPerformanceMeasureExpectedViewData) : base(currentPerson, project, ProjectCreateSection.ExpectedPerformanceMeasures.ProjectCreateSectionDisplayName, proposalSectionsStatus) { EditPerformanceMeasureExpectedViewData = editPerformanceMeasureExpectedViewData; }
public DocumentsAndNotesViewData(Person currentPerson, Models.Project project, ProposalSectionsStatus proposalSectionsStatus, EntityNotesViewData entityNotesViewData, ProjectDocumentsDetailViewData projectDocumentsDetailViewData) : base(currentPerson, project, ProjectCreateSection.NotesAndDocuments.ProjectCreateSectionDisplayName, proposalSectionsStatus) { EntityNotesViewData = entityNotesViewData; ProjectDocumentsDetailViewData = projectDocumentsDetailViewData; }
public GeospatialAreaViewData(FirmaSession currentFirmaSession, ProjectFirmaModels.Models.Project project, GeospatialAreaType geospatialAreaType, ProposalSectionsStatus proposalSectionsStatus, EditProjectGeospatialAreasViewData editProjectGeospatialAreasViewData) : base(currentFirmaSession, project, geospatialAreaType.GeospatialAreaTypeNamePluralized, proposalSectionsStatus) { EditProjectGeospatialAreasViewData = editProjectGeospatialAreasViewData; }
public ProjectCustomAttributesViewData(FirmaSession currentFirmaSession, ProjectFirmaModels.Models.Project project, ProposalSectionsStatus proposalSectionsStatus, EditProjectCustomAttributesViewData editCustomAttributesViewData, ProjectCustomAttributesValidationResult projectCustomAttributesValidationResult) : base(currentFirmaSession, project, ProjectCreateSection.CustomAttributes.ProjectCreateSectionDisplayName, proposalSectionsStatus) { EditCustomAttributesViewData = editCustomAttributesViewData; ShowCommentsSection = project.IsPendingApproval() || (project.CustomAttributesComment != null && project.ProjectApprovalStatus == ProjectApprovalStatus.Returned); CanEditComments = project.IsPendingApproval() && new ProjectEditAsAdminRegardlessOfStageFeature().HasPermission(currentFirmaSession, project).HasPermission; }
public CustomAttributesViewData(Person currentPerson, Models.Project project, ProposalSectionsStatus proposalSectionsStatus, IEnumerable <Models.ProjectCustomAttributeType> projectCustomAttributeTypes) : base(currentPerson, project, ProjectCreateSection.ProjectAttributes.ProjectCreateSectionDisplayName, proposalSectionsStatus) { ShowProjectStageDropDown = project.ProjectStage != ProjectStage.Proposed; ProjectDisplayName = project.DisplayName; AssignParameters(projectCustomAttributeTypes); }
public LocationSimpleViewData(FirmaSession currentFirmaSession, ProjectFirmaModels.Models.Project project, ProposalSectionsStatus proposalSectionsStatus, ProjectLocationSimpleViewData projectLocationSimpleViewData) : base(currentFirmaSession, project, ProjectCreateSection.LocationSimple.ProjectCreateSectionDisplayName, proposalSectionsStatus) { ProjectLocationSimpleViewData = projectLocationSimpleViewData; ShowCommentsSection = project.IsPendingApproval() || (project.BasicsComment != null && project.ProjectApprovalStatus == ProjectApprovalStatus.Returned); CanEditComments = project.IsPendingApproval() && new ProjectEditAsAdminRegardlessOfStageFeature().HasPermission(currentFirmaSession, project).HasPermission; }
public ExpectedFundingViewData(Person currentPerson, Models.Project project, ProposalSectionsStatus proposalSectionsStatus, ViewDataForAngularClass viewDataForAngularClass) : base(currentPerson, project, ProjectCreateSection.ExpectedFunding.ProjectCreateSectionDisplayName, proposalSectionsStatus) { ViewDataForAngular = viewDataForAngularClass; RequestGrantAllocationUrl = SitkaRoute <HelpController> .BuildUrlFromExpression(x => x.MissingGrantAllocation()); FundingSources = FundingSource.All.ToSelectList(x => x.FundingSourceID.ToString(), y => y.FundingSourceDisplayName).ToList(); }
protected ProjectCreateViewData(FirmaSession currentFirmaSession, ProjectFirmaModels.Models.Project project, string currentSectionDisplayName, ProposalSectionsStatus proposalSectionsStatus) : this(currentFirmaSession, project, currentSectionDisplayName, false) { Check.Assert(project != null, "Project should be created in database by this point so it cannot be null."); Check.Assert(currentSectionDisplayName.Equals("Instructions", StringComparison.InvariantCultureIgnoreCase) || currentSectionDisplayName.Equals("Basics", StringComparison.InvariantCultureIgnoreCase) || proposalSectionsStatus.IsBasicsSectionComplete, $"Can't access this section of the Proposal - You must complete the basics first ({project.GetEditUrl()})"); CurrentPersonCanWithdraw = new ProjectCreateFeature().HasPermission(currentFirmaSession, project).HasPermission; Project = project; ProposalSectionsStatus = proposalSectionsStatus; CanAdvanceStage = ProposalSectionsStatus.AreAllSectionsValidForProject(project, CurrentFirmaSession); // ReSharper disable PossibleNullReferenceException ProjectStateIsValidInWizard = project.ProjectApprovalStatus == ProjectApprovalStatus.Draft || project.ProjectApprovalStatus == ProjectApprovalStatus.Returned || project.ProjectApprovalStatus == ProjectApprovalStatus.PendingApproval; // ReSharper restore PossibleNullReferenceException IsInstructionsPage = currentSectionDisplayName.Equals("Instructions", StringComparison.InvariantCultureIgnoreCase); InstructionsPageUrl = project.ProjectStage == ProjectStage.Proposal ? SitkaRoute <ProjectCreateController> .BuildUrlFromExpression(x => x.InstructionsProposal(project.ProjectID)) : SitkaRoute <ProjectCreateController> .BuildUrlFromExpression(x => x.InstructionsEnterHistoric(project.ProjectID)); var fieldDefinitionLabelForProject = FieldDefinitionEnum.Project.ToType().GetFieldDefinitionLabel(); var pageTitle = project.ProjectStage == ProjectStage.Proposal ? $"Propose {fieldDefinitionLabelForProject}" : $"Add {fieldDefinitionLabelForProject}"; PageTitle = $"{pageTitle}: {project.GetDisplayName()}"; ProposalDetailUrl = SitkaRoute <ProjectController> .BuildUrlFromExpression(x => x.Detail(project)); ProposalBasicsUrl = SitkaRoute <ProjectCreateController> .BuildUrlFromExpression(x => x.EditBasics(project.ProjectID)); ProposalAttachmentsAndNotesUrl = SitkaRoute <ProjectCreateController> .BuildUrlFromExpression(x => x.AttachmentsAndNotes(project.ProjectID)); ProposalPhotosUrl = SitkaRoute <ProjectCreateController> .BuildUrlFromExpression(x => x.Photos(project.ProjectID)); SubmitUrl = SitkaRoute <ProjectCreateController> .BuildUrlFromExpression(x => x.Submit(project)); ApproveUrl = SitkaRoute <ProjectCreateController> .BuildUrlFromExpression(x => x.Approve(project)); ReturnUrl = SitkaRoute <ProjectCreateController> .BuildUrlFromExpression(x => x.Return(project)); WithdrawUrl = SitkaRoute <ProjectCreateController> .BuildUrlFromExpression(x => x.Withdraw(project)); RejectUrl = SitkaRoute <ProjectCreateController> .BuildUrlFromExpression(x => x.Reject(project)); TrainingUrl = SitkaRoute <HomeController> .BuildUrlFromExpression(x => x.Training()); ProjectStage = project.ProjectStage; HasCustomAttributesEditableByUser = project.HasEditableCustomAttributes(currentFirmaSession); }
public BulkSetSpatialInformationViewData(FirmaSession currentFirmaSession, ProjectFirmaModels.Models.Project project, ProposalSectionsStatus proposalSectionStatus, BulkSetProjectSpatialInformationViewData quickSetViewData) : base(currentFirmaSession, project, ProjectCreateSection.BulkSetSpatialInformation.ProjectCreateSectionDisplayName, proposalSectionStatus) { BulkSetProjectSpatialInformationViewData = quickSetViewData; }
public ExpectedPerformanceMeasureValuesViewData(FirmaSession currentFirmaSession, ProjectFirmaModels.Models.Project project, ProposalSectionsStatus proposalSectionsStatus, EditPerformanceMeasureExpectedViewData editPerformanceMeasureExpectedViewData) : base(currentFirmaSession, project, ProjectCreateSection.ExpectedAccomplishments.ProjectCreateSectionDisplayName, proposalSectionsStatus) { EditPerformanceMeasureExpectedViewData = editPerformanceMeasureExpectedViewData; ShowCommentsSection = project.IsPendingApproval() || (project.BasicsComment != null && project.ProjectApprovalStatus == ProjectApprovalStatus.Returned); CanEditComments = project.IsPendingApproval() && new ProjectEditAsAdminRegardlessOfStageFeature().HasPermission(currentFirmaSession, project).HasPermission; }
public BasicsViewData(Person currentPerson, Models.Project project, ProposalSectionsStatus proposalSectionsStatus, IEnumerable <Models.ProjectType> projectTypes) : base(currentPerson, project, ProjectCreateSection.Basics.ProjectCreateSectionDisplayName, proposalSectionsStatus) { ShowProjectStageDropDown = project.ProjectStage != ProjectStage.Proposed; ProjectDisplayName = project.DisplayName; AssignParameters(projectTypes); ProjectTypeHasBeenSet = project?.ProjectType != null; }
public PartnerFinderProjectCreateViewData(FirmaSession currentFirmaSession, ProjectFirmaModels.Models.Project project, ProposalSectionsStatus proposalSectionStatus ) : base(currentFirmaSession, project, ProjectCreateSection.PartnerFinder.ProjectCreateSectionDisplayName, proposalSectionStatus) { // Our component's view data ProjectPotentialPartnerDetailViewData = new ProjectPotentialPartnerDetailViewData(CurrentFirmaSession, project, ProjectPotentialPartnerListDisplayMode.ProjectDetailViewPartialList); }
public AttachmentsAndNotesViewData(FirmaSession currentFirmaSession, ProjectFirmaModels.Models.Project project, ProposalSectionsStatus proposalSectionsStatus, EntityNotesViewData entityNotesViewData, ProjectAttachmentsDetailViewData projectAttachmentsDetailViewData) : base(currentFirmaSession, project, ProjectCreateSection.AttachmentsAndNotes.ProjectCreateSectionDisplayName, proposalSectionsStatus) { EntityNotesViewData = entityNotesViewData; ProjectAttachmentsDetailViewData = projectAttachmentsDetailViewData; ShowCommentsSection = project.IsPendingApproval() || (project.ContactsComment != null && project.ProjectApprovalStatus == ProjectApprovalStatus.Returned); CanEditComments = project.IsPendingApproval() && new ProjectEditAsAdminRegardlessOfStageFeature().HasPermission(currentFirmaSession, project).HasPermission; }
public ExpectedFundingViewData(FirmaSession currentFirmaSession, ProjectFirmaModels.Models.Project project, ProposalSectionsStatus proposalSectionsStatus, ViewDataForAngularClass viewDataForAngularClass ) : base(currentFirmaSession, project, ProjectCreateSection.Budget.ProjectCreateSectionDisplayName, proposalSectionsStatus) { RequestFundingSourceUrl = SitkaRoute <HelpController> .BuildUrlFromExpression(x => x.MissingFundingSource()); ViewDataForAngular = viewDataForAngularClass; ShowCommentsSection = project.IsPendingApproval() || (project.BudgetComment != null && project.ProjectApprovalStatus == ProjectApprovalStatus.Returned); CanEditComments = project.IsPendingApproval() && new ProjectEditAsAdminRegardlessOfStageFeature().HasPermission(currentFirmaSession, project).HasPermission; }
protected ProjectCreateViewData(Person currentPerson, Models.Project project, string currentSectionDisplayName, ProposalSectionsStatus proposalSectionsStatus) : this(project, currentPerson, currentSectionDisplayName) { IsInstructionsPage = currentSectionDisplayName.Equals("Instructions", StringComparison.InvariantCultureIgnoreCase); bool isBasicsPage = currentSectionDisplayName.Equals("Basics", StringComparison.InvariantCultureIgnoreCase); Check.Assert(project != null, "Project should be created in database by this point so it cannot be null."); // SLG- See Story #1506 - Causing us much grief, perhaps the disease is really better than this cure? We know the Project record exists, is that maybe enough? // This whole expression seems like it had multiple errors in it, giving up on it for now, I don't understand what it is trying to do. // We can't get it to crash once this is removed, so, to heck with it for now. //Check.Assert(IsInstructionsPage || isBasicsPage || proposalSectionsStatus.IsBasicsSectionComplete, $"Can't access this section of the Proposal - You must complete the basics first ({project.GetEditUrl()})"); CurrentPersonCanWithdraw = new ProjectCreateFeature().HasPermission(currentPerson, project).HasPermission; Project = project; ProjectStage = project.ProjectStage; ProposalSectionsStatus = proposalSectionsStatus; CanAdvanceStage = ProposalSectionsStatus.AreAllSectionsValidForProject(project); // ReSharper disable PossibleNullReferenceException ProjectStateIsValidInWizard = project.ProjectApprovalStatus == ProjectApprovalStatus.Draft || project.ProjectApprovalStatus == ProjectApprovalStatus.Returned || project.ProjectApprovalStatus == ProjectApprovalStatus.PendingApproval; InstructionsPageUrl = project.ProjectStage == ProjectStage.Proposed ? SitkaRoute <ProjectCreateController> .BuildUrlFromExpression(x => x.InstructionsProposal(project.ProjectID)) : SitkaRoute <ProjectCreateController> .BuildUrlFromExpression(x => x.InstructionsEnterHistoric(project.ProjectID)); var pagetitle = project.ProjectStage == ProjectStage.Proposed ? $"{Models.FieldDefinition.Application.GetFieldDefinitionLabel()}" : $"Add {Models.FieldDefinition.Project.GetFieldDefinitionLabel()}"; PageTitle = $"{pagetitle}: {project.DisplayName}"; ProposalDetailUrl = SitkaRoute <ProjectController> .BuildUrlFromExpression(x => x.Detail(project)); ProposalBasicsUrl = SitkaRoute <ProjectCreateController> .BuildUrlFromExpression(x => x.EditBasics(project.ProjectID)); ProposalNotesUrl = SitkaRoute <ProjectCreateController> .BuildUrlFromExpression(x => x.DocumentsAndNotes(project.ProjectID)); ProposalPhotosUrl = SitkaRoute <ProjectCreateController> .BuildUrlFromExpression(x => x.Photos(project.ProjectID)); SubmitUrl = SitkaRoute <ProjectCreateController> .BuildUrlFromExpression(x => x.Submit(project)); ApproveUrl = SitkaRoute <ProjectCreateController> .BuildUrlFromExpression(x => x.Approve(project)); ReturnUrl = SitkaRoute <ProjectCreateController> .BuildUrlFromExpression(x => x.Return(project)); WithdrawUrl = SitkaRoute <ProjectCreateController> .BuildUrlFromExpression(x => x.Withdraw(project)); RejectUrl = SitkaRoute <ProjectCreateController> .BuildUrlFromExpression(x => x.Reject(project)); }
public BasicsViewData(FirmaSession currentFirmaSession, ProjectFirmaModels.Models.Project project, ProposalSectionsStatus proposalSectionsStatus, IEnumerable <ProjectFirmaModels.Models.TaxonomyLeaf> taxonomyLeafs, IEnumerable <FundingType> fundingTypes, TenantAttribute tenantAttribute) : base(currentFirmaSession, project, ProjectCreateSection.Basics.ProjectCreateSectionDisplayName, proposalSectionsStatus) { ShowCommentsSection = project.IsPendingApproval() || (project.BasicsComment != null && project.ProjectApprovalStatus == ProjectApprovalStatus.Returned); CanEditComments = project.IsPendingApproval() && new ProjectEditAsAdminRegardlessOfStageFeature().HasPermission(currentFirmaSession, project).HasPermission; ShowProjectStageDropDown = project.ProjectStage != ProjectStage.Proposal; ProjectDisplayName = project.GetDisplayName(); AssignParameters(taxonomyLeafs, fundingTypes, tenantAttribute); }
public ExpendituresViewData(FirmaSession currentFirmaSession, ProjectFirmaModels.Models.Project project, ViewDataForAngularClass viewDataForAngularClass, ProposalSectionsStatus proposalSectionsStatus) : base(currentFirmaSession, project, "OBSOLETE Reported Expenditures", proposalSectionsStatus) //: base(currentFirmaSession, project, ProjectCreateSection.ReportedExpenditures.ProjectCreateSectionDisplayName, proposalSectionsStatus) { ProjectID = project.ProjectID; ViewDataForAngular = viewDataForAngularClass; RefreshUrl = SitkaRoute <ProjectUpdateController> .BuildUrlFromExpression(x => x.RefreshExpenditures(project)); DiffUrl = SitkaRoute <ProjectUpdateController> .BuildUrlFromExpression(x => x.DiffExpenditures(project)); RequestFundingSourceUrl = SitkaRoute <HelpController> .BuildUrlFromExpression(x => x.MissingFundingSource()); ShowCommentsSection = project.IsPendingApproval() || (project.ExpendituresComment != null && project.ProjectApprovalStatus == ProjectApprovalStatus.Returned); CanEditComments = project.IsPendingApproval() && new ProjectEditAsAdminRegardlessOfStageFeature().HasPermission(currentFirmaSession, project).HasPermission; }
public ExpectedFundingByCostTypeViewData(FirmaSession currentFirmaSession, ProjectFirmaModels.Models.Project project, ProposalSectionsStatus proposalSectionsStatus, ViewDataForAngularClass viewDataForAngularClass ) : base(currentFirmaSession, project, ProjectCreateSection.Budget.ProjectCreateSectionDisplayName, proposalSectionsStatus) { RequestFundingSourceUrl = SitkaRoute <HelpController> .BuildUrlFromExpression(x => x.MissingFundingSource()); ViewDataForAngular = viewDataForAngularClass; FieldDefinitionForProject = FieldDefinitionEnum.Project.ToType(); FieldDefinitionForFundingSource = FieldDefinitionEnum.FundingSource.ToType(); FieldDefinitionForCostType = FieldDefinitionEnum.CostType.ToType(); FieldDefinitionForNoFundingSourceIdentified = FieldDefinitionEnum.NoFundingSourceIdentified.ToType(); FieldDefinitionForSecuredFunding = FieldDefinitionEnum.SecuredFunding.ToType(); FieldDefinitionForTargetedFunding = FieldDefinitionEnum.TargetedFunding.ToType(); FieldDefinitionForPlanningDesignStartYear = FieldDefinitionEnum.PlanningDesignStartYear.ToType(); FieldDefinitionForCompletionYear = FieldDefinitionEnum.CompletionYear.ToType(); FieldDefinitionForEstimatedTotalCost = FieldDefinitionEnum.EstimatedTotalCost.ToType(); FieldDefinitionForEstimatedAnnualOperatingCost = FieldDefinitionEnum.EstimatedAnnualOperatingCost.ToType(); }
//New (not yet created) Projects use this constructor. Valid only for Instructions and Basics page. protected ProjectCreateViewData(FirmaSession currentFirmaSession, string currentSectionDisplayName, string proposalInstructionsUrl) : this(currentFirmaSession, null, currentSectionDisplayName, false) { Check.Assert(currentSectionDisplayName.Equals("Instructions", StringComparison.InvariantCultureIgnoreCase) || currentSectionDisplayName.Equals("Basics", StringComparison.InvariantCultureIgnoreCase)); Project = null; ProposalSectionsStatus = new ProposalSectionsStatus(); ProposalInstructionsUrl = proposalInstructionsUrl; ProposalBasicsUrl = SitkaRoute <ProjectCreateController> .BuildUrlFromExpression(x => x.CreateAndEditBasics(true)); HistoricProjectBasicsUrl = SitkaRoute <ProjectCreateController> .BuildUrlFromExpression(x => x.CreateAndEditBasics(false)); CurrentPersonCanWithdraw = false; SubmitUrl = string.Empty; ApproveUrl = string.Empty; ReturnUrl = string.Empty; WithdrawUrl = string.Empty; RejectUrl = string.Empty; TrainingUrl = SitkaRoute <HomeController> .BuildUrlFromExpression(x => x.Training()); }
public ExpendituresViewData(Person currentPerson, Models.Project project, ViewDataForAngularClass viewDataForAngularClass, ProjectExpendituresDetailViewData projectExpendituresDetailViewData, ProposalSectionsStatus proposalSectionsStatus) : base(currentPerson, project, "THIS IS BROKEN!" /* 5/15/2019 TK- ProjectCreateSection.ReportedExpenditures.ProjectCreateSectionDisplayName*/, proposalSectionsStatus) { ViewDataForAngular = viewDataForAngularClass; RefreshUrl = SitkaRoute <ProjectUpdateController> .BuildUrlFromExpression(x => x.RefreshExpenditures(project)); DiffUrl = SitkaRoute <ProjectUpdateController> .BuildUrlFromExpression(x => x.DiffExpenditures(project)); RequestGrantAllocationUrl = SitkaRoute <HelpController> .BuildUrlFromExpression(x => x.MissingGrantAllocation()); ProjectExpendituresDetailViewData = projectExpendituresDetailViewData; }
public InstructionsProposalViewData(Person currentPerson, Models.Project project, ProposalSectionsStatus proposalSectionsStatus, Models.FirmaPage firmaPage, bool isNewProjectCreate) : base(currentPerson, project, "Instructions", proposalSectionsStatus) { InstructionsViewPageContentViewData = new ViewPageContentViewData(firmaPage, new FirmaPageManageFeature().HasPermission(currentPerson, firmaPage).HasPermission); IsNewProjectCreate = isNewProjectCreate; }
public ContactsViewData(Person currentPerson, Models.Project project, ProposalSectionsStatus proposalSectionsStatus, EditPeopleViewData editPeopleViewData) : base(currentPerson, project, ProjectCreateSection.Contacts.ProjectCreateSectionDisplayName, proposalSectionsStatus) { EditPeopleViewData = editPeopleViewData; }
public ExternalLinksViewData(FirmaSession currentFirmaSession, ProjectFirmaModels.Models.Project project, ProposalSectionsStatus proposalSectionsStatus, ViewDataForAngularClass viewDataForAngular, EntityExternalLinksViewData entityExternalLinksViewData) : base(currentFirmaSession, project, ProjectCreateSection.ExternalLinks.ProjectCreateSectionDisplayName, proposalSectionsStatus) { ViewDataForAngular = viewDataForAngular; EntityExternalLinksViewData = entityExternalLinksViewData; }
public PhotoViewData(Person currentPerson, string galleryName, IEnumerable <IFileResourcePhoto> galleryImages, string addNewPhotoUrl, Func <IFileResourcePhoto, object> sortFunction, Models.Project project, ProposalSectionsStatus proposalSectionsStatus) : base(currentPerson, project, ProjectCreateSection.Photos.ProjectCreateSectionDisplayName, proposalSectionsStatus) { var selectKeyImageUrl = SitkaRoute <ProjectImageController> .BuildUrlFromExpression(x => x.SetKeyPhoto(UrlTemplate.Parameter1Int)); ImageGalleryViewData = new ImageGalleryViewData(currentPerson, galleryName, galleryImages, true, addNewPhotoUrl, selectKeyImageUrl, true, sortFunction, "Photo"); }
public EditAssessmentViewData(FirmaSession currentFirmaSession, ProjectFirmaModels.Models.Project project, List <AssessmentGoal> assessmentGoals, string currentSectionDisplayName, ProposalSectionsStatus proposalSectionsStatus) : base(currentFirmaSession, project, currentSectionDisplayName, proposalSectionsStatus) { ProjectName = project.GetDisplayName(); AssessmentGoals = assessmentGoals; }
public PhotoViewData(FirmaSession currentFirmaSession, string galleryName, IEnumerable <FileResourcePhoto> galleryImages, string addNewPhotoUrl, Func <FileResourcePhoto, object> sortFunction, ProjectFirmaModels.Models.Project project, ProposalSectionsStatus proposalSectionsStatus) : base(currentFirmaSession, project, ProjectCreateSection.Photos.ProjectCreateSectionDisplayName, proposalSectionsStatus) { AddNewUrl = addNewPhotoUrl; var selectKeyImageUrl = SitkaRoute <ProjectImageController> .BuildUrlFromExpression(x => x.SetKeyPhoto(UrlTemplate.Parameter1Int)); ImageGalleryViewData = new ImageGalleryViewData(currentFirmaSession, galleryName, galleryImages, true, addNewPhotoUrl, selectKeyImageUrl, true, sortFunction, "Photo"); ShowCommentsSection = project.IsPendingApproval() || (project.PhotosComment != null && project.ProjectApprovalStatus == ProjectApprovalStatus.Returned); CanEditComments = project.IsPendingApproval() && new ProjectEditAsAdminRegardlessOfStageFeature().HasPermission(currentFirmaSession, project).HasPermission; }
public EditProposalClassificationsViewData(Person currentPerson, Models.Project project, List <Models.ClassificationSystem> classificationSystems, string currentSectionDisplayName, ProposalSectionsStatus proposalSectionsStatus) : base(currentPerson, project, currentSectionDisplayName, proposalSectionsStatus) { ProjectName = project.DisplayName; ClassificationSystems = classificationSystems; }