Documentation
¶
Index ¶
- Constants
- func AddEmailSubscriber(conn *sql.DB, email, token string) error
- func AddFXRate(conn *sql.DB, fx FXRate) error
- func CloseDbConn(conn *sql.DB)
- func ConfirmEmailSubscriber(conn *sql.DB, token string) error
- func CountEmailSubscribers(conn *sql.DB) (int, error)
- func CreateTmpSitemapTable(conn *sql.DB) error
- func DeleteImageByID(conn *sql.DB, id string) error
- func DuplicateImage(conn *sql.DB, oldID, newID string) error
- func GetDbConn(databaseUser string, databasePassword string, databaseHost string, ...) (*sql.DB, error)
- func GetJobClickoutsLast30Days(conn *sql.DB) (int, error)
- func GetJobPageViewsLast30Days(conn *sql.DB) (int, error)
- func GetRandomLocationsForCountry(conn *sql.DB, country string, howMany int, excludeLoc string) ([]string, error)
- func GetSitemapEntryCount(conn *sql.DB) (int, error)
- func GetSitemapLastMod(conn *sql.DB) (time.Time, error)
- func GetWebsitePageViewsLast30Days(conn *sql.DB) (int, error)
- func InitiatePaymentEventForDeveloperDirectoryAccess(conn *sql.DB, sessionID string, amount int64, description string, ...) error
- func InitiatePaymentEventForJobAd(conn *sql.DB, sessionID string, amount int64, description string, email string, ...) error
- func IsDevDirectoryPaymentEvent(conn *sql.DB, sessionID string) (bool, error)
- func IsJobAdPaymentEvent(conn *sql.DB, sessionID string) (bool, error)
- func RemoveEmailSubscriber(conn *sql.DB, token string) error
- func SaveCloudflareBrowserStat(conn *sql.DB, s CloudflareBrowserStat) error
- func SaveCloudflareCountryStat(conn *sql.DB, s CloudflareCountryStat) error
- func SaveCloudflareStat(conn *sql.DB, s CloudflareStat) error
- func SaveCloudflareStatusCodeStat(conn *sql.DB, s CloudflareStatusCodeStat) error
- func SaveMedia(conn *sql.DB, media Media) (string, error)
- func SaveSEOLandingPage(conn *sql.DB, seoLandingPage SEOLandingPage) error
- func SaveSEOLocation(conn *sql.DB, name, country, currency string) string
- func SaveSEOSkillFromCompany(conn *sql.DB)
- func SaveSitemapEntry(conn *sql.DB, entry SitemapEntry) error
- func SaveSuccessfulPaymentForDevDirectory(conn *sql.DB, sessionID string) (int, error)
- func SaveSuccessfulPaymentForJobAd(conn *sql.DB, sessionID string) (int, error)
- func SwapSitemapTable(conn *sql.DB) error
- func UpdateLastWeekClickouts(conn *sql.DB) error
- func UpdateMedia(conn *sql.DB, media Media, mediaID string) error
- type CloudflareBrowserStat
- type CloudflareCountryStat
- type CloudflareStat
- type CloudflareStatusCodeStat
- type DevDirectoryPurchaseEvent
- type EmailSubscriber
- type FXRate
- type Location
- type Media
- type PurchaseEvent
- type SEOLandingPage
- type SEOLocation
- type SEOSkill
- type SalaryDataPoint
- type SalaryTrendDataPoint
- type SitemapEntry
Constants ¶
View Source
const SitemapSize = 1000
Variables ¶
This section is empty.
Functions ¶
func CreateTmpSitemapTable ¶
func GetDbConn ¶
func GetDbConn(databaseUser string, databasePassword string, databaseHost string, databasePort string, databaseName string, sslMode string) (*sql.DB, error)
GetDbConn tries to establish a connection to postgres and return the connection handler
func SaveCloudflareBrowserStat ¶
func SaveCloudflareBrowserStat(conn *sql.DB, s CloudflareBrowserStat) error
func SaveCloudflareCountryStat ¶
func SaveCloudflareCountryStat(conn *sql.DB, s CloudflareCountryStat) error
func SaveCloudflareStat ¶
func SaveCloudflareStat(conn *sql.DB, s CloudflareStat) error
func SaveCloudflareStatusCodeStat ¶
func SaveCloudflareStatusCodeStat(conn *sql.DB, s CloudflareStatusCodeStat) error
func SaveSEOLandingPage ¶
func SaveSEOLandingPage(conn *sql.DB, seoLandingPage SEOLandingPage) error
func SaveSEOSkillFromCompany ¶
func SaveSitemapEntry ¶
func SaveSitemapEntry(conn *sql.DB, entry SitemapEntry) error
func SwapSitemapTable ¶
func UpdateLastWeekClickouts ¶
Types ¶
type CloudflareBrowserStat ¶
type CloudflareCountryStat ¶
type CloudflareStat ¶
type DevDirectoryPurchaseEvent ¶
type DevDirectoryPurchaseEvent struct { StripeSessionID string CreatedAt time.Time CompletedAt time.Time ExpiredAt time.Time Email string Amount int64 Currency string Description string RecruiterID string Duration int64 }
func GetDevDirectoryPurchaseEventBySessionID ¶
func GetDevDirectoryPurchaseEventBySessionID(conn *sql.DB, sessionID string) (DevDirectoryPurchaseEvent, error)
type EmailSubscriber ¶
type EmailSubscriber struct { Email string Token string CreatedAt time.Time ConfirmedAt *time.Time }
func GetEmailSubscribers ¶
func GetEmailSubscribers(conn *sql.DB) ([]EmailSubscriber, error)
type Location ¶
type Location struct { Name string `json:"name,omitempty"` Country string `json:"country,omitempty"` Region string `json:"region,omitempty"` Population int64 `json:"population,omitempty"` Lat float64 `json:"lat,omitempty"` Long float64 `json:"long,omitempty"` Currency string `json:"currency,omitempty"` Emoji string `json:"emoji,omitempty"` }
type PurchaseEvent ¶
type PurchaseEvent struct { StripeSessionID string CreatedAt time.Time CompletedAt time.Time Amount int Currency string Description string Email string JobID int PlanType string PlanDuration int }
func GetJobAdPurchaseEventBySessionID ¶
func GetJobAdPurchaseEventBySessionID(conn *sql.DB, sessionID string) (PurchaseEvent, error)
func GetPurchaseEvents ¶
func GetPurchaseEvents(conn *sql.DB, jobID int) ([]PurchaseEvent, error)
type SEOLandingPage ¶
type SEOLocation ¶
func GetSEOLocations ¶
func GetSEOLocations(conn *sql.DB) ([]SEOLocation, error)
type SalaryDataPoint ¶
func GetSalaryDataForLocationAndCurrency ¶
func GetSalaryDataForLocationAndCurrency(conn *sql.DB, location, currency string) ([]SalaryDataPoint, error)
type SalaryTrendDataPoint ¶
type SalaryTrendDataPoint struct { Date string `json:"date"` P10 int64 `json:"p10"` P25 int64 `json:"p25"` P50 int64 `json:"p50"` P75 int64 `json:"p75"` P90 int64 `json:"p90"` }
func GetSalaryTrendsForLocationAndCurrency ¶
func GetSalaryTrendsForLocationAndCurrency(conn *sql.DB, location, currency string) ([]SalaryTrendDataPoint, error)
type SitemapEntry ¶
func GetSitemapIndex ¶
func GetSitemapIndex(conn *sql.DB, siteHost string) ([]SitemapEntry, error)
func GetSitemapNo ¶
func GetSitemapNo(conn *sql.DB, n int) ([]SitemapEntry, error)
Click to show internal directories.
Click to hide internal directories.