concurrentTest.go 765 B

1234567891011121314151617181920212223
  1. package service
  2. import (
  3. "sfis/utils"
  4. "github.com/gin-gonic/gin"
  5. )
  6. func GetConcurrentData(appid string, productId int, c *gin.Context) {
  7. if productId == 1000 {
  8. utils.Check(appid, productId, c, func() ([]map[string]interface{}, int, error) {
  9. return ProjectListData(productId, appid, "河南大学", "", "", false)
  10. }, "", "", true)
  11. } else if productId == 1001 {
  12. utils.Check(appid, productId, c, func() ([]map[string]interface{}, int, error) {
  13. return ProjectDetailData("5f6bc00c499cb0822d7e3842")
  14. }, "", "", true)
  15. } else if productId == 1002 {
  16. utils.Check(appid, productId, c, func() ([]map[string]interface{}, int, error) {
  17. return ProjectListData(productId, appid, "", "中铁十五局集团有限公司", "", true)
  18. }, "", "", true)
  19. }
  20. }