zhulizhen 5 years ago
parent
commit
126bced9ac

+ 10 - 5
src/components/todayStrategy.vue

@@ -42,13 +42,18 @@
             </el-table-column>
             </el-table-column>
             <el-table-column label='执行情况' width='80'>
             <el-table-column label='执行情况' width='80'>
                 <template slot-scope='{row}'>
                 <template slot-scope='{row}'>
-                    <div v-if='!row.isExecuted' style='display: flex;align-items: center;'>
-                        <span style='display: inline-block;width:6px;height:6px;background:#F54E45;border-radius: 3px;margin-right: 5px;'></span>
-                        <span>未执行</span>
+                    <div v-if='row.hasOwnProperty("isExecuted")' style='display: flex;align-items: center;'>
+                        <div v-if='row.isExecuted' style='display: flex;align-items: center;'>
+                            <span style='display: inline-block;width:6px;height:6px;background:#34C724;border-radius: 3px;margin-right: 5px;'></span>
+                            <span>已执行</span>
+                        </div>
+                        <div v-if='!row.isExecuted' style='display: flex;align-items: center;'>
+                            <span style='display: inline-block;width:6px;height:6px;background:#F54E45;border-radius: 3px;margin-right: 5px;'></span>
+                            <span>未执行</span>
+                        </div>
                     </div>
                     </div>
                     <div v-else style='display: flex;align-items: center;'>
                     <div v-else style='display: flex;align-items: center;'>
-                        <span style='display: inline-block;width:6px;height:6px;background:#34C724;border-radius: 3px;margin-right: 5px;'></span>
-                        <span>已执行</span>
+                        <span>--</span>
                     </div>
                     </div>
                 </template>
                 </template>
             </el-table-column>
             </el-table-column>

+ 5 - 2
src/views/strategy/animationBox.vue

@@ -54,9 +54,9 @@
             </div>
             </div>
         </div>
         </div>
 
 
-        <div class='side-r' :class='data.isExecuted?"green":"red"'>
+        <div class='side-r' :class='data.hasOwnProperty("isExcuted")?(data.isExecuted?"green":"red"):"gray"'>
             <div v-if='!showDraw' class='float-r' @click='showDraw = true'>
             <div v-if='!showDraw' class='float-r' @click='showDraw = true'>
-                <div class='float-line' :class='data.isExecuted?"green":"red"'></div>
+                <div class='float-line' :class='data.hasOwnProperty("isExcuted")?(data.isExecuted?"green":"red"):"gray"'></div>
                 <img src='../../assets/open.png' alt />
                 <img src='../../assets/open.png' alt />
                 <p>当前策略</p>
                 <p>当前策略</p>
             </div>
             </div>
@@ -429,6 +429,9 @@ export default {
     .green {
     .green {
         background: #34c724ff;
         background: #34c724ff;
     }
     }
+    .gray {
+        background: #ccc;
+    }
     .side-r:hover {
     .side-r:hover {
         width: 68px;
         width: 68px;
         background: #fff;
         background: #fff;

+ 12 - 3
src/views/strategy/bomBox.vue

@@ -1,6 +1,6 @@
 <template>
 <template>
     <div class='bomb'>
     <div class='bomb'>
-        <div class='bomb-line' :class='data.isExecuted?"green":"red"'></div>
+        <div class='bomb-line' :class='data.hasOwnProperty("isExcuted")?(data.isExecuted?"green":"red"):"gray"'></div>
         <div class='close' @click='$emit("close")'>
         <div class='close' @click='$emit("close")'>
             <img src='../../assets/close.png' alt />
             <img src='../../assets/close.png' alt />
         </div>
         </div>
@@ -8,7 +8,13 @@
             <div class='bomb-left1'>当前策略</div>
             <div class='bomb-left1'>当前策略</div>
             <div
             <div
                 class='bomb-left2'
                 class='bomb-left2'
-            >应执行时间 {{data.executeTime?(data.executeTime.slice(8,10)+":"+ data.executeTime.slice(10,12)):'--'}} - {{data.pushTime?timestamp2String(data.pushTime).slice(8,10)+":"+timestamp2String(data.pushTime).slice(10,12): '--'}}</div>
+            >开机时间 {{data.openTime?(data.openTime.slice(0,2)+":"+ data.openTime.slice(2,4)):'--'}} - {{data.openTime?(data.openTime.slice(0,2)+":"+ data.openTime.slice(2,4)):'--'}}</div>
+            <div
+                class='bomb-left2'
+            >关机时间 {{data.offTime?(data.offTime.slice(0,2)+":"+ data.offTime.slice(2,4)):'--'}} - {{data.offTime?(data.offTime.slice(0,2)+":"+ data.offTime.slice(2,4)):'--'}}</div>
+            <div
+                class='bomb-left2'
+            >应执行时间 {{data.executeTime?(data.executeTime.slice(8,10)+":"+ data.executeTime.slice(10,12)):'--'}} - {{data.executeTime?(data.executeTime.slice(8,10)+":"+ data.executeTime.slice(10,12)):'--'}}</div>
             <div class='bomb-left3'>策略可靠度</div>
             <div class='bomb-left3'>策略可靠度</div>
             <div id='circleEcharts' style='width:170px;height:204px'></div>
             <div id='circleEcharts' style='width:170px;height:204px'></div>
         </div>
         </div>
@@ -156,7 +162,7 @@ export default {
         top: 0;
         top: 0;
         left: -8px;
         left: -8px;
         width: 8px;
         width: 8px;
-        height: 357px;
+        height: 100%;
         border-radius: 8px 0 0 8px;
         border-radius: 8px 0 0 8px;
     }
     }
     .red {
     .red {
@@ -165,6 +171,9 @@ export default {
     .green {
     .green {
         background: #34c724ff;
         background: #34c724ff;
     }
     }
+    .gray {
+        background: #ccc;
+    }
     .close {
     .close {
         cursor: pointer;
         cursor: pointer;
         margin-left: 10px;
         margin-left: 10px;