| | |
| | | <template> |
| | | <el-row justify="center" class="wrap"> |
| | | <el-row justify="start" class="wrap"> |
| | | <!-- <el-space direction="vertical" :size="0"> |
| | | <el-icon size="30"><Stopwatch /></el-icon> |
| | | <el-text class="speed-text">SPD</el-text> |
| | | </el-space> |
| | | <div> |
| | | <el-text class="speed-number">{{ speed }}</el-text> |
| | | <el-text class="speed-unit"><sub>km/h</sub></el-text> |
| | | </div> --> |
| | | <FactorIconText |
| | | elIcon="Odometer" |
| | | label="SPD" |
| | | :value="speed" |
| | | unit="km/h" |
| | | ></FactorIconText> |
| | | <!-- <el-form :inline="true"> |
| | | <el-form-item label="车速:" class="tag-2"> |
| | | {{ speed }}km/h |
| | | </el-form-item> |
| | | </el-form> --> |
| | | <GaugeChart name="车速" :value="speed"></GaugeChart> |
| | | <!-- <GaugeChart name="车速" :value="speed"></GaugeChart> --> |
| | | </el-row> |
| | | </template> |
| | | <script> |
| | |
| | | export default { |
| | | props: { |
| | | loading: Boolean, |
| | | factorDatas: FactorDatas |
| | | factorDatas: FactorDatas, |
| | | speed: { |
| | | type: Number, |
| | | default: 0 |
| | | } |
| | | }, |
| | | data() { |
| | | return { |
| | | speed: 0 |
| | | // speed: 0 |
| | | }; |
| | | }, |
| | | watch: { |
| | | factorDatas: { |
| | | handler(nV) { |
| | | this.speed = this.lastOne(nV, '14'); |
| | | // this.speed = this.lastOne(nV, '14'); |
| | | }, |
| | | deep: true |
| | | } |