|
|
@@ -17,8 +17,8 @@ import (
|
|
|
|
|
|
// 查套保计划请求
|
|
|
type QryHedgePlanReq struct {
|
|
|
- UserId int64 `form:"userId" binding:"required"` //用户ID
|
|
|
- HedgePlanStatus *int `form:"HedgePlanStatus" binding:"required"` // 套保计划状态
|
|
|
+ UserId int64 `form:"userId" binding:"required"` //用户ID
|
|
|
+ HedgePlanStatus string `form:"HedgePlanStatus" binding:"required"` // 套保计划状态(允许多个,逗号隔开)
|
|
|
}
|
|
|
|
|
|
// 查套保计划应答
|
|
|
@@ -29,7 +29,7 @@ type QryHedgePlanRsp models.ErmcpHedgePlan
|
|
|
// @Produce json
|
|
|
// @Security ApiKeyAuth
|
|
|
// @Param userId query int true "用户ID"
|
|
|
-// @Param HedgePlanStatus query int true "套保计划状态 - 0:未提交 1:待审核 2:执行中 3:正常完结 4:审核拒绝 5:异常完结 6:已撤回"
|
|
|
+// @Param HedgePlanStatus query string true "套保计划状态(允许多个,逗号隔开) - 0:未提交 1:待审核 2:执行中 3:正常完结 4:审核拒绝 5:异常完结 6:已撤回"
|
|
|
// @Success 200 {array} QryHedgePlanRsp
|
|
|
// @Failure 500 {object} app.Response
|
|
|
// @Router /Ermcp/QueryHedgePlan [get]
|
|
|
@@ -44,7 +44,7 @@ func QueryHedgePlan(c *gin.Context) {
|
|
|
}
|
|
|
|
|
|
var m = models.ErmcpHedgePlan{Areauserid: req.UserId}
|
|
|
- if d, err := m.GetData(*req.HedgePlanStatus); err == nil {
|
|
|
+ if d, err := m.GetData(req.HedgePlanStatus); err == nil {
|
|
|
appG.Response(http.StatusOK, e.SUCCESS, d)
|
|
|
} else {
|
|
|
logger.GetLogger().Errorf("query fail, %v", err)
|