Ver Fonte

修改角球赛事赔率

Your Name há 6 anos atrás
pai
commit
f8fe17516b
3 ficheiros alterados com 887 adições e 894 exclusões
  1. 95 100
      hg3535/.idea/workspace.xml
  2. 390 391
      hg3535/pipeline/roll_zuqiu.py
  3. 402 403
      hg3535/pipeline/zuqiu.py

+ 95 - 100
hg3535/.idea/workspace.xml

@@ -3,14 +3,8 @@
   <component name="ChangeListManager">
     <list default="true" id="7fa42e97-ddea-4404-91db-5a9ccc162649" name="Default Changelist" comment="">
       <change beforePath="$PROJECT_DIR$/.idea/workspace.xml" beforeDir="false" afterPath="$PROJECT_DIR$/.idea/workspace.xml" afterDir="false" />
-      <change beforePath="$PROJECT_DIR$/pipeline/roll_bangqiu.py" beforeDir="false" afterPath="$PROJECT_DIR$/pipeline/roll_bangqiu.py" afterDir="false" />
-      <change beforePath="$PROJECT_DIR$/pipeline/roll_lanqiu.py" beforeDir="false" afterPath="$PROJECT_DIR$/pipeline/roll_lanqiu.py" afterDir="false" />
-      <change beforePath="$PROJECT_DIR$/pipeline/roll_wangqiu.py" beforeDir="false" afterPath="$PROJECT_DIR$/pipeline/roll_wangqiu.py" afterDir="false" />
       <change beforePath="$PROJECT_DIR$/pipeline/roll_zuqiu.py" beforeDir="false" afterPath="$PROJECT_DIR$/pipeline/roll_zuqiu.py" afterDir="false" />
-      <change beforePath="$PROJECT_DIR$/pipeline/saiguo.py" beforeDir="false" afterPath="$PROJECT_DIR$/pipeline/saiguo.py" afterDir="false" />
-      <change beforePath="$PROJECT_DIR$/settings.py" beforeDir="false" afterPath="$PROJECT_DIR$/settings.py" afterDir="false" />
-      <change beforePath="$PROJECT_DIR$/spiders/saiguo.py" beforeDir="false" afterPath="$PROJECT_DIR$/spiders/saiguo.py" afterDir="false" />
-      <change beforePath="$PROJECT_DIR$/utils/helper.py" beforeDir="false" afterPath="$PROJECT_DIR$/utils/helper.py" afterDir="false" />
+      <change beforePath="$PROJECT_DIR$/pipeline/zuqiu.py" beforeDir="false" afterPath="$PROJECT_DIR$/pipeline/zuqiu.py" afterDir="false" />
     </list>
     <option name="EXCLUDED_CONVERTED_TO_IGNORED" value="true" />
     <option name="SHOW_DIALOG" value="false" />
@@ -20,7 +14,7 @@
   </component>
   <component name="CoverageDataManager">
     <SUITE FILE_PATH="coverage/hg3535$items.coverage" NAME="items Coverage Results" MODIFIED="1554291398794" SOURCE_PROVIDER="com.intellij.coverage.DefaultCoverageFileProvider" RUNNER="coverage.py" COVERAGE_BY_TEST_ENABLED="true" COVERAGE_TRACING_ENABLED="false" WORKING_DIRECTORY="$PROJECT_DIR$" />
-    <SUITE FILE_PATH="coverage/hg3535$main.coverage" NAME="main Coverage Results" MODIFIED="1570606986932" SOURCE_PROVIDER="com.intellij.coverage.DefaultCoverageFileProvider" RUNNER="coverage.py" COVERAGE_BY_TEST_ENABLED="true" COVERAGE_TRACING_ENABLED="false" WORKING_DIRECTORY="$PROJECT_DIR$" />
+    <SUITE FILE_PATH="coverage/hg3535$main.coverage" NAME="main Coverage Results" MODIFIED="1570607183591" SOURCE_PROVIDER="com.intellij.coverage.DefaultCoverageFileProvider" RUNNER="coverage.py" COVERAGE_BY_TEST_ENABLED="true" COVERAGE_TRACING_ENABLED="false" WORKING_DIRECTORY="$PROJECT_DIR$" />
     <SUITE FILE_PATH="coverage/hg3535$change.coverage" NAME="change Coverage Results" MODIFIED="1567749757856" SOURCE_PROVIDER="com.intellij.coverage.DefaultCoverageFileProvider" RUNNER="coverage.py" COVERAGE_BY_TEST_ENABLED="true" COVERAGE_TRACING_ENABLED="false" WORKING_DIRECTORY="$PROJECT_DIR$" />
     <SUITE FILE_PATH="coverage/hg3535$hgjieshu.coverage" NAME="hgjieshu Coverage Results" MODIFIED="1558494720094" SOURCE_PROVIDER="com.intellij.coverage.DefaultCoverageFileProvider" RUNNER="coverage.py" COVERAGE_BY_TEST_ENABLED="true" COVERAGE_TRACING_ENABLED="false" WORKING_DIRECTORY="$PROJECT_DIR$/spiders" />
     <SUITE FILE_PATH="coverage/hg3535$halffull.coverage" NAME="halffull Coverage Results" MODIFIED="1554544334424" SOURCE_PROVIDER="com.intellij.coverage.DefaultCoverageFileProvider" RUNNER="coverage.py" COVERAGE_BY_TEST_ENABLED="true" COVERAGE_TRACING_ENABLED="false" WORKING_DIRECTORY="$PROJECT_DIR$/spiders" />
@@ -50,43 +44,47 @@
   <component name="FileEditorManager">
     <leaf SIDE_TABS_SIZE_LIMIT_KEY="300">
       <file pinned="false" current-in-tab="false">
-        <entry file="file://$PROJECT_DIR$/spiders/zuqiu.py">
+        <entry file="file://$PROJECT_DIR$/pipeline/saiguo.py">
           <provider selected="true" editor-type-id="text-editor">
-            <state relative-caret-position="-980">
-              <caret line="31" column="6" selection-start-line="31" selection-start-column="6" selection-end-line="31" selection-end-column="6" />
+            <state relative-caret-position="843">
+              <caret line="107" column="42" selection-start-line="107" selection-start-column="42" selection-end-line="107" selection-end-column="42" />
               <folding>
-                <element signature="e#24#35#0" expanded="true" />
+                <element signature="e#18#32#0" expanded="true" />
               </folding>
             </state>
           </provider>
         </entry>
       </file>
-      <file pinned="false" current-in-tab="false">
-        <entry file="file://$PROJECT_DIR$/pipeline/saiguo.py">
+      <file pinned="false" current-in-tab="true">
+        <entry file="file://$PROJECT_DIR$/pipeline/zuqiu.py">
           <provider selected="true" editor-type-id="text-editor">
-            <state relative-caret-position="2341">
-              <caret line="121" lean-forward="true" selection-start-line="121" selection-end-line="121" />
+            <state relative-caret-position="5228">
+              <caret line="574" column="43" lean-forward="true" selection-start-line="574" selection-start-column="43" selection-end-line="574" selection-end-column="43" />
               <folding>
-                <element signature="e#18#32#0" expanded="true" />
+                <element signature="e#0#15#0" expanded="true" />
               </folding>
             </state>
           </provider>
         </entry>
       </file>
       <file pinned="false" current-in-tab="false">
-        <entry file="file://$PROJECT_DIR$/middlewares.py">
+        <entry file="file://$PROJECT_DIR$/pipeline/roll_zuqiu.py">
           <provider selected="true" editor-type-id="text-editor">
-            <state relative-caret-position="73">
-              <caret line="137" selection-start-line="137" selection-end-line="137" />
+            <state relative-caret-position="2042">
+              <caret line="1029" column="25" lean-forward="true" selection-start-line="1029" selection-start-column="25" selection-end-line="1029" selection-end-column="25" />
+              <folding>
+                <element signature="e#18#33#0" expanded="true" />
+                <element signature="e#37161#37176#0" />
+              </folding>
             </state>
           </provider>
         </entry>
       </file>
-      <file pinned="false" current-in-tab="true">
+      <file pinned="false" current-in-tab="false">
         <entry file="file://$PROJECT_DIR$/spiders/saiguo.py">
           <provider selected="true" editor-type-id="text-editor">
-            <state relative-caret-position="407">
-              <caret line="326" column="55" lean-forward="true" selection-start-line="326" selection-start-column="55" selection-end-line="326" selection-end-column="55" />
+            <state relative-caret-position="6020">
+              <caret line="301" column="15" selection-start-line="301" selection-start-column="15" selection-end-line="301" selection-end-column="15" />
               <folding>
                 <element signature="e#0#15#0" expanded="true" />
               </folding>
@@ -97,7 +95,7 @@
       <file pinned="false" current-in-tab="false">
         <entry file="file://$PROJECT_DIR$/utils/helper.py">
           <provider selected="true" editor-type-id="text-editor">
-            <state relative-caret-position="234">
+            <state relative-caret-position="460">
               <caret line="23" selection-start-line="23" selection-end-line="23" />
               <folding>
                 <element signature="e#0#14#0" expanded="true" />
@@ -121,7 +119,7 @@
       <file pinned="false" current-in-tab="false">
         <entry file="file://$PROJECT_DIR$/pipeline/guanjun.py">
           <provider selected="true" editor-type-id="text-editor">
-            <state relative-caret-position="484">
+            <state relative-caret-position="2480">
               <caret line="124" column="45" selection-start-line="124" selection-start-column="45" selection-end-line="124" selection-end-column="45" />
               <folding>
                 <element signature="e#18#32#0" expanded="true" />
@@ -133,7 +131,7 @@
       <file pinned="false" current-in-tab="false">
         <entry file="file://$PROJECT_DIR$/settings.py">
           <provider selected="true" editor-type-id="text-editor">
-            <state relative-caret-position="65">
+            <state relative-caret-position="3100">
               <caret line="155" column="44" selection-start-line="155" selection-start-column="44" selection-end-line="155" selection-end-column="44" />
             </state>
           </provider>
@@ -142,7 +140,7 @@
       <file pinned="false" current-in-tab="false">
         <entry file="file://$PROJECT_DIR$/items.py">
           <provider selected="true" editor-type-id="text-editor">
-            <state relative-caret-position="162">
+            <state relative-caret-position="9500">
               <caret line="475" column="31" selection-start-line="471" selection-end-line="486" selection-end-column="33" />
             </state>
           </provider>
@@ -151,7 +149,7 @@
       <file pinned="false" current-in-tab="false">
         <entry file="file://$PROJECT_DIR$/main.py">
           <provider selected="true" editor-type-id="text-editor">
-            <state relative-caret-position="244">
+            <state relative-caret-position="420">
               <caret line="21" column="40" selection-start-line="21" selection-start-column="40" selection-end-line="21" selection-end-column="40" />
               <folding>
                 <element signature="e#0#10#0" expanded="true" />
@@ -199,8 +197,8 @@
       <find>TN</find>
       <find>one_dishes_home</find>
       <find>成功</find>
-      <find>score_full</find>
       <find>match_id</find>
+      <find>score_full</find>
     </findStrings>
     <replaceStrings>
       <replace>&quot;&quot;</replace>
@@ -296,16 +294,16 @@
         <option value="$PROJECT_DIR$/pipeline/bangqiu.py" />
         <option value="$PROJECT_DIR$/pipeline/lanqiu.py" />
         <option value="$PROJECT_DIR$/pipeline/wangqiu.py" />
-        <option value="$PROJECT_DIR$/pipeline/zuqiu.py" />
         <option value="$PROJECT_DIR$/utils/helper.py" />
         <option value="$PROJECT_DIR$/pipeline/roll_lanqiu.py" />
         <option value="$PROJECT_DIR$/pipeline/roll_wangqiu.py" />
         <option value="$PROJECT_DIR$/pipeline/roll_bangqiu.py" />
-        <option value="$PROJECT_DIR$/pipeline/roll_zuqiu.py" />
         <option value="$PROJECT_DIR$/main.py" />
         <option value="$PROJECT_DIR$/settings.py" />
         <option value="$PROJECT_DIR$/pipeline/saiguo.py" />
         <option value="$PROJECT_DIR$/spiders/saiguo.py" />
+        <option value="$PROJECT_DIR$/pipeline/roll_zuqiu.py" />
+        <option value="$PROJECT_DIR$/pipeline/zuqiu.py" />
       </list>
     </option>
   </component>
@@ -321,6 +319,7 @@
       <foldersAlwaysOnTop value="true" />
     </navigator>
     <panes>
+      <pane id="Scope" />
       <pane id="ProjectPane">
         <subPane>
           <expand>
@@ -347,7 +346,6 @@
           <select />
         </subPane>
       </pane>
-      <pane id="Scope" />
     </panes>
   </component>
   <component name="PropertiesComponent">
@@ -664,14 +662,8 @@
       <workItem from="1570497048489" duration="630000" />
       <workItem from="1570519445273" duration="3553000" />
       <workItem from="1570599083340" duration="129000" />
-      <workItem from="1570605476233" duration="1643000" />
-    </task>
-    <task id="LOCAL-00051" summary="更新">
-      <created>1567767196921</created>
-      <option name="number" value="00051" />
-      <option name="presentableId" value="LOCAL-00051" />
-      <option name="project" value="LOCAL" />
-      <updated>1567767196921</updated>
+      <workItem from="1570605476233" duration="2322000" />
+      <workItem from="1570609094756" duration="543000" />
     </task>
     <task id="LOCAL-00052" summary="更新篮球, 父级玩法错误">
       <created>1567844689680</created>
@@ -1009,11 +1001,18 @@
       <option name="project" value="LOCAL" />
       <updated>1569637322958</updated>
     </task>
-    <option name="localTasksCounter" value="100" />
+    <task id="LOCAL-00100" summary="修改网球赛果提交错误">
+      <created>1570607142520</created>
+      <option name="number" value="00100" />
+      <option name="presentableId" value="LOCAL-00100" />
+      <option name="project" value="LOCAL" />
+      <updated>1570607142521</updated>
+    </task>
+    <option name="localTasksCounter" value="101" />
     <servers />
   </component>
   <component name="TimeTrackingManager">
-    <option name="totallyTimeSpent" value="2041482000" />
+    <option name="totallyTimeSpent" value="2042704000" />
   </component>
   <component name="TodoView">
     <todo-panel id="selected-file">
@@ -1028,7 +1027,7 @@
     <frame x="-8" y="-8" width="1936" height="1066" extended-state="6" />
     <editor active="true" />
     <layout>
-      <window_info content_ui="combo" id="Project" order="0" sideWeight="0.71173847" visible="true" weight="0.1673774" />
+      <window_info active="true" content_ui="combo" id="Project" order="0" sideWeight="0.71173847" visible="true" weight="0.16897655" />
       <window_info id="Structure" order="1" sideWeight="0.2882615" side_tool="true" weight="0.1108742" />
       <window_info id="Favorites" order="2" sideWeight="0.5013405" side_tool="true" weight="0.108208954" />
       <window_info anchor="bottom" id="Message" order="0" />
@@ -1043,7 +1042,7 @@
       <window_info anchor="bottom" id="Event Log" order="9" sideWeight="0.5042644" side_tool="true" weight="0.2725322" />
       <window_info anchor="bottom" x="22" y="376" width="1876" height="298" id="Terminal" order="10" sideWeight="0.49307036" weight="0.15987125" />
       <window_info anchor="bottom" id="Python Console" order="11" sideWeight="0.49946696" weight="0.26180258" />
-      <window_info active="true" anchor="bottom" id="Run" order="12" sideWeight="0.87473345" visible="true" weight="0.10729614" />
+      <window_info anchor="bottom" id="Run" order="12" sideWeight="0.87473345" weight="0.2886266" />
       <window_info anchor="right" id="Commander" internal_type="SLIDING" order="0" type="SLIDING" weight="0.4" />
       <window_info anchor="right" id="Ant Build" order="1" weight="0.25" />
       <window_info anchor="right" content_ui="combo" id="Hierarchy" order="2" weight="0.25" />
@@ -1126,7 +1125,6 @@
     </option>
   </component>
   <component name="VcsManagerConfiguration">
-    <MESSAGE value="修改联赛错误" />
     <MESSAGE value="修改冠军,导入错误" />
     <MESSAGE value="修改棒球,联赛无法写入" />
     <MESSAGE value="修改冠军,联赛url" />
@@ -1151,7 +1149,8 @@
     <MESSAGE value="添加球类赛果,接口提交" />
     <MESSAGE value="修改赛果球队名错误" />
     <MESSAGE value="更改返回错误状态码" />
-    <option name="LAST_COMMIT_MESSAGE" value="更改返回错误状态码" />
+    <MESSAGE value="修改网球赛果提交错误" />
+    <option name="LAST_COMMIT_MESSAGE" value="修改网球赛果提交错误" />
   </component>
   <component name="XDebuggerManager">
     <breakpoint-manager>
@@ -1261,11 +1260,6 @@
           <line>118</line>
           <option name="timeStamp" value="279" />
         </line-breakpoint>
-        <line-breakpoint enabled="true" suspend="THREAD" type="python-line">
-          <url>file://$PROJECT_DIR$/utils/helper.py</url>
-          <line>17</line>
-          <option name="timeStamp" value="307" />
-        </line-breakpoint>
       </breakpoints>
       <default-breakpoints>
         <breakpoint type="python-exception">
@@ -1563,16 +1557,6 @@
         </state>
       </provider>
     </entry>
-    <entry file="file://$PROJECT_DIR$/pipeline/roll_zuqiu.py">
-      <provider selected="true" editor-type-id="text-editor">
-        <state relative-caret-position="21900">
-          <caret line="1095" column="13" selection-start-line="1095" selection-start-column="13" selection-end-line="1095" selection-end-column="13" />
-          <folding>
-            <element signature="e#18#33#0" expanded="true" />
-          </folding>
-        </state>
-      </provider>
-    </entry>
     <entry file="file://$PROJECT_DIR$/pipeline/lanqiu.py">
       <provider selected="true" editor-type-id="text-editor">
         <state relative-caret-position="460">
@@ -1593,53 +1577,56 @@
         </state>
       </provider>
     </entry>
-    <entry file="file://$PROJECT_DIR$/pipeline/zuqiu.py">
+    <entry file="file://$PROJECT_DIR$/spiders/zuqiu.py">
       <provider selected="true" editor-type-id="text-editor">
-        <state relative-caret-position="160">
-          <caret line="8" lean-forward="true" selection-start-line="8" selection-end-line="8" />
+        <state relative-caret-position="620">
+          <caret line="31" column="6" selection-start-line="31" selection-start-column="6" selection-end-line="31" selection-end-column="6" />
           <folding>
-            <element signature="e#0#15#0" expanded="true" />
+            <element signature="e#24#35#0" expanded="true" />
           </folding>
         </state>
       </provider>
     </entry>
-    <entry file="file://$PROJECT_DIR$/pipeline/jieshu.py">
+    <entry file="file://$PROJECT_DIR$/middlewares.py">
       <provider selected="true" editor-type-id="text-editor">
-        <state relative-caret-position="560">
-          <caret line="28" selection-start-line="28" selection-end-line="28" />
-          <folding>
-            <element signature="e#18#33#0" expanded="true" />
-          </folding>
+        <state relative-caret-position="2680">
+          <caret line="137" selection-start-line="137" selection-end-line="137" />
         </state>
       </provider>
     </entry>
-    <entry file="file://$PROJECT_DIR$/main.py">
+    <entry file="file://$PROJECT_DIR$/spiders/saiguo.py">
       <provider selected="true" editor-type-id="text-editor">
-        <state relative-caret-position="244">
-          <caret line="21" column="40" selection-start-line="21" selection-start-column="40" selection-end-line="21" selection-end-column="40" />
+        <state relative-caret-position="6020">
+          <caret line="301" column="15" selection-start-line="301" selection-start-column="15" selection-end-line="301" selection-end-column="15" />
           <folding>
-            <element signature="e#0#10#0" expanded="true" />
+            <element signature="e#0#15#0" expanded="true" />
           </folding>
         </state>
       </provider>
     </entry>
-    <entry file="file://$PROJECT_DIR$/settings.py">
+    <entry file="file://$PROJECT_DIR$/utils/helper.py">
       <provider selected="true" editor-type-id="text-editor">
-        <state relative-caret-position="65">
-          <caret line="155" column="44" selection-start-line="155" selection-start-column="44" selection-end-line="155" selection-end-column="44" />
+        <state relative-caret-position="460">
+          <caret line="23" selection-start-line="23" selection-end-line="23" />
+          <folding>
+            <element signature="e#0#14#0" expanded="true" />
+          </folding>
         </state>
       </provider>
     </entry>
-    <entry file="file://$PROJECT_DIR$/items.py">
+    <entry file="file://$PROJECT_DIR$/pipeline/jieshu.py">
       <provider selected="true" editor-type-id="text-editor">
-        <state relative-caret-position="162">
-          <caret line="475" column="31" selection-start-line="471" selection-end-line="486" selection-end-column="33" />
+        <state relative-caret-position="560">
+          <caret line="28" selection-start-line="28" selection-end-line="28" />
+          <folding>
+            <element signature="e#18#33#0" expanded="true" />
+          </folding>
         </state>
       </provider>
     </entry>
     <entry file="file://$PROJECT_DIR$/pipeline/guanjun.py">
       <provider selected="true" editor-type-id="text-editor">
-        <state relative-caret-position="484">
+        <state relative-caret-position="2480">
           <caret line="124" column="45" selection-start-line="124" selection-start-column="45" selection-end-line="124" selection-end-column="45" />
           <folding>
             <element signature="e#18#32#0" expanded="true" />
@@ -1647,47 +1634,55 @@
         </state>
       </provider>
     </entry>
-    <entry file="file://$PROJECT_DIR$/spiders/zuqiu.py">
+    <entry file="file://$PROJECT_DIR$/settings.py">
       <provider selected="true" editor-type-id="text-editor">
-        <state relative-caret-position="-980">
-          <caret line="31" column="6" selection-start-line="31" selection-start-column="6" selection-end-line="31" selection-end-column="6" />
-          <folding>
-            <element signature="e#24#35#0" expanded="true" />
-          </folding>
+        <state relative-caret-position="3100">
+          <caret line="155" column="44" selection-start-line="155" selection-start-column="44" selection-end-line="155" selection-end-column="44" />
         </state>
       </provider>
     </entry>
-    <entry file="file://$PROJECT_DIR$/middlewares.py">
+    <entry file="file://$PROJECT_DIR$/items.py">
       <provider selected="true" editor-type-id="text-editor">
-        <state relative-caret-position="73">
-          <caret line="137" selection-start-line="137" selection-end-line="137" />
+        <state relative-caret-position="9500">
+          <caret line="475" column="31" selection-start-line="471" selection-end-line="486" selection-end-column="33" />
         </state>
       </provider>
     </entry>
-    <entry file="file://$PROJECT_DIR$/utils/helper.py">
+    <entry file="file://$PROJECT_DIR$/main.py">
       <provider selected="true" editor-type-id="text-editor">
-        <state relative-caret-position="234">
-          <caret line="23" selection-start-line="23" selection-end-line="23" />
+        <state relative-caret-position="420">
+          <caret line="21" column="40" selection-start-line="21" selection-start-column="40" selection-end-line="21" selection-end-column="40" />
           <folding>
-            <element signature="e#0#14#0" expanded="true" />
+            <element signature="e#0#10#0" expanded="true" />
           </folding>
         </state>
       </provider>
     </entry>
     <entry file="file://$PROJECT_DIR$/pipeline/saiguo.py">
       <provider selected="true" editor-type-id="text-editor">
-        <state relative-caret-position="2341">
-          <caret line="121" lean-forward="true" selection-start-line="121" selection-end-line="121" />
+        <state relative-caret-position="843">
+          <caret line="107" column="42" selection-start-line="107" selection-start-column="42" selection-end-line="107" selection-end-column="42" />
           <folding>
             <element signature="e#18#32#0" expanded="true" />
           </folding>
         </state>
       </provider>
     </entry>
-    <entry file="file://$PROJECT_DIR$/spiders/saiguo.py">
+    <entry file="file://$PROJECT_DIR$/pipeline/roll_zuqiu.py">
+      <provider selected="true" editor-type-id="text-editor">
+        <state relative-caret-position="2042">
+          <caret line="1029" column="25" lean-forward="true" selection-start-line="1029" selection-start-column="25" selection-end-line="1029" selection-end-column="25" />
+          <folding>
+            <element signature="e#18#33#0" expanded="true" />
+            <element signature="e#37161#37176#0" />
+          </folding>
+        </state>
+      </provider>
+    </entry>
+    <entry file="file://$PROJECT_DIR$/pipeline/zuqiu.py">
       <provider selected="true" editor-type-id="text-editor">
-        <state relative-caret-position="407">
-          <caret line="326" column="55" lean-forward="true" selection-start-line="326" selection-start-column="55" selection-end-line="326" selection-end-column="55" />
+        <state relative-caret-position="5228">
+          <caret line="574" column="43" lean-forward="true" selection-start-line="574" selection-start-column="43" selection-end-line="574" selection-end-column="43" />
           <folding>
             <element signature="e#0#15#0" expanded="true" />
           </folding>

+ 390 - 391
hg3535/pipeline/roll_zuqiu.py

@@ -637,397 +637,396 @@ class Roll_Zuqiupipeline(object):
                     logger.warning(match_data)
             else:
                 logger.info('足球滚球赛事已存在, 不提交')
-            p_code = "GS"
-            # 构建唯一索引
-            half_size_guest = item["half_size_guest"]
-            half_size_guest_rule = item["half_size_guest_rule"]
-            half_size_home = item["half_size_home"]
-            half_size_home_rule = item["half_size_home_rule"]
-            data_list = []
-            odds_onlys = []
-
-            # half_size_guest
-            for index, value in enumerate(half_size_guest):
-                hash_str = p_code + "gss_h" + str(index) + str(half_size_guest_rule[index]) + str(
-                    value) + "hg3535" + str(match_id)
-                sole_str = p_code + "gss_h" + str(index) + str(match_id) + "hg3535"
-                odds_only = Helper.genearte_MD5(hash_str, pt)
-                sole = Helper.genearte_MD5(sole_str, pt)
-                half_size_guest_key = ["match_id", "lg_id", "odds_code", "status", "sort", "p_code", "odds", "condition",
-                                       "odds_only", "sole", "source", "type", "team"]
-                condition = half_size_guest_rule[index]
-                half_size_guest_value = [match_id, league_id, "gss_h", "0", index, p_code, value, condition,
-                                         odds_only, sole, "hg3535", "0", ""]
-                half_size_guest_data = dict(zip(half_size_guest_key, half_size_guest_value))
-                data_list.append(half_size_guest_data)
-
-            # half_size_home
-            for index, value in enumerate(half_size_home):
-                hash_str = p_code + "gsb_h" + str(index) + str(half_size_home_rule[index]) + str(
-                    value) + "hg3535" + str(match_id)
-                sole_str = p_code + "gsb_h" + str(index) + str(match_id) + "hg3535"
-                odds_only = Helper.genearte_MD5(hash_str, pt)
-                sole = Helper.genearte_MD5(sole_str, pt)
-                half_size_home_key = ["match_id", "lg_id", "odds_code", "status", "sort", "p_code", "odds", "condition",
-                                      "odds_only", "sole", "source", "type", "team"]
-                condition = half_size_home_rule[index]
-                half_size_home_value = [match_id, league_id, "gsb_h", "0", index, p_code, value, condition,
-                                        odds_only, sole, "hg3535", "0", ""]
-                half_size_home_data = dict(zip(half_size_home_key, half_size_home_value))
-                data_list.append(half_size_home_data)
-
-            # 全场场大小
-            size_guest = item["size_guest"]
-            size_guest_rule = item["size_guest_rule"]
-            size_home = item["size_home"]
-            size_home_rule = item["size_home_rule"]
-            # size_home
-            for index, value in enumerate(size_home):
-                hash_str = p_code + "gsb" + str(index) + str(size_home_rule[index]) + str(value) + "hg3535" + str(
-                    match_id)
-                sole_str = p_code + "gsb" + str(index) + str(match_id) + "hg3535"
-                odds_only = Helper.genearte_MD5(hash_str, pt)
-                sole = Helper.genearte_MD5(sole_str, pt)
-                size_home_key = ["match_id", "lg_id", "odds_code", "status", "sort", "p_code", "odds", "condition",
-                                 "odds_only", "sole", "source", "type", "team"]
-                condition = size_home_rule[index]
-                size_home_value = [match_id, league_id, "gsb", "0", index, p_code, value, condition, odds_only,
-                                   sole, "hg3535", "0", ""]
-                size_home_data = dict(zip(size_home_key, size_home_value))
-                data_list.append(size_home_data)
-
-            # size_guest
-            for index, value in enumerate(size_guest):
-                hash_str = p_code + "gss" + str(index) + str(size_guest_rule[index]) + str(value) + "hg3535" + str(
-                    match_id)
-                sole_str = p_code + "gss" + str(index) + str(match_id) + "hg3535"
-                odds_only = Helper.genearte_MD5(hash_str, pt)
-                sole = Helper.genearte_MD5(sole_str, pt)
-                size_guest_key = ["match_id", "lg_id", "odds_code", "status", "sort", "p_code", "odds", "condition",
-                                  "odds_only", "sole", "source", "type", "team"]
-                condition = size_guest_rule[index]
-                size_guest_value = [match_id, league_id, "gss", "0", index, p_code, value, condition, odds_only,
-                                    sole, "hg3535", "0", ""]
-                size_home_data = dict(zip(size_guest_key, size_guest_value))
-                data_list.append(size_home_data)
-
-            p_code = 'CO'
-            half_concede_home_rule = item["half_concede_home_rule"]
-            half_concede_home = item["half_concede_home"]
-            half_concede_guest_rule = item["half_concede_guest_rule"]
-            half_concede_guest = item["half_concede_guest"]
-            # half_concede_home
-            for index, value in enumerate(half_concede_guest):
-                hash_str = p_code + "cog_h" + str(index) + str(half_concede_guest_rule[index]) + str(
-                    value) + "hg3535" + str(match_id)
-                sole_str = p_code + "cog_h" + str(index) + str(match_id) + "hg3535"
-                odds_only = Helper.genearte_MD5(hash_str, pt)
-                sole = Helper.genearte_MD5(sole_str, pt)
-                half_concede_guest_key = ["match_id", "lg_id", "odds_code", "status", "sort", "p_code", "odds", "condition",
-                                          "odds_only", "sole", "source", "type", "team"]
-                condition = half_concede_guest_rule[index]
-                half_concede_guest_value = [match_id, league_id, "cog_h", "0", index, p_code, value, condition,
-                                            odds_only, sole, "hg3535", "0", ""]
-                half_concede_guest_data = dict(zip(half_concede_guest_key, half_concede_guest_value))
-                data_list.append(half_concede_guest_data)
-
-            # half_concede_home
-            for index, value in enumerate(half_concede_home):
-                hash_str = p_code + "coh_h" + str(index) + str(half_concede_home_rule[index]) + str(
-                    value) + "hg3535" + str(match_id)
-                sole_str = p_code + "coh_h" + str(index) + str(match_id) + "hg3535"
-                odds_only = Helper.genearte_MD5(hash_str, pt)
-                sole = Helper.genearte_MD5(sole_str, pt)
-                half_concede_home_key = ["match_id", "lg_id", "odds_code", "status", "sort", "p_code", "odds", "condition",
-                                         "odds_only", "sole", "source", "type", "team"]
-                condition = half_concede_home_rule[index]
-                half_concede_home_value = [match_id, league_id, "coh_h", "0", index, p_code, value, condition,
-                                           odds_only, sole, "hg3535", "0", ""]
-                half_concede_home_data = dict(zip(half_concede_home_key, half_concede_home_value))
-                data_list.append(half_concede_home_data)
-
-            concede_guest = item["concede_guest"]
-            concede_guest_rule = item["concede_guest_rule"]
-            concede_home = item["concede_home"]
-            concede_home_rule = item["concede_home_rule"]
-            # concede_guest
-            for index, value in enumerate(concede_guest):
-                hash_str = p_code + "cog" + str(index) + str(concede_guest_rule[index]) + str(
-                    value) + "hg3535" + str(match_id)
-                sole_str = p_code + "cog" + str(index) + str(match_id) + "hg3535"
-                odds_only = Helper.genearte_MD5(hash_str, pt)
-                sole = Helper.genearte_MD5(sole_str, pt)
-                concede_guest_key = ["match_id", "lg_id", "odds_code", "status", "sort", "p_code", "odds", "condition",
-                                     "odds_only", "sole", "source", "type", "team"]
-                condition = concede_guest_rule[index]
-                concede_guest_value = [match_id, league_id, "cog", "0", index, p_code, value, condition,
-                                       odds_only, sole, "hg3535", "0", ""]
-                concede_guest_data = dict(zip(concede_guest_key, concede_guest_value))
-                data_list.append(concede_guest_data)
-
-            # concede_home
-            for index, value in enumerate(concede_home):
-                hash_str = p_code + "coh" + str(index) + str(concede_home_rule[index]) + str(
-                    value) + "hg3535" + str(match_id)
-                sole_str = p_code + "coh" + str(index) + str(match_id) + "hg3535"
-                odds_only = Helper.genearte_MD5(hash_str, pt)
-                sole = Helper.genearte_MD5(sole_str, pt)
-                concede_home_key = ["match_id", "lg_id", "odds_code", "status", "sort", "p_code", "odds", "condition",
-                                    "odds_only", "sole", "source", "type", "team"]
-                condition = concede_home_rule[index]
-                concede_home_value = [match_id, league_id, "coh", "0", index, p_code, value, condition, odds_only,
-                                      sole, "hg3535", "0", ""]
-                concede_guest_data = dict(zip(concede_home_key, concede_home_value))
-                data_list.append(concede_guest_data)
-
-            # 独赢-------------------------------------------------------------------------------------------------------
-            p_code = 'C'
-            half_capot_home = item["half_capot_home"]
-            half_capot_guest = item["half_capot_guest"]
-            half_capot_dogfall = item["half_capot_dogfall"]
-            capot_home = item["capot_home"]
-            capot_guest = item["capot_guest"]
-            capot_dogfall = item["capot_dogfall"]
-
-            # half_capot_home
-            hash_str = p_code + "ch_h" + '0' + '1' + str(half_capot_home) + "hg3535" + str(match_id)
-            sole_str = p_code + "ch_h" + '0' + str(match_id) + "hg3535"
-            odds_only = Helper.genearte_MD5(hash_str, pt)
-            sole = Helper.genearte_MD5(sole_str, pt)
-            half_capot_home_key = ["match_id", "lg_id", "odds_code", "status", "sort", "p_code", "odds", "condition",
-                                   "odds_only", "sole", "source", "type", "team"]
-            half_capot_home_value = [match_id, league_id, "ch_h", "0", 0, p_code, half_capot_home, '1',
-                                     odds_only, sole, "hg3535", "0", ""]
-            half_capot_homet_data = dict(zip(half_capot_home_key, half_capot_home_value))
-            data_list.append(half_capot_homet_data)
-
-            # half_capot_guest
-            hash_str = p_code + "cg_h" + '0' + '2' + str(half_capot_guest) + "hg3535" + str(match_id)
-            sole_str = p_code + "cg_h" + '0' + str(match_id) + "hg3535"
-            odds_only = Helper.genearte_MD5(hash_str, pt)
-            sole = Helper.genearte_MD5(sole_str, pt)
-            half_capot_guest_key = ["match_id", "lg_id", "odds_code", "status", "sort", "p_code", "odds", "condition",
-                                    "odds_only", "sole", "source", "type", "team"]
-            half_capot_guest_value = [match_id, league_id, "cg_h", "0", 0, p_code, half_capot_guest, '2',
-                                      odds_only, sole, "hg3535", "0", ""]
-            half_capot_guest_data = dict(zip(half_capot_guest_key, half_capot_guest_value))
-            data_list.append(half_capot_guest_data)
-
-            # half_capot_dogfall
-            hash_str = p_code + "cd_h" + '0' + 'X' + str(half_capot_dogfall) + "hg3535" + str(match_id)
-            sole_str = p_code + "cd_h" + '0' + str(match_id) + "hg3535"
-            odds_only = Helper.genearte_MD5(hash_str, pt)
-            sole = Helper.genearte_MD5(sole_str, pt)
-            half_capot_dogfall_key = ["match_id", "lg_id", "odds_code", "status", "sort", "p_code", "odds", "condition",
-                                      "odds_only", "sole", "source", "type", "team"]
-            half_capot_dogfall_value = [match_id, league_id, "cd_h", "0", 0, p_code, half_capot_dogfall, 'X',
-                                        odds_only, sole, "hg3535", "0", ""]
-            half_capot_dogfall_data = dict(zip(half_capot_dogfall_key, half_capot_dogfall_value))
-            data_list.append(half_capot_dogfall_data)
-            # capot_dogfall
-            hash_str = p_code + "cd" + '0' + 'X' + str(capot_dogfall) + "hg3535" + str(match_id)
-            sole_str = p_code + "cd" + '0' + str(match_id) + "hg3535"
-            odds_only = Helper.genearte_MD5(hash_str, pt)
-            sole = Helper.genearte_MD5(sole_str, pt)
-            capot_dogfall_key = ["match_id", "lg_id", "odds_code", "status", "sort", "p_code", "odds", "condition",
-                                 "odds_only", "sole", "source", "type", "team"]
-            capot_dogfall_value = [match_id, league_id, "cd", "0", 0, p_code, capot_dogfall, 'X', odds_only,
-                                   sole, "hg3535", "0", ""]
-            capot_dogfall_data = dict(zip(capot_dogfall_key, capot_dogfall_value))
-            data_list.append(capot_dogfall_data)
-
-            # capot_home
-            hash_str = p_code + "ch" + '0' + '1' + str(capot_home) + "hg3535" + str(match_id)
-            sole_str = p_code + "ch" + '0' + str(match_id) + "hg3535"
-            odds_only = Helper.genearte_MD5(hash_str, pt)
-            sole = Helper.genearte_MD5(sole_str, pt)
-            capot_home_key = ["match_id", "lg_id", "odds_code", "status", "sort", "p_code", "odds", "condition",
-                              "odds_only", "sole", "source", "type", "team"]
-            capot_home_value = [match_id, league_id, "ch", "0", 0, p_code, capot_home, '1',
-                                odds_only, sole, "hg3535", "0", ""]
-            capot_homet_data = dict(zip(capot_home_key, capot_home_value))
-            data_list.append(capot_homet_data)
-
-            # capot_guest
-            hash_str = p_code + "cg" + '0' + '2' + str(capot_guest) + "hg3535" + str(match_id)
-            sole_str = p_code + "cg" + '0' + str(match_id) + "hg3535"
-            odds_only = Helper.genearte_MD5(hash_str, pt)
-            sole = Helper.genearte_MD5(sole_str, pt)
-            capot_guest_key = ["match_id", "lg_id", "odds_code", "status", "sort", "p_code", "odds", "condition",
-                               "odds_only", "sole", "source", "type", "team"]
-            capot_guest_value = [match_id, league_id, "cg", "0", 0, p_code, capot_guest, '2',
-                                 odds_only, sole, "hg3535", "0", ""]
-            capot_guest_data = dict(zip(capot_guest_key, capot_guest_value))
-            data_list.append(capot_guest_data)
-
-            # 入球数单双--------------------------------------------------------------------------------------------------
-            p_code = 'TS'
-            odd_even_odd = item["odd_even_odd"]
-            odd_even_even = item["odd_even_even"]
-            half_odd_even_odd = item["half_odd_even_odd"]
-            half_odd_even_even = item["half_odd_even_even"]
-
-            # odd_even_odd
-            hash_str = p_code + "tss" + '0' + '单' + str(odd_even_odd) + "hg3535" + str(match_id)
-            sole_str = p_code + "tss" + '0' + str(match_id) + "hg3535"
-            odds_only = Helper.genearte_MD5(hash_str, pt)
-            sole = Helper.genearte_MD5(sole_str, pt)
-            single_key = ["match_id", "lg_id", "odds_code", "status", "sort", "p_code", "odds", "condition",
-                          "odds_only", "sole", "source", "type", "team"]
-            single_value = [match_id, league_id, "tss", "0", 0, p_code, odd_even_odd, '单',
-                            odds_only, sole, "hg3535", "0", ""]
-            single_data = dict(zip(single_key, single_value))
-            data_list.append(single_data)
-
-            # odd_even_even
-            hash_str = p_code + "tsd" + '0' + '双' + str(odd_even_even) + "hg3535" + str(match_id)
-            sole_str = p_code + "tsd" + '0' + str(match_id) + "hg3535"
-            odds_only = Helper.genearte_MD5(hash_str, pt)
-            sole = Helper.genearte_MD5(sole_str, pt)
-            double_key = ["match_id", "lg_id", "odds_code", "status", "sort", "p_code", "odds", "condition",
-                          "odds_only", "sole", "source", "type", "team"]
-            double_value = [match_id, league_id, "tsd", "0", 0, p_code, odd_even_even, '双',
-                            odds_only, sole, "hg3535", "0", ""]
-            double_data = dict(zip(double_key, double_value))
-            data_list.append(double_data)
-
-            # half_odd_even_even
-            hash_str = p_code + "tsd_h" + '0' + '双' + str(half_odd_even_even) + "hg3535" + str(match_id)
-            sole_str = p_code + "tsd_h" + '0' + str(match_id) + "hg3535"
-            odds_only = Helper.genearte_MD5(hash_str, pt)
-            sole = Helper.genearte_MD5(sole_str, pt)
-            half_double_key = ["match_id", "lg_id", "odds_code", "status", "sort", "p_code", "odds", "condition",
-                               "odds_only", "sole", "source", "type", "team"]
-            half_double_value = [match_id, league_id, "tsd_h", "0", 0, p_code, half_odd_even_even, '双',
-                                 odds_only, sole, "hg3535", "0", ""]
-            half_double_data = dict(zip(half_double_key, half_double_value))
-            data_list.append(half_double_data)
-
-            # half_odd_even_odd
-            hash_str = p_code + "tss_h" + '0' + '单' + str(half_odd_even_odd) + "hg3535" + str(match_id)
-            sole_str = p_code + "tss_h" + '0' + str(match_id) + "hg3535"
-            odds_only = Helper.genearte_MD5(hash_str, pt)
-            sole = Helper.genearte_MD5(sole_str, pt)
-            half_single_key = ["match_id", "lg_id", "odds_code", "status", "sort", "p_code", "odds", "condition",
-                               "odds_only", "sole", "source", "type", "team"]
-            half_single_value = [match_id, league_id, "tss_h", "0", 0, p_code, half_odd_even_odd, '单', odds_only,
-                                 sole, "hg3535", "0", ""]
-            half_single_data = dict(zip(half_single_key, half_single_value))
-            data_list.append(half_single_data)
-
-            p_code = 'TG'
-            # 总入球数 ---------------------------------------------------------------------------------------------------
-            total_goals = item['total_goal']
-            total_dict = {'tg0': '0-1', 'tg1': '2-3', 'tg2': '4-6', 'tg3': '7或以上', 'tg0_h': '0', "tg1_h": '1',
-                          "tg2_h": '2', "tg3_h": '3或以上'}
-            # 全场入球数 单双
-            for key, value in total_goals.items():
-                hash_str = p_code + key + '0' + total_dict[key] + str(value) + "hg3535" + str(match_id)
-                sole_str = p_code + key + '0' + str(match_id) + "hg3535"
-                odds_only = Helper.genearte_MD5(hash_str, pt)
-                sole = Helper.genearte_MD5(sole_str, pt)
-                total_goals_key = ["match_id", "lg_id", "odds_code", "status", "sort", "p_code", "odds", "condition",
-                                   "odds_only", "sole", "source", "type", "team"]
-                total_goals_value = [match_id, league_id, key, "0", 0, p_code, value, total_dict[key], odds_only,
-                                     sole, "hg3535", "0", ""]
-                total_goals_data = dict(zip(total_goals_key, total_goals_value))
-                data_list.append(total_goals_data)
-
-            # 全场半场 ---------------------------------------------------------------------------------------------------
-            half_fulls = item['half_full']
-            # p_code, p_id = get_pcode(corner_ball, 'half_full')
-            p_code = 'HF'
-            full_dict = {"hfhh": "主主", "hfhd": "主和", "hfhg": "主客", "hfdh": "和主",
-                         "hfdd": "和和", "hfdg": "和客", "hfgh": "客主", "hfgd": "客和", "hfgg": "客客"}
-            if half_fulls:
-                for key, value in half_fulls.items():
-                    hash_str = p_code + key + '0' + full_dict[key] + str(value) + "hg3535" + str(match_id)
-                    sole_str = p_code + key + '0' + str(match_id) + "hg3535"
-                    odds_only = Helper.genearte_MD5(hash_str, pt)
-                    sole = Helper.genearte_MD5(sole_str, pt)
-                    half_fulls_key = ["match_id", "lg_id", "odds_code", "status", "sort", "p_code", "odds", "condition",
-                                      "odds_only", "sole", "source", "type", "team"]
-                    half_fulls_value = [match_id, league_id, key, "0", 0, p_code, value, full_dict[key], odds_only,
-                                        sole, "hg3535", "0", ""]
-                    half_fulls_data = dict(zip(half_fulls_key, half_fulls_value))
-                    data_list.append(half_fulls_data)
-
-            # 波胆-------------------------------------------------------------------------------------------------------
-            p_code = 'B'
-            bodan_datas = item['bodan_data']
-            # p_code, p_id = get_pcode(corner_ball, 'bodan')
-            bodan_dict = {"b10": "1-0", "b20": "2-0", "b21": "2-1", "b30": "3-0", "b31": "3-1", "b32": "3-2",
-                          "b40": "4-0", "b41": "4-1", "b42": "4-2", "b43": "4-3", "b01": "0-1", "b02": "0-2",
-                          "b12": "1-2", "b03": "0-3", "b13": "1-3", "b23": "2-3", "b04": "0-4", "b14": "1-4",
-                          "b24": "2-4", "b34": "3-4", "b00": "0-0", "b11": "1-1", "b22": "2-2", "b33": "3-3",
-                          "b44": "4-4", "bo": "其他", "b10_h": "1-0", "b20_h": "2-0", "b21_h": "2-1", "b30_h": "3-0",
-                          "b31_h": "3-1", "b32_h": "3-2", "b01_h": "0-1", "b02_h": "0-2", "b12_h": "1-2", "b03_h": "0-3",
-                          "b13_h": "1-3", "b23_h": "2-3", "b00_h": "0-0", "b11_h": "1-1", "b22_h": "2-2", "b33_h": "3-3",
-                          "bo_h": "其他"}
-            if bodan_datas:
-                for key, value in bodan_datas.items():
-                    hash_str = p_code + key + '0' + bodan_dict[key] + str(value) + "hg3535" + str(match_id)
-                    sole_str = p_code + key + '0' + str(match_id) + "hg3535"
-                    odds_only = Helper.genearte_MD5(hash_str, pt)
-                    sole = Helper.genearte_MD5(sole_str, pt)
-                    bodan_dict_key = ["match_id", "lg_id", "odds_code", "status", "sort", "p_code", "odds", "condition",
-                                      "odds_only", "sole", "source", "type", "team"]
-                    bodan_dict_value = [match_id, league_id, key, "0", 0, p_code, value, bodan_dict[key], odds_only,
-                                        sole, "hg3535", "0", ""]
-                    bodan_dict_data = dict(zip(bodan_dict_key, bodan_dict_value))
-                    data_list.append(bodan_dict_data)
-
-            # 最先进球/最后进球 -------------------------------------------------------------------------------------------
-            first_last_balls = item['first_last_ball']
-            p_code = 'FLB'
-            first_last_dict = {"flbfh": "最先进球", "flbfg": "最先进球", "flblh": "最后进球", "flblg": "最后进球", "flbn": "没有进球"}
-            if first_last_balls:
-                for key, value in first_last_balls.items():
-                    hash_str = p_code + key + '0' + first_last_dict[key] + str(value) + "hg3535" + str(match_id)
-                    sole_str = p_code + key + '0' + str(match_id) + "hg3535"
-                    odds_only = Helper.genearte_MD5(hash_str, pt)
-                    sole = Helper.genearte_MD5(sole_str, pt)
-                    first_last_balls_key = ["match_id", "lg_id", "odds_code", "status", "sort", "p_code", "odds",
-                                            "condition",
-                                            "odds_only", "sole", "source", "type", "team"]
-                    first_last_balls_value = [match_id, league_id, key, "0", 0, p_code, value, first_last_dict[key],
-                                              odds_only,
-                                              sole, "hg3535", "0", ""]
-                    first_last_balls_data = dict(zip(first_last_balls_key, first_last_balls_value))
-                    data_list.append(first_last_balls_data)
-
-            p_code = 'TB'
-            # 球队得分全场,上半场
-            full_dicts = item['full_data']
-            half_dicts = item['half_data']
-            full_dict_rules = item['full_data_rule']
-            half_dict_rules = item['half_data_rule']
-            if full_dicts:
-                for key, value in full_dicts.items():
-                    hash_str = p_code + key + '0' + full_dict_rules[key] + str(value) + "hg3535" + str(match_id)
-                    sole_str = p_code + key + '0' + str(match_id) + "hg3535"
-                    odds_only = Helper.genearte_MD5(hash_str, pt)
-                    sole = Helper.genearte_MD5(sole_str, pt)
-                    full_dict_rules_key = ["match_id", "lg_id", "odds_code", "status", "sort", "p_code", "odds",
-                                           "condition", "odds_only", "sole", "source", "type", "team"]
-                    full_dict_rules_value = [match_id, league_id, key, "0", 0, p_code, value, full_dict_rules[key],
-                                             odds_only, sole, "hg3535", "0", ""]
-                    full_dict_rules_data = dict(zip(full_dict_rules_key, full_dict_rules_value))
-                    data_list.append(full_dict_rules_data)
-
-            if half_dicts:
-                for key, value in half_dicts.items():
-                    hash_str = p_code + key + '0' + half_dict_rules[key] + str(value) + "hg3535" + str(match_id)
-                    sole_str = p_code + key + '0' + str(match_id) + "hg3535"
-                    odds_only = Helper.genearte_MD5(hash_str, pt)
-                    sole = Helper.genearte_MD5(sole_str, pt)
-                    half_dicts_key = ["match_id", "lg_id", "odds_code", "status", "sort", "p_code", "odds",
-                                      "condition", "odds_only", "sole", "source", "type", "team"]
-                    half_dicts_value = [match_id, league_id, key, "0", 0, p_code, value, half_dict_rules[key],
-                                        odds_only, sole, "hg3535", "0", ""]
-                    half_dicts_data = dict(zip(half_dicts_key, half_dicts_value))
-                    data_list.append(half_dicts_data)
-
+            # p_code = "GS"
+            # # 构建唯一索引
+            # half_size_guest = item["half_size_guest"]
+            # half_size_guest_rule = item["half_size_guest_rule"]
+            # half_size_home = item["half_size_home"]
+            # half_size_home_rule = item["half_size_home_rule"]
+            # data_list = []
+            # odds_onlys = []
+            #
+            # # half_size_guest
+            # for index, value in enumerate(half_size_guest):
+            #     hash_str = p_code + "gss_h" + str(index) + str(half_size_guest_rule[index]) + str(
+            #         value) + "hg3535" + str(match_id)
+            #     sole_str = p_code + "gss_h" + str(index) + str(match_id) + "hg3535"
+            #     odds_only = Helper.genearte_MD5(hash_str, pt)
+            #     sole = Helper.genearte_MD5(sole_str, pt)
+            #     half_size_guest_key = ["match_id", "lg_id", "odds_code", "status", "sort", "p_code", "odds", "condition",
+            #                            "odds_only", "sole", "source", "type", "team"]
+            #     condition = half_size_guest_rule[index]
+            #     half_size_guest_value = [match_id, league_id, "gss_h", "0", index, p_code, value, condition,
+            #                              odds_only, sole, "hg3535", "0", ""]
+            #     half_size_guest_data = dict(zip(half_size_guest_key, half_size_guest_value))
+            #     data_list.append(half_size_guest_data)
+            #
+            # # half_size_home
+            # for index, value in enumerate(half_size_home):
+            #     hash_str = p_code + "gsb_h" + str(index) + str(half_size_home_rule[index]) + str(
+            #         value) + "hg3535" + str(match_id)
+            #     sole_str = p_code + "gsb_h" + str(index) + str(match_id) + "hg3535"
+            #     odds_only = Helper.genearte_MD5(hash_str, pt)
+            #     sole = Helper.genearte_MD5(sole_str, pt)
+            #     half_size_home_key = ["match_id", "lg_id", "odds_code", "status", "sort", "p_code", "odds", "condition",
+            #                           "odds_only", "sole", "source", "type", "team"]
+            #     condition = half_size_home_rule[index]
+            #     half_size_home_value = [match_id, league_id, "gsb_h", "0", index, p_code, value, condition,
+            #                             odds_only, sole, "hg3535", "0", ""]
+            #     half_size_home_data = dict(zip(half_size_home_key, half_size_home_value))
+            #     data_list.append(half_size_home_data)
+            #
+            # # 全场场大小
+            # size_guest = item["size_guest"]
+            # size_guest_rule = item["size_guest_rule"]
+            # size_home = item["size_home"]
+            # size_home_rule = item["size_home_rule"]
+            # # size_home
+            # for index, value in enumerate(size_home):
+            #     hash_str = p_code + "gsb" + str(index) + str(size_home_rule[index]) + str(value) + "hg3535" + str(
+            #         match_id)
+            #     sole_str = p_code + "gsb" + str(index) + str(match_id) + "hg3535"
+            #     odds_only = Helper.genearte_MD5(hash_str, pt)
+            #     sole = Helper.genearte_MD5(sole_str, pt)
+            #     size_home_key = ["match_id", "lg_id", "odds_code", "status", "sort", "p_code", "odds", "condition",
+            #                      "odds_only", "sole", "source", "type", "team"]
+            #     condition = size_home_rule[index]
+            #     size_home_value = [match_id, league_id, "gsb", "0", index, p_code, value, condition, odds_only,
+            #                        sole, "hg3535", "0", ""]
+            #     size_home_data = dict(zip(size_home_key, size_home_value))
+            #     data_list.append(size_home_data)
+            #
+            # # size_guest
+            # for index, value in enumerate(size_guest):
+            #     hash_str = p_code + "gss" + str(index) + str(size_guest_rule[index]) + str(value) + "hg3535" + str(
+            #         match_id)
+            #     sole_str = p_code + "gss" + str(index) + str(match_id) + "hg3535"
+            #     odds_only = Helper.genearte_MD5(hash_str, pt)
+            #     sole = Helper.genearte_MD5(sole_str, pt)
+            #     size_guest_key = ["match_id", "lg_id", "odds_code", "status", "sort", "p_code", "odds", "condition",
+            #                       "odds_only", "sole", "source", "type", "team"]
+            #     condition = size_guest_rule[index]
+            #     size_guest_value = [match_id, league_id, "gss", "0", index, p_code, value, condition, odds_only,
+            #                         sole, "hg3535", "0", ""]
+            #     size_home_data = dict(zip(size_guest_key, size_guest_value))
+            #     data_list.append(size_home_data)
+            #
+            # p_code = 'CO'
+            # half_concede_home_rule = item["half_concede_home_rule"]
+            # half_concede_home = item["half_concede_home"]
+            # half_concede_guest_rule = item["half_concede_guest_rule"]
+            # half_concede_guest = item["half_concede_guest"]
+            # # half_concede_home
+            # for index, value in enumerate(half_concede_guest):
+            #     hash_str = p_code + "cog_h" + str(index) + str(half_concede_guest_rule[index]) + str(
+            #         value) + "hg3535" + str(match_id)
+            #     sole_str = p_code + "cog_h" + str(index) + str(match_id) + "hg3535"
+            #     odds_only = Helper.genearte_MD5(hash_str, pt)
+            #     sole = Helper.genearte_MD5(sole_str, pt)
+            #     half_concede_guest_key = ["match_id", "lg_id", "odds_code", "status", "sort", "p_code", "odds", "condition",
+            #                               "odds_only", "sole", "source", "type", "team"]
+            #     condition = half_concede_guest_rule[index]
+            #     half_concede_guest_value = [match_id, league_id, "cog_h", "0", index, p_code, value, condition,
+            #                                 odds_only, sole, "hg3535", "0", ""]
+            #     half_concede_guest_data = dict(zip(half_concede_guest_key, half_concede_guest_value))
+            #     data_list.append(half_concede_guest_data)
+            #
+            # # half_concede_home
+            # for index, value in enumerate(half_concede_home):
+            #     hash_str = p_code + "coh_h" + str(index) + str(half_concede_home_rule[index]) + str(
+            #         value) + "hg3535" + str(match_id)
+            #     sole_str = p_code + "coh_h" + str(index) + str(match_id) + "hg3535"
+            #     odds_only = Helper.genearte_MD5(hash_str, pt)
+            #     sole = Helper.genearte_MD5(sole_str, pt)
+            #     half_concede_home_key = ["match_id", "lg_id", "odds_code", "status", "sort", "p_code", "odds", "condition",
+            #                              "odds_only", "sole", "source", "type", "team"]
+            #     condition = half_concede_home_rule[index]
+            #     half_concede_home_value = [match_id, league_id, "coh_h", "0", index, p_code, value, condition,
+            #                                odds_only, sole, "hg3535", "0", ""]
+            #     half_concede_home_data = dict(zip(half_concede_home_key, half_concede_home_value))
+            #     data_list.append(half_concede_home_data)
+            #
+            # concede_guest = item["concede_guest"]
+            # concede_guest_rule = item["concede_guest_rule"]
+            # concede_home = item["concede_home"]
+            # concede_home_rule = item["concede_home_rule"]
+            # # concede_guest
+            # for index, value in enumerate(concede_guest):
+            #     hash_str = p_code + "cog" + str(index) + str(concede_guest_rule[index]) + str(
+            #         value) + "hg3535" + str(match_id)
+            #     sole_str = p_code + "cog" + str(index) + str(match_id) + "hg3535"
+            #     odds_only = Helper.genearte_MD5(hash_str, pt)
+            #     sole = Helper.genearte_MD5(sole_str, pt)
+            #     concede_guest_key = ["match_id", "lg_id", "odds_code", "status", "sort", "p_code", "odds", "condition",
+            #                          "odds_only", "sole", "source", "type", "team"]
+            #     condition = concede_guest_rule[index]
+            #     concede_guest_value = [match_id, league_id, "cog", "0", index, p_code, value, condition,
+            #                            odds_only, sole, "hg3535", "0", ""]
+            #     concede_guest_data = dict(zip(concede_guest_key, concede_guest_value))
+            #     data_list.append(concede_guest_data)
+            #
+            # # concede_home
+            # for index, value in enumerate(concede_home):
+            #     hash_str = p_code + "coh" + str(index) + str(concede_home_rule[index]) + str(
+            #         value) + "hg3535" + str(match_id)
+            #     sole_str = p_code + "coh" + str(index) + str(match_id) + "hg3535"
+            #     odds_only = Helper.genearte_MD5(hash_str, pt)
+            #     sole = Helper.genearte_MD5(sole_str, pt)
+            #     concede_home_key = ["match_id", "lg_id", "odds_code", "status", "sort", "p_code", "odds", "condition",
+            #                         "odds_only", "sole", "source", "type", "team"]
+            #     condition = concede_home_rule[index]
+            #     concede_home_value = [match_id, league_id, "coh", "0", index, p_code, value, condition, odds_only,
+            #                           sole, "hg3535", "0", ""]
+            #     concede_guest_data = dict(zip(concede_home_key, concede_home_value))
+            #     data_list.append(concede_guest_data)
+            #
+            # # 独赢-------------------------------------------------------------------------------------------------------
+            # p_code = 'C'
+            # half_capot_home = item["half_capot_home"]
+            # half_capot_guest = item["half_capot_guest"]
+            # half_capot_dogfall = item["half_capot_dogfall"]
+            # capot_home = item["capot_home"]
+            # capot_guest = item["capot_guest"]
+            # capot_dogfall = item["capot_dogfall"]
+            #
+            # # half_capot_home
+            # hash_str = p_code + "ch_h" + '0' + '1' + str(half_capot_home) + "hg3535" + str(match_id)
+            # sole_str = p_code + "ch_h" + '0' + str(match_id) + "hg3535"
+            # odds_only = Helper.genearte_MD5(hash_str, pt)
+            # sole = Helper.genearte_MD5(sole_str, pt)
+            # half_capot_home_key = ["match_id", "lg_id", "odds_code", "status", "sort", "p_code", "odds", "condition",
+            #                        "odds_only", "sole", "source", "type", "team"]
+            # half_capot_home_value = [match_id, league_id, "ch_h", "0", 0, p_code, half_capot_home, '1',
+            #                          odds_only, sole, "hg3535", "0", ""]
+            # half_capot_homet_data = dict(zip(half_capot_home_key, half_capot_home_value))
+            # data_list.append(half_capot_homet_data)
+            #
+            # # half_capot_guest
+            # hash_str = p_code + "cg_h" + '0' + '2' + str(half_capot_guest) + "hg3535" + str(match_id)
+            # sole_str = p_code + "cg_h" + '0' + str(match_id) + "hg3535"
+            # odds_only = Helper.genearte_MD5(hash_str, pt)
+            # sole = Helper.genearte_MD5(sole_str, pt)
+            # half_capot_guest_key = ["match_id", "lg_id", "odds_code", "status", "sort", "p_code", "odds", "condition",
+            #                         "odds_only", "sole", "source", "type", "team"]
+            # half_capot_guest_value = [match_id, league_id, "cg_h", "0", 0, p_code, half_capot_guest, '2',
+            #                           odds_only, sole, "hg3535", "0", ""]
+            # half_capot_guest_data = dict(zip(half_capot_guest_key, half_capot_guest_value))
+            # data_list.append(half_capot_guest_data)
+            #
+            # # half_capot_dogfall
+            # hash_str = p_code + "cd_h" + '0' + 'X' + str(half_capot_dogfall) + "hg3535" + str(match_id)
+            # sole_str = p_code + "cd_h" + '0' + str(match_id) + "hg3535"
+            # odds_only = Helper.genearte_MD5(hash_str, pt)
+            # sole = Helper.genearte_MD5(sole_str, pt)
+            # half_capot_dogfall_key = ["match_id", "lg_id", "odds_code", "status", "sort", "p_code", "odds", "condition",
+            #                           "odds_only", "sole", "source", "type", "team"]
+            # half_capot_dogfall_value = [match_id, league_id, "cd_h", "0", 0, p_code, half_capot_dogfall, 'X',
+            #                             odds_only, sole, "hg3535", "0", ""]
+            # half_capot_dogfall_data = dict(zip(half_capot_dogfall_key, half_capot_dogfall_value))
+            # data_list.append(half_capot_dogfall_data)
+            # # capot_dogfall
+            # hash_str = p_code + "cd" + '0' + 'X' + str(capot_dogfall) + "hg3535" + str(match_id)
+            # sole_str = p_code + "cd" + '0' + str(match_id) + "hg3535"
+            # odds_only = Helper.genearte_MD5(hash_str, pt)
+            # sole = Helper.genearte_MD5(sole_str, pt)
+            # capot_dogfall_key = ["match_id", "lg_id", "odds_code", "status", "sort", "p_code", "odds", "condition",
+            #                      "odds_only", "sole", "source", "type", "team"]
+            # capot_dogfall_value = [match_id, league_id, "cd", "0", 0, p_code, capot_dogfall, 'X', odds_only,
+            #                        sole, "hg3535", "0", ""]
+            # capot_dogfall_data = dict(zip(capot_dogfall_key, capot_dogfall_value))
+            # data_list.append(capot_dogfall_data)
+            #
+            # # capot_home
+            # hash_str = p_code + "ch" + '0' + '1' + str(capot_home) + "hg3535" + str(match_id)
+            # sole_str = p_code + "ch" + '0' + str(match_id) + "hg3535"
+            # odds_only = Helper.genearte_MD5(hash_str, pt)
+            # sole = Helper.genearte_MD5(sole_str, pt)
+            # capot_home_key = ["match_id", "lg_id", "odds_code", "status", "sort", "p_code", "odds", "condition",
+            #                   "odds_only", "sole", "source", "type", "team"]
+            # capot_home_value = [match_id, league_id, "ch", "0", 0, p_code, capot_home, '1',
+            #                     odds_only, sole, "hg3535", "0", ""]
+            # capot_homet_data = dict(zip(capot_home_key, capot_home_value))
+            # data_list.append(capot_homet_data)
+            #
+            # # capot_guest
+            # hash_str = p_code + "cg" + '0' + '2' + str(capot_guest) + "hg3535" + str(match_id)
+            # sole_str = p_code + "cg" + '0' + str(match_id) + "hg3535"
+            # odds_only = Helper.genearte_MD5(hash_str, pt)
+            # sole = Helper.genearte_MD5(sole_str, pt)
+            # capot_guest_key = ["match_id", "lg_id", "odds_code", "status", "sort", "p_code", "odds", "condition",
+            #                    "odds_only", "sole", "source", "type", "team"]
+            # capot_guest_value = [match_id, league_id, "cg", "0", 0, p_code, capot_guest, '2',
+            #                      odds_only, sole, "hg3535", "0", ""]
+            # capot_guest_data = dict(zip(capot_guest_key, capot_guest_value))
+            # data_list.append(capot_guest_data)
+            #
+            # # 入球数单双--------------------------------------------------------------------------------------------------
+            # p_code = 'TS'
+            # odd_even_odd = item["odd_even_odd"]
+            # odd_even_even = item["odd_even_even"]
+            # half_odd_even_odd = item["half_odd_even_odd"]
+            # half_odd_even_even = item["half_odd_even_even"]
+            #
+            # # odd_even_odd
+            # hash_str = p_code + "tss" + '0' + '单' + str(odd_even_odd) + "hg3535" + str(match_id)
+            # sole_str = p_code + "tss" + '0' + str(match_id) + "hg3535"
+            # odds_only = Helper.genearte_MD5(hash_str, pt)
+            # sole = Helper.genearte_MD5(sole_str, pt)
+            # single_key = ["match_id", "lg_id", "odds_code", "status", "sort", "p_code", "odds", "condition",
+            #               "odds_only", "sole", "source", "type", "team"]
+            # single_value = [match_id, league_id, "tss", "0", 0, p_code, odd_even_odd, '单',
+            #                 odds_only, sole, "hg3535", "0", ""]
+            # single_data = dict(zip(single_key, single_value))
+            # data_list.append(single_data)
+            #
+            # # odd_even_even
+            # hash_str = p_code + "tsd" + '0' + '双' + str(odd_even_even) + "hg3535" + str(match_id)
+            # sole_str = p_code + "tsd" + '0' + str(match_id) + "hg3535"
+            # odds_only = Helper.genearte_MD5(hash_str, pt)
+            # sole = Helper.genearte_MD5(sole_str, pt)
+            # double_key = ["match_id", "lg_id", "odds_code", "status", "sort", "p_code", "odds", "condition",
+            #               "odds_only", "sole", "source", "type", "team"]
+            # double_value = [match_id, league_id, "tsd", "0", 0, p_code, odd_even_even, '双',
+            #                 odds_only, sole, "hg3535", "0", ""]
+            # double_data = dict(zip(double_key, double_value))
+            # data_list.append(double_data)
+            #
+            # # half_odd_even_even
+            # hash_str = p_code + "tsd_h" + '0' + '双' + str(half_odd_even_even) + "hg3535" + str(match_id)
+            # sole_str = p_code + "tsd_h" + '0' + str(match_id) + "hg3535"
+            # odds_only = Helper.genearte_MD5(hash_str, pt)
+            # sole = Helper.genearte_MD5(sole_str, pt)
+            # half_double_key = ["match_id", "lg_id", "odds_code", "status", "sort", "p_code", "odds", "condition",
+            #                    "odds_only", "sole", "source", "type", "team"]
+            # half_double_value = [match_id, league_id, "tsd_h", "0", 0, p_code, half_odd_even_even, '双',
+            #                      odds_only, sole, "hg3535", "0", ""]
+            # half_double_data = dict(zip(half_double_key, half_double_value))
+            # data_list.append(half_double_data)
+            #
+            # # half_odd_even_odd
+            # hash_str = p_code + "tss_h" + '0' + '单' + str(half_odd_even_odd) + "hg3535" + str(match_id)
+            # sole_str = p_code + "tss_h" + '0' + str(match_id) + "hg3535"
+            # odds_only = Helper.genearte_MD5(hash_str, pt)
+            # sole = Helper.genearte_MD5(sole_str, pt)
+            # half_single_key = ["match_id", "lg_id", "odds_code", "status", "sort", "p_code", "odds", "condition",
+            #                    "odds_only", "sole", "source", "type", "team"]
+            # half_single_value = [match_id, league_id, "tss_h", "0", 0, p_code, half_odd_even_odd, '单', odds_only,
+            #                      sole, "hg3535", "0", ""]
+            # half_single_data = dict(zip(half_single_key, half_single_value))
+            # data_list.append(half_single_data)
+            #
+            # p_code = 'TG'
+            # # 总入球数 ---------------------------------------------------------------------------------------------------
+            # total_goals = item['total_goal']
+            # total_dict = {'tg0': '0-1', 'tg1': '2-3', 'tg2': '4-6', 'tg3': '7或以上', 'tg0_h': '0', "tg1_h": '1',
+            #               "tg2_h": '2', "tg3_h": '3或以上'}
+            # # 全场入球数 单双
+            # for key, value in total_goals.items():
+            #     hash_str = p_code + key + '0' + total_dict[key] + str(value) + "hg3535" + str(match_id)
+            #     sole_str = p_code + key + '0' + str(match_id) + "hg3535"
+            #     odds_only = Helper.genearte_MD5(hash_str, pt)
+            #     sole = Helper.genearte_MD5(sole_str, pt)
+            #     total_goals_key = ["match_id", "lg_id", "odds_code", "status", "sort", "p_code", "odds", "condition",
+            #                        "odds_only", "sole", "source", "type", "team"]
+            #     total_goals_value = [match_id, league_id, key, "0", 0, p_code, value, total_dict[key], odds_only,
+            #                          sole, "hg3535", "0", ""]
+            #     total_goals_data = dict(zip(total_goals_key, total_goals_value))
+            #     data_list.append(total_goals_data)
+            #
+            # # 全场半场 ---------------------------------------------------------------------------------------------------
+            # half_fulls = item['half_full']
+            # # p_code, p_id = get_pcode(corner_ball, 'half_full')
+            # p_code = 'HF'
+            # full_dict = {"hfhh": "主主", "hfhd": "主和", "hfhg": "主客", "hfdh": "和主",
+            #              "hfdd": "和和", "hfdg": "和客", "hfgh": "客主", "hfgd": "客和", "hfgg": "客客"}
+            # if half_fulls:
+            #     for key, value in half_fulls.items():
+            #         hash_str = p_code + key + '0' + full_dict[key] + str(value) + "hg3535" + str(match_id)
+            #         sole_str = p_code + key + '0' + str(match_id) + "hg3535"
+            #         odds_only = Helper.genearte_MD5(hash_str, pt)
+            #         sole = Helper.genearte_MD5(sole_str, pt)
+            #         half_fulls_key = ["match_id", "lg_id", "odds_code", "status", "sort", "p_code", "odds", "condition",
+            #                           "odds_only", "sole", "source", "type", "team"]
+            #         half_fulls_value = [match_id, league_id, key, "0", 0, p_code, value, full_dict[key], odds_only,
+            #                             sole, "hg3535", "0", ""]
+            #         half_fulls_data = dict(zip(half_fulls_key, half_fulls_value))
+            #         data_list.append(half_fulls_data)
+            #
+            # # 波胆-------------------------------------------------------------------------------------------------------
+            # p_code = 'B'
+            # bodan_datas = item['bodan_data']
+            # # p_code, p_id = get_pcode(corner_ball, 'bodan')
+            # bodan_dict = {"b10": "1-0", "b20": "2-0", "b21": "2-1", "b30": "3-0", "b31": "3-1", "b32": "3-2",
+            #               "b40": "4-0", "b41": "4-1", "b42": "4-2", "b43": "4-3", "b01": "0-1", "b02": "0-2",
+            #               "b12": "1-2", "b03": "0-3", "b13": "1-3", "b23": "2-3", "b04": "0-4", "b14": "1-4",
+            #               "b24": "2-4", "b34": "3-4", "b00": "0-0", "b11": "1-1", "b22": "2-2", "b33": "3-3",
+            #               "b44": "4-4", "bo": "其他", "b10_h": "1-0", "b20_h": "2-0", "b21_h": "2-1", "b30_h": "3-0",
+            #               "b31_h": "3-1", "b32_h": "3-2", "b01_h": "0-1", "b02_h": "0-2", "b12_h": "1-2", "b03_h": "0-3",
+            #               "b13_h": "1-3", "b23_h": "2-3", "b00_h": "0-0", "b11_h": "1-1", "b22_h": "2-2", "b33_h": "3-3",
+            #               "bo_h": "其他"}
+            # if bodan_datas:
+            #     for key, value in bodan_datas.items():
+            #         hash_str = p_code + key + '0' + bodan_dict[key] + str(value) + "hg3535" + str(match_id)
+            #         sole_str = p_code + key + '0' + str(match_id) + "hg3535"
+            #         odds_only = Helper.genearte_MD5(hash_str, pt)
+            #         sole = Helper.genearte_MD5(sole_str, pt)
+            #         bodan_dict_key = ["match_id", "lg_id", "odds_code", "status", "sort", "p_code", "odds", "condition",
+            #                           "odds_only", "sole", "source", "type", "team"]
+            #         bodan_dict_value = [match_id, league_id, key, "0", 0, p_code, value, bodan_dict[key], odds_only,
+            #                             sole, "hg3535", "0", ""]
+            #         bodan_dict_data = dict(zip(bodan_dict_key, bodan_dict_value))
+            #         data_list.append(bodan_dict_data)
+            #
+            # # 最先进球/最后进球 -------------------------------------------------------------------------------------------
+            # first_last_balls = item['first_last_ball']
+            # p_code = 'FLB'
+            # first_last_dict = {"flbfh": "最先进球", "flbfg": "最先进球", "flblh": "最后进球", "flblg": "最后进球", "flbn": "没有进球"}
+            # if first_last_balls:
+            #     for key, value in first_last_balls.items():
+            #         hash_str = p_code + key + '0' + first_last_dict[key] + str(value) + "hg3535" + str(match_id)
+            #         sole_str = p_code + key + '0' + str(match_id) + "hg3535"
+            #         odds_only = Helper.genearte_MD5(hash_str, pt)
+            #         sole = Helper.genearte_MD5(sole_str, pt)
+            #         first_last_balls_key = ["match_id", "lg_id", "odds_code", "status", "sort", "p_code", "odds",
+            #                                 "condition",
+            #                                 "odds_only", "sole", "source", "type", "team"]
+            #         first_last_balls_value = [match_id, league_id, key, "0", 0, p_code, value, first_last_dict[key],
+            #                                   odds_only,
+            #                                   sole, "hg3535", "0", ""]
+            #         first_last_balls_data = dict(zip(first_last_balls_key, first_last_balls_value))
+            #         data_list.append(first_last_balls_data)
+            #
+            # p_code = 'TB'
+            # # 球队得分全场,上半场
+            # full_dicts = item['full_data']
+            # half_dicts = item['half_data']
+            # full_dict_rules = item['full_data_rule']
+            # half_dict_rules = item['half_data_rule']
+            # if full_dicts:
+            #     for key, value in full_dicts.items():
+            #         hash_str = p_code + key + '0' + full_dict_rules[key] + str(value) + "hg3535" + str(match_id)
+            #         sole_str = p_code + key + '0' + str(match_id) + "hg3535"
+            #         odds_only = Helper.genearte_MD5(hash_str, pt)
+            #         sole = Helper.genearte_MD5(sole_str, pt)
+            #         full_dict_rules_key = ["match_id", "lg_id", "odds_code", "status", "sort", "p_code", "odds",
+            #                                "condition", "odds_only", "sole", "source", "type", "team"]
+            #         full_dict_rules_value = [match_id, league_id, key, "0", 0, p_code, value, full_dict_rules[key],
+            #                                  odds_only, sole, "hg3535", "0", ""]
+            #         full_dict_rules_data = dict(zip(full_dict_rules_key, full_dict_rules_value))
+            #         data_list.append(full_dict_rules_data)
+            #
+            # if half_dicts:
+            #     for key, value in half_dicts.items():
+            #         hash_str = p_code + key + '0' + half_dict_rules[key] + str(value) + "hg3535" + str(match_id)
+            #         sole_str = p_code + key + '0' + str(match_id) + "hg3535"
+            #         odds_only = Helper.genearte_MD5(hash_str, pt)
+            #         sole = Helper.genearte_MD5(sole_str, pt)
+            #         half_dicts_key = ["match_id", "lg_id", "odds_code", "status", "sort", "p_code", "odds",
+            #                           "condition", "odds_only", "sole", "source", "type", "team"]
+            #         half_dicts_value = [match_id, league_id, key, "0", 0, p_code, value, half_dict_rules[key],
+            #                             odds_only, sole, "hg3535", "0", ""]
+            #         half_dicts_data = dict(zip(half_dicts_key, half_dicts_value))
+            #         data_list.append(half_dicts_data)
             p_code = 'CB'
             horn_ou_dict = item['horn_ou_dict']
             horn_ou_dict_rule = item['horn_ou_dict_rule']

+ 402 - 403
hg3535/pipeline/zuqiu.py

@@ -567,7 +567,6 @@ class Zuqiupipeline(object):
                 logging.warning('足球详细赔率接口异常, {}'.format(res))
         else:
             logger.info('足球详细赔率列表为空')
-
         # 角球处理分割线---------------------------------------------------------------------------------------------------
         horn_team = item['horn_team']
         if horn_team:
@@ -601,408 +600,408 @@ class Zuqiupipeline(object):
                     logger.warning(match_dict)
             else:
                 logger.info('足球角球, 赛事已存在,不提交')
-
-            p_code = "GS"
-            half_size_guest = item["half_size_guest"]
-            half_size_guest_rule = item["half_size_guest_rule"]
-            half_size_home = item["half_size_home"]
-            half_size_home_rule = item["half_size_home_rule"]
-            data_list = []
-            odds_onlys = []
-            # half_size_guest
-            for index, value in enumerate(half_size_guest):
-                hash_str = p_code + "gss_h" + str(index) + str(half_size_guest_rule[index]) + str(
-                    value) + "hg3535" + str(match_id)
-                sole_str = p_code + "gss_h" + str(index) + str(match_id) + "hg3535"
-                odds_only = Helper.genearte_MD5(hash_str, pt)
-                sole = Helper.genearte_MD5(sole_str, pt)
-                half_size_guest_key = ["match_id", "lg_id", "odds_code", "status", "sort", "p_code", "odds",
-                                       "condition",
-                                       "odds_only", "sole", "source", "type", "team"]
-                condition = half_size_guest_rule[index]
-                half_size_guest_value = [match_id, league_id, "gss_h", "0", index, p_code, value, condition,
-                                         odds_only, sole, "hg3535", "0", ""]
-                half_size_guest_data = dict(zip(half_size_guest_key, half_size_guest_value))
-                data_list.append(half_size_guest_data)
-            # half_size_home
-            for index, value in enumerate(half_size_home):
-                hash_str = p_code + "gsb_h" + str(index) + str(half_size_home_rule[index]) + str(
-                    value) + "hg3535" + str(match_id)
-                sole_str = p_code + "gsb_h" + str(index) + str(match_id) + "hg3535"
-                odds_only = Helper.genearte_MD5(hash_str, pt)
-                sole = Helper.genearte_MD5(sole_str, pt)
-                half_size_home_key = ["match_id", "lg_id", "odds_code", "status", "sort", "p_code", "odds", "condition",
-                                      "odds_only", "sole", "source", "type", "team"]
-                condition = half_size_home_rule[index]
-                half_size_home_value = [match_id, league_id, "gsb_h", "0", index, p_code, value, condition,
-                                        odds_only, sole, "hg3535", "0", ""]
-                half_size_home_data = dict(zip(half_size_home_key, half_size_home_value))
-                data_list.append(half_size_home_data)
-
-            # 全场场大小
-            size_guest = item["size_guest"]
-            size_guest_rule = item["size_guest_rule"]
-            size_home = item["size_home"]
-            size_home_rule = item["size_home_rule"]
-            # size_home
-            for index, value in enumerate(size_home):
-                hash_str = p_code + "gsb" + str(index) + str(size_home_rule[index]) + str(value) + "hg3535" + str(
-                    match_id)
-                sole_str = p_code + "gsb" + str(index) + str(match_id) + "hg3535"
-                odds_only = Helper.genearte_MD5(hash_str, pt)
-                sole = Helper.genearte_MD5(sole_str, pt)
-                size_home_key = ["match_id", "lg_id", "odds_code", "status", "sort", "p_code", "odds", "condition",
-                                 "odds_only", "sole", "source", "type", "team"]
-                condition = size_home_rule[index]
-                size_home_value = [match_id, league_id, "gsb", "0", index, p_code, value, condition, odds_only,
-                                   sole, "hg3535", "0", ""]
-                size_home_data = dict(zip(size_home_key, size_home_value))
-                data_list.append(size_home_data)
-            # size_guest
-            for index, value in enumerate(size_guest):
-                hash_str = p_code + "gss" + str(index) + str(size_guest_rule[index]) + str(value) + "hg3535" + str(
-                    match_id)
-                sole_str = p_code + "gss" + str(index) + str(match_id) + "hg3535"
-                odds_only = Helper.genearte_MD5(hash_str, pt)
-                sole = Helper.genearte_MD5(sole_str, pt)
-                size_guest_key = ["match_id", "lg_id", "odds_code", "status", "sort", "p_code", "odds", "condition",
-                                  "odds_only", "sole", "source", "type", "team"]
-                condition = size_guest_rule[index]
-                size_guest_value = [match_id, league_id, "gss", "0", index, p_code, value, condition, odds_only,
-                                    sole, "hg3535", "0", ""]
-                size_home_data = dict(zip(size_guest_key, size_guest_value))
-                data_list.append(size_home_data)
-
-            p_code = 'CO'
-            half_concede_home_rule = item["half_concede_home_rule"]
-            half_concede_home = item["half_concede_home"]
-            half_concede_guest_rule = item["half_concede_guest_rule"]
-            half_concede_guest = item["half_concede_guest"]
-            # half_concede_home
-            if half_concede_guest:
-                for index, value in enumerate(half_concede_guest):
-                    hash_str = p_code + "cog_h" + str(index) + str(half_concede_guest_rule[index]) + str(
-                        value) + "hg3535" + str(match_id)
-                    sole_str = p_code + "cog_h" + str(index) + str(match_id) + "hg3535"
-                    odds_only = Helper.genearte_MD5(hash_str, pt)
-                    sole = Helper.genearte_MD5(sole_str, pt)
-                    half_concede_guest_key = ["match_id", "lg_id", "odds_code", "status", "sort", "p_code", "odds",
-                                              "condition",
-                                              "odds_only", "sole", "source", "type", "team"]
-                    condition = half_concede_guest_rule[index]
-                    half_concede_guest_value = [match_id, league_id, "cog_h", "0", index, p_code, value, condition,
-                                                odds_only, sole, "hg3535", "0", ""]
-                    half_concede_guest_data = dict(zip(half_concede_guest_key, half_concede_guest_value))
-                    data_list.append(half_concede_guest_data)
-
-            # half_concede_home
-            if half_concede_home:
-                for index, value in enumerate(half_concede_home):
-                    hash_str = p_code + "coh_h" + str(index) + str(half_concede_home_rule[index]) + str(
-                        value) + "hg3535" + str(match_id)
-                    sole_str = p_code + "coh_h" + str(index) + str(match_id) + "hg3535"
-                    odds_only = Helper.genearte_MD5(hash_str, pt)
-                    sole = Helper.genearte_MD5(sole_str, pt)
-                    half_concede_home_key = ["match_id", "lg_id", "odds_code", "status", "sort", "p_code", "odds",
-                                             "condition",
-                                             "odds_only", "sole", "source", "type", "team"]
-                    condition = half_concede_home_rule[index]
-                    half_concede_home_value = [match_id, league_id, "coh_h", "0", index, p_code, value, condition,
-                                               odds_only, sole, "hg3535", "0", ""]
-                    half_concede_home_data = dict(zip(half_concede_home_key, half_concede_home_value))
-                    data_list.append(half_concede_home_data)
-
-            concede_guest = item["concede_guest"]
-            concede_guest_rule = item["concede_guest_rule"]
-            concede_home = item["concede_home"]
-            concede_home_rule = item["concede_home_rule"]
-            # concede_guest
-            if concede_guest:
-                for index, value in enumerate(concede_guest):
-                    hash_str = p_code + "cog" + str(index) + str(concede_guest_rule[index]) + str(
-                        value) + "hg3535" + str(match_id)
-                    sole_str = p_code + "cog" + str(index) + str(match_id) + "hg3535"
-                    odds_only = Helper.genearte_MD5(hash_str, pt)
-                    sole = Helper.genearte_MD5(sole_str, pt)
-                    concede_guest_key = ["match_id", "lg_id", "odds_code", "status", "sort", "p_code", "odds",
-                                         "condition",
-                                         "odds_only", "sole", "source", "type", "team"]
-                    condition = concede_guest_rule[index]
-                    concede_guest_value = [match_id, league_id, "cog", "0", index, p_code, value, condition,
-                                           odds_only, sole, "hg3535", "0", ""]
-                    concede_guest_data = dict(zip(concede_guest_key, concede_guest_value))
-                    data_list.append(concede_guest_data)
-            # concede_home
-            if concede_home:
-                for index, value in enumerate(concede_home):
-                    hash_str = p_code + "coh" + str(index) + str(concede_home_rule[index]) + str(
-                        value) + "hg3535" + str(match_id)
-                    sole_str = p_code + "coh" + str(index) + str(match_id) + "hg3535"
-                    odds_only = Helper.genearte_MD5(hash_str, pt)
-                    sole = Helper.genearte_MD5(sole_str, pt)
-                    concede_home_key = ["match_id", "lg_id", "odds_code", "status", "sort", "p_code", "odds",
-                                        "condition",
-                                        "odds_only", "sole", "source", "type", "team"]
-                    condition = concede_home_rule[index]
-                    concede_home_value = [match_id, league_id, "coh", "0", index, p_code, value, condition, odds_only,
-                                          sole, "hg3535", "0", ""]
-                    concede_guest_data = dict(zip(concede_home_key, concede_home_value))
-                    data_list.append(concede_guest_data)
-
-            # 独赢----------------------------------------------------------------------------------------------------------
-            p_code = 'C'
-            half_capot_home = item["half_capot_home"]
-            half_capot_guest = item["half_capot_guest"]
-            half_capot_dogfall = item["half_capot_dogfall"]
-            capot_home = item["capot_home"]
-            capot_guest = item["capot_guest"]
-            capot_dogfall = item["capot_dogfall"]
-
-            # half_capot_home
-            hash_str = p_code + "ch_h" + '0' + '1' + str(half_capot_home) + "hg3535" + str(match_id)
-            sole_str = p_code + "ch_h" + '0' + str(match_id) + "hg3535"
-            odds_only = Helper.genearte_MD5(hash_str, pt)
-            sole = Helper.genearte_MD5(sole_str, pt)
-            half_capot_home_key = ["match_id", "lg_id", "odds_code", "status", "sort", "p_code", "odds", "condition",
-                                   "odds_only", "sole", "source", "type", "team"]
-            half_capot_home_value = [match_id, league_id, "ch_h", "0", 0, p_code, half_capot_home, '1',
-                                     odds_only, sole, "hg3535", "0", ""]
-            half_capot_homet_data = dict(zip(half_capot_home_key, half_capot_home_value))
-            data_list.append(half_capot_homet_data)
-
-            # half_capot_guest
-            hash_str = p_code + "cg_h" + '0' + '2' + str(half_capot_guest) + "hg3535" + str(match_id)
-            sole_str = p_code + "cg_h" + '0' + str(match_id) + "hg3535"
-            odds_only = Helper.genearte_MD5(hash_str, pt)
-            sole = Helper.genearte_MD5(sole_str, pt)
-            half_capot_guest_key = ["match_id", "lg_id", "odds_code", "status", "sort", "p_code", "odds", "condition",
-                                    "odds_only", "sole", "source", "type", "team"]
-            half_capot_guest_value = [match_id, league_id, "cg_h", "0", 0, p_code, half_capot_guest, '2',
-                                      odds_only, sole, "hg3535", "0", ""]
-            half_capot_guest_data = dict(zip(half_capot_guest_key, half_capot_guest_value))
-            data_list.append(half_capot_guest_data)
-
-            # half_capot_dogfall
-            hash_str = p_code + "cd_h" + '0' + 'X' + str(half_capot_dogfall) + "hg3535" + str(match_id)
-            sole_str = p_code + "cd_h" + '0' + str(match_id) + "hg3535"
-            odds_only = Helper.genearte_MD5(hash_str, pt)
-            sole = Helper.genearte_MD5(sole_str, pt)
-            half_capot_dogfall_key = ["match_id", "lg_id", "odds_code", "status", "sort", "p_code", "odds", "condition",
-                                      "odds_only", "sole", "source", "type", "team"]
-            half_capot_dogfall_value = [match_id, league_id, "cd_h", "0", 0, p_code, half_capot_dogfall, 'X',
-                                        odds_only, sole, "hg3535", "0", ""]
-            half_capot_dogfall_data = dict(zip(half_capot_dogfall_key, half_capot_dogfall_value))
-            data_list.append(half_capot_dogfall_data)
-
-            # capot_dogfall
-            hash_str = p_code + "cd" + '0' + 'X' + str(capot_dogfall) + "hg3535" + str(match_id)
-            sole_str = p_code + "cd" + '0' + str(match_id) + "hg3535"
-            odds_only = Helper.genearte_MD5(hash_str, pt)
-            sole = Helper.genearte_MD5(sole_str, pt)
-            capot_dogfall_key = ["match_id", "lg_id", "odds_code", "status", "sort", "p_code", "odds", "condition",
-                                 "odds_only", "sole", "source", "type", "team"]
-            capot_dogfall_value = [match_id, league_id, "cd", "0", 0, p_code, capot_dogfall, 'X', odds_only,
-                                   sole, "hg3535", "0", ""]
-            capot_dogfall_data = dict(zip(capot_dogfall_key, capot_dogfall_value))
-            data_list.append(capot_dogfall_data)
-
-            # capot_home
-            hash_str = p_code + "ch" + '0' + '1' + str(capot_home) + "hg3535" + str(match_id)
-            sole_str = p_code + "ch" + '0' + str(match_id) + "hg3535"
-            odds_only = Helper.genearte_MD5(hash_str, pt)
-            sole = Helper.genearte_MD5(sole_str, pt)
-            capot_home_key = ["match_id", "lg_id", "odds_code", "status", "sort", "p_code", "odds", "condition",
-                              "odds_only", "sole", "source", "type", "team"]
-            capot_home_value = [match_id, league_id, "ch", "0", 0, p_code, capot_home, '1',
-                                odds_only, sole, "hg3535", "0", ""]
-            capot_homet_data = dict(zip(capot_home_key, capot_home_value))
-            data_list.append(capot_homet_data)
-
-            # capot_guest
-            hash_str = p_code + "cg" + '0' + '2' + str(capot_guest) + "hg3535" + str(match_id)
-            sole_str = p_code + "cg" + '0' + str(match_id) + "hg3535"
-            odds_only = Helper.genearte_MD5(hash_str, pt)
-            sole = Helper.genearte_MD5(sole_str, pt)
-            capot_guest_key = ["match_id", "lg_id", "odds_code", "status", "sort", "p_code", "odds", "condition",
-                               "odds_only", "sole", "source", "type", "team"]
-            capot_guest_value = [match_id, league_id, "cg", "0", 0, p_code, capot_guest, '2',
-                                 odds_only, sole, "hg3535", "0", ""]
-            capot_guest_data = dict(zip(capot_guest_key, capot_guest_value))
-            data_list.append(capot_guest_data)
-
-            # 入球数单双-----------------------------------------------------------------------------------------------------
-            # p_code, p_id = get_pcode(corner_ball, 'two_sides')
-            p_code = 'TS'
-            odd_even_odd = item["odd_even_odd"]
-            odd_even_even = item["odd_even_even"]
-            half_odd_even_odd = item["half_odd_even_odd"]
-            half_odd_even_even = item["half_odd_even_even"]
-
-            # odd_even_odd
-            hash_str = p_code + "tss" + '0' + '单' + str(odd_even_odd) + "hg3535" + str(match_id)
-            sole_str = p_code + "tss" + '0' + str(match_id) + "hg3535"
-            odds_only = Helper.genearte_MD5(hash_str, pt)
-            sole = Helper.genearte_MD5(sole_str, pt)
-            single_key = ["match_id", "lg_id", "odds_code", "status", "sort", "p_code", "odds", "condition",
-                          "odds_only", "sole", "source", "type", "team"]
-            single_value = [match_id, league_id, "tss", "0", 0, p_code, odd_even_odd, '单',
-                            odds_only, sole, "hg3535", "0", ""]
-            single_data = dict(zip(single_key, single_value))
-            data_list.append(single_data)
-
-            # odd_even_even
-            hash_str = p_code + "tsd" + '0' + '双' + str(odd_even_even) + "hg3535" + str(match_id)
-            sole_str = p_code + "tsd" + '0' + str(match_id) + "hg3535"
-            odds_only = Helper.genearte_MD5(hash_str, pt)
-            sole = Helper.genearte_MD5(sole_str, pt)
-            double_key = ["match_id", "lg_id", "odds_code", "status", "sort", "p_code", "odds", "condition",
-                          "odds_only", "sole", "source", "type", "team"]
-            double_value = [match_id, league_id, "tsd", "0", 0, p_code, odd_even_even, '双',
-                            odds_only, sole, "hg3535", "0", ""]
-            double_data = dict(zip(double_key, double_value))
-            data_list.append(double_data)
-
-            # half_odd_even_even
-            hash_str = p_code + "tsd_h" + '0' + '双' + str(half_odd_even_even) + "hg3535" + str(match_id)
-            sole_str = p_code + "tsd_h" + '0' + str(match_id) + "hg3535"
-            odds_only = Helper.genearte_MD5(hash_str, pt)
-            sole = Helper.genearte_MD5(sole_str, pt)
-            half_double_key = ["match_id", "lg_id", "odds_code", "status", "sort", "p_code", "odds", "condition",
-                               "odds_only", "sole", "source", "type", "team"]
-            half_double_value = [match_id, league_id, "tsd_h", "0", 0, p_code, half_odd_even_even, '双',
-                                 odds_only, sole, "hg3535", "0", ""]
-            half_double_data = dict(zip(half_double_key, half_double_value))
-            data_list.append(half_double_data)
-
-            # half_odd_even_odd
-            hash_str = p_code + "tss_h" + '0' + '单' + str(half_odd_even_odd) + "hg3535" + str(match_id)
-            sole_str = p_code + "tss_h" + '0' + str(match_id) + "hg3535"
-            odds_only = Helper.genearte_MD5(hash_str, pt)
-            sole = Helper.genearte_MD5(sole_str, pt)
-            half_single_key = ["match_id", "lg_id", "odds_code", "status", "sort", "p_code", "odds", "condition",
-                               "odds_only", "sole", "source", "type", "team"]
-            half_single_value = [match_id, league_id, "tss_h", "0", 0, p_code, half_odd_even_odd, '单', odds_only,
-                                 sole, "hg3535", "0", ""]
-            half_single_data = dict(zip(half_single_key, half_single_value))
-            data_list.append(half_single_data)
-
-            # 总入球数 ---------------------------------------------------------------------------------------------------
-            p_code = 'TG'
-            total_goals = item['total_goal']
-            total_dict = {'tg0': '0-1', 'tg1': '2-3', 'tg2': '4-6', 'tg3': '7或以上', 'tg0_h': '0', "tg1_h": '1',
-                          "tg2_h": '2', "tg3_h": '3或以上'}
-            # 全场入球数 单双
-            # 上半场入球数 单双
-            for key, value in total_goals.items():
-                hash_str = p_code + key + '0' + total_dict[key] + str(value) + "hg3535" + str(match_id)
-                sole_str = p_code + key + '0' + str(match_id) + "hg3535"
-                odds_only = Helper.genearte_MD5(hash_str, pt)
-                sole = Helper.genearte_MD5(sole_str, pt)
-                total_goals_key = ["match_id", "lg_id", "odds_code", "status", "sort", "p_code", "odds", "condition",
-                                   "odds_only", "sole", "source", "type", "team"]
-                total_goals_value = [match_id, league_id, key, "0", 0, p_code, value, total_dict[key], odds_only,
-                                     sole, "hg3535", "0", ""]
-                total_goals_data = dict(zip(total_goals_key, total_goals_value))
-                data_list.append(total_goals_data)
-
-            # 全场半场 ---------------------------------------------------------------------------------------------------
-            half_fulls = item['half_full']
-            p_code = 'HF'
-            full_dict = {"hfhh": "主主", "hfhd": "主和", "hfhg": "主客", "hfdh": "和主",
-                         "hfdd": "和和", "hfdg": "和客", "hfgh": "客主", "hfgd": "客和", "hfgg": "客客"}
-            if half_fulls:
-                for key, value in half_fulls.items():
-                    hash_str = p_code + key + '0' + full_dict[key] + str(value) + "hg3535" + str(match_id)
-                    sole_str = p_code + key + '0' + str(match_id) + "hg3535"
-                    odds_only = Helper.genearte_MD5(hash_str, pt)
-                    sole = Helper.genearte_MD5(sole_str, pt)
-                    half_fulls_key = ["match_id", "lg_id", "odds_code", "status", "sort", "p_code", "odds", "condition",
-                                      "odds_only", "sole", "source", "type", "team"]
-                    half_fulls_value = [match_id, league_id, key, "0", 0, p_code, value, full_dict[key], odds_only,
-                                        sole, "hg3535", "0", ""]
-                    half_fulls_data = dict(zip(half_fulls_key, half_fulls_value))
-                    data_list.append(half_fulls_data)
-
-            # 波胆-----------------------------------------------------------------------------------------------------------
-            bodan_datas = item['bodan_data']
-            p_code = 'B'
-            bodan_dict = {"b10": "1-0", "b20": "2-0", "b21": "2-1", "b30": "3-0", "b31": "3-1", "b32": "3-2",
-                          "b40": "4-0", "b41": "4-1", "b42": "4-2", "b43": "4-3", "b01": "0-1", "b02": "0-2",
-                          "b12": "1-2", "b03": "0-3", "b13": "1-3", "b23": "2-3", "b04": "0-4", "b14": "1-4",
-                          "b24": "2-4", "b34": "3-4", "b00": "0-0", "b11": "1-1", "b22": "2-2", "b33": "3-3",
-                          "b44": "4-4", "bo": "其他", "b10_h": "1-0", "b20_h": "2-0", "b21_h": "2-1", "b30_h": "3-0",
-                          "b31_h": "3-1", "b32_h": "3-2", "b01_h": "0-1", "b02_h": "0-2", "b12_h": "1-2",
-                          "b03_h": "0-3",
-                          "b13_h": "1-3", "b23_h": "2-3", "b00_h": "0-0", "b11_h": "1-1", "b22_h": "2-2",
-                          "b33_h": "3-3",
-                          "bo_h": "其他"}
-            if bodan_datas:
-                for key, value in bodan_datas.items():
-                    hash_str = p_code + key + '0' + bodan_dict[key] + str(value) + "hg3535" + str(match_id)
-                    sole_str = p_code + key + '0' + str(match_id) + "hg3535"
-                    odds_only = Helper.genearte_MD5(hash_str, pt)
-                    sole = Helper.genearte_MD5(sole_str, pt)
-                    bodan_dict_key = ["match_id", "lg_id", "odds_code", "status", "sort", "p_code", "odds", "condition",
-                                      "odds_only", "sole", "source", "type", "team"]
-                    bodan_dict_value = [match_id, league_id, key, "0", 0, p_code, value, bodan_dict[key], odds_only,
-                                        sole, "hg3535", "0", ""]
-                    bodan_dict_data = dict(zip(bodan_dict_key, bodan_dict_value))
-                    data_list.append(bodan_dict_data)
-
-            # 最先进球/最后进球 ----------------------------------------------------------------------------------------------
-            first_last_balls = item['first_last_ball']
-            # p_code, p_id = get_pcode(corner_ball, 'first_last_ball')
-            p_code = 'FLB'
-            first_last_dict = {"flbfh": "最先进球", "flbfg": "最先进球", "flblh": "最后进球", "flblg": "最后进球", "flbn": "没有进球"}
-            if first_last_balls:
-                for key, value in first_last_balls.items():
-                    hash_str = p_code + key + '0' + first_last_dict[key] + str(value) + "hg3535" + str(match_id)
-                    sole_str = p_code + key + '0' + str(match_id) + "hg3535"
-                    odds_only = Helper.genearte_MD5(hash_str, pt)
-                    sole = Helper.genearte_MD5(sole_str, pt)
-                    first_last_balls_key = ["match_id", "lg_id", "odds_code", "status", "sort", "p_code", "odds",
-                                            "condition",
-                                            "odds_only", "sole", "source", "type", "team"]
-                    first_last_balls_value = [match_id, league_id, key, "0", 0, p_code, value, first_last_dict[key],
-                                              odds_only,
-                                              sole, "hg3535", "0", ""]
-                    first_last_balls_data = dict(zip(first_last_balls_key, first_last_balls_value))
-                    data_list.append(first_last_balls_data)
-
-            # 球队得分大小
-            p_code = 'TB'
-            # 全场
-            full_dicts = item['full_data']
-            # 上半场
-            half_dicts = item['half_data']
-            full_dict_rules = item['full_data_rule']
-            half_dict_rules = item['half_data_rule']
-            if full_dicts:
-                for key, value in full_dicts.items():
-                    hash_str = p_code + key + '0' + full_dict_rules[key] + str(value) + "hg3535" + str(match_id)
-                    sole_str = p_code + key + '0' + str(match_id) + "hg3535"
-                    odds_only = Helper.genearte_MD5(hash_str, pt)
-                    sole = Helper.genearte_MD5(sole_str, pt)
-                    full_dict_rules_key = ["match_id", "lg_id", "odds_code", "status", "sort", "p_code", "odds",
-                                           "condition", "odds_only", "sole", "source", "type", "team"]
-                    full_dict_rules_value = [match_id, league_id, key, "0", 0, p_code, value, full_dict_rules[key],
-                                             odds_only, sole, "hg3535", "0", ""]
-                    full_dict_rules_data = dict(zip(full_dict_rules_key, full_dict_rules_value))
-                    data_list.append(full_dict_rules_data)
-
-            if half_dicts:
-                for key, value in half_dicts.items():
-                    hash_str = p_code + key + '0' + half_dict_rules[key] + str(value) + "hg3535" + str(match_id)
-                    sole_str = p_code + key + '0' + str(match_id) + "hg3535"
-                    odds_only = Helper.genearte_MD5(hash_str, pt)
-                    sole = Helper.genearte_MD5(sole_str, pt)
-                    half_dicts_key = ["match_id", "lg_id", "odds_code", "status", "sort", "p_code", "odds",
-                                      "condition", "odds_only", "sole", "source", "type", "team"]
-                    half_dicts_value = [match_id, league_id, key, "0", 0, p_code, value, half_dict_rules[key],
-                                        odds_only, sole, "hg3535", "0", ""]
-                    half_dicts_data = dict(zip(half_dicts_key, half_dicts_value))
-                    data_list.append(half_dicts_data)
-
+        #
+        #     p_code = "GS"
+        #     half_size_guest = item["half_size_guest"]
+        #     half_size_guest_rule = item["half_size_guest_rule"]
+        #     half_size_home = item["half_size_home"]
+        #     half_size_home_rule = item["half_size_home_rule"]
+        #     data_list = []
+        #     odds_onlys = []
+        #     # half_size_guest
+        #     for index, value in enumerate(half_size_guest):
+        #         hash_str = p_code + "gss_h" + str(index) + str(half_size_guest_rule[index]) + str(
+        #             value) + "hg3535" + str(match_id)
+        #         sole_str = p_code + "gss_h" + str(index) + str(match_id) + "hg3535"
+        #         odds_only = Helper.genearte_MD5(hash_str, pt)
+        #         sole = Helper.genearte_MD5(sole_str, pt)
+        #         half_size_guest_key = ["match_id", "lg_id", "odds_code", "status", "sort", "p_code", "odds",
+        #                                "condition",
+        #                                "odds_only", "sole", "source", "type", "team"]
+        #         condition = half_size_guest_rule[index]
+        #         half_size_guest_value = [match_id, league_id, "gss_h", "0", index, p_code, value, condition,
+        #                                  odds_only, sole, "hg3535", "0", ""]
+        #         half_size_guest_data = dict(zip(half_size_guest_key, half_size_guest_value))
+        #         data_list.append(half_size_guest_data)
+        #     # half_size_home
+        #     for index, value in enumerate(half_size_home):
+        #         hash_str = p_code + "gsb_h" + str(index) + str(half_size_home_rule[index]) + str(
+        #             value) + "hg3535" + str(match_id)
+        #         sole_str = p_code + "gsb_h" + str(index) + str(match_id) + "hg3535"
+        #         odds_only = Helper.genearte_MD5(hash_str, pt)
+        #         sole = Helper.genearte_MD5(sole_str, pt)
+        #         half_size_home_key = ["match_id", "lg_id", "odds_code", "status", "sort", "p_code", "odds", "condition",
+        #                               "odds_only", "sole", "source", "type", "team"]
+        #         condition = half_size_home_rule[index]
+        #         half_size_home_value = [match_id, league_id, "gsb_h", "0", index, p_code, value, condition,
+        #                                 odds_only, sole, "hg3535", "0", ""]
+        #         half_size_home_data = dict(zip(half_size_home_key, half_size_home_value))
+        #         data_list.append(half_size_home_data)
+        #
+        #     # 全场场大小
+        #     size_guest = item["size_guest"]
+        #     size_guest_rule = item["size_guest_rule"]
+        #     size_home = item["size_home"]
+        #     size_home_rule = item["size_home_rule"]
+        #     # size_home
+        #     for index, value in enumerate(size_home):
+        #         hash_str = p_code + "gsb" + str(index) + str(size_home_rule[index]) + str(value) + "hg3535" + str(
+        #             match_id)
+        #         sole_str = p_code + "gsb" + str(index) + str(match_id) + "hg3535"
+        #         odds_only = Helper.genearte_MD5(hash_str, pt)
+        #         sole = Helper.genearte_MD5(sole_str, pt)
+        #         size_home_key = ["match_id", "lg_id", "odds_code", "status", "sort", "p_code", "odds", "condition",
+        #                          "odds_only", "sole", "source", "type", "team"]
+        #         condition = size_home_rule[index]
+        #         size_home_value = [match_id, league_id, "gsb", "0", index, p_code, value, condition, odds_only,
+        #                            sole, "hg3535", "0", ""]
+        #         size_home_data = dict(zip(size_home_key, size_home_value))
+        #         data_list.append(size_home_data)
+        #     # size_guest
+        #     for index, value in enumerate(size_guest):
+        #         hash_str = p_code + "gss" + str(index) + str(size_guest_rule[index]) + str(value) + "hg3535" + str(
+        #             match_id)
+        #         sole_str = p_code + "gss" + str(index) + str(match_id) + "hg3535"
+        #         odds_only = Helper.genearte_MD5(hash_str, pt)
+        #         sole = Helper.genearte_MD5(sole_str, pt)
+        #         size_guest_key = ["match_id", "lg_id", "odds_code", "status", "sort", "p_code", "odds", "condition",
+        #                           "odds_only", "sole", "source", "type", "team"]
+        #         condition = size_guest_rule[index]
+        #         size_guest_value = [match_id, league_id, "gss", "0", index, p_code, value, condition, odds_only,
+        #                             sole, "hg3535", "0", ""]
+        #         size_home_data = dict(zip(size_guest_key, size_guest_value))
+        #         data_list.append(size_home_data)
+        #
+        #     p_code = 'CO'
+        #     half_concede_home_rule = item["half_concede_home_rule"]
+        #     half_concede_home = item["half_concede_home"]
+        #     half_concede_guest_rule = item["half_concede_guest_rule"]
+        #     half_concede_guest = item["half_concede_guest"]
+        #     # half_concede_home
+        #     if half_concede_guest:
+        #         for index, value in enumerate(half_concede_guest):
+        #             hash_str = p_code + "cog_h" + str(index) + str(half_concede_guest_rule[index]) + str(
+        #                 value) + "hg3535" + str(match_id)
+        #             sole_str = p_code + "cog_h" + str(index) + str(match_id) + "hg3535"
+        #             odds_only = Helper.genearte_MD5(hash_str, pt)
+        #             sole = Helper.genearte_MD5(sole_str, pt)
+        #             half_concede_guest_key = ["match_id", "lg_id", "odds_code", "status", "sort", "p_code", "odds",
+        #                                       "condition",
+        #                                       "odds_only", "sole", "source", "type", "team"]
+        #             condition = half_concede_guest_rule[index]
+        #             half_concede_guest_value = [match_id, league_id, "cog_h", "0", index, p_code, value, condition,
+        #                                         odds_only, sole, "hg3535", "0", ""]
+        #             half_concede_guest_data = dict(zip(half_concede_guest_key, half_concede_guest_value))
+        #             data_list.append(half_concede_guest_data)
+        #
+        #     # half_concede_home
+        #     if half_concede_home:
+        #         for index, value in enumerate(half_concede_home):
+        #             hash_str = p_code + "coh_h" + str(index) + str(half_concede_home_rule[index]) + str(
+        #                 value) + "hg3535" + str(match_id)
+        #             sole_str = p_code + "coh_h" + str(index) + str(match_id) + "hg3535"
+        #             odds_only = Helper.genearte_MD5(hash_str, pt)
+        #             sole = Helper.genearte_MD5(sole_str, pt)
+        #             half_concede_home_key = ["match_id", "lg_id", "odds_code", "status", "sort", "p_code", "odds",
+        #                                      "condition",
+        #                                      "odds_only", "sole", "source", "type", "team"]
+        #             condition = half_concede_home_rule[index]
+        #             half_concede_home_value = [match_id, league_id, "coh_h", "0", index, p_code, value, condition,
+        #                                        odds_only, sole, "hg3535", "0", ""]
+        #             half_concede_home_data = dict(zip(half_concede_home_key, half_concede_home_value))
+        #             data_list.append(half_concede_home_data)
+        #
+        #     concede_guest = item["concede_guest"]
+        #     concede_guest_rule = item["concede_guest_rule"]
+        #     concede_home = item["concede_home"]
+        #     concede_home_rule = item["concede_home_rule"]
+        #     # concede_guest
+        #     if concede_guest:
+        #         for index, value in enumerate(concede_guest):
+        #             hash_str = p_code + "cog" + str(index) + str(concede_guest_rule[index]) + str(
+        #                 value) + "hg3535" + str(match_id)
+        #             sole_str = p_code + "cog" + str(index) + str(match_id) + "hg3535"
+        #             odds_only = Helper.genearte_MD5(hash_str, pt)
+        #             sole = Helper.genearte_MD5(sole_str, pt)
+        #             concede_guest_key = ["match_id", "lg_id", "odds_code", "status", "sort", "p_code", "odds",
+        #                                  "condition",
+        #                                  "odds_only", "sole", "source", "type", "team"]
+        #             condition = concede_guest_rule[index]
+        #             concede_guest_value = [match_id, league_id, "cog", "0", index, p_code, value, condition,
+        #                                    odds_only, sole, "hg3535", "0", ""]
+        #             concede_guest_data = dict(zip(concede_guest_key, concede_guest_value))
+        #             data_list.append(concede_guest_data)
+        #     # concede_home
+        #     if concede_home:
+        #         for index, value in enumerate(concede_home):
+        #             hash_str = p_code + "coh" + str(index) + str(concede_home_rule[index]) + str(
+        #                 value) + "hg3535" + str(match_id)
+        #             sole_str = p_code + "coh" + str(index) + str(match_id) + "hg3535"
+        #             odds_only = Helper.genearte_MD5(hash_str, pt)
+        #             sole = Helper.genearte_MD5(sole_str, pt)
+        #             concede_home_key = ["match_id", "lg_id", "odds_code", "status", "sort", "p_code", "odds",
+        #                                 "condition",
+        #                                 "odds_only", "sole", "source", "type", "team"]
+        #             condition = concede_home_rule[index]
+        #             concede_home_value = [match_id, league_id, "coh", "0", index, p_code, value, condition, odds_only,
+        #                                   sole, "hg3535", "0", ""]
+        #             concede_guest_data = dict(zip(concede_home_key, concede_home_value))
+        #             data_list.append(concede_guest_data)
+        #
+        #     # 独赢----------------------------------------------------------------------------------------------------------
+        #     p_code = 'C'
+        #     half_capot_home = item["half_capot_home"]
+        #     half_capot_guest = item["half_capot_guest"]
+        #     half_capot_dogfall = item["half_capot_dogfall"]
+        #     capot_home = item["capot_home"]
+        #     capot_guest = item["capot_guest"]
+        #     capot_dogfall = item["capot_dogfall"]
+        #
+        #     # half_capot_home
+        #     hash_str = p_code + "ch_h" + '0' + '1' + str(half_capot_home) + "hg3535" + str(match_id)
+        #     sole_str = p_code + "ch_h" + '0' + str(match_id) + "hg3535"
+        #     odds_only = Helper.genearte_MD5(hash_str, pt)
+        #     sole = Helper.genearte_MD5(sole_str, pt)
+        #     half_capot_home_key = ["match_id", "lg_id", "odds_code", "status", "sort", "p_code", "odds", "condition",
+        #                            "odds_only", "sole", "source", "type", "team"]
+        #     half_capot_home_value = [match_id, league_id, "ch_h", "0", 0, p_code, half_capot_home, '1',
+        #                              odds_only, sole, "hg3535", "0", ""]
+        #     half_capot_homet_data = dict(zip(half_capot_home_key, half_capot_home_value))
+        #     data_list.append(half_capot_homet_data)
+        #
+        #     # half_capot_guest
+        #     hash_str = p_code + "cg_h" + '0' + '2' + str(half_capot_guest) + "hg3535" + str(match_id)
+        #     sole_str = p_code + "cg_h" + '0' + str(match_id) + "hg3535"
+        #     odds_only = Helper.genearte_MD5(hash_str, pt)
+        #     sole = Helper.genearte_MD5(sole_str, pt)
+        #     half_capot_guest_key = ["match_id", "lg_id", "odds_code", "status", "sort", "p_code", "odds", "condition",
+        #                             "odds_only", "sole", "source", "type", "team"]
+        #     half_capot_guest_value = [match_id, league_id, "cg_h", "0", 0, p_code, half_capot_guest, '2',
+        #                               odds_only, sole, "hg3535", "0", ""]
+        #     half_capot_guest_data = dict(zip(half_capot_guest_key, half_capot_guest_value))
+        #     data_list.append(half_capot_guest_data)
+        #
+        #     # half_capot_dogfall
+        #     hash_str = p_code + "cd_h" + '0' + 'X' + str(half_capot_dogfall) + "hg3535" + str(match_id)
+        #     sole_str = p_code + "cd_h" + '0' + str(match_id) + "hg3535"
+        #     odds_only = Helper.genearte_MD5(hash_str, pt)
+        #     sole = Helper.genearte_MD5(sole_str, pt)
+        #     half_capot_dogfall_key = ["match_id", "lg_id", "odds_code", "status", "sort", "p_code", "odds", "condition",
+        #                               "odds_only", "sole", "source", "type", "team"]
+        #     half_capot_dogfall_value = [match_id, league_id, "cd_h", "0", 0, p_code, half_capot_dogfall, 'X',
+        #                                 odds_only, sole, "hg3535", "0", ""]
+        #     half_capot_dogfall_data = dict(zip(half_capot_dogfall_key, half_capot_dogfall_value))
+        #     data_list.append(half_capot_dogfall_data)
+        #
+        #     # capot_dogfall
+        #     hash_str = p_code + "cd" + '0' + 'X' + str(capot_dogfall) + "hg3535" + str(match_id)
+        #     sole_str = p_code + "cd" + '0' + str(match_id) + "hg3535"
+        #     odds_only = Helper.genearte_MD5(hash_str, pt)
+        #     sole = Helper.genearte_MD5(sole_str, pt)
+        #     capot_dogfall_key = ["match_id", "lg_id", "odds_code", "status", "sort", "p_code", "odds", "condition",
+        #                          "odds_only", "sole", "source", "type", "team"]
+        #     capot_dogfall_value = [match_id, league_id, "cd", "0", 0, p_code, capot_dogfall, 'X', odds_only,
+        #                            sole, "hg3535", "0", ""]
+        #     capot_dogfall_data = dict(zip(capot_dogfall_key, capot_dogfall_value))
+        #     data_list.append(capot_dogfall_data)
+        #
+        #     # capot_home
+        #     hash_str = p_code + "ch" + '0' + '1' + str(capot_home) + "hg3535" + str(match_id)
+        #     sole_str = p_code + "ch" + '0' + str(match_id) + "hg3535"
+        #     odds_only = Helper.genearte_MD5(hash_str, pt)
+        #     sole = Helper.genearte_MD5(sole_str, pt)
+        #     capot_home_key = ["match_id", "lg_id", "odds_code", "status", "sort", "p_code", "odds", "condition",
+        #                       "odds_only", "sole", "source", "type", "team"]
+        #     capot_home_value = [match_id, league_id, "ch", "0", 0, p_code, capot_home, '1',
+        #                         odds_only, sole, "hg3535", "0", ""]
+        #     capot_homet_data = dict(zip(capot_home_key, capot_home_value))
+        #     data_list.append(capot_homet_data)
+        #
+        #     # capot_guest
+        #     hash_str = p_code + "cg" + '0' + '2' + str(capot_guest) + "hg3535" + str(match_id)
+        #     sole_str = p_code + "cg" + '0' + str(match_id) + "hg3535"
+        #     odds_only = Helper.genearte_MD5(hash_str, pt)
+        #     sole = Helper.genearte_MD5(sole_str, pt)
+        #     capot_guest_key = ["match_id", "lg_id", "odds_code", "status", "sort", "p_code", "odds", "condition",
+        #                        "odds_only", "sole", "source", "type", "team"]
+        #     capot_guest_value = [match_id, league_id, "cg", "0", 0, p_code, capot_guest, '2',
+        #                          odds_only, sole, "hg3535", "0", ""]
+        #     capot_guest_data = dict(zip(capot_guest_key, capot_guest_value))
+        #     data_list.append(capot_guest_data)
+        #
+        #     # 入球数单双-----------------------------------------------------------------------------------------------------
+        #     # p_code, p_id = get_pcode(corner_ball, 'two_sides')
+        #     p_code = 'TS'
+        #     odd_even_odd = item["odd_even_odd"]
+        #     odd_even_even = item["odd_even_even"]
+        #     half_odd_even_odd = item["half_odd_even_odd"]
+        #     half_odd_even_even = item["half_odd_even_even"]
+        #
+        #     # odd_even_odd
+        #     hash_str = p_code + "tss" + '0' + '单' + str(odd_even_odd) + "hg3535" + str(match_id)
+        #     sole_str = p_code + "tss" + '0' + str(match_id) + "hg3535"
+        #     odds_only = Helper.genearte_MD5(hash_str, pt)
+        #     sole = Helper.genearte_MD5(sole_str, pt)
+        #     single_key = ["match_id", "lg_id", "odds_code", "status", "sort", "p_code", "odds", "condition",
+        #                   "odds_only", "sole", "source", "type", "team"]
+        #     single_value = [match_id, league_id, "tss", "0", 0, p_code, odd_even_odd, '单',
+        #                     odds_only, sole, "hg3535", "0", ""]
+        #     single_data = dict(zip(single_key, single_value))
+        #     data_list.append(single_data)
+        #
+        #     # odd_even_even
+        #     hash_str = p_code + "tsd" + '0' + '双' + str(odd_even_even) + "hg3535" + str(match_id)
+        #     sole_str = p_code + "tsd" + '0' + str(match_id) + "hg3535"
+        #     odds_only = Helper.genearte_MD5(hash_str, pt)
+        #     sole = Helper.genearte_MD5(sole_str, pt)
+        #     double_key = ["match_id", "lg_id", "odds_code", "status", "sort", "p_code", "odds", "condition",
+        #                   "odds_only", "sole", "source", "type", "team"]
+        #     double_value = [match_id, league_id, "tsd", "0", 0, p_code, odd_even_even, '双',
+        #                     odds_only, sole, "hg3535", "0", ""]
+        #     double_data = dict(zip(double_key, double_value))
+        #     data_list.append(double_data)
+        #
+        #     # half_odd_even_even
+        #     hash_str = p_code + "tsd_h" + '0' + '双' + str(half_odd_even_even) + "hg3535" + str(match_id)
+        #     sole_str = p_code + "tsd_h" + '0' + str(match_id) + "hg3535"
+        #     odds_only = Helper.genearte_MD5(hash_str, pt)
+        #     sole = Helper.genearte_MD5(sole_str, pt)
+        #     half_double_key = ["match_id", "lg_id", "odds_code", "status", "sort", "p_code", "odds", "condition",
+        #                        "odds_only", "sole", "source", "type", "team"]
+        #     half_double_value = [match_id, league_id, "tsd_h", "0", 0, p_code, half_odd_even_even, '双',
+        #                          odds_only, sole, "hg3535", "0", ""]
+        #     half_double_data = dict(zip(half_double_key, half_double_value))
+        #     data_list.append(half_double_data)
+        #
+        #     # half_odd_even_odd
+        #     hash_str = p_code + "tss_h" + '0' + '单' + str(half_odd_even_odd) + "hg3535" + str(match_id)
+        #     sole_str = p_code + "tss_h" + '0' + str(match_id) + "hg3535"
+        #     odds_only = Helper.genearte_MD5(hash_str, pt)
+        #     sole = Helper.genearte_MD5(sole_str, pt)
+        #     half_single_key = ["match_id", "lg_id", "odds_code", "status", "sort", "p_code", "odds", "condition",
+        #                        "odds_only", "sole", "source", "type", "team"]
+        #     half_single_value = [match_id, league_id, "tss_h", "0", 0, p_code, half_odd_even_odd, '单', odds_only,
+        #                          sole, "hg3535", "0", ""]
+        #     half_single_data = dict(zip(half_single_key, half_single_value))
+        #     data_list.append(half_single_data)
+        #
+        #     # 总入球数 ---------------------------------------------------------------------------------------------------
+        #     p_code = 'TG'
+        #     total_goals = item['total_goal']
+        #     total_dict = {'tg0': '0-1', 'tg1': '2-3', 'tg2': '4-6', 'tg3': '7或以上', 'tg0_h': '0', "tg1_h": '1',
+        #                   "tg2_h": '2', "tg3_h": '3或以上'}
+        #     # 全场入球数 单双
+        #     # 上半场入球数 单双
+        #     for key, value in total_goals.items():
+        #         hash_str = p_code + key + '0' + total_dict[key] + str(value) + "hg3535" + str(match_id)
+        #         sole_str = p_code + key + '0' + str(match_id) + "hg3535"
+        #         odds_only = Helper.genearte_MD5(hash_str, pt)
+        #         sole = Helper.genearte_MD5(sole_str, pt)
+        #         total_goals_key = ["match_id", "lg_id", "odds_code", "status", "sort", "p_code", "odds", "condition",
+        #                            "odds_only", "sole", "source", "type", "team"]
+        #         total_goals_value = [match_id, league_id, key, "0", 0, p_code, value, total_dict[key], odds_only,
+        #                              sole, "hg3535", "0", ""]
+        #         total_goals_data = dict(zip(total_goals_key, total_goals_value))
+        #         data_list.append(total_goals_data)
+        #
+        #     # 全场半场 ---------------------------------------------------------------------------------------------------
+        #     half_fulls = item['half_full']
+        #     p_code = 'HF'
+        #     full_dict = {"hfhh": "主主", "hfhd": "主和", "hfhg": "主客", "hfdh": "和主",
+        #                  "hfdd": "和和", "hfdg": "和客", "hfgh": "客主", "hfgd": "客和", "hfgg": "客客"}
+        #     if half_fulls:
+        #         for key, value in half_fulls.items():
+        #             hash_str = p_code + key + '0' + full_dict[key] + str(value) + "hg3535" + str(match_id)
+        #             sole_str = p_code + key + '0' + str(match_id) + "hg3535"
+        #             odds_only = Helper.genearte_MD5(hash_str, pt)
+        #             sole = Helper.genearte_MD5(sole_str, pt)
+        #             half_fulls_key = ["match_id", "lg_id", "odds_code", "status", "sort", "p_code", "odds", "condition",
+        #                               "odds_only", "sole", "source", "type", "team"]
+        #             half_fulls_value = [match_id, league_id, key, "0", 0, p_code, value, full_dict[key], odds_only,
+        #                                 sole, "hg3535", "0", ""]
+        #             half_fulls_data = dict(zip(half_fulls_key, half_fulls_value))
+        #             data_list.append(half_fulls_data)
+        #
+        #     # 波胆-----------------------------------------------------------------------------------------------------------
+        #     bodan_datas = item['bodan_data']
+        #     p_code = 'B'
+        #     bodan_dict = {"b10": "1-0", "b20": "2-0", "b21": "2-1", "b30": "3-0", "b31": "3-1", "b32": "3-2",
+        #                   "b40": "4-0", "b41": "4-1", "b42": "4-2", "b43": "4-3", "b01": "0-1", "b02": "0-2",
+        #                   "b12": "1-2", "b03": "0-3", "b13": "1-3", "b23": "2-3", "b04": "0-4", "b14": "1-4",
+        #                   "b24": "2-4", "b34": "3-4", "b00": "0-0", "b11": "1-1", "b22": "2-2", "b33": "3-3",
+        #                   "b44": "4-4", "bo": "其他", "b10_h": "1-0", "b20_h": "2-0", "b21_h": "2-1", "b30_h": "3-0",
+        #                   "b31_h": "3-1", "b32_h": "3-2", "b01_h": "0-1", "b02_h": "0-2", "b12_h": "1-2",
+        #                   "b03_h": "0-3",
+        #                   "b13_h": "1-3", "b23_h": "2-3", "b00_h": "0-0", "b11_h": "1-1", "b22_h": "2-2",
+        #                   "b33_h": "3-3",
+        #                   "bo_h": "其他"}
+        #     if bodan_datas:
+        #         for key, value in bodan_datas.items():
+        #             hash_str = p_code + key + '0' + bodan_dict[key] + str(value) + "hg3535" + str(match_id)
+        #             sole_str = p_code + key + '0' + str(match_id) + "hg3535"
+        #             odds_only = Helper.genearte_MD5(hash_str, pt)
+        #             sole = Helper.genearte_MD5(sole_str, pt)
+        #             bodan_dict_key = ["match_id", "lg_id", "odds_code", "status", "sort", "p_code", "odds", "condition",
+        #                               "odds_only", "sole", "source", "type", "team"]
+        #             bodan_dict_value = [match_id, league_id, key, "0", 0, p_code, value, bodan_dict[key], odds_only,
+        #                                 sole, "hg3535", "0", ""]
+        #             bodan_dict_data = dict(zip(bodan_dict_key, bodan_dict_value))
+        #             data_list.append(bodan_dict_data)
+        #
+        #     # 最先进球/最后进球 ----------------------------------------------------------------------------------------------
+        #     first_last_balls = item['first_last_ball']
+        #     # p_code, p_id = get_pcode(corner_ball, 'first_last_ball')
+        #     p_code = 'FLB'
+        #     first_last_dict = {"flbfh": "最先进球", "flbfg": "最先进球", "flblh": "最后进球", "flblg": "最后进球", "flbn": "没有进球"}
+        #     if first_last_balls:
+        #         for key, value in first_last_balls.items():
+        #             hash_str = p_code + key + '0' + first_last_dict[key] + str(value) + "hg3535" + str(match_id)
+        #             sole_str = p_code + key + '0' + str(match_id) + "hg3535"
+        #             odds_only = Helper.genearte_MD5(hash_str, pt)
+        #             sole = Helper.genearte_MD5(sole_str, pt)
+        #             first_last_balls_key = ["match_id", "lg_id", "odds_code", "status", "sort", "p_code", "odds",
+        #                                     "condition",
+        #                                     "odds_only", "sole", "source", "type", "team"]
+        #             first_last_balls_value = [match_id, league_id, key, "0", 0, p_code, value, first_last_dict[key],
+        #                                       odds_only,
+        #                                       sole, "hg3535", "0", ""]
+        #             first_last_balls_data = dict(zip(first_last_balls_key, first_last_balls_value))
+        #             data_list.append(first_last_balls_data)
+        #
+        #     # 球队得分大小
+        #     p_code = 'TB'
+        #     # 全场
+        #     full_dicts = item['full_data']
+        #     # 上半场
+        #     half_dicts = item['half_data']
+        #     full_dict_rules = item['full_data_rule']
+        #     half_dict_rules = item['half_data_rule']
+        #     if full_dicts:
+        #         for key, value in full_dicts.items():
+        #             hash_str = p_code + key + '0' + full_dict_rules[key] + str(value) + "hg3535" + str(match_id)
+        #             sole_str = p_code + key + '0' + str(match_id) + "hg3535"
+        #             odds_only = Helper.genearte_MD5(hash_str, pt)
+        #             sole = Helper.genearte_MD5(sole_str, pt)
+        #             full_dict_rules_key = ["match_id", "lg_id", "odds_code", "status", "sort", "p_code", "odds",
+        #                                    "condition", "odds_only", "sole", "source", "type", "team"]
+        #             full_dict_rules_value = [match_id, league_id, key, "0", 0, p_code, value, full_dict_rules[key],
+        #                                      odds_only, sole, "hg3535", "0", ""]
+        #             full_dict_rules_data = dict(zip(full_dict_rules_key, full_dict_rules_value))
+        #             data_list.append(full_dict_rules_data)
+        #
+        #     if half_dicts:
+        #         for key, value in half_dicts.items():
+        #             hash_str = p_code + key + '0' + half_dict_rules[key] + str(value) + "hg3535" + str(match_id)
+        #             sole_str = p_code + key + '0' + str(match_id) + "hg3535"
+        #             odds_only = Helper.genearte_MD5(hash_str, pt)
+        #             sole = Helper.genearte_MD5(sole_str, pt)
+        #             half_dicts_key = ["match_id", "lg_id", "odds_code", "status", "sort", "p_code", "odds",
+        #                               "condition", "odds_only", "sole", "source", "type", "team"]
+        #             half_dicts_value = [match_id, league_id, key, "0", 0, p_code, value, half_dict_rules[key],
+        #                                 odds_only, sole, "hg3535", "0", ""]
+        #             half_dicts_data = dict(zip(half_dicts_key, half_dicts_value))
+        #             data_list.append(half_dicts_data)
+        #
             p_code = 'CB'
             horn_ou_dict = item['horn_ou_dict']
             horn_ou_dict_rule = item['horn_ou_dict_rule']