li.shaoyi 3 years ago
parent
commit
61e0ab9e8e
44 changed files with 1172 additions and 348 deletions
  1. 1 1
      public/config/appconfig.json
  2. 85 4
      public/proto/gz.proto
  3. 32 22
      src/business/goods/index.ts
  4. 127 16
      src/business/order/desting.ts
  5. 6 2
      src/business/order/list.ts
  6. 49 14
      src/business/order/listing.ts
  7. 1 0
      src/business/search/index.ts
  8. 90 80
      src/business/table/index.ts
  9. 6 4
      src/constants/funcode.ts
  10. 54 0
      src/constants/order.ts
  11. 106 18
      src/mock/router.ts
  12. 0 68
      src/packages/pc/components/modules/goods-details/index.vue
  13. 46 5
      src/packages/pc/views/listing/buy/components/delisting/index.vue
  14. 8 2
      src/packages/pc/views/listing/buy/components/details/index.vue
  15. 0 4
      src/packages/pc/views/listing/buy/index.vue
  16. 42 0
      src/packages/pc/views/listing/inquire/components/cancel/index.vue
  17. 14 1
      src/packages/pc/views/listing/inquire/index.vue
  18. 1 1
      src/packages/pc/views/listing/purchase/components/add/index.vue
  19. 43 0
      src/packages/pc/views/listing/purchase/components/cancel/index.vue
  20. 12 1
      src/packages/pc/views/listing/purchase/index.vue
  21. 7 5
      src/packages/pc/views/listing/sale/components/add/index.vue
  22. 43 0
      src/packages/pc/views/listing/sale/components/cancel/index.vue
  23. 13 1
      src/packages/pc/views/listing/sale/index.vue
  24. 0 32
      src/packages/pc/views/listing/sell/components/details/index.vue
  25. 1 4
      src/packages/pc/views/listing/sell/index.vue
  26. 2 2
      src/packages/pc/views/warehousing/goods/components/buy/index.vue
  27. 0 1
      src/packages/pc/views/warehousing/goods/components/details/index.less
  28. 67 5
      src/packages/pc/views/warehousing/goods/components/details/index.vue
  29. 1 1
      src/packages/pc/views/warehousing/goods/components/edit/diamond.vue
  30. 1 1
      src/packages/pc/views/warehousing/goods/components/edit/diamonds.vue
  31. 1 1
      src/packages/pc/views/warehousing/goods/components/edit/fancy.vue
  32. 1 1
      src/packages/pc/views/warehousing/goods/components/edit/jewelry.vue
  33. 1 1
      src/packages/pc/views/warehousing/goods/components/edit/rough.vue
  34. 6 6
      src/packages/pc/views/warehousing/goods/components/favorite/index.vue
  35. 20 14
      src/packages/pc/views/warehousing/goods/components/inquiry/index.vue
  36. 60 0
      src/packages/pc/views/warehousing/goods/components/put/index.vue
  37. 13 2
      src/packages/pc/views/warehousing/goods/index.vue
  38. 7 0
      src/services/api/common/index.ts
  39. 1 1
      src/services/api/goods/index.ts
  40. 14 7
      src/services/api/order/index.ts
  41. 18 0
      src/types/ermcp/common.d.ts
  42. 128 7
      src/types/ermcp/order.d.ts
  43. 2 1
      src/types/proto/goods.d.ts
  44. 42 12
      src/types/proto/order.d.ts

+ 1 - 1
public/config/appconfig.json

@@ -1,4 +1,4 @@
 {
   "version": "3.0.0",
-  "apiUrl": "http://192.168.31.201:8080/cfg?key=test_201"
+  "apiUrl": "http://218.17.158.45:23015/cfg?key=test_201"
 }

+ 85 - 4
public/proto/gz.proto

@@ -423,6 +423,7 @@ message ZSBuyOrderListingReq {
 	optional uint32 ClientType = 9; // 终端类型
 	optional string ClientSerialNo = 10; // 客户端流水号
 }
+
 // 钻石买挂牌接口应答
 message ZSBuyOrderListingRsp {
 	optional MessageHead Header = 1; // 消息头
@@ -468,7 +469,6 @@ message ZSSellOrderListingRsp {
 		optional string ClientSerialNo = 9; // 客户端流水号
 }
 
-
 // 钻石买摘牌接口请求
 message ZSBuyOrderDestingReq {
 	optional MessageHead Header = 1;
@@ -516,7 +516,6 @@ message ZSSellOrderDestingApplyReq {
 		optional uint64 MarketID = 14; // 市场ID,必填
 }
 
-
 // 钻石卖摘牌申请接口响应
 message ZSSellOrderDestingApplyRsp {
 	optional MessageHead Header = 1; // 消息头
@@ -528,7 +527,6 @@ message ZSSellOrderDestingApplyRsp {
 		optional string ClientSerialNo = 7; // 客户端流水号
 }
 
-
 // 钻石卖摘牌申请操作接口请求
 message ZSSellOrderDestingApplyOperateReq {
 	optional MessageHead Header = 1;
@@ -543,7 +541,6 @@ message ZSSellOrderDestingApplyOperateReq {
 		optional string ClientSerialNo = 10; // 客户端流水号
 }
 
-
 // 钻石卖摘牌申请操作接口应答
 message ZSSellOrderDestingApplyOperateRsp {
 	optional MessageHead Header = 1; // 消息头
@@ -556,4 +553,88 @@ message ZSSellOrderDestingApplyOperateRsp {
 		optional double FreezeAmount = 8; // 冻结货款
 		optional string OrderTime = 9; // 接收委托交易的时间
 		optional string ClientSerialNo = 10; // 客户端流水号
+}
+
+// 买摘牌询价接口请求
+message ZSBuyOrderDestingNegPriceReq {
+	optional MessageHead Header = 1;
+	optional uint32 UserID = 2; // 用户ID,必填
+	optional uint64 AccountID = 3; // 资金账号,必填
+	optional uint64 RelatedOrderID = 4; // 卖委托单号,必填
+	optional double OrderQty = 5; // 议价数量,2位小数,必填
+	optional double ApplyPrice = 6; // 协议价格,2位小数,必填
+	optional uint32 OrderSrc = 7; // 委托来源
+	optional string ClientSerialNo = 8; // 客户端流水号
+	optional string ClientOrderTime = 9; // 客户端委托时间
+	optional uint32 ClientType = 10; // 终端类型
+	optional uint64 OperatorID = 11; // 操作员账号ID
+	optional uint32 MarketID = 12; // 市场ID,必填
+	optional string ApplyRemark = 13; // 申请备注
+}
+
+// 买摘牌询价接口应答
+message ZSBuyOrderDestingNegPriceRsp {
+	optional MessageHead Header = 1; // 消息头
+	optional int32 RetCode = 2; // 返回码
+	optional string RetDesc = 3; // 描述信息
+		optional uint32 UserID = 4; // 用户ID
+		optional uint64 AccountID = 5; // 资金账号
+		optional uint64 WRTradeOrderID = 6; // 摘牌委托单ID
+		optional uint64 WRBargainID = 7; // 议价申请单ID
+		optional string OrderTime = 8; // 接收委托交易的时间
+		optional string ClientSerialNo = 9; // 客户端流水号
+}
+
+// 买摘牌询价操作接口请求
+message ZSBuyOrderDestingNegPriceOperateReq {
+	optional MessageHead Header = 1;
+		optional uint32 UserID = 2; // 用户ID,必填
+		optional uint64 AccountID = 3; // 资金账号,必填
+		optional uint64 WRBargainID = 4; // 议价申请单ID,必填
+		optional string AuditRemark = 5; // 备注
+		optional uint32 OperateType = 6; // 操作类型,1:撤销2:拒绝
+		optional uint32 MarketID = 7; // 市场ID,必填
+		optional uint32 ClientType = 8; // 终端类型
+		optional uint32 OrderSrc = 9; // 委托来源
+		optional string ClientSerialNo = 10; // 客户端流水号
+}
+
+// 买摘牌询价操作接口应答
+message ZSBuyOrderDestingNegPriceOperateRsp {
+	optional MessageHead Header = 1; // 消息头
+	optional int32 RetCode = 2; // 返回码
+	optional string RetDesc = 3; // 描述信息
+		optional uint32 UserID = 4; // 用户ID
+		optional uint64 AccountID = 5; // 资金账号
+		optional uint64 WRBargainID = 6; // 卖委托单号
+		optional string ClientSerialNo = 7; // 客户端流水号
+}
+
+// 挂牌撤单请求
+message WRListingCancelOrderReq {
+	optional MessageHead Header = 1;
+		optional uint32 UserID = 2; // 用户ID
+		optional uint64 AccountID = 3; // 资金账号
+		optional uint64 OldWRTradeOrderID = 4; // 目标仓单贸易委托单ID
+		optional uint32 OrderSrc = 5; // 委托来源
+		optional string ClientSerialNo = 6; // 客户端流水号
+		optional string ClientOrderTime = 7; // 客户端委托时间
+		optional uint32 ClientType = 8; // 终端类型
+		optional uint64 OperatorID = 9; // 操作员账号ID
+		optional uint32 BuyOrSell = 10; // 买卖方向
+		optional uint64 WRID = 11; // 仓单ID,卖的时候填写
+}
+
+// 挂牌撤单应答
+message WRListingCancelOrderRsp {
+	optional MessageHead Header = 1; // 消息头
+	optional int32 RetCode = 2; // 返回码
+	optional string RetDesc = 3; // 描述信息
+		optional uint64 WRTradeCancelID = 4; // 仓单贸易撤单号
+		optional uint64 OldWRTradeOrderID = 5; // 目标仓单贸易委托单ID
+		optional uint32 UserID = 6; // 用户ID
+		optional uint64 AccountID = 7; // 资金账号
+		optional uint64 CancelQty = 8; // 撤单数量
+		optional string OrderTime = 9; // 接受撤单的时间
+		optional string ClientSerialNo = 10; // 客户端流水号
 }

+ 32 - 22
src/business/goods/index.ts

@@ -27,6 +27,7 @@ import {
     getFancyColorType2List,
     getFancyColorType3List,
 } from '@/constants/diamond'
+import Long from 'long'
 
 // 钻石列表相关
 export function useDiamond() {
@@ -125,7 +126,6 @@ export function useDiamond() {
 
 // 钻石详情相关
 export function useDiamondDetails(goodsno: string) {
-    const { UserID } = sessionData.getValue('loginInfo')
     const loading = shallowRef(false)
     const details = shallowRef<Ermcp.DiamondDetailsRsp>()
 
@@ -144,33 +144,14 @@ export function useDiamondDetails(goodsno: string) {
         })
     }
 
-    // 钻石收藏
-    const diamondFavorite = () => {
-        loading.value = true
-        return goodsFavoriteOperate({
-            data: {
-                UserID, // 用户ID,必填
-                WRTradeOrderID: 0, // 委托单ID,必填
-                OperateType: 1, // 操作类型,1:添加2:删除,必填
-                ClientType: ClientType.Web, // 终端类型
-                MarketID: Market.GZ, // 市场ID,必填
-                ClientSerialNo: v4() // 客户端流水号
-            },
-            complete: () => {
-                loading.value = false
-            }
-        })
-    }
-
     return {
         loading,
         details,
         getDiamondDetails,
-        diamondFavorite
     }
 }
 
-// 钻石表单操作相关
+// 钻石上架相关
 export function useDiamondForm(category: Category) {
     const { UserID, AccountIDs } = sessionData.getValue('loginInfo')
     const loading = shallowRef(false)
@@ -269,7 +250,7 @@ export function useDiamondForm(category: Category) {
                 AccountID: AccountIDs[0],
                 AddType: performanceId.value ? 2 : 1,
                 MarketID: Market.GZ,
-                OrderSrc: 2,
+                OrderSrc: 1,
                 ClientType: ClientType.Web,
                 ClientSerialNo: v4(),
                 GZ_WRStandardExInfo: formData,
@@ -305,4 +286,33 @@ export function useDiamondForm(category: Category) {
         currencyInfo,
         addOrUpdate,
     }
+}
+
+// 钻石收藏相关
+export function useDiamondFavorite(selectedRow: Ermcp.SellOrderRsp) {
+    const { UserID } = sessionData.getValue('loginInfo')
+    const loading = shallowRef(false)
+
+    // 钻石收藏
+    const diamondFavorite = () => {
+        loading.value = true
+        return goodsFavoriteOperate({
+            data: {
+                UserID, // 用户ID,必填
+                WRTradeOrderID: Long.fromString(selectedRow.wrtradeorderid), // 委托单ID,必填
+                OperateType: 1, // 操作类型,1:添加2:删除,必填
+                ClientType: ClientType.Web, // 终端类型
+                MarketID: Market.GZ, // 市场ID,必填
+                ClientSerialNo: v4() // 客户端流水号
+            },
+            complete: () => {
+                loading.value = false
+            }
+        })
+    }
+
+    return {
+        loading,
+        diamondFavorite
+    }
 }

+ 127 - 16
src/business/order/desting.ts

@@ -4,13 +4,13 @@ import { ClientType } from '@/constants/client'
 import { Market } from '@/constants/market'
 import { useDataTable } from '@/hooks/datatable'
 import { queryDiamondList } from '@/services/api/goods'
-import { zsBuyOrderDesting, zsSellOrderDestingApply } from '@/services/api/order'
+import { zsBuyOrderDesting, zsBuyOrderDestingNegPrice, zsSellOrderDestingApply, zsBuyOrderDestingNegPriceOperate, zsSellOrderDestingApplyOperate } from '@/services/api/order'
 import { sessionData } from '@/stores'
 import moment from 'moment'
 import Long from 'long'
 
 /**
- * 钻石买摘牌(商品购买)
+ * 钻石买摘牌(立即购买)
  * @returns 
  */
 export function useBuyOrderDesting(selectedRow: Ermcp.SellOrderRsp) {
@@ -28,7 +28,7 @@ export function useBuyOrderDesting(selectedRow: Ermcp.SellOrderRsp) {
                 AccountID: AccountIDs[0],
                 RelatedWRTradeOrderID: Long.fromString(selectedRow.wrtradeorderid),
                 OrderQty: selectedRow.remainqty,
-                OrderSrc: 2,
+                OrderSrc: 1,
                 ClientSerialNo: v4(),
                 ClientOrderTime: moment().format('YYYY-MM-DD HH:mm:ss'),
                 ClientType: ClientType.Web,
@@ -48,10 +48,54 @@ export function useBuyOrderDesting(selectedRow: Ermcp.SellOrderRsp) {
 }
 
 /**
- * 钻石卖摘牌
+ * 钻石买摘牌(买询价)
  * @returns 
  */
-export function useSellOrderDesting(selectedRow: Ermcp.BuyOrderRsp) {
+export function useBuyOrderInquiry(selectedRow: Ermcp.SellOrderRsp) {
+    const { UserID, AccountIDs } = sessionData.getValue('loginInfo')
+    const loading = shallowRef(false)
+
+    const formData = reactive<Proto.ZSBuyOrderDestingNegPriceReq>({
+        Header: {
+            AccountID: AccountIDs[0],
+        },
+        UserID, // 用户ID,必填
+        AccountID: AccountIDs[0], // 资金账号,必填
+        RelatedOrderID: Long.fromString(selectedRow.wrtradeorderid), // 卖委托单号,必填
+        OrderQty: selectedRow.remainqty, // 议价数量,2位小数,必填
+        OrderSrc: 1, // 委托来源
+        ClientType: ClientType.Web, // 终端类型
+        OperatorID: UserID, // 操作员账号ID
+        MarketID: Market.GZ, // 市场ID,必填
+        ApplyRemark: '' // 申请备注
+    })
+
+    const formSubmit = () => {
+        loading.value = true
+        return zsBuyOrderDestingNegPrice({
+            data: {
+                ...formData,
+                ClientSerialNo: v4(),
+                ClientOrderTime: moment().format('YYYY-MM-DD HH:mm:ss')
+            },
+            complete: () => {
+                loading.value = false
+            }
+        })
+    }
+
+    return {
+        loading,
+        formData,
+        formSubmit
+    }
+}
+
+/**
+ * 钻石卖摘牌(卖询价)
+ * @returns 
+ */
+export function useSellOrderInquiry(selectedRow: Ermcp.BuyOrderRsp) {
     const { UserID, AccountIDs } = sessionData.getValue('loginInfo')
     const { dataList } = useDataTable<Ermcp.MyWRPositionRsp>()
     const loading = shallowRef(false)
@@ -65,7 +109,6 @@ export function useSellOrderDesting(selectedRow: Ermcp.BuyOrderRsp) {
         BuyWRTradeOrderID: Long.fromString(selectedRow.wrtradeorderid), // 买挂牌委托单ID,必填
         WRStandardID: 0, // 现货商品ID,必填
         ApplyQty: 0, // 申请数量,必填,2位小数
-        ApplyPrice: 0, // 申请价格,必填,2位小数
         LadingBillID: Long.fromNumber(0), // 提单ID,必填
         SubNum: 0, // 提单子单号,必填
         ApplyRemark: '', // 备注
@@ -101,21 +144,89 @@ export function useSellOrderDesting(selectedRow: Ermcp.BuyOrderRsp) {
     }
 
     // 获取商品列表
-    queryDiamondList({
-        data: {
-            wruserid: UserID,
-            zscategory: selectedRow.zscategory,
-        },
-        success: (res) => {
-            dataList.value = res.data.filter((e) => e.ftotalqty - e.ffreezeqty > 0)
-        },
-    })
+    const getDiamondList = () => {
+        return queryDiamondList({
+            data: {
+                wruserid: UserID,
+                zscategory: selectedRow.zscategory,
+            },
+            success: (res) => {
+                dataList.value = res.data.filter((e) => e.ftotalqty - e.ffreezeqty > 0)
+            },
+        })
+    }
 
     return {
         loading,
         dataList,
         columns,
         formData,
-        formSubmit
+        formSubmit,
+        getDiamondList,
+    }
+}
+
+/**
+ * 钻石询价操作
+ * @returns 
+ */
+export function useInquiryOperate(selectedRow: Ermcp.MyBargainApplyRsp | Ermcp.MyDelistingApplyRsp) {
+    const { UserID, AccountIDs } = sessionData.getValue('loginInfo')
+    const loading = shallowRef(false)
+
+    const formSubmit = () => {
+        loading.value = true
+
+        // 买询价操作
+        if ('wrbargainid' in selectedRow) {
+            return zsBuyOrderDestingNegPriceOperate({
+                data: {
+                    Header: {
+                        AccountID: AccountIDs[0],
+                    },
+                    UserID, // 用户ID,必填
+                    AccountID: AccountIDs[0], // 资金账号,必填
+                    WRBargainID: Long.fromString(selectedRow.wrbargainid), // 议价申请单ID,必填
+                    OperateType: 1, // 操作类型,1:撤销2:拒绝
+                    MarketID: Market.GZ, // 市场ID,必填
+                    ClientType: ClientType.Web, // 终端类型
+                    OrderSrc: 1, // 委托来源
+                    ClientSerialNo: v4() // 客户端流水号
+                },
+                complete: () => {
+                    loading.value = false
+                }
+            })
+        }
+
+        // 卖询价操作
+        if ('selldelistingapplyid' in selectedRow) {
+            return zsSellOrderDestingApplyOperate({
+                data: {
+                    Header: {
+                        AccountID: AccountIDs[0],
+                    },
+                    UserID, // 用户ID,必填
+                    AccountID: AccountIDs[0], // 资金账号,必填
+                    SellDelistingApplyID: selectedRow.selldelistingapplyid, // 卖摘牌申请ID,必填
+                    OperateType: 1, // 操作类型,1:撤销2:拒绝
+                    MarketID: Market.GZ, // 市场ID,必填
+                    ClientType: ClientType.Web, // 终端类型
+                    OrderSrc: 1, // 委托来源
+                    ClientSerialNo: v4(), // 客户端流水号
+                },
+                complete: () => {
+                    loading.value = false
+                }
+            })
+        }
+
+        loading.value = false
+        return Promise.reject('参数错误')
+    }
+
+    return {
+        loading,
+        formSubmit,
     }
 }

+ 6 - 2
src/business/order/list.ts

@@ -3,6 +3,7 @@ import { useDataTable } from '@/hooks/datatable'
 import { getTableColumns } from '@/business/table'
 import { queryBuyOrder, querySellOrder, queryMyBuyOrder, queryMySellOrder, queryMyDeListing, queryMyBargainApply, queryMyDelistingApply } from '@/services/api/order'
 import { sessionData } from '@/stores'
+import { getBuyOrSellList } from '@/constants/order'
 import { Category, getCategoryList } from '@/constants/diamond'
 
 /**
@@ -303,13 +304,13 @@ export function useDelistingOrder() {
         {
             label: '方向',
             key: 'buyorsell',
-            options: [],
+            options: getBuyOrSellList(),
         },
     ]
 
     inputList.value = [
         { label: '对手方', keys: ['matchusername'] },
-        { label: '商品', keys: ['zscategorydisplay'] },
+        { label: '商品', keys: ['goodsno'] },
     ]
 
     // 获取我的摘牌列表
@@ -321,7 +322,10 @@ export function useDelistingOrder() {
                 page: pageIndex.value,
                 pagesize: pageSize.value,
                 userid: sessionData.getLoginInfo('UserID'),
+                buyorsell: param.buyorsell,
+                matchusername: param.matchusername,
                 zscategorys: param.zscategory ? param.zscategory.toString() : categoryList.map((e) => e.value).join(','),
+                zsallproperties: param.goodsno
             },
             success: (res) => {
                 total.value = res.total

+ 49 - 14
src/business/order/listing.ts

@@ -4,7 +4,7 @@ import { ClientType } from '@/constants/client'
 import { useDataTable } from '@/hooks/datatable'
 import { Market } from '@/constants/market'
 import { queryDiamondList } from '@/services/api/goods'
-import { zsBuyOrderListing, zsSellOrderListing } from '@/services/api/order'
+import { zsBuyOrderListing, zsSellOrderListing, wrListingCancelOrder } from '@/services/api/order'
 import { sessionData } from '@/stores'
 import {
     Category,
@@ -25,7 +25,7 @@ import moment from 'moment'
 import Long from 'long'
 
 /**
- * 求购大厅挂牌
+ * 钻石求购挂牌
  * @returns 
  */
 export function useBuyOrderListing() {
@@ -80,7 +80,7 @@ export function useBuyOrderListing() {
                 UserID,
                 AccountID: AccountIDs[0],
                 MarketID: Market.GZ,
-                OrderSrc: 2,
+                OrderSrc: 1,
                 ClientType: ClientType.Web,
                 ClientSerialNo: v4(),
                 PerformanceTemplateID: performanceId.value,
@@ -103,17 +103,19 @@ export function useBuyOrderListing() {
 }
 
 /**
- * 出售大厅挂牌
+ * 钻石出售挂牌
  * @returns 
  */
-export function useSellOrderListing() {
+export function useSellOrderListing(selectedRow?: Ermcp.MyWRPositionRsp) {
     const { dataList } = useDataTable<Ermcp.MyWRPositionRsp>()
     const { UserID, AccountIDs } = sessionData.getValue('loginInfo')
+    const { zscategory, wrstandardid = 0, ladingbillid = '0', subnum = 0, ftotalqty = 0, ffreezeqty = 0 } = selectedRow ?? {}
+
     const submitLoading = shallowRef(false)
     const tableLoading = shallowRef(false)
     const columns = shallowRef<Ermcp.TableColumn[]>([])
     const categoryList = getCategoryList() // 分类列表
-    const selectedCategoryId = shallowRef(Category.Diamonds)
+    const selectedCategoryId = shallowRef(zscategory ?? Category.Diamonds)
 
     const formData = reactive<Proto.ZSSellOrderListingReq>({
         Header: {
@@ -121,12 +123,12 @@ export function useSellOrderListing() {
         },
         UserID,
         AccountID: AccountIDs[0],
-        WRStandardID: 0,
-        OrderQty: 0,
-        LadingBillID: Long.fromNumber(0),
-        SubNum: 0,
+        WRStandardID: wrstandardid,
+        OrderQty: ftotalqty - ffreezeqty,
+        LadingBillID: Long.fromString(ladingbillid),
+        SubNum: subnum,
         TimevalidType: 4, // 4:一直有效
-        OrderSrc: 2,
+        OrderSrc: 1,
         ClientSerialNo: '',
         ClientOrderTime: '',
         ClientType: ClientType.Web,
@@ -241,9 +243,6 @@ export function useSellOrderListing() {
         })
     }
 
-    // 初始化
-    categoryChange()
-
     return {
         submitLoading,
         tableLoading,
@@ -255,4 +254,40 @@ export function useSellOrderListing() {
         categoryChange,
         formSubmit,
     }
+}
+
+/**
+ * 钻石挂牌撤单
+ */
+export function useListingCancel(wrtradeorderid: string, buyorsell: number) {
+    const { UserID, AccountIDs } = sessionData.getValue('loginInfo')
+    const loading = shallowRef(false)
+
+    const formSubmit = () => {
+        loading.value = true
+        return wrListingCancelOrder({
+            data: {
+                Header: {
+                    AccountID: AccountIDs[0],
+                },
+                UserID, // 用户ID
+                AccountID: AccountIDs[0], // 资金账号
+                OldWRTradeOrderID: Long.fromString(wrtradeorderid), // 目标仓单贸易委托单ID
+                OrderSrc: 1, // 委托来源
+                ClientType: ClientType.Web, // 终端类型
+                OperatorID: UserID, // 操作员账号ID
+                BuyOrSell: buyorsell, // 买卖方向
+                ClientSerialNo: v4(),
+                ClientOrderTime: moment().format('YYYY-MM-DD HH:mm:ss')
+            },
+            complete: () => {
+                loading.value = false
+            }
+        })
+    }
+
+    return {
+        loading,
+        formSubmit,
+    }
 }

+ 1 - 0
src/business/search/index.ts

@@ -61,6 +61,7 @@ export function useSearch(category: Category) {
                 zscerttype: zscerttype?.map((val) => val.toString())
             },
             success: (res) => {
+                total.value = res.total
                 dataList.value = res.data
             },
             complete: () => {

+ 90 - 80
src/business/table/index.ts

@@ -26,18 +26,20 @@ const pcTableColumnMap = new Map<TableColumnKey, Ermcp.TableColumn[]>([
     ]],
     // 我的仓储-我的库存
     ['warehousing_diamond', [
-        { prop: 'goodsno', label: '商品编号' },
-        { prop: 'price', label: '总价' },
-        { prop: 'weight', label: '总重量' },
-        { prop: 'weightavg', label: '平均单颗重量' },
-        { prop: 'priceper', label: '克拉单位' },
-        { prop: 'ftotalqty', label: '库存重量' },
-        { prop: 'ffreezeqty', label: '冻结重量' },
-        { prop: 'warehousenamedisplay', label: '仓库', width: 180 },
+        { prop: 'warehouseid', label: '仓库' },
         { prop: 'zsshapetypedisplay', label: '形状', width: 200 },
-        { prop: 'zscolortype', label: '颜色' },
-        { prop: 'zsclaritytype', label: '净度' },
-        { prop: 'operate', label: '操作' }
+        { prop: 'zscolortype1display', label: '颜色' },
+        { prop: 'zsclaritytype1display', label: '净度' },
+        { prop: 'zscuttype1display', label: '切工' },
+        { prop: 'zspolishtype1display', label: '抛光' },
+        { prop: 'zssymmetrytype1display', label: '对称' },
+        { prop: 'zsfluorescencetype1display', label: '荧光' },
+        { prop: 'size1', label: '尺寸' },
+        { prop: 'price', label: '价格' },
+        { prop: 'weight', label: '克拉重量' },
+        { prop: 'priceper', label: '克拉单价' },
+        { prop: 'zsclaritytype', label: '是否上架' },
+        { prop: 'operate', label: '操作', width: 240 }
     ]],
     // 我的仓储-我的仓库
     ['warehousing_warehouse', [
@@ -51,53 +53,61 @@ const pcTableColumnMap = new Map<TableColumnKey, Ermcp.TableColumn[]>([
     ]],
     // 挂牌大厅-出售大厅
     ['listing_sellorder', [
-        { prop: 'wrtradeorderid', label: '卖方' },
-        { prop: 'sellusername', label: '仓库' },
-        { prop: 'zscategorydisplay', label: '形状' },
-        { prop: 'goodsno', label: '颜色' },
-        { prop: 'totalqty', label: '净度' },
-        { prop: 'fixedprice', label: '切工' },
-        { prop: 'remainqty', label: '抛光' },
-        { prop: 'wrtradeorderstatus', label: '对称' },
-        { prop: 'ordertime', label: '荧光' },
-        { prop: 'tradedate', label: '尺寸' },
-        { prop: 'tradedate', label: '价格' },
-        { prop: 'tradedate', label: '克拉重量' },
-        { prop: 'tradedate', label: '克拉单价' },
+        { prop: 'sellusername', label: '卖方' },
+        { prop: 'warehousenamedisplay', label: '仓库', width: 180 },
+        { prop: 'zsshapetypedisplay', label: '形状', width: 200 },
+        { prop: 'zscolortype1display', label: '颜色' },
+        { prop: 'zsclaritytype1display', label: '净度' },
+        { prop: 'zscuttype1display', label: '切工' },
+        { prop: 'zspolishtype1display', label: '抛光' },
+        { prop: 'zssymmetrytype1display', label: '对称' },
+        { prop: 'zsfluorescencetype1display', label: '荧光' },
+        { prop: 'size1', label: '尺寸' },
+        { prop: 'price', label: '价格' },
+        { prop: 'totalqty', label: '克拉重量' },
+        { prop: 'fixedprice', label: '克拉单价' },
         { prop: 'operate', label: '操作', width: 180 }
     ]],
     // 挂牌大厅-求购大厅
     ['listing_buyorder', [
-        { prop: 'wrtradeorderid', label: '委托单号', width: 200 },
         { prop: 'buyusername', label: '买方' },
-        { prop: 'zscategorydisplay', label: '商品分类' },
-        { prop: 'zstabledisplay', label: '求购信息' },
-        { prop: 'wrtradeorderstatus', label: '状态' },
-        { prop: 'validtime', label: '有效日期', width: 180 },
-        { prop: 'ordertime', label: '委托时间', width: 180 },
+        { prop: 'zsshapetypedisplay', label: '形状', width: 200 },
+        { prop: 'zscolortypedisplay', label: '颜色' },
+        { prop: 'zsclaritytypedisplay', label: '净度' },
+        { prop: 'zscuttypedisplay', label: '切工' },
+        { prop: 'zspolishtypedisplay', label: '抛光' },
+        { prop: 'zssymmetrytypedisplay', label: '对称' },
+        { prop: 'zsfluorescencetypedisplay', label: '荧光' },
+        { prop: 'zssize', label: '尺寸' },
         { prop: 'operate', label: '操作' }
     ]],
     // 挂牌大厅-我的出售
     ['listing_saleorder', [
-        { prop: 'wrtradeorderid', label: '委托单号', width: 200 },
-        { prop: 'zscategorydisplay', label: '商品分类' },
-        { prop: 'goodsno', label: '商品编号' },
-        { prop: 'totalqty', label: '委托重量' },
-        { prop: 'fixedprice', label: '克拉单价' },
-        { prop: 'selledqty', label: '成交重量' },
-        { prop: 'wrtradeorderstatus', label: '委托状态' },
-        { prop: 'ordertime', label: '委托时间', width: 180 },
-        { prop: 'operate', label: '操作' }
+        { prop: 'warehousenamedisplay', label: '仓库', width: 180 },
+        { prop: 'zsshapetypedisplay', label: '形状', width: 200 },
+        { prop: 'zscolortype1display', label: '颜色' },
+        { prop: 'zsclaritytype1display', label: '净度' },
+        { prop: 'zscuttype1display', label: '切工' },
+        { prop: 'zspolishtype1display', label: '抛光' },
+        { prop: 'zssymmetrytype1display', label: '对称' },
+        { prop: 'zsfluorescencetype1display', label: '荧光' },
+        { prop: 'size1', label: '尺寸' },
+        { prop: 'price', label: '价格' },
+        { prop: 'fixedprice', label: '克拉重量' },
+        { prop: 'totalqty', label: '克拉单价' },
+        { prop: 'operate', label: '操作', width: 180 }
     ]],
     // 挂牌大厅-我的求购
     ['listing_purchaseorder', [
-        { prop: 'wrtradeorderid', label: '委托单号', width: 200 },
-        { prop: 'zscategorydisplay', label: '商品分类' },
-        { prop: 'zstabledisplay', label: '求购信息' },
-        { prop: 'wrtradeorderstatus', label: '状态' },
-        { prop: 'validtime', label: '有效日期', width: 180 },
-        { prop: 'ordertime', label: '委托时间', width: 180 },
-        { prop: 'operate', label: '操作' }
+        { prop: 'zsshapetypedisplay', label: '形状', width: 200 },
+        { prop: 'zscolortypedisplay', label: '颜色' },
+        { prop: 'zsclaritytypedisplay', label: '净度' },
+        { prop: 'zscuttypedisplay', label: '切工' },
+        { prop: 'zspolishtypedisplay', label: '抛光' },
+        { prop: 'zssymmetrytypedisplay', label: '对称' },
+        { prop: 'zsfluorescencetypedisplay', label: '荧光' },
+        { prop: 'zssize', label: '尺寸' },
+        { prop: 'operate', label: '操作', width: 180 }
     ]],
     // 挂牌大厅-我的摘牌
     ['listing_delisting', [
@@ -110,9 +120,9 @@ const pcTableColumnMap = new Map<TableColumnKey, Ermcp.TableColumn[]>([
         { prop: 'zspolishtype1display', label: '抛光' },
         { prop: 'zssymmetrytype1display', label: '对称' },
         { prop: 'zsfluorescencetype1display', label: '荧光' },
-        { prop: 'ordertime', label: '尺寸' },
+        { prop: 'sizedisplay', label: '尺寸' },
         { prop: 'qty', label: '重量' },
-        { prop: 'ordertime', label: '价格' },
+        { prop: 'price', label: '价格' },
         { prop: 'exchangerate', label: '汇率' },
         { prop: 'tradeprice', label: '成交价格' },
         { prop: 'tradetime', label: '成交时间', width: 200 },
@@ -120,41 +130,41 @@ const pcTableColumnMap = new Map<TableColumnKey, Ermcp.TableColumn[]>([
     ]],
     // 挂牌大厅-我的询价-求购
     ['listing_inquire_buy', [
-        { prop: 'buyorsell', label: '类型' },
-        { prop: 'matchusername', label: '对手方' },
-        { prop: 'zstabledisplay', label: '形状' },
-        { prop: 'wrtradeorderstatus', label: '颜色' },
-        { prop: 'validtime', label: '净度' },
-        { prop: 'ordertime', label: '切工' },
-        { prop: 'ordertime', label: '抛光' },
-        { prop: 'ordertime', label: '对称' },
-        { prop: 'ordertime', label: '荧光' },
-        { prop: 'ordertime', label: '尺寸' },
-        { prop: 'qty', label: '重量' },
-        { prop: 'ordertime', label: '价格' },
-        { prop: 'exchangerate', label: '汇率' },
-        { prop: 'tradeprice', label: '成交价格' },
-        { prop: 'tradetime', label: '成交时间', width: 200 },
-        { prop: 'operate', label: '操作' }
+        { prop: 'sellusername', label: '卖方' },
+        { prop: 'warehousenamedisplay', label: '仓库' },
+        { prop: 'zsshapetypedisplay', label: '形状' },
+        { prop: 'zscolortype1display', label: '颜色' },
+        { prop: 'zsclaritytype1display', label: '净度' },
+        { prop: 'zscuttype1display', label: '切工' },
+        { prop: 'zspolishtype1display', label: '抛光' },
+        { prop: 'zssymmetrytype1display', label: '对称' },
+        { prop: 'zsfluorescencetype1display', label: '荧光' },
+        { prop: 'sizedisplay', label: '尺寸' },
+        { prop: 'price', label: '价格' },
+        { prop: 'qty', label: '克拉重量' },
+        { prop: 'exchangerate', label: '克拉单价' },
+        { prop: 'applyprice', label: '我的出价' },
+        { prop: 'applystatus', label: '申请状态' },
+        { prop: 'applytime', label: '申请时间', width: 200 },
+        { prop: 'operate', label: '操作', width: 180 }
     ]],
     // 挂牌大厅-我的询价-出售
     ['listing_inquire_sell', [
-        { prop: 'buyorsell', label: '类型' },
-        { prop: 'matchusername', label: '对手方' },
-        { prop: 'zstabledisplay', label: '形状' },
-        { prop: 'wrtradeorderstatus', label: '颜色' },
-        { prop: 'validtime', label: '净度' },
-        { prop: 'ordertime', label: '切工' },
-        { prop: 'ordertime', label: '抛光' },
-        { prop: 'ordertime', label: '对称' },
-        { prop: 'ordertime', label: '荧光' },
-        { prop: 'ordertime', label: '尺寸' },
-        { prop: 'qty', label: '重量' },
-        { prop: 'ordertime', label: '价格' },
-        { prop: 'exchangerate', label: '汇率' },
-        { prop: 'tradeprice', label: '成交价格' },
-        { prop: 'tradetime', label: '成交时间', width: 200 },
-        { prop: 'operate', label: '操作' }
+        { prop: 'buyusername', label: '买方' },
+        { prop: 'zsshapetypedisplay', label: '形状' },
+        { prop: 'zscolortype1display', label: '颜色' },
+        { prop: 'zsclaritytype1display', label: '净度' },
+        { prop: 'zscuttype1display', label: '切工' },
+        { prop: 'zspolishtype1display', label: '抛光' },
+        { prop: 'zssymmetrytype1display', label: '对称' },
+        { prop: 'zsfluorescencetype1display', label: '荧光' },
+        { prop: 'sizedisplay', label: '尺寸' },
+        { prop: 'goodsno', label: '我的商品' },
+        { prop: 'applyqty', label: '克拉重量' },
+        { prop: 'applyprice', label: '我的出价' },
+        { prop: 'applystatus', label: '申请状态' },
+        { prop: 'applytime', label: '申请时间', width: 200 },
+        { prop: 'operate', label: '操作', width: 180 }
     ]],
     // 会员中心-我的出入金
     ['mine_capital', [

+ 6 - 4
src/constants/funcode.ts

@@ -35,12 +35,14 @@ export enum FunCode {
     ZSBuyOrderDestingRsp = 1441832, // 钻石买摘牌接口响应
     ZSSellOrderDestingApplyReq = 1441839, // 钻石卖摘牌申请接口请求
     ZSSellOrderDestingApplyRsp = 1441840, // 钻石卖摘牌申请接口响应
-    ZSSellOrderDestingApplyOperateReq = 1441841, // 钻石卖摘牌申请操作接口请求
-    ZSSellOrderDestingApplyOperateRsp = 1441842, // 钻石卖摘牌申请操作接口应答
     ZSBuyOrderDestingNegPriceReq = 1441833, // 买摘牌询价接口请求
     ZSBuyOrderDestingNegPriceRsp = 1441834, // 买摘牌询价接口应答
-    ZSBuyOrderDestingNegPriceOperateReq = 1441835, // 买摘牌询价操作接口请求
-    ZSBuyOrderDestingNegPriceOperateRsp = 1441836, // 买摘牌询价操作接口应答
+    ZSBuyOrderDestingNegPriceOperateReq = 1441835, // 买摘牌询价操作接口请求(钻石买询价操作接口请求)
+    ZSBuyOrderDestingNegPriceOperateRsp = 1441836, // 买摘牌询价操作接口应答(钻石买询价操作接口应答)
+    ZSSellOrderDestingApplyOperateReq = 1441841, // 钻石卖摘牌申请操作接口请求(钻石卖询价申请操作接口请求)
+    ZSSellOrderDestingApplyOperateRsp = 1441842, // 钻石卖摘牌申请操作接口应答(钻石卖询价申请操作接口应答)
+    WRListingCancelOrderReq = 1441796, // 挂牌撤单请求(钻石挂牌撤单请求)
+    WRListingCancelOrderRsp = 1441797, // 挂牌撤单应答(钻石挂牌撤单应答)
 
     GoodsFavoriteOperateReq = 1441843, // 商品收藏操作接口请求
     GoodsFavoriteOperateRsp = 1441844, // 商品收藏操作接口应答

+ 54 - 0
src/constants/order.ts

@@ -0,0 +1,54 @@
+import { getEnumTypes, getEnumTypeName, getEnumTypeList } from './index'
+
+const enumKeys = ['wrApplyStatus'] as const
+const enumMap = getEnumTypes(...enumKeys)
+
+/**
+ * 买卖方向
+ */
+export enum BuyOrSell {
+    Buy = 0, // 买
+    Sell = 1, // 卖
+}
+
+/**
+ * 获取买卖方向列表
+ * @returns 
+ */
+export function getBuyOrSellList() {
+    return [
+        { label: '买', value: BuyOrSell.Buy },
+        { label: '卖', value: BuyOrSell.Sell },
+    ]
+}
+
+/**
+ * 获取买卖方向名称
+ * @returns 
+ */
+export function getBuyOrSellName(value: number) {
+    return getEnumTypeName(getBuyOrSellList(), value)
+}
+
+/**
+ * 申请状态
+ */
+export enum ApplyStatus {
+    Pending = 1, // 待确认
+}
+
+/**
+ * 获取申请状态列表
+ * @returns 
+ */
+export function getApplyStatusList() {
+    return getEnumTypeList(enumMap.get('wrApplyStatus'))
+}
+
+/**
+ * 获取申请状态名称
+ * @returns 
+ */
+export function getApplyStatusName(value: number) {
+    return getEnumTypeName(getApplyStatusList(), value)
+}

+ 106 - 18
src/mock/router.ts

@@ -67,17 +67,9 @@ const appmenu = {
                         children: [
                             {
                                 authType: 3,
-                                title: '我要出售',
-                                code: 'listing_sell_add',
-                                component: 'views/listing/sell/components/add/index.vue',
-                                buttonName: 'add',
-                                buttonType: 'primary',
-                            },
-                            {
-                                authType: 3,
                                 title: '详情',
                                 code: 'listing_sell_details',
-                                component: 'components/modules/goods-details/index.vue',
+                                component: 'views/warehousing/goods/components/details/index.vue',
                                 buttonName: 'details',
                                 buttonType: 'primary',
                             },
@@ -102,14 +94,6 @@ const appmenu = {
                         children: [
                             {
                                 authType: 3,
-                                title: '我要求购',
-                                code: 'listing_buy_add',
-                                component: 'views/listing/buy/components/add/index.vue',
-                                buttonName: 'add',
-                                buttonType: 'primary',
-                            },
-                            {
-                                authType: 3,
                                 title: '详情',
                                 code: 'listing_buy_details',
                                 component: 'views/listing/buy/components/details/index.vue',
@@ -136,6 +120,32 @@ const appmenu = {
                         url: 'sale',
                         urlType: 1,
                         component: 'views/listing/sale/index.vue',
+                        children: [
+                            {
+                                authType: 3,
+                                title: '我要出售',
+                                code: 'listing_sale_add',
+                                component: 'views/listing/sale/components/add/index.vue',
+                                buttonName: 'add',
+                                buttonType: 'primary',
+                            },
+                            {
+                                authType: 3,
+                                title: '详情',
+                                code: 'listing_sale_details',
+                                component: 'views/listing/sale/components/details/index.vue',
+                                buttonName: 'details',
+                                buttonType: 'primary',
+                            },
+                            {
+                                authType: 3,
+                                title: '撤销',
+                                code: 'listing_sale_cancel',
+                                component: 'views/listing/sale/components/cancel/index.vue',
+                                buttonName: 'cancel',
+                                buttonType: 'primary',
+                            },
+                        ]
                     },
                     {
                         authType: 1,
@@ -145,6 +155,32 @@ const appmenu = {
                         url: 'purchase',
                         urlType: 1,
                         component: 'views/listing/purchase/index.vue',
+                        children: [
+                            {
+                                authType: 3,
+                                title: '我要求购',
+                                code: 'listing_purchase_add',
+                                component: 'views/listing/purchase/components/add/index.vue',
+                                buttonName: 'add',
+                                buttonType: 'primary',
+                            },
+                            {
+                                authType: 3,
+                                title: '详情',
+                                code: 'listing_purchase_details',
+                                component: 'views/listing/purchase/components/details/index.vue',
+                                buttonName: 'details',
+                                buttonType: 'primary',
+                            },
+                            {
+                                authType: 3,
+                                title: '撤销',
+                                code: 'listing_purchase_cancel',
+                                component: 'views/listing/purchase/components/cancel/index.vue',
+                                buttonName: 'cancel',
+                                buttonType: 'primary',
+                            },
+                        ]
                     },
                     {
                         authType: 1,
@@ -154,6 +190,16 @@ const appmenu = {
                         url: 'delisting',
                         urlType: 1,
                         component: 'views/listing/delisting/index.vue',
+                        children: [
+                            {
+                                authType: 3,
+                                title: '详情',
+                                code: 'listing_delisting_details',
+                                component: 'views/listing/delisting/components/details/index.vue',
+                                buttonName: 'details',
+                                buttonType: 'primary',
+                            },
+                        ]
                     },
                     {
                         authType: 1,
@@ -163,6 +209,24 @@ const appmenu = {
                         url: 'inquire',
                         urlType: 1,
                         component: 'views/listing/inquire/index.vue',
+                        children: [
+                            {
+                                authType: 3,
+                                title: '详情',
+                                code: 'listing_inquire_details',
+                                component: 'views/listing/inquire/components/details/index.vue',
+                                buttonName: 'details',
+                                buttonType: 'primary',
+                            },
+                            {
+                                authType: 3,
+                                title: '撤销',
+                                code: 'listing_inquire_cancel',
+                                component: 'views/listing/inquire/components/cancel/index.vue',
+                                buttonName: 'cancel',
+                                buttonType: 'primary',
+                            },
+                        ]
                     }
                 ]
             },
@@ -208,7 +272,31 @@ const appmenu = {
                                 component: 'views/warehousing/goods/components/details/index.vue',
                                 buttonName: 'details',
                                 buttonType: 'primary',
-                            }
+                            },
+                            {
+                                authType: 3,
+                                title: '上架',
+                                code: 'warehousing_goods_put',
+                                component: 'views/warehousing/goods/components/put/index.vue',
+                                buttonName: 'put',
+                                buttonType: 'primary',
+                            },
+                            {
+                                authType: 3,
+                                title: '下架',
+                                code: 'warehousing_goods_pull',
+                                component: 'views/warehousing/goods/components/pull/index.vue',
+                                buttonName: 'pull',
+                                buttonType: 'primary',
+                            },
+                            {
+                                authType: 3,
+                                title: '删除',
+                                code: 'warehousing_goods_delete',
+                                component: 'views/warehousing/goods/components/delete/index.vue',
+                                buttonName: 'delete',
+                                buttonType: 'primary',
+                            },
                         ]
                     },
                     {

+ 0 - 68
src/packages/pc/components/modules/goods-details/index.vue

@@ -1,68 +0,0 @@
-<!-- 商品详情 -->
-<template>
-    <teleport :to="teleport">
-        <app-view class="app-details" v-bind="$attrs">
-            <template #header>
-                <div>
-                    <el-button @click="$emit('closed')">返回</el-button>
-                    <el-button type="primary" @click="openComponent('buy')" v-if="showButton">立即购买</el-button>
-                    <el-button type="primary" @click="openComponent('inquiry')" v-if="showButton">询价申请</el-button>
-                </div>
-            </template>
-            <template v-if="details">
-                <div class="app-details__intro">
-                    <div class="gallery">
-
-                    </div>
-                    <div class="info">
-                        <h1>商品详情</h1>
-                    </div>
-                </div>
-                <div class="rule">
-
-                </div>
-                <div class="property" style="line-height:normal">
-                    {{ details }}
-                </div>
-            </template>
-        </app-view>
-        <component :is="componentMap.get(componentId)" v-bind="{ details }" @closed="closeComponent"
-            v-if="componentId" />
-    </teleport>
-</template>
-
-<script lang="ts" setup>
-import { computed, PropType, defineAsyncComponent } from 'vue'
-import { sessionData } from '@/stores'
-import { useComponent } from '@/hooks/component'
-import { useDiamondDetails } from '@/business/goods'
-
-const componentMap = new Map<string, unknown>([
-    ['buy', defineAsyncComponent(() => import('./buy.vue'))], // 立即购买
-    ['inquiry', defineAsyncComponent(() => import('./inquiry.vue'))] // 询价申请
-])
-
-const props = defineProps({
-    teleport: {
-        type: String as PropType<'#appPageTeleport' | '#appMainTeleport'>,
-        default: '#appMainTeleport'
-    },
-    goodsno: {
-        type: String,
-        required: true
-    },
-})
-
-const { details, getDiamondDetails } = useDiamondDetails(props.goodsno)
-const { componentId, openComponent, closeComponent } = useComponent()
-
-// 不能购买自己上架的商品
-const showButton = computed(() => {
-    if (details.value) {
-        return details.value.userid !== sessionData.getLoginInfo('UserID')
-    }
-    return false
-})
-
-getDiamondDetails()
-</script>

+ 46 - 5
src/packages/pc/views/listing/buy/components/delisting/index.vue

@@ -1,13 +1,30 @@
 <template>
-    <div>摘牌</div>
+    <h3>我的摘牌</h3>
     <app-table :data="dataList" :columns="columns" :show-header="false" selection-type="single" border
         @select="onTableSelect" />
+    <el-form ref="formRef" label-width="80px" :model="formData" :rules="formRules" v-if="dataList.length"
+        style="width:460px">
+        <el-form-item label="价格(¥)" prop="ApplyPrice">
+            <div class="el-form-item--col">
+                <el-input type="number" placeholder="请输入" v-model.number="formData.ApplyPrice" />
+                <span style="white-space:nowrap;">汇率:6.7500</span>
+            </div>
+        </el-form-item>
+        <el-form-item label="备注" prop="ApplyRemark">
+            <el-input type="textarea" :rows="3" v-model="formData.ApplyRemark" />
+        </el-form-item>
+        <el-form-item>
+            <el-button type="primary" :loading="loading" @click="onSubmit">摘牌申请</el-button>
+        </el-form-item>
+    </el-form>
 </template>
 
 <script lang="ts" setup>
-import { PropType } from 'vue'
+import { ref, PropType } from 'vue'
 import Long from 'long'
-import { useSellOrderDesting } from '@/business/order/desting'
+import { ElMessage } from 'element-plus'
+import type { FormInstance, FormRules } from 'element-plus'
+import { useSellOrderInquiry } from '@/business/order/desting'
 import AppTable from '@pc/components/base/table/index.vue'
 
 const props = defineProps({
@@ -17,7 +34,12 @@ const props = defineProps({
     }
 })
 
-const { loading, dataList, columns, formData } = useSellOrderDesting(props.selectedRow)
+const { loading, dataList, columns, formData, formSubmit, getDiamondList } = useSellOrderInquiry(props.selectedRow)
+const formRef = ref<FormInstance>()
+
+const formRules: FormRules = {
+    ApplyPrice: [{ required: true, message: '请输入价格', trigger: 'blur' }],
+}
 
 // 勾选表格行
 const onTableSelect = (rows: Ermcp.MyWRPositionRsp[]) => {
@@ -25,10 +47,29 @@ const onTableSelect = (rows: Ermcp.MyWRPositionRsp[]) => {
     if (row) {
         formData.WRStandardID = row.wrstandardid
         formData.LadingBillID = Long.fromString(row.ladingbillid)
-        formData.ApplyQty = row.ftotalqty - row.ffreezeqty
+        formData.ApplyQty = row.weight
         formData.SubNum = row.subnum
     } else {
         formData.WRStandardID = 0
     }
 }
+
+const onSubmit = () => {
+    formRef.value?.validate((valid) => {
+        if (valid) {
+            if (formData.WRStandardID) {
+                formSubmit().then(() => {
+                    ElMessage.success('提交成功')
+                    getDiamondList()
+                }).catch((err) => {
+                    ElMessage.error('提交失败:' + err)
+                })
+            } else {
+                ElMessage.warning('请选择商品')
+            }
+        }
+    })
+}
+
+getDiamondList()
 </script>

+ 8 - 2
src/packages/pc/views/listing/buy/components/details/index.vue

@@ -21,15 +21,16 @@
                 <el-descriptions-item label="荧光">{{ selectedRow.zsfluorescencetypedisplay }}</el-descriptions-item>
             </el-descriptions>
             <template v-for="(auth, index) in getAuthComponent()" :key="index">
-                <component :is="componentMap.get(auth.code)" v-bind="{ selectedRow }" />
+                <component :is="componentMap.get(auth.code)" v-bind="{ selectedRow }" v-if="showComponent" />
             </template>
         </app-view>
     </teleport>
 </template>
 
 <script lang="ts" setup>
-import { PropType } from 'vue'
+import { computed, PropType } from 'vue'
 import { useAuth } from '@/hooks/auth'
+import { sessionData } from '@/stores'
 
 const props = defineProps({
     code: String,
@@ -40,4 +41,9 @@ const props = defineProps({
 })
 
 const { componentMap, getAuthComponent } = useAuth(props.code)
+
+// 不能购买自己发布的求购
+const showComponent = computed(() => {
+    return props.selectedRow.userid !== sessionData.getLoginInfo('UserID')
+})
 </script>

+ 0 - 4
src/packages/pc/views/listing/buy/index.vue

@@ -6,9 +6,6 @@
         </template>
         <!-- 表格数据 -->
         <app-table :data="dataList" v-model:columns="columns" :loading="loading">
-            <template #header>
-                <app-auth-operation :menus="headerButtons" @closed="getBuyOrderList" />
-            </template>
             <!-- 操作 -->
             <template #operate="{ row }">
                 <app-auth-operation :menus="handleOperateButtons(row)" :options="{ selectedRow: row }"
@@ -32,7 +29,6 @@ import AppPagination from '@pc/components/base/pagination/index.vue'
 import AppFilter from '@pc/components/base/table-filter/index.vue'
 
 const { loading, dataList, columns, total, pageIndex, pageSize, selectList, inputList, buttonList, getBuyOrderList } = useBuyOrder()
-const headerButtons = ['add']
 const operateButtons = ['details', 'delisting']
 
 const handleOperateButtons = (row: Ermcp.SellOrderRsp) => {

+ 42 - 0
src/packages/pc/views/listing/inquire/components/cancel/index.vue

@@ -0,0 +1,42 @@
+<!-- 挂牌大厅-我的询价-撤销 -->
+<template>
+    <app-drawer title="提示" v-model:show="show" :loading="loading" :refresh="refresh">
+        <div style="font-size:16px;text-align:center">是否撤销该询价?</div>
+        <template #footer>
+            <el-button @click="onCancel(false)" plain>取消</el-button>
+            <el-button type="primary" @click="onSubmit">确认</el-button>
+        </template>
+    </app-drawer>
+</template>
+
+<script lang="ts" setup>
+import { shallowRef, PropType } from 'vue'
+import { ElMessage } from 'element-plus'
+import { useInquiryOperate } from '@/business/order/desting'
+import AppDrawer from '@pc/components/base/drawer/index.vue'
+
+const props = defineProps({
+    selectedRow: {
+        type: Object as PropType<Ermcp.MyBargainApplyRsp | Ermcp.MyDelistingApplyRsp>,
+        default: () => ({})
+    }
+})
+
+const { loading, formSubmit } = useInquiryOperate(props.selectedRow)
+const show = shallowRef(true)
+const refresh = shallowRef(false)
+
+const onCancel = (isRefresh = false) => {
+    show.value = false
+    refresh.value = isRefresh
+}
+
+const onSubmit = () => {
+    formSubmit().then(() => {
+        ElMessage.success('提交成功')
+        onCancel(true)
+    }).catch((err) => {
+        ElMessage.error('提交失败:' + err)
+    })
+}
+</script>

+ 14 - 1
src/packages/pc/views/listing/inquire/index.vue

@@ -13,9 +13,13 @@
         </template>
         <!-- 表格数据 -->
         <app-table :data="dataList" v-model:columns="columns" :loading="loading">
+            <!-- 申请状态 -->
+            <template #applystatus="{ value }">
+                {{ getApplyStatusName(value) }}
+            </template>
             <!-- 操作 -->
             <template #operate="{ row }">
-                <app-auth-operation :menus="['details']" :options="{ selectedRow: row }"
+                <app-auth-operation :menus="handleTableButtons(row)" :options="{ selectedRow: row }"
                     @closed="getInquireOrderList" />
             </template>
             <template #footer>
@@ -29,11 +33,20 @@
 <script lang="ts" setup>
 import { ElMessage } from 'element-plus'
 import { useInquireOrder } from '@/business/order/list'
+import { getApplyStatusName, ApplyStatus } from '@/constants/order'
 import AppTable from '@pc/components/base/table/index.vue'
 import AppPagination from '@pc/components/base/pagination/index.vue'
 import AppAuthOperation from '@pc/components/modules/auth-operation/index.vue'
 
 const { loading, dataList, total, pageIndex, pageSize, columns, buyOrSell, status, selectedBuyOrSell, selectedStatus, getInquireOrderList } = useInquireOrder()
 
+// “待确认”状态 有撤销按钮
+const handleTableButtons = (row: Ermcp.MyBargainApplyRsp | Ermcp.MyDelistingApplyRsp) => {
+    if (row.applystatus === ApplyStatus.Pending) {
+        return ['details', 'cancel']
+    }
+    return ['details']
+}
+
 getInquireOrderList().catch((err) => ElMessage.error(err))
 </script>

+ 1 - 1
src/packages/pc/views/listing/buy/components/add/index.vue → src/packages/pc/views/listing/purchase/components/add/index.vue

@@ -1,4 +1,4 @@
-<!-- 求购大厅-我要求购 -->
+<!-- 挂牌大厅-我的求购-我要求购 -->
 <template>
     <app-drawer title="我要求购" :width="960" v-model:show="show" :loading="loading" :refresh="refresh">
         <el-form ref="formRef" class="el-form--horizontal" label-width="100px" :model="formData" :rules="formRules">

+ 43 - 0
src/packages/pc/views/listing/purchase/components/cancel/index.vue

@@ -0,0 +1,43 @@
+<!-- 挂牌大厅-我的求购-撤销 -->
+<template>
+    <app-drawer title="提示" v-model:show="show" :loading="loading" :refresh="refresh">
+        <div style="font-size:16px;text-align:center">是否撤销该求购?</div>
+        <template #footer>
+            <el-button @click="onCancel(false)" plain>取消</el-button>
+            <el-button type="primary" @click="onSubmit">确认</el-button>
+        </template>
+    </app-drawer>
+</template>
+
+<script lang="ts" setup>
+import { shallowRef, PropType } from 'vue'
+import { ElMessage } from 'element-plus'
+import { BuyOrSell } from '@/constants/order'
+import { useListingCancel } from '@/business/order/listing'
+import AppDrawer from '@pc/components/base/drawer/index.vue'
+
+const props = defineProps({
+    selectedRow: {
+        type: Object as PropType<Ermcp.MyBuyOrderRsp>,
+        default: () => ({})
+    }
+})
+
+const { loading, formSubmit } = useListingCancel(props.selectedRow.wrtradeorderid, BuyOrSell.Buy)
+const show = shallowRef(true)
+const refresh = shallowRef(false)
+
+const onCancel = (isRefresh = false) => {
+    show.value = false
+    refresh.value = isRefresh
+}
+
+const onSubmit = () => {
+    formSubmit().then(() => {
+        ElMessage.success('提交成功')
+        onCancel(true)
+    }).catch((err) => {
+        ElMessage.error('提交失败:' + err)
+    })
+}
+</script>

+ 12 - 1
src/packages/pc/views/listing/purchase/index.vue

@@ -6,9 +6,12 @@
         </template>
         <!-- 表格数据 -->
         <app-table :data="dataList" v-model:columns="columns" :loading="loading">
+            <template #header>
+                <app-auth-operation :menus="['add']" @closed="getPurchaseOrderList" />
+            </template>
             <!-- 操作 -->
             <template #operate="{ row }">
-                <app-auth-operation :menus="['details']" :options="{ selectedRow: row }"
+                <app-auth-operation :menus="handleTableButtons(row)" :options="{ selectedRow: row }"
                     @closed="getPurchaseOrderList" />
             </template>
             <template #footer>
@@ -29,5 +32,13 @@ import AppFilter from '@pc/components/base/table-filter/index.vue'
 
 const { loading, dataList, total, pageIndex, pageSize, columns, selectList, inputList, buttonList, getPurchaseOrderList } = usePurchaseOrder()
 
+// 3:委托成功 7:部成 -  状态有撤销
+const handleTableButtons = (row: Ermcp.MyBuyOrderRsp) => {
+    if ([3, 7].includes(row.wrtradeorderstatus)) {
+        return ['details', 'cancel']
+    }
+    return ['details']
+}
+
 getPurchaseOrderList().catch((err) => ElMessage.error(err))
 </script>

+ 7 - 5
src/packages/pc/views/listing/sell/components/add/index.vue → src/packages/pc/views/listing/sale/components/add/index.vue

@@ -1,4 +1,4 @@
-<!-- 出售大厅-我要出售 -->
+<!-- 挂牌大厅-我的出售-我要出售 -->
 <template>
     <app-drawer title="我要出售" :width="960" v-model:show="show" :loading="submitLoading" :refresh="refresh">
         <el-form ref="formRef" class="el-form--horizontal" label-width="100px" :model="formData" :rules="formRules">
@@ -16,19 +16,19 @@
             selection-type="single" border @select="onTableSelect">
             <!-- 剩余数量 -->
             <template #remainqty="{ row }">
-                {{  row.ftotalqty - row.ffreezeqty  }}
+                {{ row.ftotalqty - row.ffreezeqty }}
             </template>
             <!-- 颜色 -->
             <template #zscolortype="{ row }">
-                {{  [row.zscolortype1display, row.zscolortype2display].join('-')  }}
+                {{ [row.zscolortype1display, row.zscolortype2display].join('-') }}
             </template>
             <!-- 净度 -->
             <template #zsclaritytype="{ row }">
-                {{  [row.zsclaritytype1display, row.zsclaritytype2display].join('-')  }}
+                {{ [row.zsclaritytype1display, row.zsclaritytype2display].join('-') }}
             </template>
             <!-- 彩钻颜色 -->
             <template #zsczcolortype="{ row }">
-                {{  [row.zsczcolor1typedisplay, row.zsczcolor2typedisplay, row.zsczcolor3typedisplay].join('-')  }}
+                {{ [row.zsczcolor1typedisplay, row.zsczcolor2typedisplay, row.zsczcolor3typedisplay].join('-') }}
             </template>
         </app-table>
         <template #footer>
@@ -104,4 +104,6 @@ const onSubmit = () => {
         }
     })
 }
+
+categoryChange()
 </script>

+ 43 - 0
src/packages/pc/views/listing/sale/components/cancel/index.vue

@@ -0,0 +1,43 @@
+<!-- 挂牌大厅-我的出售-撤销 -->
+<template>
+    <app-drawer title="提示" v-model:show="show" :loading="loading" :refresh="refresh">
+        <div style="font-size:16px;text-align:center">是否撤销该出售?</div>
+        <template #footer>
+            <el-button @click="onCancel(false)" plain>取消</el-button>
+            <el-button type="primary" @click="onSubmit">确认</el-button>
+        </template>
+    </app-drawer>
+</template>
+
+<script lang="ts" setup>
+import { shallowRef, PropType } from 'vue'
+import { ElMessage } from 'element-plus'
+import { BuyOrSell } from '@/constants/order'
+import { useListingCancel } from '@/business/order/listing'
+import AppDrawer from '@pc/components/base/drawer/index.vue'
+
+const props = defineProps({
+    selectedRow: {
+        type: Object as PropType<Ermcp.MySellOrderRsp>,
+        default: () => ({})
+    }
+})
+
+const { loading, formSubmit } = useListingCancel(props.selectedRow.wrtradeorderid, BuyOrSell.Sell)
+const show = shallowRef(true)
+const refresh = shallowRef(false)
+
+const onCancel = (isRefresh = false) => {
+    show.value = false
+    refresh.value = isRefresh
+}
+
+const onSubmit = () => {
+    formSubmit().then(() => {
+        ElMessage.success('提交成功')
+        onCancel(true)
+    }).catch((err) => {
+        ElMessage.error('提交失败:' + err)
+    })
+}
+</script>

+ 13 - 1
src/packages/pc/views/listing/sale/index.vue

@@ -6,9 +6,13 @@
         </template>
         <!-- 表格数据 -->
         <app-table :data="dataList" v-model:columns="columns" :loading="loading">
+            <template #header>
+                <app-auth-operation :menus="['add']" @closed="getSaleOrderList" />
+            </template>
             <!-- 操作 -->
             <template #operate="{ row }">
-                <app-auth-operation :menus="['details']" :options="{ selectedRow: row }" @closed="getSaleOrderList" />
+                <app-auth-operation :menus="handleTableButtons(row)" :options="{ selectedRow: row }"
+                    @closed="getSaleOrderList" />
             </template>
             <template #footer>
                 <app-pagination :total="total" v-model:page-size="pageSize" v-model:page-index="pageIndex"
@@ -28,5 +32,13 @@ import AppFilter from '@pc/components/base/table-filter/index.vue'
 
 const { loading, dataList, total, pageIndex, pageSize, columns, selectList, inputList, buttonList, getSaleOrderList } = useSaleOrder()
 
+// 3:委托成功 7:部成 -  状态有撤销
+const handleTableButtons = (row: Ermcp.MySellOrderRsp) => {
+    if ([3, 7].includes(row.wrtradeorderstatus)) {
+        return ['details', 'cancel']
+    }
+    return ['details']
+}
+
 getSaleOrderList().catch((err) => ElMessage.error(err))
 </script>

+ 0 - 32
src/packages/pc/views/listing/sell/components/details/index.vue

@@ -1,32 +0,0 @@
-<!-- 出售大厅-我要出售-详情 -->
-<template>
-    <app-details :goodsno="selectedRow.goodsno">
-        <el-button type="primary" @click="onSubmit" :loading="loading" v-if="showButton">立即购买</el-button>
-    </app-details>
-</template>
-
-<script lang="ts" setup>
-import { PropType, computed } from 'vue'
-import { ElMessage } from 'element-plus'
-import { sessionData } from '@/stores'
-import { useBuyOrderDesting } from '@/business/order/desting'
-import AppDetails from '@pc/components/modules/goods-details/index.vue'
-
-const props = defineProps({
-    selectedRow: {
-        type: Object as PropType<Ermcp.SellOrderRsp>,
-        default: () => ({})
-    }
-})
-
-const { loading, formSubmit } = useBuyOrderDesting(props.selectedRow)
-const showButton = computed(() => props.selectedRow.userid !== sessionData.getLoginInfo('UserID'))
-
-const onSubmit = () => {
-    formSubmit().then(() => {
-        ElMessage.success('提交成功')
-    }).catch((err) => {
-        ElMessage.error('提交失败:' + err)
-    })
-}
-</script>

+ 1 - 4
src/packages/pc/views/listing/sell/index.vue

@@ -6,12 +6,9 @@
         </template>
         <!-- 表格数据 -->
         <app-table :data="dataList" v-model:columns="columns" :loading="loading">
-            <template #header>
-                <app-auth-operation :menus="['add']" @closed="getSellOrderList" />
-            </template>
             <!-- 操作 -->
             <template #operate="{ row }">
-                <app-auth-operation :menus="['details', 'favorite']" :options="{ goodsno: row.goodsno }"
+                <app-auth-operation :menus="['details', 'favorite']" :options="{ selectedRow: row }"
                     @closed="getSellOrderList" />
             </template>
             <template #footer>

+ 2 - 2
src/packages/pc/components/modules/goods-details/buy.vue → src/packages/pc/views/warehousing/goods/components/buy/index.vue

@@ -16,13 +16,13 @@ import { useBuyOrderDesting } from '@/business/order/desting'
 import AppDrawer from '@pc/components/base/drawer/index.vue'
 
 const props = defineProps({
-    details: {
+    selectedRow: {
         type: Object as PropType<Ermcp.SellOrderRsp>,
         default: () => ({})
     }
 })
 
-const { loading, formSubmit } = useBuyOrderDesting(props.details)
+const { loading, formSubmit } = useBuyOrderDesting(props.selectedRow)
 const show = shallowRef(true)
 
 const onCancel = () => {

+ 0 - 1
src/packages/pc/views/warehousing/goods/components/details/index.less

@@ -1 +0,0 @@
-.warehousing-stock-details {}

+ 67 - 5
src/packages/pc/views/warehousing/goods/components/details/index.vue

@@ -1,10 +1,72 @@
+<!-- 商品详情 -->
 <template>
-    <div class="warehousing-stock-details">详情</div>
+    <teleport :to="teleport">
+        <app-view class="app-details" v-bind="$attrs">
+            <template #header>
+                <div>
+                    <el-button @click="$emit('closed')">返回</el-button>
+                    <template v-if="showButton && selectedRow.wrtradeorderid">
+                        <el-button type="primary" @click="openComponent('favorite')">收藏</el-button>
+                        <el-button type="primary" @click="openComponent('buy')">立即购买</el-button>
+                        <el-button type="primary" @click="openComponent('inquiry')">询价申请</el-button>
+                    </template>
+                </div>
+            </template>
+            <template v-if="details">
+                <div class="app-details__intro">
+                    <div class="gallery">
+
+                    </div>
+                    <div class="info">
+                        <h1>商品详情</h1>
+                    </div>
+                </div>
+                <div class="rule">
+
+                </div>
+                <div class="property" style="line-height:normal">
+                    {{ details }}
+                </div>
+            </template>
+        </app-view>
+        <component :is="componentMap.get(componentId)" v-bind="{ selectedRow }" @closed="closeComponent"
+            v-if="componentId" />
+    </teleport>
 </template>
 
 <script lang="ts" setup>
-</script>
+import { computed, PropType, defineAsyncComponent } from 'vue'
+import { sessionData } from '@/stores'
+import { useComponent } from '@/hooks/component'
+import { useDiamondDetails } from '@/business/goods'
+
+const componentMap = new Map<string, unknown>([
+    ['favorite', defineAsyncComponent(() => import('../favorite/index.vue'))], // 收藏
+    ['buy', defineAsyncComponent(() => import('../buy/index.vue'))], // 立即购买
+    ['inquiry', defineAsyncComponent(() => import('../inquiry/index.vue'))] // 询价申请
+])
+
+const props = defineProps({
+    teleport: {
+        type: String as PropType<'#appPageTeleport' | '#appMainTeleport'>,
+        default: '#appMainTeleport'
+    },
+    selectedRow: {
+        type: Object as PropType<Ermcp.SellOrderRsp & Ermcp.MyWRPositionRsp>,
+        default: () => ({})
+    },
+})
+
+const { details, getDiamondDetails } = useDiamondDetails(props.selectedRow.goodsno)
+const { componentId, openComponent, closeComponent } = useComponent()
+
+// 不能购买自己上架的商品
+const showButton = computed(() => {
+    if (details.value) {
+        return details.value.userid !== sessionData.getLoginInfo('UserID')
+    }
+    return false
+})
 
-<style lang="less" scoped>
-@import './index.less';
-</style>
+getDiamondDetails()
+</script>

+ 1 - 1
src/packages/pc/views/warehousing/goods/components/edit/diamond.vue

@@ -4,7 +4,7 @@
         <el-form-item label="商品编号" prop="GoodsNo">
             <el-input placeholder="请输入" v-model="formData.GoodsNo" />
         </el-form-item>
-        <el-form-item label="履约方式" prop="PerformanceTemplateID" v-if="code === 'warehousing_stock_sell'">
+        <el-form-item label="履约方式" prop="PerformanceTemplateID" v-if="code === 'warehousing_goods_sell'">
             <component :is="components.performance" v-model="performanceId" />
         </el-form-item>
         <el-form-item label="货币类型" prop="ZSCurrencyType">

+ 1 - 1
src/packages/pc/views/warehousing/goods/components/edit/diamonds.vue

@@ -4,7 +4,7 @@
         <el-form-item label="商品编号" prop="GoodsNo">
             <el-input placeholder="请输入" v-model="formData.GoodsNo" />
         </el-form-item>
-        <el-form-item label="履约方式" prop="PerformanceTemplateID" v-if="code === 'warehousing_stock_sell'">
+        <el-form-item label="履约方式" prop="PerformanceTemplateID" v-if="code === 'warehousing_goods_sell'">
             <component :is="components.performance" v-model="performanceId" />
         </el-form-item>
         <el-form-item label="货币类型" prop="ZSCurrencyType">

+ 1 - 1
src/packages/pc/views/warehousing/goods/components/edit/fancy.vue

@@ -4,7 +4,7 @@
         <el-form-item label="商品编号" prop="GoodsNo">
             <el-input placeholder="请输入" v-model="formData.GoodsNo" />
         </el-form-item>
-        <el-form-item label="履约方式" prop="PerformanceTemplateID" v-if="code === 'warehousing_stock_sell'">
+        <el-form-item label="履约方式" prop="PerformanceTemplateID" v-if="code === 'warehousing_goods_sell'">
             <component :is="components.performance" v-model="performanceId" />
         </el-form-item>
         <el-form-item label="货币类型" prop="ZSCurrencyType">

+ 1 - 1
src/packages/pc/views/warehousing/goods/components/edit/jewelry.vue

@@ -4,7 +4,7 @@
         <el-form-item label="商品编号" prop="GoodsNo">
             <el-input placeholder="请输入" v-model="formData.GoodsNo" />
         </el-form-item>
-        <el-form-item label="履约方式" prop="PerformanceTemplateID" v-if="code === 'warehousing_stock_sell'">
+        <el-form-item label="履约方式" prop="PerformanceTemplateID" v-if="code === 'warehousing_goods_sell'">
             <component :is="components.performance" v-model="performanceId" />
         </el-form-item>
         <el-form-item label="货币类型" prop="ZSCurrencyType">

+ 1 - 1
src/packages/pc/views/warehousing/goods/components/edit/rough.vue

@@ -4,7 +4,7 @@
         <el-form-item label="商品编号" prop="GoodsNo">
             <el-input placeholder="请输入" v-model="formData.GoodsNo" />
         </el-form-item>
-        <el-form-item label="履约方式" prop="PerformanceTemplateID" v-if="code === 'warehousing_stock_sell'">
+        <el-form-item label="履约方式" prop="PerformanceTemplateID" v-if="code === 'warehousing_goods_sell'">
             <component :is="components.performance" v-model="performanceId" />
         </el-form-item>
         <el-form-item label="货币类型" prop="ZSCurrencyType">

+ 6 - 6
src/packages/pc/views/warehousing/goods/components/favorite/index.vue

@@ -9,19 +9,19 @@
 </template>
 
 <script lang="ts" setup>
-import { shallowRef } from 'vue'
+import { shallowRef, PropType } from 'vue'
 import { ElMessage } from 'element-plus'
-import { useDiamondDetails } from '@/business/goods'
+import { useDiamondFavorite } from '@/business/goods'
 import AppDrawer from '@pc/components/base/drawer/index.vue'
 
 const props = defineProps({
-    goodsno: {
-        type: String,
-        required: true
+    selectedRow: {
+        type: Object as PropType<Ermcp.SellOrderRsp>,
+        default: () => ({})
     },
 })
 
-const { loading, diamondFavorite } = useDiamondDetails(props.goodsno)
+const { loading, diamondFavorite } = useDiamondFavorite(props.selectedRow)
 const show = shallowRef(true)
 const refresh = shallowRef(false)
 

+ 20 - 14
src/packages/pc/components/modules/goods-details/inquiry.vue → src/packages/pc/views/warehousing/goods/components/inquiry/index.vue

@@ -1,15 +1,15 @@
 <!-- 商品详情-询价申请 -->
 <template>
     <app-drawer title="询价" :width="600" v-model:show="show" :loading="loading">
-        <el-form ref="formRef" label-width="60px" :rules="formRules">
-            <el-form-item label="价格" prop="warehousecode">
+        <el-form ref="formRef" label-width="60px" :model="formData" :rules="formRules">
+            <el-form-item label="价格" prop="ApplyPrice">
                 <div class="el-form-item--col">
-                    <el-input placeholder="请输入" />
+                    <el-input type="number" placeholder="请输入" v-model.number="formData.ApplyPrice" />
                     <span style="white-space:nowrap;">汇率:6.7500</span>
                 </div>
             </el-form-item>
-            <el-form-item label="备注" prop="Remark">
-                <el-input type="textarea" :rows="3" />
+            <el-form-item label="备注" prop="ApplyRemark">
+                <el-input type="textarea" :rows="3" v-model="formData.ApplyRemark" />
             </el-form-item>
         </el-form>
         <template #footer>
@@ -23,32 +23,38 @@
 import { ref, PropType } from 'vue'
 import { ElMessage } from 'element-plus'
 import type { FormInstance, FormRules } from 'element-plus'
-import { useBuyOrderDesting } from '@/business/order/desting'
+import { useBuyOrderInquiry } from '@/business/order/desting'
 import AppDrawer from '@pc/components/base/drawer/index.vue'
 
 const props = defineProps({
-    details: {
+    selectedRow: {
         type: Object as PropType<Ermcp.SellOrderRsp>,
         default: () => ({})
     }
 })
 
-const { loading, formSubmit } = useBuyOrderDesting(props.details)
+const { loading, formData, formSubmit } = useBuyOrderInquiry(props.selectedRow)
 const formRef = ref<FormInstance>()
 const show = ref(true)
 
-const formRules: FormRules = {}
+const formRules: FormRules = {
+    ApplyPrice: [{ required: true, message: '请输入价格', trigger: 'blur' }],
+}
 
 const onCancel = () => {
     show.value = false
 }
 
 const onSubmit = () => {
-    formSubmit().then(() => {
-        ElMessage.success('提交成功')
-        onCancel()
-    }).catch((err) => {
-        ElMessage.error('提交失败:' + err)
+    formRef.value?.validate((valid) => {
+        if (valid) {
+            formSubmit().then(() => {
+                ElMessage.success('提交成功')
+                onCancel()
+            }).catch((err) => {
+                ElMessage.error('提交失败:' + err)
+            })
+        }
     })
 }
 </script>

+ 60 - 0
src/packages/pc/views/warehousing/goods/components/put/index.vue

@@ -0,0 +1,60 @@
+<!-- 我的仓储-我的库存-上架 -->
+<template>
+    <app-drawer title="上架挂牌" :width="480" v-model:show="show" :loading="submitLoading" :refresh="refresh">
+        <el-form ref="formRef" label-width="100px" :model="formData" :rules="formRules">
+            <el-form-item label="商品编号">
+                {{selectedRow.goodsno}}
+            </el-form-item>
+            <el-form-item label="履约方式" prop="PerformanceTemplateID">
+                <app-performance v-model="formData.PerformanceTemplateID" />
+            </el-form-item>
+        </el-form>
+        <template #footer>
+            <el-button @click="onCancel(false)" plain>取消</el-button>
+            <el-button type="primary" @click="onSubmit">提交</el-button>
+        </template>
+    </app-drawer>
+</template>
+
+<script lang="ts" setup>
+import { ref, PropType } from 'vue'
+import { ElMessage } from 'element-plus'
+import type { FormInstance, FormRules } from 'element-plus'
+import { useSellOrderListing } from '@/business/order/listing'
+import AppDrawer from '@pc/components/base/drawer/index.vue'
+import AppPerformance from '@pc/components/modules/performance/index.vue'
+
+const props = defineProps({
+    selectedRow: {
+        type: Object as PropType<Ermcp.MyWRPositionRsp>,
+        default: () => ({})
+    }
+})
+
+const { submitLoading, formData, formSubmit } = useSellOrderListing(props.selectedRow)
+const show = ref(true)
+const refresh = ref(false)
+const formRef = ref<FormInstance>()
+
+const formRules: FormRules = {
+    PerformanceTemplateID: [{ required: true, message: '请选择履约方式' }],
+}
+
+const onCancel = (isRefresh = false) => {
+    show.value = false
+    refresh.value = isRefresh
+}
+
+const onSubmit = () => {
+    formRef.value?.validate((valid) => {
+        if (valid) {
+            formSubmit().then(() => {
+                ElMessage.success('提交成功')
+                onCancel(true)
+            }).catch((err) => {
+                ElMessage.error('提交失败:' + err)
+            })
+        }
+    })
+}
+</script>

+ 13 - 2
src/packages/pc/views/warehousing/goods/index.vue

@@ -7,7 +7,7 @@
         <!-- 表格数据 -->
         <app-table :data="dataList" v-model:columns="columns" :loading="loading">
             <template #header>
-                <app-auth-operation :menus="['add', 'sell']" @closed="getDiamondList" />
+                <app-auth-operation :menus="headerButtons" @closed="getDiamondList" />
             </template>
             <!-- 颜色 -->
             <template #zscolortype="{ row }">
@@ -19,7 +19,8 @@
             </template>
             <!-- 操作 -->
             <template #operate="{ row }">
-                <app-auth-operation :menus="['details']" :options="{ selectedRow: row }" @closed="getDiamondList" />
+                <app-auth-operation :menus="handleTableButtons(row)" :options="{ selectedRow: row }"
+                    @closed="getDiamondList" />
             </template>
             <template #footer>
                 <app-pagination :total="total" v-model:page-size="pageSize" v-model:page-index="pageIndex"
@@ -38,6 +39,16 @@ import AppAuthOperation from '@pc/components/modules/auth-operation/index.vue'
 import AppFilter from '@pc/components/base/table-filter/index.vue'
 
 const { loading, dataList, total, pageIndex, pageSize, columns, selectList, inputList, buttonList, getDiamondList } = useDiamond()
+const headerButtons = ['add', 'sell']
+const tableButtons = ['details', 'put', 'pull', 'delete']
+
+// 冻结数量 > 0则为已上架
+const handleTableButtons = (row: Ermcp.MyWRPositionRsp) => {
+    if (row.ffreezeqty > 0) {
+        return tableButtons.filter((code) => code !== 'put')
+    }
+    return tableButtons.filter((code) => code !== 'pull')
+}
 
 getDiamondList().catch((err) => ElMessage.error(err))
 </script>

+ 7 - 0
src/services/api/common/index.ts

@@ -48,4 +48,11 @@ export function updateNewFuncmenu(params: HttpRequest<{ req: Partial<Ermcp.NewFu
  */
 export function deleteNewFuncmenu(params: HttpRequest<{ req: Partial<Ermcp.NewFuncmenuRsp> }>) {
     return httpRequest('/Common/DeleteNewFuncmenu', 'delete', params);
+}
+
+/**
+ * 查询汇率信息
+ */
+export function queryRates(params: HttpRequest<{ req: Ermcp.RatesReq, rsp: Ermcp.RatesRsp }>) {
+    return httpRequest('/Common/QueryRates', 'get', params);
 }

+ 1 - 1
src/services/api/goods/index.ts

@@ -36,5 +36,5 @@ export function addZSGoods(params: TradeRequest<Proto.AddZSGoodsReq, Proto.AddZS
  * 商品收藏操作
  */
 export function goodsFavoriteOperate(params: TradeRequest<Proto.GoodsFavoriteOperateReq, Proto.GoodsFavoriteOperateRsp>) {
-    return tradeServerRequest('GoodsFavoriteOperateReq', 'GoodsFavoriteOperateRsp', params);
+    return tradeServerRequest('GoodsFavoriteOperateReq', 'GoodsFavoriteOperateRsp', params, Market.GZ);
 }

+ 14 - 7
src/services/api/order/index.ts

@@ -33,27 +33,34 @@ export function zsBuyOrderDestingNegPrice(params: TradeRequest<Proto.ZSBuyOrderD
 }
 
 /**
- * 钻石买摘牌询价操作
+ * 钻石卖摘牌申请
  */
-export function zsBuyOrderDestingNegPriceOperate(params: TradeRequest<Proto.ZSBuyOrderDestingNegPriceOperateReq, Proto.ZSBuyOrderDestingNegPriceOperateRsp>) {
-    return tradeServerRequest('ZSBuyOrderDestingNegPriceOperateReq', 'ZSBuyOrderDestingNegPriceOperateRsp', params, Market.GZ);
+export function zsSellOrderDestingApply(params: TradeRequest<Proto.ZSSellOrderDestingApplyReq, Proto.ZSSellOrderDestingApplyRsp>) {
+    return tradeServerRequest('ZSSellOrderDestingApplyReq', 'ZSSellOrderDestingApplyRsp', params, Market.GZ);
 }
 
 /**
- * 钻石卖摘牌申请
+ * 钻石买询价操作
  */
-export function zsSellOrderDestingApply(params: TradeRequest<Proto.ZSSellOrderDestingApplyReq, Proto.ZSSellOrderDestingApplyRsp>) {
-    return tradeServerRequest('ZSSellOrderDestingApplyReq', 'ZSSellOrderDestingApplyRsp', params, Market.GZ);
+export function zsBuyOrderDestingNegPriceOperate(params: TradeRequest<Proto.ZSBuyOrderDestingNegPriceOperateReq, Proto.ZSBuyOrderDestingNegPriceOperateRsp>) {
+    return tradeServerRequest('ZSBuyOrderDestingNegPriceOperateReq', 'ZSBuyOrderDestingNegPriceOperateRsp', params, Market.GZ);
 }
 
 /**
- * 钻石卖摘牌申请操作
+ * 钻石卖询价操作
  */
 export function zsSellOrderDestingApplyOperate(params: TradeRequest<Proto.ZSSellOrderDestingApplyOperateReq, Proto.ZSSellOrderDestingApplyOperateRsp>) {
     return tradeServerRequest('ZSSellOrderDestingApplyOperateReq', 'ZSSellOrderDestingApplyOperateRsp', params, Market.GZ);
 }
 
 /**
+ * 钻石挂牌撤单
+ */
+export function wrListingCancelOrder(params: TradeRequest<Proto.WRListingCancelOrderReq, Proto.WRListingCancelOrderRsp>) {
+    return tradeServerRequest('WRListingCancelOrderReq', 'WRListingCancelOrderRsp', params, Market.GZ);
+}
+
+/**
  * 查询求购大厅委托单
  */
 export function queryBuyOrder(params: HttpRequest<{ req: Ermcp.BuyOrderReq, rsp: Ermcp.BuyOrderRsp[] }>) {

+ 18 - 0
src/types/ermcp/common.d.ts

@@ -0,0 +1,18 @@
+/** 企业风管 */
+declare namespace Ermcp {
+    /** 查询汇率信息 请求 */
+    interface RatesReq {
+        page?: number; // 页码
+        pagesize?: number; // 每页条数
+        oricurrencyid: number; // 源币种ID
+        descurrencyid: number; // 目标币种ID
+    }
+
+    /** 查询汇率信息 响应 */
+    interface RatesRsp {
+        descurrencyid: number; // 目标币种ID
+        exchangerate: number; // 汇率
+        oricurrencyid: number; // 源币种ID
+        remark: string; // 备注
+    }
+}

+ 128 - 7
src/types/ermcp/order.d.ts

@@ -45,10 +45,12 @@ declare namespace Ermcp {
         canbargain: number; // 是否可议价 - 0:不可 1:可
         cancelqty: number; // 撤销数量
         canceltime: string; // 撤销时间
+        cerno: string;
         chargealgorithm: number; // 手续费收取方式 1:比率 2:固定
         chargealgorithmvalue: number; // 手续费设置值(交易所部分)
         chargealgorithmvalue2: number; // 手续费设置值(会员部分)
         clientordertime: string; // 客户端委托时间
+        cpcertno: string;
         exchangerate: number; // 汇率[67]
         firstratio: number; // 首付比率 - [挂牌时指定,摘牌时使用]
         fixedprice: number; // [克拉单价]固定价格 - [挂牌]
@@ -56,24 +58,34 @@ declare namespace Ermcp {
         freezefirstamount: number; // 冻结首付金额 - [摘牌]
         freezemargin: number; // 冻结保证金
         goodsno: string; // 商品编号
+        imagepath: string;
         isQueryDiamond: boolean; // 是否钻石查询
         isspecified: number; // 是否指定对手 - 0:不指定 1:指定好友(贸易圈) 2:指定对手 - [挂牌]
+        kppath: string;
+        kpweight: string;
         marginalgorithm: number; // 保证金方式 - 1:比率 2:固定
         marginvalue: number; // 保证金设置值
         marketid: number; // 市场ID
+        marketprice: string;
         orderamount: number; // 挂牌金额[账户] [67]= OrderQty * FixedPrice * ExchangeRate /100
         ordertime: string; // 委托时间
         performancetemplateid: number; // 履约计划模板ID
         pricefactor: number; // 价格系数(浮动价时填写) - [挂牌]
         pricemove: number; // 升贴水(浮动价时填写) - [挂牌]
+        priceper: string;
         relatedwrtradeorderid: number; // 关联委托单号(摘牌委托关联挂牌委托单ID)
         remainqty: number; // 剩余重量
+        remark: string;
         retcode: number; // 错误代码
         sellusername: string; // 卖方(查询字段-模糊查询)
+        settingmaterial: string;
+        size1: string;
+        size2: string;
+        size3: string;
+        stonedesc: string;
         totalqty: number; // 总重量
         tradedate: string; // 交易日(yyyyMMdd)
         tradeprice: number; // 成交价格 - [摘牌] (浮动价 ((商品1价格商品1价格系数+升贴水) 商品1重量系数 + 商品2价格商品2价格系数+商品2升贴水) 商品2重量系数 …)* 委托单价格系数 + 委托单升贴水)
-        tradeqty: number; // 成交数量
         unfreezecharge: number; // 解冻手续费
         unfreezefirstamount: number; // 解冻首付金额 - [摘牌]
         unfreezemargin: number; // 解冻保证金
@@ -81,8 +93,10 @@ declare namespace Ermcp {
         uuid: string; // 发起端唯一id
         validtime: string; // 有效期限
         validtype: number; // 有效类型 - 1当日有效 2本周有效 3指定日期有效 4一直有效
+        warehousenamedisplay: string;
         wrbargainid: number; // 议价申请单ID
         wrfactortypeid: number; // 仓单要素类型ID/商品ID(77)
+        wrpath: string;
         wrpricetype: number; // 价格方式 - 1:固定价 2-浮动价 - [挂牌]
         wrstandardid: number; // 现货商品ID
         wrtradeorderid: string; // 仓单贸易委托单ID(320+Unix秒时间戳(10位)+xxxxxx)
@@ -90,7 +104,30 @@ declare namespace Ermcp {
         wrtradetype: number; // 仓单贸易类型 - 1:挂牌 2:摘牌 3:提货卖(文化中国) 4:提货买(文化中国)
         wrtransferuserid: number; // 仓单受让用户 - [摘牌]
         zscategory: number; // 钻石分类 - 枚举”ZSCategory“
+        zscategorydisplay: string; // 钻石分类 - 描述
+        zscerttypedisplay: string;
+        zsclaritytype1display: string;
+        zsclaritytype2display: string;
+        zscolortype1display: string;
+        zscolortype2display: string;
+        zscrystaltype: string;
+        zscrystaltypedisplay: string;
         zscurrencytype: number; // 货币类型 - 枚举“ZSCurrencyType”
+        zscurrencytypedisplay: string;
+        zscurrencytypedisplayunit: string;
+        zscuttype1display: string;
+        zscuttype2display: string;
+        zsczcolor1typedisplay: string;
+        zsczcolor2typedisplay: string;
+        zsczcolor3typedisplay: string;
+        zsfluorescencetype1display: string;
+        zsfluorescencetype2display: string;
+        zspolishtype1display: string;
+        zspolishtype2display: string;
+        zsshapetypedisplay: string;
+        zsstyletypedisplay: string;
+        zssymmetrytype1display: string;
+        zssymmetrytype2display: string;
     }
 
     /** 查询求购大厅委托单请求 */
@@ -170,10 +207,12 @@ declare namespace Ermcp {
         canbargain: number; // 是否可议价 - 0:不可 1:可
         cancelqty: number; // 撤销数量
         canceltime: string; // 撤销时间
+        cerno: string;
         chargealgorithm: number; // 手续费收取方式 1:比率 2:固定
         chargealgorithmvalue: number; // 手续费设置值(交易所部分)
         chargealgorithmvalue2: number; // 手续费设置值(会员部分)
         clientordertime: string; // 客户端委托时间
+        cpcertno: string;
         exchangerate: number; // 汇率[67]
         firstratio: number; // 首付比率 - [挂牌时指定,摘牌时使用]
         fixedprice: number; // [克拉单价]固定价格 - [挂牌]
@@ -181,22 +220,33 @@ declare namespace Ermcp {
         freezefirstamount: number; // 冻结首付金额 - [摘牌]
         freezemargin: number; // 冻结保证金
         goodsno: string; // 商品编号
+        imagepath: string;
         isspecified: number; // 是否指定对手 - 0:不指定 1:指定好友(贸易圈) 2:指定对手 - [挂牌]
+        kppath: string;
+        kpweight: string;
         marginalgorithm: number; // 保证金方式 - 1:比率 2:固定
         marginvalue: number; // 保证金设置值
         marketid: number; // 市场ID
+        marketprice: string;
         orderamount: number; // 挂牌金额[账户] [67]= OrderQty * FixedPrice * ExchangeRate /100
         ordertime: string; // 委托时间
         performancetemplateid: number; // 履约计划模板ID
+        price: number; // 价格
         pricefactor: number; // 价格系数(浮动价时填写) - [挂牌]
         pricemove: number; // 升贴水(浮动价时填写) - [挂牌]
+        priceper: string;
         relatedwrtradeorderid: number; // 关联委托单号(摘牌委托关联挂牌委托单ID)
+        remark: string;
         retcode: number; // 错误代码
         selledqty: number; // 成交重量
+        settingmaterial: string;
+        size1: string;
+        size2: string;
+        size3: string;
+        stonedesc: string;
         totalqty: number; // 总重量
         tradedate: string; // 交易日(yyyyMMdd)
         tradeprice: number; // 成交价格 - [摘牌] (浮动价 ((商品1价格商品1价格系数+升贴水) 商品1重量系数 + 商品2价格商品2价格系数+商品2升贴水) 商品2重量系数 …)* 委托单价格系数 + 委托单升贴水)
-        tradeqty: number; // 成交数量
         unfreezecharge: number; // 解冻手续费
         unfreezefirstamount: number; // 解冻首付金额 - [摘牌]
         unfreezemargin: number; // 解冻保证金
@@ -204,8 +254,10 @@ declare namespace Ermcp {
         uuid: string; // 发起端唯一id
         validtime: string; // 有效期限
         validtype: number; // 有效类型 - 1当日有效 2本周有效 3指定日期有效 4一直有效
+        warehousenamedisplay: string;
         wrbargainid: number; // 议价申请单ID
         wrfactortypeid: number; // 仓单要素类型ID/商品ID(77)
+        wrpath: string;
         wrpricetype: number; // 价格方式 - 1:固定价 2-浮动价 - [挂牌]
         wrstandardid: number; // 现货商品ID
         wrtradeorderid: string; // 仓单贸易委托单ID(320+Unix秒时间戳(10位)+xxxxxx)
@@ -213,7 +265,30 @@ declare namespace Ermcp {
         wrtradetype: number; // 仓单贸易类型 - 1:挂牌 2:摘牌 3:提货卖(文化中国) 4:提货买(文化中国)
         wrtransferuserid: number; // 仓单受让用户 - [摘牌]
         zscategory: number; // 钻石分类 - 枚举”ZSCategory“
+        zscategorydisplay: string; // 钻石分类 - 描述
+        zscerttypedisplay: string;
+        zsclaritytype1display: string;
+        zsclaritytype2display: string;
+        zscolortype1display: string;
+        zscolortype2display: string;
+        zscrystaltype: string;
+        zscrystaltypedisplay: string;
         zscurrencytype: number; // 货币类型 - 枚举“ZSCurrencyType”
+        zscurrencytypedisplay: string;
+        zscurrencytypedisplayunit: string;
+        zscuttype1display: string;
+        zscuttype2display: string;
+        zsczcolor1typedisplay: string;
+        zsczcolor2typedisplay: string;
+        zsczcolor3typedisplay: string;
+        zsfluorescencetype1display: string;
+        zsfluorescencetype2display: string;
+        zspolishtype1display: string;
+        zspolishtype2display: string;
+        zsshapetypedisplay: string;
+        zsstyletypedisplay: string;
+        zssymmetrytype1display: string;
+        zssymmetrytype2display: string;
     }
 
     /** 查询我的求购请求 */
@@ -278,9 +353,10 @@ declare namespace Ermcp {
         page?: number; // 页码
         pagesize?: number; // 每页条数
         zsallproperties?: string; // 商品(查询字段-模糊查询)
-        zscategorys?: string; // 钻石分类, 格式:1,2,3
-        wrtradedetailid?: number; // 成交单号
-        buyorsell?: number; // 方向,0-全部(可不传) 1-购买 2-出售
+        zscategorys?: string; // 钻石分类枚举ID
+        wrtradeorderid?: string; // 委托单号
+        buyorsell?: number; // 方向,0-购买 1-出售
+        matchusername?: string; // 对手方(模糊匹配)
         begindate?: string; // 开始交易日(yyyymmdd)
         enddate?: string; // 结束交易日(yyyymmdd)
     }
@@ -363,15 +439,39 @@ declare namespace Ermcp {
         marketid: number; // 市场ID
         matchaccountid: number; // 挂牌方资金账号
         matchuserid: number; // 挂牌方用户ID
+        price: number; // 价格
         qty: number; // 申请数量
         refprice: string; // 参考价格
         retcode: number; // 委托返回代码
         sellusername: string; // 卖方
+        sizedisplay: string; // 尺寸
         subnum: number; // 摘牌方提单子单号 [卖]
         tradedate: string; // 交易日(yyyyMMdd)
         userid: number; // 摘牌人用户ID
-        wrbargainid: number; // [询价单号]议价申请单ID(327+Unix秒时间戳(10位)+xxxxxx)
+        warehousenamedisplay: string;
+        wrbargainid: string; // [询价单号]议价申请单ID(327+Unix秒时间戳(10位)+xxxxxx)
         wrtradeorderid: number; // 关联委托单ID
+        zscerttypedisplay: string;
+        zsclaritytype1display: string;
+        zsclaritytype2display: string;
+        zscolortype1display: string;
+        zscolortype2display: string;
+        zscrystaltypedisplay: string;
+        zscurrencytypedisplay: string;
+        zscurrencytypedisplayunit: string;
+        zscuttype1display: string;
+        zscuttype2display: string;
+        zsczcolor1typedisplay: string;
+        zsczcolor2typedisplay: string;
+        zsczcolor3typedisplay: string;
+        zsfluorescencetype1display: string;
+        zsfluorescencetype2display: string;
+        zspolishtype1display: string;
+        zspolishtype2display: string;
+        zsshapetypedisplay: string;
+        zsstyletypedisplay: string;
+        zssymmetrytype1display: string;
+        zssymmetrytype2display: string;
     }
 
     /** 查询我的询价-出售 请求 */
@@ -392,16 +492,37 @@ declare namespace Ermcp {
         auditremark: string; // 确认备注
         audittime: string; // 确认时间
         buyuserid: number; // 买方用户ID
-        buyusername: string; // 买方
+        buyusername: string;
         buywrtradeorderid: number; // 买委托单ID
+        goodsno: string; // – view_GZ_WRStandard_Ex_Query –
         ladingbillid: number; // 卖方提单ID
         marketid: number; // 市场ID
+        price: number; // 价格
         sellaccountid: number; // 卖方账户ID
         selldelistingapplyid: number; // [询价单号]卖摘牌申请ID(916+Unix秒时间戳(10位)+xxxxxx)
         selltradeorderid: number; // 卖方委托ID(买方确认成交后更新)
         selluserid: number; // 卖方用户ID
         subnum: number; // 卖方提单子单号
+        warehouseinfosdisplay: string;
+        weight: number; // 克拉重量
         wrfactortypeid: number; // 仓单要素类型ID
         wrstandardid: number; // 现货商品ID
+        zsallproperties: string; // – VIEW_GZ_BUYORDERDETAIL_QUERY
+        zscategorydisplay: string;
+        zsclaritytypedisplay: string;
+        zscolortypedisplay: string;
+        zscrystaltypedisplay: string;
+        zscurrencytypedisplay: string;
+        zscuttypedisplay: string;
+        zsczcolor1typedisplay: string;
+        zsczcolor2typedisplay: string;
+        zsczcolor3typedisplay: string;
+        zsfluorescencetypedisplay: string;
+        zspolishtypedisplay: string;
+        zsshapetypedisplay: string;
+        zssizedisplay: string;
+        zsstyletypedisplay: string;
+        zssymmetrytypedisplay: string;
+        zstabledisplay: string;
     }
 }

+ 2 - 1
src/types/proto/goods.d.ts

@@ -1,4 +1,5 @@
 import { IMessageHead } from '@/services/socket/trade/protobuf/proto'
+import Long from 'long'
 
 declare global {
     namespace Proto {
@@ -78,7 +79,7 @@ declare global {
         interface GoodsFavoriteOperateReq {
             Header?: IMessageHead; // 消息头
             UserID: number; // 用户ID,必填
-            WRTradeOrderID: number; // 委托单ID,必填
+            WRTradeOrderID: Long; // 委托单ID,必填
             OperateType: number; // 操作类型,1:添加2:删除,必填
             ClientType: number; // 终端类型
             MarketID: number; // 市场ID,必填

+ 42 - 12
src/types/proto/order.d.ts

@@ -120,15 +120,16 @@ declare global {
             Header?: IMessageHead; // 消息头
             UserID: number; // 用户ID,必填
             AccountID: number; // 资金账号,必填
-            RelatedOrderID: number; // 卖委托单号,必填
+            RelatedOrderID: Long; // 卖委托单号,必填
             OrderQty: number; // 议价数量,2位小数,必填
-            ApplyPrice: string; // 协议价格,2位小数,必填
+            ApplyPrice?: number; // 协议价格,2位小数,必填
             OrderSrc: number; // 委托来源
-            ClientSerialNo: string; // 客户端流水号
-            ClientOrderTime: string; // 客户端委托时间
+            ClientSerialNo?: string; // 客户端流水号
+            ClientOrderTime?: string; // 客户端委托时间
             ClientType: number; // 终端类型
             OperatorID: number; // 操作员账号ID
             MarketID: number; // 市场ID,必填
+            ApplyRemark: string; // 申请备注
         }
 
         /** 买摘牌询价接口应答 */
@@ -144,13 +145,13 @@ declare global {
             ClientSerialNo: string; // 客户端流水号
         }
 
-        /** 买摘牌询价操作接口请求 */
+        /** 钻石买询价操作接口请求 */
         interface ZSBuyOrderDestingNegPriceOperateReq {
             Header?: IMessageHead; // 消息头
             UserID: number; // 用户ID,必填
             AccountID: number; // 资金账号,必填
-            WRBargainID: number; // 议价申请单ID,必填
-            AuditRemark: string; // 备注
+            WRBargainID: Long; // 议价申请单ID,必填
+            AuditRemark?: string; // 备注
             OperateType: number; // 操作类型,1:撤销2:拒绝
             MarketID: number; // 市场ID,必填
             ClientType: number; // 终端类型
@@ -158,7 +159,7 @@ declare global {
             ClientSerialNo: string; // 客户端流水号
         }
 
-        /** 买摘牌询价操作接口应答 */
+        /** 钻石买询价操作接口应答 */
         interface ZSBuyOrderDestingNegPriceOperateRsp {
             Header?: IMessageHead; // 消息头
             RetCode: number; // 返回码
@@ -178,7 +179,7 @@ declare global {
             WRStandardID: number; // 现货商品ID,必填
             WRFactorTypeID?: number; // 仓单要素类型ID,必填
             ApplyQty: number; // 申请数量,必填,2位小数
-            ApplyPrice: number; // 申请价格,必填,2位小数
+            ApplyPrice?: number; // 申请价格,必填,2位小数
             LadingBillID: Long; // 提单ID,必填
             SubNum: number; // 提单子单号,必填
             ApplyRemark?: string; // 备注
@@ -198,13 +199,13 @@ declare global {
             ClientSerialNo: string; // 客户端流水号
         }
 
-        /** 钻石卖摘牌申请操作接口请求 */
+        /** 钻石卖询价操作接口请求 */
         interface ZSSellOrderDestingApplyOperateReq {
             Header?: IMessageHead; // 消息头
             UserID: number; // 用户ID,必填
             AccountID: number; // 资金账号
             SellDelistingApplyID: number; // 卖摘牌申请ID,必填
-            AuditRemark: string; // 备注
+            AuditRemark?: string; // 备注
             OperateType: number; // 操作类型,1:撤销2:拒绝
             MarketID: number; // 市场ID,必填
             ClientType: number; // 终端类型
@@ -212,7 +213,7 @@ declare global {
             ClientSerialNo: string; // 客户端流水号
         }
 
-        /** 钻石卖摘牌申请操作接口应答 */
+        /** 钻石卖询价操作接口应答 */
         interface ZSSellOrderDestingApplyOperateRsp {
             Header?: IMessageHead; // 消息头
             RetCode: number; // 返回码
@@ -225,5 +226,34 @@ declare global {
             OrderTime: string; // 接收委托交易的时间
             ClientSerialNo: string; // 客户端流水号
         }
+
+        /** 钻石挂牌撤单请求 */
+        interface WRListingCancelOrderReq {
+            Header?: IMessageHead; // 消息头
+            UserID: number; // 用户ID
+            AccountID: number; // 资金账号
+            OldWRTradeOrderID: Long; // 目标仓单贸易委托单ID
+            OrderSrc: number; // 委托来源
+            ClientSerialNo: string; // 客户端流水号
+            ClientOrderTime: string; // 客户端委托时间
+            ClientType: number; // 终端类型
+            OperatorID: number; // 操作员账号ID
+            BuyOrSell: number; // 买卖方向
+            WRID?: number; // 仓单ID,卖的时候填写
+        }
+
+        /** 钻石挂牌撤单应答 */
+        interface WRListingCancelOrderRsp {
+            Header?: IMessageHead; // 消息头
+            RetCode: number; // 返回码
+            RetDesc: string; // 描述信息
+            WRTradeCancelID: number; // 仓单贸易撤单号
+            OldWRTradeOrderID: number; // 目标仓单贸易委托单ID
+            UserID: number; // 用户ID
+            AccountID: number; // 资金账号
+            CancelQty: number; // 撤单数量
+            OrderTime: string; // 接受撤单的时间
+            ClientSerialNo: string; // 客户端流水号
+        }
     }
 }