|
@@ -1,6 +1,10 @@
|
|
|
package v1
|
|
|
|
|
|
-import "github.com/gin-gonic/gin"
|
|
|
+import (
|
|
|
+ // . "sfis/service"
|
|
|
+
|
|
|
+ "github.com/gin-gonic/gin"
|
|
|
+)
|
|
|
|
|
|
/**
|
|
|
项目相关接口服务
|
|
@@ -11,16 +15,38 @@ func ProjectApiRegister(router *gin.Engine) {
|
|
|
{
|
|
|
routerGroup.POST("/projectList", getProjectsList)
|
|
|
routerGroup.POST("/projectDetail", getProjectDetail)
|
|
|
+ routerGroup.POST("/winnerProjectList", winnerProjectList)
|
|
|
}
|
|
|
}
|
|
|
|
|
|
-/**
|
|
|
- 获取项目列表接口
|
|
|
-*/
|
|
|
+//获取项目列表接口
|
|
|
func getProjectsList(c *gin.Context) {
|
|
|
-
|
|
|
+ projectName := c.Query("name")
|
|
|
+ winner := c.Query("winner")
|
|
|
+ // time := c.Query("time")
|
|
|
+ data := &map[string]interface{}{}
|
|
|
+ if projectName != "" || winner != "" {
|
|
|
+ // data = ProjectListData(projectName, winner, time)
|
|
|
+ }
|
|
|
+ c.JSON(200, data)
|
|
|
}
|
|
|
|
|
|
+//获取项目详情
|
|
|
func getProjectDetail(c *gin.Context) {
|
|
|
+ id := c.Query("id")
|
|
|
+ data := &map[string]interface{}{}
|
|
|
+ if id != "" {
|
|
|
+ // data = ProjectDetailData(id)
|
|
|
+ }
|
|
|
+ c.JSON(200, data)
|
|
|
+}
|
|
|
|
|
|
+//中标信息查询项目
|
|
|
+func winnerProjectList(c *gin.Context) {
|
|
|
+ winner := c.Query("winner")
|
|
|
+ data := &map[string]interface{}{}
|
|
|
+ if winner != "" {
|
|
|
+ // data = WinnerProjectListData(winner)
|
|
|
+ }
|
|
|
+ c.JSON(200, data)
|
|
|
}
|