huangbin преди 4 години
родител
ревизия
68d05e6b38

+ 1 - 1
src/services/bus/index.ts

@@ -34,7 +34,7 @@ export async function globalDataRefresh(): Promise<string> {
             } else {
                 // token校验成功 马上轮询
                 checkTokenLoop();
-                Promise.all([GetErmcpGoods(), GetPCMenus(), QueryTableDefine(), LoginQuery()])
+                await Promise.all([GetErmcpGoods(), GetPCMenus(), QueryTableDefine(), LoginQuery()])
             }
         } else {
             // 重置数据中心数据

+ 1 - 1
src/services/bus/login.ts

@@ -25,7 +25,7 @@ export const login = async (logidCode: string, password: String, byteArr: Uint8A
 
         // localstorage 缓存登录信息,处理页面刷新
         setLoginData(loginData);
-        Promise.all([GetErmcpGoods(), GetPCMenus(), QueryTableDefine(), getServerTime(), LoginQuery()])
+        await Promise.all([GetErmcpGoods(), GetPCMenus(), QueryTableDefine(), getServerTime(), LoginQuery()])
         // await GetPCMenus();
         // await QueryTableDefine();
         // 获取服务时间

+ 3 - 1
src/views/information/spot-contract/components/add/index.vue

@@ -434,6 +434,7 @@ import { initData } from '@/common/methods';
 import { handleFromState, handleContract, handlevalidate, handleDeliveryGoods, handlePrice, handleDate } from './setup';
 import { getUserName } from '@/services/bus/user';
 import { getGoodsList } from '@/services/bus/goods';
+import { Goods } from '@/services/go/ermcp/goodsInfo/interface';
 
 export default defineComponent({
     name: 'add-spot-contract',
@@ -472,7 +473,7 @@ export default defineComponent({
         // 日期
         const { deliveryDate, disabledDate } = handleDate();
         // 现货商品列表
-        const goodsList = getGoodsList();
+        const goodsList = ref<Goods[]>([]);
         function submit() {
             loading.value = true;
             setTimeout(() => {
@@ -483,6 +484,7 @@ export default defineComponent({
         initData(() => {
             queryCustomList();
             getDeliveryGoods();
+            goodsList.value = getGoodsList();
         });
         return {
             visible,

+ 1 - 1
src/views/information/spot-contract/components/add/interface.ts

@@ -20,7 +20,7 @@ export interface FormState {
     DeliveryStartDate: string// string 交收期(开始)
     DeliveryEndDate: string // string 交收期(结束)
     GoodsID: number // uint64 点价合约ID-0:为现货,其它为期货商品合约ID[2:点价3:暂定价]
-    // PriceMove: number// double 升贴水[2:点价3:暂定价]
+    PriceMove: number// double 升贴水[2:点价3:暂定价]
     // StartDate: string // string 点价开始日期[2:点价3:暂定价]
     // EndDate: string // string 点价结束日期[2:点价3:暂定价]
     // PointDesc: string // string 点价备注[2:点价3:暂定价]

+ 1 - 0
src/views/information/spot-contract/components/add/setup.ts

@@ -36,6 +36,7 @@ export function handleFromState() {
         Remark: '', // string 合同备注
         CurrencyID: undefined, // 结算币种ID
         GoodsID: undefined, // uint64 点价合约ID-0:为现货,其它为期货商品合约ID[2:点价3:暂定价]
+        PriceMove: null// double 升贴水[2:点价3:暂定价]
     })
     // 业务类型
     const businessType = [