feat: 引入循环交易管理、邮件通知和用户设置功能
This commit is contained in:
@@ -3,8 +3,8 @@ package handler
|
||||
import (
|
||||
"errors"
|
||||
|
||||
"accounting-app/pkg/api"
|
||||
"accounting-app/internal/service"
|
||||
"accounting-app/pkg/api"
|
||||
|
||||
"github.com/gin-gonic/gin"
|
||||
)
|
||||
@@ -70,6 +70,10 @@ func (h *SettingsHandler) UpdateSettings(c *gin.Context) {
|
||||
api.BadRequest(c, "Invalid image compression, must be one of: low, medium, high")
|
||||
return
|
||||
}
|
||||
if errors.Is(err, service.ErrInvalidNotificationChannel) {
|
||||
api.BadRequest(c, "Invalid notification channel")
|
||||
return
|
||||
}
|
||||
api.InternalError(c, "Failed to update settings: "+err.Error())
|
||||
return
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user