ソースを参照

增加进球数方案

flyzto 5 ヶ月 前
コミット
a6135cffc5

+ 1 - 0
server/models/GamesPs.js

@@ -18,6 +18,7 @@ const PS_IOR_KEYS = [
   ['-2', 'ior_rh_25', 'ior_wmh_2', 'ior_rac_15'],
   ['+1', 'ior_rah_05', 'ior_wmc_1', 'ior_rc_15'],
   ['+2', 'ior_rah_15', 'ior_wmc_2', 'ior_rc_25'],
+  ['2-3', 'ior_ot_2', 'ior_os_2#3', 'ior_ot_3'],
 ];
 
 const BASE_URL = 'https://api.isthe.me/api/p';

+ 6 - 2
web/apps/web-antd/src/views/match/components/match_card.vue

@@ -5,7 +5,11 @@ const parseEventKey = (key) => {
   }
   else if (key?.startsWith('wm')) {
     const ratio = key.split('_')[1];
-    return `净胜${ratio}`;
+    return `净胜 ${ratio}`;
+  }
+  else if (key?.startsWith('ou')) {
+    const ratio = key.split('_')[1];
+    return `大/小 ${ratio}`;
   }
   return key;
 }
@@ -147,7 +151,7 @@ defineProps({
       text-align: center;
     }
     th {
-      width: 64px;
+      width: 80px;
       font-weight: normal;
     }
     td {

+ 10 - 0
web/apps/web-antd/src/views/match/solutions/index.vue

@@ -162,6 +162,7 @@ const PS_IOR_KEYS = [
   ['-2', 'ior_rh_25', 'ior_wmh_2', 'ior_rac_15'],
   ['+1', 'ior_rah_05', 'ior_wmc_1', 'ior_rc_15'],
   ['+2', 'ior_rah_15', 'ior_wmc_2', 'ior_rc_25'],
+  ['2-3', 'ior_ot_2', 'ior_os_2#3', 'ior_ot_3'],
 ];
 
 const formatPsEvents = (events) => {
@@ -234,6 +235,15 @@ const formatEvents = (events, cprKeys) => {
         index = 2;
       }
     }
+    else if (type === 'ou') {
+      ratioKey = `ou_${Math.abs(ratio)}`;
+      if (side === 'c') {
+        index = 0;
+      }
+      else if (side === 'h') {
+        index = 2;
+      }
+    }
     if (typeof (ratioKey) == 'number') {
       if (ratioKey > 0) {
         ratioKey = `+${ratioKey}`;