hookehuyr

fix

...@@ -16,6 +16,10 @@ declare module '@vue/runtime-core' { ...@@ -16,6 +16,10 @@ declare module '@vue/runtime-core' {
16 NutCol: typeof import('@nutui/nutui-taro')['Col'] 16 NutCol: typeof import('@nutui/nutui-taro')['Col']
17 NutConfigProvider: typeof import('@nutui/nutui-taro')['ConfigProvider'] 17 NutConfigProvider: typeof import('@nutui/nutui-taro')['ConfigProvider']
18 NutRow: typeof import('@nutui/nutui-taro')['Row'] 18 NutRow: typeof import('@nutui/nutui-taro')['Row']
19 + NutTabbar: typeof import('@nutui/nutui-taro')['Tabbar']
20 + NutTabbarItem: typeof import('@nutui/nutui-taro')['TabbarItem']
21 + NutTabPane: typeof import('@nutui/nutui-taro')['TabPane']
22 + NutTabs: typeof import('@nutui/nutui-taro')['Tabs']
19 Picker: typeof import('./src/components/time-picker-data/picker.vue')['default'] 23 Picker: typeof import('./src/components/time-picker-data/picker.vue')['default']
20 PosterBuilder: typeof import('./src/components/PosterBuilder/index.vue')['default'] 24 PosterBuilder: typeof import('./src/components/PosterBuilder/index.vue')['default']
21 RoomCard: typeof import('./src/components/roomCard.vue')['default'] 25 RoomCard: typeof import('./src/components/roomCard.vue')['default']
......
1 <!-- 1 <!--
2 * @Date: 2022-09-19 14:11:06 2 * @Date: 2022-09-19 14:11:06
3 * @LastEditors: hookehuyr hookehuyr@gmail.com 3 * @LastEditors: hookehuyr hookehuyr@gmail.com
4 - * @LastEditTime: 2023-12-15 13:07:36 4 + * @LastEditTime: 2023-12-15 13:32:01
5 * @FilePath: /meihuaApp/src/pages/book/index.vue 5 * @FilePath: /meihuaApp/src/pages/book/index.vue
6 * @Description: 文件描述 6 * @Description: 文件描述
7 --> 7 -->
8 <template> 8 <template>
9 <view class="book-page"> 9 <view class="book-page">
10 - <view id="book-content" class="book-content"> 10 + <view v-if="showContent" id="book-content" class="book-content">
11 <view id="book-cal" class="book-cal"> 11 <view id="book-cal" class="book-cal">
12 <calendar-select @on-dates-change="onDatesChange"></calendar-select> 12 <calendar-select @on-dates-change="onDatesChange"></calendar-select>
13 </view> 13 </view>
...@@ -16,9 +16,9 @@ ...@@ -16,9 +16,9 @@
16 <nut-tab-pane v-for="item in list" :title="'Tab ' + item" :pane-key="item"> 16 <nut-tab-pane v-for="item in list" :title="'Tab ' + item" :pane-key="item">
17 <view class="book-list"> 17 <view class="book-list">
18 <scroll-view :style="scrollStyle" :scroll-y="true" :scroll-with-animation="true" @scrolltolower="onScrollToLower"> 18 <scroll-view :style="scrollStyle" :scroll-y="true" :scroll-with-animation="true" @scrolltolower="onScrollToLower">
19 - <view v-for="(item, index) in 20" :key="index"> 19 + <view v-for="(item, index) in 10" :key="index">
20 <room-card :key="index"></room-card> 20 <room-card :key="index"></room-card>
21 - <view v-if="index === 19" style="height: 2rem;"></view> 21 + <view v-if="index === 9" style="height: 2rem;"></view>
22 </view> 22 </view>
23 </scroll-view> 23 </scroll-view>
24 </view> 24 </view>
...@@ -33,8 +33,8 @@ ...@@ -33,8 +33,8 @@
33 <script setup> 33 <script setup>
34 import Taro from '@tarojs/taro' 34 import Taro from '@tarojs/taro'
35 import { ref } from "vue"; 35 import { ref } from "vue";
36 -import calendarSelect from '@/components/calendarSelect.vue'
37 import navBar from '@/components/navBar.vue' 36 import navBar from '@/components/navBar.vue'
37 +import calendarSelect from '@/components/calendarSelect.vue'
38 import roomCard from '@/components/roomCard.vue' 38 import roomCard from '@/components/roomCard.vue'
39 39
40 const onDatesChange = ({ startDate, endDate }) => { 40 const onDatesChange = ({ startDate, endDate }) => {
...@@ -42,7 +42,7 @@ const onDatesChange = ({ startDate, endDate }) => { ...@@ -42,7 +42,7 @@ const onDatesChange = ({ startDate, endDate }) => {
42 } 42 }
43 43
44 const value = ref('0'); 44 const value = ref('0');
45 -const list = new Array(10).fill(0).map((_, index) => index); 45 +const list = new Array(5).fill(0).map((_, index) => index);
46 </script> 46 </script>
47 47
48 <script> 48 <script>
...@@ -62,6 +62,10 @@ export default { ...@@ -62,6 +62,10 @@ export default {
62 mounted () { 62 mounted () {
63 // 设置首页封面高度 63 // 设置首页封面高度
64 const windowHeight = wx.getSystemInfoSync().windowHeight; 64 const windowHeight = wx.getSystemInfoSync().windowHeight;
65 + // 处理切换显示白屏问题
66 + setTimeout(() => {
67 + this.showContent = true;
68 + }, 100);
65 setTimeout(async () => { 69 setTimeout(async () => {
66 const navHeight = await $('#navbar-page').height(); 70 const navHeight = await $('#navbar-page').height();
67 const calHeight = await $('#book-cal').height(); 71 const calHeight = await $('#book-cal').height();
...@@ -70,6 +74,7 @@ export default { ...@@ -70,6 +74,7 @@ export default {
70 }, 74 },
71 data() { 75 data() {
72 return { 76 return {
77 + showContent: false,
73 indexCoverHeight: 0, 78 indexCoverHeight: 0,
74 }; 79 };
75 }, 80 },
......