|
@@ -14,7 +14,7 @@
|
|
|
<view class="record-item" v-if="index==current" v-for="(item,sindex) in list" :key="item.id" @click="getDetails(item)">
|
|
|
<view class="item-head">
|
|
|
<text class="item-c-tit">{{item.storeName}}</text>
|
|
|
- <u-tag class="item-c-type" :text="item.status | taskStatus" type="primary" />
|
|
|
+ <u-tag class="item-c-type" :text="item.status | taskStatus" :type="item.status | statusCls" />
|
|
|
</view>
|
|
|
<view class="item-main">
|
|
|
<text class="item-tit">创建时间:</text>
|
|
@@ -108,6 +108,20 @@
|
|
|
}
|
|
|
return str
|
|
|
},
|
|
|
+ // 状态颜色标记
|
|
|
+ statusCls(val){
|
|
|
+ let str = ''
|
|
|
+ if(val == 'PENDING'){
|
|
|
+ str = 'error'
|
|
|
+ }else if(val == 'RUNNING'){
|
|
|
+ str = 'primary'
|
|
|
+ }else if(val == 'FINISHED'){
|
|
|
+ str = 'success'
|
|
|
+ }else if(val == 'EXPIRED'){
|
|
|
+ str = 'warning'
|
|
|
+ }
|
|
|
+ return str
|
|
|
+ },
|
|
|
// 巡店耗时 秒转时分
|
|
|
formatTime(s){
|
|
|
let time = ''
|