|
|
@@ -31,7 +31,7 @@ |
|
|
|
{{food.name}} |
|
|
|
</view> |
|
|
|
<view class="reservation-timerange" v-if="isReserve"> |
|
|
|
{{new Date(food.startReserveTime).toLocaleTimeString('chinese',{hour12:false}) || '无'}} - {{new Date(food.endReserveTime).toLocaleTimeString('chinese',{hour12:false}) || '无'}} |
|
|
|
{{onFormartLocalDate(food.startReserveTime)}} - {{onFormartLocalDate(food.endReserveTime)}} |
|
|
|
</view> |
|
|
|
<view class="food-card-no-vip"> |
|
|
|
非会员{{food.price}}起 |
|
|
@@ -276,6 +276,13 @@ |
|
|
|
} else { |
|
|
|
return false; |
|
|
|
} |
|
|
|
}, |
|
|
|
onFormartLocalDate(times) { |
|
|
|
const date = new Date(times); |
|
|
|
const hour = date.getHours() < 10 ? `0${date.getHours()}` : date.getHours(); |
|
|
|
const minutes = date.getMinutes() < 10 ? `0${date.getMinutes()}` : date.getMinutes(); |
|
|
|
const seconds = date.getMilliseconds() < 10 ? `0${date.getMilliseconds()}` : date.getMilliseconds(); |
|
|
|
return `${hour}:${minutes}:${seconds}`; |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|