ソースを参照

commit 新接口加入

yu jie 4 年 前
コミット
1cf8a93d1b

+ 66 - 0
public/proto/mtp.proto

@@ -1579,3 +1579,69 @@ message DGFactoryItems {
 }
 
 
+// 仓单出库申请 0 29 113
+message WROutApplyReq {
+ optional MessageHead Header = 1; // MessageHead
+ optional uint64 ClientSerialID = 2; // uint64 客户端唯一ID
+ optional uint64 WRStandardID = 3; // uint64 仓单标准ID
+ optional uint64 WarehouseID = 4; // uint64 仓库ID
+ optional uint64 UserID = 5; // uint64 申请人ID
+ optional uint64 AccountID = 6; // uint64 申请人账户ID
+ optional string Mobile = 7; // string 申请人手机号
+ optional string AppointmentDate = 8; // string 预约出库时间(格式:20200101)
+ optional uint32 AppointmentModel = 9; // uint32 预约方式:1-物流,2-自送,3-自提
+  optional uint64 CountryID = 10; // uint64 国家
+  optional uint64 ProvinceID = 11; // uint64 省
+  optional uint64 DistrictID = 12; // uint64 区
+  optional uint64 CityID = 13; // uint64 市
+  optional string Address = 14; // string 详细地址
+  optional string ContactName = 15; // string 收货人提货人
+  optional string ContactNum = 16; // string 收货人提货人手机
+  optional string AppointmentRemark = 17; // string 预约备注
+ optional uint64 CreatorID = 18; // uint64 创建人ID
+ repeated WROutInDetail WROutInDetails = 19; // WROutInDetail 仓单出库提单明细数据
+}
+// 仓单出库申请响应 0 29 114
+message WROutApplyRsp {
+ optional MessageHead Header = 1; // MessageHead 消息头
+ optional int32 RetCode = 2; // int32 返回码
+ optional string RetDesc = 3; // string 描述信息
+ optional uint64 ClientSerialID = 4; // uint64 客户端唯一ID
+}
+
+// 仓单出库提单明细数据 0 29 112
+message WROutInDetail {
+  optional string LadingBillID = 1; // string 提单ID
+  optional uint64 SubNum = 2; // uint64 提单子单号
+  optional uint64 Qty = 3; // uint64 子提单总数量
+  optional uint64 OutQty = 4; // uint64 预约数量
+}
+
+// 挂牌撤单请求 0 22 4
+message WRListingCancelOrderReq {
+ optional MessageHead Header = 1; // MessageHead
+ optional uint32 UserID = 2; // uint32 用户ID
+ optional uint64 AccountID = 3; // uint64 资金账号
+ optional uint64 OldWRTradeOrderID = 4; // uint64 目标仓单贸易委托单ID
+ optional uint32 OrderSrc = 5; // uint32 委托来源
+ optional string ClientSerialNo = 6; // string 客户端流水号
+ optional string ClientOrderTime = 7; // string 客户端委托时间
+ optional uint32 ClientType = 8; // uint32 终端类型
+ optional uint64 OperatorID = 9; // uint64 操作员账号ID
+ optional uint32 BuyOrSell = 10; // uint32 买卖方向
+ optional uint64 WRID = 11; // uint64 仓单ID,卖的时候填写
+}
+// 挂牌撤单应答 0 22 5
+message WRListingCancelOrderRsp {
+ optional MessageHead Header = 1; // MessageHead 消息头
+ optional int32 RetCode = 2; // int32 返回码
+ optional string RetDesc = 3; // string 描述信息
+ optional uint64 WRTradeCancelID = 4; // uint64 仓单贸易撤单号
+ optional uint64 OldWRTradeOrderID = 5; // uint64 目标仓单贸易委托单ID
+ optional uint32 UserID = 6; // uint32 用户ID
+ optional uint64 AccountID = 7; // uint64 资金账号
+ optional uint64 CancelQty = 8; // uint64 撤单数量
+ optional string OrderTime = 9; // string 接受撤单的时间
+ optional string ClientSerialNo = 10; // string 客户端流水号
+}
+

+ 8 - 0
src/services/funcode/index.ts

@@ -158,9 +158,17 @@ export const funCode: Code = {
     QHJAgreementConfigOperateReq: 1900733,  /// 协议操作请求
     QHJAgreementConfigOperateRsp: 1900734,  /// 协议操作响应
 
+    // 仓单贸易
+
     HdWROrderReq: 1441807,  ///  持仓单挂牌请求
     HdWROrderRsp: 1441808,  ///  持仓单挂牌应答
 
     HdWRDealOrderReq: 1441809, ///  持仓单摘牌请求
     HdWRDealOrderRsp: 1441810, ///  持仓单摘牌应答
+
+    WROutApplyReq: 1900657, //// 仓单出库申请
+    WROutApplyRsp: 1900658,  /// 仓单出库申请响应
+
+    WRListingCancelOrderReq: 1441796, // 挂牌撤单请求
+    WRListingCancelOrderRsp: 1441797, // 挂牌撤单应答
 };

+ 14 - 1
src/services/go/TaAccount/index.ts

@@ -1,9 +1,11 @@
 import APP from '@/services';
 import { getLongTypeLoginID } from "@/services/bus/login";
 import { commonSearch_go } from "..";
+import {ErmcpBizGroupEx} from "@/services/go/ermcp/account/interface";
+import {QueryAmountLogReq, QueryAmountLogRsp} from "@/services/go/TaAccount/interface";
 
 /**
- * 
+ *  获取资金账户信息
  */
 export function getTaAccount() {
     const loginID = getLongTypeLoginID()?.toNumber()
@@ -11,4 +13,15 @@ export function getTaAccount() {
         APP.set('accountList', res);
         return 'ok'
     }).catch(err => { throw new Error(`获取资金账户信息失败:${err}`) })
+}
+
+/**
+ * /TaAccount/QueryAmountLog
+ * 资金流水查询(当前)
+ * @param req
+ */
+export function queryAmountLog(req: QueryAmountLogReq) : Promise<QueryAmountLogRsp> {
+    return commonSearch_go('/TaAccount/QueryAmountLog', { req }).catch((err) => {
+        throw new Error(`资金流水查询(当前): ${err}`);
+    });
 }

+ 111 - 0
src/services/go/TaAccount/interface.ts

@@ -0,0 +1,111 @@
+export interface QueryAmountLogReq {
+    page?: number               // 页码
+    pagesize?: number           // 每页条数
+    accountID: string           // 资金账户 - 格式:1,2,3
+    OperateType?: number        // 资金操作类型 - 格式:1,2,3
+}
+
+export interface QueryAmountLogRsp{
+    OPERATETYPENAME	:string;//资金操作类型名称
+    accountid	:number;//资金账户ID
+    agoodscode	:string;//竞拍商品代码
+    agoodsname	:string;//竞拍商品名称
+    amount	:number;//资金金额
+    amountadjusttype	:number;//资金调整类型(默认值为number;
+//) - number;
+//:系统 1:单边账调整 2:人工调整
+    autoid	:number;//流水ID(22number;
+//+Unix秒时间戳(1number;
+//位)+xxxxxx)
+    balance	:number;//期初余额
+    businesscode	:number;//业务编号
+    createtime	:string;//发生时间
+    currencyid	:number;//币种ID
+    currentbalance	:number;//期末余额(变动后金额)
+    dgoodscode	:string;//交割商品代码
+    dgoodsname	:string;//交割商品名称
+    goodscode	:string;//商品代码
+    goodsid	:number;//商品ID
+    goodsname	:string;//商品名称
+    marketid	:number;//市场ID
+    marketname	:string;//市场名称
+    moneyticket	:number;//资金流水号:银行端流水号
+    operatetype	:number;//资金操作类型 (AccountFundCmdOp)- 1number;
+//1:入金 1number;
+//2:入金手续费 1number;
+//3:出金 1number;
+//4:出金冻结 1number;
+//5:出金解冻 1number;
+//6:出金手续费 1number;
+//7:出金手续费冻结 1number;
+//8:出金手续费解冻 2number;
+//1:交易冻结 2number;
+//2:交易解冻 2number;
+//3:交易占用 2number;
+//4:交易解占用 2number;
+//5:交易手续费冻结 2number;
+//6:交易手续费解冻 2number;
+//7:交易手续费 2number;
+//8:交易货款 2number;
+//9:交易盈亏 3number;
+//1:交割冻结 3number;
+//2:交割解冻 3number;
+//3:交割手续费 3number;
+//4:交割手续费冻结 3number;
+//5:交割手续费解冻 3number;
+//6:交割货款 3number;
+//7:交割税款 4number;
+//1:结算盈亏 4number;
+//2:结算递延费 4number;
+//3:分润收入 4number;
+//4:延期分润 5number;
+//1:授信增加 5number;
+//2:授信减少 5number;
+//3:转积分 5number;
+//4:转入 5number;
+//5:转出 5number;
+//6:转出冻结 5number;
+//7:转出解冻 6number;
+//1:履约金额冻结 6number;
+//2:履约最大冻结 6number;
+//3:履约金额解冻 6number;
+//4:履约扣款 6number;
+//5:履约收款 6number;
+//6:履约违约手续费 6number;
+//7:履约违约收入 6number;
+//8:履约最大扣款 7number;
+//1:供应链金融冻结 7number;
+//2:供应链金融解冻 7number;
+//3:供应链金融最大冻结 7number;
+//4:供应链金融利息 7number;
+//5:供应链金融货款 7number;
+//6:供应链金融押金 7number;
+//7:供应链金融最大扣款 8number;
+//1:仓单贸易冻结 8number;
+//2:仓单贸易解冻 8number;
+//3:仓单贸易首付款 8number;
+//4:仓单贸易最大扣款 9number;
+//1:商城扣款冻结 9number;
+//2:商城扣款解冻 9number;
+//3:商城扣款 9number;
+//4:商城收款 1number;
+//number;
+//1:期权冻结 1number;
+//number;
+//2:期权解冻 1number;
+//number;
+//3:期权权力金 1number;
+//number;
+//4:期权手续费冻结 1number;
+//number;
+//5:期权手续费解冻 1number;
+//number;
+//6:期权手续费 1number;
+//number;
+//7:期权盈亏 11number;
+//1:营销扣款 11number;
+//2:营销收款
+    relationorderid	:string;//关联单号
+    remark	:string;//备注
+    trademode	:number;//交易模式
+}

+ 25 - 2
src/services/proto/warehousetrade/index.ts

@@ -1,4 +1,9 @@
-import { HdWRDealOrderReq, HdWROrderReq } from "@/services/proto/warehousetrade/interface";
+import {
+    HdWRDealOrderReq,
+    HdWROrderReq,
+    WRListingCancelOrderReq,
+    WROutApplyReq
+} from "@/services/proto/warehousetrade/interface";
 import { protoMiddleware } from "@/services/socket/protobuf/buildReq";
 
 
@@ -17,4 +22,22 @@ export const hdWROrder = (param: HdWROrderReq): Promise<any> => {
  */
 export const HdWRDealOrder = (param: HdWRDealOrderReq): Promise<any> => {
     return protoMiddleware<HdWRDealOrderReq>(param, 'HdWRDealOrderReq', 'HdWRDealOrderRsp', 2)
-}
+}
+
+/**
+ * 出入库请求
+ * @param param
+ */
+export const wROutApply = (param: WROutApplyReq): Promise<any> =>{
+    return protoMiddleware<WROutApplyReq>(param, 'WROutApplyReq', 'WROutApplyRsp', 2)
+}
+
+/**
+ * 挂牌撤单请求
+ * @param param
+ */
+export const wRListingCancelOrder = (param: WRListingCancelOrderReq): Promise<any> =>{
+    return protoMiddleware<WRListingCancelOrderReq>(param, 'WRListingCancelOrderReq', 'WRListingCancelOrderRsp', 2)
+}
+
+

+ 66 - 0
src/services/proto/warehousetrade/interface.ts

@@ -98,3 +98,69 @@ export interface DGFactoryItems {
 }
 
 
+// 仓单出库申请 0 29 113
+export interface WROutApplyReq {
+    ClientSerialID: number; // uint64 客户端唯一ID
+    WRStandardID: number; // uint64 仓单标准ID
+    WarehouseID: number; // uint64 仓库ID
+    UserID: number; // uint64 申请人ID
+    AccountID: string; // uint64 申请人账户ID
+    Mobile: string; // string 申请人手机号
+    AppointmentDate: string; // string 预约出库时间(格式:20200101)
+    AppointmentModel: number; // uint32 预约方式:1-物流,2-自送,3-自提
+    CountryID: number; // uint64 国家
+    ProvinceID: number; // uint64 省
+    DistrictID: number; // uint64 区
+    CityID: number; // uint64 市
+    Address: string; // string 详细地址
+    ContactName: string; // string 收货人提货人
+    ContactNum: string; // string 收货人提货人手机
+    AppointmentRemark: string; // string 预约备注
+    CreatorID: number; // uint64 创建人ID
+    WROutInDetails: WROutInDetail; // WROutInDetail 仓单出库提单明细数据
+}
+// 仓单出库申请响应 0 29 114
+export interface WROutApplyRsp {
+    RetCode: number; // int32 返回码
+    RetDesc: string; // string 描述信息
+    ClientSerialID: number; // uint64 客户端唯一ID
+}
+
+// 仓单出库提单明细数据 0 29 112
+export interface WROutInDetail {
+    LadingBillID: string; // string 提单ID
+    SubNum: number; // uint64 提单子单号
+    Qty: number; // uint64 子提单总数量
+    OutQty: number; // uint64 预约数量
+}
+
+
+// 挂牌撤单请求 0 22 4
+export interface WRListingCancelOrderReq {
+    UserID: number; // uint32 用户ID
+    AccountID: number; // uint64 资金账号
+    OldWRTradeOrderID: number; // uint64 目标仓单贸易委托单ID
+    OrderSrc: number; // uint32 委托来源
+    ClientSerialNo: string; // string 客户端流水号
+    ClientOrderTime: string; // string 客户端委托时间
+    ClientType: number; // uint32 终端类型
+    OperatorID: number; // uint64 操作员账号ID
+    BuyOrSell: number; // uint32 买卖方向
+    WRI: number; // uint64 仓单ID,卖的时候填写
+}
+
+// 挂牌撤单应答 0 22 5
+export interface WRListingCancelOrderRsp {
+    RetCode: number; // int32 返回码
+    RetDesc: string; // string 描述信息
+    WRTradeCancelID: number; // uint64 仓单贸易撤单号
+    OldWRTradeOrderID : number; // uint64 目标仓单贸易委托单ID
+    UserID: number; // uint32 用户ID
+    AccountID: number; // uint64 资金账号
+    CancelQty: number; // uint64 撤单数量
+    OrderTime: string; // string 接受撤单的时间
+    ClientSerialNo: string; // string 客户端流水号
+}
+
+
+