feat: 增加存储详情功能
This commit is contained in:
@@ -13,12 +13,12 @@
|
||||
</wd-button>
|
||||
</view>
|
||||
|
||||
<wd-segmented v-model:value="current" :options="list" style="overflow: auto;" />
|
||||
<wd-segmented v-model:value="current" :options="list"/>
|
||||
</view>
|
||||
|
||||
<!-- 时间轴区域 -->
|
||||
<view class="px-5 py-2">
|
||||
<wd-empty v-if="grouped.length === 0" icon="no-content" tip="暂无内容" />
|
||||
<wd-empty v-if="grouped.length === 0" icon="no-content" tip="暂无记录" />
|
||||
|
||||
<!-- 外层:每个日期分组 -->
|
||||
<view v-for="group in grouped" :key="group.date" class="mb-6">
|
||||
@@ -90,7 +90,6 @@
|
||||
|
||||
<script lang="ts" setup>
|
||||
import { computed, ref } from 'vue'
|
||||
import type { IHealthRecord } from '@/utils/record'
|
||||
import {
|
||||
getMonthRecords,
|
||||
getMonthStr,
|
||||
@@ -100,6 +99,7 @@ import {
|
||||
groupByDate,
|
||||
} from '@/utils/record'
|
||||
import { onShow } from "@dcloudio/uni-app";
|
||||
import type { IHealthRecord } from "@/type/record";
|
||||
|
||||
const currentDate = ref(Date.now())
|
||||
const showDatePicker = ref(false)
|
||||
@@ -141,12 +141,16 @@ function openDatePicker() {
|
||||
showDatePicker.value = true
|
||||
}
|
||||
|
||||
function onDateConfirm({ value }) {
|
||||
function onDateConfirm() {
|
||||
loadRecords()
|
||||
}
|
||||
</script>
|
||||
|
||||
<style scoped lang="scss">
|
||||
:deep(.wd-segmented) {
|
||||
overflow: auto;
|
||||
}
|
||||
|
||||
:deep(.wd-segmented__item) {
|
||||
min-width: 60px;
|
||||
flex-shrink: 0;
|
||||
|
||||
Reference in New Issue
Block a user