materials.go 402 B

12345678910111213141516
  1. package controller
  2. import (
  3. "github.com/gin-gonic/gin"
  4. "icloudapp.cn/tools/entity"
  5. "icloudapp.cn/tools/model"
  6. utString "icloudapp.cn/tools/util/string"
  7. )
  8. func Materials(ctx *gin.Context) {
  9. uid := utString.ConvertInt64(ctx.GetString("uid"))
  10. mMaterial := model.NewMMaterial(ctx)
  11. materials := mMaterial.Materials(uid)
  12. entity.ResponseNormal(ctx, materials.Code, materials.Msg, materials.Body)
  13. }