Replace Gorush with direct APNs/FCM integration
- Add direct APNs client using sideshow/apns2 for iOS push - Add direct FCM client using legacy HTTP API for Android push - Remove Gorush dependency (no external push server needed) - Update all services/handlers to use new push.Client - Update config for APNS_PRODUCTION flag 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
@@ -19,11 +19,11 @@ import (
|
||||
type AdminNotificationHandler struct {
|
||||
db *gorm.DB
|
||||
emailService *services.EmailService
|
||||
pushClient *push.GorushClient
|
||||
pushClient *push.Client
|
||||
}
|
||||
|
||||
// NewAdminNotificationHandler creates a new admin notification handler
|
||||
func NewAdminNotificationHandler(db *gorm.DB, emailService *services.EmailService, pushClient *push.GorushClient) *AdminNotificationHandler {
|
||||
func NewAdminNotificationHandler(db *gorm.DB, emailService *services.EmailService, pushClient *push.Client) *AdminNotificationHandler {
|
||||
return &AdminNotificationHandler{
|
||||
db: db,
|
||||
emailService: emailService,
|
||||
|
||||
@@ -20,7 +20,7 @@ import (
|
||||
// Dependencies holds optional services for admin routes
|
||||
type Dependencies struct {
|
||||
EmailService *services.EmailService
|
||||
PushClient *push.GorushClient
|
||||
PushClient *push.Client
|
||||
}
|
||||
|
||||
// SetupRoutes configures all admin routes
|
||||
@@ -114,7 +114,7 @@ func SetupRoutes(router *gin.Engine, db *gorm.DB, cfg *config.Config, deps *Depe
|
||||
|
||||
// Notification management
|
||||
var emailService *services.EmailService
|
||||
var pushClient *push.GorushClient
|
||||
var pushClient *push.Client
|
||||
if deps != nil {
|
||||
emailService = deps.EmailService
|
||||
pushClient = deps.PushClient
|
||||
|
||||
Reference in New Issue
Block a user