Documentation
¶
Index ¶
- Constants
- Variables
- func Paginate(p *PaginationInput) func(db *gorm.DB) *gorm.DB
- type Allergy
- type Amendment
- type Appointment
- func (r *Appointment) AfterCreate(tx *gorm.DB) error
- func (r *Appointment) CreateNewAppointment(billingID *int, invoiceNo *string) error
- func (r *Appointment) Delete(ID int) error
- func (r *Appointment) FindAppointmentsByPatientAndRange(patientID int, start time.Time, end time.Time) ([]*Appointment, error)
- func (r *Appointment) FindByProvider(p PaginationInput, searchTerm *string, visitTypes []string, userID int) ([]Appointment, int64, error)
- func (r *Appointment) FindByUserSubscriptions(ids []int, searchTerm *string, visitTypes []string, p PaginationInput) ([]Appointment, int64, error)
- func (r *Appointment) FindTodaysAppointments(p PaginationInput, searchTerm *string) ([]Appointment, int64, error)
- func (r *Appointment) FindTodaysCheckedInAppointments(p PaginationInput, searchTerm *string, visitTypes []string) ([]Appointment, int64, error)
- func (r *Appointment) Get(ID int) error
- func (r *Appointment) GetAll(p PaginationInput, filter *Appointment) ([]Appointment, int64, error)
- func (r *Appointment) GetByIds(ids []int, p PaginationInput) ([]Appointment, int64, error)
- func (r *Appointment) GetWithDetails(ID int) error
- func (r *Appointment) NurseHomeStats() (int, int, int, error)
- func (r *Appointment) PatientsAppointmentToday(patientID int, checkedIn *bool) (Appointment, error)
- func (r *Appointment) PayForConsultation(patientID int, date *time.Time) (bool, error)
- func (r *Appointment) PhysicianHomeStats(userId int) (int, int, int, error)
- func (r *Appointment) ReceptionHomeStats() (int, int, int, error)
- func (r *Appointment) Save() error
- func (r *Appointment) SchedulePostOp(appointment Appointment) error
- func (r *Appointment) SearchAppointments(page PaginationInput, p AppointmentSearchInput) ([]Appointment, int64, error)
- func (r *Appointment) Update() error
- type AppointmentQueue
- func (r *AppointmentQueue) Delete(ID int) error
- func (r *AppointmentQueue) FindByAppointment(p PaginationInput, userID int) ([]AppointmentQueue, int64, error)
- func (r *AppointmentQueue) FindTodaysAppointments(appointmentID int) ([]AppointmentQueue, error)
- func (r *AppointmentQueue) Get(ID int) error
- func (r *AppointmentQueue) Save() error
- func (r *AppointmentQueue) Update() (*AppointmentQueue, error)
- type AppointmentSearchInput
- type AppointmentStatus
- func (r *AppointmentStatus) Count(dbString string) (int64, error)
- func (r *AppointmentStatus) Delete(ID int) error
- func (r *AppointmentStatus) Get(ID int) error
- func (r *AppointmentStatus) GetAll(p PaginationInput) ([]AppointmentStatus, int64, error)
- func (r *AppointmentStatus) GetByTitle(title string) error
- func (r *AppointmentStatus) Save() error
- func (r *AppointmentStatus) Seed()
- func (r *AppointmentStatus) Update() (*AppointmentStatus, error)
- type AutoRefraction
- type Billing
- func (r *Billing) Delete(ID int) error
- func (r *Billing) Get(ID int) error
- func (r *Billing) GetAll(p PaginationInput) ([]Billing, int64, error)
- func (r *Billing) GetByIds(ids []*int) ([]Billing, error)
- func (r *Billing) GetConsultationBillings() ([]*Billing, error)
- func (r *Billing) Save() error
- func (r *Billing) Search(p PaginationInput, filter *Billing, searchTerm *string) ([]Billing, int64, error)
- func (r *Billing) Update() (*Billing, error)
- type Chat
- type ChatDelete
- type ChatMember
- func (r *ChatMember) Delete(userID int, chatID int) error
- func (r *ChatMember) FindCommonChatID(userID int, recipientID int) (int, error)
- func (r *ChatMember) Get(ID int) error
- func (r *ChatMember) GetByChatID(ID int) ([]*ChatMember, error)
- func (r *ChatMember) Save() error
- func (r *ChatMember) Update() error
- type ChatMessage
- type ChatMute
- type ChatUnreadMessage
- func (r *ChatUnreadMessage) Delete(ID int) error
- func (r *ChatUnreadMessage) DeleteForUserChat(userID int, chatID int) error
- func (r *ChatUnreadMessage) Get(ID int) error
- func (r *ChatUnreadMessage) GetByUserID(ID int) ([]*ChatUnreadMessage, error)
- func (r *ChatUnreadMessage) Save() error
- func (r *ChatUnreadMessage) Update() error
- type ChiefComplaint
- func (r *ChiefComplaint) Delete(ID int) error
- func (r *ChiefComplaint) Get(ID int) error
- func (r *ChiefComplaint) GetAll(p PaginationInput, filter *ChiefComplaint) ([]ChiefComplaint, int64, error)
- func (r *ChiefComplaint) Save() error
- func (r *ChiefComplaint) Search(p PaginationInput, searchTerm string) ([]ChiefComplaint, int64, error)
- func (r *ChiefComplaint) Update() error
- type ChiefComplaintType
- func (r *ChiefComplaintType) Delete(ID int) error
- func (r *ChiefComplaintType) Get(ID int) error
- func (r *ChiefComplaintType) GetAll(p PaginationInput, searchTerm *string) ([]ChiefComplaintType, int64, error)
- func (r *ChiefComplaintType) GetByTitle(title string) error
- func (r *ChiefComplaintType) GetFavorites(p PaginationInput, searchTerm *string, userId int) ([]ChiefComplaintType, int64, error)
- func (r *ChiefComplaintType) Save() error
- func (r *ChiefComplaintType) Update() error
- type CoverTest
- type Diagnosis
- func (r *Diagnosis) Delete(ID int) error
- func (r *Diagnosis) Get(ID int) error
- func (r *Diagnosis) GetAll(p PaginationInput, searchTerm *string) ([]Diagnosis, int64, error)
- func (r *Diagnosis) GetByTitle(title string) error
- func (r *Diagnosis) GetFavorites(p PaginationInput, searchTerm *string, userId int) ([]Diagnosis, int64, error)
- func (r *Diagnosis) Save() error
- func (r *Diagnosis) Update() error
- type DiagnosticProcedure
- func (r *DiagnosticProcedure) ClearAssociation(association string, diagnosticProcedureID int) error
- func (r *DiagnosticProcedure) Delete(ID int) error
- func (r *DiagnosticProcedure) DeleteFile(association string, diagnosticProcedureID int, fileID int) error
- func (r *DiagnosticProcedure) Get(ID int) error
- func (r *DiagnosticProcedure) GetAll(p PaginationInput, filter *DiagnosticProcedure) ([]DiagnosticProcedure, int64, error)
- func (r *DiagnosticProcedure) GetByPatientChartID(ID int) error
- func (r *DiagnosticProcedure) GetRefraction(patientChartID int) error
- func (r *DiagnosticProcedure) Save() error
- func (r *DiagnosticProcedure) Update() error
- type DiagnosticProcedureOrder
- func (r *DiagnosticProcedureOrder) Confirm(id int, invoiceNo string) error
- func (r *DiagnosticProcedureOrder) Delete(ID int) error
- func (r *DiagnosticProcedureOrder) GetAll(p PaginationInput, filter *DiagnosticProcedureOrder) ([]DiagnosticProcedureOrder, int64, error)
- func (r *DiagnosticProcedureOrder) GetByPatientChartID(patientChartID int) error
- func (r *DiagnosticProcedureOrder) GetCount(filter *DiagnosticProcedureOrder, date *time.Time, searchTerm *string) (int64, error)
- func (r *DiagnosticProcedureOrder) GetPatientDiagnosticProcedureTitles(patientID int) ([]string, error)
- func (r *DiagnosticProcedureOrder) GetTodaysOrderedCount() (count int)
- func (r *DiagnosticProcedureOrder) OrderAndConfirm()
- func (r *DiagnosticProcedureOrder) Save(diagnosticProcedureTypeID int, patientChartID int, patientID int, ...) error
- func (r *DiagnosticProcedureOrder) Search(p PaginationInput, filter *DiagnosticProcedureOrder, date *time.Time, ...) ([]DiagnosticProcedureOrder, int64, error)
- func (r *DiagnosticProcedureOrder) Update() error
- type DiagnosticProcedureOrderStatus
- type DiagnosticProcedureStatus
- type DiagnosticProcedureType
- func (r *DiagnosticProcedureType) Delete(ID int) error
- func (r *DiagnosticProcedureType) Get(ID int) error
- func (r *DiagnosticProcedureType) GetAll(p PaginationInput, searchTerm *string) ([]DiagnosticProcedureType, int64, error)
- func (r *DiagnosticProcedureType) GetByTitle(title string) error
- func (r *DiagnosticProcedureType) Save() error
- func (r *DiagnosticProcedureType) Update() error
- type ExamCategory
- func (r *ExamCategory) Delete(ID int) error
- func (r *ExamCategory) Get(ID int) error
- func (r *ExamCategory) GetAll(p PaginationInput, searchTerm *string) ([]ExamCategory, int64, error)
- func (r *ExamCategory) GetByTitle(title string) error
- func (r *ExamCategory) Save() error
- func (r *ExamCategory) Update() error
- type ExamFinding
- func (r *ExamFinding) Delete(ID int) error
- func (r *ExamFinding) Get(ID int) error
- func (r *ExamFinding) GetAll(p PaginationInput, searchTerm *string) ([]ExamFinding, int64, error)
- func (r *ExamFinding) GetByTitle(title string) error
- func (r *ExamFinding) Save() error
- func (r *ExamFinding) Update() error
- type ExternalExam
- type EyewearPrescription
- func (r *EyewearPrescription) Delete(ID int) error
- func (r *EyewearPrescription) Get(ID int) error
- func (r *EyewearPrescription) GetAll(p PaginationInput, filter *EyewearPrescription) ([]EyewearPrescription, int64, error)
- func (r *EyewearPrescription) Save() error
- func (r *EyewearPrescription) Update() error
- type EyewearPrescriptionOrder
- func (r *EyewearPrescriptionOrder) Delete(ID int) error
- func (r *EyewearPrescriptionOrder) Get(ID int) error
- func (r *EyewearPrescriptionOrder) GetAll(p PaginationInput, filter *EyewearPrescriptionOrder) ([]EyewearPrescriptionOrder, int64, error)
- func (r *EyewearPrescriptionOrder) GetByPatientChartID(patientChartID int) error
- func (r *EyewearPrescriptionOrder) Save() error
- func (r *EyewearPrescriptionOrder) SaveEyewearPrescription(eyewearPrescription EyewearPrescription, patientID int) error
- func (r *EyewearPrescriptionOrder) Search(p PaginationInput, filter *EyewearPrescriptionOrder, date *time.Time, ...) ([]EyewearPrescriptionOrder, int64, error)
- func (r *EyewearPrescriptionOrder) Update() error
- type EyewearShop
- type FamilyIllness
- type FavoriteChiefComplaint
- type FavoriteDiagnosis
- type FavoriteMedication
- func (r *FavoriteMedication) Delete(ID int) error
- func (r *FavoriteMedication) Get(ID int) error
- func (r *FavoriteMedication) GetAll(p PaginationInput, filter *FavoriteMedication, searchTerm *string) ([]FavoriteMedication, int64, error)
- func (r *FavoriteMedication) Save() error
- func (r *FavoriteMedication) Search(p PaginationInput, searchTerm string) ([]FavoriteMedication, int64, error)
- func (r *FavoriteMedication) Update() error
- type File
- type FollowUp
- type FollowUpOrder
- func (r *FollowUpOrder) ConfirmOrder(followUpOrderID int, followUpID int, billingID *int, invoiceNo *string, ...) error
- func (r *FollowUpOrder) Delete(ID int) error
- func (r *FollowUpOrder) GetAll(p PaginationInput, filter *FollowUpOrder) ([]FollowUpOrder, int64, error)
- func (r *FollowUpOrder) GetByPatientChartID(patientChartID int) error
- func (r *FollowUpOrder) GetCount(filter *FollowUpOrder, date *time.Time, searchTerm *string) (int64, error)
- func (r *FollowUpOrder) GetTodaysOrderedCount() (count int)
- func (r *FollowUpOrder) Save(patientChartID int, patientID int, user User, receptionNote string) error
- func (r *FollowUpOrder) Search(p PaginationInput, filter *FollowUpOrder, date *time.Time, searchTerm *string, ...) ([]FollowUpOrder, int64, error)
- func (r *FollowUpOrder) Update() error
- type FollowUpOrderStatus
- type FollowUpStatus
- type Funduscopy
- type HpiComponent
- func (r *HpiComponent) Delete(ID int) error
- func (r *HpiComponent) Get(ID int) error
- func (r *HpiComponent) GetAll(p PaginationInput, filter *HpiComponent) ([]HpiComponent, int64, error)
- func (r *HpiComponent) GetByIds(ids []*int) ([]HpiComponent, error)
- func (r *HpiComponent) Save() error
- func (r *HpiComponent) Search(p PaginationInput, filter *HpiComponent, searchTerm *string) ([]HpiComponent, int64, error)
- func (r *HpiComponent) Update() error
- type HpiComponentType
- func (r *HpiComponentType) Count(dbString string) (int64, error)
- func (r *HpiComponentType) Delete(ID int) error
- func (r *HpiComponentType) Get(ID int) error
- func (r *HpiComponentType) GetAll(p PaginationInput) ([]HpiComponentType, int64, error)
- func (r *HpiComponentType) Save() error
- func (r *HpiComponentType) Update() error
- type Iop
- type Lab
- func (r *Lab) ClearAssociation(association string, labID int) error
- func (r *Lab) Delete(ID int) error
- func (r *Lab) DeleteFile(association string, LabID int, fileID int) error
- func (r *Lab) Get(ID int) error
- func (r *Lab) GetAll(p PaginationInput, filter *Lab) ([]Lab, int64, error)
- func (r *Lab) GetByPatientChartID(ID int) error
- func (r *Lab) NewOrder(LabTypeID int, patientChartID int, appointmentID int, patientID int, ...) error
- func (r *Lab) Save() error
- func (r *Lab) Update() error
- type LabOrder
- func (r *LabOrder) Confirm(id int, invoiceNo string) error
- func (r *LabOrder) Delete(ID int) error
- func (r *LabOrder) Get(ID int) error
- func (r *LabOrder) GetAll(p PaginationInput, filter *LabOrder) ([]LabOrder, int64, error)
- func (r *LabOrder) GetByPatientChartID(patientChartID int) error
- func (r *LabOrder) GetCount(filter *LabOrder, date *time.Time, searchTerm *string) (int64, error)
- func (r *LabOrder) GetTodaysOrderedCount() (count int)
- func (r *LabOrder) Save(labTypeID int, patientChartID int, patientID int, billingIds []int, user User, ...) error
- func (r *LabOrder) Search(p PaginationInput, filter *LabOrder, date *time.Time, searchTerm *string, ...) ([]LabOrder, int64, error)
- func (r *LabOrder) Update() error
- type LabOrderStatus
- type LabStatus
- type LabType
- type Lifestyle
- type LifestyleType
- func (r *LifestyleType) Count(dbString string) (int64, error)
- func (r *LifestyleType) Delete(ID int) error
- func (r *LifestyleType) Get(ID int) error
- func (r *LifestyleType) GetAll(p PaginationInput) ([]LifestyleType, int64, error)
- func (r *LifestyleType) GetByTitle(title string) error
- func (r *LifestyleType) Save() error
- func (r *LifestyleType) Update() error
- type MedicalPrescription
- func (r *MedicalPrescription) Delete(ID int) error
- func (r *MedicalPrescription) Get(ID int) error
- func (r *MedicalPrescription) GetAll(p PaginationInput, filter *MedicalPrescription) ([]MedicalPrescription, int64, error)
- func (r *MedicalPrescription) Save() error
- func (r *MedicalPrescription) Search(p PaginationInput, filter *MedicalPrescription, date *time.Time, ...) ([]MedicalPrescription, int64, error)
- func (r *MedicalPrescription) Update() error
- type MedicalPrescriptionOrder
- func (r *MedicalPrescriptionOrder) Delete(ID int) error
- func (r *MedicalPrescriptionOrder) Get(ID int) error
- func (r *MedicalPrescriptionOrder) GetAll(p PaginationInput, filter *MedicalPrescriptionOrder) ([]MedicalPrescriptionOrder, int64, error)
- func (r *MedicalPrescriptionOrder) GetByPatientChartID(patientChartID int) error
- func (r *MedicalPrescriptionOrder) SaveMedicalPrescription(medicalPrescription MedicalPrescription, patientID int) error
- func (r *MedicalPrescriptionOrder) Search(p PaginationInput, filter *MedicalPrescriptionOrder, date *time.Time, ...) ([]MedicalPrescriptionOrder, int64, error)
- func (r *MedicalPrescriptionOrder) Update() error
- type Model
- func (m *Model) AutoMigrateAll()
- func (m *Model) DropAll()
- func (m *Model) IsOpen() bool
- func (m *Model) OpenPostgres() error
- func (m *Model) OpenWithConfigTest(cfg *conf.Configuration) error
- func (m *Model) Register(values ...interface{}) error
- func (m *Model) RegisterAllModels()
- func (m *Model) SeedData() error
- type OcularMotility
- type OpthalmologyExam
- type OpticDisc
- type Order
- func (r *Order) Confirm(orderID int, invoiceNo string) error
- func (r *Order) ConfirmFollowUpOrder(orderID int, checkInTime time.Time, roomID int) error
- func (r *Order) Counts() (treatment int, referral int, followUps int, errs error)
- func (r *Order) Delete(ID int) error
- func (r *Order) Get(ID int) error
- func (r *Order) OrderFollowup(appointmentID int, userID int, note *string) error
- func (r *Order) ProviderOrders(p PaginationInput, searchTerm *string, userId int) ([]Order, int64, error)
- func (r *Order) Save() error
- func (r *Order) ScheduleSurgery(orderID int, roomID int, checkInTime time.Time, invoiceNo string) error
- func (r *Order) ScheduleTreatment(orderID int, roomID int, checkInTime time.Time, invoiceNo string) error
- func (r *Order) Search(p PaginationInput, f *OrderFilterInput) ([]Order, int64, error)
- func (r *Order) Update() error
- type OrderFilterInput
- type OrderStatus
- type OrderType
- type OrganizationDetails
- type PaginationInput
- type PastHospitalization
- type PastIllness
- type PastIllnessType
- func (r *PastIllnessType) Delete(ID int) error
- func (r *PastIllnessType) Get(ID int) error
- func (r *PastIllnessType) GetAll(p PaginationInput) ([]PastIllnessType, int64, error)
- func (r *PastIllnessType) GetByTitle(title string) error
- func (r *PastIllnessType) Save() error
- func (r *PastIllnessType) Update() error
- type PastInjury
- type PastOptSurgery
- type PastSurgery
- type Patient
- func (r *Patient) AfterCreate(tx *gorm.DB) error
- func (r *Patient) AfterUpdate(tx *gorm.DB) (err error)
- func (r *Patient) Clean() error
- func (r *Patient) Delete(ID int) error
- func (r *Patient) FindByCardNo(cardNo string) error
- func (r *Patient) FindByName(firstName string, lastName string) ([]*Patient, error)
- func (r *Patient) FindByPhoneNo(phoneNo string) ([]*Patient, error)
- func (r *Patient) Get(ID int) error
- func (r *Patient) GetAll(p PaginationInput) ([]Patient, int64, error)
- func (r *Patient) GetAllProgress(patientID int) (*PatientHistory, []*Appointment, error)
- func (r *Patient) GetAllProgressNotes(appointmentID int) (*PatientHistory, []*Appointment, error)
- func (r *Patient) GetPatientDiagnosticProcedures(patientID int, diagnosticProcedureTypeTitle string) ([]*Appointment, error)
- func (r *Patient) GetPatientFiles(patientID int) ([]*File, error)
- func (r *Patient) GetVitalSignsProgress(patientID int) ([]*Appointment, error)
- func (r *Patient) Save() error
- func (r *Patient) Search(term string) ([]*Patient, error)
- func (r *Patient) Update() error
- type PatientChart
- func (r *PatientChart) AfterCreate(tx *gorm.DB) error
- func (r *PatientChart) Get(ID int) error
- func (r *PatientChart) GetByAppointmentID(appointmentID int) error
- func (r *PatientChart) GetWithDetails(ID int) error
- func (r *PatientChart) Save() error
- func (r *PatientChart) SignAndLock(patientChartID int, userID *int) error
- func (r *PatientChart) Update() error
- type PatientDiagnosis
- func (r *PatientDiagnosis) Delete(ID int) error
- func (r *PatientDiagnosis) Get(ID int) error
- func (r *PatientDiagnosis) GetAll(p PaginationInput, filter *PatientDiagnosis) ([]PatientDiagnosis, int64, error)
- func (r *PatientDiagnosis) GetByPatientChartID(ID int) error
- func (r *PatientDiagnosis) Save(diagnosisID int) error
- func (r *PatientDiagnosis) Update() error
- type PatientEncounterLimit
- func (r *PatientEncounterLimit) Delete(ID int) error
- func (r *PatientEncounterLimit) Get(ID int) error
- func (r *PatientEncounterLimit) GetAll(p PaginationInput) ([]PatientEncounterLimit, int64, error)
- func (r *PatientEncounterLimit) GetByUser(userID int) error
- func (r *PatientEncounterLimit) Save() error
- func (r *PatientEncounterLimit) Update() error
- type PatientHistory
- type PatientQueue
- func (r *PatientQueue) AddToQueue(toQueueName string, appointmentID int, queueType string) error
- func (r *PatientQueue) ClearExpired() error
- func (r *PatientQueue) DeleteFromQueue(patientQueueID int, appointmentID int) error
- func (r *PatientQueue) Get(id int) error
- func (r *PatientQueue) GetAll() ([]*PatientQueue, error)
- func (r *PatientQueue) GetByQueueName(queueName string) error
- func (r *PatientQueue) Move(fromQueueID int, toQueueID int, appointmentID int) error
- func (r *PatientQueue) MoveToQueueName(fromQueueID int, toQueueName string, appointmentID int, queueType string) error
- func (r *PatientQueue) Save() error
- func (r *PatientQueue) UpdateQueue(queueName string, queue datatypes.JSON) error
- type Payment
- func (r *Payment) BatchUpdate(ids []int, e Payment) error
- func (r *Payment) Delete(ID int) error
- func (r *Payment) Get(ID int) error
- func (r *Payment) GetByIds(ids []int) ([]Payment, error)
- func (r *Payment) RequestWaiver(paymentID int, patientID int, userID int) error
- func (r *Payment) RequestWaiverBatch(paymentIds []int, patientId int, userId int) error
- func (r *Payment) Save() error
- func (r *Payment) Update() error
- type PaymentStatus
- type PaymentWaiver
- func (r *PaymentWaiver) ApproveWaiver(id int, approve bool) error
- func (r *PaymentWaiver) BatchSave(waivers []PaymentWaiver) error
- func (r *PaymentWaiver) Delete(ID int) error
- func (r *PaymentWaiver) Get(ID int) error
- func (r *PaymentWaiver) GetAll(p PaginationInput) ([]PaymentWaiver, int64, error)
- func (r *PaymentWaiver) GetApprovedCount() (int, error)
- func (r *PaymentWaiver) Save() error
- func (r *PaymentWaiver) Update() error
- type Pharmacy
- type PhysicalExamFinding
- func (r *PhysicalExamFinding) Delete(ID int) error
- func (r *PhysicalExamFinding) DeleteExamCategory(physicalExamFindingID int, examCategoryID int) error
- func (r *PhysicalExamFinding) Get(ID int) error
- func (r *PhysicalExamFinding) GetAll(p PaginationInput, filter *PhysicalExamFinding) ([]PhysicalExamFinding, int64, error)
- func (r *PhysicalExamFinding) GetByPatientChartID(id string) error
- func (r *PhysicalExamFinding) Save() error
- func (r *PhysicalExamFinding) Update() error
- type Pupils
- type QueueDestination
- func (r *QueueDestination) Delete(ID int) error
- func (r *QueueDestination) Get(ID int) error
- func (r *QueueDestination) GetAll(p PaginationInput) ([]QueueDestination, int64, error)
- func (r *QueueDestination) GetByTitle(title string) error
- func (r *QueueDestination) GetUserTypeFromDestination(destination string) string
- func (r *QueueDestination) Save() error
- func (r *QueueDestination) Seed()
- func (r *QueueDestination) Update() (*QueueDestination, error)
- type QueueSubscription
- type QueueType
- type Referral
- type ReferralOrder
- func (r *ReferralOrder) ConfirmOrder(referralOrderID int, referralID int, billingID *int, invoiceNo *string, ...) error
- func (r *ReferralOrder) Delete(ID int) error
- func (r *ReferralOrder) GetAll(p PaginationInput, filter *FollowUpOrder) ([]ReferralOrder, int64, error)
- func (r *ReferralOrder) GetByPatientChartID(patientChartID int) error
- func (r *ReferralOrder) GetCount(filter *ReferralOrder, date *time.Time, searchTerm *string) (int64, error)
- func (r *ReferralOrder) GetTodaysOrderedCount() (count int)
- func (r *ReferralOrder) Save(patientChartID int, patientID int, orderedToID *int, referralType ReferralType, ...) error
- func (r *ReferralOrder) Search(p PaginationInput, filter *ReferralOrder, date *time.Time, searchTerm *string, ...) ([]ReferralOrder, int64, error)
- func (r *ReferralOrder) Update() error
- type ReferralOrderStatus
- type ReferralStatus
- type ReferralType
- type ReviewOfSystem
- func (r *ReviewOfSystem) Delete(ID int) error
- func (r *ReviewOfSystem) Get(ID int) error
- func (r *ReviewOfSystem) GetAll(p PaginationInput, filter *ReviewOfSystem) ([]ReviewOfSystem, int64, error)
- func (r *ReviewOfSystem) GetByPatientHistoryID(id string) error
- func (r *ReviewOfSystem) Save() error
- func (r *ReviewOfSystem) Update() error
- type Room
- type SlitLampExam
- type Supply
- func (r *Supply) Delete(ID int) error
- func (r *Supply) Get(ID int) error
- func (r *Supply) GetAll(p PaginationInput, searchTerm *string) ([]Supply, int64, error)
- func (r *Supply) GetByIds(ids []*int) ([]Supply, error)
- func (r *Supply) GetByTitle(title string) error
- func (r *Supply) Save() error
- func (r *Supply) Update() error
- type SurgeryStatus
- type SurgicalOrder
- func (r *SurgicalOrder) ConfirmOrder(surgicalOrderID int, surgicalProcedureID int, invoiceNo string, roomID int, ...) error
- func (r *SurgicalOrder) Delete(ID int) error
- func (r *SurgicalOrder) GetAll(p PaginationInput, filter *SurgicalOrder) ([]SurgicalOrder, int64, error)
- func (r *SurgicalOrder) GetByPatientChartID(patientChartID int) error
- func (r *SurgicalOrder) GetCount(filter *SurgicalOrder, date *time.Time, searchTerm *string) (int64, error)
- func (r *SurgicalOrder) GetTodaysOrderedCount() (count int)
- func (r *SurgicalOrder) SaveOpthalmologyOrder(surgicalProcedureTypeID int, patientChartID int, patientID int, billingID int, ...) error
- func (r *SurgicalOrder) Search(p PaginationInput, filter *SurgicalOrder, date *time.Time, searchTerm *string, ...) ([]SurgicalOrder, int64, error)
- func (r *SurgicalOrder) Update() error
- type SurgicalOrderStatus
- type SurgicalProcedure
- func (r *SurgicalProcedure) Delete(ID int) error
- func (r *SurgicalProcedure) DeleteFile(association string, surgicalProcedureID int, fileID int) error
- func (r *SurgicalProcedure) Get(ID int) error
- func (r *SurgicalProcedure) GetAll(p PaginationInput, filter *SurgicalProcedure) ([]SurgicalProcedure, int64, error)
- func (r *SurgicalProcedure) GetByPatient(p PaginationInput, patientID int) ([]SurgicalProcedure, int64, error)
- func (r *SurgicalProcedure) GetByPatientChart(ID int) error
- func (r *SurgicalProcedure) Save() error
- func (r *SurgicalProcedure) Update() error
- type SurgicalProcedureType
- func (r *SurgicalProcedureType) Delete(ID int) error
- func (r *SurgicalProcedureType) Get(ID int) error
- func (r *SurgicalProcedureType) GetAll(p PaginationInput, searchTerm *string) ([]SurgicalProcedureType, int64, error)
- func (r *SurgicalProcedureType) GetByTitle(title string) error
- func (r *SurgicalProcedureType) Save() error
- func (r *SurgicalProcedureType) Update() error
- type System
- type SystemSymptom
- func (r *SystemSymptom) Delete(ID int) error
- func (r *SystemSymptom) Get(ID int) error
- func (r *SystemSymptom) GetAll(p PaginationInput, searchTerm *string) ([]SystemSymptom, int64, error)
- func (r *SystemSymptom) GetByTitle(title string) error
- func (r *SystemSymptom) Save() error
- func (r *SystemSymptom) Update() error
- type Treatment
- func (r *Treatment) Delete(ID int) error
- func (r *Treatment) Get(ID int) error
- func (r *Treatment) GetAll(p PaginationInput, filter *Treatment) ([]Treatment, int64, error)
- func (r *Treatment) GetByPatient(p PaginationInput, patientID int) ([]Treatment, int64, error)
- func (r *Treatment) GetByPatientChart(ID int) error
- func (r *Treatment) Save() error
- func (r *Treatment) Update() error
- type TreatmentOrder
- func (r *TreatmentOrder) ConfirmOrder(treatmentOrderID int, treatmentID int, invoiceNo string, roomID int, ...) error
- func (r *TreatmentOrder) Delete(ID int) error
- func (r *TreatmentOrder) GetAll(p PaginationInput, filter *TreatmentOrder) ([]TreatmentOrder, int64, error)
- func (r *TreatmentOrder) GetByPatientChartID(patientChartID int) error
- func (r *TreatmentOrder) GetCount(filter *TreatmentOrder, date *time.Time, searchTerm *string) (int64, error)
- func (r *TreatmentOrder) GetTodaysOrderedCount() (count int)
- func (r *TreatmentOrder) SaveOpthalmologyTreatment(treatmentTypeID int, patientChartID int, patientID int, billingID int, ...) error
- func (r *TreatmentOrder) Search(p PaginationInput, filter *TreatmentOrder, date *time.Time, searchTerm *string, ...) ([]TreatmentOrder, int64, error)
- func (r *TreatmentOrder) Update() error
- type TreatmentOrderStatus
- type TreatmentStatus
- type TreatmentType
- func (r *TreatmentType) Delete(ID int) error
- func (r *TreatmentType) Get(ID int) error
- func (r *TreatmentType) GetAll(p PaginationInput, searchTerm *string) ([]TreatmentType, int64, error)
- func (r *TreatmentType) GetByTitle(title string) error
- func (r *TreatmentType) Save() error
- func (r *TreatmentType) Update() error
- type User
- func (r *User) AfterCreate(tx *gorm.DB) error
- func (r *User) CheckIfUserLegacy(oldUserName string) error
- func (r *User) CheckPassword(providedPassword string) error
- func (r *User) CheckPasswordEquality(password1 string, password2 string) bool
- func (r *User) Get(ID int) error
- func (r *User) GetAll(p PaginationInput) ([]User, int64, error)
- func (r *User) GetByEmail(email string) error
- func (r *User) GetByOldUserName(userName string) error
- func (r *User) GetByUserType(userTypeID int) (users []User, err error)
- func (r *User) GetByUserTypeTitle(userTypeTitle string) ([]*User, error)
- func (r *User) HashPassword() error
- func (r *User) Ping() error
- func (r *User) Save(userTypes []UserType) error
- func (r *User) Search(p PaginationInput, filter *User, searchTerm *string) ([]User, int64, error)
- func (r *User) SearchPhysicians(searchTerm string) ([]*User, error)
- func (r *User) Seed()
- func (r *User) Update(userTypes []UserType) error
- type UserType
- func (r *UserType) Delete(ID int) error
- func (r *UserType) Get(ID int) error
- func (r *UserType) GetAll(p PaginationInput) ([]UserType, int64, error)
- func (r *UserType) GetByIds(ids []*int) ([]UserType, error)
- func (r *UserType) GetByTitle(title string) error
- func (r *UserType) Save() error
- func (r *UserType) Seed()
- func (r *UserType) Update() (*UserType, error)
- type VisitType
- func (r *VisitType) Count(dbString string) (int64, error)
- func (r *VisitType) Delete(ID int) error
- func (r *VisitType) Get(ID int) error
- func (r *VisitType) GetAll(p PaginationInput) ([]VisitType, int64, error)
- func (r *VisitType) GetByTitle(title string) error
- func (r *VisitType) GetByTitles(titles []string) ([]VisitType, error)
- func (r *VisitType) Save() error
- func (r *VisitType) Seed()
- func (r *VisitType) Update() error
- type VisualAcuity
- type VitalSigns
Constants ¶
const ( OrderedOrderStatus OrderStatus = "ORDERED" CompletedOrderStatus OrderStatus = "COMPLETED" DiagnosticOrderType OrderType = "DIAGNOSTIC_PROCEDURE" SurgicalOrderType OrderType = "SURGICAL_PROCEDURE" FollowUpOrderType OrderType = "FOLLOW_UP" InHouseReferralOrderType OrderType = "PATIENT_IN_HOUSE_REFERRAL" OutsourceReferralOrderType OrderType = "PATIENT_OUTSOURCE_REFERRAL" TreatmentOrderType OrderType = "TREATMENT" LabOrderType OrderType = "LABRATORY" )
Enums ...
const ( ReferralStatusOrdered ReferralStatus = "ORDERED" ReferralStatusCompleted ReferralStatus = "COMPLETED" ReferralTypeInHouse ReferralType = "PATIENT_IN_HOUSE_REFERRAL" ReferralTypeOutsource ReferralType = "PATIENT_OUTSOURCE_REFERRAL" )
SurgicalProcedureOrder statuses ...
Variables ¶
var DB *gorm.DB
Global variable
Functions ¶
Types ¶
type Allergy ¶
type Allergy struct {
gorm.Model
ID int `gorm:"primaryKey" json:"id"`
Title string `json:"title"`
IssueSeverity string `json:"issueSeverity"`
IssueReaction string `json:"issueReaction"`
IssueOutcome string `json:"issueOutcome"`
IssueOccurrence string `json:"issueOccurrence"`
PatientHistoryID int `json:"patientHistoryId"`
Count int64 `json:"count"`
}
Allergy ...
type Amendment ¶
type Amendment struct {
gorm.Model
ID int `gorm:"primaryKey"`
PatientChartID int `json:"patientChartId"`
Note string `json:"note"`
Count int64 `json:"count"`
}
Amendment ...
type Appointment ¶
type Appointment struct {
gorm.Model
ID int `gorm:"primaryKey" json:"id"`
PatientID int `json:"patientId"`
Patient Patient `json:"patient"`
FirstName string `json:"firstName"`
LastName string `json:"lastName"`
PhoneNo string `json:"phoneNo"`
CheckInTime time.Time `json:"checkInTime" gorm:"index:check_in_time_idx"`
CheckedInTime *time.Time `json:"checkedInTime" gorm:"index:daily_appointment_idx"`
CheckedOutTime time.Time `json:"checkedOutTime"`
RoomID int `json:"roomId"`
Room Room `json:"room"`
VisitTypeID int `json:"visitTypeId"`
VisitType VisitType `json:"visitType"`
AppointmentStatusID int `json:"appointmentStatusId" gorm:"index:daily_appointment_idx"`
AppointmentStatus AppointmentStatus `json:"appointmentStatus"`
Emergency *bool `json:"emergency"`
MedicalDepartment string `json:"medicalDepartment"`
Credit bool `json:"credit"`
Payments []Payment `json:"payments" gorm:"many2many:appointment_payments;"`
Files []File `json:"files" gorm:"many2many:appointment_files"`
UserID int `json:"userId"`
ProviderName string `json:"providerName"`
PatientChart PatientChart `json:"patientChart"`
QueueID int `json:"queueId"`
QueueName string `json:"queueName"`
Document string `gorm:"type:tsvector"`
Count int64 `json:"count"`
}
Appointment ...
func (*Appointment) AfterCreate ¶
func (r *Appointment) AfterCreate(tx *gorm.DB) error
AfterCreate ...
func (*Appointment) CreateNewAppointment ¶
func (r *Appointment) CreateNewAppointment(billingID *int, invoiceNo *string) error
CreateNewAppointment ... Creates a new appointment along with PatientChart
func (*Appointment) FindAppointmentsByPatientAndRange ¶
func (r *Appointment) FindAppointmentsByPatientAndRange(patientID int, start time.Time, end time.Time) ([]*Appointment, error)
FindAppointmentsByPatientAndRange ...
func (*Appointment) FindByProvider ¶
func (r *Appointment) FindByProvider(p PaginationInput, searchTerm *string, visitTypes []string, userID int) ([]Appointment, int64, error)
FindByProvider ...
func (*Appointment) FindByUserSubscriptions ¶
func (r *Appointment) FindByUserSubscriptions(ids []int, searchTerm *string, visitTypes []string, p PaginationInput) ([]Appointment, int64, error)
GetByIds ...
func (*Appointment) FindTodaysAppointments ¶
func (r *Appointment) FindTodaysAppointments(p PaginationInput, searchTerm *string) ([]Appointment, int64, error)
FindTodaysAppointments ...
func (*Appointment) FindTodaysCheckedInAppointments ¶
func (r *Appointment) FindTodaysCheckedInAppointments(p PaginationInput, searchTerm *string, visitTypes []string) ([]Appointment, int64, error)
FindTodaysCheckedInAppointments ...
func (*Appointment) GetAll ¶
func (r *Appointment) GetAll(p PaginationInput, filter *Appointment) ([]Appointment, int64, error)
GetAll ...
func (*Appointment) GetByIds ¶
func (r *Appointment) GetByIds(ids []int, p PaginationInput) ([]Appointment, int64, error)
GetByIds ...
func (*Appointment) GetWithDetails ¶
func (r *Appointment) GetWithDetails(ID int) error
GetWithDetails ...
func (*Appointment) NurseHomeStats ¶
func (r *Appointment) NurseHomeStats() (int, int, int, error)
NurseHomeStats ...
func (*Appointment) PatientsAppointmentToday ¶
func (r *Appointment) PatientsAppointmentToday(patientID int, checkedIn *bool) (Appointment, error)
PatientsAppointmentsToday ...
func (*Appointment) PayForConsultation ¶
PayForConsultation ...
func (*Appointment) PhysicianHomeStats ¶
PhysicianHomeStats ...
func (*Appointment) ReceptionHomeStats ¶
func (r *Appointment) ReceptionHomeStats() (int, int, int, error)
ReceptionHomeStats ...
func (*Appointment) SchedulePostOp ¶
func (r *Appointment) SchedulePostOp(appointment Appointment) error
SchedulePostOp ...
func (*Appointment) SearchAppointments ¶
func (r *Appointment) SearchAppointments(page PaginationInput, p AppointmentSearchInput) ([]Appointment, int64, error)
SearchAppointments ...
type AppointmentQueue ¶
type AppointmentQueue struct {
gorm.Model
ID int `gorm:"primaryKey" json:"id"`
AppointmentID int `json:"appointmentId"`
Appointment Appointment `json:"appointment"`
QueueDestinationID int `json:"queueDestinationId"`
QueueDestination QueueDestination `json:"queueDestination"`
Count int64 `json:"count"`
}
AppointmentQueue ...
func (*AppointmentQueue) FindByAppointment ¶
func (r *AppointmentQueue) FindByAppointment(p PaginationInput, userID int) ([]AppointmentQueue, int64, error)
FindByAppointment ...
func (*AppointmentQueue) FindTodaysAppointments ¶
func (r *AppointmentQueue) FindTodaysAppointments(appointmentID int) ([]AppointmentQueue, error)
FindTodaysAppointments ...
func (*AppointmentQueue) Update ¶
func (r *AppointmentQueue) Update() (*AppointmentQueue, error)
Update ...
type AppointmentSearchInput ¶
type AppointmentSearchInput struct {
SearchTerm *string `json:"searchTerm"`
UserID *int `json:"userId"`
PatientID *int `json:"patientId"`
AppointmentStatusID *string `json:"appointmentStatusId"`
VisitTypeID *string `json:"visitTypeId"`
CheckInTime *time.Time `json:"checkInTime"`
}
AppointmentSearchInput ...
type AppointmentStatus ¶
type AppointmentStatus struct {
gorm.Model
ID int `gorm:"primaryKey"`
Title string `json:"title" gorm:"uniqueIndex"`
}
AppointmentStatus ...
func (*AppointmentStatus) Count ¶
func (r *AppointmentStatus) Count(dbString string) (int64, error)
Count ...
func (*AppointmentStatus) GetAll ¶
func (r *AppointmentStatus) GetAll(p PaginationInput) ([]AppointmentStatus, int64, error)
GetAll ...
func (*AppointmentStatus) GetByTitle ¶
func (r *AppointmentStatus) GetByTitle(title string) error
GetByTitle ...
func (*AppointmentStatus) Update ¶
func (r *AppointmentStatus) Update() (*AppointmentStatus, error)
Update ...
type AutoRefraction ¶
type AutoRefraction struct {
gorm.Model
ID int `gorm:"primaryKey"`
RightDistanceSph *string `json:"rightDistanceSph"`
LeftDistanceSph *string `json:"leftDistanceSph"`
RightDistanceAxis *string `json:"rightDistanceAxis"`
LeftDistanceAxis *string `json:"leftDistanceAxis"`
RightDistanceCyl *string `json:"rightDistanceCyl"`
LeftDistanceCyl *string `json:"leftDistanceCyl"`
RightNearSph *string `json:"rightNearSph"`
LeftNearSph *string `json:"leftNearSph"`
RightNearCyl *string `json:"rightNearCyl"`
LeftNearCyl *string `json:"leftNearCyl"`
RightNearAxis *string `json:"rightNearAxis"`
LeftNearAxis *string `json:"leftNearAxis"`
RightLensMeterSph *string `json:"rightLensMeterSph"`
LeftLensMeterSph *string `json:"leftLensMeterSph"`
RightLensMeterAxis *string `json:"rightLensMeterAxis"`
LeftLensMeterAxis *string `json:"leftLensMeterAxis"`
RightLensMeterCyl *string `json:"rightLensMeterCyl"`
LeftLensMeterCyl *string `json:"leftLensMeterCyl"`
PatientChartID int `json:"patientChartId" gorm:"unique"`
}
AutoRefraction ...
func (*AutoRefraction) GetByPatientChart ¶
func (r *AutoRefraction) GetByPatientChart(ID int) error
GetByPatientChart ...
func (*AutoRefraction) SaveForPatientChart ¶
func (r *AutoRefraction) SaveForPatientChart() error
SaveForPatientChart ...
type Billing ¶
type Billing struct {
gorm.Model
ID int `gorm:"primaryKey"`
Item string `json:"item"`
Code string `json:"code"`
Price float64 `json:"price"`
Credit bool `json:"credit"`
Remark string `json:"remark"`
Document string `gorm:"type:tsvector"`
Count int64 `json:"count"`
}
Billing ...
func (*Billing) GetAll ¶
func (r *Billing) GetAll(p PaginationInput) ([]Billing, int64, error)
GetAll ...
func (*Billing) GetConsultationBillings ¶
GetConsultationBillings ...
type Chat ¶
type Chat struct {
gorm.Model
ID int `gorm:"primaryKey"`
RecentMessage string `json:"recentMessage"`
ChatMembers []ChatMember `json:"chatMembers"`
ChatMutes []ChatMute `json:"chatMutes"`
ChatDeletes []ChatDelete `json:"chatDeletes"`
ChatUnreadMessages []ChatUnreadMessage `json:"chatUnreadMessages"`
ChatMessages []ChatMessage `json:"chatMessages"`
}
Chat ...
func (*Chat) GetUserChats ¶
GetUserChats ...
type ChatDelete ¶
type ChatDelete struct {
gorm.Model
ID int `gorm:"primaryKey"`
UserID int `json:"userId"`
ChatID int `json:"chatId"`
Count int64 `json:"count"`
}
ChatDelete ...
type ChatMember ¶
type ChatMember struct {
gorm.Model
ID int `gorm:"primaryKey"`
UserID int `json:"userId"`
ChatID int `json:"chatId"`
DisplayName string `json:"displayName"`
PhotoURL *string `json:"photoUrl"`
}
ChatMemeber ...
func (*ChatMember) FindCommonChatID ¶
func (r *ChatMember) FindCommonChatID(userID int, recipientID int) (int, error)
FindCommonChatID ...
func (*ChatMember) GetByChatID ¶
func (r *ChatMember) GetByChatID(ID int) ([]*ChatMember, error)
GetByChatID ...
type ChatMessage ¶
type ChatMessage struct {
gorm.Model
ID int `gorm:"primaryKey"`
Body string `json:"body"`
ChatID int `json:"chatId"`
UserID int `json:"userId"`
}
ChatMessage ...
func (*ChatMessage) GetByChatID ¶
func (r *ChatMessage) GetByChatID(ID int) ([]*ChatMessage, error)
GetByChatID ...
type ChatMute ¶
type ChatMute struct {
gorm.Model
ID int `gorm:"primaryKey"`
UserID int `json:"userId"`
ChatID int `json:"chatId"`
}
ChatMute ...
type ChatUnreadMessage ¶
type ChatUnreadMessage struct {
gorm.Model
ID int `gorm:"primaryKey"`
UserID int `json:"userId"`
ChatID int `json:"chatId"`
}
ChatUnreadMessage ...
func (*ChatUnreadMessage) DeleteForUserChat ¶
func (r *ChatUnreadMessage) DeleteForUserChat(userID int, chatID int) error
Delete ...
func (*ChatUnreadMessage) GetByUserID ¶
func (r *ChatUnreadMessage) GetByUserID(ID int) ([]*ChatUnreadMessage, error)
GetByUserID ...
type ChiefComplaint ¶
type ChiefComplaint struct {
gorm.Model
ID int `gorm:"primaryKey"`
Title string `json:"title"`
PatientChartID int `json:"patientChartId"`
HPIComponents []HpiComponent `gorm:"many2many:complaint_hpi_components"`
Count int64 `json:"count"`
OldId int `json:"oldId"`
}
ChiefComplaint ...
func (*ChiefComplaint) GetAll ¶
func (r *ChiefComplaint) GetAll(p PaginationInput, filter *ChiefComplaint) ([]ChiefComplaint, int64, error)
GetAll ...
func (*ChiefComplaint) Search ¶
func (r *ChiefComplaint) Search(p PaginationInput, searchTerm string) ([]ChiefComplaint, int64, error)
Search ...
type ChiefComplaintType ¶
type ChiefComplaintType struct {
gorm.Model
ID int `gorm:"primaryKey" json:"id"`
Title string `json:"title"`
Count int64 `json:"count"`
Active bool `json:"active"`
}
ChiefComplaintType ...
func (*ChiefComplaintType) GetAll ¶
func (r *ChiefComplaintType) GetAll(p PaginationInput, searchTerm *string) ([]ChiefComplaintType, int64, error)
GetAll ...
func (*ChiefComplaintType) GetByTitle ¶
func (r *ChiefComplaintType) GetByTitle(title string) error
GetByTitle ...
func (*ChiefComplaintType) GetFavorites ¶
func (r *ChiefComplaintType) GetFavorites(p PaginationInput, searchTerm *string, userId int) ([]ChiefComplaintType, int64, error)
GetFavorites ...
type CoverTest ¶
type CoverTest struct {
gorm.Model
ID int `gorm:"primaryKey"`
RightCoverTest *string `json:"rightCoverTest"`
LeftCoverTest *string `json:"leftCoverTest"`
Note *string `json:"note"`
PatientChartID int `json:"patientChartId"`
}
CoverTest ...
func (*CoverTest) GetByPatientChart ¶
GetByPatientChart ...
func (*CoverTest) SaveForPatientChart ¶
SaveForPatientChart ...
type Diagnosis ¶
type Diagnosis struct {
ID int `gorm:"primaryKey" json:"id"`
CategoryCode *string `json:"categoryCode"`
DiagnosisCode *string `json:"diagnosisCode"`
FullCode *string `json:"fullCode"`
AbbreviatedDescription *string `json:"abbreviatedDescription"`
FullDescription string `json:"fullDescription"`
CategoryTitle *string `json:"categoryTitle"`
Active bool `json:"active"`
Document string `gorm:"type:tsvector"`
Count int64 `json:"count"`
}
Diagnosis ...
func (*Diagnosis) GetFavorites ¶
func (r *Diagnosis) GetFavorites(p PaginationInput, searchTerm *string, userId int) ([]Diagnosis, int64, error)
GetFavorites ...
type DiagnosticProcedure ¶
type DiagnosticProcedure struct {
gorm.Model
ID int `gorm:"primaryKey"`
DiagnosticProcedureOrderID int `json:"diagnosticProcedureOrderId"`
PatientChartID int `json:"patientChartId"`
GeneralText *string `json:"generalText"`
Images []File `json:"images" gorm:"many2many:diagnostic_images"`
Documents []File `json:"documents" gorm:"many2many:diagnostic_documents"`
IsRefraction bool `json:"isRefraction"`
RightDistanceSubjectiveSph *string `json:"rightDistanceSubjectiveSph"`
LeftDistanceSubjectiveSph *string `json:"leftDistanceSubjectiveSph"`
RightDistanceSubjectiveCyl *string `json:"rightDistanceSubjectiveCyl"`
LeftDistanceSubjectiveCyl *string `json:"leftDistanceSubjectiveCyl"`
RightDistanceSubjectiveAxis *string `json:"rightDistanceSubjectiveAxis"`
LeftDistanceSubjectiveAxis *string `json:"leftDistanceSubjectiveAxis"`
RightNearSubjectiveSph *string `json:"rightNearSubjectiveSph"`
LeftNearSubjectiveSph *string `json:"leftNearSubjectiveSph"`
RightNearSubjectiveCyl *string `json:"rightNearSubjectiveCyl"`
LeftNearSubjectiveCyl *string `json:"leftNearSubjectiveCyl"`
RightNearSubjectiveAxis *string `json:"rightNearSubjectiveAxis"`
LeftNearSubjectiveAxis *string `json:"leftNearSubjectiveAxis"`
RightDistanceObjectiveSph *string `json:"rightDistanceObjectiveSph"`
LeftDistanceObjectiveSph *string `json:"leftDistanceObjectiveSph"`
RightDistanceObjectiveCyl *string `json:"rightDistanceObjectiveCyl"`
LeftDistanceObjectiveCyl *string `json:"leftDistanceObjectiveCyl"`
RightDistanceObjectiveAxis *string `json:"rightDistanceObjectiveAxis"`
LeftDistanceObjectiveAxis *string `json:"leftDistanceObjectiveAxis"`
RightNearObjectiveSph *string `json:"rightNearObjectiveSph"`
LeftNearObjectiveSph *string `json:"leftNearObjectiveSph"`
RightNearObjectiveCyl *string `json:"rightNearObjectiveCyl"`
LeftNearObjectiveCyl *string `json:"leftNearObjectiveCyl"`
RightNearObjectiveAxis *string `json:"rightNearObjectiveAxis"`
LeftNearObjectiveAxis *string `json:"leftNearObjectiveAxis"`
RightDistanceFinalSph *string `json:"rightDistanceFinalSph"`
LeftDistanceFinalSph *string `json:"leftDistanceFinalSph"`
RightDistanceFinalCyl *string `json:"rightDistanceFinalCyl"`
LeftDistanceFinalCyl *string `json:"leftDistanceFinalCyl"`
RightDistanceFinalAxis *string `json:"rightDistanceFinalAxis"`
LeftDistanceFinalAxis *string `json:"leftDistanceFinalAxis"`
RightNearFinalSph *string `json:"rightNearFinalSph"`
LeftNearFinalSph *string `json:"leftNearFinalSph"`
RightNearFinalCyl *string `json:"rightNearFinalCyl"`
LeftNearFinalCyl *string `json:"leftNearFinalCyl"`
RightNearFinalAxis *string `json:"rightNearFinalAxis"`
LeftNearFinalAxis *string `json:"leftNearFinalAxis"`
RightVisualAcuity *string `json:"rightVisualAcuity"`
LeftVisualAcuity *string `json:"leftVisualAcuity"`
FarPd *string `json:"farPd"`
NearPd *string `json:"nearPd"`
DiagnosticProcedureTypeID int `json:"diagnosticProcedureTypeId"`
DiagnosticProcedureType DiagnosticProcedureType `json:"diagnosticProcedureType"`
DiagnosticProcedureTypeTitle string `json:"diagnosticProcedureTypeTitle"`
Payments []Payment `json:"payments" gorm:"many2many:diagnostic_procedure_payments;constraint:OnUpdate:CASCADE,OnDelete:CASCADE;"`
Status DiagnosticProcedureStatus `json:"status"`
OrderNote string `json:"orderNote"`
ReceptionNote string `json:"receptionNote"`
Count int64 `json:"count"`
OldId int `json:"oldId"`
}
DiagnosticProcedure ...
func (*DiagnosticProcedure) ClearAssociation ¶
func (r *DiagnosticProcedure) ClearAssociation(association string, diagnosticProcedureID int) error
ClearAssociation ...
func (*DiagnosticProcedure) DeleteFile ¶
func (r *DiagnosticProcedure) DeleteFile(association string, diagnosticProcedureID int, fileID int) error
DeleteFile ...
func (*DiagnosticProcedure) GetAll ¶
func (r *DiagnosticProcedure) GetAll(p PaginationInput, filter *DiagnosticProcedure) ([]DiagnosticProcedure, int64, error)
GetAll ...
func (*DiagnosticProcedure) GetByPatientChartID ¶
func (r *DiagnosticProcedure) GetByPatientChartID(ID int) error
GetByPatientChartID ...
func (*DiagnosticProcedure) GetRefraction ¶
func (r *DiagnosticProcedure) GetRefraction(patientChartID int) error
GetRefraction ...
type DiagnosticProcedureOrder ¶
type DiagnosticProcedureOrder struct {
gorm.Model
ID int `gorm:"primaryKey"`
PatientChartID int `json:"patientChartId"`
PatientID int `json:"patientId"`
FirstName string `json:"firstName"`
LastName string `json:"lastName"`
PhoneNo string `json:"phoneNo"`
UserName string `json:"userName"`
OrderedByID *int `json:"orderedById"`
OrderedBy *User `json:"orderedBy"`
Status DiagnosticProcedureOrderStatus `json:"status"`
DiagnosticProcedures []DiagnosticProcedure `json:"diagnosticProcedures"`
Document string `gorm:"type:tsvector"`
Count int64 `json:"count"`
}
DiagnosticProcedureOrder struct holds the order of the diagnostic procedures.
func (*DiagnosticProcedureOrder) Confirm ¶
func (r *DiagnosticProcedureOrder) Confirm(id int, invoiceNo string) error
Confirm ...
func (*DiagnosticProcedureOrder) Delete ¶
func (r *DiagnosticProcedureOrder) Delete(ID int) error
Delete ...
func (*DiagnosticProcedureOrder) GetAll ¶
func (r *DiagnosticProcedureOrder) GetAll(p PaginationInput, filter *DiagnosticProcedureOrder) ([]DiagnosticProcedureOrder, int64, error)
GetAll ...
func (*DiagnosticProcedureOrder) GetByPatientChartID ¶
func (r *DiagnosticProcedureOrder) GetByPatientChartID(patientChartID int) error
GetByPatientChartID ...
func (*DiagnosticProcedureOrder) GetCount ¶
func (r *DiagnosticProcedureOrder) GetCount(filter *DiagnosticProcedureOrder, date *time.Time, searchTerm *string) (int64, error)
GetCount ...
func (*DiagnosticProcedureOrder) GetPatientDiagnosticProcedureTitles ¶
func (r *DiagnosticProcedureOrder) GetPatientDiagnosticProcedureTitles(patientID int) ([]string, error)
GetPatientDiagnosticOrderTitles ...
func (*DiagnosticProcedureOrder) GetTodaysOrderedCount ¶
func (r *DiagnosticProcedureOrder) GetTodaysOrderedCount() (count int)
GetTodaysOrderedCount ...
func (*DiagnosticProcedureOrder) OrderAndConfirm ¶
func (r *DiagnosticProcedureOrder) OrderAndConfirm()
OrderAndConfirm ...
func (*DiagnosticProcedureOrder) Save ¶
func (r *DiagnosticProcedureOrder) Save(diagnosticProcedureTypeID int, patientChartID int, patientID int, billingID int, user User, orderNote string, receptionNote string) error
Save ...
func (*DiagnosticProcedureOrder) Search ¶
func (r *DiagnosticProcedureOrder) Search(p PaginationInput, filter *DiagnosticProcedureOrder, date *time.Time, searchTerm *string, ascending bool) ([]DiagnosticProcedureOrder, int64, error)
Search ...
func (*DiagnosticProcedureOrder) Update ¶
func (r *DiagnosticProcedureOrder) Update() error
Update ...
type DiagnosticProcedureOrderStatus ¶
type DiagnosticProcedureOrderStatus string
DiagnosticProcedureOrderStatus ...
const ( DiagnosticProcedureOrderOrderedStatus DiagnosticProcedureOrderStatus = "ORDERED" DiagnosticProcedureOrderCompletedStatus DiagnosticProcedureOrderStatus = "COMPLETED" )
DiagnosticProcedureOrder statuses ...
type DiagnosticProcedureStatus ¶
type DiagnosticProcedureStatus string
DiagnosticProcedureStatus ...
const ( DiagnosticProcedureOrderedStatus DiagnosticProcedureStatus = "ORDERED" DiagnosticProcedureCompletedStatus DiagnosticProcedureStatus = "COMPLETED" )
DiagnosticProcedureOrder statuses ...
type DiagnosticProcedureType ¶
type DiagnosticProcedureType struct {
gorm.Model
ID int `gorm:"primaryKey" json:"id"`
Title string `json:"title"`
Active bool `json:"active"`
Billings []Billing `json:"billings" gorm:"many2many:diagnostic_procedure_type_billings" `
Count int64 `json:"count"`
}
DiagnosticProcedureType ...
func (*DiagnosticProcedureType) Delete ¶
func (r *DiagnosticProcedureType) Delete(ID int) error
Delete ...
func (*DiagnosticProcedureType) GetAll ¶
func (r *DiagnosticProcedureType) GetAll(p PaginationInput, searchTerm *string) ([]DiagnosticProcedureType, int64, error)
GetAll ...
func (*DiagnosticProcedureType) GetByTitle ¶
func (r *DiagnosticProcedureType) GetByTitle(title string) error
GetByTitle ...
func (*DiagnosticProcedureType) Update ¶
func (r *DiagnosticProcedureType) Update() error
Update ...
type ExamCategory ¶
type ExamCategory struct {
gorm.Model
ID int `json:"id" gorm:"primaryKey"`
Title string `json:"title"`
Count int64 `json:"count"`
Active bool `json:"active"`
}
ExamCategory ...
func (*ExamCategory) GetAll ¶
func (r *ExamCategory) GetAll(p PaginationInput, searchTerm *string) ([]ExamCategory, int64, error)
GetAll ...
func (*ExamCategory) GetByTitle ¶
func (r *ExamCategory) GetByTitle(title string) error
GetByTitle ...
type ExamFinding ¶
type ExamFinding struct {
gorm.Model
ID int `gorm:"primaryKey" json:"id"`
Title string `json:"title"`
Pertinence bool `json:"pertinence"`
ExamCategoryID int `json:"examCategoryId"`
ExamCategory ExamCategory `json:"examCategory"`
Active bool `json:"active"`
Count int64 `json:"count"`
}
ExamFinding ...
func (*ExamFinding) GetAll ¶
func (r *ExamFinding) GetAll(p PaginationInput, searchTerm *string) ([]ExamFinding, int64, error)
GetAll ...
func (*ExamFinding) GetByTitle ¶
func (r *ExamFinding) GetByTitle(title string) error
GetByTitle ...
type ExternalExam ¶
type ExternalExam struct {
gorm.Model
ID int `gorm:"primaryKey"`
RightOrbits *string `json:"rightOrbits"`
LeftOrbits *string `json:"leftOrbits"`
RightLids *string `json:"rightLids"`
LeftLids *string `json:"leftLids"`
RightLacrimalSystem *string `json:"rightLacrimalSystem"`
LeftLacrimalSystem *string `json:"leftLacrimalSystem"`
Note *string `json:"note"`
PatientChartID int `json:"patientChartId"`
}
ExternalExam ...
func (*ExternalExam) GetByPatientChart ¶
func (r *ExternalExam) GetByPatientChart(ID int) error
GetByPatientChart ...
func (*ExternalExam) SaveForPatientChart ¶
func (r *ExternalExam) SaveForPatientChart() error
SaveForPatientChart ...
type EyewearPrescription ¶
type EyewearPrescription struct {
gorm.Model
ID int `gorm:"primaryKey"`
EyewearPrescriptionOrderID int `json:"eyewearPrescriptionOrderId"`
PatientID int `json:"patientId"`
Patient Patient `json:"patient"`
Glass *bool `json:"glass"`
Plastic *bool `json:"plastic"`
SingleVision *bool `json:"singleVision"`
PhotoChromatic *bool `json:"photoChromatic"`
GlareFree *bool `json:"glareFree"`
ScratchResistant *bool `json:"scratchResistant"`
Bifocal *bool `json:"bifocal"`
Progressive *bool `json:"progressive"`
TwoSeparateGlasses *bool `json:"twoSeparateGlasses"`
HighIndex *bool `json:"highIndex"`
Tint *bool `json:"tint"`
BlueCut *bool `json:"blueCut"`
PrescribedDate *time.Time `json:"prescribedDate"`
History bool `json:"history"`
Status string `json:"status"`
Count int64 `json:"count"`
}
EyewearPrescription ...
func (*EyewearPrescription) GetAll ¶
func (r *EyewearPrescription) GetAll(p PaginationInput, filter *EyewearPrescription) ([]EyewearPrescription, int64, error)
GetAll ...
type EyewearPrescriptionOrder ¶
type EyewearPrescriptionOrder struct {
gorm.Model
ID int `gorm:"primaryKey"`
EyewearShopID int `json:"eyewearShopId"`
EyewearShop EyewearShop `json:"eyewearShop"`
PatientChartID int `json:"patientChartId"`
FirstName string `json:"firstName"`
LastName string `json:"lastName"`
PhoneNo string `json:"phoneNo"`
UserName string `json:"userName"`
OrderedByID *int `json:"orderedById"`
OrderedBy *User `json:"orderedBy"`
Status string `json:"status"`
EyewearPrescriptions []EyewearPrescription `json:"eyewearPrescription"`
Count int64 `json:"count"`
}
EyewearPrescriptionOrder ...
func (*EyewearPrescriptionOrder) Delete ¶
func (r *EyewearPrescriptionOrder) Delete(ID int) error
Delete ...
func (*EyewearPrescriptionOrder) GetAll ¶
func (r *EyewearPrescriptionOrder) GetAll(p PaginationInput, filter *EyewearPrescriptionOrder) ([]EyewearPrescriptionOrder, int64, error)
GetAll ...
func (*EyewearPrescriptionOrder) GetByPatientChartID ¶
func (r *EyewearPrescriptionOrder) GetByPatientChartID(patientChartID int) error
GetByPatientChartID ...
func (*EyewearPrescriptionOrder) SaveEyewearPrescription ¶
func (r *EyewearPrescriptionOrder) SaveEyewearPrescription(eyewearPrescription EyewearPrescription, patientID int) error
SaveEyewearPrescription ...
func (*EyewearPrescriptionOrder) Search ¶
func (r *EyewearPrescriptionOrder) Search(p PaginationInput, filter *EyewearPrescriptionOrder, date *time.Time, searchTerm *string, ascending bool) ([]EyewearPrescriptionOrder, int64, error)
Search ...
func (*EyewearPrescriptionOrder) Update ¶
func (r *EyewearPrescriptionOrder) Update() error
Update ...
type EyewearShop ¶
type EyewearShop struct {
gorm.Model
ID int `gorm:"primaryKey"`
Title string `json:"title" gorm:"uniqueIndex"`
Address string `json:"address"`
Region string `json:"region"`
Country string `json:"country"`
Phone string `json:"phone"`
InHouse bool `json:"inHouse"`
Count int64 `json:"count"`
Active bool `json:"active"`
}
EyewearShop is a repository for the EyewearShop domain.
func (*EyewearShop) GetAll ¶
func (r *EyewearShop) GetAll(p PaginationInput, filter *EyewearShop) ([]EyewearShop, int64, error)
GetAll ...
type FamilyIllness ¶
type FamilyIllness struct {
gorm.Model
ID int `gorm:"primaryKey" json:"id"`
Title string `json:"title"`
Description string `json:"description"`
PatientHistoryID int `json:"patientHistoryID"`
}
FamilyIllness ...
func (*FamilyIllness) GetByPatientHistoryID ¶
func (r *FamilyIllness) GetByPatientHistoryID(ID int) ([]*FamilyIllness, error)
GetByPatientHistoryID ...
type FavoriteChiefComplaint ¶
type FavoriteChiefComplaint struct {
gorm.Model
ID int `gorm:"primaryKey" json:"id"`
ChiefComplaintTypeID int `json:"chiefComplaintTypeId"`
ChiefComplaintType ChiefComplaintType `json:"chiefComplaintType"`
UserID int `json:"user_id"`
User User `json:"user"`
Count int64 `json:"count"`
}
FavoriteChiefComplaint ...
func (*FavoriteChiefComplaint) Delete ¶
func (r *FavoriteChiefComplaint) Delete(id int) error
Delete ...
func (*FavoriteChiefComplaint) GetByUser ¶
func (r *FavoriteChiefComplaint) GetByUser(ID int) ([]*FavoriteChiefComplaint, error)
GetByUser ...
type FavoriteDiagnosis ¶
type FavoriteDiagnosis struct {
gorm.Model
ID int `gorm:"primaryKey" json:"id"`
DiagnosisID int `json:"diagnosisId"`
Diagnosis Diagnosis `json:"diagnosis"`
UserID int `json:"user_id"`
User User `json:"user"`
Count int64 `json:"count"`
}
FavoriteDiagnosis ...
func (*FavoriteDiagnosis) GetByUser ¶
func (r *FavoriteDiagnosis) GetByUser(ID int) ([]*FavoriteDiagnosis, error)
GetByUser ...
type FavoriteMedication ¶
type FavoriteMedication struct {
gorm.Model
ID int `gorm:"primaryKey" json:"id"`
Medication string `json:"medication"`
Sig string `json:"sig"`
RxCui *string `json:"rxCui"`
Synonym *string `json:"synonym"`
Tty *string `json:"tty"`
Language *string `json:"language"`
Refill int `json:"refill"`
Generic bool `json:"generic"`
SubstitutionAllowed bool `json:"substitutionAllowed"`
DirectionToPatient string `json:"directionToPatient"`
UserID int `json:"user_id"`
User User `json:"user"`
Count int64 `json:"count"`
}
FavoriteMedication ...
func (*FavoriteMedication) GetAll ¶
func (r *FavoriteMedication) GetAll(p PaginationInput, filter *FavoriteMedication, searchTerm *string) ([]FavoriteMedication, int64, error)
GetAll ...
func (*FavoriteMedication) Search ¶
func (r *FavoriteMedication) Search(p PaginationInput, searchTerm string) ([]FavoriteMedication, int64, error)
Search ...
type File ¶
type File struct {
gorm.Model
ID int `gorm:"primaryKey"`
ContentType string `json:"contentType"`
FileName string `json:"fileName"`
Extension string `json:"extension"`
Hash string `json:"hash"`
Size int64 `json:"size"`
}
File ...
type FollowUp ¶
type FollowUp struct {
gorm.Model
ID int `gorm:"primaryKey"`
FollowUpOrderID int `json:"followUpOrderId"`
PatientChartID int `json:"patientChartId"`
Status FollowUpStatus `json:"status"`
ReceptionNote string `json:"receptionNote"`
Count int64 `json:"count"`
}
FollowUp ...
func (*FollowUp) GetByPatientChart ¶
GetByPatientChart ...
type FollowUpOrder ¶
type FollowUpOrder struct {
gorm.Model
ID int `gorm:"primaryKey"`
PatientChartID int `json:"patientChartId"`
PatientID int `json:"patientId"`
FirstName string `json:"firstName"`
LastName string `json:"lastName"`
PhoneNo string `json:"phoneNo"`
UserName string `json:"userName"`
OrderedByID int `json:"orderedById"`
OrderedBy User `json:"orderedBy"`
Status FollowUpOrderStatus `json:"status"`
FollowUps []FollowUp `json:"followUps"`
Emergency *bool `json:"emergency"`
Document string `gorm:"type:tsvector"`
Count int64 `json:"count"`
}
FollowUpOrder ...
func (*FollowUpOrder) ConfirmOrder ¶
func (r *FollowUpOrder) ConfirmOrder(followUpOrderID int, followUpID int, billingID *int, invoiceNo *string, roomID int, checkInTime time.Time) error
ConfirmOrder ...
func (*FollowUpOrder) GetAll ¶
func (r *FollowUpOrder) GetAll(p PaginationInput, filter *FollowUpOrder) ([]FollowUpOrder, int64, error)
GetAll ...
func (*FollowUpOrder) GetByPatientChartID ¶
func (r *FollowUpOrder) GetByPatientChartID(patientChartID int) error
GetByPatientChartID ...
func (*FollowUpOrder) GetCount ¶
func (r *FollowUpOrder) GetCount(filter *FollowUpOrder, date *time.Time, searchTerm *string) (int64, error)
GetCount ...
func (*FollowUpOrder) GetTodaysOrderedCount ¶
func (r *FollowUpOrder) GetTodaysOrderedCount() (count int)
GetTodaysOrderedCount ...
func (*FollowUpOrder) Save ¶
func (r *FollowUpOrder) Save(patientChartID int, patientID int, user User, receptionNote string) error
Save ...
func (*FollowUpOrder) Search ¶
func (r *FollowUpOrder) Search(p PaginationInput, filter *FollowUpOrder, date *time.Time, searchTerm *string, ascending bool) ([]FollowUpOrder, int64, error)
Search ...
type FollowUpOrderStatus ¶
type FollowUpOrderStatus string
FollowUpOrderStatus ...
const ( FollowUpOrderStatusOrdered FollowUpOrderStatus = "ORDERED" FollowUpOrderStatusCompleted FollowUpOrderStatus = "COMPLETED" )
FollowUpOrderStatus statuses ...
type FollowUpStatus ¶
type FollowUpStatus string
FollowUpStatus ...
const ( FollowUpStatusOrdered FollowUpStatus = "ORDERED" FollowUpStatusCompleted FollowUpStatus = "COMPLETED" )
SurgicalProcedureOrder statuses ...
type Funduscopy ¶
type Funduscopy struct {
gorm.Model
ID int `gorm:"primaryKey"`
RightRetina *string `json:"rightRetina"`
LeftRetina *string `json:"leftRetina"`
Note *string `json:"note"`
LeftRetinaSketch *string `json:"leftRetinaSketch"`
RightRetinaSketch *string `json:"rightRetinaSketch"`
PatientChartID int `json:"patientChartId"`
}
Funduscopy ...
func (*Funduscopy) GetByPatientChart ¶
func (r *Funduscopy) GetByPatientChart(ID int) error
GetByPatientChart ...
func (*Funduscopy) SaveForPatientChart ¶
func (r *Funduscopy) SaveForPatientChart() error
SaveForPatientChart ...
type HpiComponent ¶
type HpiComponent struct {
gorm.Model
ID int `gorm:"primaryKey"`
Title string `json:"title"`
HpiComponentTypeID int `json:"hpiComponentTypeId"`
HpiComponentType HpiComponentType `json:"hpiComponentType"`
Count int64 `json:"count"`
}
HpiComponent ...
func (*HpiComponent) GetAll ¶
func (r *HpiComponent) GetAll(p PaginationInput, filter *HpiComponent) ([]HpiComponent, int64, error)
GetAll ...
func (*HpiComponent) GetByIds ¶
func (r *HpiComponent) GetByIds(ids []*int) ([]HpiComponent, error)
GetByIds ...
func (*HpiComponent) Search ¶
func (r *HpiComponent) Search(p PaginationInput, filter *HpiComponent, searchTerm *string) ([]HpiComponent, int64, error)
Search ...
type HpiComponentType ¶
type HpiComponentType struct {
gorm.Model
ID int `gorm:"primaryKey"`
Title string `json:"title"`
Description string `json:"description"`
}
HpiComponentType ...
func (*HpiComponentType) Count ¶
func (r *HpiComponentType) Count(dbString string) (int64, error)
Count ...
func (*HpiComponentType) GetAll ¶
func (r *HpiComponentType) GetAll(p PaginationInput) ([]HpiComponentType, int64, error)
GetAll ...
type Iop ¶
type Iop struct {
gorm.Model
ID int `gorm:"primaryKey"`
RightIop *string `json:"rightIop"`
LeftIop *string `json:"leftIop"`
RightApplanation *string `json:"rightApplanation"`
LeftApplanation *string `json:"leftApplanation"`
RightTonopen *string `json:"rightTonopen"`
LeftTonopen *string `json:"leftTonopen"`
RightDigital *string `json:"rightDigital"`
LeftDigital *string `json:"leftDigital"`
RightNoncontact *string `json:"rightNoncontact"`
LeftNoncontact *string `json:"leftNoncontact"`
PatientChartID int `json:"patientChartId" gorm:"unique"`
}
Iop ...
type Lab ¶
type Lab struct {
gorm.Model
ID int `gorm:"primaryKey"`
LabOrderID int `json:"labOrderId"`
PatientChartID int `json:"patinetChartId"`
// Hematology (CBC)
CbcWbcActive *bool `json:"cbcWbcActive"`
CbcWbcResults *string `json:"cbcWbcResults"`
CbcWbcDate *time.Time `json:"cbcWbcDate"`
CbcHgbActive *bool `json:"cbcHgbActive"`
CbcHgbResults *string `json:"cbcHgbResults"`
CbcHgbDate *time.Time `json:"cbcHgbDate"`
CbcHctActive *bool `json:"cbcHctActive"`
CbcHctResults *string `json:"cbcHctResults"`
CbcHctDate *time.Time `json:"cbcHctDate"`
CbcEsrActive *bool `json:"cbcEsrActive"`
CbcEsrResults *string `json:"cbcEsrResults"`
CbcEsrDate *time.Time `json:"cbcEsrDate"`
CbcBloodGroupActive *bool `json:"cbcBloodGroupActive"`
CbcBloodGroupResults *string `json:"cbcBloodGroupResults"`
CbcBloodGroupDate *time.Time `json:"cbcBloodGroupDate"`
CbcRhActive *bool `json:"cbcRhActive"`
CbcRhResults *string `json:"cbcRhResults"`
CbcRhDate *time.Time `json:"cbcRhDate"`
CbcBloodFilmActive *bool `json:"cbcBloodFilmActive"`
CbcBloodFilmResults *string `json:"cbcBloodFilmResults"`
CbcBloodFilmDate *time.Time `json:"cbcBloodFilmDate"`
CbcPltActive *bool `json:"cbcPltActive"`
CbcPltResults *string `json:"cbcPltResults"`
CbcPltDate *time.Time `json:"cbcPltDate"`
// Liver Function Test
LiverCoagulationPtActive *bool `json:"liverCoagulationPtActive"`
LiverCoagulationPtResults *string `json:"liverCoagulationPtResults"`
LiverCoagulationPtDate *time.Time `json:"liverCoagulationPtDate"`
LiverCoagulationPttActive *bool `json:"liverCoagulationPttActive"`
LiverCoagulationPttResults *string `json:"liverCoagulationPttResults"`
LiverCoagulationPttDate *time.Time `json:"liverCoagulationPttDate"`
LiverCoagulationInrActive *bool `json:"liverCoagulationInrActive"`
LiverCoagulationInrResults *string `json:"liverCoagulationInrResults"`
LiverCoagulationInrDate *time.Time `json:"liverCoagulationInrDate"`
LiverAstsgotActive *bool `json:"liverAstsgotActive"`
LiverAstsgotResults *string `json:"liverAstsgotResults"`
LiverAstsgotDate *time.Time `json:"liverAstsgotDate"`
LiverAltsgptActive *bool `json:"liverAltsgptActive"`
LiverAltsgptResults *string `json:"liverAltsgptResults"`
LiverAltsgptDate *time.Time `json:"liverAltsgptDate"`
LiverAlpActive *bool `json:"liverAlpActive"`
LiverAlpResults *string `json:"liverAlpResults"`
LiverAlpDate *time.Time `json:"liverAlpDate"`
// Renal Function Test
RenalCrActive *bool `json:"renalCrActive"`
RenalCrResults *string `json:"renalCrResults"`
RenalCrDate *time.Time `json:"renalCrDate"`
RenalBunActive *bool `json:"renalBunActive"`
RenalBunResults *string `json:"renalBunResults"`
RenalBunDate *time.Time `json:"renalBunDate"`
// Thyroid Function Test
ThyroidFreeT3Active *bool `json:"thyroidFreeT3Active"`
ThyroidFreeT3Results *string `json:"thyroidFreeT3Results"`
ThyroidFreeT3Date *time.Time `json:"thyroidFreeT3Date"`
ThyroidTotalT4Active *bool `json:"thyroidTotalT4Active"`
ThyroidTotalT4Results *string `json:"thyroidTotalT4Results"`
ThyroidTotalT4Date *time.Time `json:"thyroidTotalT4Date"`
ThyroidTshActive *bool `json:"thyroidTshActive"`
ThyroidTshResults *string `json:"thyroidTshResults"`
ThyroidTshDate *time.Time `json:"thyroidTshDate"`
// Electrolytes
ElectrolytesNaPlusActive *bool `json:"electrolytesNaPlusActive"`
ElectrolytesNaPlusResults *string `json:"electrolytesNaPlusResults"`
ElectrolytesNaPlusDate *time.Time `json:"electrolytesNaPlusDate"`
ElectrolytesKPlusActive *bool `json:"electrolytesKPlusActive"`
ElectrolytesKPlusResults *string `json:"electrolytesKPlusResults"`
ElectrolytesKPlusDate *time.Time `json:"electrolytesKPlusDate"`
ElectrolytesClMinusActive *bool `json:"electrolytesClMinusActive"`
ElectrolytesClMinusResults *string `json:"electrolytesClMinusResults"`
ElectrolytesClMinusDate *time.Time `json:"electrolytesClMinusDate"`
ElectrolytesCa2PlusActive *bool `json:"electrolytesCa2PlusActive"`
ElectrolytesCa2PlusResults *string `json:"electrolytesCa2PlusResults"`
ElectrolytesCa2PlusDate *time.Time `json:"electrolytesCa2PlusDate"`
ElectrolytesMg2PlusActive *bool `json:"electrolytesMg2PlusActive"`
ElectrolytesMg2PlusResults *string `json:"electrolytesMg2PlusResults"`
ElectrolytesMg2PlusDate *time.Time `json:"electrolytesMg2PlusDate"`
ElectrolytesPMinusActive *bool `json:"electrolytesPMinusActive"`
ElectrolytesPMinusResults *string `json:"electrolytesPMinusResults"`
ElectrolytesPMinusDate *time.Time `json:"electrolytesPMinusDate"`
// Stool Examination
StoolConsistencyActive *bool `json:"stoolConsistencyActive"`
StoolConsistencyResults *string `json:"stoolConsistencyResults"`
StoolConsistencyDate *time.Time `json:"stoolConsistencyDate"`
StoolOpActive *bool `json:"stoolOpActive"`
StoolOpResults *string `json:"stoolOpResults"`
StoolOpDate *time.Time `json:"stoolOpDate"`
StoolConcentrationActive *bool `json:"stoolConcentrationActive"`
StoolConcentrationResults *string `json:"stoolConcentrationResults"`
StoolConcentrationDate *time.Time `json:"stoolConcentrationDate"`
StoolOccultBloodActive *bool `json:"stoolOccultBloodActive"`
StoolOccultBloodResults *string `json:"stoolOccultBloodResults"`
StoolOccultBloodDate *time.Time `json:"stoolOccultBloodDate"`
// Microscopy
MicroscopyEpitCellsActive *bool `json:"microscopyEpitCellsActive"`
MicroscopyEpitCellsResults *string `json:"microscopyEpitCellsResults"`
MicroscopyEpitCellsDate *time.Time `json:"microscopyEpitCellsDate"`
MicroscopyWbcActive *bool `json:"microscopyWbcActive"`
MicroscopyWbcResults *string `json:"microscopyWbcResults"`
MicroscopyWbcDate *time.Time `json:"microscopyWbcDate"`
MicroscopyRbcActive *bool `json:"microscopyRbcActive"`
MicroscopyRbcResults *string `json:"microscopyRbcResults"`
MicroscopyRbcDate *time.Time `json:"microscopyRbcDate"`
MicroscopyCastsActive *bool `json:"microscopyCastsActive"`
MicroscopyCastsResults *string `json:"microscopyCastsResults"`
MicroscopyCastsDate *time.Time `json:"microscopyCastsDate"`
MicroscopyCrystalsActive *bool `json:"microscopyCrystalsActive"`
MicroscopyCrystalsResults *string `json:"microscopyCrystalsResults"`
MicroscopyCrystalsDate *time.Time `json:"microscopyCrystalsDate"`
MicroscopyBacteriaActive *bool `json:"microscopyBacteriaActive"`
MicroscopyBacteriaResults *string `json:"microscopyBacteriaResults"`
MicroscopyBacteriaDate *time.Time `json:"microscopyBacteriaDate"`
MicroscopyHcgActive *bool `json:"microscopyHcgActive"`
MicroscopyHcgResults *string `json:"microscopyHcgResults"`
MicroscopyHcgDate *time.Time `json:"microscopyHcgDate"`
// Urinalysis
UrinalysisColorActive *bool `json:"urinalysisColorActive"`
UrinalysisColorResults *string `json:"urinalysisColorResults"`
UrinalysisColorDate *time.Time `json:"urinalysisColorDate"`
UrinalysisAppearanceActive *bool `json:"urinalysisAppearanceActive"`
UrinalysisAppearanceResults *string `json:"urinalysisAppearanceResults"`
UrinalysisAppearanceDate *time.Time `json:"urinalysisAppearanceDate"`
UrinalysisPhActive *bool `json:"urinalysisPhActive"`
UrinalysisPhResults *string `json:"urinalysisPhResults"`
UrinalysisPhDate *time.Time `json:"urinalysisPhDate"`
UrinalysisSgActive *bool `json:"urinalysisSgActive"`
UrinalysisSgResults *string `json:"urinalysisSgResults"`
UrinalysisSgDate *time.Time `json:"urinalysisSgDate"`
UrinalysisProteinActive *bool `json:"urinalysisProteinActive"`
UrinalysisProteinResults *string `json:"urinalysisProteinResults"`
UrinalysisProteinDate *time.Time `json:"urinalysisProteinDate"`
UrinalysisGlucoseActive *bool `json:"urinalysisGlucoseActive"`
UrinalysisGlucoseResults *string `json:"urinalysisGlucoseResults"`
UrinalysisGlucoseDate *time.Time `json:"urinalysisGlucoseDate"`
UrinalysisLeukocyteActive *bool `json:"urinalysisLeukocyteActive"`
UrinalysisLeukocyteResults *string `json:"urinalysisLeukocyteResults"`
UrinalysisLeukocyteDate *time.Time `json:"urinalysisLeukocyteDate"`
UrinalysisKetoneActive *bool `json:"urinalysisKetoneActive"`
UrinalysisKetoneResults *string `json:"urinalysisKetoneResults"`
UrinalysisKetoneDate *time.Time `json:"urinalysisKetoneDate"`
UrinalysisBilirubinActive *bool `json:"urinalysisBilirubinActive"`
UrinalysisBilirubinResults *string `json:"urinalysisBilirubinResults"`
UrinalysisBilirubinDate *time.Time `json:"urinalysisBilirubinDate"`
UrinalysisUrobilingenActive *bool `json:"urinalysisUrobilingenActive"`
UrinalysisUrobilingenResults *string `json:"urinalysisUrobilingenResults"`
UrinalysisUrobilingenDate *time.Time `json:"urinalysisUrobilingenDate"`
UrinalysisBloodActive *bool `json:"urinalysisBloodActive"`
UrinalysisBloodResults *string `json:"urinalysisBloodResults"`
UrinalysisBloodDate *time.Time `json:"urinalysisBloodDate"`
// Serology
SerologyVdrlActive *bool `json:"serologyVdrlActive"`
SerologyVdrlResults *string `json:"serologyVdrlResults"`
SerologyVdrlDate *time.Time `json:"serologyVdrlDate"`
SerologyWidalHActive *bool `json:"serologyWidalHActive"`
SerologyWidalHResults *string `json:"serologyWidalHResults"`
SerologyWidalHDate *time.Time `json:"serologyWidalHDate"`
SerologyWidalOActive *bool `json:"serologyWidalOActive"`
SerologyWidalOResults *string `json:"serologyWidalOResults"`
SerologyWidalODate *time.Time `json:"serologyWidalODate"`
SerologyWeilFelixActive *bool `json:"serologyWeilFelixActive"`
SerologyWeilFelixResults *string `json:"serologyWeilFelixResults"`
SerologyWeilFelixDate *time.Time `json:"serologyWeilFelixDate"`
SerologyHbsAgActive *bool `json:"serologyHbsAgActive"`
SerologyHbsAgResults *string `json:"serologyHbsAgResults"`
SerologyHbsAgDate *time.Time `json:"serologyHbsAgDate"`
SerologyHcvAbActive *bool `json:"serologyHcvAbActive"`
SerologyHcvAbResults *string `json:"serologyHcvAbResults"`
SerologyHcvAbDate *time.Time `json:"serologyHcvAbDate"`
SerologyAsoActive *bool `json:"serologyAsoActive"`
SerologyAsoResults *string `json:"serologyAsoResults"`
SerologyAsoDate *time.Time `json:"serologyAsoDate"`
SerologyRfActive *bool `json:"serologyRfActive"`
SerologyRfResults *string `json:"serologyRfResults"`
SerologyRfDate *time.Time `json:"serologyRfDate"`
SerologyHpayloryAgActive *bool `json:"serologyHpayloryAgActive"`
SerologyHpayloryAgResults *string `json:"serologyHpayloryAgResults"`
SerologyHpayloryAgDate *time.Time `json:"serologyHpayloryAgDate"`
SerologyHpyloryAbActive *bool `json:"serologyHpyloryAbActive"`
SerologyHpyloryAbResults *string `json:"serologyHpyloryAbResults"`
SerologyHpyloryAbDate *time.Time `json:"serologyHpyloryAbDate"`
// Bacterology
BacterologySampleActive *bool `json:"bacterologySampleActive"`
BacterologySampleResults *string `json:"bacterologySampleResults"`
BacterologySampleDate *time.Time `json:"bacterologySampleDate"`
BacterologyKohActive *bool `json:"bacterologyKohActive"`
BacterologyKohResults *string `json:"bacterologyKohResults"`
BacterologyKohDate *time.Time `json:"bacterologyKohDate"`
BacterologyGramStainActive *bool `json:"bacterologyGramStainActive"`
BacterologyGramStainResults *string `json:"bacterologyGramStainResults"`
BacterologyGramStainDate *time.Time `json:"bacterologyGramStainDate"`
BacterologyWetFilmActive *bool `json:"bacterologyWetFilmActive"`
BacterologyWetFilmResults *string `json:"bacterologyWetFilmResults"`
BacterologyWetFilmDate *time.Time `json:"bacterologyWetFilmDate"`
BacterologyAfb1Active *bool `json:"bacterologyAfb1Active"`
BacterologyAfb1Results *string `json:"bacterologyAfb1Results"`
BacterologyAfb1Date *time.Time `json:"bacterologyAfb1Date"`
BacterologyAfb2Active *bool `json:"bacterologyAfb2Active"`
BacterologyAfb2Results *string `json:"bacterologyAfb2Results"`
BacterologyAfb2Date *time.Time `json:"bacterologyAfb2Date"`
BacterologyAfb3Active *bool `json:"bacterologyAfb3Active"`
BacterologyAfb3Results *string `json:"bacterologyAfb3Results"`
BacterologyAfb3Date *time.Time `json:"bacterologyAfb3Date"`
BacterologyCultureActive *bool `json:"bacterologyCultureActive"`
BacterologyCultureResults *string `json:"bacterologyCultureResults"`
BacterologyCultureDate *time.Time `json:"bacterologyCultureDate"`
// Chemistry
ChemistryFbsRbsActive *bool `json:"chemistryFbsRbsActive"`
ChemistryFbsRbsResults *string `json:"chemistryFbsRbsResults"`
ChemistryFbsRbsDate *time.Time `json:"chemistryFbsRbsDate"`
ChemistrySgotActive *bool `json:"chemistrySgotActive"`
ChemistrySgotResults *string `json:"chemistrySgotResults"`
ChemistrySgotDate *time.Time `json:"chemistrySgotDate"`
ChemistrySgptActive *bool `json:"chemistrySgptActive"`
ChemistrySgptResults *string `json:"chemistrySgptResults"`
ChemistrySgptDate *time.Time `json:"chemistrySgptDate"`
ChemistryAlkalinePhosphatesActive *bool `json:"chemistryAlkalinePhosphatesActive"`
ChemistryAlkalinePhosphatesResults *string `json:"chemistryAlkalinePhosphatesResults"`
ChemistryAlkalinePhosphatesDate *time.Time `json:"chemistryAlkalinePhosphatesDate"`
ChemistryBilirubinTotalActive *bool `json:"chemistryBilirubinTotalActive"`
ChemistryBilirubinTotalResults *string `json:"chemistryBilirubinTotalResults"`
ChemistryBilirubinTotalDate *time.Time `json:"chemistryBilirubinTotalDate"`
ChemistryBilirubinDirectActive *bool `json:"chemistryBilirubinDirectActive"`
ChemistryBilirubinDirectResults *string `json:"chemistryBilirubinDirectResults"`
ChemistryBilirubinDirectDate *time.Time `json:"chemistryBilirubinDirectDate"`
ChemistryUreaActive *bool `json:"chemistryUreaActive"`
ChemistryUreaResults *string `json:"chemistryUreaResults"`
ChemistryUreaDate *time.Time `json:"chemistryUreaDate"`
ChemistryBunActive *bool `json:"chemistryBunActive"`
ChemistryBunResults *string `json:"chemistryBunResults"`
ChemistryBunDate *time.Time `json:"chemistryBunDate"`
ChemistryCreatnineActive *bool `json:"chemistryCreatnineActive"`
ChemistryCreatnineResults *string `json:"chemistryCreatnineResults"`
ChemistryCreatnineDate *time.Time `json:"chemistryCreatnineDate"`
ChemistryUricAcidActive *bool `json:"chemistryUricAcidActive"`
ChemistryUricAcidResults *string `json:"chemistryUricAcidResults"`
ChemistryUricAcidDate *time.Time `json:"chemistryUricAcidDate"`
ChemistryTotalProteinActive *bool `json:"chemistryTotalProteinActive"`
ChemistryTotalProteinResults *string `json:"chemistryTotalProteinResults"`
ChemistryTotalProteinDate *time.Time `json:"chemistryTotalProteinDate"`
ChemistryTriglyceridesActive *bool `json:"chemistryTriglyceridesActive"`
ChemistryTriglyceridesResults *string `json:"chemistryTriglyceridesResults"`
ChemistryTriglyceridesDate *time.Time `json:"chemistryTriglyceridesDate"`
ChemistryCholestrolActive *bool `json:"chemistryCholestrolActive"`
ChemistryCholestrolResults *string `json:"chemistryCholestrolResults"`
ChemistryCholestrolDate *time.Time `json:"chemistryCholestrolDate"`
ChemistryHdlActive *bool `json:"chemistryHdlActive"`
ChemistryHdlResults *string `json:"chemistryHdlResults"`
ChemistryHdlDate *time.Time `json:"chemistryHdlDate"`
ChemistryLdlActive *bool `json:"chemistryLdlActive"`
ChemistryLdlResults *string `json:"chemistryLdlResults"`
ChemistryLdlDate *time.Time `json:"chemistryLdlDate"`
RightEyeText *string `json:"rightEyeText"`
LeftEyeText *string `json:"leftEyeText"`
GeneralText *string `json:"generalText"`
RightEyeImages []File `json:"rightEyeImages" gorm:"many2many:lab_right_eye_images" `
LeftEyeImages []File `json:"leftEyeImages" gorm:"many2many:lab_left_eye_images"`
RightEyeSketches []File `json:"rightEyeSketches" gorm:"many2many:lab_right_eye_sketches"`
LeftEyeSketches []File `json:"leftEyeSketches" gorm:"many2many:lab_left_eye_sketches"`
Images []File `json:"images" gorm:"many2many:lab_images"`
Documents []File `json:"documents" gorm:"many2many:lab_documents"`
LabTypeID int `json:"labTypeId"`
LabType LabType `json:"labType"`
LabTypeTitle string `json:"labTypeTitle"`
Payments []Payment `json:"payments" gorm:"many2many:lab_payments;constraint:OnUpdate:CASCADE,OnDelete:CASCADE;"`
OrderNote string `json:"orderNote"`
ReceptionNote string `json:"receptionNote"`
Status LabStatus `json:"status"`
Count int64 `json:"count"`
}
Lab ...
func (*Lab) ClearAssociation ¶
ClearAssociation ...
func (*Lab) DeleteFile ¶
DeleteFile ...
func (*Lab) GetByPatientChartID ¶
GetByPatientChartID ...
type LabOrder ¶
type LabOrder struct {
gorm.Model
ID int `gorm:"primaryKey"`
PatientChartID int `json:"patientChartId"`
PatientID int `json:"patientId"`
FirstName string `json:"firstName"`
LastName string `json:"lastName"`
PhoneNo string `json:"phoneNo"`
UserName string `json:"userName"`
OrderedByID *int `json:"orderedById"`
OrderedBy *User `json:"orderedBy"`
Status LabOrderStatus `json:"status"`
Labs []Lab `json:"labs"`
Document string `gorm:"type:tsvector"`
Count int64 `json:"count"`
}
LabOrder ...
func (*LabOrder) GetByPatientChartID ¶
GetByPatientChartID ...
func (*LabOrder) GetTodaysOrderedCount ¶
GetTodaysOrderedCount ...
func (*LabOrder) Save ¶
func (r *LabOrder) Save(labTypeID int, patientChartID int, patientID int, billingIds []int, user User, orderNote string, receptionNote string) error
NewOrder ...
type LabOrderStatus ¶
type LabOrderStatus string
LabOrderStatus
const ( LabOrderOrderedStatus LabOrderStatus = "ORDERED" LabOrderCompletedStatus LabOrderStatus = "COMPLETED" )
LabOrder statuses
type LabType ¶
type LabType struct {
gorm.Model
ID int `gorm:"primaryKey" json:"id"`
Title string `json:"title"`
Active bool `json:"active"`
Billings []Billing `json:"billings" gorm:"many2many:lab_type_billings" `
Count int64 `json:"count"`
}
LabType ...
type Lifestyle ¶
type Lifestyle struct {
gorm.Model
ID int `gorm:"primaryKey"`
Title string `json:"title"`
Description string `json:"description"`
Note string `json:"note"`
PatientHistoryID int `json:"patientHistoryID"`
}
Lifestyle ...
func (*Lifestyle) GetByPatientHistoryID ¶
GetByPatientHistoryID ...
type LifestyleType ¶
type LifestyleType struct {
gorm.Model
ID int `gorm:"primaryKey" json:"id"`
Title string `json:"title"`
}
LifestyleType ...
func (*LifestyleType) Count ¶
func (r *LifestyleType) Count(dbString string) (int64, error)
Count ...
func (*LifestyleType) GetAll ¶
func (r *LifestyleType) GetAll(p PaginationInput) ([]LifestyleType, int64, error)
GetAll ...
func (*LifestyleType) GetByTitle ¶
func (r *LifestyleType) GetByTitle(title string) error
GetByTitle ...
type MedicalPrescription ¶
type MedicalPrescription struct {
gorm.Model
ID int `gorm:"primaryKey"`
MedicalPrescriptionOrderID *int `json:"medicalPrescriptionOrderId"`
PatientID int `json:"patientId"`
Patient Patient `json:"patient"`
Medication string `json:"medication"`
RxCui *string `json:"rxCui"`
Synonym *string `json:"synonym"`
Tty *string `json:"tty"`
Language *string `json:"language"`
Sig *string `json:"sig"`
Refill *int `json:"refill"`
Generic *bool `json:"generic"`
SubstitutionAllowed *bool `json:"substitutionAllowed"`
DirectionToPatient *string `json:"directionToPatient"`
PrescribedDate *time.Time `json:"prescribedDate"`
History bool `json:"history"`
Status string `json:"status"`
Count int64 `json:"count"`
}
MedicalPrescription ...
func (*MedicalPrescription) GetAll ¶
func (r *MedicalPrescription) GetAll(p PaginationInput, filter *MedicalPrescription) ([]MedicalPrescription, int64, error)
GetAll ...
func (*MedicalPrescription) Search ¶
func (r *MedicalPrescription) Search(p PaginationInput, filter *MedicalPrescription, date *time.Time, searchTerm *string, ascending bool) ([]MedicalPrescription, int64, error)
Search ...
type MedicalPrescriptionOrder ¶
type MedicalPrescriptionOrder struct {
gorm.Model
ID int `gorm:"primaryKey"`
PharmacyID int `json:"pharmacyId"`
Pharmacy Pharmacy `json:"pharmacy"`
PatientChartID int `json:"patientChartId"`
OrderedByID *int `json:"orderedById"`
OrderedBy *User `json:"orderedBy"`
FirstName string `json:"firstName"`
LastName string `json:"lastName"`
PhoneNo string `json:"phoneNo"`
UserName string `json:"userName"`
Status string `json:"status"`
MedicalPrescriptions []MedicalPrescription `json:"medicalPrescriptions"`
Count int64 `json:"count"`
}
MedicalPrescriptionOrder is a gorm struct for the prescription_order table
func (*MedicalPrescriptionOrder) Delete ¶
func (r *MedicalPrescriptionOrder) Delete(ID int) error
Delete ...
func (*MedicalPrescriptionOrder) GetAll ¶
func (r *MedicalPrescriptionOrder) GetAll(p PaginationInput, filter *MedicalPrescriptionOrder) ([]MedicalPrescriptionOrder, int64, error)
GetAll ...
func (*MedicalPrescriptionOrder) GetByPatientChartID ¶
func (r *MedicalPrescriptionOrder) GetByPatientChartID(patientChartID int) error
GetByPatientChartID ...
func (*MedicalPrescriptionOrder) SaveMedicalPrescription ¶
func (r *MedicalPrescriptionOrder) SaveMedicalPrescription(medicalPrescription MedicalPrescription, patientID int) error
SaveMedicalPrescription ...
func (*MedicalPrescriptionOrder) Search ¶
func (r *MedicalPrescriptionOrder) Search(p PaginationInput, filter *MedicalPrescriptionOrder, date *time.Time, searchTerm *string, ascending bool) ([]MedicalPrescriptionOrder, int64, error)
Search ...
func (*MedicalPrescriptionOrder) Update ¶
func (r *MedicalPrescriptionOrder) Update() error
Update ...
type Model ¶
Model facilitate database interactions
func NewModel ¶
func NewModel() *Model
NewModel returns a new Model without opening database connection
func (*Model) AutoMigrateAll ¶
func (m *Model) AutoMigrateAll()
AutoMigrateAll runs migrations for all the registered models
func (*Model) IsOpen ¶
IsOpen returns true if the Model has already established connection to the database
func (*Model) OpenWithConfigTest ¶
func (m *Model) OpenWithConfigTest(cfg *conf.Configuration) error
OpenWithConfigTest opens database connection with test database
type OcularMotility ¶
type OcularMotility struct {
gorm.Model
ID int `gorm:"primaryKey"`
RightOcularMotility *string `json:"rightOcularMotility"`
LeftOcularMotility *string `json:"leftOcularMotility"`
Rsr *string `json:"rsr"`
Rio *string `json:"rio"`
Rlr *string `json:"rlr"`
Rmr *string `json:"rmr"`
Rir *string `json:"rir"`
Rso *string `json:"rso"`
RightFlick *bool `json:"rightFlick"`
Lsr *string `json:"lsr"`
Lio *string `json:"lio"`
Llr *string `json:"llr"`
Lrl *string `json:"lrl"`
Lmr *string `json:"lmr"`
Lir *string `json:"lir"`
Lso *string `json:"lso"`
LeftFlick *bool `json:"leftFlick"`
Distance *string `json:"distance"`
Near *string `json:"near"`
Note *string `json:"note"`
PatientChartID int `json:"patientChartId"`
}
OcularMotility ...
func (*OcularMotility) GetByPatientChart ¶
func (r *OcularMotility) GetByPatientChart(ID int) error
GetByPatientChart ...
func (*OcularMotility) SaveForPatientChart ¶
func (r *OcularMotility) SaveForPatientChart() error
SaveForPatientChart ...
type OpthalmologyExam ¶
type OpthalmologyExam struct {
gorm.Model
ID int `gorm:"primaryKey"`
PatientChartID int `json:"patientChartId" gorm:"uniqueIndex"`
// External Exam
RightOrbits *string `json:"rightOrbits"`
LeftOrbits *string `json:"leftOrbits"`
RightLids *string `json:"rightLids"`
LeftLids *string `json:"leftLids"`
RightLacrimalSystem *string `json:"rightLacrimalSystem"`
LeftLacrimalSystem *string `json:"leftLacrimalSystem"`
ExternalExamNote *string `json:"externalExamNote"`
// Ocular Motility
RightOcularMotility *string `json:"rightOcularMotility"`
LeftOcularMotility *string `json:"leftOcularMotility"`
Rsr *string `json:"rsr"`
Rio *string `json:"rio"`
Rlr *string `json:"rlr"`
Rmr *string `json:"rmr"`
Rir *string `json:"rir"`
Rso *string `json:"rso"`
RightFlick *bool `json:"rightFlick" gorm:"default:false"`
Lsr *string `json:"lsr"`
Lio *string `json:"lio"`
Llr *string `json:"llr"`
Lrl *string `json:"lrl"`
Lmr *string `json:"lmr"`
Lir *string `json:"lir"`
Lso *string `json:"lso"`
LeftFlick *bool `json:"leftFlick" gorm:"default:false"`
Distance *string `json:"distance"`
Near *string `json:"near"`
OcularMotilityNote *string `json:"ocularMotility"`
// Cover Test
RightCoverTest *string `json:"rightCoverTest"`
LeftCoverTest *string `json:"leftCoverTest"`
CoverTestNote *string `json:"coverTestNote"`
// Funduscopy
RightRetina *string `json:"rightRetina"`
LeftRetina *string `json:"leftRetina"`
LeftRetinaSketch *string `json:"leftRetinaSketch"`
RightRetinaSketch *string `json:"rightRetinaSketch"`
FunduscopyNote *string `json:"funduscopyNote"`
// Optic Disc
RightOpticDisc *string `json:"rightOpticDisc"`
LeftOpticDisc *string `json:"leftOpticDisc"`
RightOpticDiscSketch *string `json:"rightOpticDiscSketch"`
LeftOpticDiscSketch *string `json:"leftOpticDiscSketch"`
RightCdr *string `json:"rightCdr"`
LeftCdr *string `json:"leftCdr"`
OpticDiscNote *string `json:"opticDiscNote"`
// Pupils
RightPupils *string `json:"rightPupils"`
LeftPupils *string `json:"leftPupils"`
PupilsNote *string `json:"pupilsNote"`
// Slit Lamp Exam
RightConjunctiva *string `json:"rightConjunctiva"`
LeftConjunctiva *string `json:"leftConjunctiva"`
RightCornea *string `json:"rightCornea"`
LeftCornea *string `json:"leftCornea"`
RightCorneaSketch *string `json:"rightCorneaSketch"`
LeftCorneaSketch *string `json:"leftCorneaSketch"`
LeftSclera *string `json:"leftSclera"`
RightSclera *string `json:"rightSclera"`
RightAnteriorChamber *string `json:"rightAnteriorChamber"`
LeftAnteriorChamber *string `json:"leftAnteriorChamber"`
RightIris *string `json:"rightIris"`
LeftIris *string `json:"leftIris"`
RightLens *string `json:"rightLens"`
LeftLens *string `json:"leftLens"`
RightLensSketch *string `json:"rightLensSketch"`
LeftLensSketch *string `json:"leftLensSketch"`
RightVitreos *string `json:"rightVitreos"`
LeftVitreos *string `json:"leftVitreos"`
SlitLampExamNote *string `json:"slitLampExamNote"`
}
OpthalmologyExam ...
func (*OpthalmologyExam) Get ¶
func (r *OpthalmologyExam) Get(filter OpthalmologyExam) error
Get ...
func (*OpthalmologyExam) GetByPatientChart ¶
func (r *OpthalmologyExam) GetByPatientChart(ID int) error
GetByPatientChart ...
func (*OpthalmologyExam) Recreate ¶
func (r *OpthalmologyExam) Recreate(patientChartID int) error
type OpticDisc ¶
type OpticDisc struct {
gorm.Model
ID int `gorm:"primaryKey"`
RightOpticDisc *string `json:"rightOpticDisc"`
LeftOpticDisc *string `json:"leftOpticDisc"`
RightOpticDiscSketch *string `json:"rightOpticDiscSketch"`
LeftOpticDiscSketch *string `json:"leftOpticDiscSketch"`
RightCdr *string `json:"rightCdr"`
LeftCdr *string `json:"leftCdr"`
Note *string `json:"note"`
PatientChartID int `json:"patientChartId"`
}
OpticDisc ...
func (*OpticDisc) GetByPatientChart ¶
GetByPatientChart ...
func (*OpticDisc) SaveForPatientChart ¶
SaveForPatientChart ...
type Order ¶
type Order struct {
gorm.Model
ID int `gorm:"primaryKey"`
UserID int `json:"userID"`
User User `json:"user"`
FirstName string `json:"firstName"`
LastName string `json:"lastName"`
PhoneNo string `json:"phoneNo"`
UserName string `json:"userName"`
PatientID int `json:"patientId"`
PatientChartID int `json:"patientChartId"`
AppointmentID int `json:"appointmentId"`
Emergency *bool `json:"emergency"`
Note string `json:"note"`
Status OrderStatus `json:"status" sql:"order_status"`
OrderType OrderType `json:"orderType" sql:"order_type"`
Payments []Payment `json:"payments" gorm:"many2many:order_payments;constraint:OnUpdate:CASCADE,OnDelete:CASCADE;"`
Count int64 `json:"count"`
}
Order ...
func (*Order) ConfirmFollowUpOrder ¶
ConfirmFollowUpOrder ...
func (*Order) OrderFollowup ¶
OrderFollowup ...
func (*Order) ProviderOrders ¶
func (r *Order) ProviderOrders(p PaginationInput, searchTerm *string, userId int) ([]Order, int64, error)
ProviderOrders ...
func (*Order) ScheduleSurgery ¶
func (r *Order) ScheduleSurgery(orderID int, roomID int, checkInTime time.Time, invoiceNo string) error
ScheduleSurgery ...
func (*Order) ScheduleTreatment ¶
func (r *Order) ScheduleTreatment(orderID int, roomID int, checkInTime time.Time, invoiceNo string) error
ScheduleSurgery ...
func (*Order) Search ¶
func (r *Order) Search(p PaginationInput, f *OrderFilterInput) ([]Order, int64, error)
GetAll ...
type OrderFilterInput ¶
type OrderFilterInput struct {
AppointmentID *int `json:"appointmentId"`
PatientChartID *int `json:"patientChartId"`
UserID *int `json:"userId"`
Status *string `json:"status"`
OrderType *string `json:"orderType"`
SearchTerm *string `json:"searchTerm"`
Date *time.Time `json:"date"`
}
OrderFilterInput ...
type OrganizationDetails ¶
type OrganizationDetails struct {
gorm.Model
ID int `gorm:"primaryKey" json:"id"`
Name *string `json:"name"`
PhoneNo *string `json:"phoneNo"`
PhoneNo2 *string `json:"phoneNo2"`
Address *string `json:"address"`
Address2 *string `json:"address2"`
Website *string `json:"website"`
Email *string `json:"email"`
LanIpAddress *string `json:"lanIpAddress"`
LogoID *int `json:"logoId"`
Logo *File `json:"logo"`
DefaultMedicalDepartment *string `json:"defaultMedicalDepartment"`
}
OrganizationDetails ...
type PaginationInput ¶
PaginationInput ...
type PastHospitalization ¶
type PastHospitalization struct {
gorm.Model
ID int `gorm:"primaryKey"`
Reason string `json:"reason"`
Provider string `json:"provider"`
From *time.Time `json:"from"`
To *time.Time `json:"to"`
PatientHistoryID int `json:"patientHistoryID"`
}
PastHospitalization ...
func (*PastHospitalization) GetByPatientHistoryID ¶
func (r *PastHospitalization) GetByPatientHistoryID(ID int) ([]*PastHospitalization, error)
GetByPatientHistoryID ...
type PastIllness ¶
type PastIllness struct {
gorm.Model
ID int `gorm:"primaryKey"`
Title string `json:"title"`
Description string `json:"description"`
PatientHistoryID int `json:"patientHistoryId"`
}
PastIllness ...
func (*PastIllness) GetByPatientHistoryID ¶
func (r *PastIllness) GetByPatientHistoryID(ID int) ([]*PastIllness, error)
GetByPatientHistoryID ...
type PastIllnessType ¶
type PastIllnessType struct {
gorm.Model
ID int `gorm:"primaryKey" json:"id"`
Title string `json:"title"`
Count int64 `json:"count"`
}
PastIllnessType ...
func (*PastIllnessType) GetAll ¶
func (r *PastIllnessType) GetAll(p PaginationInput) ([]PastIllnessType, int64, error)
GetAll ...
func (*PastIllnessType) GetByTitle ¶
func (r *PastIllnessType) GetByTitle(title string) error
GetByTitle ...
type PastInjury ¶
type PastInjury struct {
gorm.Model
ID int `gorm:"primaryKey"`
Description string `json:"description"`
InjuryDate *time.Time `json:"injuryDate"`
PatientHistoryID int `json:"patientHistoryID"`
}
PastInjury ...
func (*PastInjury) GetByPatientHistoryID ¶
func (r *PastInjury) GetByPatientHistoryID(ID int) ([]*PastInjury, error)
GetByPatientHistoryID ...
type PastOptSurgery ¶
type PastOptSurgery struct {
gorm.Model
ID int `gorm:"primaryKey"`
Title string `json:"title"`
Description string `json:"description"`
PatientHistoryID int `json:"patientHistoryID"`
}
PastOptSurgery ...
func (*PastOptSurgery) Update ¶
func (r *PastOptSurgery) Update() (*PastOptSurgery, error)
Update ...
type PastSurgery ¶
type PastSurgery struct {
gorm.Model
ID int `gorm:"primaryKey"`
Description string `json:"description"`
SurgeryDate *time.Time `json:"injuryDate"`
PatientHistoryID int `json:"patientHistoryID"`
}
PastSurgery ...
func (*PastSurgery) GetByPatientHistoryID ¶
func (r *PastSurgery) GetByPatientHistoryID(ID int) ([]*PastSurgery, error)
GetByPatientHistoryID ...
type Patient ¶
type Patient struct {
gorm.Model
ID int `gorm:"primaryKey"`
FirstName string `json:"firstName" gorm:"not null;"`
LastName string `json:"lastName" gorm:"not null;"`
FullName string `json:"fullName"`
Gender string `json:"gender"`
PhoneNo string `json:"phoneNo" gorm:"size:100;not null;"`
PhoneNo2 string `json:"phoneNo2" gorm:"size:100;not null;"`
TelNo string `json:"telNo"`
HomePhone string `json:"homePhone"`
Email string `json:"email" gorm:"size:100;not null;"`
DateOfBirth time.Time `json:"dateOfBirth"`
IDNo string `json:"idNo"`
IDType string `json:"idType"`
MartialStatus string `json:"martialStatus"`
Occupation string `json:"occupation"`
Credit *bool `json:"credit"`
CreditCompany *string `json:"creditCompany"`
EmergencyContactName string `json:"emergencyContactName"`
EmergencyContactRel string `json:"emergencyContactRel"`
EmergencyContactPhone string `json:"emergencyContactPhone"`
EmergencyContactPhone2 string `json:"emergencyContactPhone2"`
EmergencyContactMemo string `json:"emergencyContactMemo"`
City string `json:"city"`
SubCity string `json:"subCity"`
Region string `json:"region"`
Woreda string `json:"woreda"`
Zone string `json:"zone"`
Kebele string `json:"kebele"`
HouseNo string `json:"houseNo"`
Memo string `json:"memo"`
CardNo string `json:"cardNo"`
PaperRecord bool `json:"paperRecord"`
PaperRecordDocumentID *int `json:"paperRecordDocumentId"`
PaperRecordDocument *File `json:"paperRecordDocument"`
Documents []File `json:"documents" gorm:"many2many:patient_documents"`
PatientHistory PatientHistory `json:"patientHistory"`
Appointments []Appointment `json:"appointments"`
Document string `gorm:"type:tsvector"`
Count int64 `json:"count"`
}
Patient ...
func (*Patient) AfterUpdate ¶
AfterUpdate ...
func (*Patient) FindByName ¶
FindByName ...
func (*Patient) FindByPhoneNo ¶
FindByPhoneNo ...
func (*Patient) GetAll ¶
func (r *Patient) GetAll(p PaginationInput) ([]Patient, int64, error)
GetAll ...
func (*Patient) GetAllProgress ¶
func (r *Patient) GetAllProgress(patientID int) (*PatientHistory, []*Appointment, error)
GetAllProgress ...
func (*Patient) GetAllProgressNotes ¶
func (r *Patient) GetAllProgressNotes(appointmentID int) (*PatientHistory, []*Appointment, error)
GetAllProgressNotes ...
func (*Patient) GetPatientDiagnosticProcedures ¶
func (r *Patient) GetPatientDiagnosticProcedures(patientID int, diagnosticProcedureTypeTitle string) ([]*Appointment, error)
GetPatientDiagnosticProcedures ...
func (*Patient) GetPatientFiles ¶
GetPatientFiles ...
func (*Patient) GetVitalSignsProgress ¶
func (r *Patient) GetVitalSignsProgress(patientID int) ([]*Appointment, error)
GetVisionProgress ...
type PatientChart ¶
type PatientChart struct {
gorm.Model
ID int `gorm:"primaryKey"`
AppointmentID int `json:"appointmentId"`
VitalSigns VitalSigns `json:"vitalSigns"`
PhysicalExamFindings []PhysicalExamFinding `json:"physicalExamFindings"`
PhysicalExamFindingNote *string `json:"physicalExamFindingNote"`
OpthalmologyExam OpthalmologyExam `json:"opthalmologyExam"`
SurgicalProcedure SurgicalProcedure `json:"surgicalProcedure"`
Treatment Treatment `json:"treatment"`
ChiefComplaints []ChiefComplaint `json:"chiefComplaints"`
ChiefComplaintsNote *string `json:"chiefComplaintNote"`
BloodPressure *string `json:"bloodPressure"`
HpiNote *string `json:"hpiNote"`
DiagnosisNote *string `json:"diagnosisNote"`
DifferentialDiagnosisNote *string `json:"differentialDiagnosisNote"`
RightSummarySketch *string `json:"rightSummarySketch"`
LeftSummarySketch *string `json:"leftSummarySketch"`
SummaryNote *string `json:"summaryNote"`
StickieNote *string `json:"stickieNote"`
MedicalRecommendation *string `json:"medicalRecommendation"`
SickLeave *string `json:"sickLeave"`
MedicalPrescriptionOrder MedicalPrescriptionOrder `json:"medicalPrescriptionOrder"`
EyewearPrescriptionOrder EyewearPrescriptionOrder `json:"eyewearPrescriptionOrder"`
DiagnosticProcedureOrder DiagnosticProcedureOrder `json:"diagnosticProcedureOrder"`
SurgicalOrder SurgicalOrder `json:"surgicalOrder"`
TreatmentOrder TreatmentOrder `json:"treatmentOrder"`
ReferralOrder ReferralOrder `json:"referralOrder"`
FollowUpOrder FollowUpOrder `json:"followUpOrder"`
LabOrder LabOrder `json:"labOrder"`
Diagnoses []PatientDiagnosis `json:"diagnoses"`
Locked *bool `json:"locked"`
LockedDate *time.Time `json:"lockedDate"`
LockedByID *int `json:"lockedById"`
LockedBy *User `json:"lockedBy"`
Amendments []Amendment `json:"amendments"`
OldPatientChartId int `json:"oldPatientChartId"`
}
PatientChart ...
func (*PatientChart) AfterCreate ¶
func (r *PatientChart) AfterCreate(tx *gorm.DB) error
AfterCreate ...
func (*PatientChart) GetByAppointmentID ¶
func (r *PatientChart) GetByAppointmentID(appointmentID int) error
GetByAppointmentID ...
func (*PatientChart) SignAndLock ¶
func (r *PatientChart) SignAndLock(patientChartID int, userID *int) error
SignAndLock ...
type PatientDiagnosis ¶
type PatientDiagnosis struct {
gorm.Model
ID int `gorm:"primaryKey"`
PatientChartID int `json:"patientChartId"`
CategoryCode *string `json:"categoryCode"`
DiagnosisCode *string `json:"diagnosisCode"`
FullCode *string `json:"fullCode"`
AbbreviatedDescription *string `json:"abbreviatedDescription"`
FullDescription string `json:"fullDescription"`
CategoryTitle *string `json:"categoryTitle"`
Location string `json:"location"`
Differential bool `json:"differential"`
Count int64 `json:"count"`
}
PatientDiagnosis ...
func (*PatientDiagnosis) GetAll ¶
func (r *PatientDiagnosis) GetAll(p PaginationInput, filter *PatientDiagnosis) ([]PatientDiagnosis, int64, error)
GetAll ...
func (*PatientDiagnosis) GetByPatientChartID ¶
func (r *PatientDiagnosis) GetByPatientChartID(ID int) error
GetByPatientChartID ...
type PatientEncounterLimit ¶
type PatientEncounterLimit struct {
gorm.Model
ID int `gorm:"primaryKey"`
UserID int `json:"userId" gorm:"uniqueIndex"`
User User `json:"user"`
MondayLimit int `json:"mondayLimit"`
TuesdayLimit int `json:"tuesdayLimit"`
WednesdayLimit int `json:"wednesdayLimit"`
ThursdayLimit int `json:"thursdayLimit"`
FridayLimit int `json:"fridayLimit"`
SaturdayLimit int `json:"saturdayLimit"`
SundayLimit int `json:"sundayLimit"`
Overbook int `json:"overbook"`
Count int64 `json:"count"`
}
PatientEncounterLimit ...
func (*PatientEncounterLimit) Delete ¶
func (r *PatientEncounterLimit) Delete(ID int) error
Delete ...
func (*PatientEncounterLimit) GetAll ¶
func (r *PatientEncounterLimit) GetAll(p PaginationInput) ([]PatientEncounterLimit, int64, error)
GetAll ...
func (*PatientEncounterLimit) GetByUser ¶
func (r *PatientEncounterLimit) GetByUser(userID int) error
GetByUser ...
type PatientHistory ¶
type PatientHistory struct {
gorm.Model
ID int `gorm:"primaryKey" json:"id"`
PatientID int `json:"patientId" gorm:"uniqueIndex"`
ReviewOfSystems []ReviewOfSystem `json:"reviewOfSystems"`
ReviewOfSystemsNote *string `json:"reviewOfSystemsNote"`
PastIllnesses []PastIllness `json:"pastIllnesses"`
PastInjuries []PastInjury `json:"pastInjuries"`
PastHospitalizations []PastHospitalization `json:"pastHospitalizations"`
PastSurgeries []PastSurgery `json:"pastSurgeries"`
FamilyIllnesses []FamilyIllness `json:"familyIllnesses"`
Lifestyles []Lifestyle `json:"lifestyles"`
Allergies []Allergy `json:"allergies"`
}
PatientHistory ...
func (*PatientHistory) GetByPatientID ¶
func (r *PatientHistory) GetByPatientID(ID int) error
GetByPatientID ...
func (*PatientHistory) GetByPatientIDWithDetails ¶
func (r *PatientHistory) GetByPatientIDWithDetails(ID int) error
GetByPatientIDWithDetails ...
type PatientQueue ¶
type PatientQueue struct {
gorm.Model
ID int `gorm:"primaryKey" json:"id"`
QueueName string `json:"queueName"`
Queue datatypes.JSON `json:"queue"`
QueueType QueueType `json:"queueType"`
}
PatientQueue ...
func (*PatientQueue) AddToQueue ¶
func (r *PatientQueue) AddToQueue(toQueueName string, appointmentID int, queueType string) error
AddToQueue
func (*PatientQueue) DeleteFromQueue ¶
func (r *PatientQueue) DeleteFromQueue(patientQueueID int, appointmentID int) error
DeleteFromQueue ...
func (*PatientQueue) GetByQueueName ¶
func (r *PatientQueue) GetByQueueName(queueName string) error
GetByQueueName ...
func (*PatientQueue) Move ¶
func (r *PatientQueue) Move(fromQueueID int, toQueueID int, appointmentID int) error
Move ...
func (*PatientQueue) MoveToQueueName ¶
func (r *PatientQueue) MoveToQueueName(fromQueueID int, toQueueName string, appointmentID int, queueType string) error
MoveToQueueName ...
func (*PatientQueue) UpdateQueue ¶
func (r *PatientQueue) UpdateQueue(queueName string, queue datatypes.JSON) error
GetByQueueName ...
type Payment ¶
type Payment struct {
gorm.Model
ID int `gorm:"primaryKey"`
InvoiceNo string `json:"invoiceNo"`
Status PaymentStatus `json:"status" sql:"payment_status"`
BillingID int `json:"billingId"`
Billing Billing `json:"billing"`
}
Payment ...
func (*Payment) BatchUpdate ¶
BatchUpdate ...
func (*Payment) RequestWaiver ¶
RequestWaiver ...
func (*Payment) RequestWaiverBatch ¶
RequestWaiverBatch ...
type PaymentStatus ¶
type PaymentStatus string
PaymentStatus ...
const ( PaidPaymentStatus PaymentStatus = "PAID" NotPaidPaymentStatus PaymentStatus = "NOTPAID" WaiverRequestedPaymentStatus PaymentStatus = "PAYMENT_WAIVER_REQUESTED" )
Payment statuses ...
type PaymentWaiver ¶
type PaymentWaiver struct {
gorm.Model
ID int `gorm:"primaryKey"`
PaymentID int `json:"paymentId" gorm:"unique"`
Payment Payment `json:"payment"`
UserID int `json:"userID"`
User User `json:"user"`
PatientID int `json:"patientId"`
Patient Patient `json:"patient"`
Approved *bool `json:"approved"`
Count int64 `json:"count"`
}
PaymentWaiver ...
func (*PaymentWaiver) ApproveWaiver ¶
func (r *PaymentWaiver) ApproveWaiver(id int, approve bool) error
ApproveWaiver ...
func (*PaymentWaiver) BatchSave ¶
func (r *PaymentWaiver) BatchSave(waivers []PaymentWaiver) error
BatchSave ...
func (*PaymentWaiver) GetAll ¶
func (r *PaymentWaiver) GetAll(p PaginationInput) ([]PaymentWaiver, int64, error)
GetAll ...
func (*PaymentWaiver) GetApprovedCount ¶
func (r *PaymentWaiver) GetApprovedCount() (int, error)
GetCount ...
type Pharmacy ¶
type Pharmacy struct {
gorm.Model
ID int `gorm:"primaryKey"`
Title string `json:"title" gorm:"uniqueIndex"`
Address string `json:"address"`
Region string `json:"region"`
Country string `json:"country"`
Phone string `json:"phone"`
InHouse bool `json:"inHouse"`
Count int64 `json:"count"`
Active bool `json:"active"`
}
Pharmacy is a repository for the pharmacy domain.
type PhysicalExamFinding ¶
type PhysicalExamFinding struct {
gorm.Model
ID int `gorm:"primaryKey" json:"id"`
PatientChartID int `json:"patientChartId" gorm:"uniqueIndex"`
ExamCategoryID int `json:"examCategoryId"`
ExamCategory ExamCategory `json:"examCategory"`
Abnormal bool `string:"abnormal"`
Note *string `json:"note"`
Count int64 `json:"count"`
}
PhysicalExamFinding ...
func (*PhysicalExamFinding) DeleteExamCategory ¶
func (r *PhysicalExamFinding) DeleteExamCategory(physicalExamFindingID int, examCategoryID int) error
DeleteExamCategory
func (*PhysicalExamFinding) GetAll ¶
func (r *PhysicalExamFinding) GetAll(p PaginationInput, filter *PhysicalExamFinding) ([]PhysicalExamFinding, int64, error)
GetAll ...
func (*PhysicalExamFinding) GetByPatientChartID ¶
func (r *PhysicalExamFinding) GetByPatientChartID(id string) error
GetByTitle ...
type Pupils ¶
type Pupils struct {
gorm.Model
ID int `gorm:"primaryKey"`
RightPupils *string `json:"rightPupils"`
LeftPupils *string `json:"leftPupils"`
Note *string `json:"note"`
PatientChartID int `json:"patientChartId"`
}
Pupils ...
func (*Pupils) GetByPatientChart ¶
GetByPatientChart ...
func (*Pupils) SaveForPatientChart ¶
SaveForPatientChart ...
type QueueDestination ¶
type QueueDestination struct {
gorm.Model
ID int `gorm:"primaryKey" json:"id"`
Title string `json:"title" gorm:"uniqueIndex"`
Count int64 `json:"count"`
}
QueueDestination ...
func (*QueueDestination) GetAll ¶
func (r *QueueDestination) GetAll(p PaginationInput) ([]QueueDestination, int64, error)
GetAll ...
func (*QueueDestination) GetByTitle ¶
func (r *QueueDestination) GetByTitle(title string) error
GetByTitle ...
func (*QueueDestination) GetUserTypeFromDestination ¶
func (r *QueueDestination) GetUserTypeFromDestination(destination string) string
GetUserTypeFromDestination ...
func (*QueueDestination) Update ¶
func (r *QueueDestination) Update() (*QueueDestination, error)
Update ...
type QueueSubscription ¶
type QueueSubscription struct {
gorm.Model
ID int `gorm:"primaryKey" json:"id"`
UserID int `json:"userId" gorm:"uniqueIndex"`
User User `json:"user"`
Subscriptions []PatientQueue `json:"subscriptions" gorm:"many2many:user_queue_subscriptions;"`
}
QueueSubscription ....
func (*QueueSubscription) GetByUserId ¶
func (r *QueueSubscription) GetByUserId(userID int) error
GetByUserId ...
func (*QueueSubscription) Subscribe ¶
func (r *QueueSubscription) Subscribe(userId int, patientQueueId int) error
Subscribe ...
func (*QueueSubscription) Unsubscribe ¶
func (r *QueueSubscription) Unsubscribe(userId int, patientQueueId int) error
Unsubscribe ...
type Referral ¶
type Referral struct {
gorm.Model
ID int `gorm:"primaryKey"`
ReferralOrderID int `json:"referralOrderId"`
PatientChartID int `json:"patientChartId"`
Reason string `json:"reason"`
ReferredToID *int `json:"referredToId"`
ReferredToName string `json:"referredToName"`
Status ReferralStatus `json:"status"`
Type ReferralType `json:"type"`
ReceptionNote string `json:"receptionNote"`
Count int64 `json:"count"`
}
Referral ...
type ReferralOrder ¶
type ReferralOrder struct {
gorm.Model
ID int `gorm:"primaryKey"`
PatientChartID int `json:"patientChartId"`
PatientID int `json:"patientId"`
FirstName string `json:"firstName"`
LastName string `json:"lastName"`
PhoneNo string `json:"phoneNo"`
UserName string `json:"userName"`
OrderedByID int `json:"orderedById"`
OrderedBy User `json:"orderedBy"`
Status ReferralOrderStatus `json:"status"`
Referrals []Referral `json:"referrals"`
Emergency *bool `json:"emergency"`
Document string `gorm:"type:tsvector"`
Count int64 `json:"count"`
}
ReferralOrder ...
func (*ReferralOrder) ConfirmOrder ¶
func (r *ReferralOrder) ConfirmOrder(referralOrderID int, referralID int, billingID *int, invoiceNo *string, roomID *int, checkInTime *time.Time) error
ConfirmOrder ...
func (*ReferralOrder) GetAll ¶
func (r *ReferralOrder) GetAll(p PaginationInput, filter *FollowUpOrder) ([]ReferralOrder, int64, error)
GetAll ...
func (*ReferralOrder) GetByPatientChartID ¶
func (r *ReferralOrder) GetByPatientChartID(patientChartID int) error
GetByPatientChartID ...
func (*ReferralOrder) GetCount ¶
func (r *ReferralOrder) GetCount(filter *ReferralOrder, date *time.Time, searchTerm *string) (int64, error)
GetCount ...
func (*ReferralOrder) GetTodaysOrderedCount ¶
func (r *ReferralOrder) GetTodaysOrderedCount() (count int)
GetTodaysOrderedCount ...
func (*ReferralOrder) Save ¶
func (r *ReferralOrder) Save(patientChartID int, patientID int, orderedToID *int, referralType ReferralType, user User, receptionNote *string, reason string, providerName *string) error
Save ...
func (*ReferralOrder) Search ¶
func (r *ReferralOrder) Search(p PaginationInput, filter *ReferralOrder, date *time.Time, searchTerm *string, ascending bool) ([]ReferralOrder, int64, error)
Search ...
type ReferralOrderStatus ¶
type ReferralOrderStatus string
ReferralOrderStatus ...
const ( ReferralOrderStatusOrdered ReferralOrderStatus = "ORDERED" ReferralOrderStatusCompleted ReferralOrderStatus = "COMPLETED" )
ReferralOrderStatus statuses ...
type ReviewOfSystem ¶
type ReviewOfSystem struct {
gorm.Model
ID int `gorm:"primaryKey" json:"id"`
PatientHistoryID int `json:"patientHistoryId"`
SystemSymptomID int `json:"systemSymptomId"`
SystemSymptom SystemSymptom `json:"systemSymptom"`
Note *string `json:"note"`
Count int64 `json:"count"`
}
ReviewOfSystem ...
func (*ReviewOfSystem) GetAll ¶
func (r *ReviewOfSystem) GetAll(p PaginationInput, filter *ReviewOfSystem) ([]ReviewOfSystem, int64, error)
GetAll ...
func (*ReviewOfSystem) GetByPatientHistoryID ¶
func (r *ReviewOfSystem) GetByPatientHistoryID(id string) error
GetByTitle ...
type Room ¶
type Room struct {
gorm.Model
ID int `gorm:"primaryKey"`
Title string `json:"title" gorm:"unique"`
}
Room ...
type SlitLampExam ¶
type SlitLampExam struct {
gorm.Model
ID int `gorm:"primaryKey"`
RightConjunctiva *string `json:"rightConjunctiva"`
LeftConjunctiva *string `json:"leftConjunctiva"`
RightCornea *string `json:"rightCornea"`
LeftCornea *string `json:"leftCornea"`
RightCorneaSketch *string `json:"rightCorneaSketch"`
LeftCorneaSketch *string `json:"leftCorneaSketch"`
LeftSclera *string `json:"leftSclera"`
RightSclera *string `json:"rightSclera"`
RightAnteriorChamber *string `json:"rightAnteriorChamber"`
LeftAnteriorChamber *string `json:"leftAnteriorChamber"`
RightIris *string `json:"rightIris"`
LeftIris *string `json:"leftIris"`
RightLens *string `json:"rightLens"`
LeftLens *string `json:"leftLens"`
RightLensSketch *string `json:"rightLensSketch"`
LeftLensSketch *string `json:"leftLensSketch"`
RightVitreos *string `json:"rightVitreos"`
LeftVitreos *string `json:"leftVitreos"`
Note *string `json:"note"`
PatientChartID int `json:"patientChartId"`
}
SlitLampExam ...
func (*SlitLampExam) GetByPatientChart ¶
func (r *SlitLampExam) GetByPatientChart(ID int) error
GetByPatientChart ...
func (*SlitLampExam) SaveForPatientChart ¶
func (r *SlitLampExam) SaveForPatientChart() error
SaveForPatientChart ...
type Supply ¶
type Supply struct {
gorm.Model
ID int `gorm:"primaryKey" json:"id"`
Title string `json:"title"`
Active bool `json:"active"`
Billings []Billing `json:"billings" gorm:"many2many:supply_billings"`
Count int64 `json:"count"`
}
Supply ...
type SurgeryStatus ¶
type SurgeryStatus string
SurgeryStatus ...
const ( SurgeryStatusOrdered SurgeryStatus = "ORDERED" SurgeryStatusCompleted SurgeryStatus = "COMPLETED" )
SurgicalProcedureOrder statuses ...
type SurgicalOrder ¶
type SurgicalOrder struct {
gorm.Model
ID int `gorm:"primaryKey"`
PatientChartID int `json:"patientChartId"`
PatientID int `json:"patientId"`
FirstName string `json:"firstName"`
LastName string `json:"lastName"`
PhoneNo string `json:"phoneNo"`
UserName string `json:"userName"`
OrderedByID int `json:"orderedById"`
OrderedBy User `json:"orderedBy"`
Status SurgicalOrderStatus `json:"status"`
SurgicalProcedures []SurgicalProcedure `json:"surgicalProcedures"`
Emergency *bool `json:"emergency"`
Document string `gorm:"type:tsvector"`
Count int64 `json:"count"`
}
SurgicalOrder ...
func (*SurgicalOrder) ConfirmOrder ¶
func (r *SurgicalOrder) ConfirmOrder(surgicalOrderID int, surgicalProcedureID int, invoiceNo string, roomID int, checkInTime time.Time) error
ConfirmOrder ...
func (*SurgicalOrder) GetAll ¶
func (r *SurgicalOrder) GetAll(p PaginationInput, filter *SurgicalOrder) ([]SurgicalOrder, int64, error)
GetAll ...
func (*SurgicalOrder) GetByPatientChartID ¶
func (r *SurgicalOrder) GetByPatientChartID(patientChartID int) error
GetByPatientChartID ...
func (*SurgicalOrder) GetCount ¶
func (r *SurgicalOrder) GetCount(filter *SurgicalOrder, date *time.Time, searchTerm *string) (int64, error)
GetCount ...
func (*SurgicalOrder) GetTodaysOrderedCount ¶
func (r *SurgicalOrder) GetTodaysOrderedCount() (count int)
GetTodaysOrderedCount ...
func (*SurgicalOrder) SaveOpthalmologyOrder ¶
func (r *SurgicalOrder) SaveOpthalmologyOrder(surgicalProcedureTypeID int, patientChartID int, patientID int, billingID int, user User, performOnEye string, orderNote string, receptionNote string) error
SaveOpthalmologyOrder ...
func (*SurgicalOrder) Search ¶
func (r *SurgicalOrder) Search(p PaginationInput, filter *SurgicalOrder, date *time.Time, searchTerm *string, ascending bool) ([]SurgicalOrder, int64, error)
Search ...
type SurgicalOrderStatus ¶
type SurgicalOrderStatus string
SurgicalOrderStatus ...
const ( SurgicalOrderStatusOrdered SurgicalOrderStatus = "ORDERED" SurgicalOrderStatusCompleted SurgicalOrderStatus = "COMPLETED" )
SurgicalOrderStatus statuses ...
type SurgicalProcedure ¶
type SurgicalProcedure struct {
gorm.Model
ID int `gorm:"primaryKey"`
SurgicalOrderID int `json:"surgicalOrderId"`
PatientChartID int `json:"patientChartId"`
// Preasnesthetic
Respiratory *string `json:"respiratory"`
Cardiovascular *string `json:"cardiovascular"`
Abdomen *string `json:"abdomen"`
Gus *string `json:"gus"`
Ismss *string `json:"ismss"`
Cns *string `json:"cns"`
PreanestheticAllergies *bool `json:"preanestheticAllergies"`
PreanestheticAllergiesNote *string `json:"preanestheticAllergiesNote"`
PhysicalBloodPressure *string `json:"physicalBloodPressure"`
PhysicalPr *string `json:"physicalPr"`
PhysicalRr *string `json:"physicalRr"`
PhysicalSaO2 *string `json:"physicalSaO2"`
PhysicalTemperature *string `json:"physicalTemperature"`
PhysicalWeight *string `json:"physicalWeight"`
PhysicalHeent *string `json:"physicalHeent"`
PhysicalArtificalDenture *bool `json:"physicalArtificalDenture"`
PhysicalArtificalDentureNote *string `json:"physicalArtificalDentureNote"`
PhysicalLgs *string `json:"physicalLgs"`
PhysicalChest *string `json:"physicalChest"`
PhysicalCvs *string `json:"physicalCvs"`
PhysicalAbdomen *string `json:"physicalAbdomen"`
PhysicalGus *string `json:"physicalGus"`
PhysicalIs *string `json:"physicalIs"`
PhysicalMss *string `json:"physicalMss"`
PhysicalCns *string `json:"physicalCns"`
WbcActive *bool `json:"wbcActive"`
WbcResults *string `json:"wbcResults"`
WbcDate *time.Time `json:"wbcDate"`
HgbhctActive *bool `json:"hgbhctActive"`
HgbhctResults *string `json:"hgbhctResults"`
HgbhctDate *time.Time `json:"hgbhctDate"`
PltActive *bool `json:"pltActive"`
PltResults *string `json:"pltResults"`
PltDate *time.Time `json:"pltDate"`
CoagulationPtActive *bool `json:"coagulationPtActive"`
CoagulationPtResults *string `json:"coagulationPtResults"`
CoagulationPtDate *time.Time `json:"coagulationPtDate"`
CoagulationPttActive *bool `json:"coagulationPttActive"`
CoagulationPttResults *string `json:"coagulationPttResults"`
CoagulationPttDate *time.Time `json:"coagulationPttDate"`
CoagulationInrActive *bool `json:"coagulationInrActive"`
CoagulationInrResults *string `json:"coagulationInrResults"`
CoagulationInrDate *time.Time `json:"coagulationInrDate"`
SerumAlbuminActive *bool `json:"serumAlbuminActive"`
SerumAlbuminResults *string `json:"serumAlbuminResults"`
SerumAlbuminDate *time.Time `json:"serumAlbuminDate"`
TotalProteinActive *bool `json:"totalProteinActive"`
TotalProteinResults *string `json:"totalProteinResults"`
TotalProteinDate *time.Time `json:"totalProteinDate"`
BilirubinTotalActive *bool `json:"bilirubinTotalActive"`
BilirubinTotalResults *string `json:"bilirubinTotalResults"`
BilirubinTotalDate *time.Time `json:"bilirubinTotalDate"`
BilirubinDirectActive *bool `json:"bilirubinDirectActive"`
BilirubinDirectResults *string `json:"bilirubinDirectResults"`
BilirubinDirectDate *time.Time `json:"bilirubinDirectDate"`
AstsgotActive *bool `json:"astsgotActive"`
AstsgotResults *string `json:"astsgotResults"`
AstsgotDate *time.Time `json:"astsgotDate"`
AltsgptActive *bool `json:"altsgptActive"`
AltsgptResults *string `json:"altsgptResults"`
AltsgptDate *time.Time `json:"altsgptDate"`
AlpActive *bool `json:"alpActive"`
AlpResults *string `json:"alpResults"`
AlpDate *time.Time `json:"alpDate"`
RenalCrActive *bool `json:"renalCrActive"`
RenalCrResults *string `json:"renalCrResults"`
RenalCrDate *time.Time `json:"renalCrDate"`
RenalBunActive *bool `json:"renalBunActive"`
RenalBunResults *string `json:"renalBunResults"`
RenalBunDate *time.Time `json:"renalBunDate"`
ThyroidFreeT3Active *bool `json:"thyroidFreeT3Active"`
ThyroidFreeT3Results *string `json:"thyroidFreeT3Results"`
ThyroidFreeT3Date *time.Time `json:"thyroidFreeT3Date"`
ThyroidTotalT4Active *bool `json:"thyroidTotalT4Active"`
ThyroidTotalT4Results *string `json:"thyroidTotalT4Results"`
ThyroidTotalT4Date *time.Time `json:"thyroidTotalT4Date"`
ThyroidTshActive *bool `json:"thyroidTshActive"`
ThyroidTshResults *string `json:"thyroidTshResults"`
ThyroidTshDate *time.Time `json:"thyroidTshDate"`
ElectrolytesNaPlusActive *bool `json:"electrolytesNaPlusActive"`
ElectrolytesNaPlusResults *string `json:"electrolytesNaPlusResults"`
ElectrolytesNaPlusDate *time.Time `json:"electrolytesNaPlusDate"`
ElectrolytesKPlusActive *bool `json:"electrolytesKPlusActive"`
ElectrolytesKPlusResults *string `json:"electrolytesKPlusResults"`
ElectrolytesKPlusDate *time.Time `json:"electrolytesKPlusDate"`
ElectrolytesClMinusActive *bool `json:"electrolytesClMinusActive"`
ElectrolytesClMinusResults *string `json:"electrolytesClMinusResults"`
ElectrolytesClMinusDate *time.Time `json:"electrolytesClMinusDate"`
ElectrolytesCa2PlusActive *bool `json:"electrolytesCa2PlusActive"`
ElectrolytesCa2PlusResults *string `json:"electrolytesCa2PlusResults"`
ElectrolytesCa2PlusDate *time.Time `json:"electrolytesCa2PlusDate"`
ElectrolytesMg2PlusActive *bool `json:"electrolytesMg2PlusActive"`
ElectrolytesMg2PlusResults *string `json:"electrolytesMg2PlusResults"`
ElectrolytesMg2PlusDate *time.Time `json:"electrolytesMg2PlusDate"`
ElectrolytesPMinusActive *bool `json:"electrolytesPMinusActive"`
ElectrolytesPMinusResults *string `json:"electrolytesPMinusResults"`
ElectrolytesPMinusDate *time.Time `json:"electrolytesPMinusDate"`
Asa1 *bool `json:"asa1"`
Asa2 *bool `json:"asa2"`
Asa3 *bool `json:"asa3"`
Asa4 *bool `json:"asa4"`
Asa5 *bool `json:"asa5"`
Opv1 *bool `json:"opv1"`
Opv2 *bool `json:"opv2"`
Opv3 *bool `json:"opv3"`
Opv4 *bool `json:"opv4"`
BleedingTendancy *bool `json:"bleedingTendancy"`
BleedingTendancyNote *string `json:"bleedingTendancyNote"`
Dm *bool `json:"dm"`
DmNote *string `json:"dmNote"`
Hypertension *bool `json:"hypertension"`
HypertensionNote *string `json:"hypertensionNote"`
Cardiac *bool `json:"cardiac"`
CardiacNote *string `json:"cardiacNote"`
PreanestheticAsthma *bool `json:"preanestheticAsthma"`
PreanestheticAsthmaNote *string `json:"preanestheticAsthmaNote"`
Rvi *bool `json:"rvi"`
RviNote *string `json:"rviNote"`
Renal *bool `json:"renal"`
RenalNote *string `json:"renalNote"`
PreanestheticPerformedBy *int `json:"preanestheticPerformedBy"`
FitForSurgery *bool `json:"fitForSurgery"`
FitForSurgeryNote *string `json:"fitForSurgeryNote"`
PreanestheticDocuments []File `json:"preanestheticDocuments" gorm:"many2many:surgical_procedure_preanesthetic_documents"`
// Pre-operation
RightCorrected *string `json:"rightCorrected"`
LeftCorrected *string `json:"leftCorrected"`
RightIop *string `json:"rightIop"`
LeftIop *string `json:"leftIop"`
RightAnteriorSegment *string `json:"rightAnteriorSegment"`
LeftAnteriorSegment *string `json:"leftAnteriorSegment"`
RightPosteriorSegment *string `json:"rightPosteriorSegment"`
LeftPosteriorSegment *string `json:"leftPosteriorSegment"`
RightBiometry *string `json:"rightBiometry"`
LeftBiometry *string `json:"leftBiometry"`
Diabetes *string `json:"diabetes"`
Hpn *string `json:"hpn"`
Asthma *string `json:"asthma"`
CardiacDisease *string `json:"cardiacDisease"`
Allergies *string `json:"allergies"`
BloodPressure *string `json:"bloodPressure"`
BloodSugar *string `json:"bloodSugar"`
URIAnalysis *string `json:"uriAnalysis"`
// Intra-operation
PerformOnEye string `json:"performOnEye"`
La *bool `json:"la"`
Ga *bool `json:"ga"`
Retrobulbar *bool `json:"retrobulbar"`
Peribulbar *bool `json:"peribulbar"`
Subtenones *bool `json:"subtenones"`
Topical *bool `json:"topical"`
ConjFlapLimbal *bool `json:"conjFlapLimbal"`
ConjFlapFornix *bool `json:"conjFlapFornix"`
SectionLimbal *bool `json:"sectionLimbal"`
SectionCorneral *bool `json:"sectionCorneral"`
SectionScleralTunnel *bool `json:"sectionScleralTunnel"`
CapsulotomyLinear *bool `json:"capsulotomyLinear"`
CapsulotomyCanOpener *bool `json:"capsulotomyCanOpener"`
CapsulotomyCcc *bool `json:"capsulotomyCcc"`
IolPlacementBag *bool `json:"iolPlacementBag"`
IolSulcus *bool `json:"iolSulcus"`
IolBagSulcus *bool `json:"iolBagSulcus"`
IrodectpmyNone *bool `json:"irodectpmyNone"`
IrodectpmyPl *bool `json:"irodectpmyPl"`
IrodectpmySl *bool `json:"irodectpmySl"`
Sphincterectomy *bool `json:"sphincterectomy"`
LensExtractionIcce *bool `json:"lensExtractionIcce"`
LensExtractionEcce *bool `json:"lensExtractionEcce"`
LensExtractionPhaco *bool `json:"lensExtractionPhaco"`
SutureNone *bool `json:"sutureNone"`
SutureContinuous *bool `json:"sutureContinuous"`
SutureInterrupted *bool `json:"sutureInterrupted"`
Drapes *bool `json:"drapes"`
Ringer *bool `json:"ringer"`
Bss *bool `json:"bss"`
Air *bool `json:"air"`
Hpmc *bool `json:"hpmc"`
Healon *bool `json:"healon"`
Pilo *bool `json:"pilo"`
Adrenalin *bool `json:"adrenalin"`
Antibiotic *bool `json:"antibiotic"`
Steroid *bool `json:"steroid"`
Suture80 *bool `json:"suture80"`
Suture90 *bool `json:"suture90"`
Suture100 *bool `json:"suture100"`
IrrigatingSolution *string `json:"irrigatingSolution"`
Visco *string `json:"visco"`
Interacameral *string `json:"interacameral"`
Subconj *string `json:"subconj"`
Suture *string `json:"suture"`
Silk *bool `json:"silk"`
Nylon *bool `json:"nylon"`
PcTear *bool `json:"pcTear"`
VitreousLoss *bool `json:"vitreousLoss"`
DescematesStrip *bool `json:"descematesStrip"`
EndothelialDamage *bool `json:"endothelialDamage"`
NucluesDrop *bool `json:"nucluesDrop"`
IridoDialysis *bool `json:"iridoDialysis"`
IrisDamage *bool `json:"irisDamage"`
RetainedCortex *bool `json:"retainedCortex"`
Hyphema *bool `json:"hyphema"`
ComplicationsOthers *string `json:"complicationsOthers"`
ComplicationsNote *string `json:"complicationsNote"`
Vitrectomy *string `json:"vitrectomy"`
TypeOfIolAc *bool `json:"typeOfIolAc"`
TypeOfIolPc *bool `json:"typeOfIolPc"`
TypeOfIol *string `json:"typeOfIol"`
IolModel *string `json:"iolModel"`
Company *string `json:"company"`
Aclol *string `json:"aclol"`
AclolPlanned *bool `json:"aclolPlanned"`
AclolUnplanned *bool `json:"aclolUnplanned"`
Unplanned *string `json:"unplanned"`
AdditionalNotes *string `json:"additionalNotes"`
SpecialInstructions *string `json:"specialInstructions"`
Treatment *string `json:"treatment"`
AssistantName *string `json:"assistantName"`
SurgicalProcedureTypeID int `json:"surgicalProcedureTypeId"`
SurgicalProcedureType SurgicalProcedureType `json:"surgicalProcedureType"`
SurgicalProcedureTypeTitle string `json:"surgicalProcedureTypeTitle"`
Payments []Payment `json:"payments" gorm:"many2many:surgery_payments;constraint:OnUpdate:CASCADE,OnDelete:CASCADE;"`
Status SurgeryStatus `json:"status"`
OrderNote string `json:"orderNote"`
ReceptionNote string `json:"receptionNote"`
Count int64 `json:"count"`
}
SurgicalProcedure ...
func (*SurgicalProcedure) DeleteFile ¶
func (r *SurgicalProcedure) DeleteFile(association string, surgicalProcedureID int, fileID int) error
DeleteFile ...
func (*SurgicalProcedure) GetAll ¶
func (r *SurgicalProcedure) GetAll(p PaginationInput, filter *SurgicalProcedure) ([]SurgicalProcedure, int64, error)
GetAll ...
func (*SurgicalProcedure) GetByPatient ¶
func (r *SurgicalProcedure) GetByPatient(p PaginationInput, patientID int) ([]SurgicalProcedure, int64, error)
GetByPatient ...
func (*SurgicalProcedure) GetByPatientChart ¶
func (r *SurgicalProcedure) GetByPatientChart(ID int) error
GetByPatientChart ...
type SurgicalProcedureType ¶
type SurgicalProcedureType struct {
gorm.Model
ID int `gorm:"primaryKey" json:"id"`
Title string `json:"title"`
Active bool `json:"active"`
Billings []Billing `json:"billings" gorm:"many2many:surgical_procedure_type_billings"`
Supplies []Supply `json:"supplies" gorm:"many2many:surgical_procedure_supplies"`
Count int64 `json:"count"`
}
SurgicalProcedureType ...
func (*SurgicalProcedureType) Delete ¶
func (r *SurgicalProcedureType) Delete(ID int) error
Delete ...
func (*SurgicalProcedureType) GetAll ¶
func (r *SurgicalProcedureType) GetAll(p PaginationInput, searchTerm *string) ([]SurgicalProcedureType, int64, error)
GetAll ...
func (*SurgicalProcedureType) GetByTitle ¶
func (r *SurgicalProcedureType) GetByTitle(title string) error
GetByTitle ...
type System ¶
type System struct {
gorm.Model
ID int `json:"id" gorm:"primaryKey"`
Title string `json:"title"`
Count int64 `json:"count"`
Active bool `json:"active"`
}
System ...
type SystemSymptom ¶
type SystemSymptom struct {
gorm.Model
ID int `gorm:"primaryKey" json:"id"`
Title string `json:"title"`
Count int64 `json:"count"`
Active bool `json:"active"`
SystemID int `json:"systemId"`
System System `json:"system"`
}
SystemSymptom
func (*SystemSymptom) GetAll ¶
func (r *SystemSymptom) GetAll(p PaginationInput, searchTerm *string) ([]SystemSymptom, int64, error)
GetAll ...
func (*SystemSymptom) GetByTitle ¶
func (r *SystemSymptom) GetByTitle(title string) error
GetByTitle ...
type Treatment ¶
type Treatment struct {
gorm.Model
ID int `gorm:"primaryKey"`
TreatmentOrderID int `json:"treatmentOrderId"`
PatientChartID int `json:"patientChartId"`
Note string `json:"note"`
Result string `json:"result"`
RightEyeText string `json:"rightEyeText"`
LeftEyeText string `json:"leftEyeText"`
GeneralText string `json:"generalText"`
TreatmentTypeID int `json:"treatmentTypeId"`
TreatmentType TreatmentType `json:"treatmentType"`
TreatmentTypeTitle string `json:"treatmentTypeTitle"`
Payments []Payment `json:"payments" gorm:"many2many:treatment_payments;constraint:OnUpdate:CASCADE,OnDelete:CASCADE;"`
ReceptionNote string `json:"receptionNote"`
Status TreatmentStatus `json:"status"`
Count int64 `json:"count"`
}
Treatment ...
func (*Treatment) GetByPatient ¶
GetByPatient ...
func (*Treatment) GetByPatientChart ¶
GetByPatientChart ...
type TreatmentOrder ¶
type TreatmentOrder struct {
gorm.Model
ID int `gorm:"primaryKey"`
PatientChartID int `json:"patientChartId"`
PatientID int `json:"patientId"`
FirstName string `json:"firstName"`
LastName string `json:"lastName"`
PhoneNo string `json:"phoneNo"`
UserName string `json:"userName"`
OrderedByID int `json:"orderedById"`
OrderedBy User `json:"orderedBy"`
Status TreatmentOrderStatus `json:"status"`
Treatments []Treatment `json:"treatments"`
Emergency *bool `json:"emergency"`
Document string `gorm:"type:tsvector"`
Count int64 `json:"count"`
}
TreatmentOrder ...
func (*TreatmentOrder) ConfirmOrder ¶
func (r *TreatmentOrder) ConfirmOrder(treatmentOrderID int, treatmentID int, invoiceNo string, roomID int, checkInTime time.Time) error
ConfirmOrder ...
func (*TreatmentOrder) GetAll ¶
func (r *TreatmentOrder) GetAll(p PaginationInput, filter *TreatmentOrder) ([]TreatmentOrder, int64, error)
GetAll ...
func (*TreatmentOrder) GetByPatientChartID ¶
func (r *TreatmentOrder) GetByPatientChartID(patientChartID int) error
GetByPatientChartID ...
func (*TreatmentOrder) GetCount ¶
func (r *TreatmentOrder) GetCount(filter *TreatmentOrder, date *time.Time, searchTerm *string) (int64, error)
GetCount ...
func (*TreatmentOrder) GetTodaysOrderedCount ¶
func (r *TreatmentOrder) GetTodaysOrderedCount() (count int)
GetTodaysOrderedCount ...
func (*TreatmentOrder) SaveOpthalmologyTreatment ¶
func (r *TreatmentOrder) SaveOpthalmologyTreatment(treatmentTypeID int, patientChartID int, patientID int, billingID int, user User, treatmentNote string, orderNote string) error
SaveOpthalmologyTreatment ...
func (*TreatmentOrder) Search ¶
func (r *TreatmentOrder) Search(p PaginationInput, filter *TreatmentOrder, date *time.Time, searchTerm *string, ascending bool) ([]TreatmentOrder, int64, error)
Search ...
type TreatmentOrderStatus ¶
type TreatmentOrderStatus string
TreatmentOrderStatus ...
const ( TreatmentOrderStatusOrdered TreatmentOrderStatus = "ORDERED" TreatmentOrderStatusCompleted TreatmentOrderStatus = "COMPLETED" )
TreatmentOrderStatus statuses ...
type TreatmentStatus ¶
type TreatmentStatus string
TreatmentStatus ...
const ( TreatmentStatusOrdered TreatmentStatus = "ORDERED" TreatmentStatusCompleted TreatmentStatus = "COMPLETED" )
SurgicalProcedureOrder statuses ...
type TreatmentType ¶
type TreatmentType struct {
gorm.Model
ID int `gorm:"primaryKey" json:"id"`
Title string `json:"title"`
Status string `json:"status"`
Billings []Billing `json:"billings" gorm:"many2many:treatment_type_billings"`
Supplies []Supply `json:"supplies" gorm:"many2many:treatment_supplies"`
Active bool `json:"active"`
Count int64 `json:"count"`
}
TreatmentType ...
func (*TreatmentType) GetAll ¶
func (r *TreatmentType) GetAll(p PaginationInput, searchTerm *string) ([]TreatmentType, int64, error)
GetAll ...
func (*TreatmentType) GetByTitle ¶
func (r *TreatmentType) GetByTitle(title string) error
GetByTitle ...
type User ¶
type User struct {
gorm.Model
ID int `gorm:"primaryKey"`
FirstName string `json:"firstName"`
LastName string `json:"lastName"`
Email string `json:"email"`
Password string `json:"password"`
OldUserName string `json:"oldUserName"`
UserTypes []UserType `gorm:"many2many:user_type_roles;" json:"userTypes"`
Appointments []Appointment `json:"appointments"`
Active bool `json:"active"`
SignatureID *int `json:"signatureId"`
Signature *File `json:"signature"`
ProfilePicID *int `json:"profilePicId"`
ProfilePic *File `json:"profilePic"`
// Confirm
ConfirmSelector string
ConfirmVerifier string
Confirmed bool
// Lock
AttemptCount int
LastAttempt *time.Time
Locked *time.Time
// Recover
RecoverSelector string
RecoverVerifier string
RecoverTokenExpiry *time.Time
// OAuth2
OAuth2UID string
OAuth2Provider string
OAuth2AccessToken string
OAuth2RefreshToken string
OAuth2Expiry *time.Time
// 2fa
TOTPSecretKey string
SMSPhoneNumber string
SMSSeedPhoneNumber string
RecoveryCodes string
Document string `gorm:"type:tsvector"`
Count int64 `json:"count"`
}
User ...
func (*User) CheckIfUserLegacy ¶
CheckIfUserLegacy ...
func (*User) CheckPassword ¶
CheckPassword checks user password
func (*User) CheckPasswordEquality ¶
HashPassword encrypts user password
func (*User) GetByOldUserName ¶
GetByOldUserName ...
func (*User) GetByUserType ¶
GetByUserType ...
func (*User) GetByUserTypeTitle ¶
GetByUserTypeTitle ...
func (*User) SearchPhysicians ¶
Search ...
type UserType ¶
type UserType struct {
gorm.Model
ID int `gorm:"primaryKey"`
Title string `json:"title" gorm:"uniqueIndex"`
Users []User `gorm:"many2many:user_type_roles;"`
Count int64 `json:"count"`
}
UserType ...
type VisitType ¶
type VisitType struct {
gorm.Model
ID int `gorm:"primaryKey"`
Title string `json:"title" gorm:"unique"`
}
VisitType ...
func (*VisitType) GetAll ¶
func (r *VisitType) GetAll(p PaginationInput) ([]VisitType, int64, error)
GetAll ...
func (*VisitType) GetByTitles ¶
GetByTitles ...
type VisualAcuity ¶
type VisualAcuity struct {
gorm.Model
ID int `gorm:"primaryKey"`
RightDistanceUncorrected *string `json:"rightDistanceUncorrected"`
LeftDistanceUncorrected *string `json:"leftDistanceUncorrected"`
RightDistancePinhole *string `json:"rightDistancePinhole"`
LeftDistancePinhole *string `json:"leftDistancePinhole"`
RightDistanceCorrected *string `json:"rightDistanceCorrected"`
LeftDistanceCorrected *string `json:"leftDistanceCorrected"`
RightNearUncorrected *string `json:"rightNearUncorrected"`
LeftNearUncorrected *string `json:"leftNearUncorrected"`
RightNearPinhole *string `json:"rightNearPinhole"`
LeftNearPinhole *string `json:"leftNearPinhole"`
RightNearCorrected *string `json:"rightNearCorrected"`
LeftNearCorrected *string `json:"leftNearCorrected"`
PatientChartID int `json:"patientChartId" gorm:"unique"`
}
VisualAcuity ...
func (*VisualAcuity) GetByPatientChart ¶
func (r *VisualAcuity) GetByPatientChart(ID int) error
GetByPatientChart ...
func (*VisualAcuity) SaveForPatientChart ¶
func (r *VisualAcuity) SaveForPatientChart() error
SaveForPatientChart ...
type VitalSigns ¶
type VitalSigns struct {
gorm.Model
ID int `gorm:"primaryKey"`
PatientChartID int `json:"patientChartId" gorm:"uniqueIndex"`
Temperature *float64 `json:"temperature"`
Pulse *float64 `json:"pulse"`
BloodPressureSystolic *float64 `json:"bloodPressureSystolic"`
BloodPressureDiastolic *float64 `json:"bloodPressureDiastolic"`
RespiratoryRate *float64 `json:"respiratoryRate"`
OxygenSaturation *float64 `json:"oxygenSaturation"`
Height *float64 `json:"height"`
Weight *float64 `json:"weight"`
Bmi *float64 `json:"bmi"`
// Visual Acuity
RightDistanceUncorrected *string `json:"rightDistanceUncorrected"`
LeftDistanceUncorrected *string `json:"leftDistanceUncorrected"`
RightDistancePinhole *string `json:"rightDistancePinhole"`
LeftDistancePinhole *string `json:"leftDistancePinhole"`
RightDistanceCorrected *string `json:"rightDistanceCorrected"`
LeftDistanceCorrected *string `json:"leftDistanceCorrected"`
RightNearUncorrected *string `json:"rightNearUncorrected"`
LeftNearUncorrected *string `json:"leftNearUncorrected"`
RightNearPinhole *string `json:"rightNearPinhole"`
LeftNearPinhole *string `json:"leftNearPinhole"`
RightNearCorrected *string `json:"rightNearCorrected"`
LeftNearCorrected *string `json:"leftNearCorrected"`
// IOP
RightIop *string `json:"rightIop"`
LeftIop *string `json:"leftIop"`
RightApplanation *string `json:"rightApplanation"`
LeftApplanation *string `json:"leftApplanation"`
RightTonopen *string `json:"rightTonopen"`
LeftTonopen *string `json:"leftTonopen"`
RightDigital *string `json:"rightDigital"`
LeftDigital *string `json:"leftDigital"`
RightNoncontact *string `json:"rightNoncontact"`
LeftNoncontact *string `json:"leftNoncontact"`
// Auto Refraction
RightDistanceSph *string `json:"rightDistanceSph"`
LeftDistanceSph *string `json:"leftDistanceSph"`
RightDistanceAxis *string `json:"rightDistanceAxis"`
LeftDistanceAxis *string `json:"leftDistanceAxis"`
RightDistanceCyl *string `json:"rightDistanceCyl"`
LeftDistanceCyl *string `json:"leftDistanceCyl"`
RightNearSph *string `json:"rightNearSph"`
LeftNearSph *string `json:"leftNearSph"`
RightNearCyl *string `json:"rightNearCyl"`
LeftNearCyl *string `json:"leftNearCyl"`
RightNearAxis *string `json:"rightNearAxis"`
LeftNearAxis *string `json:"leftNearAxis"`
RightLensMeterSph *string `json:"rightLensMeterSph"`
LeftLensMeterSph *string `json:"leftLensMeterSph"`
RightLensMeterAxis *string `json:"rightLensMeterAxis"`
LeftLensMeterAxis *string `json:"leftLensMeterAxis"`
RightLensMeterCyl *string `json:"rightLensMeterCyl"`
LeftLensMeterCyl *string `json:"leftLensMeterCyl"`
}
VitalSigns ...
func (*VitalSigns) GetByPatientChart ¶
func (r *VitalSigns) GetByPatientChart(ID int) error
GetByPatientChart ...
Source Files
¶
- allergy.go
- amendment.go
- appointment.go
- appointment_queue.go
- appointment_status.go
- auto_refraction.go
- billing.go
- chat.go
- chat_delete.go
- chat_member.go
- chat_message.go
- chat_mute.go
- chat_unread_message.go
- chief_complaint.go
- chief_complaint_type.go
- cover_test_entity.go
- diagnosis.go
- diagnostic_procedure.go
- diagnostic_procedure_order.go
- diagnostic_procedure_type.go
- exam_category.go
- exam_finding.go
- external_exam.go
- eyewear_prescription.go
- eyewear_prescription_order.go
- eyewear_shop.go
- family_illness.go
- favorite_chief_complaint.go
- favorite_diagnosis.go
- favorite_medication.go
- file.go
- follow_up.go
- follow_up_order.go
- funduscopy.go
- hpi_component.go
- hpi_component_type.go
- iop.go
- lab.go
- lab_order.go
- lab_type.go
- lifestyle.go
- lifestyle_type.go
- medical_prescription.go
- medical_prescription_order.go
- models.go
- ocular_motility.go
- ophthalmology_exam.go
- optic_disc.go
- order.go
- organization_details.go
- page.go
- past_hospitalization.go
- past_illness.go
- past_illness_type.go
- past_injury.go
- past_opt_surgery.go
- past_surgery.go
- patient.go
- patient_chart.go
- patient_diagnosis.go
- patient_encounter_limit.go
- patient_history.go
- patient_queue.go
- payment.go
- payment_waiver.go
- pharmacy.go
- physical_exam_finding.go
- pupils.go
- queue_destination.go
- queue_subscription.go
- referral.go
- referral_order.go
- review_of_system.go
- room.go
- slit_lamp_exam.go
- supply.go
- surgical_order.go
- surgical_procedure.go
- surgical_procedure_type.go
- system.go
- system_symptom.go
- treatment.go
- treatment_order.go
- treatment_type.go
- user.go
- user_type.go
- visit_type.go
- visual_acuity.go
- vital_signs.go