<template>
  <view>
    <picker mode="date" @change="onDateChange" :value="DateValue">
      <!-- <view>
        <text style="color: red; margin: 0 10rpx">*</text>
        <text>选择时间</text>
      </view> -->

      <view class="time-container">
        <view class="date-picker">{{ DateValue }}</view>
        <text>&gt;</text>
      </view>
    </picker>
  </view>
</template>

<script>
export default {
  data() {
    return {
      DateValue: this.$moment().format('YYYY-MM-DD')
    }
  },
  methods: {
    onDateChange(e) {
      this.DateValue = e.detail.value
    }
  }
}
</script>

<style scoped>
.time-container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10rpx 38rpx;
}
</style>
