瀏覽代碼

修改收藏

zs 1 年之前
父節點
當前提交
2323c1fd75
共有 36 個文件被更改,包括 752 次插入56 次删除
  1. 33 2
      pages/map/index.vue
  2. 27 10
      pagesHome/hotel/index.vue
  3. 32 1
      pagesHome/ticket/info.vue
  4. 26 10
      pagesHome/type/index.vue
  5. 5 1
      pagesHome/type/info.vue
  6. 1 1
      unpackage/dist/dev/.sourcemap/mp-weixin/common/runtime.js.map
  7. 1 1
      unpackage/dist/dev/.sourcemap/mp-weixin/common/vendor.js.map
  8. 1 1
      unpackage/dist/dev/.sourcemap/mp-weixin/pages/map/index.js.map
  9. 1 1
      unpackage/dist/dev/.sourcemap/mp-weixin/pagesHome/hotel/index.js.map
  10. 1 1
      unpackage/dist/dev/.sourcemap/mp-weixin/pagesHome/ticket/index.js.map
  11. 1 1
      unpackage/dist/dev/.sourcemap/mp-weixin/pagesHome/ticket/info.js.map
  12. 1 1
      unpackage/dist/dev/.sourcemap/mp-weixin/pagesHome/type/index.js.map
  13. 1 1
      unpackage/dist/dev/.sourcemap/mp-weixin/pagesHome/type/info.js.map
  14. 1 0
      unpackage/dist/dev/.sourcemap/mp-weixin/uni_modules/uni-fav/components/uni-fav/uni-fav.js.map
  15. 2 2
      unpackage/dist/dev/mp-weixin/common/runtime.js
  16. 62 0
      unpackage/dist/dev/mp-weixin/common/vendor.js
  17. 49 1
      unpackage/dist/dev/mp-weixin/pages/map/index.js
  18. 1 1
      unpackage/dist/dev/mp-weixin/pages/map/index.wxml
  19. 35 0
      unpackage/dist/dev/mp-weixin/pagesHome/hotel/index.js
  20. 3 1
      unpackage/dist/dev/mp-weixin/pagesHome/hotel/index.json
  21. 1 1
      unpackage/dist/dev/mp-weixin/pagesHome/hotel/index.wxml
  22. 9 4
      unpackage/dist/dev/mp-weixin/pagesHome/hotel/index.wxss
  23. 58 5
      unpackage/dist/dev/mp-weixin/pagesHome/ticket/info.js
  24. 3 1
      unpackage/dist/dev/mp-weixin/pagesHome/ticket/info.json
  25. 1 1
      unpackage/dist/dev/mp-weixin/pagesHome/ticket/info.wxml
  26. 4 0
      unpackage/dist/dev/mp-weixin/pagesHome/ticket/info.wxss
  27. 33 0
      unpackage/dist/dev/mp-weixin/pagesHome/type/index.js
  28. 3 1
      unpackage/dist/dev/mp-weixin/pagesHome/type/index.json
  29. 1 1
      unpackage/dist/dev/mp-weixin/pagesHome/type/index.wxml
  30. 9 4
      unpackage/dist/dev/mp-weixin/pagesHome/type/index.wxss
  31. 1 1
      unpackage/dist/dev/mp-weixin/pagesHome/type/info.wxml
  32. 3 0
      unpackage/dist/dev/mp-weixin/pagesHome/type/info.wxss
  33. 301 0
      unpackage/dist/dev/mp-weixin/uni_modules/uni-fav/components/uni-fav/uni-fav.js
  34. 6 0
      unpackage/dist/dev/mp-weixin/uni_modules/uni-fav/components/uni-fav/uni-fav.json
  35. 1 0
      unpackage/dist/dev/mp-weixin/uni_modules/uni-fav/components/uni-fav/uni-fav.wxml
  36. 34 0
      unpackage/dist/dev/mp-weixin/uni_modules/uni-fav/components/uni-fav/uni-fav.wxss

+ 33 - 2
pages/map/index.vue

@@ -1,6 +1,6 @@
 <template>
 <template>
 	<view class="main">
 	<view class="main">
-		<map class="map" :latitude="latitude" :longitude="longitude" :scale="scale"></map>
+		<map class="map" :latitude="latitude" :longitude="longitude" :scale="scale" :markers="covers"></map>
 	</view>
 	</view>
 </template>
 </template>
 
 
@@ -10,7 +10,38 @@
 			return {
 			return {
 				latitude: 43.3517, // 设置地图的纬度
 				latitude: 43.3517, // 设置地图的纬度
 				longitude: 125.86854, // 设置地图的经度
 				longitude: 125.86854, // 设置地图的经度
-				scale: 13
+				scale: 13,
+				covers: [{
+					id: 0,
+					latitude: 43.34931,
+					longitude: 125.87221,
+					width: 20, //宽
+					height: 30, //高
+					callout: { //自定义标记点上方的气泡窗口 点击有效  
+						content: '吊水壶森林公园', //文本
+						color: '#ffffff', //文字颜色
+						fontSize: 14, //文本大小
+						borderRadius: 15, //边框圆角
+						borderWidth: '10',
+						bgColor: '#e51860', //背景颜色
+						display: 'ALWAYS', //常显
+					},
+				}, {
+					id: 1,
+					latitude: 43.34526,
+					longitude: 125.85224,
+					width: 20, //宽
+					height: 30, //高
+					callout: { //自定义标记点上方的气泡窗口 点击有效
+						content: '公厕', //文本
+						color: '#ffffff', //文字颜色
+						fontSize: 14, //文本大小
+						borderRadius: 15, //边框圆角
+						borderWidth: '10',
+						bgColor: '#e51860', //背景颜色
+						display: 'ALWAYS', //常显
+					},
+				}]
 			}
 			}
 		},
 		},
 		methods: {
 		methods: {

+ 27 - 10
pagesHome/hotel/index.vue

@@ -10,8 +10,15 @@
 						<image class="image" :src="item.file&&item.file.length>0?item.file[0].url:''" mode="aspectFill">
 						<image class="image" :src="item.file&&item.file.length>0?item.file[0].url:''" mode="aspectFill">
 						</image>
 						</image>
 						<view class="list_1">
 						<view class="list_1">
-							<view class="name textOne">{{ item.name ||'暂无'}}</view>
-							<view class="other other_2"><text>入离时间:</text>{{ item.start_time||'暂无' }}-{{ item.end_time||'暂无' }}</view>
+							<view class="top">
+								<view class="name textOne">{{ item.name ||'暂无'}}</view>
+								<view class="collect">
+									<uni-fav :checked="item.is_collect" @click="onClick(item)" />
+								</view>
+							</view>
+							<view class="other other_2">
+								<text>入离时间:</text>{{ item.start_time||'暂无' }}-{{ item.end_time||'暂无' }}
+							</view>
 							<view class="other other_2"><text>联系电话:</text>{{ item.phone||'暂无' }}</view>
 							<view class="other other_2"><text>联系电话:</text>{{ item.phone||'暂无' }}</view>
 							<view class="other other_2 textOne">{{ item.address ||'暂无'}}</view>
 							<view class="other other_2 textOne">{{ item.address ||'暂无'}}</view>
 						</view>
 						</view>
@@ -117,6 +124,11 @@
 					url: `/pagesHome/hotel/info?id=${e.id||e._id}`
 					url: `/pagesHome/hotel/info?id=${e.id||e._id}`
 				})
 				})
 			},
 			},
+			// 收藏
+			onClick() {
+				const that = this;
+				item.is_collect = !item.is_collect
+			},
 			// 分页
 			// 分页
 			toPage(e) {
 			toPage(e) {
 				const that = this;
 				const that = this;
@@ -192,19 +204,25 @@
 				border-radius: 5px;
 				border-radius: 5px;
 
 
 				.image {
 				.image {
-					width: 20vw;
-					height: 20vw;
+					width: 22vw;
+					height: 22vw;
 					border-radius: 5px;
 					border-radius: 5px;
 				}
 				}
 
 
 				.list_1 {
 				.list_1 {
-					width: 68vw;
+					width: 67vw;
 					padding: 0 0 0 2vw;
 					padding: 0 0 0 2vw;
 
 
-					.name {
-						font-size: var(--font14Size);
-						font-weight: bold;
-						padding: 0 0 1vw 0;
+					.top {
+						display: flex;
+						justify-content: space-between;
+
+						.name {
+							width: 50vw;
+							font-size: var(--font14Size);
+							font-weight: bold;
+							padding: 0 0 1vw 0;
+						}
 					}
 					}
 
 
 					.other {
 					.other {
@@ -222,7 +240,6 @@
 
 
 					.other_2 {
 					.other_2 {
 						color: var(--f85Color);
 						color: var(--f85Color);
-
 					}
 					}
 				}
 				}
 			}
 			}

+ 32 - 1
pagesHome/ticket/info.vue

@@ -2,11 +2,17 @@
 	<view class="main">
 	<view class="main">
 		<view class="top">
 		<view class="top">
 			<view class="left">
 			<view class="left">
-				<image class="image" :src="info.file&&info.file.length>0?info.file[0].url:''" mode="aspectFill">
+				<image v-if="info.file.length>0" class="image" :src="info.file&&info.file.length>0?info.file[0].url:''"
+					mode="aspectFill">
+					<image v-else class="image" :src="config.file&&config.file.length>0?config.file[0].url:''"
+						mode="aspectFill">
 			</view>
 			</view>
 			<view class="right">
 			<view class="right">
 				<view class="right_1 textOver">{{info.name||'暂无'}}</view>
 				<view class="right_1 textOver">{{info.name||'暂无'}}</view>
 				<view class="right_2">已售 {{info.buy_num||0}}</view>
 				<view class="right_2">已售 {{info.buy_num||0}}</view>
+				<view class="right_3">
+					<uni-fav :checked="info.is_collect" @click="onClick(item)" />
+				</view>
 			</view>
 			</view>
 		</view>
 		</view>
 		<view class="center">
 		<view class="center">
@@ -57,6 +63,7 @@
 			return {
 			return {
 				id: '',
 				id: '',
 				user: {},
 				user: {},
+				config: {},
 				info: {
 				info: {
 					file: []
 					file: []
 				},
 				},
@@ -67,6 +74,7 @@
 		onLoad: async function(e) {
 		onLoad: async function(e) {
 			const that = this;
 			const that = this;
 			that.$set(that, `id`, e && e.id || '');
 			that.$set(that, `id`, e && e.id || '');
+			that.searchConfig();
 			await that.searchOther();
 			await that.searchOther();
 			await that.search();
 			await that.search();
 		},
 		},
@@ -90,6 +98,19 @@
 					});
 					});
 				}
 				}
 			},
 			},
+			searchConfig() {
+				const that = this;
+				try {
+					const res = uni.getStorageSync('config');
+					if (res) that.$set(that, `config`, res);
+				} catch (e) {
+					uni.showToast({
+						title: err.errmsg,
+						icon: 'error',
+						duration: 2000
+					});
+				}
+			},
 			async search() {
 			async search() {
 				const that = this;
 				const that = this;
 				if (that.id) {
 				if (that.id) {
@@ -117,6 +138,11 @@
 					}).replace(/\<img/gi, '<img style="width:100%;"') // 对 img 元素增加 style 属性,并设置宽度为 100%
 					}).replace(/\<img/gi, '<img style="width:100%;"') // 对 img 元素增加 style 属性,并设置宽度为 100%
 				}
 				}
 			},
 			},
+			// 收藏
+			onClick() {
+				const that = this;
+				item.is_collect = !item.is_collect
+			},
 			// 预订
 			// 预订
 			toBuy(item) {
 			toBuy(item) {
 				const that = this;
 				const that = this;
@@ -181,6 +207,11 @@
 					font-size: var(--font14Size);
 					font-size: var(--font14Size);
 					color: var(--f85Color);
 					color: var(--f85Color);
 				}
 				}
+
+				.right_3 {
+					display: flex;
+					justify-content: flex-end;
+				}
 			}
 			}
 		}
 		}
 
 

+ 26 - 10
pagesHome/type/index.vue

@@ -10,8 +10,13 @@
 						<image class="image" :src="item.file&&item.file.length>0?item.file[0].url:''" mode="aspectFill">
 						<image class="image" :src="item.file&&item.file.length>0?item.file[0].url:''" mode="aspectFill">
 						</image>
 						</image>
 						<view class="list_1">
 						<view class="list_1">
-							<view class="name textOne">{{ item.name ||'暂无'}}</view>
-							<view class="other other_1"><text>人均消费:</text>¥{{ item.money ||'暂无'}}</view>
+							<view class="top">
+								<view class="name textOne">{{ item.name ||'暂无'}}</view>
+								<view class="collect">
+									<uni-fav :checked="item.is_collect" @click="onClick(item)" />
+								</view>
+							</view>
+							<!-- <view class="other other_1"><text>人均消费:</text>¥{{ item.money ||'暂无'}}</view> -->
 							<view class="other other_2"><text>营业时间:</text>{{ item.open_time||'暂无' }}</view>
 							<view class="other other_2"><text>营业时间:</text>{{ item.open_time||'暂无' }}</view>
 							<view class="other other_2"><text>联系电话:</text>{{ item.phone||'暂无' }}</view>
 							<view class="other other_2"><text>联系电话:</text>{{ item.phone||'暂无' }}</view>
 							<view class="other other_2 textOne">{{ item.address ||'暂无'}}</view>
 							<view class="other other_2 textOne">{{ item.address ||'暂无'}}</view>
@@ -41,7 +46,7 @@
 				page: 0,
 				page: 0,
 				// 数据是否触底
 				// 数据是否触底
 				is_bottom: false,
 				is_bottom: false,
-				scrollTop: 0,
+				scrollTop: 0
 			}
 			}
 		},
 		},
 		onLoad: async function(e) {
 		onLoad: async function(e) {
@@ -118,6 +123,11 @@
 					url: `/pagesHome/type/info?id=${e.id||e._id}`
 					url: `/pagesHome/type/info?id=${e.id||e._id}`
 				})
 				})
 			},
 			},
+			// 收藏
+			onClick(item) {
+				const that = this;
+				item.is_collect = !item.is_collect
+			},
 			// 分页
 			// 分页
 			toPage(e) {
 			toPage(e) {
 				const that = this;
 				const that = this;
@@ -193,19 +203,25 @@
 				border-radius: 5px;
 				border-radius: 5px;
 
 
 				.image {
 				.image {
-					width: 25vw;
-					height: 25vw;
+					width: 22vw;
+					height: 22vw;
 					border-radius: 5px;
 					border-radius: 5px;
 				}
 				}
 
 
 				.list_1 {
 				.list_1 {
-					width: 63vw;
+					width: 67vw;
 					padding: 0 0 0 2vw;
 					padding: 0 0 0 2vw;
 
 
-					.name {
-						font-size: var(--font14Size);
-						font-weight: bold;
-						padding: 0 0 1vw 0;
+					.top {
+						display: flex;
+						justify-content: space-between;
+
+						.name {
+							width: 50vw;
+							font-size: var(--font14Size);
+							font-weight: bold;
+							padding: 0 0 1vw 0;
+						}
 					}
 					}
 
 
 					.other {
 					.other {

+ 5 - 1
pagesHome/type/info.vue

@@ -27,7 +27,7 @@
 				</view>
 				</view>
 				<view class="thr_1">
 				<view class="thr_1">
 					<view class="left">人均消费:</view>
 					<view class="left">人均消费:</view>
-					<view class="right">
+					<view class="money">
 						<text>¥{{info.money||'暂无'}}</text>
 						<text>¥{{info.money||'暂无'}}</text>
 					</view>
 					</view>
 				</view>
 				</view>
@@ -179,6 +179,10 @@
 						font-weight: bold;
 						font-weight: bold;
 					}
 					}
 
 
+					.money {
+						color: var(--fF0Color);
+					}
+
 					.right {
 					.right {
 						color: var(--f85Color);
 						color: var(--f85Color);
 
 

文件差異過大導致無法顯示
+ 1 - 1
unpackage/dist/dev/.sourcemap/mp-weixin/common/runtime.js.map


文件差異過大導致無法顯示
+ 1 - 1
unpackage/dist/dev/.sourcemap/mp-weixin/common/vendor.js.map


文件差異過大導致無法顯示
+ 1 - 1
unpackage/dist/dev/.sourcemap/mp-weixin/pages/map/index.js.map


文件差異過大導致無法顯示
+ 1 - 1
unpackage/dist/dev/.sourcemap/mp-weixin/pagesHome/hotel/index.js.map


文件差異過大導致無法顯示
+ 1 - 1
unpackage/dist/dev/.sourcemap/mp-weixin/pagesHome/ticket/index.js.map


文件差異過大導致無法顯示
+ 1 - 1
unpackage/dist/dev/.sourcemap/mp-weixin/pagesHome/ticket/info.js.map


文件差異過大導致無法顯示
+ 1 - 1
unpackage/dist/dev/.sourcemap/mp-weixin/pagesHome/type/index.js.map


文件差異過大導致無法顯示
+ 1 - 1
unpackage/dist/dev/.sourcemap/mp-weixin/pagesHome/type/info.js.map


文件差異過大導致無法顯示
+ 1 - 0
unpackage/dist/dev/.sourcemap/mp-weixin/uni_modules/uni-fav/components/uni-fav/uni-fav.js.map


文件差異過大導致無法顯示
+ 2 - 2
unpackage/dist/dev/mp-weixin/common/runtime.js


+ 62 - 0
unpackage/dist/dev/mp-weixin/common/vendor.js

@@ -41862,6 +41862,68 @@ function createAnimation(option, _this) {
 }
 }
 /* WEBPACK VAR INJECTION */}.call(this, __webpack_require__(/*! ./node_modules/@dcloudio/uni-mp-weixin/dist/index.js */ 2)["default"]))
 /* WEBPACK VAR INJECTION */}.call(this, __webpack_require__(/*! ./node_modules/@dcloudio/uni-mp-weixin/dist/index.js */ 2)["default"]))
 
 
+/***/ }),
+/* 586 */,
+/* 587 */,
+/* 588 */,
+/* 589 */,
+/* 590 */,
+/* 591 */,
+/* 592 */
+/*!*******************************************************************************************!*\
+  !*** D:/project/神鹿峰旅游/travel_applet/uni_modules/uni-fav/components/uni-fav/i18n/index.js ***!
+  \*******************************************************************************************/
+/*! no static exports found */
+/***/ (function(module, exports, __webpack_require__) {
+
+"use strict";
+
+
+var _interopRequireDefault = __webpack_require__(/*! @babel/runtime/helpers/interopRequireDefault */ 4);
+Object.defineProperty(exports, "__esModule", {
+  value: true
+});
+exports.default = void 0;
+var _en = _interopRequireDefault(__webpack_require__(/*! ./en.json */ 593));
+var _zhHans = _interopRequireDefault(__webpack_require__(/*! ./zh-Hans.json */ 594));
+var _zhHant = _interopRequireDefault(__webpack_require__(/*! ./zh-Hant.json */ 595));
+var _default = {
+  en: _en.default,
+  'zh-Hans': _zhHans.default,
+  'zh-Hant': _zhHant.default
+};
+exports.default = _default;
+
+/***/ }),
+/* 593 */
+/*!******************************************************************************************!*\
+  !*** D:/project/神鹿峰旅游/travel_applet/uni_modules/uni-fav/components/uni-fav/i18n/en.json ***!
+  \******************************************************************************************/
+/*! exports provided: uni-fav.collect, uni-fav.collected, default */
+/***/ (function(module) {
+
+module.exports = JSON.parse("{\"uni-fav.collect\":\"collect\",\"uni-fav.collected\":\"collected\"}");
+
+/***/ }),
+/* 594 */
+/*!***********************************************************************************************!*\
+  !*** D:/project/神鹿峰旅游/travel_applet/uni_modules/uni-fav/components/uni-fav/i18n/zh-Hans.json ***!
+  \***********************************************************************************************/
+/*! exports provided: uni-fav.collect, uni-fav.collected, default */
+/***/ (function(module) {
+
+module.exports = JSON.parse("{\"uni-fav.collect\":\"收藏\",\"uni-fav.collected\":\"已收藏\"}");
+
+/***/ }),
+/* 595 */
+/*!***********************************************************************************************!*\
+  !*** D:/project/神鹿峰旅游/travel_applet/uni_modules/uni-fav/components/uni-fav/i18n/zh-Hant.json ***!
+  \***********************************************************************************************/
+/*! exports provided: uni-fav.collect, uni-fav.collected, default */
+/***/ (function(module) {
+
+module.exports = JSON.parse("{\"uni-fav.collect\":\"收藏\",\"uni-fav.collected\":\"已收藏\"}");
+
 /***/ })
 /***/ })
 ]]);
 ]]);
 //# sourceMappingURL=../../.sourcemap/mp-weixin/common/vendor.js.map
 //# sourceMappingURL=../../.sourcemap/mp-weixin/common/vendor.js.map

+ 49 - 1
unpackage/dist/dev/mp-weixin/pages/map/index.js

@@ -154,9 +154,57 @@ var _default = {
       // 设置地图的纬度
       // 设置地图的纬度
       longitude: 125.86854,
       longitude: 125.86854,
       // 设置地图的经度
       // 设置地图的经度
-      scale: 13
+      scale: 13,
+      covers: [{
+        id: 0,
+        latitude: 43.34931,
+        longitude: 125.87221,
+        width: 20,
+        //宽
+        height: 30,
+        //高
+        callout: {
+          //自定义标记点上方的气泡窗口 点击有效  
+          content: '吊水壶森林公园',
+          //文本
+          color: '#ffffff',
+          //文字颜色
+          fontSize: 14,
+          //文本大小
+          borderRadius: 15,
+          //边框圆角
+          borderWidth: '10',
+          bgColor: '#e51860',
+          //背景颜色
+          display: 'ALWAYS' //常显
+        }
+      }, {
+        id: 1,
+        latitude: 43.34526,
+        longitude: 125.85224,
+        width: 20,
+        //宽
+        height: 30,
+        //高
+        callout: {
+          //自定义标记点上方的气泡窗口 点击有效
+          content: '公厕',
+          //文本
+          color: '#ffffff',
+          //文字颜色
+          fontSize: 14,
+          //文本大小
+          borderRadius: 15,
+          //边框圆角
+          borderWidth: '10',
+          bgColor: '#e51860',
+          //背景颜色
+          display: 'ALWAYS' //常显
+        }
+      }]
     };
     };
   },
   },
+
   methods: {}
   methods: {}
 };
 };
 exports.default = _default;
 exports.default = _default;

+ 1 - 1
unpackage/dist/dev/mp-weixin/pages/map/index.wxml

@@ -1 +1 @@
-<view class="main data-v-4219aa94"><map class="map data-v-4219aa94" latitude="{{latitude}}" longitude="{{longitude}}" scale="{{scale}}"></map></view>
+<view class="main data-v-4219aa94"><map class="map data-v-4219aa94" latitude="{{latitude}}" longitude="{{longitude}}" scale="{{scale}}" markers="{{covers}}"></map></view>

+ 35 - 0
unpackage/dist/dev/mp-weixin/pagesHome/hotel/index.js

@@ -98,6 +98,29 @@ __webpack_require__.r(__webpack_exports__);
 /* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "recyclableRender", function() { return recyclableRender; });
 /* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "recyclableRender", function() { return recyclableRender; });
 /* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "components", function() { return components; });
 /* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "components", function() { return components; });
 var components
 var components
+try {
+  components = {
+    uniFav: function () {
+      return Promise.all(/*! import() | uni_modules/uni-fav/components/uni-fav/uni-fav */[__webpack_require__.e("common/vendor"), __webpack_require__.e("uni_modules/uni-fav/components/uni-fav/uni-fav")]).then(__webpack_require__.bind(null, /*! @/uni_modules/uni-fav/components/uni-fav/uni-fav.vue */ 587))
+    },
+  }
+} catch (e) {
+  if (
+    e.message.indexOf("Cannot find module") !== -1 &&
+    e.message.indexOf(".vue") !== -1
+  ) {
+    console.error(e.message)
+    console.error("1. 排查组件名称拼写是否正确")
+    console.error(
+      "2. 排查组件是否符合 easycom 规范,文档:https://uniapp.dcloud.net.cn/collocation/pages?id=easycom"
+    )
+    console.error(
+      "3. 若组件不符合 easycom 规范,需手动引入,并在 components 中注册该组件"
+    )
+  } else {
+    throw e
+  }
+}
 var render = function () {
 var render = function () {
   var _vm = this
   var _vm = this
   var _h = _vm.$createElement
   var _h = _vm.$createElement
@@ -191,6 +214,13 @@ function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { va
 //
 //
 //
 //
 //
 //
+//
+//
+//
+//
+//
+//
+//
 var _default = {
 var _default = {
   data: function data() {
   data: function data() {
     return {
     return {
@@ -312,6 +342,11 @@ var _default = {
         url: "/pagesHome/hotel/info?id=".concat(e.id || e._id)
         url: "/pagesHome/hotel/info?id=".concat(e.id || e._id)
       });
       });
     },
     },
+    // 收藏
+    onClick: function onClick() {
+      var that = this;
+      item.is_collect = !item.is_collect;
+    },
     // 分页
     // 分页
     toPage: function toPage(e) {
     toPage: function toPage(e) {
       var that = this;
       var that = this;

+ 3 - 1
unpackage/dist/dev/mp-weixin/pagesHome/hotel/index.json

@@ -1,5 +1,7 @@
 {
 {
   "navigationBarTitleText": "酒店民宿",
   "navigationBarTitleText": "酒店民宿",
   "enablePullDownRefresh": true,
   "enablePullDownRefresh": true,
-  "usingComponents": {}
+  "usingComponents": {
+    "uni-fav": "/uni_modules/uni-fav/components/uni-fav/uni-fav"
+  }
 }
 }

文件差異過大導致無法顯示
+ 1 - 1
unpackage/dist/dev/mp-weixin/pagesHome/hotel/index.wxml


+ 9 - 4
unpackage/dist/dev/mp-weixin/pagesHome/hotel/index.wxss

@@ -35,15 +35,20 @@
   border-radius: 5px;
   border-radius: 5px;
 }
 }
 .main .two .list .image.data-v-fde50d66 {
 .main .two .list .image.data-v-fde50d66 {
-  width: 20vw;
-  height: 20vw;
+  width: 22vw;
+  height: 22vw;
   border-radius: 5px;
   border-radius: 5px;
 }
 }
 .main .two .list .list_1.data-v-fde50d66 {
 .main .two .list .list_1.data-v-fde50d66 {
-  width: 68vw;
+  width: 67vw;
   padding: 0 0 0 2vw;
   padding: 0 0 0 2vw;
 }
 }
-.main .two .list .list_1 .name.data-v-fde50d66 {
+.main .two .list .list_1 .top.data-v-fde50d66 {
+  display: flex;
+  justify-content: space-between;
+}
+.main .two .list .list_1 .top .name.data-v-fde50d66 {
+  width: 50vw;
   font-size: var(--font14Size);
   font-size: var(--font14Size);
   font-weight: bold;
   font-weight: bold;
   padding: 0 0 1vw 0;
   padding: 0 0 1vw 0;

+ 58 - 5
unpackage/dist/dev/mp-weixin/pagesHome/ticket/info.js

@@ -98,11 +98,36 @@ __webpack_require__.r(__webpack_exports__);
 /* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "recyclableRender", function() { return recyclableRender; });
 /* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "recyclableRender", function() { return recyclableRender; });
 /* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "components", function() { return components; });
 /* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "components", function() { return components; });
 var components
 var components
+try {
+  components = {
+    uniFav: function () {
+      return Promise.all(/*! import() | uni_modules/uni-fav/components/uni-fav/uni-fav */[__webpack_require__.e("common/vendor"), __webpack_require__.e("uni_modules/uni-fav/components/uni-fav/uni-fav")]).then(__webpack_require__.bind(null, /*! @/uni_modules/uni-fav/components/uni-fav/uni-fav.vue */ 587))
+    },
+  }
+} catch (e) {
+  if (
+    e.message.indexOf("Cannot find module") !== -1 &&
+    e.message.indexOf(".vue") !== -1
+  ) {
+    console.error(e.message)
+    console.error("1. 排查组件名称拼写是否正确")
+    console.error(
+      "2. 排查组件是否符合 easycom 规范,文档:https://uniapp.dcloud.net.cn/collocation/pages?id=easycom"
+    )
+    console.error(
+      "3. 若组件不符合 easycom 规范,需手动引入,并在 components 中注册该组件"
+    )
+  } else {
+    throw e
+  }
+}
 var render = function () {
 var render = function () {
   var _vm = this
   var _vm = this
   var _h = _vm.$createElement
   var _h = _vm.$createElement
   var _c = _vm._self._c || _h
   var _c = _vm._self._c || _h
-  var g0 = _vm.info.file && _vm.info.file.length > 0
+  var g0 = _vm.info.file.length
+  var g1 = g0 > 0 ? _vm.info.file && _vm.info.file.length > 0 : null
+  var g2 = !(g0 > 0) ? _vm.config.file && _vm.config.file.length > 0 : null
   var m0 = _vm.info.buy_explain
   var m0 = _vm.info.buy_explain
     ? _vm.formatRichText(_vm.info.buy_explain)
     ? _vm.formatRichText(_vm.info.buy_explain)
     : null
     : null
@@ -120,6 +145,8 @@ var render = function () {
     {
     {
       $root: {
       $root: {
         g0: g0,
         g0: g0,
+        g1: g1,
+        g2: g2,
         m0: m0,
         m0: m0,
         m1: m1,
         m1: m1,
         m2: m2,
         m2: m2,
@@ -222,11 +249,18 @@ var _asyncToGenerator2 = _interopRequireDefault(__webpack_require__(/*! @babel/r
 //
 //
 //
 //
 //
 //
+//
+//
+//
+//
+//
+//
 var _default = {
 var _default = {
   data: function data() {
   data: function data() {
     return {
     return {
       id: '',
       id: '',
       user: {},
       user: {},
+      config: {},
       info: {
       info: {
         file: []
         file: []
       },
       },
@@ -243,12 +277,13 @@ var _default = {
             case 0:
             case 0:
               that = this;
               that = this;
               that.$set(that, "id", e && e.id || '');
               that.$set(that, "id", e && e.id || '');
-              _context.next = 4;
+              that.searchConfig();
+              _context.next = 5;
               return that.searchOther();
               return that.searchOther();
-            case 4:
-              _context.next = 6;
+            case 5:
+              _context.next = 7;
               return that.search();
               return that.search();
-            case 6:
+            case 7:
             case "end":
             case "end":
               return _context.stop();
               return _context.stop();
           }
           }
@@ -297,6 +332,19 @@ var _default = {
         });
         });
       }
       }
     },
     },
+    searchConfig: function searchConfig() {
+      var that = this;
+      try {
+        var res = uni.getStorageSync('config');
+        if (res) that.$set(that, "config", res);
+      } catch (e) {
+        uni.showToast({
+          title: err.errmsg,
+          icon: 'error',
+          duration: 2000
+        });
+      }
+    },
     search: function search() {
     search: function search() {
       var _this = this;
       var _this = this;
       return (0, _asyncToGenerator2.default)( /*#__PURE__*/_regenerator.default.mark(function _callee3() {
       return (0, _asyncToGenerator2.default)( /*#__PURE__*/_regenerator.default.mark(function _callee3() {
@@ -344,6 +392,11 @@ var _default = {
         }).replace(/\<img/gi, '<img style="width:100%;"'); // 对 img 元素增加 style 属性,并设置宽度为 100%
         }).replace(/\<img/gi, '<img style="width:100%;"'); // 对 img 元素增加 style 属性,并设置宽度为 100%
       }
       }
     },
     },
+    // 收藏
+    onClick: function onClick() {
+      var that = this;
+      item.is_collect = !item.is_collect;
+    },
     // 预订
     // 预订
     toBuy: function toBuy(item) {
     toBuy: function toBuy(item) {
       var that = this;
       var that = this;

+ 3 - 1
unpackage/dist/dev/mp-weixin/pagesHome/ticket/info.json

@@ -1,4 +1,6 @@
 {
 {
   "navigationBarTitleText": "门票详情",
   "navigationBarTitleText": "门票详情",
-  "usingComponents": {}
+  "usingComponents": {
+    "uni-fav": "/uni_modules/uni-fav/components/uni-fav/uni-fav"
+  }
 }
 }

文件差異過大導致無法顯示
+ 1 - 1
unpackage/dist/dev/mp-weixin/pagesHome/ticket/info.wxml


+ 4 - 0
unpackage/dist/dev/mp-weixin/pagesHome/ticket/info.wxss

@@ -35,6 +35,10 @@
   font-size: var(--font14Size);
   font-size: var(--font14Size);
   color: var(--f85Color);
   color: var(--f85Color);
 }
 }
+.main .top .right .right_3.data-v-071bd532 {
+  display: flex;
+  justify-content: flex-end;
+}
 .main .center.data-v-071bd532 {
 .main .center.data-v-071bd532 {
   position: relative;
   position: relative;
   flex-grow: 1;
   flex-grow: 1;

+ 33 - 0
unpackage/dist/dev/mp-weixin/pagesHome/type/index.js

@@ -98,6 +98,29 @@ __webpack_require__.r(__webpack_exports__);
 /* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "recyclableRender", function() { return recyclableRender; });
 /* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "recyclableRender", function() { return recyclableRender; });
 /* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "components", function() { return components; });
 /* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "components", function() { return components; });
 var components
 var components
+try {
+  components = {
+    uniFav: function () {
+      return Promise.all(/*! import() | uni_modules/uni-fav/components/uni-fav/uni-fav */[__webpack_require__.e("common/vendor"), __webpack_require__.e("uni_modules/uni-fav/components/uni-fav/uni-fav")]).then(__webpack_require__.bind(null, /*! @/uni_modules/uni-fav/components/uni-fav/uni-fav.vue */ 587))
+    },
+  }
+} catch (e) {
+  if (
+    e.message.indexOf("Cannot find module") !== -1 &&
+    e.message.indexOf(".vue") !== -1
+  ) {
+    console.error(e.message)
+    console.error("1. 排查组件名称拼写是否正确")
+    console.error(
+      "2. 排查组件是否符合 easycom 规范,文档:https://uniapp.dcloud.net.cn/collocation/pages?id=easycom"
+    )
+    console.error(
+      "3. 若组件不符合 easycom 规范,需手动引入,并在 components 中注册该组件"
+    )
+  } else {
+    throw e
+  }
+}
 var render = function () {
 var render = function () {
   var _vm = this
   var _vm = this
   var _h = _vm.$createElement
   var _h = _vm.$createElement
@@ -192,6 +215,11 @@ function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { va
 //
 //
 //
 //
 //
 //
+//
+//
+//
+//
+//
 var _default = {
 var _default = {
   data: function data() {
   data: function data() {
     return {
     return {
@@ -313,6 +341,11 @@ var _default = {
         url: "/pagesHome/type/info?id=".concat(e.id || e._id)
         url: "/pagesHome/type/info?id=".concat(e.id || e._id)
       });
       });
     },
     },
+    // 收藏
+    onClick: function onClick(item) {
+      var that = this;
+      item.is_collect = !item.is_collect;
+    },
     // 分页
     // 分页
     toPage: function toPage(e) {
     toPage: function toPage(e) {
       var that = this;
       var that = this;

+ 3 - 1
unpackage/dist/dev/mp-weixin/pagesHome/type/index.json

@@ -1,5 +1,7 @@
 {
 {
   "navigationBarTitleText": "分类",
   "navigationBarTitleText": "分类",
   "enablePullDownRefresh": true,
   "enablePullDownRefresh": true,
-  "usingComponents": {}
+  "usingComponents": {
+    "uni-fav": "/uni_modules/uni-fav/components/uni-fav/uni-fav"
+  }
 }
 }

文件差異過大導致無法顯示
+ 1 - 1
unpackage/dist/dev/mp-weixin/pagesHome/type/index.wxml


+ 9 - 4
unpackage/dist/dev/mp-weixin/pagesHome/type/index.wxss

@@ -35,15 +35,20 @@
   border-radius: 5px;
   border-radius: 5px;
 }
 }
 .main .two .list .image.data-v-3031ac97 {
 .main .two .list .image.data-v-3031ac97 {
-  width: 25vw;
-  height: 25vw;
+  width: 22vw;
+  height: 22vw;
   border-radius: 5px;
   border-radius: 5px;
 }
 }
 .main .two .list .list_1.data-v-3031ac97 {
 .main .two .list .list_1.data-v-3031ac97 {
-  width: 63vw;
+  width: 67vw;
   padding: 0 0 0 2vw;
   padding: 0 0 0 2vw;
 }
 }
-.main .two .list .list_1 .name.data-v-3031ac97 {
+.main .two .list .list_1 .top.data-v-3031ac97 {
+  display: flex;
+  justify-content: space-between;
+}
+.main .two .list .list_1 .top .name.data-v-3031ac97 {
+  width: 50vw;
   font-size: var(--font14Size);
   font-size: var(--font14Size);
   font-weight: bold;
   font-weight: bold;
   padding: 0 0 1vw 0;
   padding: 0 0 1vw 0;

文件差異過大導致無法顯示
+ 1 - 1
unpackage/dist/dev/mp-weixin/pagesHome/type/info.wxml


+ 3 - 0
unpackage/dist/dev/mp-weixin/pagesHome/type/info.wxss

@@ -41,6 +41,9 @@
   padding: 0 1vw 0 0;
   padding: 0 1vw 0 0;
   font-weight: bold;
   font-weight: bold;
 }
 }
+.main .bottom .thr .thr_1 .money.data-v-ecf5e70e {
+  color: var(--fF0Color);
+}
 .main .bottom .thr .thr_1 .right.data-v-ecf5e70e {
 .main .bottom .thr .thr_1 .right.data-v-ecf5e70e {
   color: var(--f85Color);
   color: var(--f85Color);
 }
 }

文件差異過大導致無法顯示
+ 301 - 0
unpackage/dist/dev/mp-weixin/uni_modules/uni-fav/components/uni-fav/uni-fav.js


+ 6 - 0
unpackage/dist/dev/mp-weixin/uni_modules/uni-fav/components/uni-fav/uni-fav.json

@@ -0,0 +1,6 @@
+{
+  "usingComponents": {
+    "uni-icons": "/uni_modules/uni-icons/components/uni-icons/uni-icons"
+  },
+  "component": true
+}

文件差異過大導致無法顯示
+ 1 - 0
unpackage/dist/dev/mp-weixin/uni_modules/uni-fav/components/uni-fav/uni-fav.wxml


+ 34 - 0
unpackage/dist/dev/mp-weixin/uni_modules/uni-fav/components/uni-fav/uni-fav.wxss

@@ -0,0 +1,34 @@
+@charset "UTF-8";
+/* 水平间距 */
+/* 水平间距 */
+.uni-fav {
+  display: flex;
+  flex-direction: row;
+  align-items: center;
+  justify-content: center;
+  width: 60px;
+  height: 25px;
+  line-height: 25px;
+  text-align: center;
+  border-radius: 3px;
+}
+.uni-fav--circle {
+  border-radius: 30px;
+}
+.uni-fav-star {
+  display: flex;
+  height: 25px;
+  line-height: 24px;
+  margin-right: 3px;
+  align-items: center;
+  justify-content: center;
+}
+.uni-fav-text {
+  display: flex;
+  height: 25px;
+  line-height: 25px;
+  align-items: center;
+  justify-content: center;
+  font-size: 12px;
+}
+