li.shaoyi 2 lat temu
rodzic
commit
649ade1664

+ 4 - 2
app/main.js

@@ -80,8 +80,10 @@ const createWindow = () => {
     const win = new BrowserWindow({
         show: false,
         center: true,
-        minWidth: 1024,
-        minHeight: 768,
+        width: 1280,
+        height: 800,
+        minWidth: 480,
+        minHeight: 300,
         icon: path.resolve(__dirname, 'dist/favicon.ico')
     })
 

+ 1 - 1
app/package.json

@@ -1,5 +1,5 @@
 {
-  "name": "trading",
+  "name": "trading-beta",
   "version": "1.0.14",
   "main": "main.js",
   "dependencies": {

+ 1 - 1
file/android/fxgl.txt

@@ -32,7 +32,7 @@ http://8.130.132.95:8280/cfg?key=mtp_20
 cn.muchinfo.qxst_release_v1.0.0.apk
 http://8.130.72.213:8280/cfg?key=mtp_20
 实盘链路2
-http://8.130.28.27:8280/cfg?key=mtp_20
+http://8.130.28.27:8280/cfg?key=gzys_sp2
 
 
 中融文遗通

+ 1 - 1
oem/gstj/config/appconfig.json

@@ -4,7 +4,7 @@
   "version": "1.0.14",
   "versionCode": "100014",
   "apiUrl": "http://192.168.31.204:8080/cfg?key=test_204",
-  "tradeChannel": "ws",
+  "tradeChannel": "http",
   "modules": [
     "register",
     "delivery"

+ 5 - 5
src/packages/mobile/views/goods/detail/components/listing/Index.vue

@@ -44,8 +44,7 @@
                 <div class="g-form__footer">
                     <template v-if="buyOrSell === BuyOrSell.Buy">
                         <Button type="danger" block square :disabled="!formData.OrderQty"
-                            @click="onBeforeSubmit(EBuildType.BUILDTYPE_OPEN)"
-                            v-if="!quote?.iscannotbuy">订立买入</Button>
+                            @click="onBeforeSubmit(EBuildType.BUILDTYPE_OPEN)" v-if="!quote?.iscannotbuy">订立买入</Button>
                         <Button type="primary" block square
                             :disabled="!formData.OrderQty || !sellQty || (formData.OrderQty > sellQty)"
                             @click="onBeforeSubmit(EBuildType.BUILDTYPE_CLOSE)" v-if="!isTrademode16">
@@ -55,7 +54,8 @@
                     </template>
                     <template v-if="buyOrSell === BuyOrSell.Sell">
                         <Button type="danger" block square :disabled="!formData.OrderQty"
-                            @click="onBeforeSubmit(EBuildType.BUILDTYPE_OPEN)" v-if="!isTrademode16 && !quote?.iscannotsell">订立卖出</Button>
+                            @click="onBeforeSubmit(EBuildType.BUILDTYPE_OPEN)"
+                            v-if="!isTrademode16 && !quote?.iscannotsell">订立卖出</Button>
                         <Button type="primary" block square
                             :disabled="!formData.OrderQty || !buyQty || (formData.OrderQty > buyQty)"
                             @click="onBeforeSubmit(EBuildType.BUILDTYPE_CLOSE)">
@@ -127,10 +127,10 @@ const enableQty = computed(() => {
 
     if (fixed && ratio) {
         if (marketmarginalgorithm === 1) {
-            return Math.trunc(avaiableMoney / ratio)
+            return Math.trunc(avaiableMoney / ratio) || 0
         }
         if (marketmarginalgorithm === 2) {
-            return Math.trunc(avaiableMoney / fixed)
+            return Math.trunc(avaiableMoney / fixed) || 0
         }
     }
     return 0

+ 2 - 2
src/packages/pc/views/market/trade/goods/list/listing/index.vue

@@ -124,10 +124,10 @@ const enableQty = computed(() => {
 
     if (fixed && ratio) {
         if (marketmarginalgorithm === 1) {
-            return Math.trunc(avaiableMoney / ratio)
+            return Math.trunc(avaiableMoney / ratio) || 0
         }
         if (marketmarginalgorithm === 2) {
-            return Math.trunc(avaiableMoney / fixed)
+            return Math.trunc(avaiableMoney / fixed) || 0
         }
     }
     return 0

+ 11 - 10
src/services/http/index.ts

@@ -242,25 +242,26 @@ export default new (class {
         Status?: number;
     }>(response: T, responseCode: keyof typeof FunCode) {
         console.log(responseCode, response)
-        switch (response.RetCode) {
+        const res = { ...response } // websocket 消息对象未定义的属性可能会有默认值
+        switch (res.RetCode) {
             case 0: {
-                return Promise.resolve(response)
+                return Promise.resolve(res)
             }
             case 12018: {
-                if (response.RetDesc) {
-                    const word = cryptojs.enc.Base64.parse(response.RetDesc) // 解析base64
-                    response.RetDesc = cryptojs.enc.Utf8.stringify(word)
+                if (res.RetDesc) {
+                    const word = cryptojs.enc.Base64.parse(res.RetDesc) // 解析base64
+                    res.RetDesc = cryptojs.enc.Utf8.stringify(word)
                 }
-                return Promise.reject(response.RetDesc)
+                return Promise.reject(res.RetDesc)
             }
             default: {
                 // 银行 业务 以 Status 作为判断依据
-                if (response.Status === 0 || response.Status == 6007) {
-                    return Promise.resolve(response)
+                if (res.Status === 0 || res.Status == 6007) {
+                    return Promise.resolve(res)
                 }
                 const { getErrorInfoByCode } = useErrorInfoStore()
-                const msg = getErrorInfoByCode(response.Status && [6003, 6066, 6019].includes(response.Status) ? response.Status : response.RetCode)
-                const error = String(response.RetDesc || response.RetCode || response.Status)
+                const msg = getErrorInfoByCode(res.Status && [6003, 6066, 6019].includes(res.Status) ? res.Status : res.RetCode)
+                const error = String(res.RetDesc || res.RetCode || res.Status)
                 return Promise.reject(msg ?? error)
             }
         }

+ 5 - 5
src/stores/modules/global.ts

@@ -113,11 +113,11 @@ export const useGlobalStore = defineStore(() => {
                 el.style.setProperty('font-size', fontSize)
             }
         } else {
-            if (screenWidth > 768) {
-                state.isMobile = false
-            } else {
-                state.isMobile = true
-            }
+            // if (screenWidth > 768) {
+            //     state.isMobile = false
+            // } else {
+            //     state.isMobile = true
+            // }
 
             el.setAttribute('screen', state.isMobile ? 'small' : 'normal')
         }