<template>
  <v-header title="配送计划" :async="async" @fetch="fetch" scroll border backgroundColor="#fff">
    <view v-for="(item,index) in data" :key="index" class="distribution-item row aCenter"
      :class="{
        'distribution-item-active': item.status === 1
      }"
    >
      <view class="flex-all-1">{{item.date}}</view>
      <view v-if="!is_refound && item.status === 2" @click="confirm(item)" class="distribution-button center">确认收货</view>
      <view v-else-if="is_refound && item.status === 2">配送中(退款)</view>
      <view v-else>{{item.status === 1?'已送达':'未配送'}}</view>
    </view>
  </v-header>
</template>

<script>
import vHeader from '../../components/v-header/main';
import mixins from './mixins/index';
export default {
  name: "distribution",
  mixins,
  components:{
    vHeader
  }
}
</script>

<style scoped src="./style.scss" lang="scss">

</style>