Browse Source

QueryOrderQuote接口增加缩略图片字段

zhou.xiaoning 3 years ago
parent
commit
c187a4b4a1
4 changed files with 48 additions and 35 deletions
  1. 19 19
      docs/docs.go
  2. 14 8
      docs/swagger.json
  3. 12 8
      docs/swagger.yaml
  4. 3 0
      models/wrTrade2.go

+ 19 - 19
docs/docs.go

@@ -1,13 +1,14 @@
-// Package docs GENERATED BY THE COMMAND ABOVE; DO NOT EDIT
+// GENERATED BY THE COMMAND ABOVE; DO NOT EDIT
 // This file was generated by swaggo/swag
 // This file was generated by swaggo/swag
+
 package docs
 package docs
 
 
 import (
 import (
 	"bytes"
 	"bytes"
 	"encoding/json"
 	"encoding/json"
 	"strings"
 	"strings"
-	"text/template"
 
 
+	"github.com/alecthomas/template"
 	"github.com/swaggo/swag"
 	"github.com/swaggo/swag"
 )
 )
 
 
@@ -15,7 +16,7 @@ var doc = `{
     "schemes": {{ marshal .Schemes }},
     "schemes": {{ marshal .Schemes }},
     "swagger": "2.0",
     "swagger": "2.0",
     "info": {
     "info": {
-        "description": "{{escape .Description}}",
+        "description": "{{.Description}}",
         "title": "{{.Title}}",
         "title": "{{.Title}}",
         "termsOfService": "http://www.muchinfo.cn",
         "termsOfService": "http://www.muchinfo.cn",
         "contact": {},
         "contact": {},
@@ -14332,7 +14333,9 @@ var doc = `{
                 "code": {
                 "code": {
                     "type": "integer"
                     "type": "integer"
                 },
                 },
-                "data": {},
+                "data": {
+                    "type": "object"
+                },
                 "msg": {
                 "msg": {
                     "type": "string"
                     "type": "string"
                 },
                 },
@@ -17412,31 +17415,31 @@ var doc = `{
                     "type": "number"
                     "type": "number"
                 },
                 },
                 "diffArbitrageQty": {
                 "diffArbitrageQty": {
-                    "description": "期现数量差 = 套保计划量 - 今日期货关联成交量",
+                    "description": "套利变动量",
                     "type": "number"
                     "type": "number"
                 },
                 },
                 "diffExposoureQty": {
                 "diffExposoureQty": {
-                    "description": "期现数量差 = 套保计划量 - 今日期货关联成交量",
+                    "description": "变动量(套保敞口)",
                     "type": "number"
                     "type": "number"
                 },
                 },
                 "diffFutuQty": {
                 "diffFutuQty": {
-                    "description": "期现数量差 = 套保计划量 - 今日期货关联成交量",
+                    "description": "变动量(期货总量) 平安:保值净持仓量今日变动",
                     "type": "number"
                     "type": "number"
                 },
                 },
                 "diffHedgeQty": {
                 "diffHedgeQty": {
-                    "description": "期现数量差 = 套保计划量 - 今日期货关联成交量",
+                    "description": "套保变动量",
                     "type": "number"
                     "type": "number"
                 },
                 },
                 "diffQty": {
                 "diffQty": {
-                    "description": "期现数量差 = 套保计划量 - 今日期货关联成交量",
+                    "description": "变动量(总敞口) 平安:净敞口今日变动",
                     "type": "number"
                     "type": "number"
                 },
                 },
                 "diffSpotHedgeQty": {
                 "diffSpotHedgeQty": {
-                    "description": "期现数量差 = 套保计划量 - 今日期货关联成交量",
+                    "description": "变动量(现货应套保总量) 平安:应套保量今日变动",
                     "type": "number"
                     "type": "number"
                 },
                 },
                 "diffSpotQty": {
                 "diffSpotQty": {
-                    "description": "期现数量差 = 套保计划量 - 今日期货关联成交量",
+                    "description": "变动量(现货总量) = 现货数量 - 期初现货数量 平安:采销定价净值今日变动",
                     "type": "number"
                     "type": "number"
                 },
                 },
                 "enumdicname": {
                 "enumdicname": {
@@ -35719,6 +35722,10 @@ var doc = `{
                     "description": "卖量",
                     "description": "卖量",
                     "type": "number"
                     "type": "number"
                 },
                 },
+                "thumurls": {
+                    "description": "缩略图片(1:1)(逗号分隔)",
+                    "type": "string"
+                },
                 "warehousecode": {
                 "warehousecode": {
                     "description": "仓库代码",
                     "description": "仓库代码",
                     "type": "string"
                     "type": "string"
@@ -40453,13 +40460,6 @@ func (s *s) ReadDoc() string {
 			a, _ := json.Marshal(v)
 			a, _ := json.Marshal(v)
 			return string(a)
 			return string(a)
 		},
 		},
-		"escape": func(v interface{}) string {
-			// escape tabs
-			str := strings.Replace(v.(string), "\t", "\\t", -1)
-			// replace " with \", and if that results in \\", replace that with \\\"
-			str = strings.Replace(str, "\"", "\\\"", -1)
-			return strings.Replace(str, "\\\\\"", "\\\\\\\"", -1)
-		},
 	}).Parse(doc)
 	}).Parse(doc)
 	if err != nil {
 	if err != nil {
 		return doc
 		return doc
@@ -40474,5 +40474,5 @@ func (s *s) ReadDoc() string {
 }
 }
 
 
 func init() {
 func init() {
-	swag.Register("swagger", &s{})
+	swag.Register(swag.Name, &s{})
 }
 }

+ 14 - 8
docs/swagger.json

@@ -14317,7 +14317,9 @@
                 "code": {
                 "code": {
                     "type": "integer"
                     "type": "integer"
                 },
                 },
-                "data": {},
+                "data": {
+                    "type": "object"
+                },
                 "msg": {
                 "msg": {
                     "type": "string"
                     "type": "string"
                 },
                 },
@@ -17397,31 +17399,31 @@
                     "type": "number"
                     "type": "number"
                 },
                 },
                 "diffArbitrageQty": {
                 "diffArbitrageQty": {
-                    "description": "期现数量差 = 套保计划量 - 今日期货关联成交量",
+                    "description": "套利变动量",
                     "type": "number"
                     "type": "number"
                 },
                 },
                 "diffExposoureQty": {
                 "diffExposoureQty": {
-                    "description": "期现数量差 = 套保计划量 - 今日期货关联成交量",
+                    "description": "变动量(套保敞口)",
                     "type": "number"
                     "type": "number"
                 },
                 },
                 "diffFutuQty": {
                 "diffFutuQty": {
-                    "description": "期现数量差 = 套保计划量 - 今日期货关联成交量",
+                    "description": "变动量(期货总量) 平安:保值净持仓量今日变动",
                     "type": "number"
                     "type": "number"
                 },
                 },
                 "diffHedgeQty": {
                 "diffHedgeQty": {
-                    "description": "期现数量差 = 套保计划量 - 今日期货关联成交量",
+                    "description": "套保变动量",
                     "type": "number"
                     "type": "number"
                 },
                 },
                 "diffQty": {
                 "diffQty": {
-                    "description": "期现数量差 = 套保计划量 - 今日期货关联成交量",
+                    "description": "变动量(总敞口) 平安:净敞口今日变动",
                     "type": "number"
                     "type": "number"
                 },
                 },
                 "diffSpotHedgeQty": {
                 "diffSpotHedgeQty": {
-                    "description": "期现数量差 = 套保计划量 - 今日期货关联成交量",
+                    "description": "变动量(现货应套保总量) 平安:应套保量今日变动",
                     "type": "number"
                     "type": "number"
                 },
                 },
                 "diffSpotQty": {
                 "diffSpotQty": {
-                    "description": "期现数量差 = 套保计划量 - 今日期货关联成交量",
+                    "description": "变动量(现货总量) = 现货数量 - 期初现货数量 平安:采销定价净值今日变动",
                     "type": "number"
                     "type": "number"
                 },
                 },
                 "enumdicname": {
                 "enumdicname": {
@@ -35704,6 +35706,10 @@
                     "description": "卖量",
                     "description": "卖量",
                     "type": "number"
                     "type": "number"
                 },
                 },
+                "thumurls": {
+                    "description": "缩略图片(1:1)(逗号分隔)",
+                    "type": "string"
+                },
                 "warehousecode": {
                 "warehousecode": {
                     "description": "仓库代码",
                     "description": "仓库代码",
                     "type": "string"
                     "type": "string"

+ 12 - 8
docs/swagger.yaml

@@ -4,7 +4,8 @@ definitions:
     properties:
     properties:
       code:
       code:
         type: integer
         type: integer
-      data: {}
+      data:
+        type: object
       msg:
       msg:
         type: string
         type: string
       page:
       page:
@@ -2295,25 +2296,25 @@ definitions:
         description: 套利量
         description: 套利量
         type: number
         type: number
       diffArbitrageQty:
       diffArbitrageQty:
-        description: 期现数量差 = 套保计划量 - 今日期货关联成交
+        description: 套利变动
         type: number
         type: number
       diffExposoureQty:
       diffExposoureQty:
-        description: 期现数量差 = 套保计划量 - 今日期货关联成交量
+        description: 变动量(套保敞口)
         type: number
         type: number
       diffFutuQty:
       diffFutuQty:
-        description: 期现数量差 = 套保计划量 - 今日期货关联成交量
+        description: 变动量(期货总量) 平安:保值净持仓量今日变动
         type: number
         type: number
       diffHedgeQty:
       diffHedgeQty:
-        description: 期现数量差 = 套保计划量 - 今日期货关联成交
+        description: 套保变动
         type: number
         type: number
       diffQty:
       diffQty:
-        description: 期现数量差 = 套保计划量 - 今日期货关联成交量
+        description: 变动量(总敞口) 平安:净敞口今日变动
         type: number
         type: number
       diffSpotHedgeQty:
       diffSpotHedgeQty:
-        description: 期现数量差 = 套保计划量 - 今日期货关联成交量
+        description: 变动量(现货应套保总量) 平安:应套保量今日变动
         type: number
         type: number
       diffSpotQty:
       diffSpotQty:
-        description: 期现数量差 = 套保计划量 - 今日期货关联成交量
+        description: 变动量(现货总量) = 现货数量 - 期初现货数量 平安:采销定价净值今日变动
         type: number
         type: number
       enumdicname:
       enumdicname:
         description: 单位名称
         description: 单位名称
@@ -15949,6 +15950,9 @@ definitions:
       sellqty:
       sellqty:
         description: 卖量
         description: 卖量
         type: number
         type: number
+      thumurls:
+        description: 缩略图片(1:1)(逗号分隔)
+        type: string
       warehousecode:
       warehousecode:
         description: 仓库代码
         description: 仓库代码
         type: string
         type: string

+ 3 - 0
models/wrTrade2.go

@@ -33,6 +33,7 @@ type WrOrderQuote struct {
 	WRSTANDARDNAME    string           `json:"wrstandardname"  xorm:"'WRSTANDARDNAME'" form:"wrstandardname"` // 商品名称
 	WRSTANDARDNAME    string           `json:"wrstandardname"  xorm:"'WRSTANDARDNAME'" form:"wrstandardname"` // 商品名称
 	WRSTANDARDCODE    string           `json:"wrstandardcode"  xorm:"'WRSTANDARDCODE'"`                       // 商品代码
 	WRSTANDARDCODE    string           `json:"wrstandardcode"  xorm:"'WRSTANDARDCODE'"`                       // 商品代码
 	WRGOODSNAME       string           `json:"wrgoodsname"  xorm:"'WRGOODSNAME'"`                             // 商品(商品名称+仓库要素名称 拼接)
 	WRGOODSNAME       string           `json:"wrgoodsname"  xorm:"'WRGOODSNAME'"`                             // 商品(商品名称+仓库要素名称 拼接)
+	THUMURLS          string           `json:"thumurls"  xorm:"THUMURLS"`                                     // 缩略图片(1:1)(逗号分隔)
 	PICTUREURLS       string           `json:"pictureurls"  xorm:"PICTUREURLS"`                               // 详情图片(逗号分隔)
 	PICTUREURLS       string           `json:"pictureurls"  xorm:"PICTUREURLS"`                               // 详情图片(逗号分隔)
 	BANNERPICURL      string           `json:"bannerpicurl"  xorm:"BANNERPICURL"`                             // Banner图
 	BANNERPICURL      string           `json:"bannerpicurl"  xorm:"BANNERPICURL"`                             // Banner图
 	BUYPRICEMOVE      float64          `json:"buypricemove"  xorm:"'BUYPRICEMOVE'"`                           // 买升贴水(基差)
 	BUYPRICEMOVE      float64          `json:"buypricemove"  xorm:"'BUYPRICEMOVE'"`                           // 买升贴水(基差)
@@ -124,6 +125,7 @@ func (r *WrOrderQuote) buildSqlFixedPrice() string {
 		"       wg.wrstandardname || w.wrfactortypename2 as wrgoodsname," +
 		"       wg.wrstandardname || w.wrfactortypename2 as wrgoodsname," +
 		"       wg.bannerpicurl," +
 		"       wg.bannerpicurl," +
 		"       wg.pictureurls," +
 		"       wg.pictureurls," +
+		"       wg.thumurls," +
 		"       e.enumdicname" +
 		"       e.enumdicname" +
 		"  from wrQuote k" +
 		"  from wrQuote k" +
 		"  left join WRFactorType w" +
 		"  left join WRFactorType w" +
@@ -234,6 +236,7 @@ func (r *WrOrderQuote) buildSqlPriceMove() string {
 		"       wg.wrstandardname || w.wrfactortypename2 as wrgoodsname," +
 		"       wg.wrstandardname || w.wrfactortypename2 as wrgoodsname," +
 		"       wg.bannerpicurl," +
 		"       wg.bannerpicurl," +
 		"       wg.pictureurls," +
 		"       wg.pictureurls," +
+		"       wg.thumurls," +
 		"       e.enumdicname" +
 		"       e.enumdicname" +
 		"  from wrQuote k" +
 		"  from wrQuote k" +
 		"  left join WRFactorType w" +
 		"  left join WRFactorType w" +