Documentation ¶
Index ¶
- type ResearcherDBService
- func (dbService *ResearcherDBService) AddNoteToParticipantContact(substudyKey string, contactID string, note types.ContactNote) error
- func (dbService *ResearcherDBService) AddNotificationSubscription(substudyKey string, sub types.NotificationSubscription) (string, error)
- func (dbService *ResearcherDBService) AddParticipantContact(substudyKey string, pc types.ParticipantContact) (string, error)
- func (dbService *ResearcherDBService) CleanUpExpiredParticipantContacts(substudyKey string, deleteAfterInDays int) error
- func (dbService *ResearcherDBService) DeleteEmailAllNotificationsForStudy(substudyKey string) (err error)
- func (dbService *ResearcherDBService) DeleteNotificationSubscription(substudyKey string, id string) (count int64, err error)
- func (dbService *ResearcherDBService) DeleteParticipantContact(substudyKey string, contactID string) error
- func (dbService *ResearcherDBService) DeleteStudyInfo(substudyKey string) (count int64, err error)
- func (dbService *ResearcherDBService) FindAllStudyInfos() (studyInfos []types.StudyInfo, err error)
- func (dbService *ResearcherDBService) FindNotificationSubscriptions(substudyKey string, topic string) (subs []types.NotificationSubscription, err error)
- func (dbService *ResearcherDBService) FindParticipantContactByID(substudyKey string, id string) (pcs types.ParticipantContact, err error)
- func (dbService *ResearcherDBService) FindParticipantContacts(substudyKey string) (pcs []types.ParticipantContact, err error)
- func (dbService *ResearcherDBService) FindStudyInfo(substudyKey string) (types.StudyInfo, error)
- func (dbService *ResearcherDBService) FindStudyInfosByKeys(substudyKeys []string) (studyInfos []types.StudyInfo, err error)
- func (dbService *ResearcherDBService) SaveStudyInfo(studyInfo types.StudyInfo) (types.StudyInfo, error)
- func (dbService *ResearcherDBService) UpdateKeepParticipantContactStatus(substudyKey string, contactID string, value bool) error
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type ResearcherDBService ¶
type ResearcherDBService struct { DBClient *mongo.Client DBNamePrefix string // contains filtered or unexported fields }
func NewResearcherDBService ¶
func NewResearcherDBService(configs types.DBConfig) *ResearcherDBService
func (*ResearcherDBService) AddNoteToParticipantContact ¶
func (dbService *ResearcherDBService) AddNoteToParticipantContact(substudyKey string, contactID string, note types.ContactNote) error
func (*ResearcherDBService) AddNotificationSubscription ¶
func (dbService *ResearcherDBService) AddNotificationSubscription(substudyKey string, sub types.NotificationSubscription) (string, error)
func (*ResearcherDBService) AddParticipantContact ¶
func (dbService *ResearcherDBService) AddParticipantContact(substudyKey string, pc types.ParticipantContact) (string, error)
func (*ResearcherDBService) CleanUpExpiredParticipantContacts ¶
func (dbService *ResearcherDBService) CleanUpExpiredParticipantContacts(substudyKey string, deleteAfterInDays int) error
Remove entries after certain time if not marked as permanent
func (*ResearcherDBService) DeleteEmailAllNotificationsForStudy ¶
func (dbService *ResearcherDBService) DeleteEmailAllNotificationsForStudy(substudyKey string) (err error)
func (*ResearcherDBService) DeleteNotificationSubscription ¶
func (dbService *ResearcherDBService) DeleteNotificationSubscription(substudyKey string, id string) (count int64, err error)
func (*ResearcherDBService) DeleteParticipantContact ¶
func (dbService *ResearcherDBService) DeleteParticipantContact(substudyKey string, contactID string) error
Remove entries after certain time if not marked as permanent
func (*ResearcherDBService) DeleteStudyInfo ¶
func (dbService *ResearcherDBService) DeleteStudyInfo(substudyKey string) (count int64, err error)
func (*ResearcherDBService) FindAllStudyInfos ¶
func (dbService *ResearcherDBService) FindAllStudyInfos() (studyInfos []types.StudyInfo, err error)
func (*ResearcherDBService) FindNotificationSubscriptions ¶
func (dbService *ResearcherDBService) FindNotificationSubscriptions(substudyKey string, topic string) (subs []types.NotificationSubscription, err error)
func (*ResearcherDBService) FindParticipantContactByID ¶ added in v1.2.0
func (dbService *ResearcherDBService) FindParticipantContactByID(substudyKey string, id string) (pcs types.ParticipantContact, err error)
func (*ResearcherDBService) FindParticipantContacts ¶
func (dbService *ResearcherDBService) FindParticipantContacts(substudyKey string) (pcs []types.ParticipantContact, err error)
func (*ResearcherDBService) FindStudyInfo ¶
func (dbService *ResearcherDBService) FindStudyInfo(substudyKey string) (types.StudyInfo, error)
func (*ResearcherDBService) FindStudyInfosByKeys ¶
func (dbService *ResearcherDBService) FindStudyInfosByKeys(substudyKeys []string) (studyInfos []types.StudyInfo, err error)
func (*ResearcherDBService) SaveStudyInfo ¶
func (*ResearcherDBService) UpdateKeepParticipantContactStatus ¶
func (dbService *ResearcherDBService) UpdateKeepParticipantContactStatus(substudyKey string, contactID string, value bool) error
Click to show internal directories.
Click to hide internal directories.