Reorganize directory structures
Signed-off-by: Sean Du <do4suki@gmail.com>
This commit is contained in:
@@ -0,0 +1,39 @@
|
||||
package handler
|
||||
|
||||
import (
|
||||
"encoding/json"
|
||||
"honoka-chan/internal/model"
|
||||
"honoka-chan/internal/utils"
|
||||
"net/http"
|
||||
"time"
|
||||
|
||||
"github.com/gin-gonic/gin"
|
||||
)
|
||||
|
||||
func ProductList(ctx *gin.Context) {
|
||||
prodReesp := model.ProductResp{
|
||||
ResponseData: model.ProductRes{
|
||||
RestrictionInfo: model.RestrictionInfo{
|
||||
Restricted: false,
|
||||
},
|
||||
UnderAgeInfo: model.UnderAgeInfo{
|
||||
BirthSet: true,
|
||||
HasLimit: false,
|
||||
LimitAmount: nil,
|
||||
MonthUsed: 0,
|
||||
},
|
||||
SnsProductList: []any{},
|
||||
ProductList: []any{},
|
||||
SubscriptionList: []any{},
|
||||
ShowPointShop: true,
|
||||
ServerTimestamp: time.Now().Unix(),
|
||||
},
|
||||
ReleaseInfo: []any{},
|
||||
StatusCode: 200,
|
||||
}
|
||||
resp, err := json.Marshal(prodReesp)
|
||||
utils.CheckErr(err)
|
||||
|
||||
ctx.Header("X-Message-Sign", utils.GenXMS(resp))
|
||||
ctx.String(http.StatusOK, string(resp))
|
||||
}
|
||||
Reference in New Issue
Block a user