mirror of
https://github.com/nprasad2077/NBA_Go.git
synced 2026-09-22 14:05:13 +00:00
shot imports
This commit is contained in:
@@ -41,3 +41,6 @@ docs/cloudflare.json
|
|||||||
docs/notes
|
docs/notes
|
||||||
|
|
||||||
docs/postman
|
docs/postman
|
||||||
|
|
||||||
|
docs/kiro.md
|
||||||
|
docs/digital_ocean/digitaal ocean llms.txt
|
||||||
@@ -91,7 +91,7 @@ func importGameSchedules(db *gorm.DB) {
|
|||||||
func importBoxScores(db *gorm.DB) {
|
func importBoxScores(db *gorm.DB) {
|
||||||
// now := time.Now()
|
// now := time.Now()
|
||||||
|
|
||||||
from := time.Date(2026, time.April, 28, 0, 0, 0, 0, time.UTC)
|
from := time.Date(2026, time.May, 25, 0, 0, 0, 0, time.UTC)
|
||||||
// from := time.Date(now.Year(), now.Month(), now.Day()-1, 5, 30, 0, 0, time.UTC)
|
// from := time.Date(now.Year(), now.Month(), now.Day()-1, 5, 30, 0, 0, time.UTC)
|
||||||
to := time.Date(2026, time.June, 15, 5, 30, 0, 0, time.UTC)
|
to := time.Date(2026, time.June, 15, 5, 30, 0, 0, time.UTC)
|
||||||
|
|
||||||
@@ -115,7 +115,7 @@ func importPlayerShotCharts(db *gorm.DB) {
|
|||||||
log.Println("--- Starting Player Shot Chart Import from Predefined List ---")
|
log.Println("--- Starting Player Shot Chart Import from Predefined List ---")
|
||||||
|
|
||||||
// 1. Define the season range. Your service fetches from newest to oldest.
|
// 1. Define the season range. Your service fetches from newest to oldest.
|
||||||
startSeason := 2025
|
startSeason := 2026
|
||||||
endSeason := 2017 // Basketball-Reference has data going back this far.
|
endSeason := 2017 // Basketball-Reference has data going back this far.
|
||||||
|
|
||||||
// 2. Define the static list of player IDs to import.
|
// 2. Define the static list of player IDs to import.
|
||||||
|
|||||||
@@ -68,8 +68,8 @@ func main() {
|
|||||||
importBoxScores(db)
|
importBoxScores(db)
|
||||||
log.Println("🎉 Related Box Score Imports completed successfully 📦")
|
log.Println("🎉 Related Box Score Imports completed successfully 📦")
|
||||||
|
|
||||||
// importPlayerShotCharts(db)
|
importPlayerShotCharts(db)
|
||||||
// log.Println("🎉 Player Shot Chart Import completed successfully 🎯")
|
log.Println("🎉 Player Shot Chart Import completed successfully 🎯")
|
||||||
|
|
||||||
log.Println("🏀 ALL Imports completed successfully ✅ 🙌")
|
log.Println("🏀 ALL Imports completed successfully ✅ 🙌")
|
||||||
return
|
return
|
||||||
|
|||||||
Reference in New Issue
Block a user