feat: 增加存储详情功能
This commit is contained in:
@@ -81,10 +81,11 @@ import SportPopup from "@/components/Home/SportPopup.vue";
|
||||
import BpPopup from "@/components/Home/BpPopup.vue";
|
||||
import GlucosePopup from "@/components/Home/GlucosePopup.vue";
|
||||
import TempPopup from "@/components/Home/TempPopup.vue";
|
||||
import { ref, computed, onMounted, watch } from 'vue'
|
||||
import { ref, computed, watch } from 'vue'
|
||||
import { useRecordStore } from '@/store/record'
|
||||
import type { IHealthRecord } from '@/utils/record'
|
||||
import { getDateStr, getDayRecords } from '@/utils/record'
|
||||
import { countRecordsByMonth, getDateStr, getDayRecords } from '@/utils/record'
|
||||
import type { IHealthRecord } from "@/type/record";
|
||||
import {onShow} from "@dcloudio/uni-app";
|
||||
|
||||
defineOptions({
|
||||
name: 'Home',
|
||||
@@ -114,7 +115,7 @@ const today = computed(() => {
|
||||
return `${m}月${d}日 周${w}`
|
||||
})
|
||||
|
||||
onMounted(() => {
|
||||
onShow(() => {
|
||||
todayRecords.value = getDayRecords(getDateStr(Date.now()))
|
||||
})
|
||||
|
||||
@@ -196,3 +197,9 @@ function handelFabClick() {
|
||||
recordStore.showFab = false
|
||||
}
|
||||
</script>
|
||||
|
||||
<style scoped lang="scss">
|
||||
:deep(.wd-card:not(:last-child)) {
|
||||
margin-bottom: 0;
|
||||
}
|
||||
</style>
|
||||
|
||||
Reference in New Issue
Block a user