Browse Source

Merge branch 'dev' of http://git.ycjcjy.com/shigongli/miniapp-v2 into dev

张延森 3 years ago
parent
commit
215c28c8d0

+ 14
- 59
src/hotel/components/shareRoom/ShareRoom.jsx View File

@@ -19,19 +19,24 @@ export default (props) => {
19 19
     setEndDate(e.detail.value)
20 20
   }
21 21
   const handelShare = () => {
22
-    if (roomNum != '' && startDate != '' && endDate != '') {
23
-      shareRoom({ hotelId: room.hotelId, personNum: roomNum, roomId: room.roomId, startDate: startDate, endDate: endDate }).then((res) => {
24
-        onFinish(res)
25
-        setStartDate('')
26
-        setEndDate('')
27
-        setRoomNum()
28
-      })
29
-    }
22
+    var myDate = new Date();
23
+    shareRoom({
24
+      hotelId: room.hotelId,
25
+      personNum: roomNum == '' ? 0 : roomNum, roomId: room.roomId,
26
+      startDate: startDate == '' ? myDate.toLocaleDateString() : startDate,
27
+      endDate: endDate == '' ? myDate.toLocaleDateString() : endDate
28
+    }).then((res) => {
29
+      onFinish(res)
30
+      setStartDate('')
31
+      setEndDate('')
32
+      setRoomNum()
33
+    })
34
+
30 35
   }
31 36
   return (
32 37
     <Popup show={showCutover} onClose={onClose}>
33 38
       <View className='from-room srl'>
34
-        <View style={{marginBottom:'25px'}}>
39
+        <View style={{ marginBottom: '25px' }}>
35 40
           <View className='rzline' /><Label className='srl mg'>请输入入住人信息</Label><View className='rzline' />
36 41
         </View>
37 42
         <View className='srleft'>
@@ -54,57 +59,7 @@ export default (props) => {
54 59
           <Button className='cancel' onClick={onClose}>取消</Button>
55 60
           <Button className='btn' onClick={handelShare}>分享</Button>
56 61
         </View>
57
-
58
-
59
-
60
-
61
-        {/* <mp-form  >
62
-        <Label style={{color:'black'}}>请输入入住人信息</Label>
63
-        <mp-cells    footer='  ' >
64
-          <mp-cell title='入住人数:' extClass='font'>
65
-            <Input focus dataField='nm' onInput={(e) => setRoomNum(e.detail.value)} value={roomNum} type='number' placeholder='请输入入住人数' />
66
-          </mp-cell>
67
-          <mp-cell title='入住开始时间:' extClass='font'>
68
-            <Picker mode='date' onChange={handelStartDate}>
69
-              {startDate == '' ? '请选择入住开始时间' : startDate}
70
-            </Picker>
71
-          </mp-cell>
72
-          <mp-cell title='入住结束时间:' extClass='font'>
73
-            <Picker  mode='date' onChange={handelEndDate}>
74
-            {endDate == '' ? '请选择入住结束时间' : endDate}
75
-          </Picker>
76
-          </mp-cell>
77
-          <mp-cell>
78
-            <Button className='cancel' onClick={onClose}>取消</Button><Button className='btn' onClick={handelShare}>分享</Button>
79
-          </mp-cell>
80
-        </mp-cells>
81
-      </mp-form> */}
82 62
       </View>
83
-
84
-
85
-
86
-
87
-
88
-
89
-
90
-      {/* <View className='from-room'>
91
-        <Label style={{ color: 'black' }}>请输入入住人信息</Label>
92
-        <View className='flex'>
93
-          <Label>入住人数:</Label><Input focus dataField='nm' onInput={(e) => setRoomNum(e.detail.value)} value={roomNum} type='number' placeholder='请输入入住人数' /></View>
94
-        <View className='flex'>
95
-          <Label>入住开始时间:</Label>
96
-          <Picker mode='date' className='picker' onChange={handelStartDate}>
97
-            {startDate == '' ? '请选择入住开始时间' : startDate}
98
-          </Picker>
99
-        </View>
100
-        <View className='flex'>
101
-          <Label>入住结束时间:</Label>
102
-          <Picker className='picker' mode='date' onChange={handelEndDate}>
103
-            {endDate == '' ? '请选择入住结束时间' : endDate}
104
-          </Picker>
105
-        </View>
106
-        <View><Button className='cancel' onClick={onClose}>取消</Button><Button className='btn' onClick={handelShare}>分享</Button></View>
107
-      </View> */}
108 63
     </Popup>
109 64
   )
110 65
 }

+ 3
- 3
src/pages/index/tabs/Guide.jsx View File

@@ -88,9 +88,9 @@ export default (props) => {
88 88
         setAllextNum(res.total)
89 89
         setNewextNum(res.records.length)
90 90
       })
91
-      getRecommendList({ location: RoomLocation }).then((res) => {
92
-        setPackage(res || [])
93
-      })
91
+      // getRecommendList({ location: RoomLocation }).then((res) => {
92
+      //   setPackage(res || [])
93
+      // })
94 94
 
95 95
 
96 96
     } else {

+ 21
- 13
src/pages/index/tabs/GuideCss/style.less View File

@@ -39,7 +39,6 @@
39 39
       margin-left: 30px;
40 40
 
41 41
       .MessageCard-name {
42
-        width: 400px;
43 42
         height: 40px;
44 43
         font-size: 32px;
45 44
         font-weight: bold;
@@ -50,6 +49,8 @@
50 49
         white-space: nowrap;
51 50
       }
52 51
       .MessageCard-info {
52
+        display: flex;
53
+        width: 998em;
53 54
         height: 23px;
54 55
         font-size: 24px;
55 56
         font-weight: 400;
@@ -178,18 +179,24 @@
178 179
       margin-left: 30px;
179 180
 
180 181
       .MessageCard-name-hotle {
181
-  
182
-        width: 100%;
183
-        /* height: 40rpx; */
184
-        font-size: 32px;
185
-        font-weight: bold;
186
-        color: #202020;
187
-        line-height: 44px;
188
-        /* overflow: hidden; */
189
-        /* -o-text-overflow: ellipsis; */
190
-        text-overflow: ellipsis;
191
-        /* white-space: nowrap; */
192
-        display: flex;
182
+        // width: 100%;
183
+        // font-size: 32px;
184
+        // font-weight: bold;
185
+        // color: #202020;
186
+        // line-height: 44px;
187
+        // display: flex;
188
+
189
+    font-size: 32px;
190
+    font-weight: bold;
191
+    color: #202020;
192
+    line-height: 44px;
193
+    display: flex;
194
+    overflow: hidden;
195
+    -webkit-line-clamp: 2;
196
+    text-overflow: ellipsis;
197
+    -webkit-box-orient: vertical;
198
+    display: -webkit-box;
199
+        
193 200
       }
194 201
       .MessageCard-info-hotle {
195 202
         height: 23px;
@@ -209,6 +216,7 @@
209 216
       text-align: center;
210 217
       display: inline-block;
211 218
       left: 1.5em;
219
+      top: -48px;
212 220
       .MessageCard-image-hotle {
213 221
         width: 30px;
214 222
         height: 30px;