diff --git a/backend/main.go b/backend/main.go index f177280..29fac77 100644 --- a/backend/main.go +++ b/backend/main.go @@ -1430,6 +1430,17 @@ func connect() { "result": result, }) + case "check-popsrecord": + err := dbpop.QueryRow("SELECT COUNT(OrderPayId) AS result FROM orderpaydetail WHERE oprefid = ?" , data).Scan(&result) + if err != nil { + c.AbortWithError(http.StatusBadRequest, err) + c.String(http.StatusBadRequest, err.Error()) + return + } + c.JSON(http.StatusOK, gin.H{ + "result": result, + }) + } })