Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func GetChurchID ¶
Types ¶
type Address ¶
type Address struct { ZipCode string `json:"zipCode"` State string `json:"state"` City string `json:"city"` Address string `json:"address"` District string `json:"district"` Number int `json:"number"` MoreInfo string `json:"moreInfo"` }
Address struct
type Church ¶
type Church struct { ID string `json:"id"` Name string `json:"name"` Abbreviation string `json:"abbreviation"` Language string `json:"language"` Email string `json:"email"` }
Church provides information about a church
type Contact ¶
type Contact struct { PhoneArea int `json:"phoneArea,omitempty"` Phone int `json:"phone,omitempty"` CellPhoneArea int `json:"cellPhoneArea"` CellPhone int `json:"cellPhone"` Email string `json:"email"` }
Contact struct
func (Contact) GetFormattedCellPhone ¶
GetFormattedCellPhone (99) 999999999
func (Contact) GetFormattedPhone ¶
GetFormattedPhone (99) 99999999
type Member ¶
type Member struct { ID string `json:"id"` ChurchID string `json:"church_id"` OldChurch string `json:"oldChurch,omitempty"` AttendsFridayWorship bool `json:"attendsFridayWorship"` AttendsSaturdayWorship bool `json:"attendsSaturdayWorship"` AttendsSundayWorship bool `json:"attendsSundayWorship"` AttendsSundaySchool bool `json:"attendsSundaySchool"` AttendsObservation string `json:"attendsObservation,omitempty"` Person *Person `json:"person"` Religion *Religion `json:"religion"` Active bool `json:"active,omitempty"` MembershipStartDate time.Time `json:"membership_start_date"` MembershipEndDate *time.Time `json:"membership_end_date,omitempty"` MembershipEndReason string `json:"membership_end_reason,omitempty"` }
Member struct
func (Member) Classification ¶
func (member Member) Classification() enum.Classification
Classification returns a member classification based on age and marriage
func (Member) MembershipEndCurrentYear ¶
type NotificationPreferences ¶
type Person ¶
type Person struct { Name string `json:"name"` FirstName string `json:"firstName"` LastName string `json:"lastName"` BirthDate time.Time `json:"birthDate"` MarriageDate *time.Time `json:"marriageDate,omitempty"` PlaceOfBirth string `json:"placeOfBirth"` FathersName string `json:"fathersName"` MothersName string `json:"mothersName"` MaritalStatus string `json:"maritalStatus"` SpousesName string `json:"spousesName,omitempty"` BrothersQuantity int `json:"brothersQuantity"` ChildrenQuantity int `json:"childrenQuantity"` Profession string `json:"profession,omitempty"` Gender string `json:"gender"` Contact *Contact `json:"contact"` Address *Address `json:"address"` }
Person type
func (Person) GetCoupleName ¶
GetCoupleName return the couple name in case the person is married
type Religion ¶
type Religion struct { FathersReligion string `json:"fathersReligion,omitempty"` BaptismPlace string `json:"baptismPlace"` LearnedGospelAge int `json:"learnedGospelAge"` AcceptedJesus bool `json:"acceptedJesus"` Baptized bool `json:"baptized"` CatholicBaptized bool `json:"catholicBaptized"` KnowsTithe bool `json:"knowsTithe"` AgreesTithe bool `json:"agreesTithe"` Tithe bool `json:"tithe"` AcceptedJesusDate *time.Time `json:"acceptedJesusDate"` BaptismDate *time.Time `json:"baptismDate"` }
Religion struct
type SortByBirthDay ¶
type SortByBirthDay []*Member
SortByBirthDay a list of members
func (SortByBirthDay) Len ¶
func (a SortByBirthDay) Len() int
func (SortByBirthDay) Less ¶
func (a SortByBirthDay) Less(i, j int) bool
func (SortByBirthDay) Swap ¶
func (a SortByBirthDay) Swap(i, j int)
type SortByMarriageDay ¶
type SortByMarriageDay []*Member
SortByMarriageDay a list of members
func (SortByMarriageDay) Len ¶
func (a SortByMarriageDay) Len() int
func (SortByMarriageDay) Less ¶
func (a SortByMarriageDay) Less(i, j int) bool
func (SortByMarriageDay) Swap ¶
func (a SortByMarriageDay) Swap(i, j int)
type SortByName ¶
type SortByName []*Member
SortByName a list of members
func (SortByName) Len ¶
func (a SortByName) Len() int
func (SortByName) Less ¶
func (a SortByName) Less(i, j int) bool
func (SortByName) Swap ¶
func (a SortByName) Swap(i, j int)
type User ¶
type User struct { ID string `json:"id"` ChurchID string `json:"church_id"` UserName string `json:"username"` Email string `json:"email"` ConfirmedEmail bool `json:"confirmed_email"` Role enum.Role `json:"role"` Phone string `json:"phone"` Preferences NotificationPreferences `json:"-"` Password []byte `json:"-"` Church *Church `json:"-"` }
Click to show internal directories.
Click to hide internal directories.