Documentation
¶
Index ¶
- func AnalyzedAuditCreate(np sqlutils.NamedPreparer, logger logging.ILogger, ...) (*models.AnalyzedAudit, error)
- func AnalyzedAuditGetByDate(np sqlutils.NamedPreparer, _ logging.ILogger, date time.Time) ([]*models.AnalyzedAudit, error)
- func AnalyzedAuditGetByModelPlanIDAndDate(np sqlutils.NamedPreparer, _ *zap.Logger, modelPlanID uuid.UUID, ...) (*models.AnalyzedAudit, error)
- func AnalyzedAuditGetByModelPlanIDsAndDate(np sqlutils.NamedPreparer, _ logging.ILogger, modelPlanIDs []uuid.UUID, ...) ([]*models.AnalyzedAudit, error)
- func AnalyzedAuditGetByModelPlanIDsAndDateLoader(np sqlutils.NamedPreparer, paramTableJSON string) ([]*models.AnalyzedAudit, error)
- func AuditChangeCollectionByIDAndTable(np sqlutils.NamedPreparer, _ logging.ILogger, tableName models.TableName, ...) ([]*models.AuditChange, error)
- func AuditChangeCollectionByIDAndTableAndField(np sqlutils.NamedPreparer, _ logging.ILogger, tableName string, ...) ([]*models.AuditChange, error)
- func AuditChangeCollectionByPrimaryKeyOrForeignKeyAndDate(np sqlutils.NamedPreparer, _ logging.ILogger, primaryKey uuid.UUID, ...) ([]*models.AuditChange, error)
- func AuditChangeCollectionGetByModelPlanIDandTimeRange(np sqlutils.NamedPreparer, _ *zap.Logger, modelPlanID uuid.UUID, ...) ([]*models.AuditChange, error)
- func AuditChangeGetNotProcessed(np sqlutils.NamedPreparer, _ zap.Logger) ([]*models.AuditChangeWithModelPlanID, error)
- func AuditChangeWithModelPlanGetByID(np sqlutils.NamedPreparer, _ logging.ILogger, auditID int) (*models.AuditChangeWithModelPlanID, error)
- func CTATRequestAdminUpdate(np sqlutils.NamedPreparer, request *models.CTATRequest) (*models.CTATRequest, error)
- func CTATRequestCreate(np sqlutils.NamedPreparer, request *models.CTATRequest) (*models.CTATRequest, error)
- func CTATRequestDocumentCreate(np sqlutils.NamedPreparer, doc *models.CTATRequestDocument) (*models.CTATRequestDocument, error)
- func CTATRequestDocumentGetByCTATRequestIDLOADER(np sqlutils.NamedPreparer, ctatRequestIDs []uuid.UUID) ([]*models.CTATRequestDocument, error)
- func CTATRequestDocumentsUpdateVirusScanStatuses(ctx context.Context, s3Client *s3.S3Client, ...) error
- func CTATRequestGetByIDLOADER(np sqlutils.NamedPreparer, ids []uuid.UUID) ([]*models.CTATRequest, error)
- func CTATRequestGetByRequesterIDLOADER(np sqlutils.NamedPreparer, requesterIDs []uuid.UUID) ([]*models.CTATRequest, error)
- func CTATRequestGetForAdminLOADER(np sqlutils.NamedPreparer) ([]*models.CTATRequest, error)
- func CTATRequestModelPlanLinkCreate(np sqlutils.NamedPreparer, link *models.CTATRequestModelPlanLink) (*models.CTATRequestModelPlanLink, error)
- func CheckIfCollaborator(np sqlutils.NamedPreparer, _ *zap.Logger, principalID uuid.UUID, ...) (bool, error)
- func CheckIfCollaboratorByDiscussionID(np sqlutils.NamedPreparer, _ *zap.Logger, principalID uuid.UUID, ...) (bool, error)
- func CheckIfCollaboratorByMilestoneID(np sqlutils.NamedPreparer, _ *zap.Logger, principalID uuid.UUID, ...) (bool, error)
- func ClearReadyForClearanceByModelPlanID(np sqlutils.NamedPreparer, _ *zap.Logger, modelPlanID uuid.UUID, ...) error
- func CommonWaiverGetByIDLoader(np sqlutils.NamedPreparer, _ *zap.Logger, ids []uuid.UUID) ([]*models.CommonWaiver, error)
- func CommonWaiverGetByModelPlanIDLoader(np sqlutils.NamedPreparer, _ *zap.Logger, modelPlanIDs []uuid.UUID) ([]*models.CommonWaiver, error)
- func CustomTimelineDateCreate(np sqlutils.NamedPreparer, customTimelineDate *models.CustomTimelineDate) (*models.CustomTimelineDate, error)
- func CustomTimelineDateDelete(tx *sqlx.Tx, actorUserID uuid.UUID, id uuid.UUID) (*models.CustomTimelineDate, error)
- func CustomTimelineDateGetByIDLoader(np sqlutils.NamedPreparer, ids []uuid.UUID) ([]*models.CustomTimelineDate, error)
- func CustomTimelineDateGetByModelPlanIDLoader(np sqlutils.NamedPreparer, modelPlanIDs []uuid.UUID) ([]*models.CustomTimelineDate, error)
- func CustomTimelineDateUpdate(np sqlutils.NamedPreparer, customTimelineDate *models.CustomTimelineDate) (*models.CustomTimelineDate, error)
- func CustomTimelineDateUpdateDatesByIDs(np sqlutils.NamedPreparer, actorUserID uuid.UUID, ...) ([]*models.CustomTimelineDate, error)
- func DiscussionReplyByID(np sqlutils.NamedPreparer, _ *zap.Logger, id uuid.UUID) (*models.DiscussionReply, error)
- func DiscussionReplyCreate(logger *zap.Logger, reply *models.DiscussionReply, np sqlutils.NamedPreparer) (*models.DiscussionReply, error)
- func DiscussionReplyDelete(tx *sqlx.Tx, logger *zap.Logger, id uuid.UUID, userID uuid.UUID) (*models.DiscussionReply, error)
- func DiscussionReplyGetByDiscussionIDLOADER(np sqlutils.NamedPreparer, _ *zap.Logger, paramTableJSON string) ([]*models.DiscussionReply, error)
- func DiscussionReplyUpdate(np sqlutils.NamedPreparer, logger *zap.Logger, reply *models.DiscussionReply) (*models.DiscussionReply, error)
- func ExistingModelCollectionGet(np sqlutils.NamedPreparer, _ *zap.Logger) ([]*models.ExistingModel, error)
- func ExistingModelGetByID(np sqlutils.NamedPreparer, _ *zap.Logger, id int) (*models.ExistingModel, error)
- func ExistingModelGetByIDLOADER(np sqlutils.NamedPreparer, _ *zap.Logger, paramTableJSON string) ([]*models.ExistingModel, error)
- func ExistingModelLinkGetByID(np sqlutils.NamedPreparer, logger *zap.Logger, id uuid.UUID) (*models.ExistingModelLink, error)
- func ExistingModelLinkGetByModelPlanIDAndFieldNameLOADER(np sqlutils.NamedPreparer, logger *zap.Logger, paramTableJSON string) ([]*models.ExistingModelLink, error)
- func ExistingModelLinksUpdate(tx *sqlx.Tx, logger *zap.Logger, userID uuid.UUID, modelPlanID uuid.UUID, ...) ([]*models.ExistingModelLink, error)
- func GetChangesPerModelBySectionLoader(np sqlutils.NamedPreparer, _ *zap.Logger) ([]*models.ModelChangesBySectionAnalytics, error)
- func GetChangesPerModelLoader(np sqlutils.NamedPreparer, _ *zap.Logger) ([]*models.ModelChangesAnalytics, error)
- func GetChangesPerModelOtherDataLoader(np sqlutils.NamedPreparer, _ *zap.Logger) ([]*models.ModelChangesOtherDataAnalytics, error)
- func GetDiscussionReplyDetailsForEmail(np sqlutils.NamedPreparer, discussionID uuid.UUID) ([]*email.DiscussionReplyEmailContentDB, error)
- func GetExistingModelLinkNamesByModelPlanIDAndFieldNameLOADER(np sqlutils.NamedPreparer, logger *zap.Logger, paramTableJSON string) ([]*models.ExistingModelLinks, error)
- func GetMTOSolutionSelectedDetails(np sqlutils.NamedPreparer, solutionID uuid.UUID) (*email.MTOSolutionSelectedDB, error)
- func GetModelsByStatusLoader(np sqlutils.NamedPreparer, _ *zap.Logger) ([]*models.ModelsByStatusAnalytics, error)
- func GetMostRecentDiscussionRoleSelection(np sqlutils.NamedPreparer, logger *zap.Logger, userID uuid.UUID) (*models.DiscussionRoleSelection, error)
- func GetNumberOfFollowersPerModelLoader(np sqlutils.NamedPreparer, _ *zap.Logger) ([]*models.ModelFollowersAnalytics, error)
- func GetNumberOfModelsOverTimeLoader(np sqlutils.NamedPreparer, _ *zap.Logger) ([]*models.ModelCountAnalyticsOverTime, error)
- func GetTotalNumberOfModelsLoader(np sqlutils.NamedPreparer, _ *zap.Logger) ([]*models.ModelCountAnalytics, error)
- func IDDOCQuestionnaireCreate(np sqlutils.NamedPreparer, _ *zap.Logger, ...) (*models.IDDOCQuestionnaire, error)
- func IDDOCQuestionnaireGetByID(np sqlutils.NamedPreparer, _ *zap.Logger, id uuid.UUID) (*models.IDDOCQuestionnaire, error)
- func IDDOCQuestionnaireGetByIDLoader(np sqlutils.NamedPreparer, _ *zap.Logger, ids []uuid.UUID) ([]*models.IDDOCQuestionnaire, error)
- func IDDOCQuestionnaireGetByModelPlanIDLoader(np sqlutils.NamedPreparer, _ *zap.Logger, modelPlanIDs []uuid.UUID) ([]*models.IDDOCQuestionnaire, error)
- func IDDOCQuestionnaireUpdate(np sqlutils.NamedPreparer, logger *zap.Logger, ...) (*models.IDDOCQuestionnaire, error)
- func KeyContactCategoryCreate(np sqlutils.NamedPreparer, _ *zap.Logger, ...) (*models.KeyContactCategory, error)
- func KeyContactCategoryDelete(np sqlutils.NamedPreparer, _ *zap.Logger, id uuid.UUID) (*models.KeyContactCategory, error)
- func KeyContactCategoryGetAll(np sqlutils.NamedPreparer, _ *zap.Logger) ([]*models.KeyContactCategory, error)
- func KeyContactCategoryGetAllLoader(np sqlutils.NamedPreparer, _ *zap.Logger) ([]*models.KeyContactCategory, error)
- func KeyContactCategoryGetByID(np sqlutils.NamedPreparer, _ *zap.Logger, id uuid.UUID) (*models.KeyContactCategory, error)
- func KeyContactCategoryGetByIDsLoader(np sqlutils.NamedPreparer, _ *zap.Logger, ids []uuid.UUID) ([]*models.KeyContactCategory, error)
- func KeyContactCategoryUpdate(np sqlutils.NamedPreparer, _ *zap.Logger, ...) (*models.KeyContactCategory, error)
- func KeyContactCreateContact(np sqlutils.NamedPreparer, _ *zap.Logger, KeyContact *models.KeyContact) (*models.KeyContact, error)
- func KeyContactDeleteContactByID(tx *sqlx.Tx, actorUserID uuid.UUID, _ *zap.Logger, id uuid.UUID) (*models.KeyContact, error)
- func KeyContactGetAllLoader(np sqlutils.NamedPreparer, _ *zap.Logger) ([]*models.KeyContact, error)
- func KeyContactGetByCategoryIDsLoader(np sqlutils.NamedPreparer, _ *zap.Logger, ids []uuid.UUID) ([]*models.KeyContact, error)
- func KeyContactGetByIDsLoader(np sqlutils.NamedPreparer, _ *zap.Logger, ids []uuid.UUID) ([]*models.KeyContact, error)
- func KeyContactUpdateContact(np sqlutils.NamedPreparer, _ *zap.Logger, KeyContact *models.KeyContact) (*models.KeyContact, error)
- func MTOCategoryAndSubCategoriesGetByModelPlanIDLoader(np sqlutils.NamedPreparer, _ *zap.Logger, modelPlanIDs []uuid.UUID) ([]*models.MTOCategory, error)
- func MTOCategoryCreate(np sqlutils.NamedPreparer, _ *zap.Logger, MTOCategory *models.MTOCategory) (*models.MTOCategory, error)
- func MTOCategoryCreateAllowConflicts(np sqlutils.NamedPreparer, _ *zap.Logger, MTOCategory *models.MTOCategory) (*models.MTOCategoryWithNewlyInsertedStatus, error)
- func MTOCategoryDelete(tx *sqlx.Tx, actorUserID uuid.UUID, id uuid.UUID) error
- func MTOCategoryGetByID(np sqlutils.NamedPreparer, _ *zap.Logger, id uuid.UUID) (*models.MTOCategory, error)
- func MTOCategoryGetByIDLoader(np sqlutils.NamedPreparer, _ *zap.Logger, ids []uuid.UUID) ([]*models.MTOCategory, error)
- func MTOCategoryGetByModelPlanIDLoader(np sqlutils.NamedPreparer, _ *zap.Logger, modelPlanIDs []uuid.UUID) ([]*models.MTOCategory, error)
- func MTOCategoryUpdate(np sqlutils.NamedPreparer, _ *zap.Logger, MTOCategory *models.MTOCategory) (*models.MTOCategory, error)
- func MTOCommonMilestoneArchive(np sqlutils.TransactionPreparer, logger *zap.Logger, id uuid.UUID, ...) (*models.MTOCommonMilestone, error)
- func MTOCommonMilestoneCreate(np sqlutils.TransactionPreparer, name string, description string, ...) (*models.MTOCommonMilestone, error)
- func MTOCommonMilestoneGetByIDLoader(np sqlutils.NamedPreparer, _ *zap.Logger, ids []uuid.UUID) ([]*models.MTOCommonMilestone, error)
- func MTOCommonMilestoneGetByModelPlanIDLoader(np sqlutils.NamedPreparer, _ *zap.Logger, modelPlanIDs []uuid.UUID) ([]*models.MTOCommonMilestone, error)
- func MTOCommonMilestoneGetCommonCategories(np sqlutils.NamedPreparer, _ *zap.Logger) ([]*models.CommonCategory, error)
- func MTOCommonMilestoneUpdate(np sqlutils.TransactionPreparer, commonMilestone *models.MTOCommonMilestone, ...) (*models.MTOCommonMilestone, error)
- func MTOCommonSolutionContactGetByCommonSolutionKeyLoader(np sqlutils.NamedPreparer, _ *zap.Logger, keys []models.MTOCommonSolutionKey) ([]*models.MTOCommonSolutionContact, error)
- func MTOCommonSolutionContactGetByIDsLoader(np sqlutils.NamedPreparer, _ *zap.Logger, ids []uuid.UUID) ([]*models.MTOCommonSolutionContact, error)
- func MTOCommonSolutionContactUnsetPrimaryContactByKey(np sqlutils.NamedPreparer, _ *zap.Logger, ...) error
- func MTOCommonSolutionContractorGetByCommonSolutionKeyLoader(np sqlutils.NamedPreparer, _ *zap.Logger, keys []models.MTOCommonSolutionKey) ([]*models.MTOCommonSolutionContractor, error)
- func MTOCommonSolutionContractorGetByIDLoader(np sqlutils.NamedPreparer, _ *zap.Logger, ids []uuid.UUID) ([]*models.MTOCommonSolutionContractor, error)
- func MTOCommonSolutionCreateContact(np sqlutils.NamedPreparer, _ *zap.Logger, ...) (*models.MTOCommonSolutionContact, error)
- func MTOCommonSolutionCreateContractor(np sqlutils.NamedPreparer, _ *zap.Logger, ...) (*models.MTOCommonSolutionContractor, error)
- func MTOCommonSolutionCreateSystemOwner(np sqlutils.NamedPreparer, _ *zap.Logger, ...) (*models.MTOCommonSolutionSystemOwner, error)
- func MTOCommonSolutionDeleteContactByID(tx *sqlx.Tx, actorUserID uuid.UUID, _ *zap.Logger, id uuid.UUID) (*models.MTOCommonSolutionContact, error)
- func MTOCommonSolutionDeleteContractorByID(tx *sqlx.Tx, actorUserID uuid.UUID, _ *zap.Logger, id uuid.UUID) (*models.MTOCommonSolutionContractor, error)
- func MTOCommonSolutionGetByCommonMilestoneIDLoader(np sqlutils.NamedPreparer, _ *zap.Logger, mtoCommonMilestoneIDs []uuid.UUID) ([]*models.MTOCommonSolution, error)
- func MTOCommonSolutionGetByIDLoader(np sqlutils.NamedPreparer, _ *zap.Logger, ids []uuid.UUID) ([]*models.MTOCommonSolution, error)
- func MTOCommonSolutionGetByKeyLoader(np sqlutils.NamedPreparer, _ *zap.Logger, keys []models.MTOCommonSolutionKey) ([]*models.MTOCommonSolution, error)
- func MTOCommonSolutionGetByModelPlanIDLoader(np sqlutils.NamedPreparer, _ *zap.Logger, modelPlanIDs []uuid.UUID) ([]*models.MTOCommonSolution, error)
- func MTOCommonSolutionGetContactByID(np sqlutils.NamedPreparer, _ *zap.Logger, id uuid.UUID) (*models.MTOCommonSolutionContact, error)
- func MTOCommonSolutionGetContractorByID(np sqlutils.NamedPreparer, _ *zap.Logger, id uuid.UUID) (*models.MTOCommonSolutionContractor, error)
- func MTOCommonSolutionSystemOwnerDeleteByID(tx *sqlx.Tx, actorUserID uuid.UUID, _ *zap.Logger, id uuid.UUID) (*models.MTOCommonSolutionSystemOwner, error)
- func MTOCommonSolutionSystemOwnerGetByCommonSolutionKeyLoader(np sqlutils.NamedPreparer, _ *zap.Logger, keys []models.MTOCommonSolutionKey) ([]*models.MTOCommonSolutionSystemOwner, error)
- func MTOCommonSolutionSystemOwnerGetByID(np sqlutils.NamedPreparer, _ *zap.Logger, id uuid.UUID) (*models.MTOCommonSolutionSystemOwner, error)
- func MTOCommonSolutionSystemOwnerGetByIDLoader(np sqlutils.NamedPreparer, _ *zap.Logger, ids []uuid.UUID) ([]*models.MTOCommonSolutionSystemOwner, error)
- func MTOCommonSolutionSystemOwnerUpdate(np sqlutils.NamedPreparer, _ *zap.Logger, ...) (*models.MTOCommonSolutionSystemOwner, error)
- func MTOCommonSolutionUpdateContact(np sqlutils.NamedPreparer, _ *zap.Logger, ...) (*models.MTOCommonSolutionContact, error)
- func MTOCommonSolutionUpdateContractor(np sqlutils.NamedPreparer, _ *zap.Logger, ...) (*models.MTOCommonSolutionContractor, error)
- func MTOInfoCreate(np sqlutils.NamedPreparer, _ *zap.Logger, MTOInfo *models.MTOInfo) (*models.MTOInfo, error)
- func MTOInfoGetByModelPlanIDLoader(np sqlutils.NamedPreparer, _ *zap.Logger, modelPlanIDs []uuid.UUID) ([]*models.MTOInfo, error)
- func MTOInfoUpdate(np sqlutils.NamedPreparer, _ *zap.Logger, MTOInfo *models.MTOInfo) (*models.MTOInfo, error)
- func MTOMilestoneCreate(np sqlutils.NamedPreparer, _ *zap.Logger, MTOMilestone *models.MTOMilestone) (*models.MTOMilestone, error)
- func MTOMilestoneCreateAllowConflicts(np sqlutils.NamedPreparer, _ *zap.Logger, MTOMilestone *models.MTOMilestone) (*models.MTOMilestoneWithNewlyInsertedStatus, error)
- func MTOMilestoneDelete(tx *sqlx.Tx, actorUserID uuid.UUID, _ *zap.Logger, milestoneID uuid.UUID) error
- func MTOMilestoneGetByID(np sqlutils.NamedPreparer, _ *zap.Logger, id uuid.UUID) (*models.MTOMilestone, error)
- func MTOMilestoneGetByIDLoader(np sqlutils.NamedPreparer, _ *zap.Logger, ids []uuid.UUID) ([]*models.MTOMilestone, error)
- func MTOMilestoneGetByModelPlanIDAndCategoryIDLoader(np sqlutils.NamedPreparer, _ *zap.Logger, ...) ([]*models.MTOMilestone, error)
- func MTOMilestoneGetByModelPlanIDLoader(np sqlutils.NamedPreparer, _ *zap.Logger, modelPlanIDs []uuid.UUID) ([]*models.MTOMilestone, error)
- func MTOMilestoneGetByModelPlanIDNoLinkedSolutionLoader(np sqlutils.NamedPreparer, _ *zap.Logger, modelPlanIDs []uuid.UUID) ([]*models.MTOMilestone, error)
- func MTOMilestoneGetBySolutionIDLoader(np sqlutils.NamedPreparer, _ *zap.Logger, solutionIDs []uuid.UUID) ([]*models.MTOMilestoneWithSolutionID, error)
- func MTOMilestoneNoteCreate(np sqlutils.NamedPreparer, _ *zap.Logger, ...) (*models.MTOMilestoneNote, error)
- func MTOMilestoneNoteDelete(tx *sqlx.Tx, actorUserID uuid.UUID, _ *zap.Logger, milestoneNoteID uuid.UUID) error
- func MTOMilestoneNoteGetByIDLoader(np sqlutils.NamedPreparer, _ *zap.Logger, ids []uuid.UUID) ([]*models.MTOMilestoneNote, error)
- func MTOMilestoneNoteGetByMilestoneIDLoader(np sqlutils.NamedPreparer, _ *zap.Logger, milestoneIDs []uuid.UUID) ([]*models.MTOMilestoneNote, error)
- func MTOMilestoneNoteUpdate(np sqlutils.NamedPreparer, _ *zap.Logger, ...) (*models.MTOMilestoneNote, error)
- func MTOMilestoneSolutionLinkCreate(np sqlutils.NamedPreparer, _ *zap.Logger, ...) (*models.MTOMilestoneSolutionLink, error)
- func MTOMilestoneSolutionLinkGetByMilestoneID(np sqlutils.NamedPreparer, _ *zap.Logger, milestoneID uuid.UUID) ([]*models.MTOMilestoneSolutionLink, error)
- func MTOMilestoneSolutionLinkMergeSolutionsToMilestones(tx *sqlx.Tx, _ *zap.Logger, milestoneID uuid.UUID, solutionIDs []uuid.UUID, ...) ([]*models.MTOSolution, error)
- func MTOMilestoneSolutionLinkMilestonesToSolution(tx *sqlx.Tx, logger *zap.Logger, solutionID uuid.UUID, ...) ([]*models.MTOMilestone, error)
- func MTOMilestoneUpdate(np sqlutils.NamedPreparer, _ *zap.Logger, MTOMilestone *models.MTOMilestone) (*models.MTOMilestone, error)
- func MTOSolutionCreate(np sqlutils.NamedPreparer, _ *zap.Logger, mtoSolution *models.MTOSolution) (*models.MTOSolution, error)
- func MTOSolutionCreateCommonAllowConflictsSQL(np sqlutils.NamedPreparer, _ *zap.Logger, ...) ([]*models.MTOSolutionWithNewlyInsertedStatus, error)
- func MTOSolutionDelete(tx *sqlx.Tx, actorUserID uuid.UUID, _ *zap.Logger, milestoneID uuid.UUID) error
- func MTOSolutionGetByCommonMilestoneIDLoader(np sqlutils.NamedPreparer, _ *zap.Logger, mtoCommonMilestoneIDs []uuid.UUID) ([]*models.MTOCommonSolution, error)
- func MTOSolutionGetByIDLoader(np sqlutils.NamedPreparer, _ *zap.Logger, ids []uuid.UUID) ([]*models.MTOSolution, error)
- func MTOSolutionGetByKeyLoader(np sqlutils.NamedPreparer, _ *zap.Logger, keys []models.MTOCommonSolutionKey) ([]*models.MTOSolution, error)
- func MTOSolutionGetByMilestoneIDLoader(np sqlutils.NamedPreparer, _ *zap.Logger, milestoneIDs []uuid.UUID) ([]*models.MTOSolutionWithMilestoneID, error)
- func MTOSolutionGetByModelPlanIDAndFilterViewLoader(np sqlutils.NamedPreparer, _ *zap.Logger, ...) ([]*models.MTOSolutionWithModelFilterView, error)
- func MTOSolutionGetByModelPlanIDLoader(np sqlutils.NamedPreparer, _ *zap.Logger, modelPlanIDs []uuid.UUID) ([]*models.MTOSolution, error)
- func MTOSolutionUpdate(np sqlutils.NamedPreparer, _ *zap.Logger, mtoSolution *models.MTOSolution) (*models.MTOSolution, error)
- func MTOSubcategoryGetByParentIDLoader(np sqlutils.NamedPreparer, _ *zap.Logger, parentIDs []uuid.UUID) ([]*models.MTOSubcategory, error)
- func MTOSuggestedMilestoneReasonGetByMTOSuggestedMilestoneIDLoader(np sqlutils.NamedPreparer, _ *zap.Logger, ids []uuid.UUID) ([]*models.MTOSuggestedMilestoneReason, error)
- func MTOTemplateCategoryGetByIDLoader(np sqlutils.NamedPreparer, _ *zap.Logger, ids []uuid.UUID) ([]*models.MTOTemplateCategory, error)
- func MTOTemplateCategoryGetByTemplateIDLoader(np sqlutils.NamedPreparer, _ *zap.Logger, templateIDs []uuid.UUID) ([]*models.MTOTemplateCategory, error)
- func MTOTemplateGetAllLoader(np sqlutils.NamedPreparer, _ *zap.Logger) ([]*models.MTOTemplate, error)
- func MTOTemplateGetByIDLoader(np sqlutils.NamedPreparer, _ *zap.Logger, ids []uuid.UUID) ([]*models.MTOTemplate, error)
- func MTOTemplateGetByKeyLoader(np sqlutils.NamedPreparer, _ *zap.Logger, keys []models.MTOTemplateKey) ([]*models.MTOTemplate, error)
- func MTOTemplateGetByModelPlanIDLoader(np sqlutils.NamedPreparer, _ *zap.Logger, modelPlanIDs []uuid.UUID) ([]*models.MTOTemplate, error)
- func MTOTemplateMilestoneGetByCategoryIDLoader(np sqlutils.NamedPreparer, _ *zap.Logger, categoryIDs []uuid.UUID) ([]*models.MTOTemplateMilestone, error)
- func MTOTemplateMilestoneGetByIDLoader(np sqlutils.NamedPreparer, _ *zap.Logger, ids []uuid.UUID) ([]*models.MTOTemplateMilestone, error)
- func MTOTemplateMilestoneGetBySolutionIDLoader(np sqlutils.NamedPreparer, _ *zap.Logger, solutionIDs []uuid.UUID) ([]*models.MTOTemplateMilestone, error)
- func MTOTemplateMilestoneGetByTemplateIDLoader(np sqlutils.NamedPreparer, _ *zap.Logger, templateIDs []uuid.UUID) ([]*models.MTOTemplateMilestone, error)
- func MTOTemplateMilestoneSolutionLinkGetByTemplateIDLoader(np sqlutils.NamedPreparer, _ *zap.Logger, templateIDs []uuid.UUID) ([]*models.MTOTemplateMilestoneSolutionLink, error)
- func MTOTemplateSolutionGetByIDLoader(np sqlutils.NamedPreparer, _ *zap.Logger, ids []uuid.UUID) ([]*models.MTOTemplateSolution, error)
- func MTOTemplateSolutionGetByMilestoneIDLoader(np sqlutils.NamedPreparer, _ *zap.Logger, milestoneIDs []uuid.UUID) ([]*models.MTOTemplateSolution, error)
- func MTOTemplateSolutionGetByTemplateIDLoader(np sqlutils.NamedPreparer, _ *zap.Logger, templateIDs []uuid.UUID) ([]*models.MTOTemplateSolution, error)
- func MTOTemplateSubCategoryGetByCategoryIDLoader(np sqlutils.NamedPreparer, _ *zap.Logger, categoryIDs []uuid.UUID) ([]*models.MTOTemplateSubCategory, error)
- func MTOTemplateSubCategoryGetByIDLoader(np sqlutils.NamedPreparer, _ *zap.Logger, ids []uuid.UUID) ([]*models.MTOTemplateSubCategory, error)
- func MTOTemplateSubCategoryGetByTemplateIDLoader(np sqlutils.NamedPreparer, _ *zap.Logger, templateIDs []uuid.UUID) ([]*models.MTOTemplateSubCategory, error)
- func ModelPlanCollection(np sqlutils.NamedPreparer, logger logging.ILogger, archived bool) ([]*models.ModelPlan, error)
- func ModelPlanCollectionApproachingClearance(np sqlutils.NamedPreparer, logger *zap.Logger) ([]*models.ModelPlan, error)
- func ModelPlanCollectionCollaboratorOnly(np sqlutils.NamedPreparer, logger *zap.Logger, archived bool, userID uuid.UUID) ([]*models.ModelPlan, error)
- func ModelPlanCollectionFavorited(np sqlutils.NamedPreparer, logger *zap.Logger, archived bool, userID uuid.UUID) ([]*models.ModelPlan, error)
- func ModelPlanCollectionNewlyCreated(np sqlutils.NamedPreparer, logger *zap.Logger) ([]*models.ModelPlan, error)
- func ModelPlanCreate(np sqlutils.NamedPreparer, logger *zap.Logger, plan *models.ModelPlan) (*models.ModelPlan, error)
- func ModelPlanGetByComponentGroupLoader(np sqlutils.NamedPreparer, logger *zap.Logger, ...) ([]*models.ModelPlanAndGroup, error)
- func ModelPlanGetByID(np sqlutils.NamedPreparer, logger logging.ILogger, id uuid.UUID) (*models.ModelPlan, error)
- func ModelPlanGetByMTOSolutionKeyLOADER(np sqlutils.NamedPreparer, _ *zap.Logger, keys []models.MTOCommonSolutionKey) ([]*models.ModelPlanAndMTOCommonSolution, error)
- func ModelPlanGetByName(np sqlutils.NamedPreparer, logger *zap.Logger, modelName string) (*models.ModelPlan, error)
- func ModelPlanGetByStatuses(np sqlutils.NamedPreparer, logger *zap.Logger, statuses []models.ModelStatus) ([]*models.ModelPlan, error)
- func ModelPlanGetTaskListStatus(np sqlutils.NamedPreparer, logger *zap.Logger, modelPlanID uuid.UUID) (models.TaskStatus, error)
- func ModelPlanMTOTemplateLinkGetByIDLoader(np sqlutils.NamedPreparer, _ *zap.Logger, ids []uuid.UUID) ([]*models.ModelPlanMTOTemplateLink, error)
- func ModelPlanMTOTemplateLinkGetByModelPlanIDLoader(np sqlutils.NamedPreparer, _ *zap.Logger, modelPlanIDs []uuid.UUID) ([]*models.ModelPlanMTOTemplateLink, error)
- func ModelPlanMTOTemplateLinkGetByTemplateIDLoader(np sqlutils.NamedPreparer, _ *zap.Logger, templateIDs []uuid.UUID) ([]*models.ModelPlanMTOTemplateLink, error)
- func ModelPlanMTOTemplateLinkUpsert(np sqlutils.NamedPreparer, _ *zap.Logger, ...) (*models.ModelPlanMTOTemplateLink, error)
- func ModelPlanUpdate(np sqlutils.NamedPreparer, logger logging.ILogger, plan *models.ModelPlan) (*models.ModelPlan, error)
- func ModelPlansGetByCTATRequestIDsLOADER(np sqlutils.NamedPreparer, _ *zap.Logger, ctatRequestIDs []uuid.UUID) ([]*models.ModelPlanWithCTATRequestID, error)
- func ModelPlansGetByModePlanIDsLOADER(np sqlutils.NamedPreparer, _ *zap.Logger, modelPlanIDs []uuid.UUID) ([]*models.ModelPlan, error)
- func NDAAgreementCreate(np sqlutils.NamedPreparer, _ *zap.Logger, nda *models.NDAAgreement) (*models.NDAAgreement, error)
- func NDAAgreementGetByUserID(np sqlutils.NamedPreparer, _ *zap.Logger, userID uuid.UUID) (*models.NDAAgreement, error)
- func NDAAgreementUpdate(np sqlutils.NamedPreparer, _ *zap.Logger, nda *models.NDAAgreement) (*models.NDAAgreement, error)
- func PlanBasicsCreate(np sqlutils.NamedPreparer, logger *zap.Logger, basics *models.PlanBasics) (*models.PlanBasics, error)
- func PlanBasicsGetByID(np sqlutils.NamedPreparer, _ *zap.Logger, id uuid.UUID) (*models.PlanBasics, error)
- func PlanBasicsGetByModelPlanIDLoader(np sqlutils.NamedPreparer, _ *zap.Logger, modelPlanIDs []uuid.UUID) ([]*models.PlanBasics, error)
- func PlanBasicsUpdate(tx *sqlx.Tx, logger *zap.Logger, plan *models.PlanBasics) (*models.PlanBasics, error)
- func PlanBeneficiariesCreate(np sqlutils.NamedPreparer, logger *zap.Logger, b *models.PlanBeneficiaries) (*models.PlanBeneficiaries, error)
- func PlanBeneficiariesGetByID(np sqlutils.NamedPreparer, _ *zap.Logger, id uuid.UUID) (*models.PlanBeneficiaries, error)
- func PlanBeneficiariesGetByModelPlanIDLOADER(np sqlutils.NamedPreparer, _ *zap.Logger, paramTableJSON string) ([]*models.PlanBeneficiaries, error)
- func PlanBeneficiariesUpdate(np sqlutils.NamedPreparer, logger *zap.Logger, b *models.PlanBeneficiaries) (*models.PlanBeneficiaries, error)
- func PlanCRCreate(np sqlutils.NamedPreparer, logger *zap.Logger, planCR *models.PlanCR) (*models.PlanCR, error)
- func PlanCRDelete(tx *sqlx.Tx, _ *zap.Logger, id uuid.UUID, userID uuid.UUID) (*models.PlanCR, error)
- func PlanCRGetByID(np sqlutils.NamedPreparer, _ *zap.Logger, id uuid.UUID) (*models.PlanCR, error)
- func PlanCRUpdate(np sqlutils.NamedPreparer, logger *zap.Logger, planCR *models.PlanCR) (*models.PlanCR, error)
- func PlanCRsGetByModelPlanID(np sqlutils.NamedPreparer, _ *zap.Logger, modelPlanID uuid.UUID) ([]*models.PlanCR, error)
- func PlanCollaboratorCreate(np sqlutils.NamedPreparer, _ *zap.Logger, ...) (*models.PlanCollaborator, error)
- func PlanCollaboratorDelete(tx *sqlx.Tx, _ *zap.Logger, id uuid.UUID, userID uuid.UUID) (*models.PlanCollaborator, error)
- func PlanCollaboratorGetByID(np sqlutils.NamedPreparer, id uuid.UUID) (*models.PlanCollaborator, error)
- func PlanCollaboratorGetByModelPlanID(np sqlutils.NamedPreparer, _ logging.ILogger, modelPlanID uuid.UUID) ([]*models.PlanCollaborator, error)
- func PlanCollaboratorGetByModelPlanIDLOADER(np sqlutils.NamedPreparer, _ *zap.Logger, modelPlanIDs []uuid.UUID) ([]*models.PlanCollaborator, error)
- func PlanCollaboratorGetCountByUserID(np sqlutils.NamedPreparer, userID uuid.UUID) (int, error)
- func PlanCollaboratorGetIDLOADER(np sqlutils.NamedPreparer, ids []uuid.UUID) ([]*models.PlanCollaborator, error)
- func PlanCollaboratorUpdate(np sqlutils.NamedPreparer, _ *zap.Logger, ...) (*models.PlanCollaborator, error)
- func PlanDataExchangeApproachCreate(np sqlutils.NamedPreparer, _ *zap.Logger, ...) (*models.PlanDataExchangeApproach, error)
- func PlanDataExchangeApproachGetByID(np sqlutils.NamedPreparer, _ *zap.Logger, id uuid.UUID) (*models.PlanDataExchangeApproach, error)
- func PlanDataExchangeApproachGetByModelPlanIDLoader(np sqlutils.NamedPreparer, _ *zap.Logger, modelPlanIDs []uuid.UUID) ([]*models.PlanDataExchangeApproach, error)
- func PlanDataExchangeApproachUpdate(np sqlutils.NamedPreparer, logger *zap.Logger, ...) (*models.PlanDataExchangeApproach, error)
- func PlanDiscussionByID(np sqlutils.NamedPreparer, _ *zap.Logger, id uuid.UUID) (*models.PlanDiscussion, error)
- func PlanDiscussionByIDWithNumberOfReplies(np sqlutils.NamedPreparer, _ *zap.Logger, id uuid.UUID, timeToCheck time.Time) (*models.PlanDiscussionWithNumberOfReplies, error)
- func PlanDiscussionCreate(logger *zap.Logger, discussion *models.PlanDiscussion, ...) (*models.PlanDiscussion, error)
- func PlanDiscussionDelete(tx *sqlx.Tx, _ *zap.Logger, id uuid.UUID, userID uuid.UUID) (*models.PlanDiscussion, error)
- func PlanDiscussionGetByModelPlanIDLOADER(np sqlutils.NamedPreparer, _ *zap.Logger, modelPlanIDs []uuid.UUID) ([]*models.PlanDiscussion, error)
- func PlanDiscussionUpdate(np sqlutils.NamedPreparer, logger *zap.Logger, ...) (*models.PlanDiscussion, error)
- func PlanDocumentCreate(tx *sqlx.Tx, logger *zap.Logger, principal string, ...) (*models.PlanDocument, error)
- func PlanDocumentDelete(tx *sqlx.Tx, logger *zap.Logger, id uuid.UUID, userID uuid.UUID) (sql.Result, error)
- func PlanDocumentGetByIDNoS3Check(np sqlutils.NamedPreparer, _ *zap.Logger, id uuid.UUID) (*models.PlanDocument, error)
- func PlanDocumentRead(np sqlutils.NamedPreparer, _ *zap.Logger, s3Client *s3.S3Client, id uuid.UUID) (*models.PlanDocument, error)
- func PlanDocumentsReadByModelPlanID(np sqlutils.NamedPreparer, logger *zap.Logger, modelPlanID uuid.UUID, ...) ([]*models.PlanDocument, error)
- func PlanDocumentsReadByModelPlanIDNotRestricted(np sqlutils.NamedPreparer, logger *zap.Logger, modelPlanID uuid.UUID, ...) ([]*models.PlanDocument, error)
- func PlanDocumentsReadByPlanTaskID(np sqlutils.NamedPreparer, logger *zap.Logger, planTaskID uuid.UUID, ...) ([]*models.PlanDocument, error)
- func PlanDocumentsReadByPlanTaskIDNotRestricted(np sqlutils.NamedPreparer, logger *zap.Logger, planTaskID uuid.UUID, ...) ([]*models.PlanDocument, error)
- func PlanFavoriteCollectionGetUniqueUserIDs(np sqlutils.NamedPreparer) ([]uuid.UUID, error)
- func PlanFavoriteCreate(np sqlutils.NamedPreparer, logger *zap.Logger, favorite models.PlanFavorite) (*models.PlanFavorite, error)
- func PlanFavoriteDelete(tx *sqlx.Tx, _ *zap.Logger, userAccountID uuid.UUID, planID uuid.UUID, ...) (*models.PlanFavorite, error)
- func PlanFavoriteGetByModelIDAndUserAccountID(np sqlutils.NamedPreparer, _ *zap.Logger, userAccountID uuid.UUID, ...) (*models.PlanFavorite, error)
- func PlanFavoriteGetCollectionByUserID(np sqlutils.NamedPreparer, _ logging.ILogger, userAccountID uuid.UUID) ([]*models.PlanFavorite, error)
- func PlanGeneralCharacteristicsCreate(np sqlutils.NamedPreparer, logger *zap.Logger, ...) (*models.PlanGeneralCharacteristics, error)
- func PlanGeneralCharacteristicsGetByID(np sqlutils.NamedPreparer, _ *zap.Logger, id uuid.UUID) (*models.PlanGeneralCharacteristics, error)
- func PlanGeneralCharacteristicsGetByModelPlanIDLOADER(np sqlutils.NamedPreparer, _ *zap.Logger, paramTableJSON string) ([]*models.PlanGeneralCharacteristics, error)
- func PlanGeneralCharacteristicsUpdate(np sqlutils.NamedPreparer, logger *zap.Logger, ...) (*models.PlanGeneralCharacteristics, error)
- func PlanOpsEvalAndLearningCreate(np sqlutils.NamedPreparer, logger *zap.Logger, ...) (*models.PlanOpsEvalAndLearning, error)
- func PlanOpsEvalAndLearningGetByID(np sqlutils.NamedPreparer, _ *zap.Logger, id uuid.UUID) (*models.PlanOpsEvalAndLearning, error)
- func PlanOpsEvalAndLearningGetByModelPlanIDLOADER(np sqlutils.NamedPreparer, _ *zap.Logger, paramTableJSON string) ([]*models.PlanOpsEvalAndLearning, error)
- func PlanOpsEvalAndLearningUpdate(np sqlutils.NamedPreparer, logger *zap.Logger, ...) (*models.PlanOpsEvalAndLearning, error)
- func PlanParticipantsAndProvidersCreate(np sqlutils.NamedPreparer, logger *zap.Logger, ...) (*models.PlanParticipantsAndProviders, error)
- func PlanParticipantsAndProvidersGetByID(np sqlutils.NamedPreparer, _ *zap.Logger, id uuid.UUID) (*models.PlanParticipantsAndProviders, error)
- func PlanParticipantsAndProvidersGetByModelPlanIDLOADER(np sqlutils.NamedPreparer, _ *zap.Logger, paramTableJSON string) ([]*models.PlanParticipantsAndProviders, error)
- func PlanParticipantsAndProvidersUpdate(np sqlutils.NamedPreparer, logger *zap.Logger, ...) (*models.PlanParticipantsAndProviders, error)
- func PlanPaymentsCreate(np sqlutils.NamedPreparer, logger *zap.Logger, payments *models.PlanPayments) (*models.PlanPayments, error)
- func PlanPaymentsGetByModelPlanIDLOADER(np sqlutils.NamedPreparer, _ *zap.Logger, paramTableJSON string) ([]*models.PlanPayments, error)
- func PlanPaymentsRead(np sqlutils.NamedPreparer, _ *zap.Logger, id uuid.UUID) (*models.PlanPayments, error)
- func PlanPaymentsUpdate(np sqlutils.NamedPreparer, logger *zap.Logger, payments *models.PlanPayments) (*models.PlanPayments, error)
- func PlanTDLCreate(np sqlutils.NamedPreparer, logger *zap.Logger, planTDL *models.PlanTDL) (*models.PlanTDL, error)
- func PlanTDLDelete(tx *sqlx.Tx, _ *zap.Logger, id uuid.UUID, userID uuid.UUID) (*models.PlanTDL, error)
- func PlanTDLGetByID(np sqlutils.NamedPreparer, _ *zap.Logger, id uuid.UUID) (*models.PlanTDL, error)
- func PlanTDLUpdate(np sqlutils.NamedPreparer, logger *zap.Logger, planTDL *models.PlanTDL) (*models.PlanTDL, error)
- func PlanTDLsGetByModelPlanID(np sqlutils.NamedPreparer, _ *zap.Logger, modelPlanID uuid.UUID) ([]*models.PlanTDL, error)
- func PlanTaskActivateUpcoming(np sqlutils.NamedPreparer, _ *zap.Logger, modelPlanID uuid.UUID, ...) (*models.PlanTask, error)
- func PlanTaskCreate(np sqlutils.NamedPreparer, logger *zap.Logger, task *models.PlanTask) (*models.PlanTask, error)
- func PlanTaskGetByIDLoader(np sqlutils.NamedPreparer, _ *zap.Logger, ids []uuid.UUID) ([]*models.PlanTask, error)
- func PlanTaskGetByModelPlanIDAndKey(np sqlutils.NamedPreparer, _ *zap.Logger, modelPlanID uuid.UUID, ...) (*models.PlanTask, error)
- func PlanTaskGetByModelPlanIDs(np sqlutils.NamedPreparer, _ *zap.Logger, modelPlanIDs []uuid.UUID) ([]*models.PlanTask, error)
- func PlanTaskGetModelPlanIDsDueForPrepareForClearance(np sqlutils.NamedPreparer, _ *zap.Logger, triggerThreshold time.Time) ([]*uuid.UUID, error)
- func PlanTaskUpdateStateByKey(np sqlutils.NamedPreparer, _ *zap.Logger, modelPlanID uuid.UUID, ...) (*models.PlanTaskWithPreviousState, error)
- func PlanTimelineClearApplicationDatesByModelPlanID(np sqlutils.NamedPreparer, logger *zap.Logger, modelPlanID uuid.UUID, ...) (*models.PlanTimeline, error)
- func PlanTimelineCreate(np sqlutils.NamedPreparer, logger *zap.Logger, ...) (*models.PlanTimeline, error)
- func PlanTimelineGetByID(np sqlutils.NamedPreparer, _ *zap.Logger, id uuid.UUID) (*models.PlanTimeline, error)
- func PlanTimelineGetByModelPlanID(np sqlutils.NamedPreparer, modelPlanID uuid.UUID) (*models.PlanTimeline, error)
- func PlanTimelineGetByModelPlanIDLoader(np sqlutils.NamedPreparer, _ *zap.Logger, modelPlanIDs []uuid.UUID) ([]*models.PlanTimeline, error)
- func PlanTimelineUpdate(np sqlutils.NamedPreparer, logger *zap.Logger, ...) (*models.PlanTimeline, error)
- func ReadyForClearanceGetByModelPlanID(np sqlutils.NamedPreparer, _ *zap.Logger, modelPlanID uuid.UUID) (*models.PrepareForClearanceResponse, error)
- func SuggestedWaiverCreate(np sqlutils.NamedPreparer, _ *zap.Logger, sw *models.SuggestedWaiver) (*models.SuggestedWaiver, error)
- func SuggestedWaiverGetByID(np sqlutils.NamedPreparer, _ *zap.Logger, id uuid.UUID) (*models.SuggestedWaiver, error)
- func SuggestedWaiverGetByModelPlanIDLoader(np sqlutils.NamedPreparer, _ *zap.Logger, modelPlanIDs []uuid.UUID) ([]*models.SuggestedWaiver, error)
- func TagCollectionCreate(np sqlutils.NamedPreparer, _ *zap.Logger, tags []*models.Tag, ...) ([]*models.Tag, error)
- func TagCollectionGetByContentIDAndField(np sqlutils.NamedPreparer, _ *zap.Logger, taggedTable string, ...) ([]*models.Tag, error)
- func TranslatedAuditCollectionGetByModelPlanID(np sqlutils.NamedPreparer, modelPlanID uuid.UUID, ...) ([]*models.TranslatedAudit, error)
- func TranslatedAuditCreate(np sqlutils.NamedPreparer, translatedAudit *models.TranslatedAudit) (*models.TranslatedAudit, error)
- func TranslatedAuditFieldCollectionGetByTranslatedAuditIDLoader(np sqlutils.NamedPreparer, paramTableJSON string) ([]*models.TranslatedAuditField, error)
- func TranslatedAuditFieldCreate(np sqlutils.NamedPreparer, translatedAuditField *models.TranslatedAuditField) (*models.TranslatedAuditField, error)
- func TranslatedAuditFieldCreateCollection(np sqlutils.NamedPreparer, ...) ([]*models.TranslatedAuditField, error)
- func TranslatedAuditMostRecentGetByModelPlanIDAndTableNamesLoader(np sqlutils.NamedPreparer, _ *zap.Logger, ...) ([]*models.TranslatedAuditWithFilteredView, error)
- func TranslatedAuditQueueGetByID(np sqlutils.NamedPreparer, id uuid.UUID) (*models.TranslatedAuditQueue, error)
- func TranslatedAuditQueueGetEntriesToQueue(np sqlutils.NamedPreparer) ([]*models.TranslatedAuditQueue, error)
- func TranslatedAuditQueueGetQueued(np sqlutils.NamedPreparer) ([]*models.TranslatedAuditQueue, error)
- func TranslatedAuditQueueUpdate(np sqlutils.NamedPreparer, logger logging.ILogger, ...) (*models.TranslatedAuditQueue, error)
- func UserAccountCollectionGet(np sqlutils.NamedPreparer) ([]*authentication.UserAccount, error)
- func UserAccountGetByID(np sqlutils.NamedPreparer, id uuid.UUID) (*authentication.UserAccount, error)
- func UserAccountGetByIDLOADER(np sqlutils.NamedPreparer, _ *zap.Logger, paramTableJSON string) ([]*authentication.UserAccount, error)
- func UserAccountGetByUsername(np sqlutils.NamedPreparer, username string) (*authentication.UserAccount, error)
- func UserAccountGetFollowersForModelFollowerUpdate(np sqlutils.NamedPreparer, modelPlanID uuid.UUID) ([]*models.UserAccountAndNotificationPreferences, error)
- func UserAccountGetLeadModelPlanCount(np sqlutils.NamedPreparer, userID uuid.UUID) (int, error)
- func UserAccountGetNotificationPreferencesForDataExchangeApproachMarkedComplete(np sqlutils.NamedPreparer, modelPlanID uuid.UUID) ([]*models.UserAccountAndNotificationPreferences, error)
- func UserAccountGetNotificationPreferencesForIDDOCQuestionnaireCompleted(np sqlutils.NamedPreparer, modelPlanID uuid.UUID) ([]*models.UserAccountAndNotificationPreferences, error)
- func UserAccountGetNotificationPreferencesForMTOReadyForReview(np sqlutils.NamedPreparer, modelPlanID uuid.UUID) ([]*models.UserAccountAndNotificationPreferences, error)
- func UserAccountGetNotificationPreferencesForNewTaskAdded(np sqlutils.NamedPreparer, modelPlanID uuid.UUID) ([]*models.UserAccountAndNotificationPreferences, error)
- func UserAccountGetNotificationPreferencesForTaskCompleted(np sqlutils.NamedPreparer, modelPlanID uuid.UUID) ([]*models.UserAccountAndNotificationPreferences, error)
- func UserAccountGetNotificationPreferencesForWaiverAssessmentSurveyMarkedComplete(np sqlutils.NamedPreparer, modelPlanID uuid.UUID) ([]*models.UserAccountAndNotificationPreferences, error)
- func UserAccountInsertByUsername(np sqlutils.NamedPreparer, userAccount *authentication.UserAccount) (*authentication.UserAccount, error)
- func UserAccountNotificationPreferencesNewModelPlan(np sqlutils.NamedPreparer) ([]*models.UserAccountAndNotificationPreferences, error)
- func UserAccountUpdateByUserName(np sqlutils.NamedPreparer, userAccount *authentication.UserAccount) (*authentication.UserAccount, error)
- func UserAccountsGetNotificationRecipientsForDatesChanged(np sqlutils.NamedPreparer, modelPlanID uuid.UUID) ([]*models.UserAccountAndNotificationPreferences, error)
- func UserAccountsGetNotificationRecipientsForDiscussionAdded(np sqlutils.NamedPreparer, modelPlanID uuid.UUID) ([]*models.UserAccountAndNotificationPreferences, error)
- func UserNotificationPreferencesCreate(np sqlutils.NamedPreparer, ...) (*models.UserNotificationPreferences, error)
- func UserNotificationPreferencesGetByUserID(np sqlutils.NamedPreparer, userID uuid.UUID) (*models.UserNotificationPreferences, error)
- func UserNotificationPreferencesGetByUserIDLoader(np sqlutils.NamedPreparer, paramTableJSON string) ([]*models.UserNotificationPreferences, error)
- func UserNotificationPreferencesUpdate(np sqlutils.NamedPreparer, ...) (*models.UserNotificationPreferences, error)
- func UserViewCustomizationCreate(np sqlutils.NamedPreparer, userViewCustomization *models.UserViewCustomization) (*models.UserViewCustomization, error)
- func UserViewCustomizationGetByUserID(np sqlutils.NamedPreparer, userID uuid.UUID) (*models.UserViewCustomization, error)
- func UserViewCustomizationUpdate(np sqlutils.NamedPreparer, userViewCustomization *models.UserViewCustomization) (*models.UserViewCustomization, error)
- func WaiverAssessmentSurveyCreate(np sqlutils.NamedPreparer, _ *zap.Logger, ...) (*models.WaiverAssessmentSurvey, error)
- func WaiverAssessmentSurveyGetByID(np sqlutils.NamedPreparer, _ *zap.Logger, id uuid.UUID) (*models.WaiverAssessmentSurvey, error)
- func WaiverAssessmentSurveyGetByModelPlanIDLoader(np sqlutils.NamedPreparer, _ *zap.Logger, modelPlanIDs []uuid.UUID) ([]*models.WaiverAssessmentSurvey, error)
- func WaiverAssessmentSurveyUpdate(np sqlutils.NamedPreparer, _ *zap.Logger, ...) (*models.WaiverAssessmentSurvey, error)
- func WaiverGetByID(np sqlutils.NamedPreparer, _ *zap.Logger, id uuid.UUID) (*models.Waiver, error)
- func WaiverGetByModelPlanIDLoader(np sqlutils.NamedPreparer, _ *zap.Logger, modelPlanIDs []uuid.UUID) ([]*models.Waiver, error)
- func WaiverUpsert(np sqlutils.NamedPreparer, _ *zap.Logger, waiver *models.Waiver) (*models.Waiver, error)
- func WaiverUpsertCollection(np sqlutils.NamedPreparer, _ *zap.Logger, waivers []*models.Waiver) ([]*models.Waiver, error)
- type AnalyticsType
- type DBConfig
- type IsCollaboratorKey
- type IsCollaboratorResult
- type IsFavoriteKey
- type IsFavoriteResult
- type MTOMilestoneByModelPlanAndCategoryKey
- type MTOSolutionByModelPlanIDAndFilterViewKey
- type MostRecentByModelPlanIDAndTableFilters
- type Store
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func AnalyzedAuditCreate ¶
func AnalyzedAuditCreate( np sqlutils.NamedPreparer, logger logging.ILogger, AnalyzedAudit *models.AnalyzedAudit, ) (*models.AnalyzedAudit, error)
AnalyzedAuditCreate creates and returns an AnalyzedAudit object
func AnalyzedAuditGetByDate ¶
func AnalyzedAuditGetByDate(np sqlutils.NamedPreparer, _ logging.ILogger, date time.Time) ([]*models.AnalyzedAudit, error)
AnalyzedAuditGetByDate gets and returns all AnalyzedAudits by date
func AnalyzedAuditGetByModelPlanIDAndDate ¶
func AnalyzedAuditGetByModelPlanIDAndDate( np sqlutils.NamedPreparer, _ *zap.Logger, modelPlanID uuid.UUID, date time.Time, ) (*models.AnalyzedAudit, error)
AnalyzedAuditGetByModelPlanIDAndDate gets and returns all AnalyzedAudits by modelPlanID
func AnalyzedAuditGetByModelPlanIDsAndDate ¶
func AnalyzedAuditGetByModelPlanIDsAndDate( np sqlutils.NamedPreparer, _ logging.ILogger, modelPlanIDs []uuid.UUID, date time.Time, ) ([]*models.AnalyzedAudit, error)
AnalyzedAuditGetByModelPlanIDsAndDate gets and returns all AnalyzedAudits by modelPlanIDs and date
func AnalyzedAuditGetByModelPlanIDsAndDateLoader ¶
func AnalyzedAuditGetByModelPlanIDsAndDateLoader( np sqlutils.NamedPreparer, paramTableJSON string, ) ([]*models.AnalyzedAudit, error)
AnalyzedAuditGetByModelPlanIDsAndDateLoader gets and returns all AnalyzedAudits by modelPlanIDs and date using a dataLoader
func AuditChangeCollectionByIDAndTable ¶
func AuditChangeCollectionByIDAndTable( np sqlutils.NamedPreparer, _ logging.ILogger, tableName models.TableName, primaryKey uuid.UUID, ) ([]*models.AuditChange, error)
AuditChangeCollectionByIDAndTable returns changes based on tablename and primary key from the database
func AuditChangeCollectionByIDAndTableAndField ¶
func AuditChangeCollectionByIDAndTableAndField( np sqlutils.NamedPreparer, _ logging.ILogger, tableName string, primaryKey uuid.UUID, fieldName string, sortDir models.SortDirection, ) ([]*models.AuditChange, error)
AuditChangeCollectionByIDAndTableAndField returns changes based on tablename and primary key from the database. It will only return record sets where the given field was modified. It will return all changed fields anywyas
func AuditChangeCollectionByPrimaryKeyOrForeignKeyAndDate ¶
func AuditChangeCollectionByPrimaryKeyOrForeignKeyAndDate( np sqlutils.NamedPreparer, _ logging.ILogger, primaryKey uuid.UUID, foreignKey uuid.UUID, dayToAnalyze time.Time, sortDir models.SortDirection, ) ([]*models.AuditChange, error)
AuditChangeCollectionByPrimaryKeyOrForeignKeyAndDate returns changes based on foreign key and date from the database.
func AuditChangeCollectionGetByModelPlanIDandTimeRange ¶
func AuditChangeCollectionGetByModelPlanIDandTimeRange( np sqlutils.NamedPreparer, _ *zap.Logger, modelPlanID uuid.UUID, timeStart time.Time, timeEnd time.Time, ) ([]*models.AuditChange, error)
AuditChangeCollectionGetByModelPlanIDandTimeRange gets all audit_changes associated with a Model Plan for a specific date range It joins on the foreign key field to trace every relevant change back to it's parent model_plan_id. It currently knows how to handle model_plan_id, discussion_id, operational_need_id, and solution_id. If another level of relationships is added that point back to model_plan_id, this should be updated.
func AuditChangeGetNotProcessed ¶
func AuditChangeGetNotProcessed( np sqlutils.NamedPreparer, _ zap.Logger, ) ([]*models.AuditChangeWithModelPlanID, error)
AuditChangeGetNotProcessed returns all audit changes that have yet to be processed in the processing queue
func AuditChangeWithModelPlanGetByID ¶
func AuditChangeWithModelPlanGetByID( np sqlutils.NamedPreparer, _ logging.ILogger, auditID int, ) (*models.AuditChangeWithModelPlanID, error)
func CTATRequestAdminUpdate ¶
func CTATRequestAdminUpdate(np sqlutils.NamedPreparer, request *models.CTATRequest) (*models.CTATRequest, error)
CTATRequestAdminUpdate updates admin-managed CTAT request fields.
func CTATRequestCreate ¶
func CTATRequestCreate(np sqlutils.NamedPreparer, request *models.CTATRequest) (*models.CTATRequest, error)
CTATRequestCreate creates a CTAT request row.
func CTATRequestDocumentCreate ¶
func CTATRequestDocumentCreate( np sqlutils.NamedPreparer, doc *models.CTATRequestDocument, ) (*models.CTATRequestDocument, error)
CTATRequestDocumentCreate creates a CTAT request document row.
func CTATRequestDocumentGetByCTATRequestIDLOADER ¶
func CTATRequestDocumentGetByCTATRequestIDLOADER(np sqlutils.NamedPreparer, ctatRequestIDs []uuid.UUID) ([]*models.CTATRequestDocument, error)
CTATRequestDocumentGetByCTATRequestIDLOADER returns CTAT request documents for the supplied CTAT request IDs.
func CTATRequestDocumentsUpdateVirusScanStatuses ¶
func CTATRequestDocumentsUpdateVirusScanStatuses(ctx context.Context, s3Client *s3.S3Client, documents []*models.CTATRequestDocument) error
CTATRequestDocumentsUpdateVirusScanStatuses updates virus scan fields from S3 av-status tags.
func CTATRequestGetByIDLOADER ¶
func CTATRequestGetByIDLOADER(np sqlutils.NamedPreparer, ids []uuid.UUID) ([]*models.CTATRequest, error)
CTATRequestGetByIDLOADER returns CTAT requests for the supplied request IDs.
func CTATRequestGetByRequesterIDLOADER ¶
func CTATRequestGetByRequesterIDLOADER(np sqlutils.NamedPreparer, requesterIDs []uuid.UUID) ([]*models.CTATRequest, error)
CTATRequestGetByRequesterIDLOADER returns CTAT requests for the supplied requester IDs.
func CTATRequestGetForAdminLOADER ¶
func CTATRequestGetForAdminLOADER(np sqlutils.NamedPreparer) ([]*models.CTATRequest, error)
CTATRequestGetForAdminLOADER returns CTAT requests for the admin table view.
func CTATRequestModelPlanLinkCreate ¶
func CTATRequestModelPlanLinkCreate( np sqlutils.NamedPreparer, link *models.CTATRequestModelPlanLink, ) (*models.CTATRequestModelPlanLink, error)
CTATRequestModelPlanLinkCreate creates a CTAT request model-plan link row.
func CheckIfCollaborator ¶
func CheckIfCollaborator(np sqlutils.NamedPreparer, _ *zap.Logger, principalID uuid.UUID, modelPlanID uuid.UUID) (bool, error)
CheckIfCollaborator returns true if the principal is a collaborator on a model plan.
func CheckIfCollaboratorByDiscussionID ¶
func CheckIfCollaboratorByDiscussionID( np sqlutils.NamedPreparer, _ *zap.Logger, principalID uuid.UUID, discussionID uuid.UUID, ) (bool, error)
CheckIfCollaboratorByDiscussionID returns true if the principal is a collaborator on a model plan, by the relation on the plan discussion
func ClearReadyForClearanceByModelPlanID ¶
func ClearReadyForClearanceByModelPlanID( np sqlutils.NamedPreparer, _ *zap.Logger, modelPlanID uuid.UUID, modifiedBy uuid.UUID, ) error
ClearReadyForClearanceByModelPlanID clears ready-for-clearance status on all task-list sections for a model plan.
func CommonWaiverGetByIDLoader ¶
func CommonWaiverGetByIDLoader(np sqlutils.NamedPreparer, _ *zap.Logger, ids []uuid.UUID) ([]*models.CommonWaiver, error)
CommonWaiverGetByIDLoader returns the common waivers for a slice of ids
func CommonWaiverGetByModelPlanIDLoader ¶
func CommonWaiverGetByModelPlanIDLoader(np sqlutils.NamedPreparer, _ *zap.Logger, modelPlanIDs []uuid.UUID) ([]*models.CommonWaiver, error)
CommonWaiverGetByModelPlanIDLoader returns the common waivers for a slice of model plan ids It casts a nil model plan id to UUID.nil. If model plan id is provided, it will provide contextual information such as will_use_waiver, using_reason, not_using_reason, and suggested_waiver_id. If not, those fields will be null/zero value.
func CustomTimelineDateCreate ¶
func CustomTimelineDateCreate(np sqlutils.NamedPreparer, customTimelineDate *models.CustomTimelineDate) (*models.CustomTimelineDate, error)
CustomTimelineDateCreate creates a custom timeline date.
func CustomTimelineDateDelete ¶
func CustomTimelineDateDelete(tx *sqlx.Tx, actorUserID uuid.UUID, id uuid.UUID) (*models.CustomTimelineDate, error)
CustomTimelineDateDelete deletes the custom timeline date for a given id.
func CustomTimelineDateGetByIDLoader ¶
func CustomTimelineDateGetByIDLoader(np sqlutils.NamedPreparer, ids []uuid.UUID) ([]*models.CustomTimelineDate, error)
CustomTimelineDateGetByIDLoader returns custom timeline dates for a slice of ids.
func CustomTimelineDateGetByModelPlanIDLoader ¶
func CustomTimelineDateGetByModelPlanIDLoader(np sqlutils.NamedPreparer, modelPlanIDs []uuid.UUID) ([]*models.CustomTimelineDate, error)
CustomTimelineDateGetByModelPlanIDLoader returns custom timeline dates for a slice of model plan ids.
func CustomTimelineDateUpdate ¶
func CustomTimelineDateUpdate(np sqlutils.NamedPreparer, customTimelineDate *models.CustomTimelineDate) (*models.CustomTimelineDate, error)
CustomTimelineDateUpdate updates the custom timeline date for a given id.
func CustomTimelineDateUpdateDatesByIDs ¶
func CustomTimelineDateUpdateDatesByIDs( np sqlutils.NamedPreparer, actorUserID uuid.UUID, customTimelineDateUpdates []*model.CustomTimelineDateUpdateDatesInput, ) ([]*models.CustomTimelineDate, error)
CustomTimelineDateUpdateDatesByIDs updates start and end dates for custom timeline dates by id.
func DiscussionReplyByID ¶
func DiscussionReplyByID(np sqlutils.NamedPreparer, _ *zap.Logger, id uuid.UUID) (*models.DiscussionReply, error)
DiscussionReplyByID retrieves the discussion reply for a given id
func DiscussionReplyCreate ¶
func DiscussionReplyCreate( logger *zap.Logger, reply *models.DiscussionReply, np sqlutils.NamedPreparer, ) (*models.DiscussionReply, error)
DiscussionReplyCreate creates a discussion reply the method is expected to be part of a larger transaction and does not handle committing or rolling back the transactions if the *sqlx.Tx is nil, this function will create one. The returned tx is the same as the one in the parameters.
func DiscussionReplyDelete ¶
func DiscussionReplyDelete(tx *sqlx.Tx, logger *zap.Logger, id uuid.UUID, userID uuid.UUID) (*models.DiscussionReply, error)
DiscussionReplyDelete deletes the discussion reply for a given id
func DiscussionReplyGetByDiscussionIDLOADER ¶
func DiscussionReplyGetByDiscussionIDLOADER( np sqlutils.NamedPreparer, _ *zap.Logger, paramTableJSON string, ) ([]*models.DiscussionReply, error)
DiscussionReplyGetByDiscussionIDLOADER returns the plan GeneralCharacteristics for a slice of model plan ids
func DiscussionReplyUpdate ¶
func DiscussionReplyUpdate( np sqlutils.NamedPreparer, logger *zap.Logger, reply *models.DiscussionReply, ) (*models.DiscussionReply, error)
DiscussionReplyUpdate updates a discussion reply object
func ExistingModelCollectionGet ¶
func ExistingModelCollectionGet(np sqlutils.NamedPreparer, _ *zap.Logger) ([]*models.ExistingModel, error)
ExistingModelCollectionGet returns a list of existing models
func ExistingModelGetByID ¶
func ExistingModelGetByID( np sqlutils.NamedPreparer, _ *zap.Logger, id int, ) (*models.ExistingModel, error)
ExistingModelGetByID returns the existing model for a single model plan id
func ExistingModelGetByIDLOADER ¶
func ExistingModelGetByIDLOADER( np sqlutils.NamedPreparer, _ *zap.Logger, paramTableJSON string, ) ([]*models.ExistingModel, error)
ExistingModelGetByIDLOADER returns the existing model for a slice of model plan ids
func ExistingModelLinkGetByID ¶
func ExistingModelLinkGetByID(np sqlutils.NamedPreparer, logger *zap.Logger, id uuid.UUID) (*models.ExistingModelLink, error)
ExistingModelLinkGetByID returns an an existing model link by ID
func ExistingModelLinkGetByModelPlanIDAndFieldNameLOADER ¶
func ExistingModelLinkGetByModelPlanIDAndFieldNameLOADER( np sqlutils.NamedPreparer, logger *zap.Logger, paramTableJSON string, ) ([]*models.ExistingModelLink, error)
ExistingModelLinkGetByModelPlanIDAndFieldNameLOADER returns the plan GeneralCharacteristics for a slice of model plan ids
func ExistingModelLinksUpdate ¶
func ExistingModelLinksUpdate( tx *sqlx.Tx, logger *zap.Logger, userID uuid.UUID, modelPlanID uuid.UUID, fieldName models.ExisitingModelLinkFieldType, existingModelIDs []int, currentModelPlanIDs []uuid.UUID, ) ([]*models.ExistingModelLink, error)
ExistingModelLinksUpdate creates a new links that don't yet exist, deletes ones that are no longer provided,
func GetChangesPerModelBySectionLoader ¶
func GetChangesPerModelBySectionLoader(np sqlutils.NamedPreparer, _ *zap.Logger) ([]*models.ModelChangesBySectionAnalytics, error)
func GetChangesPerModelLoader ¶
func GetChangesPerModelLoader(np sqlutils.NamedPreparer, _ *zap.Logger) ([]*models.ModelChangesAnalytics, error)
func GetChangesPerModelOtherDataLoader ¶
func GetChangesPerModelOtherDataLoader(np sqlutils.NamedPreparer, _ *zap.Logger) ([]*models.ModelChangesOtherDataAnalytics, error)
func GetDiscussionReplyDetailsForEmail ¶
func GetDiscussionReplyDetailsForEmail(np sqlutils.NamedPreparer, discussionID uuid.UUID) ([]*email.DiscussionReplyEmailContentDB, error)
GetDiscussionReplyDetailsForEmail returns Discussion replies along with user account information for each reply. It is sorted by the database with the newest replies going to oldest replies.
func GetExistingModelLinkNamesByModelPlanIDAndFieldNameLOADER ¶
func GetExistingModelLinkNamesByModelPlanIDAndFieldNameLOADER( np sqlutils.NamedPreparer, logger *zap.Logger, paramTableJSON string, ) ([]*models.ExistingModelLinks, error)
GetExistingModelLinkNamesByModelPlanIDAndFieldNameLOADER returns the plan GeneralCharacteristics for a slice of model plan ids and field Names
func GetMTOSolutionSelectedDetails ¶
func GetMTOSolutionSelectedDetails(np sqlutils.NamedPreparer, solutionID uuid.UUID) (*email.MTOSolutionSelectedDB, error)
GetMTOSolutionSelectedDetails queries the database to return information that is useful
func GetModelsByStatusLoader ¶
func GetModelsByStatusLoader(np sqlutils.NamedPreparer, _ *zap.Logger) ([]*models.ModelsByStatusAnalytics, error)
func GetMostRecentDiscussionRoleSelection ¶
func GetMostRecentDiscussionRoleSelection( np sqlutils.NamedPreparer, logger *zap.Logger, userID uuid.UUID, ) (*models.DiscussionRoleSelection, error)
GetMostRecentDiscussionRoleSelection retrieves the latest role selection for a given user
func GetNumberOfFollowersPerModelLoader ¶
func GetNumberOfFollowersPerModelLoader(np sqlutils.NamedPreparer, _ *zap.Logger) ([]*models.ModelFollowersAnalytics, error)
func GetNumberOfModelsOverTimeLoader ¶
func GetNumberOfModelsOverTimeLoader(np sqlutils.NamedPreparer, _ *zap.Logger) ([]*models.ModelCountAnalyticsOverTime, error)
func GetTotalNumberOfModelsLoader ¶
func GetTotalNumberOfModelsLoader(np sqlutils.NamedPreparer, _ *zap.Logger) ([]*models.ModelCountAnalytics, error)
func IDDOCQuestionnaireCreate ¶
func IDDOCQuestionnaireCreate(np sqlutils.NamedPreparer, _ *zap.Logger, questionnaire *models.IDDOCQuestionnaire) (*models.IDDOCQuestionnaire, error)
IDDOCQuestionnaireCreate creates a new IDDOC questionnaire
func IDDOCQuestionnaireGetByID ¶
func IDDOCQuestionnaireGetByID(np sqlutils.NamedPreparer, _ *zap.Logger, id uuid.UUID) (*models.IDDOCQuestionnaire, error)
IDDOCQuestionnaireGetByID returns the IDDOC questionnaire for a given id
func IDDOCQuestionnaireGetByIDLoader ¶
func IDDOCQuestionnaireGetByIDLoader(np sqlutils.NamedPreparer, _ *zap.Logger, ids []uuid.UUID) ([]*models.IDDOCQuestionnaire, error)
IDDOCQuestionnaireGetByIDLoader returns the IDDOC questionnaires for a slice of ids
func IDDOCQuestionnaireGetByModelPlanIDLoader ¶
func IDDOCQuestionnaireGetByModelPlanIDLoader(np sqlutils.NamedPreparer, _ *zap.Logger, modelPlanIDs []uuid.UUID) ([]*models.IDDOCQuestionnaire, error)
IDDOCQuestionnaireGetByModelPlanIDLoader returns the IDDOC questionnaire for a slice of model plan ids
func IDDOCQuestionnaireUpdate ¶
func IDDOCQuestionnaireUpdate(np sqlutils.NamedPreparer, logger *zap.Logger, questionnaire *models.IDDOCQuestionnaire) (*models.IDDOCQuestionnaire, error)
IDDOCQuestionnaireUpdate updates the IDDOC questionnaire for a given id
func KeyContactCategoryCreate ¶
func KeyContactCategoryCreate(np sqlutils.NamedPreparer, _ *zap.Logger, keyContactCategory *models.KeyContactCategory) (*models.KeyContactCategory, error)
KeyContactCategoryCreate creates a new key contact category
func KeyContactCategoryDelete ¶
func KeyContactCategoryDelete(np sqlutils.NamedPreparer, _ *zap.Logger, id uuid.UUID) (*models.KeyContactCategory, error)
KeyContactCategoryDelete deletes a key contact category
func KeyContactCategoryGetAll ¶
func KeyContactCategoryGetAll(np sqlutils.NamedPreparer, _ *zap.Logger) ([]*models.KeyContactCategory, error)
KeyContactCategoryGetAll gets all key contact categories
func KeyContactCategoryGetAllLoader ¶
func KeyContactCategoryGetAllLoader(np sqlutils.NamedPreparer, _ *zap.Logger) ([]*models.KeyContactCategory, error)
KeyContactCategoryGetAllLoader returns all key contact categories
func KeyContactCategoryGetByID ¶
func KeyContactCategoryGetByID(np sqlutils.NamedPreparer, _ *zap.Logger, id uuid.UUID) (*models.KeyContactCategory, error)
KeyContactCategoryGetByID gets a key contact category by ID
func KeyContactCategoryGetByIDsLoader ¶
func KeyContactCategoryGetByIDsLoader(np sqlutils.NamedPreparer, _ *zap.Logger, ids []uuid.UUID) ([]*models.KeyContactCategory, error)
KeyContactCategoryGetByIDsLoader returns key contact categories by IDs
func KeyContactCategoryUpdate ¶
func KeyContactCategoryUpdate(np sqlutils.NamedPreparer, _ *zap.Logger, keyContactCategory *models.KeyContactCategory) (*models.KeyContactCategory, error)
KeyContactCategoryUpdate updates a key contact category
func KeyContactCreateContact ¶
func KeyContactCreateContact(np sqlutils.NamedPreparer, _ *zap.Logger, KeyContact *models.KeyContact) (*models.KeyContact, error)
KeyContactCreateContact creates a new KeyContact in the database.
func KeyContactGetAllLoader ¶
func KeyContactGetAllLoader(np sqlutils.NamedPreparer, _ *zap.Logger) ([]*models.KeyContact, error)
KeyContactGetAllLoader returns all key contacts
func KeyContactGetByCategoryIDsLoader ¶
func KeyContactGetByCategoryIDsLoader(np sqlutils.NamedPreparer, _ *zap.Logger, ids []uuid.UUID) ([]*models.KeyContact, error)
KeyContactGetByCategoryIDsLoader returns all key contacts for the given subject category IDs
func KeyContactGetByIDsLoader ¶
func KeyContactGetByIDsLoader(np sqlutils.NamedPreparer, _ *zap.Logger, ids []uuid.UUID) ([]*models.KeyContact, error)
func KeyContactUpdateContact ¶
func KeyContactUpdateContact(np sqlutils.NamedPreparer, _ *zap.Logger, KeyContact *models.KeyContact) (*models.KeyContact, error)
func MTOCategoryAndSubCategoriesGetByModelPlanIDLoader ¶
func MTOCategoryAndSubCategoriesGetByModelPlanIDLoader(np sqlutils.NamedPreparer, _ *zap.Logger, modelPlanIDs []uuid.UUID) ([]*models.MTOCategory, error)
MTOCategoryAndSubCategoriesGetByModelPlanIDLoader returns all mto categories for a slice of model plan ids
func MTOCategoryCreate ¶
func MTOCategoryCreate(np sqlutils.NamedPreparer, _ *zap.Logger, MTOCategory *models.MTOCategory) (*models.MTOCategory, error)
MTOCategoryCreate creates a new MTOCategory in the database
func MTOCategoryCreateAllowConflicts ¶
func MTOCategoryCreateAllowConflicts(np sqlutils.NamedPreparer, _ *zap.Logger, MTOCategory *models.MTOCategory) (*models.MTOCategoryWithNewlyInsertedStatus, error)
MTOCategoryCreateAllowConflicts creates a new MTOCategory in the database, but in the case of a conflict, instead just returns the conflicting row (and doesn't return an error) In all other ways, it is effectively equivalent to MTOCategoryCreate
func MTOCategoryDelete ¶
MTOCategoryDelete deletes an existing MTOCategory from the database
func MTOCategoryGetByID ¶
func MTOCategoryGetByID(np sqlutils.NamedPreparer, _ *zap.Logger, id uuid.UUID) (*models.MTOCategory, error)
MTOCategoryGetByID returns an existing MTOCategory from the database
func MTOCategoryGetByIDLoader ¶
func MTOCategoryGetByIDLoader(np sqlutils.NamedPreparer, _ *zap.Logger, ids []uuid.UUID) ([]*models.MTOCategory, error)
MTOCategoryGetByIDLoader returns all categories by the provided
func MTOCategoryGetByModelPlanIDLoader ¶
func MTOCategoryGetByModelPlanIDLoader(np sqlutils.NamedPreparer, _ *zap.Logger, modelPlanIDs []uuid.UUID) ([]*models.MTOCategory, error)
MTOCategoryGetByModelPlanIDLoader returns all top level categories for a slice of model plan ids
func MTOCategoryUpdate ¶
func MTOCategoryUpdate(np sqlutils.NamedPreparer, _ *zap.Logger, MTOCategory *models.MTOCategory) (*models.MTOCategory, error)
MTOCategoryUpdate updates a new MTOCategory in the database
func MTOCommonMilestoneArchive ¶
func MTOCommonMilestoneArchive( np sqlutils.TransactionPreparer, logger *zap.Logger, id uuid.UUID, actorUserID uuid.UUID, ) (*models.MTOCommonMilestone, error)
MTOCommonMilestoneArchive marks a common milestone as archived, removes its library/template references, and preserves already-applied model plan milestones.
func MTOCommonMilestoneCreate ¶
func MTOCommonMilestoneCreate( np sqlutils.TransactionPreparer, name string, description string, categoryName string, subCategoryName *string, facilitatedByRole []models.MTOFacilitator, facilitatedByOther *string, commonSolutions []models.MTOCommonSolutionKey, actorUserID uuid.UUID, ) (*models.MTOCommonMilestone, error)
MTOCommonMilestoneCreate creates a common milestone library row and its common solution links.
func MTOCommonMilestoneGetByIDLoader ¶
func MTOCommonMilestoneGetByIDLoader(np sqlutils.NamedPreparer, _ *zap.Logger, ids []uuid.UUID) ([]*models.MTOCommonMilestone, error)
MTOCommonMilestoneGetByIDLoader returns all common milestones for a slice of milestone IDs
func MTOCommonMilestoneGetByModelPlanIDLoader ¶
func MTOCommonMilestoneGetByModelPlanIDLoader(np sqlutils.NamedPreparer, _ *zap.Logger, modelPlanIDs []uuid.UUID) ([]*models.MTOCommonMilestone, error)
MTOCommonMilestoneGetByModelPlanIDLoader returns all common milestones, with the context of the model plan id to determine if it was added or not if model plan id is null, contextual data will show up as false (is_added, is_suggested)
func MTOCommonMilestoneGetCommonCategories ¶
func MTOCommonMilestoneGetCommonCategories(np sqlutils.NamedPreparer, _ *zap.Logger) ([]*models.CommonCategory, error)
MTOCommonMilestoneGetCommonCategories returns deduplicated, alphabetized common categories. The source data currently comes from the mto_template_category table hierarchy.
func MTOCommonMilestoneUpdate ¶
func MTOCommonMilestoneUpdate( np sqlutils.TransactionPreparer, commonMilestone *models.MTOCommonMilestone, commonSolutions []models.MTOCommonSolutionKey, actorUserID uuid.UUID, ) (*models.MTOCommonMilestone, error)
MTOCommonMilestoneUpdate updates a common milestone library row and optionally replaces its common solution links.
func MTOCommonSolutionContactGetByCommonSolutionKeyLoader ¶
func MTOCommonSolutionContactGetByCommonSolutionKeyLoader(np sqlutils.NamedPreparer, _ *zap.Logger, keys []models.MTOCommonSolutionKey) ([]*models.MTOCommonSolutionContact, error)
MTOCommonSolutionContactGetByCommonSolutionKeyLoader returns a list of common solution contacts associated with
func MTOCommonSolutionContactGetByIDsLoader ¶
func MTOCommonSolutionContactGetByIDsLoader(np sqlutils.NamedPreparer, _ *zap.Logger, ids []uuid.UUID) ([]*models.MTOCommonSolutionContact, error)
func MTOCommonSolutionContactUnsetPrimaryContactByKey ¶
func MTOCommonSolutionContactUnsetPrimaryContactByKey(np sqlutils.NamedPreparer, _ *zap.Logger, existingContact *models.MTOCommonSolutionContact) error
MTOCommonSolutionContactUnsetPrimaryContactByKey unsets the primary contact for a given common solution key.
func MTOCommonSolutionContractorGetByCommonSolutionKeyLoader ¶
func MTOCommonSolutionContractorGetByCommonSolutionKeyLoader(np sqlutils.NamedPreparer, _ *zap.Logger, keys []models.MTOCommonSolutionKey) ([]*models.MTOCommonSolutionContractor, error)
MTOCommonSolutionContractorGetByCommonSolutionKeyLoader returns a list of contractors associated with the given keys.
func MTOCommonSolutionContractorGetByIDLoader ¶
func MTOCommonSolutionContractorGetByIDLoader(np sqlutils.NamedPreparer, _ *zap.Logger, ids []uuid.UUID) ([]*models.MTOCommonSolutionContractor, error)
MTOCommonSolutionContractorGetByIDLoader returns a list of contractors associated with the given keys.
func MTOCommonSolutionCreateContact ¶
func MTOCommonSolutionCreateContact(np sqlutils.NamedPreparer, _ *zap.Logger, MTOCommonSolutionContact *models.MTOCommonSolutionContact) (*models.MTOCommonSolutionContact, error)
MTOCommonSolutionCreateContact creates a new MTOCommonSolutionContact in the database.
func MTOCommonSolutionCreateContractor ¶
func MTOCommonSolutionCreateContractor(np sqlutils.NamedPreparer, _ *zap.Logger, contractor *models.MTOCommonSolutionContractor) (*models.MTOCommonSolutionContractor, error)
MTOCommonSolutionCreateContractor creates a new MTOCommonSolutionContractor in the database.
func MTOCommonSolutionCreateSystemOwner ¶
func MTOCommonSolutionCreateSystemOwner(np sqlutils.NamedPreparer, _ *zap.Logger, systemOwner *models.MTOCommonSolutionSystemOwner) (*models.MTOCommonSolutionSystemOwner, error)
MTOCommonSolutionCreateSystemOwner creates a new MTOCommonSolutionSystemOwner in the database.
func MTOCommonSolutionDeleteContractorByID ¶
func MTOCommonSolutionDeleteContractorByID(tx *sqlx.Tx, actorUserID uuid.UUID, _ *zap.Logger, id uuid.UUID) (*models.MTOCommonSolutionContractor, error)
MTOCommonSolutionDeleteContractorByID deletes a contractor by its ID.
func MTOCommonSolutionGetByCommonMilestoneIDLoader ¶
func MTOCommonSolutionGetByCommonMilestoneIDLoader(np sqlutils.NamedPreparer, _ *zap.Logger, mtoCommonMilestoneIDs []uuid.UUID) ([]*models.MTOCommonSolution, error)
MTOCommonSolutionGetByCommonMilestoneIDLoader returns all common solutions associated with a Common Milestone ID
func MTOCommonSolutionGetByIDLoader ¶
func MTOCommonSolutionGetByIDLoader(np sqlutils.NamedPreparer, _ *zap.Logger, ids []uuid.UUID) ([]*models.MTOCommonSolution, error)
MTOCommonSolutionGetByIDLoader returns all MTO common solutions associated by a list of ids
func MTOCommonSolutionGetByKeyLoader ¶
func MTOCommonSolutionGetByKeyLoader(np sqlutils.NamedPreparer, _ *zap.Logger, keys []models.MTOCommonSolutionKey) ([]*models.MTOCommonSolution, error)
MTOCommonSolutionGetByKeyLoader returns all Common Solutions associated by a list of keys
func MTOCommonSolutionGetByModelPlanIDLoader ¶
func MTOCommonSolutionGetByModelPlanIDLoader(np sqlutils.NamedPreparer, _ *zap.Logger, modelPlanIDs []uuid.UUID) ([]*models.MTOCommonSolution, error)
MTOCommonSolutionGetByModelPlanIDLoader returns all common solutions, with the context of the model plan id to determine if it was added or not if model plan id is null, contextual data will show up as false (is_added, is_suggested)
func MTOCommonSolutionGetContactByID ¶
func MTOCommonSolutionGetContactByID(np sqlutils.NamedPreparer, _ *zap.Logger, id uuid.UUID) (*models.MTOCommonSolutionContact, error)
func MTOCommonSolutionGetContractorByID ¶
func MTOCommonSolutionGetContractorByID(np sqlutils.NamedPreparer, _ *zap.Logger, id uuid.UUID) (*models.MTOCommonSolutionContractor, error)
MTOCommonSolutionGetContractorByID fetches a contractor by its ID.
func MTOCommonSolutionSystemOwnerDeleteByID ¶
func MTOCommonSolutionSystemOwnerDeleteByID(tx *sqlx.Tx, actorUserID uuid.UUID, _ *zap.Logger, id uuid.UUID) (*models.MTOCommonSolutionSystemOwner, error)
MTOCommonSolutionSystemOwnerDeleteByID deletes a system owner by its ID.
func MTOCommonSolutionSystemOwnerGetByCommonSolutionKeyLoader ¶
func MTOCommonSolutionSystemOwnerGetByCommonSolutionKeyLoader(np sqlutils.NamedPreparer, _ *zap.Logger, keys []models.MTOCommonSolutionKey) ([]*models.MTOCommonSolutionSystemOwner, error)
MTOCommonSolutionSystemOwnerGetByCommonSolutionKeyLoader returns a list of system owners associated with the given keys.
func MTOCommonSolutionSystemOwnerGetByID ¶
func MTOCommonSolutionSystemOwnerGetByID(np sqlutils.NamedPreparer, _ *zap.Logger, id uuid.UUID) (*models.MTOCommonSolutionSystemOwner, error)
MTOCommonSolutionSystemOwnerGetByID fetches a system owner by its ID.
func MTOCommonSolutionSystemOwnerGetByIDLoader ¶
func MTOCommonSolutionSystemOwnerGetByIDLoader(np sqlutils.NamedPreparer, _ *zap.Logger, ids []uuid.UUID) ([]*models.MTOCommonSolutionSystemOwner, error)
MTOCommonSolutionSystemOwnerGetByIDLoader returns a list of system owners associated with the given IDs.
func MTOCommonSolutionSystemOwnerUpdate ¶
func MTOCommonSolutionSystemOwnerUpdate(np sqlutils.NamedPreparer, _ *zap.Logger, systemOwner *models.MTOCommonSolutionSystemOwner) (*models.MTOCommonSolutionSystemOwner, error)
MTOCommonSolutionSystemOwnerUpdate updates an existing system owner.
func MTOCommonSolutionUpdateContact ¶
func MTOCommonSolutionUpdateContact(np sqlutils.NamedPreparer, _ *zap.Logger, MTOCommonSolutionContact *models.MTOCommonSolutionContact) (*models.MTOCommonSolutionContact, error)
func MTOCommonSolutionUpdateContractor ¶
func MTOCommonSolutionUpdateContractor(np sqlutils.NamedPreparer, _ *zap.Logger, contractor *models.MTOCommonSolutionContractor) (*models.MTOCommonSolutionContractor, error)
MTOCommonSolutionUpdateContractor updates an existing contractor.
func MTOInfoCreate ¶
func MTOInfoCreate(np sqlutils.NamedPreparer, _ *zap.Logger, MTOInfo *models.MTOInfo) (*models.MTOInfo, error)
MTOInfoCreate creates a new MTOInfo in the database
func MTOInfoGetByModelPlanIDLoader ¶
func MTOInfoGetByModelPlanIDLoader(np sqlutils.NamedPreparer, _ *zap.Logger, modelPlanIDs []uuid.UUID) ([]*models.MTOInfo, error)
MTOInfoGetByModelPlanIDLoader returns all mto info records for a slice of model plan ids
func MTOInfoUpdate ¶
func MTOInfoUpdate(np sqlutils.NamedPreparer, _ *zap.Logger, MTOInfo *models.MTOInfo) (*models.MTOInfo, error)
MTOInfoUpdate updates a new MTOInfo in the database
func MTOMilestoneCreate ¶
func MTOMilestoneCreate(np sqlutils.NamedPreparer, _ *zap.Logger, MTOMilestone *models.MTOMilestone) (*models.MTOMilestone, error)
MTOMilestoneCreate creates a new MTOMilestone in the database
NOTE: This method is used for creating both Custom and Library-sourced (Common) milestones. It WILL return an error if you try to create one that has both custom info (like a `name`) and a CommonMilestoneID This is controlled not by application code, but by constraints initially added in this migration: migrations/V185__Add_MTO_Milestone.sql
func MTOMilestoneCreateAllowConflicts ¶
func MTOMilestoneCreateAllowConflicts(np sqlutils.NamedPreparer, _ *zap.Logger, MTOMilestone *models.MTOMilestone) (*models.MTOMilestoneWithNewlyInsertedStatus, error)
MTOMilestoneCreateAllowConflicts creates a new MTOMilestone in the database, allowing conflicts If a milestone with the same model_plan_id and mto_common_milestone_id already exists, it returns the existing one
func MTOMilestoneDelete ¶
func MTOMilestoneDelete(tx *sqlx.Tx, actorUserID uuid.UUID, _ *zap.Logger, milestoneID uuid.UUID) error
MTOMilestoneDelete deletes an MTOMilestone in the database
func MTOMilestoneGetByID ¶
func MTOMilestoneGetByID(np sqlutils.NamedPreparer, _ *zap.Logger, id uuid.UUID) (*models.MTOMilestone, error)
MTOMilestoneGetByID returns an existing MTOMilestone from the database
func MTOMilestoneGetByIDLoader ¶
func MTOMilestoneGetByIDLoader(np sqlutils.NamedPreparer, _ *zap.Logger, ids []uuid.UUID) ([]*models.MTOMilestone, error)
MTOMilestoneGetByIDLoader returns all milestones by the provided ids
func MTOMilestoneGetByModelPlanIDAndCategoryIDLoader ¶
func MTOMilestoneGetByModelPlanIDAndCategoryIDLoader(np sqlutils.NamedPreparer, _ *zap.Logger, keys []MTOMilestoneByModelPlanAndCategoryKey) ([]*models.MTOMilestone, error)
MTOMilestoneGetByModelPlanIDAndCategoryIDLoader returns mto milestones that are associated with a model plan id and category
func MTOMilestoneGetByModelPlanIDLoader ¶
func MTOMilestoneGetByModelPlanIDLoader(np sqlutils.NamedPreparer, _ *zap.Logger, modelPlanIDs []uuid.UUID) ([]*models.MTOMilestone, error)
MTOMilestoneGetByModelPlanIDLoader returns all top level categories for a slice of model plan ids
func MTOMilestoneGetByModelPlanIDNoLinkedSolutionLoader ¶
func MTOMilestoneGetByModelPlanIDNoLinkedSolutionLoader(np sqlutils.NamedPreparer, _ *zap.Logger, modelPlanIDs []uuid.UUID) ([]*models.MTOMilestone, error)
MTOMilestoneGetByModelPlanIDNoLinkedSolutionLoader returns all milestones by a model plan ID that are not linked to a solution
func MTOMilestoneGetBySolutionIDLoader ¶
func MTOMilestoneGetBySolutionIDLoader(np sqlutils.NamedPreparer, _ *zap.Logger, solutionIDs []uuid.UUID) ([]*models.MTOMilestoneWithSolutionID, error)
func MTOMilestoneNoteCreate ¶
func MTOMilestoneNoteCreate(np sqlutils.NamedPreparer, _ *zap.Logger, MTOMilestoneNote *models.MTOMilestoneNote) (*models.MTOMilestoneNote, error)
func MTOMilestoneNoteDelete ¶
func MTOMilestoneNoteGetByIDLoader ¶
func MTOMilestoneNoteGetByIDLoader(np sqlutils.NamedPreparer, _ *zap.Logger, ids []uuid.UUID) ([]*models.MTOMilestoneNote, error)
MTOMilestoneNoteGetByIDLoader returns all milestone notes by the provided ids
func MTOMilestoneNoteGetByMilestoneIDLoader ¶
func MTOMilestoneNoteGetByMilestoneIDLoader(np sqlutils.NamedPreparer, _ *zap.Logger, milestoneIDs []uuid.UUID) ([]*models.MTOMilestoneNote, error)
func MTOMilestoneNoteUpdate ¶
func MTOMilestoneNoteUpdate(np sqlutils.NamedPreparer, _ *zap.Logger, MTOMilestoneNote *models.MTOMilestoneNote) (*models.MTOMilestoneNote, error)
func MTOMilestoneSolutionLinkCreate ¶
func MTOMilestoneSolutionLinkCreate( np sqlutils.NamedPreparer, _ *zap.Logger, mtoMilestoneSolutionLink *models.MTOMilestoneSolutionLink, ) (*models.MTOMilestoneSolutionLink, error)
MTOMilestoneSolutionLinkCreate creates a new MTO Milestone-Solution link in the database
func MTOMilestoneSolutionLinkGetByMilestoneID ¶
func MTOMilestoneSolutionLinkGetByMilestoneID( np sqlutils.NamedPreparer, _ *zap.Logger, milestoneID uuid.UUID, ) ([]*models.MTOMilestoneSolutionLink, error)
MTOMilestoneSolutionLinkGetByMilestoneID returns all MTO Milestone-Solution links for a given Milestone ID
func MTOMilestoneSolutionLinkMergeSolutionsToMilestones ¶
func MTOMilestoneSolutionLinkMergeSolutionsToMilestones( tx *sqlx.Tx, _ *zap.Logger, milestoneID uuid.UUID, solutionIDs []uuid.UUID, actorID uuid.UUID, ) ([]*models.MTOSolution, error)
MTOMilestoneSolutionLinkMergeSolutionsToMilestones takes a list of solution ids, and will merge them to a milestone the end result is that solutions not included here have their link removed
func MTOMilestoneSolutionLinkMilestonesToSolution ¶
func MTOMilestoneSolutionLinkMilestonesToSolution( tx *sqlx.Tx, logger *zap.Logger, solutionID uuid.UUID, milestoneIDs []uuid.UUID, actorID uuid.UUID, ) ([]*models.MTOMilestone, error)
MTOMilestoneSolutionLinkMilestonesToSolution takes a list of milestone IDs and links them to a solution. The end result is that milestones not included here are unlinked from the solution.
func MTOMilestoneUpdate ¶
func MTOMilestoneUpdate(np sqlutils.NamedPreparer, _ *zap.Logger, MTOMilestone *models.MTOMilestone) (*models.MTOMilestone, error)
MTOMilestoneUpdate updates a new MTOMilestone in the database
NOTE: This method is used for updating both Custom and Library-sourced (Common) milestones. It WILL return an error if you try to update one that has both custom info (like a `name`) and a CommonMilestoneID This is controlled not by application code, but by constraints initially added in this migration: migrations/V185__Add_MTO_Milestone.sql
func MTOSolutionCreate ¶
func MTOSolutionCreate( np sqlutils.NamedPreparer, _ *zap.Logger, mtoSolution *models.MTOSolution, ) (*models.MTOSolution, error)
MTOSolutionCreate creates a new MTOSolution in the database
func MTOSolutionCreateCommonAllowConflictsSQL ¶
func MTOSolutionCreateCommonAllowConflictsSQL( np sqlutils.NamedPreparer, _ *zap.Logger, commonSolutionKeys []models.MTOCommonSolutionKey, modelPlanID uuid.UUID, createdBy uuid.UUID, ) ([]*models.MTOSolutionWithNewlyInsertedStatus, error)
MTOSolutionCreateCommonAllowConflictsSQL takes a list of common solution keys for a model plan id, and inserts ones that don't exist it will return existing data, or newly inserted data
func MTOSolutionDelete ¶
func MTOSolutionGetByCommonMilestoneIDLoader ¶
func MTOSolutionGetByCommonMilestoneIDLoader( np sqlutils.NamedPreparer, _ *zap.Logger, mtoCommonMilestoneIDs []uuid.UUID, ) ([]*models.MTOCommonSolution, error)
MTOSolutionGetByCommonMilestoneIDLoader returns all solutions associated with a Common Milestone ID
func MTOSolutionGetByIDLoader ¶
func MTOSolutionGetByIDLoader(np sqlutils.NamedPreparer, _ *zap.Logger, ids []uuid.UUID) ([]*models.MTOSolution, error)
MTOSolutionGetByIDLoader returns solutions by ID
func MTOSolutionGetByKeyLoader ¶
func MTOSolutionGetByKeyLoader(np sqlutils.NamedPreparer, _ *zap.Logger, keys []models.MTOCommonSolutionKey) ([]*models.MTOSolution, error)
MTOSolutionGetByKeyLoader returns all solutions associated by a list of keys
func MTOSolutionGetByMilestoneIDLoader ¶
func MTOSolutionGetByMilestoneIDLoader( np sqlutils.NamedPreparer, _ *zap.Logger, milestoneIDs []uuid.UUID, ) ([]*models.MTOSolutionWithMilestoneID, error)
func MTOSolutionGetByModelPlanIDAndFilterViewLoader ¶
func MTOSolutionGetByModelPlanIDAndFilterViewLoader(np sqlutils.NamedPreparer, _ *zap.Logger, keys []MTOSolutionByModelPlanIDAndFilterViewKey) ([]*models.MTOSolutionWithModelFilterView, error)
MTOSolutionGetByModelPlanIDAndFilterViewLoader returns all solutions associated with a model plan id and filter view
func MTOSolutionGetByModelPlanIDLoader ¶
func MTOSolutionGetByModelPlanIDLoader(np sqlutils.NamedPreparer, _ *zap.Logger, modelPlanIDs []uuid.UUID) ([]*models.MTOSolution, error)
MTOSolutionGetByModelPlanIDLoader returns all solutions, with the context of the model plan id to determine if it was added or not if model plan id is null, contextual data will show up as false (is_added, is_suggested)
func MTOSolutionUpdate ¶
func MTOSolutionUpdate( np sqlutils.NamedPreparer, _ *zap.Logger, mtoSolution *models.MTOSolution, ) (*models.MTOSolution, error)
MTOSolutionUpdate updates a new MTOSolution in the database
func MTOSubcategoryGetByParentIDLoader ¶
func MTOSubcategoryGetByParentIDLoader(np sqlutils.NamedPreparer, _ *zap.Logger, parentIDs []uuid.UUID) ([]*models.MTOSubcategory, error)
MTOSubcategoryGetByParentIDLoader returns the categories that are sub categories for a slice of category ids Note, this returns the object as a subcategory, but it is the same table
func MTOSuggestedMilestoneReasonGetByMTOSuggestedMilestoneIDLoader ¶
func MTOSuggestedMilestoneReasonGetByMTOSuggestedMilestoneIDLoader( np sqlutils.NamedPreparer, _ *zap.Logger, ids []uuid.UUID, ) ([]*models.MTOSuggestedMilestoneReason, error)
MTOSuggestedMilestoneReasonGetByMTOSuggestedMilestoneIDLoader returns all suggestion reasons for a slice of mto_suggested_milestone IDs.
func MTOTemplateCategoryGetByIDLoader ¶
func MTOTemplateCategoryGetByIDLoader(np sqlutils.NamedPreparer, _ *zap.Logger, ids []uuid.UUID) ([]*models.MTOTemplateCategory, error)
MTOTemplateCategoryGetByIDLoader returns template categories by ID
func MTOTemplateCategoryGetByTemplateIDLoader ¶
func MTOTemplateCategoryGetByTemplateIDLoader(np sqlutils.NamedPreparer, _ *zap.Logger, templateIDs []uuid.UUID) ([]*models.MTOTemplateCategory, error)
MTOTemplateCategoryGetByTemplateIDLoader returns template categories by template ID
func MTOTemplateGetAllLoader ¶
func MTOTemplateGetAllLoader(np sqlutils.NamedPreparer, _ *zap.Logger) ([]*models.MTOTemplate, error)
MTOTemplateGetAllLoader returns all templates
func MTOTemplateGetByIDLoader ¶
func MTOTemplateGetByIDLoader(np sqlutils.NamedPreparer, _ *zap.Logger, ids []uuid.UUID) ([]*models.MTOTemplate, error)
MTOTemplateGetByIDLoader returns templates by ID
func MTOTemplateGetByKeyLoader ¶
func MTOTemplateGetByKeyLoader(np sqlutils.NamedPreparer, _ *zap.Logger, keys []models.MTOTemplateKey) ([]*models.MTOTemplate, error)
MTOTemplateGetByKeyLoader returns templates by template key
func MTOTemplateGetByModelPlanIDLoader ¶
func MTOTemplateGetByModelPlanIDLoader(np sqlutils.NamedPreparer, _ *zap.Logger, modelPlanIDs []uuid.UUID) ([]*models.MTOTemplate, error)
MTOTemplateGetByModelPlanIDLoader returns all templates associated with a model plan ID
func MTOTemplateMilestoneGetByCategoryIDLoader ¶
func MTOTemplateMilestoneGetByCategoryIDLoader(np sqlutils.NamedPreparer, _ *zap.Logger, categoryIDs []uuid.UUID) ([]*models.MTOTemplateMilestone, error)
MTOTemplateMilestoneGetByCategoryIDLoader returns template milestones by category ID
func MTOTemplateMilestoneGetByIDLoader ¶
func MTOTemplateMilestoneGetByIDLoader(np sqlutils.NamedPreparer, _ *zap.Logger, ids []uuid.UUID) ([]*models.MTOTemplateMilestone, error)
MTOTemplateMilestoneGetByIDLoader returns template milestones by ID
func MTOTemplateMilestoneGetBySolutionIDLoader ¶
func MTOTemplateMilestoneGetBySolutionIDLoader(np sqlutils.NamedPreparer, _ *zap.Logger, solutionIDs []uuid.UUID) ([]*models.MTOTemplateMilestone, error)
MTOTemplateMilestoneGetBySolutionIDLoader returns template milestones by solution ID
func MTOTemplateMilestoneGetByTemplateIDLoader ¶
func MTOTemplateMilestoneGetByTemplateIDLoader(np sqlutils.NamedPreparer, _ *zap.Logger, templateIDs []uuid.UUID) ([]*models.MTOTemplateMilestone, error)
MTOTemplateMilestoneGetByTemplateIDLoader returns template milestones by template ID
func MTOTemplateMilestoneSolutionLinkGetByTemplateIDLoader ¶
func MTOTemplateMilestoneSolutionLinkGetByTemplateIDLoader(np sqlutils.NamedPreparer, _ *zap.Logger, templateIDs []uuid.UUID) ([]*models.MTOTemplateMilestoneSolutionLink, error)
MTOTemplateMilestoneSolutionLinkGetByTemplateIDLoader returns milestone-solution links by template ID
func MTOTemplateSolutionGetByIDLoader ¶
func MTOTemplateSolutionGetByIDLoader(np sqlutils.NamedPreparer, _ *zap.Logger, ids []uuid.UUID) ([]*models.MTOTemplateSolution, error)
MTOTemplateSolutionGetByIDLoader returns template solutions by ID
func MTOTemplateSolutionGetByMilestoneIDLoader ¶
func MTOTemplateSolutionGetByMilestoneIDLoader(np sqlutils.NamedPreparer, _ *zap.Logger, milestoneIDs []uuid.UUID) ([]*models.MTOTemplateSolution, error)
Add to mto_template_solution.go
func MTOTemplateSolutionGetByTemplateIDLoader ¶
func MTOTemplateSolutionGetByTemplateIDLoader(np sqlutils.NamedPreparer, _ *zap.Logger, templateIDs []uuid.UUID) ([]*models.MTOTemplateSolution, error)
MTOTemplateSolutionGetByTemplateIDLoader returns template solutions by template ID
func MTOTemplateSubCategoryGetByCategoryIDLoader ¶
func MTOTemplateSubCategoryGetByCategoryIDLoader(np sqlutils.NamedPreparer, _ *zap.Logger, categoryIDs []uuid.UUID) ([]*models.MTOTemplateSubCategory, error)
MTOTemplateSubCategoryGetByCategoryIDLoader returns template subcategories by category ID
func MTOTemplateSubCategoryGetByIDLoader ¶
func MTOTemplateSubCategoryGetByIDLoader(np sqlutils.NamedPreparer, _ *zap.Logger, ids []uuid.UUID) ([]*models.MTOTemplateSubCategory, error)
MTOTemplateSubCategoryGetByIDLoader returns template subcategories by ID
func MTOTemplateSubCategoryGetByTemplateIDLoader ¶
func MTOTemplateSubCategoryGetByTemplateIDLoader(np sqlutils.NamedPreparer, _ *zap.Logger, templateIDs []uuid.UUID) ([]*models.MTOTemplateSubCategory, error)
func ModelPlanCollection ¶
func ModelPlanCollection(np sqlutils.NamedPreparer, logger logging.ILogger, archived bool) ([]*models.ModelPlan, error)
ModelPlanCollection returns a list of all model plans (whether or not you're a collaborator)
func ModelPlanCollectionCollaboratorOnly ¶
func ModelPlanCollectionCollaboratorOnly( np sqlutils.NamedPreparer, logger *zap.Logger, archived bool, userID uuid.UUID, ) ([]*models.ModelPlan, error)
ModelPlanCollectionCollaboratorOnly returns a list of all model plans for which the user_accountID supplied is a collaborator.
func ModelPlanCollectionFavorited ¶
func ModelPlanCollectionFavorited( np sqlutils.NamedPreparer, logger *zap.Logger, archived bool, userID uuid.UUID, ) ([]*models.ModelPlan, error)
ModelPlanCollectionFavorited returns a list of all model plans which are favorited by the user Note: Externally, this is called "followed" but internally we call it "favorited"
func ModelPlanCollectionNewlyCreated ¶
func ModelPlanCollectionNewlyCreated(np sqlutils.NamedPreparer, logger *zap.Logger) ([]*models.ModelPlan, error)
ModelPlanCollectionNewlyCreated returns a list of all model plans created within the last 6 months
func ModelPlanCreate ¶
func ModelPlanCreate(np sqlutils.NamedPreparer, logger *zap.Logger, plan *models.ModelPlan) (*models.ModelPlan, error)
ModelPlanCreate creates a model plan using a transaction
func ModelPlanGetByComponentGroupLoader ¶
func ModelPlanGetByComponentGroupLoader(np sqlutils.NamedPreparer, logger *zap.Logger, componentGroups []models.ComponentGroup) ([]*models.ModelPlanAndGroup, error)
ModelPlanGetByComponentGroupLoader returns model plans for multiple component group keys using a batched loader query
func ModelPlanGetByID ¶
func ModelPlanGetByID(np sqlutils.NamedPreparer, logger logging.ILogger, id uuid.UUID) (*models.ModelPlan, error)
ModelPlanGetByID returns a model plan for a given ID
func ModelPlanGetByMTOSolutionKeyLOADER ¶
func ModelPlanGetByMTOSolutionKeyLOADER(np sqlutils.NamedPreparer, _ *zap.Logger, keys []models.MTOCommonSolutionKey) ([]*models.ModelPlanAndMTOCommonSolution, error)
func ModelPlanGetByName ¶
func ModelPlanGetByName(np sqlutils.NamedPreparer, logger *zap.Logger, modelName string) (*models.ModelPlan, error)
ModelPlanGetByName returns a model plan for a given ID
func ModelPlanGetByStatuses ¶
func ModelPlanGetByStatuses(np sqlutils.NamedPreparer, logger *zap.Logger, statuses []models.ModelStatus) ([]*models.ModelPlan, error)
func ModelPlanGetTaskListStatus ¶
func ModelPlanGetTaskListStatus(np sqlutils.NamedPreparer, logger *zap.Logger, modelPlanID uuid.UUID) (models.TaskStatus, error)
func ModelPlanMTOTemplateLinkGetByIDLoader ¶
func ModelPlanMTOTemplateLinkGetByIDLoader(np sqlutils.NamedPreparer, _ *zap.Logger, ids []uuid.UUID) ([]*models.ModelPlanMTOTemplateLink, error)
ModelPlanMTOTemplateLinkGetByIDLoader returns model plan MTO template links by ID
func ModelPlanMTOTemplateLinkGetByModelPlanIDLoader ¶
func ModelPlanMTOTemplateLinkGetByModelPlanIDLoader(np sqlutils.NamedPreparer, _ *zap.Logger, modelPlanIDs []uuid.UUID) ([]*models.ModelPlanMTOTemplateLink, error)
ModelPlanMTOTemplateLinkGetByModelPlanIDLoader returns model plan MTO template links by model plan ID
func ModelPlanMTOTemplateLinkGetByTemplateIDLoader ¶
func ModelPlanMTOTemplateLinkGetByTemplateIDLoader(np sqlutils.NamedPreparer, _ *zap.Logger, templateIDs []uuid.UUID) ([]*models.ModelPlanMTOTemplateLink, error)
ModelPlanMTOTemplateLinkGetByTemplateIDLoader returns model plan MTO template links by template ID
func ModelPlanMTOTemplateLinkUpsert ¶
func ModelPlanMTOTemplateLinkUpsert(np sqlutils.NamedPreparer, _ *zap.Logger, link *models.ModelPlanMTOTemplateLink) (*models.ModelPlanMTOTemplateLink, error)
ModelPlanMTOTemplateLinkUpsert creates a new model plan MTO template link or updates an existing one
func ModelPlanUpdate ¶
func ModelPlanUpdate(np sqlutils.NamedPreparer, logger logging.ILogger, plan *models.ModelPlan) (*models.ModelPlan, error)
ModelPlanUpdate updates a model plan
func ModelPlansGetByCTATRequestIDsLOADER ¶
func ModelPlansGetByCTATRequestIDsLOADER(np sqlutils.NamedPreparer, _ *zap.Logger, ctatRequestIDs []uuid.UUID) ([]*models.ModelPlanWithCTATRequestID, error)
func NDAAgreementCreate ¶
func NDAAgreementCreate(np sqlutils.NamedPreparer, _ *zap.Logger, nda *models.NDAAgreement) (*models.NDAAgreement, error)
NDAAgreementCreate creates a new nda agreement based on an EUA
func NDAAgreementGetByUserID ¶
func NDAAgreementGetByUserID(np sqlutils.NamedPreparer, _ *zap.Logger, userID uuid.UUID) (*models.NDAAgreement, error)
NDAAgreementGetByUserID returns an NDA based on a UserID
func NDAAgreementUpdate ¶
func NDAAgreementUpdate(np sqlutils.NamedPreparer, _ *zap.Logger, nda *models.NDAAgreement) (*models.NDAAgreement, error)
NDAAgreementUpdate updates an nda agreement based on userID
func PlanBasicsCreate ¶
func PlanBasicsCreate(np sqlutils.NamedPreparer, logger *zap.Logger, basics *models.PlanBasics) (*models.PlanBasics, error)
PlanBasicsCreate creates a new plan basics
func PlanBasicsGetByID ¶
func PlanBasicsGetByID(np sqlutils.NamedPreparer, _ *zap.Logger, id uuid.UUID) (*models.PlanBasics, error)
PlanBasicsGetByID returns the plan basics for a given id
func PlanBasicsGetByModelPlanIDLoader ¶
func PlanBasicsGetByModelPlanIDLoader(np sqlutils.NamedPreparer, _ *zap.Logger, modelPlanIDs []uuid.UUID) ([]*models.PlanBasics, error)
PlanBasicsGetByModelPlanIDLoader returns the plan basics for a slice of model plan ids
func PlanBasicsUpdate ¶
func PlanBasicsUpdate(tx *sqlx.Tx, logger *zap.Logger, plan *models.PlanBasics) (*models.PlanBasics, error)
PlanBasicsUpdate updates the plan basics for a given id. When the saved model type includes MANDATORY_NATIONAL or MANDATORY_REGIONAL_OR_STATE, timeline application period dates are cleared in the same transaction.
func PlanBeneficiariesCreate ¶
func PlanBeneficiariesCreate( np sqlutils.NamedPreparer, logger *zap.Logger, b *models.PlanBeneficiaries, ) (*models.PlanBeneficiaries, error)
PlanBeneficiariesCreate creates a new plan benficiaries object
func PlanBeneficiariesGetByID ¶
func PlanBeneficiariesGetByID( np sqlutils.NamedPreparer, _ *zap.Logger, id uuid.UUID, ) (*models.PlanBeneficiaries, error)
PlanBeneficiariesGetByID returns the plan general characteristics for a given id
func PlanBeneficiariesGetByModelPlanIDLOADER ¶
func PlanBeneficiariesGetByModelPlanIDLOADER( np sqlutils.NamedPreparer, _ *zap.Logger, paramTableJSON string, ) ([]*models.PlanBeneficiaries, error)
PlanBeneficiariesGetByModelPlanIDLOADER returns the plan GeneralCharacteristics for a slice of model plan ids
func PlanBeneficiariesUpdate ¶
func PlanBeneficiariesUpdate( np sqlutils.NamedPreparer, logger *zap.Logger, b *models.PlanBeneficiaries, ) (*models.PlanBeneficiaries, error)
PlanBeneficiariesUpdate updates the plan general characteristics for a given id
func PlanCRCreate ¶
func PlanCRCreate(np sqlutils.NamedPreparer, logger *zap.Logger, planCR *models.PlanCR) (*models.PlanCR, error)
PlanCRCreate creates returns a plan_cr_tdl object
func PlanCRDelete ¶
func PlanCRDelete(tx *sqlx.Tx, _ *zap.Logger, id uuid.UUID, userID uuid.UUID) (*models.PlanCR, error)
PlanCRDelete deletes a plan_cr_tdl
func PlanCRGetByID ¶
PlanCRGetByID returns a plan_cr_tdl
func PlanCRUpdate ¶
func PlanCRUpdate(np sqlutils.NamedPreparer, logger *zap.Logger, planCR *models.PlanCR) (*models.PlanCR, error)
PlanCRUpdate updates and returns a plan_cr_tdl object
func PlanCRsGetByModelPlanID ¶
func PlanCRsGetByModelPlanID(np sqlutils.NamedPreparer, _ *zap.Logger, modelPlanID uuid.UUID) ([]*models.PlanCR, error)
PlanCRsGetByModelPlanID returns all plan_cr_tdls associated with a model plan
func PlanCollaboratorCreate ¶
func PlanCollaboratorCreate( np sqlutils.NamedPreparer, _ *zap.Logger, collaborator *models.PlanCollaborator, ) (*models.PlanCollaborator, error)
PlanCollaboratorCreate creates a new plan collaborator
func PlanCollaboratorDelete ¶
func PlanCollaboratorDelete( tx *sqlx.Tx, _ *zap.Logger, id uuid.UUID, userID uuid.UUID, ) (*models.PlanCollaborator, error)
PlanCollaboratorDelete deletes the plan collaborator for a given id
func PlanCollaboratorGetByID ¶
func PlanCollaboratorGetByID(np sqlutils.NamedPreparer, id uuid.UUID) (*models.PlanCollaborator, error)
PlanCollaboratorGetByID returns a plan collaborator for a given database ID, or nil if none found Note: The dataloader method should be preferred over this method.
func PlanCollaboratorGetByModelPlanID ¶
func PlanCollaboratorGetByModelPlanID( np sqlutils.NamedPreparer, _ logging.ILogger, modelPlanID uuid.UUID, ) ([]*models.PlanCollaborator, error)
PlanCollaboratorGetByModelPlanID returns a slice of plan collaborators corresponding with a model plan id
func PlanCollaboratorGetByModelPlanIDLOADER ¶
func PlanCollaboratorGetByModelPlanIDLOADER( np sqlutils.NamedPreparer, _ *zap.Logger, modelPlanIDs []uuid.UUID, ) ([]*models.PlanCollaborator, error)
PlanCollaboratorGetByModelPlanIDLOADER returns the plan collaborators for a slice of model plan ids
func PlanCollaboratorGetCountByUserID ¶
PlanCollaboratorGetCountByUserID returns the number of plan collaborators for a given user_id
func PlanCollaboratorGetIDLOADER ¶
func PlanCollaboratorGetIDLOADER( np sqlutils.NamedPreparer, ids []uuid.UUID, ) ([]*models.PlanCollaborator, error)
PlanCollaboratorGetIDLOADER returns the plan collaborators corresponding to an array of plan collaborator IDs
func PlanCollaboratorUpdate ¶
func PlanCollaboratorUpdate( np sqlutils.NamedPreparer, _ *zap.Logger, collaborator *models.PlanCollaborator, ) (*models.PlanCollaborator, error)
PlanCollaboratorUpdate updates the plan collaborator for a given id
func PlanDataExchangeApproachCreate ¶
func PlanDataExchangeApproachCreate(np sqlutils.NamedPreparer, _ *zap.Logger, approach *models.PlanDataExchangeApproach) (*models.PlanDataExchangeApproach, error)
PlanDataExchangeApproachCreate creates a new plan data exchange approach
func PlanDataExchangeApproachGetByID ¶
func PlanDataExchangeApproachGetByID(np sqlutils.NamedPreparer, _ *zap.Logger, id uuid.UUID) (*models.PlanDataExchangeApproach, error)
PlanDataExchangeApproachGetByID returns the plan data exchange approach for a given id
func PlanDataExchangeApproachGetByModelPlanIDLoader ¶
func PlanDataExchangeApproachGetByModelPlanIDLoader(np sqlutils.NamedPreparer, _ *zap.Logger, modelPlanIDs []uuid.UUID) ([]*models.PlanDataExchangeApproach, error)
PlanDataExchangeApproachGetByModelPlanIDLoader returns the plan date exchange approach for a slice of model plan ids
func PlanDataExchangeApproachUpdate ¶
func PlanDataExchangeApproachUpdate(np sqlutils.NamedPreparer, logger *zap.Logger, approach *models.PlanDataExchangeApproach) (*models.PlanDataExchangeApproach, error)
PlanDataExchangeApproachUpdate updates the plan data exchange approach for a given id
func PlanDiscussionByID ¶
func PlanDiscussionByID(np sqlutils.NamedPreparer, _ *zap.Logger, id uuid.UUID) (*models.PlanDiscussion, error)
PlanDiscussionByID retrieves the plan discussion for a given id
func PlanDiscussionByIDWithNumberOfReplies ¶
func PlanDiscussionByIDWithNumberOfReplies(np sqlutils.NamedPreparer, _ *zap.Logger, id uuid.UUID, timeToCheck time.Time) (*models.PlanDiscussionWithNumberOfReplies, error)
PlanDiscussionByIDWithNumberOfReplies retrieves the plan discussion for a given id, and also returns the number of replies the discussion has
func PlanDiscussionCreate ¶
func PlanDiscussionCreate( logger *zap.Logger, discussion *models.PlanDiscussion, np sqlutils.NamedPreparer, ) (*models.PlanDiscussion, error)
PlanDiscussionCreate creates a plan discussion the method is expected to be part of a larger transaction and does not handle committing or rollingback the transactions if the *sqlx.Tx is nil, this function will create one. The returned tx is the same as the one in the parameters.
func PlanDiscussionDelete ¶
func PlanDiscussionDelete( tx *sqlx.Tx, _ *zap.Logger, id uuid.UUID, userID uuid.UUID, ) (*models.PlanDiscussion, error)
PlanDiscussionDelete deletes the plan discussion for a given id
func PlanDiscussionGetByModelPlanIDLOADER ¶
func PlanDiscussionGetByModelPlanIDLOADER( np sqlutils.NamedPreparer, _ *zap.Logger, modelPlanIDs []uuid.UUID, ) ([]*models.PlanDiscussion, error)
PlanDiscussionGetByModelPlanIDLOADER returns the plan GeneralCharacteristics for a slice of model plan ids
func PlanDiscussionUpdate ¶
func PlanDiscussionUpdate( np sqlutils.NamedPreparer, logger *zap.Logger, discussion *models.PlanDiscussion, ) (*models.PlanDiscussion, error)
PlanDiscussionUpdate updates a plan discussion object
func PlanDocumentCreate ¶
func PlanDocumentCreate( tx *sqlx.Tx, logger *zap.Logger, principal string, inputDocument *models.PlanDocument, ) (*models.PlanDocument, error)
PlanDocumentCreate creates a plan document
func PlanDocumentDelete ¶
func PlanDocumentDelete(tx *sqlx.Tx, logger *zap.Logger, id uuid.UUID, userID uuid.UUID) (sql.Result, error)
PlanDocumentDelete deletes a plan document object by id
func PlanDocumentGetByIDNoS3Check ¶
func PlanDocumentGetByIDNoS3Check( np sqlutils.NamedPreparer, _ *zap.Logger, id uuid.UUID, ) (*models.PlanDocument, error)
PlanDocumentGetByIDNoS3Check gets a plan document object by id
func PlanDocumentRead ¶
func PlanDocumentRead( np sqlutils.NamedPreparer, _ *zap.Logger, s3Client *s3.S3Client, id uuid.UUID, ) (*models.PlanDocument, error)
PlanDocumentRead reads a plan document object by id
func PlanDocumentsReadByModelPlanID ¶
func PlanDocumentsReadByModelPlanID( np sqlutils.NamedPreparer, logger *zap.Logger, modelPlanID uuid.UUID, s3Client *s3.S3Client) ([]*models.PlanDocument, error)
PlanDocumentsReadByModelPlanID reads a plan document object by model plan id
func PlanDocumentsReadByModelPlanIDNotRestricted ¶
func PlanDocumentsReadByModelPlanIDNotRestricted( np sqlutils.NamedPreparer, logger *zap.Logger, modelPlanID uuid.UUID, s3Client *s3.S3Client) ([]*models.PlanDocument, error)
PlanDocumentsReadByModelPlanIDNotRestricted reads a plan document object by model plan id and restricted = false
func PlanDocumentsReadByPlanTaskID ¶
func PlanDocumentsReadByPlanTaskID(np sqlutils.NamedPreparer, logger *zap.Logger, planTaskID uuid.UUID, s3Client *s3.S3Client) ([]*models.PlanDocument, error)
PlanDocumentsReadByPlanTaskID reads plan documents attributed to a plan task.
func PlanDocumentsReadByPlanTaskIDNotRestricted ¶
func PlanDocumentsReadByPlanTaskIDNotRestricted( np sqlutils.NamedPreparer, logger *zap.Logger, planTaskID uuid.UUID, s3Client *s3.S3Client) ([]*models.PlanDocument, error)
PlanDocumentsReadByPlanTaskIDNotRestricted reads non-restricted plan documents attributed to a plan task.
func PlanFavoriteCollectionGetUniqueUserIDs ¶
func PlanFavoriteCollectionGetUniqueUserIDs(np sqlutils.NamedPreparer) ([]uuid.UUID, error)
PlanFavoriteCollectionGetUniqueUserIDs returns userIDs of users that have favorited any model
func PlanFavoriteCreate ¶
func PlanFavoriteCreate(np sqlutils.NamedPreparer, logger *zap.Logger, favorite models.PlanFavorite) (*models.PlanFavorite, error)
PlanFavoriteCreate creates and returns a plan favorite object
func PlanFavoriteDelete ¶
func PlanFavoriteDelete( tx *sqlx.Tx, _ *zap.Logger, userAccountID uuid.UUID, planID uuid.UUID, deletedByUserID uuid.UUID, ) (*models.PlanFavorite, error)
PlanFavoriteDelete deletes a plan favorite
func PlanFavoriteGetByModelIDAndUserAccountID ¶
func PlanFavoriteGetByModelIDAndUserAccountID( np sqlutils.NamedPreparer, _ *zap.Logger, userAccountID uuid.UUID, modelPlanID uuid.UUID, ) (*models.PlanFavorite, error)
PlanFavoriteGetByModelIDAndUserAccountID returns a plan favorite
func PlanFavoriteGetCollectionByUserID ¶
func PlanFavoriteGetCollectionByUserID( np sqlutils.NamedPreparer, _ logging.ILogger, userAccountID uuid.UUID, ) ([]*models.PlanFavorite, error)
PlanFavoriteGetCollectionByUserID returns plan favorites by userID
func PlanGeneralCharacteristicsCreate ¶
func PlanGeneralCharacteristicsCreate( np sqlutils.NamedPreparer, logger *zap.Logger, gc *models.PlanGeneralCharacteristics, ) (*models.PlanGeneralCharacteristics, error)
PlanGeneralCharacteristicsCreate creates a new plan basics
func PlanGeneralCharacteristicsGetByID ¶
func PlanGeneralCharacteristicsGetByID( np sqlutils.NamedPreparer, _ *zap.Logger, id uuid.UUID, ) (*models.PlanGeneralCharacteristics, error)
PlanGeneralCharacteristicsGetByID returns the plan general characteristics for a given id
func PlanGeneralCharacteristicsGetByModelPlanIDLOADER ¶
func PlanGeneralCharacteristicsGetByModelPlanIDLOADER( np sqlutils.NamedPreparer, _ *zap.Logger, paramTableJSON string, ) ([]*models.PlanGeneralCharacteristics, error)
PlanGeneralCharacteristicsGetByModelPlanIDLOADER returns the plan GeneralCharacteristics for a slice of model plan ids
func PlanGeneralCharacteristicsUpdate ¶
func PlanGeneralCharacteristicsUpdate( np sqlutils.NamedPreparer, logger *zap.Logger, gc *models.PlanGeneralCharacteristics, ) (*models.PlanGeneralCharacteristics, error)
PlanGeneralCharacteristicsUpdate updates the plan general characteristics for a given id
func PlanOpsEvalAndLearningCreate ¶
func PlanOpsEvalAndLearningCreate( np sqlutils.NamedPreparer, logger *zap.Logger, oel *models.PlanOpsEvalAndLearning, ) (*models.PlanOpsEvalAndLearning, error)
PlanOpsEvalAndLearningCreate creates a new plan providers_and_participants object
func PlanOpsEvalAndLearningGetByID ¶
func PlanOpsEvalAndLearningGetByID( np sqlutils.NamedPreparer, _ *zap.Logger, id uuid.UUID, ) (*models.PlanOpsEvalAndLearning, error)
PlanOpsEvalAndLearningGetByID returns the plan providers_and_participants for a given id
func PlanOpsEvalAndLearningGetByModelPlanIDLOADER ¶
func PlanOpsEvalAndLearningGetByModelPlanIDLOADER( np sqlutils.NamedPreparer, _ *zap.Logger, paramTableJSON string, ) ([]*models.PlanOpsEvalAndLearning, error)
PlanOpsEvalAndLearningGetByModelPlanIDLOADER returns the plan GeneralCharacteristics for a slice of model plan ids
func PlanOpsEvalAndLearningUpdate ¶
func PlanOpsEvalAndLearningUpdate( np sqlutils.NamedPreparer, logger *zap.Logger, oel *models.PlanOpsEvalAndLearning, ) (*models.PlanOpsEvalAndLearning, error)
PlanOpsEvalAndLearningUpdate updates the plan providers_and_participants for a given id
func PlanParticipantsAndProvidersCreate ¶
func PlanParticipantsAndProvidersCreate( np sqlutils.NamedPreparer, logger *zap.Logger, gc *models.PlanParticipantsAndProviders, ) (*models.PlanParticipantsAndProviders, error)
PlanParticipantsAndProvidersCreate creates a new plan providers_and_participants object
func PlanParticipantsAndProvidersGetByID ¶
func PlanParticipantsAndProvidersGetByID( np sqlutils.NamedPreparer, _ *zap.Logger, id uuid.UUID, ) (*models.PlanParticipantsAndProviders, error)
PlanParticipantsAndProvidersGetByID returns the plan providers_and_participants for a given id
func PlanParticipantsAndProvidersGetByModelPlanIDLOADER ¶
func PlanParticipantsAndProvidersGetByModelPlanIDLOADER( np sqlutils.NamedPreparer, _ *zap.Logger, paramTableJSON string, ) ([]*models.PlanParticipantsAndProviders, error)
PlanParticipantsAndProvidersGetByModelPlanIDLOADER returns the plan GeneralCharacteristics for a slice of model plan ids
func PlanParticipantsAndProvidersUpdate ¶
func PlanParticipantsAndProvidersUpdate( np sqlutils.NamedPreparer, logger *zap.Logger, gc *models.PlanParticipantsAndProviders, ) (*models.PlanParticipantsAndProviders, error)
PlanParticipantsAndProvidersUpdate updates the plan providers_and_participants for a given id
func PlanPaymentsCreate ¶
func PlanPaymentsCreate( np sqlutils.NamedPreparer, logger *zap.Logger, payments *models.PlanPayments) (*models.PlanPayments, error)
PlanPaymentsCreate creates a new plan payments row in the database and returns a copy to the caller
func PlanPaymentsGetByModelPlanIDLOADER ¶
func PlanPaymentsGetByModelPlanIDLOADER( np sqlutils.NamedPreparer, _ *zap.Logger, paramTableJSON string, ) ([]*models.PlanPayments, error)
PlanPaymentsGetByModelPlanIDLOADER returns the plan GeneralCharacteristics for a slice of model plan ids
func PlanPaymentsRead ¶
func PlanPaymentsRead( np sqlutils.NamedPreparer, _ *zap.Logger, id uuid.UUID) (*models.PlanPayments, error)
PlanPaymentsRead finds a plan payments model by id
func PlanPaymentsUpdate ¶
func PlanPaymentsUpdate( np sqlutils.NamedPreparer, logger *zap.Logger, payments *models.PlanPayments) (*models.PlanPayments, error)
PlanPaymentsUpdate updates a plan payment model in the database
func PlanTDLCreate ¶
func PlanTDLCreate(np sqlutils.NamedPreparer, logger *zap.Logger, planTDL *models.PlanTDL) (*models.PlanTDL, error)
PlanTDLCreate creates returns a plan_cr_tdl object
func PlanTDLDelete ¶
func PlanTDLDelete(tx *sqlx.Tx, _ *zap.Logger, id uuid.UUID, userID uuid.UUID) (*models.PlanTDL, error)
PlanTDLDelete deletes a plan_cr_tdl
func PlanTDLGetByID ¶
func PlanTDLGetByID(np sqlutils.NamedPreparer, _ *zap.Logger, id uuid.UUID) (*models.PlanTDL, error)
PlanTDLGetByID returns a plan_cr_tdl
func PlanTDLUpdate ¶
func PlanTDLUpdate(np sqlutils.NamedPreparer, logger *zap.Logger, planTDL *models.PlanTDL) (*models.PlanTDL, error)
PlanTDLUpdate updates and returns a plan_cr_tdl object
func PlanTDLsGetByModelPlanID ¶
func PlanTDLsGetByModelPlanID(np sqlutils.NamedPreparer, _ *zap.Logger, modelPlanID uuid.UUID) ([]*models.PlanTDL, error)
PlanTDLsGetByModelPlanID returns all plan_cr_tdls associated with a model plan
func PlanTaskActivateUpcoming ¶
func PlanTaskActivateUpcoming( np sqlutils.NamedPreparer, _ *zap.Logger, modelPlanID uuid.UUID, key models.PlanTaskKey, modifiedBy uuid.UUID, ) (*models.PlanTask, error)
PlanTaskActivateUpcoming moves a plan task from UPCOMING to TO_DO in a single conditional update, attributing the change to modifiedBy. It returns nil if the task wasn't currently UPCOMING (already activated, has otherwise progressed, or doesn't exist), which is a no-op rather than an error.
func PlanTaskCreate ¶
func PlanTaskCreate( np sqlutils.NamedPreparer, logger *zap.Logger, task *models.PlanTask, ) (*models.PlanTask, error)
PlanTaskCreate creates a new plan task (used when a model plan is created)
func PlanTaskGetByIDLoader ¶
func PlanTaskGetByIDLoader( np sqlutils.NamedPreparer, _ *zap.Logger, ids []uuid.UUID, ) ([]*models.PlanTask, error)
PlanTaskGetByIDLoader returns plan tasks for a slice of task IDs
func PlanTaskGetByModelPlanIDAndKey ¶
func PlanTaskGetByModelPlanIDAndKey( np sqlutils.NamedPreparer, _ *zap.Logger, modelPlanID uuid.UUID, key models.PlanTaskKey, ) (*models.PlanTask, error)
PlanTaskGetByModelPlanIDAndKey returns the plan task for a specific (modelPlanID, key) pair, or nil if none exists. Unlike PlanTaskGetByModelPlanIDs, this filters in SQL rather than fetching every task for the plan and scanning for the key in Go.
func PlanTaskGetByModelPlanIDs ¶
func PlanTaskGetByModelPlanIDs( np sqlutils.NamedPreparer, _ *zap.Logger, modelPlanIDs []uuid.UUID, ) ([]*models.PlanTask, error)
PlanTaskGetByModelPlanIDs returns all plan tasks for a slice of model plan IDs. It backs the ByModelPlanID dataloader (see storage/loaders/plan_task_loader.go) exclusively - callers that need a single task by (modelPlanID, key), including those running inside a DB transaction that can't safely use the request-scoped dataloader, should use PlanTaskGetByModelPlanIDAndKey instead.
func PlanTaskGetModelPlanIDsDueForPrepareForClearance ¶
func PlanTaskGetModelPlanIDsDueForPrepareForClearance( np sqlutils.NamedPreparer, _ *zap.Logger, triggerThreshold time.Time, ) ([]*uuid.UUID, error)
PlanTaskGetModelPlanIDsDueForPrepareForClearance returns the model plan IDs whose PREPARE_FOR_CLEARANCE task is still UPCOMING and whose internal clearance start date is on or before triggerThreshold (i.e. within models.PrepareForClearanceTriggerDays of now). Used by pkg/worker/prepare_for_clearance_batch_job.go to find which plans need activation.
func PlanTaskUpdateStateByKey ¶
func PlanTaskUpdateStateByKey( np sqlutils.NamedPreparer, _ *zap.Logger, modelPlanID uuid.UUID, key models.PlanTaskKey, newState models.PlanTaskState, completedBy *uuid.UUID, completedDts *time.Time, modifiedBy uuid.UUID, ) (*models.PlanTaskWithPreviousState, error)
PlanTaskUpdateStateByKey sets a plan task's state and completion metadata (identified by modelPlanID + key, rather than a pre-fetched row) in a single conditional update, attributing the change to modifiedBy. It returns (nil, nil) - a no-op, not an error - if the task was already at the target state and completion metadata, or if it doesn't exist for this model plan; callers that need to distinguish "doesn't exist" from "no-op" should follow up with PlanTaskGetByModelPlanIDAndKey in that case.
func PlanTimelineClearApplicationDatesByModelPlanID ¶
func PlanTimelineClearApplicationDatesByModelPlanID(np sqlutils.NamedPreparer, logger *zap.Logger, modelPlanID uuid.UUID, modifiedBy uuid.UUID) (*models.PlanTimeline, error)
PlanTimelineClearApplicationDatesByModelPlanID sets application period dates to NULL for the timeline row for modelPlanID.
func PlanTimelineCreate ¶
func PlanTimelineCreate(np sqlutils.NamedPreparer, logger *zap.Logger, planTimeline *models.PlanTimeline) (*models.PlanTimeline, error)
PlanTimelineCreate creates a new planTimeline
func PlanTimelineGetByID ¶
func PlanTimelineGetByID(np sqlutils.NamedPreparer, _ *zap.Logger, id uuid.UUID) (*models.PlanTimeline, error)
PlanTimelineGetByID returns the planTimeline for a given id
func PlanTimelineGetByModelPlanID ¶
func PlanTimelineGetByModelPlanID(np sqlutils.NamedPreparer, modelPlanID uuid.UUID) (*models.PlanTimeline, error)
PlanTimelineGetByModelPlanID returns the planTimeline for a given model plan id
func PlanTimelineGetByModelPlanIDLoader ¶
func PlanTimelineGetByModelPlanIDLoader(np sqlutils.NamedPreparer, _ *zap.Logger, modelPlanIDs []uuid.UUID) ([]*models.PlanTimeline, error)
PlanTimelineGetByModelPlanIDLoader returns the planTimeline for a slice of model plan ids
func PlanTimelineUpdate ¶
func PlanTimelineUpdate(np sqlutils.NamedPreparer, logger *zap.Logger, planTimeline *models.PlanTimeline) (*models.PlanTimeline, error)
PlanTimelineUpdate updates the planTimeline for a given id
func ReadyForClearanceGetByModelPlanID ¶
func ReadyForClearanceGetByModelPlanID( np sqlutils.NamedPreparer, _ *zap.Logger, modelPlanID uuid.UUID, ) (*models.PrepareForClearanceResponse, error)
ReadyForClearanceGetByModelPlanID reads clearance aggregate data for a model plan.
func SuggestedWaiverCreate ¶
func SuggestedWaiverCreate(np sqlutils.NamedPreparer, _ *zap.Logger, sw *models.SuggestedWaiver) (*models.SuggestedWaiver, error)
SuggestedWaiverCreate creates a new suggested_waiver row
func SuggestedWaiverGetByID ¶
func SuggestedWaiverGetByID(np sqlutils.NamedPreparer, _ *zap.Logger, id uuid.UUID) (*models.SuggestedWaiver, error)
SuggestedWaiverGetByID returns a suggested_waiver row for a given id
func SuggestedWaiverGetByModelPlanIDLoader ¶
func SuggestedWaiverGetByModelPlanIDLoader(np sqlutils.NamedPreparer, _ *zap.Logger, modelPlanIDs []uuid.UUID) ([]*models.SuggestedWaiver, error)
SuggestedWaiverGetByModelPlanIDLoader returns all suggested_waiver rows for the given model plan ids (one-to-many)
func TagCollectionCreate ¶
func TagCollectionCreate(np sqlutils.NamedPreparer, _ *zap.Logger, tags []*models.Tag, createdBy uuid.UUID) ([]*models.Tag, error)
TagCollectionCreate creates an array of tags in the database based on the tag context provided in the string the method is expected to be part of a larger transaction and does not handle committing or rolling back the transactions
func TagCollectionGetByContentIDAndField ¶
func TagCollectionGetByContentIDAndField(np sqlutils.NamedPreparer, _ *zap.Logger, taggedTable string, taggedField string, taggedContentID uuid.UUID) ([]*models.Tag, error)
TagCollectionGetByContentIDAndField returns relevant tags for specific table and field
func TranslatedAuditCollectionGetByModelPlanID ¶
func TranslatedAuditCollectionGetByModelPlanID(np sqlutils.NamedPreparer, modelPlanID uuid.UUID, tablesToInclude []models.TableName, hasRestrictedAccess bool, limit *int, offset *int) ([]*models.TranslatedAudit, error)
TranslatedAuditCollectionGetByModelPlanID returns all translatedAudits for a given model plan id tablesToInclude: the tables to include in the query. This is a list of models.TableName. If nil or empty, include all hasRestrictedAccess: whether or not to show restricted records limit: this controls how many records will be returned at once. A null entry will return all records offset: how many records to skip before returning results. If null, no records will be skipped.
func TranslatedAuditCreate ¶
func TranslatedAuditCreate(np sqlutils.NamedPreparer, translatedAudit *models.TranslatedAudit) (*models.TranslatedAudit, error)
TranslatedAuditCreate creates a TranslatedAudit in the database, using the values passed in the translatedAudit parameter
func TranslatedAuditFieldCollectionGetByTranslatedAuditIDLoader ¶
func TranslatedAuditFieldCollectionGetByTranslatedAuditIDLoader(np sqlutils.NamedPreparer, paramTableJSON string) ([]*models.TranslatedAuditField, error)
TranslatedAuditFieldCollectionGetByTranslatedAuditIDLoader returns all TranslatedAuditFields for a translated audit id
func TranslatedAuditFieldCreate ¶
func TranslatedAuditFieldCreate(np sqlutils.NamedPreparer, translatedAuditField *models.TranslatedAuditField) (*models.TranslatedAuditField, error)
TranslatedAuditFieldCreate creates a TranslatedAuditField in the database, using the values passed in the translatedAuditField parameter
func TranslatedAuditFieldCreateCollection ¶
func TranslatedAuditFieldCreateCollection(np sqlutils.NamedPreparer, translatedAuditFields []*models.TranslatedAuditField) ([]*models.TranslatedAuditField, error)
TranslatedAuditFieldCreateCollection creates a TranslatedAuditField in the database, using the values passed in the translatedAuditFields parameter
func TranslatedAuditMostRecentGetByModelPlanIDAndTableNamesLoader ¶
func TranslatedAuditMostRecentGetByModelPlanIDAndTableNamesLoader(np sqlutils.NamedPreparer, _ *zap.Logger, keys []MostRecentByModelPlanIDAndTableFilters) ([]*models.TranslatedAuditWithFilteredView, error)
TranslatedAuditMostRecentGetByModelPlanIDAndTableNamesLoader returns the most recent TranslatedAudit for a given model plan id and table names it serializes the params into a json array and passes it to the sql query it will return only the most recent for each combination
func TranslatedAuditQueueGetByID ¶
func TranslatedAuditQueueGetByID(np sqlutils.NamedPreparer, id uuid.UUID) (*models.TranslatedAuditQueue, error)
TranslatedAuditQueueGetByID returns a translatedAuditQueue for a given id
func TranslatedAuditQueueGetEntriesToQueue ¶
func TranslatedAuditQueueGetEntriesToQueue(np sqlutils.NamedPreparer) ([]*models.TranslatedAuditQueue, error)
TranslatedAuditQueueGetEntriesToQueue returns a translatedAuditQueue entries that are ready to be queued (the record was created by the audit trigger)
func TranslatedAuditQueueGetQueued ¶
func TranslatedAuditQueueGetQueued(np sqlutils.NamedPreparer) ([]*models.TranslatedAuditQueue, error)
TranslatedAuditQueueGetQueued returns a translatedAuditQueue entries that are already queued
func TranslatedAuditQueueUpdate ¶
func TranslatedAuditQueueUpdate( np sqlutils.NamedPreparer, logger logging.ILogger, translatedAuditQueue *models.TranslatedAuditQueue) (*models.TranslatedAuditQueue, error)
TranslatedAuditQueueUpdate updates a TranslatedAuditQueue record in the database
func UserAccountCollectionGet ¶
func UserAccountCollectionGet(np sqlutils.NamedPreparer) ([]*authentication.UserAccount, error)
UserAccountCollectionGet returns all user accounts from the database
func UserAccountGetByID ¶
func UserAccountGetByID(np sqlutils.NamedPreparer, id uuid.UUID) (*authentication.UserAccount, error)
UserAccountGetByID gets a User account from the database by its internal id.
func UserAccountGetByIDLOADER ¶
func UserAccountGetByIDLOADER( np sqlutils.NamedPreparer, _ *zap.Logger, paramTableJSON string, ) ([]*authentication.UserAccount, error)
UserAccountGetByIDLOADER gets multiple User account from the database by its internal id.
func UserAccountGetByUsername ¶
func UserAccountGetByUsername(np sqlutils.NamedPreparer, username string) (*authentication.UserAccount, error)
UserAccountGetByUsername gets a user account by a give username
func UserAccountGetFollowersForModelFollowerUpdate ¶
func UserAccountGetFollowersForModelFollowerUpdate( np sqlutils.NamedPreparer, modelPlanID uuid.UUID, ) ([]*models.UserAccountAndNotificationPreferences, error)
UserAccountGetFollowersForModelFollowerUpdate returns the user accounts of everyone following (i.e. who has favorited) a model plan, along with their model follower update notification preferences
func UserAccountGetLeadModelPlanCount ¶
UserAccountGetLeadModelPlanCount returns the count of model plans where the user is a lead.
func UserAccountGetNotificationPreferencesForDataExchangeApproachMarkedComplete ¶
func UserAccountGetNotificationPreferencesForDataExchangeApproachMarkedComplete( np sqlutils.NamedPreparer, modelPlanID uuid.UUID, ) ([]*models.UserAccountAndNotificationPreferences, error)
UserAccountGetNotificationPreferencesForDataExchangeApproachMarkedComplete returns a collection of user accounts that should be notified of when a data exchange approach is marked complete
func UserAccountGetNotificationPreferencesForIDDOCQuestionnaireCompleted ¶
func UserAccountGetNotificationPreferencesForIDDOCQuestionnaireCompleted( np sqlutils.NamedPreparer, modelPlanID uuid.UUID, ) ([]*models.UserAccountAndNotificationPreferences, error)
UserAccountGetNotificationPreferencesForIDDOCQuestionnaireCompleted returns a collection of user accounts that should be notified of when an IDDOC questionnaire is completed
func UserAccountGetNotificationPreferencesForMTOReadyForReview ¶
func UserAccountGetNotificationPreferencesForMTOReadyForReview( np sqlutils.NamedPreparer, modelPlanID uuid.UUID, ) ([]*models.UserAccountAndNotificationPreferences, error)
UserAccountGetNotificationPreferencesForMTOReadyForReview returns a collection of user accounts that should be notified of when an MTO is marked ready for review
func UserAccountGetNotificationPreferencesForNewTaskAdded ¶
func UserAccountGetNotificationPreferencesForNewTaskAdded( np sqlutils.NamedPreparer, modelPlanID uuid.UUID, ) ([]*models.UserAccountAndNotificationPreferences, error)
UserAccountGetNotificationPreferencesForNewTaskAdded returns a collection of user accounts that should be notified when a plan task becomes available
func UserAccountGetNotificationPreferencesForTaskCompleted ¶
func UserAccountGetNotificationPreferencesForTaskCompleted( np sqlutils.NamedPreparer, modelPlanID uuid.UUID, ) ([]*models.UserAccountAndNotificationPreferences, error)
UserAccountGetNotificationPreferencesForTaskCompleted returns a collection of user accounts that should be notified when a plan task is completed
func UserAccountGetNotificationPreferencesForWaiverAssessmentSurveyMarkedComplete ¶
func UserAccountGetNotificationPreferencesForWaiverAssessmentSurveyMarkedComplete( np sqlutils.NamedPreparer, modelPlanID uuid.UUID, ) ([]*models.UserAccountAndNotificationPreferences, error)
UserAccountGetNotificationPreferencesForWaiverAssessmentSurveyMarkedComplete returns a collection of user accounts that should be notified of when a waiver assessment survey is marked complete
func UserAccountInsertByUsername ¶
func UserAccountInsertByUsername(np sqlutils.NamedPreparer, userAccount *authentication.UserAccount) (*authentication.UserAccount, error)
UserAccountInsertByUsername creates a new user account for a given username
func UserAccountNotificationPreferencesNewModelPlan ¶
func UserAccountNotificationPreferencesNewModelPlan(np sqlutils.NamedPreparer) ( []*models.UserAccountAndNotificationPreferences, error, )
UserAccountNotificationPreferencesNewModelPlan gets the notification preferences for a new model plan for a slice of users who have at least one enabled preference
func UserAccountUpdateByUserName ¶
func UserAccountUpdateByUserName(np sqlutils.NamedPreparer, userAccount *authentication.UserAccount) ( *authentication.UserAccount, error, )
UserAccountUpdateByUserName updates an existing user account for a given username
func UserAccountsGetNotificationRecipientsForDatesChanged ¶
func UserAccountsGetNotificationRecipientsForDatesChanged( np sqlutils.NamedPreparer, modelPlanID uuid.UUID, ) ( []*models.UserAccountAndNotificationPreferences, error, )
UserAccountsGetNotificationRecipientsForDatesChanged returns a collection of user accounts that should be notified of a change in model plan dates
func UserAccountsGetNotificationRecipientsForDiscussionAdded ¶
func UserAccountsGetNotificationRecipientsForDiscussionAdded( np sqlutils.NamedPreparer, modelPlanID uuid.UUID, ) ( []*models.UserAccountAndNotificationPreferences, error, )
UserAccountsGetNotificationRecipientsForDiscussionAdded returns a collection of user accounts that should be notified of when a new discussion is added to a model plan
func UserNotificationPreferencesCreate ¶
func UserNotificationPreferencesCreate(np sqlutils.NamedPreparer, userNotificationPreferences *models.UserNotificationPreferences) (*models.UserNotificationPreferences, error)
UserNotificationPreferencesCreate creates a new UserNotificationPreferences in the database
func UserNotificationPreferencesGetByUserID ¶
func UserNotificationPreferencesGetByUserID(np sqlutils.NamedPreparer, userID uuid.UUID) (*models.UserNotificationPreferences, error)
UserNotificationPreferencesGetByUserID returns a UserNotificationPreferences object for a given user_id in the database Note this should only be used for cases when a data loader is not possible to use directly.
func UserNotificationPreferencesGetByUserIDLoader ¶
func UserNotificationPreferencesGetByUserIDLoader(np sqlutils.NamedPreparer, paramTableJSON string) ([]*models.UserNotificationPreferences, error)
UserNotificationPreferencesGetByUserIDLoader returns a collection of UserNotificationPreferences object for a given collection of user_ids, serialized in json
func UserNotificationPreferencesUpdate ¶
func UserNotificationPreferencesUpdate(np sqlutils.NamedPreparer, userNotificationPreferences *models.UserNotificationPreferences) (*models.UserNotificationPreferences, error)
UserNotificationPreferencesUpdate updates a new UserNotificationPreferences in the database
func UserViewCustomizationCreate ¶
func UserViewCustomizationCreate( np sqlutils.NamedPreparer, userViewCustomization *models.UserViewCustomization, ) (*models.UserViewCustomization, error)
UserViewCustomizationCreate creates a new UserViewCustomization in the database
func UserViewCustomizationGetByUserID ¶
func UserViewCustomizationGetByUserID( np sqlutils.NamedPreparer, userID uuid.UUID, ) (*models.UserViewCustomization, error)
UserViewCustomizationGetByUserID returns a UserViewCustomization object for a given user_id in the database
func UserViewCustomizationUpdate ¶
func UserViewCustomizationUpdate( np sqlutils.NamedPreparer, userViewCustomization *models.UserViewCustomization, ) (*models.UserViewCustomization, error)
UserViewCustomizationUpdate updates a new UserViewCustomization in the database
func WaiverAssessmentSurveyCreate ¶
func WaiverAssessmentSurveyCreate(np sqlutils.NamedPreparer, _ *zap.Logger, survey *models.WaiverAssessmentSurvey) (*models.WaiverAssessmentSurvey, error)
WaiverAssessmentSurveyCreate creates a new waiver assessment survey
func WaiverAssessmentSurveyGetByID ¶
func WaiverAssessmentSurveyGetByID(np sqlutils.NamedPreparer, _ *zap.Logger, id uuid.UUID) (*models.WaiverAssessmentSurvey, error)
WaiverAssessmentSurveyGetByID returns the waiver assessment survey for a given id
func WaiverAssessmentSurveyGetByModelPlanIDLoader ¶
func WaiverAssessmentSurveyGetByModelPlanIDLoader(np sqlutils.NamedPreparer, _ *zap.Logger, modelPlanIDs []uuid.UUID) ([]*models.WaiverAssessmentSurvey, error)
WaiverAssessmentSurveyGetByModelPlanIDLoader returns the waiver assessment surveys for a slice of model plan ids
func WaiverAssessmentSurveyUpdate ¶
func WaiverAssessmentSurveyUpdate(np sqlutils.NamedPreparer, _ *zap.Logger, survey *models.WaiverAssessmentSurvey) (*models.WaiverAssessmentSurvey, error)
WaiverAssessmentSurveyUpdate updates the waiver assessment survey for a given id
func WaiverGetByID ¶
WaiverGetByID returns a waiver row for a given id.
func WaiverGetByModelPlanIDLoader ¶
func WaiverGetByModelPlanIDLoader(np sqlutils.NamedPreparer, _ *zap.Logger, modelPlanIDs []uuid.UUID) ([]*models.Waiver, error)
WaiverGetByModelPlanIDLoader returns ALL waivers for the given model plan ids (one-to-many).
func WaiverUpsert ¶
func WaiverUpsert(np sqlutils.NamedPreparer, _ *zap.Logger, waiver *models.Waiver) (*models.Waiver, error)
WaiverUpsert creates the waiver row if it does not exist, otherwise updates the selection and its reason fields. Used by the bulk updateSelectedWaivers mutation.
func WaiverUpsertCollection ¶
func WaiverUpsertCollection(np sqlutils.NamedPreparer, _ *zap.Logger, waivers []*models.Waiver) ([]*models.Waiver, error)
WaiverUpsertCollection inserts or updates a collection of waiver rows in a single SQL statement. Accepts a JSON array via JSON_TO_RECORDSET; intended to be called within a transaction.
Types ¶
type AnalyticsType ¶
type AnalyticsType interface {
models.ModelFollowersAnalytics |
models.ModelCountAnalytics |
models.ModelChangesAnalytics |
models.ModelChangesBySectionAnalytics |
models.ModelChangesOtherDataAnalytics |
models.ModelsByStatusAnalytics |
models.ModelCountAnalyticsOverTime
}
AnalyticsType constraint ensures T is one of the analytics struct types
type DBConfig ¶
type DBConfig struct {
Host string
Port string
Database string
Username string
Password string
SSLMode string
UseIAM bool
MaxConnections int
}
DBConfig holds the configurations for a database connection
type IsCollaboratorKey ¶
type IsCollaboratorKey struct {
ModelPlanID uuid.UUID `json:"model_plan_id"`
UserID uuid.UUID `json:"user_id"`
}
IsCollaboratorKey is a composite key for batch-checking if a user is a collaborator on a model plan
type IsCollaboratorResult ¶
type IsCollaboratorResult struct {
ModelPlanID uuid.UUID `json:"model_plan_id" db:"model_plan_id"`
UserID uuid.UUID `json:"user_id" db:"user_id"`
IsCollaborator bool `json:"is_collaborator" db:"is_collaborator"`
}
IsCollaboratorResult holds the result of a batch collaborator existence check
func CheckIfCollaboratorLOADER ¶
func CheckIfCollaboratorLOADER(np sqlutils.NamedPreparer, keys []IsCollaboratorKey) ([]*IsCollaboratorResult, error)
CheckIfCollaboratorLOADER batch-checks if users are collaborators on model plans
type IsFavoriteKey ¶
type IsFavoriteKey struct {
ModelPlanID uuid.UUID `json:"model_plan_id"`
UserID uuid.UUID `json:"user_id"`
}
IsFavoriteKey is a composite key for batch-checking if a user has favorited a model plan
type IsFavoriteResult ¶
type IsFavoriteResult struct {
ModelPlanID uuid.UUID `json:"model_plan_id" db:"model_plan_id"`
UserID uuid.UUID `json:"user_id" db:"user_id"`
IsFavorite bool `json:"is_favorite" db:"is_favorite"`
}
IsFavoriteResult holds the result of a batch favorite existence check
func PlanFavoriteIsFavoritedLOADER ¶
func PlanFavoriteIsFavoritedLOADER(np sqlutils.NamedPreparer, keys []IsFavoriteKey) ([]*IsFavoriteResult, error)
PlanFavoriteIsFavoritedLOADER batch-checks if users have favorited model plans
type MTOMilestoneByModelPlanAndCategoryKey ¶
type MTOMilestoneByModelPlanAndCategoryKey struct {
// ModelPlanID is the model plan the milestone is in reference to
ModelPlanID uuid.UUID `json:"model_plan_id"`
// MTOCategoryID is the category the milestone is associated with. Note, this can be null
MTOCategoryID uuid.UUID `json:"mto_category_id"`
}
MTOMilestoneByModelPlanAndCategoryKey is a key to get MTO milestones by a model plan id and category combination
type MTOSolutionByModelPlanIDAndFilterViewKey ¶
type MTOSolutionByModelPlanIDAndFilterViewKey struct {
// ModelPlanID is the ID of the model plan
ModelPlanID uuid.UUID `json:"model_plan_id"`
// FilterView is the filter view to be applied
FilterView models.ModelViewFilter `json:"filter_view"`
}
MTOSolutionByModelPlanIDAndFilterViewKey is a struct that holds the model plan ID and filter view
type MostRecentByModelPlanIDAndTableFilters ¶
type MostRecentByModelPlanIDAndTableFilters struct {
// ModelPlanID is the ID of the model plan
ModelPlanID uuid.UUID `json:"model_plan_id"`
// IsAdmin specifies if the user is an admin
// this controls if sensitive data is shown, admins can see everything as well as collaborators.
IsAdmin bool `json:"is_admin"`
// TableFilters is the list of tableNames that are used to find a result.
// It really uses models.TableName as the type, but must be comparable to work with a dataloader
// We make a compromise here to fit the dataloader interface
TableNames string `json:"table_names"`
// ExcludedFields is a list of fields to exclude from the result.
// It is provided as a string to fit the comparable interface
ExcludedFields string `json:"excluded_fields"`
}
MostRecentByModelPlanIDAndTableFilters is a key to get the most recent record by model plan ID and table filters Note, if desired we could also introduce a limit param which would allow you to dynamically address how many entries get returned per key
type Store ¶
type Store struct {
// contains filtered or unexported fields
}
Store performs database operations for MINT
func NewStore ¶
NewStore creates a new Store struct The `db` property on the Store will always be a *sqlx.DB, but a notable difference in the DB is that if config.UseIAM is true, that DB instance will be backed by a custom connector in iam_db.go that generates IAM auth tokens when making new connections to the database. If config.UseIAM is false, it will connect using the "postgres" driver that SQLx registers in its init() function https://github.com/jmoiron/sqlx/blob/75a7ebf246fd757c9c7742da7dc4d26c6fdb6b5b/bind.go#L33-L40
func (*Store) Beginx ¶
Beginx implements the TransactionPreparer interface Implementing the sqlutils.TransactionPreparer interfaces allows us to use a sqlx.DB or a storage.Store to create a transaction
func (*Store) PrepareNamed ¶
PrepareNamed implements the INamedPreparer interface Implementing the sqlutils.NamedPreparer interface allows us to use a sqlx.Tx or a storage.Store as a parameter in our DB calls (the former for when we want to implement transactions, the latter for when we don't)
Source Files
¶
- access_controlStore.go
- analytics.go
- analyzed_auditStore.go
- audit_changeStore.go
- common_waiverStore.go
- ctat_request.go
- ctat_request_document.go
- ctat_request_model_plan_link.go
- custom_timeline_date.go
- dataloader_keys.go
- emailStore.go
- existing_modelStore.go
- existing_model_linkStore.go
- iam_db.go
- iddoc_questionnaireStore.go
- key_contact.go
- key_contact_category.go
- model_planStore.go
- model_plan_mto_template_link.go
- mto_category.go
- mto_common_milestone.go
- mto_common_solution.go
- mto_common_solution_contact.go
- mto_common_solution_contractor.go
- mto_common_solution_system_owner.go
- mto_info.go
- mto_milestone.go
- mto_milestone_note.go
- mto_milestone_solution_link.go
- mto_solution.go
- mto_suggested_milestone_reason.go
- mto_template.go
- mto_template_category.go
- mto_template_milestone.go
- mto_template_milestone_solution_link.go
- mto_template_solution.go
- nda_agreementStore.go
- plan_basicsStore.go
- plan_beneficiariesStore.go
- plan_collaboratorStore.go
- plan_crStore.go
- plan_data_exchange_approachStore.go
- plan_discussionStore.go
- plan_documentStore.go
- plan_favoriteStore.go
- plan_general_characteristicsStore.go
- plan_ops_eval_and_learningStore.go
- plan_participants_and_providersStore.go
- plan_paymentsStore.go
- plan_taskStore.go
- plan_task_document_link.go
- plan_tdlStore.go
- plan_timelineStore.go
- prepare_for_clearance.go
- store.go
- suggested_waiverStore.go
- tagStore.go
- translated_auditStore.go
- translated_audit_fieldStore.go
- translated_audit_queueStore.go
- truncate.go
- user_accountStore.go
- user_notification_preferencesStore.go
- user_view_customizationStore.go
- utitiltyStore.go
- waiverStore.go
- waiver_assessment_surveyStore.go
Directories
¶
| Path | Synopsis |
|---|---|
|
Package loaders is a responsible for batched data calls
|
Package loaders is a responsible for batched data calls |