diff --git a/.idea/workspace.xml b/.idea/workspace.xml
index a543680..730f7ff 100644
--- a/.idea/workspace.xml
+++ b/.idea/workspace.xml
@@ -4,9 +4,9 @@
-
+
-
+
@@ -153,7 +153,6 @@
-
@@ -178,7 +177,8 @@
-
+
+
true
diff --git a/pkg/internal/services/sign.go b/pkg/internal/services/sign.go
index aeb9069..2a1a7fd 100644
--- a/pkg/internal/services/sign.go
+++ b/pkg/internal/services/sign.go
@@ -11,7 +11,7 @@ import (
)
func CheckDailyCanSign(user models.Account) error {
- probe := time.Now().Format("YYYY-MM-DD")
+ probe := time.Now().Format("2006-01-02")
var record models.SignRecord
if err := database.C.Where("account_id = ? AND created_at::date = ?", user.ID, probe).First(&record).Error; err != nil {
@@ -24,7 +24,7 @@ func CheckDailyCanSign(user models.Account) error {
}
func GetTodayDailySign(user models.Account) (models.SignRecord, error) {
- probe := time.Now().Format("YYYY-MM-DD")
+ probe := time.Now().Format("2006-01-02")
var record models.SignRecord
if err := database.C.Where("account_id = ? AND created_at::date = ?", user.ID, probe).First(&record).Error; err != nil {