Browse Source

2024-12-6

cmy 3 tháng trước cách đây
mục cha
commit
a72b5cb22c
100 tập tin đã thay đổi với 4302 bổ sung1344 xóa
  1. 13 4
      App.vue
  2. 2 2
      api/login.js
  3. 10 1
      api/model.js
  4. 8 0
      api/user.js
  5. 1 1
      manifest.json
  6. 143 123
      pages.json
  7. 86 58
      pages/eduction/detail.vue
  8. 145 0
      pages/index/detail.vue
  9. 75 31
      pages/index/index.vue
  10. 0 2
      pages/index/list.vue
  11. 103 52
      pages/modelData/index.vue
  12. 17 12
      pages/modelData/modeltemplate/model_1.vue
  13. 8 4
      pages/modelData/modeltemplate/model_2.vue
  14. 669 644
      pages/modelData/modeltemplate/model_3.vue
  15. 8 3
      pages/public/artDetail.vue
  16. 138 0
      pages/public/artDetailTab.vue
  17. 0 1
      pages/public/domApp.vue
  18. 2 2
      pages/public/login.vue
  19. 0 6
      pages/public/loginMethods.vue
  20. 29 0
      pages/public/video.vue
  21. 0 8
      pages/public/wxLogin.vue
  22. 0 1
      pages/set/address.vue
  23. 0 2
      pages/set/addressManage.vue
  24. 1 5
      pages/set/set.vue
  25. 0 4
      pages/set/userinfo.vue
  26. 0 1
      pages/user/award/award.vue
  27. 0 1
      pages/user/award/awardList.vue
  28. 1 1
      pages/user/award/withdrawal.vue
  29. 61 29
      pages/user/model/model.vue
  30. 423 0
      pages/user/model/modelQr.vue
  31. 224 136
      pages/user/model/modelrz.vue
  32. 1 9
      pages/user/model/phb.vue
  33. 0 3
      pages/user/model/shoprz.vue
  34. 0 5
      pages/user/money/recharge.vue
  35. 0 2
      pages/user/money/wallet.vue
  36. 0 1
      pages/user/money/walletList.vue
  37. 0 1
      pages/user/myteam.vue
  38. 0 2
      pages/user/realName/cropper.vue
  39. 0 4
      pages/user/realName/realNameAuthentication.vue
  40. 0 41
      pages/user/shareQrCode.vue
  41. 0 1
      pages/user/teamph.vue
  42. 78 40
      pages/userhome/user.vue
  43. BIN
      static/controller/baoxiu.png
  44. BIN
      static/controller/dianchi.png
  45. BIN
      static/controller/dingwei.png
  46. BIN
      static/controller/huanche.png
  47. BIN
      static/controller/kaisuo.png
  48. BIN
      static/controller/qidong.png
  49. BIN
      static/controller/shouquan.png
  50. BIN
      static/controller/witchMessage.png
  51. BIN
      static/controller/witchShop.png
  52. BIN
      static/controller/xincheng.png
  53. BIN
      static/controller/xunche.png
  54. BIN
      static/icon/appleIcon.png
  55. BIN
      static/icon/gpsW.png
  56. BIN
      static/icon/myAddress.png
  57. BIN
      static/icon/myCode.png
  58. BIN
      static/icon/mymoney.png
  59. BIN
      static/icon/orderAli.png
  60. BIN
      static/icon/orderWx.png
  61. BIN
      static/icon/scend.png
  62. BIN
      static/icon/search.png
  63. BIN
      static/icon/searchList.png
  64. BIN
      static/icon/yh.png
  65. BIN
      static/image/followButtom.png
  66. BIN
      static/image/followCenter.png
  67. BIN
      static/image/followTop.jpg
  68. BIN
      static/image/modelQshare.png
  69. BIN
      static/image/qybanner.jpg
  70. BIN
      static/image/qyweichat.jpg
  71. BIN
      static/image/realBm.png
  72. BIN
      static/image/realUser.png
  73. BIN
      static/image/realXyf.png
  74. BIN
      static/image/realZm.png
  75. BIN
      static/image/teimImg.jpg
  76. BIN
      static/img/b0c1028581f40a90b2454abfde489f9.png
  77. BIN
      static/img/bg.png
  78. BIN
      static/img/domLogo.png
  79. BIN
      static/img/e0caee5ee096efb49bed156878b1db1.png
  80. BIN
      static/tabBar/tab-xxjl-current.png
  81. BIN
      static/tabBar/tab-xxjl.png
  82. 8 0
      store/index.js
  83. 24 0
      uni_modules/q-previewImage/changelog.md
  84. 124 0
      uni_modules/q-previewImage/components/q-previewImage/q-previewImage.vue
  85. 82 0
      uni_modules/q-previewImage/package.json
  86. 244 0
      uni_modules/q-previewImage/readme.md
  87. 18 0
      uni_modules/uni-icons/changelog.md
  88. 91 0
      uni_modules/uni-icons/components/uni-icons/uni-icons.uvue
  89. 31 17
      uni_modules/uni-icons/components/uni-icons/uni-icons.vue
  90. 32 31
      uni_modules/uni-icons/components/uni-icons/uniicons.css
  91. BIN
      uni_modules/uni-icons/components/uni-icons/uniicons.ttf
  92. 664 0
      uni_modules/uni-icons/components/uni-icons/uniicons_file.ts
  93. 649 0
      uni_modules/uni-icons/components/uni-icons/uniicons_file_vue.js
  94. 14 12
      uni_modules/uni-icons/package.json
  95. 4 0
      uni_modules/uni-notice-bar/changelog.md
  96. 54 18
      uni_modules/uni-notice-bar/components/uni-notice-bar/uni-notice-bar.vue
  97. 4 7
      uni_modules/uni-notice-bar/package.json
  98. 13 12
      utils/newRequest.js
  99. 0 2
      utils/request.js
  100. 0 2
      utils/rocessor.js

+ 13 - 4
App.vue

@@ -19,10 +19,20 @@ export default {
 	methods: {
 		...mapMutations('user', ['setUserInfo', 'login', 'hasLogin']),
 		...mapMutations('shop', ['setShopInfo','setShopAction']),
-		...mapMutations(['setFirstUse'])
+		...mapMutations(['setFirstUse']),
+		// #ifdef MP
+		...mapMutations(['setSystem']),
+		// #endif
 	},
 	onLaunch: function(urlObj) {
-		console.log('开始升级');
+		const that = this;
+		// #ifdef MP
+		uni.getSystemInfo({
+			success(re) {
+				that.setSystem(re.osName)
+			}
+		})
+		// #endif
 		const obj = this;
 		// 加载缓存中的用户信息
 		const userInfo = uni.getStorageSync('userInfo') || '';
@@ -40,6 +50,7 @@ export default {
 				
 			});
 		}
+		
 		// 获取当前位置附近商店数据
 		const shopDetail = uni.getStorageSync('shopDetail') ||'';
 		if(shopDetail){
@@ -97,10 +108,8 @@ export default {
 	},
 	onShow: function() {
 		// 加载拦截
-		// console.log('App Show');
 	},
 	onHide: function() {
-		// console.log('App Hide');
 	}
 };
 </script>

+ 2 - 2
api/login.js

@@ -3,8 +3,8 @@ import request from '@/utils/request'
 // 登录
 export function login(data) {
 	return request({
-		url: '/api/login',
-		method: 'post',
+		url: '/api/login/adminLogin',
+		method: 'get',
 		data
 	});
 }

+ 10 - 1
api/model.js

@@ -106,4 +106,13 @@ export function getUserCardInfo(data, id) {
 		method: 'post',
 		data
 	});
-}
+}
+
+// 获取微信分享码
+export function getWxmpShowQrcode(data) {
+	return request({
+		url: '/api/user/getWxmpShowQrcode',
+		method: 'get',
+		data
+	});
+}

+ 8 - 0
api/user.js

@@ -294,4 +294,12 @@ export function getInviterRanking(data) {
 		method: 'post',
 		data
 	});
+}
+// 激活key
+export function useCode(data) {
+	return request({
+		url: '/api/user/useCode',
+		method: 'post',
+		data
+	});
 }

+ 1 - 1
manifest.json

@@ -1,6 +1,6 @@
 {
     "name" : "母婴界严选",
-    "appid" : "__UNI__F0EBD91",
+    "appid" : "__UNI__FA8FAF8",
     "description" : "",
     "versionName" : "1.0.19",
     "versionCode" : 122,

+ 143 - 123
pages.json

@@ -14,6 +14,22 @@
 				// #endif
 				"navigationBarTitleText": "母婴界严选"
 			}
+		},
+		{
+			"path": "pages/index/detail",
+			"style": {
+				// #ifndef MP
+				"navigationStyle": "custom",
+				"app-plus": {
+					"titleNView": false
+				},
+				// #endif
+				// #ifdef MP
+				"navigationBarBackgroundColor": "#ff629f",
+				"navigationBarTextStyle":"white",
+				// #endif
+				"navigationBarTitleText": "学习交流群"
+			}
 		},
 		// {
 		// 	"path": "pages/cart/cart",
@@ -49,12 +65,6 @@
 		"root": "pages/user",
 		"name": "user",
 		"pages": [
-			// {
-			// 	"path": "realName/realNameAuthentication",
-			// 	"style": {
-			// 		"navigationBarTitleText": "实名认证"
-			// 	}
-			// },
 			{
 				"path": "realName/cropper",
 				"style": {
@@ -73,68 +83,68 @@
 					"navigationBarTitleText": "我的团队"
 				}
 			},
-			{
-				"path": "award/award",
-				"style": {
-					"navigationBarTitleText": "佣金",
-					"navigationBarBackgroundColor": "#f6ab0b",
-					"navigationBarTextStyle": "white"
-				}
-			},
-			{
-				"path": "award/awardList",
-				"style": {
-					"navigationBarTitleText": "佣金明细"
-				}
-			},
+			// {
+			// 	"path": "award/award",
+			// 	"style": {
+			// 		"navigationBarTitleText": "佣金",
+			// 		"navigationBarBackgroundColor": "#f6ab0b",
+			// 		"navigationBarTextStyle": "white"
+			// 	}
+			// },
+			// {
+			// 	"path": "award/awardList",
+			// 	"style": {
+			// 		"navigationBarTitleText": "佣金明细"
+			// 	}
+			// },
 			// {
 			// 	"path": "award/withdrawal",
 			// 	"style": {
 			// 		"navigationBarTitleText": "提现"
 			// 	}
 			// },
-			{
-				"path": "money/pay",
-				"style": {
-					"navigationBarTitleText": "支付",
-					"navigationBarBackgroundColor": "#0BBB62",
-					"navigationBarTextStyle": "white"
-				}
-			},
-			{
-				"path": "money/paySuccess",
-				"style": {
-					"navigationBarTitleText": "支付成功"
-				}
-			},
-			{
-				"path": "money/wallet",
-				"style": {
-					"navigationBarTitleText": "我的钱包",
-					"navigationBarBackgroundColor": "#0BBB62",
-					"navigationBarTextStyle": "white"
-				}
-			},
-			{
-				"path": "money/walletList",
-				"style": {
-					"navigationBarTitleText": "余额明细"
-				}
-			},
+			// {
+			// 	"path": "money/pay",
+			// 	"style": {
+			// 		"navigationBarTitleText": "支付",
+			// 		"navigationBarBackgroundColor": "#0BBB62",
+			// 		"navigationBarTextStyle": "white"
+			// 	}
+			// },
+			// {
+			// 	"path": "money/paySuccess",
+			// 	"style": {
+			// 		"navigationBarTitleText": "支付成功"
+			// 	}
+			// },
+			// {
+			// 	"path": "money/wallet",
+			// 	"style": {
+			// 		"navigationBarTitleText": "我的钱包",
+			// 		"navigationBarBackgroundColor": "#0BBB62",
+			// 		"navigationBarTextStyle": "white"
+			// 	}
+			// },
+			// {
+			// 	"path": "money/walletList",
+			// 	"style": {
+			// 		"navigationBarTitleText": "余额明细"
+			// 	}
+			// },
 			// {
 			// 	"path": "award/account",
 			// 	"style": {
 			// 		"navigationBarTitleText": "提现账号"
 			// 	}
 			// },
-			{
-				"path": "money/recharge",
-				"style": {
-					"navigationBarTitleText": "充值",
-					"navigationBarBackgroundColor": "#0BBB62",
-					"navigationBarTextStyle": "white"
-				}
-			},
+			// {
+			// 	"path": "money/recharge",
+			// 	"style": {
+			// 		"navigationBarTitleText": "充值",
+			// 		"navigationBarBackgroundColor": "#0BBB62",
+			// 		"navigationBarTextStyle": "white"
+			// 	}
+			// },
 			{
 				"path": "shareQrCode",
 				"style": {
@@ -146,6 +156,12 @@
 				"style": {
 					"navigationBarTitleText": "资料认证"
 				}
+			},
+			{
+				"path": "model/modelQr",
+				"style": {
+					"navigationBarTitleText": "模版分享"
+				}
 			},
 			{
 				"path": "model/model",
@@ -188,18 +204,18 @@
 					"navigationBarTitleText": "设置"
 				}
 			},
-			{
-				"path": "address",
-				"style": {
-					"navigationBarTitleText": "收货地址"
-				}
-			},
-			{
-				"path": "addressManage",
-				"style": {
-					"navigationBarTitleText": ""
-				}
-			},
+			// {
+			// 	"path": "address",
+			// 	"style": {
+			// 		"navigationBarTitleText": "收货地址"
+			// 	}
+			// },
+			// {
+			// 	"path": "addressManage",
+			// 	"style": {
+			// 		"navigationBarTitleText": ""
+			// 	}
+			// },
 			{
 				"path": "phone",
 				"style": {
@@ -223,17 +239,6 @@
 		"root": "pages/public",
 		"name": "public",
 		"pages": [
-			// #ifdef H5
-			{
-				"path": "domApp",
-				"style": {
-					"navigationBarTitleText": "app下载",
-					"app-plus": {
-						"titleNView": false
-					}
-				}
-			},
-			// #endif
 			// #ifndef MP
 			{
 				"path": "workwork",
@@ -242,38 +247,38 @@
 				}
 			},
 			// #endif
-			{
-				"path": "register",
-				"style": {
-					"navigationBarTitleText": "注册",
-					"app-plus": {
-						"titleNView": false
-					}
-				}
-			},
-			{
-				"path": "phoneLogin",
-				"style": {
-					"navigationBarTitleText": "手机登录",
-					"app-plus": {
-						"titleNView": false
-					}
-				}
-			},
-			{
-				"path": "login",
-				"style": {
-					"navigationBarTitleText": "登录",
-					"app-plus": {
-						"titleNView": false
-					}
-				}
-			},
+			// {
+			// 	"path": "register",
+			// 	"style": {
+			// 		"navigationBarTitleText": "注册",
+			// 		"app-plus": {
+			// 			"titleNView": false
+			// 		}
+			// 	}
+			// },
+			// {
+			// 	"path": "phoneLogin",
+			// 	"style": {
+			// 		"navigationBarTitleText": "手机登录",
+			// 		"app-plus": {
+			// 			"titleNView": false
+			// 		}
+			// 	}
+			// },
+			// {
+			// 	"path": "login",
+			// 	"style": {
+			// 		"navigationBarTitleText": "登录",
+			// 		"app-plus": {
+			// 			"titleNView": false
+			// 		}
+			// 	}
+			// },
 			// #ifdef MP || H5
 			{
 				"path": "wxLogin",
 				"style": {
-					"navigationBarTitleText": "微信登录",
+					"navigationBarTitleText": "授权登录",
 					"app-plus": {
 						"titleNView": {
 							"type": "transparent"
@@ -282,15 +287,16 @@
 				}
 			},
 			// #endif
-			{
-				"path": "forget",
-				"style": {
-					"navigationBarTitleText": "忘记密码",
-					"app-plus": {
-						"titleNView": false
-					}
-				}
-			},
+			// {
+			// 	"path": "forget",
+			// 	"style": {
+			// 		"navigationBarTitleText": "忘记密码",
+			// 		"app-plus": {
+			// 			"titleNView": false
+			// 		}
+			// 	}
+			// },
+			// #ifdef H5 
 			{
 				"path": "redirect",
 				"style": {
@@ -300,6 +306,7 @@
 					}
 				}
 			},
+			// #endif 
 			{
 				"path": "userAgreement",
 				"style": {
@@ -317,7 +324,20 @@
 				"style": {
 					"navigationBarTitleText": ""
 				}
-			}
+			},
+			{
+				"path": "video",
+				"style": {
+					"navigationBarTitleText": "数字名片制作"
+				}
+			}
+			// ,
+			// {
+			// 	"path": "artDetailTab",
+			// 	"style": {
+			// 		"navigationBarTitleText": ""
+			// 	}
+			// }
 		]
 	},{
 		"root": "pages/eduction",
@@ -366,12 +386,12 @@
 			// 	"selectedIconPath": "static/tabBar/tab-cate-current.png",
 			// 	"text": "分类"
 			// },
-			// {
-			// 	"pagePath": "pages/cart/cart",
-			// 	"iconPath": "static/tabBar/tab-cart.png",
-			// 	"selectedIconPath": "static/tabBar/tab-cart-current.png",
-			// 	"text": "购物车"
-			// },
+			{
+				"pagePath": "pages/index/detail",
+				"iconPath": "static/tabBar/tab-xxjl.png",
+				"selectedIconPath": "static/tabBar/tab-xxjl-current.png",
+				"text": "学习交流群"
+			},
 			{
 				"pagePath": "pages/userhome/user",
 				"iconPath": "static/tabBar/tab-my.png",

+ 86 - 58
pages/eduction/detail.vue

@@ -1,7 +1,8 @@
 <template>
 	<view class="content">
 		<view class="video-wrap">
-			<video :src="could_play?chooseCourse.course_sp:''" id="videoId" class="top-video" :poster="topimg" v-if="chooseCourse.course_sp"></video>
+			<video :src="could_play?chooseCourse.course_sp:''" id="videoId" class="top-video" :poster="topimg"
+				v-if="chooseCourse.course_sp"></video>
 			<image :src="topimg" mode="widthFix" v-else class="top-video"></image>
 			<!-- 视频蒙版 -->
 			<!-- <view class="mask" v-if="!could_play" @click.stop=""></view> -->
@@ -31,7 +32,8 @@
 				</view>
 			</view>
 			<view class="jianjie">
-				<audio  :src="bq(chooseCourse.course_audio)"  controls v-if="chooseCourse.course_audio" :name="chooseCourse.course_topic" author="母婴严选"></audio>
+				<audio :src="bq(chooseCourse.course_audio)" controls v-if="chooseCourse.course_audio"
+					:name="chooseCourse.course_topic" author="母婴严选"></audio>
 				<view class="jianjie-top flex">
 					<view class="hx">
 
@@ -61,7 +63,9 @@
 				</view>
 				<view class="kc-list">
 					<view class="kc-item flex" v-for="item in recommendList" v-if="item.gr_id != id">
-						<image :src="item.indeximg.indexOf('http') == -1 ? ('https://myj.liuniu946.com' +item.indeximg) : item.indeximg" mode="" class="kc-img"></image>
+						<image
+							:src="item.indeximg.indexOf('http') == -1 ? ('https://myj.liuniu946.com' +item.indeximg) : item.indeximg"
+							mode="" class="kc-img"></image>
 						<view class="kc-info">
 							<view class="info-tit clamp">
 								{{item.title}}
@@ -131,7 +135,10 @@
 	import {
 		getUser
 	} from '@/api/user.js';
-	import { getCourseList,recommend } from "@/api/index.js"
+	import {
+		getCourseList,
+		recommend
+	} from "@/api/index.js"
 	export default {
 		data() {
 			return {
@@ -157,24 +164,26 @@
 			};
 		},
 		computed: {
+			// #ifdef MP
+			...mapState(['systeam']),
+			// #endif
 			videoContext() {
 				return uni.createVideoContext('videoId', this)
 			}
 		},
 		onLoad(opt) {
-			
-			if(opt.id) {
+
+			if (opt.id) {
 				this.id = opt.id
 				this.getCourseList()
 			}
-			if(opt.img ) {
+			if (opt.img) {
 				let imgurl = decodeURI(opt.img)
-				console.log(this.topimg);
 			}
 			this.getrecommendList()
 		},
 		onShow() {
-			
+
 		},
 		onReachBottom() {
 
@@ -192,85 +201,104 @@
 				});
 			},
 			getUser() {
-				console.log('data')
 				const that = this;
 				getUser({}).then((e) => {
 					this.user = e.data;
 					this.setUserInfo(e.data)
 					// 
-					if(that.user.info_audit_status == 1 ) {
+					if (that.user.info_audit_status == 1) {
 						//双认证可播放
-						if(that.user.type_audit_status == 1) {
+						if (that.user.type_audit_status == 1) {
 							that.could_play = true
-						}else {
+						} else {
 							// 单次认证无平台认证
-							if(that.chooseCourse.course_price_3*1 > 0) {
+							if (that.chooseCourse.course_price_3 * 1 > 0) {
 								//一次认证付费
 								that.could_play = false
 								let str = ''
-								if(that.user.type_audit_status == -2) {
+								if (that.user.type_audit_status == -2) {
 									str = '您未完成平台认证,是否立即认证?'
 								}
-								if(that.user.type_audit_status == -1) {
+								if (that.user.type_audit_status == -1) {
 									str = '您平台认证失败,请重新认证'
 								}
-								if(that.user.type_audit_status == -3) {
+								if (that.user.type_audit_status == -3) {
 									str = '您平台认证已失效,请重新认证'
 								}
-								if(that.user.type_audit_status == 0) {
+								if (that.user.type_audit_status == 0) {
 									str = '您已提交认证信息请等待认证结束'
 								}
 								uni.showModal({
-									title:'提示',
-									content:str?str:'您未完成平台认证,是否立即认证?',
+									title: '提示',
+									content: str ? str : '您未完成平台认证,是否立即认证?',
 									complete(e) {
-										if(e.confirm) {
-											if (that.user.work_type_id <=0) {
-												that.navTo('/pages/user/model/modelrz?modelid='+that.user.show_template_id)
+										if (e.confirm) {
+											if (that.user.work_type_id <= 0) {
+												that.navTo('/pages/user/model/modelrz?modelid=' + that.user
+													.show_template_id)
 											} else {
 												if (that.user.show_template_id) {
-													that.navTo('/pages/user/model/model?mtype=' + that.user.show_template_id+'&type=3')
-												}else{
-													uni.showModal({
-														title: '错误',
-														content: '您未购买模板请先购买',
-														showCancel: false,
-													});
+													that.navTo('/pages/user/model/model?mtype=' + that.user
+														.show_template_id + '&type=3')
+												} else {
+													if (that.systeam == 'ios') {
+														uni.showModal({
+															title: '错误',
+															content: 'IOS暂不支持',
+															showCancel: false,
+														});
+													} else {
+														uni.showModal({
+															title: '错误',
+															content: '您未购买模板请先购买',
+															showCancel: false,
+														});
+													}
 												}
 											}
 										}
 									}
 								})
-								
-							}else {
+
+							} else {
 								//一次认证即免费
 								that.could_play = true
 							}
 						}
-					}else {
+					} else {
 						//无认证 免费
-						if(that.chooseCourse.course_price*1 == 0) {
+						if (that.chooseCourse.course_price * 1 == 0) {
 							that.could_play = true
-						}else {
+						} else {
 							//付费
 							that.could_play = false
 							uni.showModal({
-								title:'提示',
-								content:'您未完成信息认证,是否立即认证?',
+								title: '提示',
+								content: '您未完成信息认证,是否立即认证?',
 								complete(e) {
-									
-									if(e.confirm) {
-										if (that.user.work_type_id <=0) {
-											that.navTo('/pages/user/model/modelrz?modelid='+that.user.show_template_id)
+
+									if (e.confirm) {
+										if (that.user.work_type_id <= 0) {
+											that.navTo('/pages/user/model/modelrz?modelid=' + that.user
+												.show_template_id)
 										} else {
 											if (that.user.show_template_id) {
-												that.navTo('/pages/user/model/model?mtype=' + that.user.show_template_id+'&type=3')
-											}else{
-												uni.showModal({
-													title: '错误',
-													content: '您未购买模板请先购买',
-													showCancel: false,
-												});
+												that.navTo('/pages/user/model/model?mtype=' + that.user
+													.show_template_id + '&type=3')
+											} else {
+												if (that.systeam == 'ios') {
+													uni.showModal({
+														title: '错误',
+														content: 'IOS暂不支持',
+														showCancel: false,
+													});
+												} else {
+													uni.showModal({
+														title: '错误',
+														content: '您未购买模板请先购买',
+														showCancel: false,
+													});
+												}
 											}
 										}
 									}
@@ -278,27 +306,25 @@
 							})
 						}
 					}
-					
+
 				}).catch((e) => {
 					console.log(e, 'sj');
 				})
 			},
 			bq(url) {
-				if(url.indexOf('http') == -1) {
+				if (url.indexOf('http') == -1) {
 					url = 'https://myj.liuniu946.com' + url
 				}
 				return url
 			},
 			choose(item) {
-				console.log(item,'item');
 				this.choosId = item.course_id
 				this.chooseCourse = item
 				this.currentIndex = 0
 			},
 			getrecommendList() {
 				recommend().then(res => {
-					console.log(res);
-					this.recommendList = res.data.recommendList.slice(0,3)
+					this.recommendList = res.data.recommendList.slice(0, 3)
 				})
 			},
 			getCourseList() {
@@ -306,16 +332,17 @@
 				getCourseList({
 					gr_id: that.id
 				}).then(res => {
-					console.log(res);
 					this.courseList = res.data.map(item => {
 						// item.course_sp = (item.course_sp.indexOf('http') == -1 )? ('http://qiniuyun.deepbytop.com' + item.course_sp ): item.course_sp
-						item.course_sp = item.course_sp.replace(/http:/g,'https:')
-						item.course_intro = item.course_intro.replace(/img src="/g,'img class="rich-img" src="https://myj.liuniu946.com')
+						item.course_sp = item.course_sp.replace(/http:/g, 'https:')
+						item.course_intro = item.course_intro.replace(/img src="/g,
+							'img class="rich-img" src="https://myj.liuniu946.com')
 						return item
 					})
 					this.chooseCourse = this.courseList[0]
-					this.topimg = (this.chooseCourse.course_cover.indexOf('http') == -1 ? ('https://myj.liuniu946.com' + this.chooseCourse.course_cover): this.chooseCourse.course_cover)
-					console.log(this.chooseCourse.course_sp);
+					this.topimg = (this.chooseCourse.course_cover.indexOf('http') == -1 ? (
+							'https://myj.liuniu946.com' + this.chooseCourse.course_cover) : this.chooseCourse
+						.course_cover)
 					this.getUser()
 				})
 			},
@@ -506,6 +533,7 @@
 		}
 
 	}
+
 	/deep/ .rich-img {
 		width: 100% !important;
 	}

+ 145 - 0
pages/index/detail.vue

@@ -0,0 +1,145 @@
+<template>
+	<view class="content ">
+		<view class="flex-center">
+		<image class="bannerImg" src="../../static/image/qybanner.jpg" mode="widthFix"></image>
+		</view>
+		<view class="flex">
+			<image class="qun" src="../../static/image/teimImg.jpg" mode="widthFix"></image>
+		</view>
+		<view class="flex-center">
+		<image class="shareImg" show-menu-by-longpress src="../../static/image/qyweichat.jpg" mode="scaleToFill"></image>
+		</view>
+		<view class="buttom">
+			长按二维码识别加入群聊
+		</view>
+		<view class="footerTottom">
+			更多社群福利
+		</view>
+		<view class="flex footerBox">
+			<view class="item">
+				<view class="line1">
+					实时领取母婴
+				</view>
+				<view class="line1">
+					最新技能资料
+				</view>
+				<view class="lineJg"></view>
+				<view class="titleItem">
+					线上新技能
+				</view>
+			</view>
+			<view class="item">
+				<view class="line1">
+					全国参加举办
+				</view>
+				<view class="line1">
+					母婴工作交流会
+				</view>
+				<view class="lineJg"></view>
+				<view class="titleItem">
+					线下工友会
+				</view>
+			</view>
+			<view class="item">
+				<view class="line1">
+					领取母婴品牌
+				</view>
+				<view class="line1">
+					厂家福利产品
+				</view>
+				<view class="lineJg"></view>
+				<view class="titleItem">
+					母婴心福利
+				</view>
+			</view>
+		</view>
+	</view>
+</template>
+<script>
+	import {
+		mapState,
+		mapMutations
+	} from 'vuex';
+	import {
+		getUser
+	} from '@/api/user.js';
+	import { getCourseList,recommend } from "@/api/index.js"
+	export default {
+		data() {
+			return {
+				
+			};
+		},
+		onLoad(opt) {
+			
+		},
+		onShow() {
+			
+		},
+		onReachBottom() {
+
+		},
+		methods: {
+			
+		}
+	};
+</script>
+<style lang="scss" scoped>
+	.qun{
+		width: 600rpx;
+	}
+	.footerBox{
+		padding: 30rpx 50rpx;
+		color: #FFF;
+		line-height: 1;
+		.item{
+			background-color:rgb(55,175,165) ;
+			border-radius: 30rpx;
+			padding: 40rpx 5rpx;
+			width: 200rpx;
+			.line1{
+				font-size: 24rpx;
+				padding:10rpx 0rpx;
+			}
+			.lineJg{
+				height: 10rpx;
+				background-color: #FFF;
+				margin: 20rpx 0 30rpx 0;
+			}
+			.titleItem{
+				font-size: 32rpx;
+				font-weight: bold;
+				padding-bottom: 10rpx;
+			}
+		}
+	}
+	.footerTottom{
+		color: rgb(251,104,159);
+		font-size: 32rpx;
+		font-weight: bold;
+		text-align-last: left;
+		padding-left: 50rpx;
+	}
+	.buttom{
+		padding: 30rpx 50rpx;
+		margin: 50rpx 50rpx;
+		background-image: linear-gradient(to right,rgb(239,132,43),rgb(244,153,60));
+		border-radius: 100rpx;
+		font-weight: bold;
+		font-size: 40rpx;
+		color: #FFF;
+	}
+	.bannerImg{
+		width: 750rpx;
+	}
+	.content{
+		background-color: #FFF;
+		text-align: center;
+		min-height: 100vh;
+	}
+	.shareImg{
+		width: 350rpx;
+		height: 350rpx;
+		margin: 50rpx 0;
+	}
+</style>

+ 75 - 31
pages/index/index.vue

@@ -1,10 +1,13 @@
 <template>
 	<view class="indexBox">
 		<swiper class="top-swiper" autoplay="true" duration="400" interval="5000" @change="swiperChange">
-			<swiper-item v-for="item in imagelist" class="carousel-item" @click="navTo(item.url)">
+			<swiper-item v-for="item in imagelist" class="carousel-item" @click="openXcx(item.url)">
 				<image class="imageitem" :src="item.img" />
 			</swiper-item>
 		</swiper>
+		<view v-if="textList.length>0" class="padding-t-30">
+			<uni-notice-bar @click="navTo(textList[0].url)" show-icon scrollable :text="textList[0].title" />
+		</view>
 		<view class="hot-list-box">
 			<view class="title-box flex">
 				<view class="flex">
@@ -31,6 +34,17 @@
 					<view class="hot-title clamp">
 						{{item.title}}
 					</view>
+					<!-- #ifdef MP -->
+					<view class="hot-money flex clamp" v-if="systeam!='ios'">
+						<text class="money">
+							¥{{item.price}}
+						</text>
+						<text class="oldmoney">
+							{{item.old_price}}
+						</text>
+					</view>
+					<!-- #endif -->
+					<!-- #ifndef MP -->
 					<view class="hot-money flex clamp">
 						<text class="money">
 							¥{{item.price}}
@@ -39,13 +53,19 @@
 							{{item.old_price}}
 						</text>
 					</view>
+					<!-- #endif -->
 				</view>
 				<view class="item-none" v-if="rmList.length<3" v-for="item in (3-rmList.length)">
 
 				</view>
 			</view>
-			<view class="banner" @click="navTo('/pages/user/model/phb')">
-				<image src="../../static/img/phb.png" mode="widthFix"></image>
+			<view class="flex">
+				<view class="banner" @click="navTo('/pages/public/video')">
+					<image :src="baseURL+'/static/img/indexLeft.png'" mode="widthFix"></image>
+				</view>
+				<view class="banner" @click="navTo('/pages/user/model/phb')">
+					<image :src="baseURL+'/static/img/indexRight.png'" mode="widthFix"></image>
+				</view>
 			</view>
 
 			<view class="title-box flex">
@@ -63,15 +83,15 @@
 						<image src="../../static/icon/next1.png" mode="scaleToFill" class="tip"></image>
 					</view>
 				</navigator> -->
-				<view class="sy-top">
+				<!-- <view class="sy-top">
 					<image src="../../static/icon/tj.png" mode=""></image>
 					<view class="top-tit">
 						精选推荐
 					</view>
-				</view>
+				</view> -->
 			</view>
 
-			<view class="list-box">
+			<!-- <view class="list-box">
 				<view class="list" v-for="(item,index) in navList.orderList"
 					@click="navTo('/pages/user/model/model?mtype=' + item.id+'&type=0')">
 					<view class="list-image-box">
@@ -89,8 +109,8 @@
 						</view>
 					</view>
 				</view>
-			</view>
-			<view class="title-box flex"  v-if="jxList.length > 0">
+			</view> -->
+			<view class="title-box flex" v-if="jxList.length > 0">
 				<view class="flex">
 					<image class="hot margin-r-10" src="../../static/icon/hot.png" mode="scaleToFill"></image>
 					<view class="title">
@@ -99,7 +119,9 @@
 				</view>
 			</view>
 			<view class="bd-wrap">
-				<view class="bd-btm-item flex" v-for="item in jxList" @click="navTo('/pages/user/model/model?uid=' + item.uid + '&mtype=' + item.show_template_id + '&type=2')" v-if="item.name != '影子' && item.name != '测试牛niu' &&item.name != '111'">
+				<view class="bd-btm-item flex" v-for="item in jxList"
+					@click="navTo('/pages/user/model/model?uid=' + item.uid + '&mtype=' + item.show_template_id + '&type=2')"
+					v-if="item.name != '影子' && item.name != '测试牛niu' &&item.name != '111'">
 					<image :src="item.avatar" mode="" class="item-img"></image>
 					<view class="flex item-info">
 						<view class="item-name">
@@ -115,7 +137,7 @@
 					</view>
 				</view>
 			</view>
-			<view class="title-box flex"  v-if="zxList.length > 0">
+			<view class="title-box flex" v-if="zxList.length > 0">
 				<view class="flex">
 					<image class="hot margin-r-10" src="../../static/icon/hot.png" mode="scaleToFill"></image>
 					<view class="title">
@@ -124,7 +146,9 @@
 				</view>
 			</view>
 			<view class="bd-wrap">
-				<view class="bd-btm-item flex" v-for="item in zxList" @click="navTo('/pages/user/model/model?uid=' + item.uid + '&mtype=' + item.show_template_id + '&type=2')" v-if="item.name != '影子' && item.name != '测试牛niu' &&item.name != '111'">
+				<view class="bd-btm-item flex" v-for="item in zxList"
+					@click="navTo('/pages/user/model/model?uid=' + item.uid + '&mtype=' + item.show_template_id + '&type=2')"
+					v-if="item.name != '影子' && item.name != '测试牛niu' &&item.name != '111'">
 					<image :src="item.avatar" mode="" class="item-img"></image>
 					<view class="flex item-info">
 						<view class="item-name">
@@ -167,6 +191,8 @@
 	export default {
 		data() {
 			return {
+				// 通知列表
+				textList: [],
 				rz: this.$store.state.baseURL + '/resource/icon/rz.png',
 				//轮播图
 				imagelist: [],
@@ -183,19 +209,21 @@
 				// 热门商品
 				rmList: [],
 				jxList: [], //精选列表
-				zxList:[]
+				zxList: [],
 			};
 		},
 		computed: {
 			...mapState('user', ['userInfo']),
+			// #ifdef MP
+			...mapState(['systeam', 'baseURL']),
+			// #endif
 		},
 		onLoad: function(option) {
-			// #ifndef MP
+			const that = this;
 			if (option.spread) {
 				// 存储其他邀请人
 				uni.setStorageSync('spread', option.spread);
 			}
-			// #endif
 			// #ifdef MP
 			if (option.scene) {
 				// 存储小程序邀请人
@@ -251,25 +279,31 @@
 		},
 		// #endif
 		methods: {
+			// 打开小程序
+			openXcx(url) {
+				// #ifdef MP
+				wx.navigateToMiniProgram({
+					appId: "wx3fa16889ff680ac8",
+					path: url,
+				})
+				// #endif
+			},
 			getWorkerList() {
 				try {
 					getGoodWorkerList().then(res => {
 						let arr = []
-						// console.log(res,'basa');
 						res.data.list.forEach(item => {
 							let cc = false
 							arr.forEach(itemt => {
-								if(itemt.uid == item.uid) {
+								if (itemt.uid == item.uid) {
 									cc = true
 								}
 							})
-							if(!cc) {
+							if (!cc) {
 								arr.push(item)
-								// console.log(item,arr);
 							}
 						})
 						this.jxList = arr
-						// console.log(arr,this.jxList,'dddddd');
 					})
 				} catch (e) {
 					//TODO handle the exception
@@ -281,39 +315,34 @@
 				try {
 					getNewWorkerList().then(res => {
 						let arr = []
-						// console.log(res,'basa');
 						res.data.list.forEach(item => {
 							let cc = false
 							arr.forEach(itemt => {
-								if(itemt.uid == item.uid) {
+								if (itemt.uid == item.uid) {
 									cc = true
 								}
 							})
-							if(!cc) {
+							if (!cc) {
 								arr.push(item)
-								// console.log(item,arr);
 							}
 						})
 						this.zxList = arr
-						// console.log(arr,this.jxList,'dddddd');
 					})
 				} catch (e) {
 					//TODO handle the exception
 					console.log(e);
 				}
-			
+
 			},
 			swiperChange() {
 
 			},
 			share() {
-				// console.log('加载分享');
 				const that = this;
 				// 请求获取默认数据
 				share({}).then(({
 					data
 				}) => {
-					// console.log('分享回调', data);
 					that.shareData = data.data
 				});
 			},
@@ -325,7 +354,18 @@
 				getBannerList().then(
 					(res) => {
 						that.imagelist = res.data.list
-						// console.log(res);
+					}
+				).catch(
+					(res) => {
+						console.log(res);
+					}
+				)
+				// 获取广告
+				getBannerList({
+					page_id: 71
+				}).then(
+					(res) => {
+						that.textList = res.data.list
 					}
 				).catch(
 					(res) => {
@@ -343,7 +383,6 @@
 							res.old_price = +res.old_price
 							return res
 						})
-						// console.log(res);
 					}
 				).catch(
 					(res) => {
@@ -542,6 +581,7 @@
 				box-shadow: 0px 0px 20rpx 0px rgba(50, 50, 52, 0.06);
 				border-radius: 15rpx;
 				margin-bottom: 20rpx;
+
 				.list-image-box {
 					width: 330rpx;
 					height: 420rpx;
@@ -608,6 +648,7 @@
 		&:first-of-type {
 			border-top: none;
 		}
+
 		margin-bottom: 20rpx;
 		box-shadow: 0rpx 0rpx 20rpx 0rpx rgba(46, 46, 49, 0.06);
 		border-radius: 20rpx;
@@ -681,14 +722,17 @@
 		flex-wrap: wrap;
 		padding: 30rpx 0;
 	}
+
 	.banner {
 		image {
-			width: 691rpx;
+			width: 348rpx;
 			margin: auto;
 		}
+
 		padding: 20rpx 0;
 	}
-	.footer{
+
+	.footer {
 		text-align: center;
 		color: $font-color-light;
 		margin-top: 30rpx;

+ 0 - 2
pages/index/list.vue

@@ -108,7 +108,6 @@
 			},
 			getrecommendList() {
 				recommend().then(res => {
-					console.log(res);
 					this.recommendList = res.data.recommendList
 				})
 			},
@@ -127,7 +126,6 @@
 					page: item.page,
 					pageSize: item.pageSize
 				}).then(res => {
-					console.log(res);
 					item.list = item.list.concat(res.data.grlist)
 					item.page++
 					if(item.pageSize == res.data.grlist.length) {

+ 103 - 52
pages/modelData/index.vue

@@ -1,63 +1,114 @@
-<template>
-	<view>
-		<model1 :shareNumber='shareNumber' :isDefault='isDefault' v-if="modelId==3||modelId==1" :templateDetail='templateData' :isShare='isShare' :isLook='isLook'></model1>
-		<model2 :shareNumber='shareNumber' :isDefault='isDefault' v-if="modelId==4" :templateDetail='templateData' :isShare='isShare' :isLook='isLook'></model2>
-		<model3 :shareNumber='shareNumber' :isDefault='isDefault' v-if="modelId==5" :templateDetail='templateData' :isShare='isShare' :isLook='isLook'></model3>
-	</view>
-</template>
-
-<script>
+<template>
+	<view>
+		<model1 :shareNumber='shareNumber' @openImage='openImage' :isDefault='isDefault' v-if="modelId==3||modelId==1"
+			:templateDetail='templateData' :isShare='isShare' :isLook='isLook'></model1>
+		<model2 :shareNumber='shareNumber' @openImage='openImage' :isDefault='isDefault' v-if="modelId==4" :templateDetail='templateData'
+			:isShare='isShare' :isLook='isLook'></model2>
+		<model3 :shareNumber='shareNumber' @openImage='openImage' :isDefault='isDefault' v-if="modelId==5"  :templateDetail='templateData'
+			:isShare='isShare' :isLook='isLook'></model3>
+		<template v-if="templateData.service_imgs && templateData.service_imgs.length > 0">
+			<q-previewImage ref="previewImage" :urls="imageList" @open="open"
+				@close="close"></q-previewImage>
+		</template>
+	</view>
+</template>
+
+<script>
 	import model1 from './modeltemplate/model_1.vue';
-	import model2 from './modeltemplate/model_2.vue'
-	import model3 from './modeltemplate/model_3.vue'
-	export default {
+	import model2 from './modeltemplate/model_2.vue'
+	import model3 from './modeltemplate/model_3.vue'
+	export default {
 		props: {
 			// 浏览数量
 			shareNumber: {
 				type: Number,
-				default:0
+				default: 0
 			},
 			// 是否显示默认数据
-			isDefault: {
+			isDefault: {
 				type: Boolean,
-				default:true
-			},
-			templateData: {
-				type: Object,
-				default: ()=>{
-					return {}
-				}
-			},
-			isShare:{
-				type: Boolean,
-				default:false
-			},
-			//1为模板2为用户
-			isLook:{
-				type: Number,
-				default:0
-			},
-			modelId:{
-				type: Number,
-				default:0
-			},
+				default: true
+			},
+			templateData: {
+				type: Object,
+				default: () => {
+					return {}
+				}
+			},
+			isShare: {
+				type: Boolean,
+				default: false
+			},
+			//1为模板2为用户
+			isLook: {
+				type: Number,
+				default: 0
+			},
+			modelId: {
+				type: Number,
+				default: 0
+			},
 		},
-		components: {
+		components: {
 			model1,
 			model2,
-			model3
-		},
-		data() {
-			return {
-				model: 0
-			}
-		},
-		onLoad() {
-			console.log('233');
-			uni.postMessage('打开页面')
-		},
-		onUnload() {
-			uni.postMessage('关闭页面')
-		}
-	}
-</script>
+			model3
+		},
+		computed: {
+			imageList() {
+				try{
+					let templateData = this.templateData;
+					let arr = [];
+					if(templateData.service_intro_imgs && templateData.service_intro_imgs.length > 0){
+						arr = [...templateData.service_intro_imgs]
+					}
+					if (templateData.service_audit_imgs && templateData.service_audit_imgs.length > 0) {
+						arr = arr.concat(templateData.service_audit_imgs)
+					}
+					if (templateData.service_imgs && templateData.service_imgs.length > 0) {
+						arr = arr.concat(templateData.service_imgs)
+					}
+					return arr
+				}catch(e){
+					console.log(e,'eeee')
+					return []
+					//TODO handle the exception
+				}
+			}
+		},
+		methods: {
+			openImage(item) {
+				this.$nextTick(() => {
+					this.$refs.previewImage.open(item);
+				})
+			},
+			open() { //监听组件显示 (隐藏TabBar和NavigationBar,隐藏video原生组件)
+				// uni.hideTabBar()
+				// uni.setNavigationBarColor({
+				//   frontColor: '#000000', // 设置前景色为黑色
+				//   backgroundColor: '#000000', // 设置背景色为黑色
+				// })
+				// this.videoShow = false 
+			},
+			close() { //监听组件隐藏 (显示TabBar和NavigationBar,显示video原生组件)
+				// uni.showTabBar()
+				// uni.setNavigationBarColor({
+				//   frontColor: '#ffffff', // 设置前景色为白色
+				//   backgroundColor: '#000000', // 设置背景色为黑色
+				// })
+				// this.videoShow = true
+			}
+		},
+		data() {
+			return {
+				model: 0
+			}
+		},
+		onLoad() {
+			uni.postMessage('打开页面')
+		},
+		onUnload() {
+			uni.postMessage('关闭页面')
+		}
+	}
+</script>

+ 17 - 12
pages/modelData/modeltemplate/model_1.vue

@@ -48,7 +48,7 @@
 								从<text class="qianger"></text>业: {{(cardInfo.work_year + '年')|| '暂无'}}
 							</view>
 							<view class="info-item-b">
-								星<text class="qianger"></text>座: {{cardInfo.constellation || '暂无'}}
+								身<text class="qianger"></text>高: {{cardInfo.height*1+'厘米' || '暂无'}}
 							</view>
 							<!-- <view class="info-item-b">
 								职<text class="qianger"></text>业: {{cardInfo.user_work_type_title || '暂无'}}
@@ -57,7 +57,7 @@
 								籍<text class="qianger"></text>贯: {{cardInfo.ancestral_place || '暂无'}}
 							</view>
 							<view class="info-item-b">
-								民<text class="qianger"></text>族: {{cardInfo.minority || '暂无'}}
+								体<text class="qianger"></text>重: {{cardInfo.weight*1+'kg' || '暂无'}}
 							</view>
 							<view class="info-item-b">
 								学<text class="qianger"></text>历: {{cardInfo.education || '暂无'}}
@@ -77,8 +77,13 @@
 										海外
 									</view>
 								</view>
+								<view class="fwdz flex" v-if="cardInfo.is_china == 2">
+									<view >
+										全国
+									</view>
+								</view>
 							</view>
-							<view class="info-item-q flex" style="align-items: flex-start;">
+							<!-- <view class="info-item-q flex" style="align-items: flex-start;">
 								<text style="flex-shrink: 0;">服务价格: </text>
 								<view class="gzt">
 									<image :src="baseURL + '/resource/model/model1/tiao.png'" mode=""></image>
@@ -91,7 +96,7 @@
 								</view>
 								<image :src="baseURL + '/resource/model/model1/yrz.png'" mode="" class="rz"
 									v-if="cardInfo.is_type_audit == 1"></image>
-							</view>
+							</view> -->
 						</view>
 					</view>
 					<view class="" style="height: 80rpx;"></view>
@@ -110,7 +115,7 @@
 							<rich-text :nodes="cardInfo.service_intro_content"></rich-text>
 						</view>
 						<view class="img-list flex" style="padding-top: 0;">
-							<image :src="siiitem" mode="" v-for="siiitem in cardInfo.service_intro_imgs"></image>
+							<image @click="$emit('openImage',siiitem)" :src="siiitem" mode="" v-for="siiitem in cardInfo.service_intro_imgs"></image>
 						</view>
 					</view>
 				</view>
@@ -123,7 +128,7 @@
 						<image :src="baseURL + '/resource/model/model1/m3.png'" mode="" class="tit-logo"></image>我的证书
 					</view>
 					<view class="img-list flex">
-						<image :src="saiitem" mode="" v-for="saiitem in cardInfo.service_audit_imgs"></image>
+						<image @click="$emit('openImage',saiitem)" :src="saiitem" mode="" v-for="saiitem in cardInfo.service_audit_imgs"></image>
 					</view>
 				</view>
 			</view>
@@ -153,7 +158,7 @@
 					<image :src="baseURL + '/resource/model/model1/m5.png'" mode="" class="tit-logo"></image>服务照片
 				</view>
 				<view class="img-list flex">
-					<image :src="siitem" mode="" v-for="siitem in cardInfo.service_imgs"></image>
+					<image @click="$emit('openImage',siitem)" :src="siitem" mode="" v-for="siitem in cardInfo.service_imgs"></image>
 				</view>
 			</view>
 			<!-- 底部图片 -->
@@ -310,22 +315,22 @@
 				}
 			}
 			.top-user {
-				width: 222rpx;
-				height: 222rpx;
+				width: 272rpx;
+				height: 272rpx;
 				background: #FEFEFE;
 				box-shadow: 0rpx 0rpx 20rpx 0rpx rgba(50, 50, 52, 0.06);
 				border-radius: 50%;
 				position: absolute;
 				left: 0;
 				right: 0;
-				top: 80rpx;
+				top: 30rpx;
 				justify-content: center;
 				align-items: center;
 				margin: auto;
 
 				.user-logo {
-					width: 200rpx;
-					height: 200rpx;
+					width: 250rpx;
+					height: 250rpx;
 					border-radius: 50%;
 					background-color: #fff;
 				}

+ 8 - 4
pages/modelData/modeltemplate/model_2.vue

@@ -79,6 +79,11 @@
 										海外
 									</view>
 								</view>
+								<view class="fwdz flex" v-if="cardInfo.is_china == 2">
+									<view >
+										全国
+									</view>
+								</view>
 							</view>
 							<view class="info-item-q flex" style="align-items: flex-start;height: 110rpx;">
 								<text style="flex-shrink: 0;">服务价格: </text>
@@ -113,7 +118,7 @@
 							<rich-text :nodes="cardInfo.service_intro_content"></rich-text>
 						</view>
 						<view class="img-list flex" style="padding-top: 0;">
-							<image :src="siiitem" mode="" v-for="siiitem in cardInfo.service_intro_imgs"></image>
+							<image @click="$emit('openImage',siiitem)" :src="siiitem" mode="" v-for="siiitem in cardInfo.service_intro_imgs"></image>
 						</view>
 					</view>
 				</view>
@@ -125,7 +130,7 @@
 						<image :src="baseURL + '/resource/icon/model2/wdzs.png'" mode="" class=""></image>
 					</view>
 					<view class="img-list flex">
-						<image :src="saiitem" mode="" v-for="saiitem in cardInfo.service_audit_imgs"></image>
+						<image @click="$emit('openImage',saiitem)" :src="saiitem" mode="" v-for="saiitem in cardInfo.service_audit_imgs"></image>
 					</view>
 				</view>
 			</view>
@@ -155,7 +160,7 @@
 							<image :src="baseURL + '/resource/icon/model2/fwzp.png'" mode="" class=""></image>
 						</view>
 						<view class="img-list flex">
-							<image :src="siitem" mode="" v-for="siitem in cardInfo.service_imgs"></image>
+							<image @click="$emit('openImage',siitem)" :src="siitem" mode="" v-for="siitem in cardInfo.service_imgs"></image>
 						</view>
 					</view>
 				</view>
@@ -263,7 +268,6 @@
 		computed: {
 			...mapState(['baseURL']),
 			cardInfo() {
-				console.log("进入");
 				if (this.isDefault) {
 					return this.defaults
 				} else {

+ 669 - 644
pages/modelData/modeltemplate/model_3.vue

@@ -1,261 +1,272 @@
-<template>
-	<view class="mone">
-		<view class="top-left-icon-1"></view>
-		<view class="top-center-icon-1"></view>
-		<view class="top-center-icon-2"></view>
-		<view class="top-right-icon-1 icon-box-border">
-			<view class="top-right-content icon-box-content">
-			</view>
-		</view>
-		<view class="user-bottom-icon icon-box-border">
-			<view class="user-bottom-content icon-box-content">
-			</view>
-		</view>
-		<image class="user-top-icon" :src="baseURL + '/resource/model/static/model3/tap3.png'" mode="scaleToFill"></image>
-		<image class="user-right-logo" :src="baseURL + '/resource/model/model3/tap13.png'" mode="widthFix"></image>
-		<view class="user-img">
-			<image class="image" :src="cardInfo.avatar" mode="widthFix"></image>
-		</view>
-		<image class="content-left-icon" :src="baseURL + '/resource/model/model3/tap6.png'" mode="widthFix"></image>
-		<image class="page-bottom-right" :src="baseURL + '/resource/model/model3/tap7.png'" mode="widthFix"></image>
-		<view class="share-number">
-			浏览:{{shareNumber}}
-		</view>
-		<view class="right-content">
-			<view class="name">
-				{{cardInfo.name || '暂无'}}
-			</view>
-			<view class="career margin-t-10">
-				职业:{{cardInfo.user_work_type_title || '暂无'}}
-			</view>
-			<view class="career margin-t-10">
-				编号:{{cardInfo.no}}
-			</view>
-			<image class="line-icon margin-t-10" :src="baseURL + '/resource/model/model3/tap11.png'" mode="widthFix"></image>
-		</view>
-		<image class="right-center-icon" :src="baseURL + '/resource/model/model3/tap5.png'" mode="widthFix"></image>
-		<view class="content ">
-			<view class="icon-round-min">
-
-			</view>
-			<view class="icon-round-base">
-
-			</view>
-			<view class="content-icon-right icon-box-border">
-				<view class="content-right-content icon-box-content">
-				</view>
-			</view>
-			<view class="center-data flex">
-				<view class="left">
-					<view class="list-item">
-						年龄: {{cardInfo.age|| '暂无'}}
-					</view>
-					<view class="list-item">
-						从业: {{(cardInfo.work_year + '年')|| '暂无'}}
-					</view>
-					<view class="list-item">
-						籍贯: {{cardInfo.ancestral_place || '暂无'}}
-					</view>
-					<view class="list-item">
-						学历: {{cardInfo.education || '暂无'}}
-					</view>
-				</view>
-				<view class="right">
-					<view class="list-item">
-						属相:{{cardInfo.twelve|| '暂无'}}
-					</view>
-					<view class="list-item">
-						星座:{{cardInfo.constellation || '暂无'}}
-					</view>
-					<view class="list-item">
-						民族: {{cardInfo.minority || '暂无'}}
+<template>
+	<view class="mone">
+		<view class="top-left-icon-1"></view>
+		<view class="top-center-icon-1"></view>
+		<view class="top-center-icon-2"></view>
+		<view class="top-right-icon-1 icon-box-border">
+			<view class="top-right-content icon-box-content">
+			</view>
+		</view>
+		<view class="user-bottom-icon icon-box-border">
+			<view class="user-bottom-content icon-box-content">
+			</view>
+		</view>
+		<image class="user-top-icon" :src="baseURL + '/resource/model/static/model3/tap3.png'" mode="scaleToFill">
+		</image>
+		<image class="user-right-logo" :src="baseURL + '/resource/model/model3/tap13.png'" mode="widthFix"></image>
+		<view class="user-img">
+			<image class="image" :src="cardInfo.avatar" mode="widthFix"></image>
+		</view>
+		<image class="content-left-icon" :src="baseURL + '/resource/model/model3/tap6.png'" mode="widthFix"></image>
+		<image class="page-bottom-right" :src="baseURL + '/resource/model/model3/tap7.png'" mode="widthFix"></image>
+		<view class="share-number">
+			浏览:{{shareNumber}}
+		</view>
+		<view class="right-content">
+			<view class="name">
+				{{cardInfo.name || '暂无'}}
+			</view>
+			<view class="career margin-t-10">
+				职业:{{cardInfo.user_work_type_title || '暂无'}}
+			</view>
+			<view class="career margin-t-10">
+				编号:{{cardInfo.no}}
+			</view>
+			<image class="line-icon margin-t-10" :src="baseURL + '/resource/model/model3/tap11.png'" mode="widthFix">
+			</image>
+		</view>
+		<image class="right-center-icon" :src="baseURL + '/resource/model/model3/tap5.png'" mode="widthFix"></image>
+		<view class="content ">
+			<view class="icon-round-min">
+
+			</view>
+			<view class="icon-round-base">
+
+			</view>
+			<view class="content-icon-right icon-box-border">
+				<view class="content-right-content icon-box-content">
+				</view>
+			</view>
+			<view class="center-data flex">
+				<view class="left">
+					<view class="list-item">
+						年龄: {{cardInfo.age|| '暂无'}}
+					</view>
+					<view class="list-item">
+						从业: {{(cardInfo.work_year + '年')|| '暂无'}}
+					</view>
+					<view class="list-item">
+						籍贯: {{cardInfo.ancestral_place || '暂无'}}
+					</view>
+					<view class="list-item">
+						学历: {{cardInfo.education || '暂无'}}
+					</view>
+				</view>
+				<view class="right">
+					<view class="list-item">
+						属相:{{cardInfo.twelve|| '暂无'}}
+					</view>
+					<view class="list-item">
+						星座:{{cardInfo.constellation || '暂无'}}
+					</view>
+					<view class="list-item">
+						民族: {{cardInfo.minority || '暂无'}}
 					</view>
 					<view class="list-item">
 						服务次数: {{cardInfo.service_count || '0'}}
-					</view>
-				</view>
-			</view>
-			<view class="list-item padding-l-30 margin-b-30">
-				服务地区:
-				<block v-for="(fwitem,fwindex) in cardInfo.service_area_all" v-if="cardInfo.is_china == 1">
-					{{fwitem}}{{fwindex ==(cardInfo.service_area_all.length -1) ?'': '、'  }}
-				</block>
-				<block v-if="cardInfo.is_china == 0">
-					海外
-				</block>
-			</view>
-			<view class="info-item-q flex-start ">
-				<text class="flex-shrink-false">服务价格: </text>
-				<view class="gzt">
-					<view class="line-box flex">
-						<view class="item" v-for="i in 18"></view>
-					</view>
-					<view class="gzt-price">
-						<text
-							class="money">{{cardInfo.service_min_price}}</text>元/{{ cardInfo.service_time_type_title && cardInfo.service_time_type_title.replace('每','')}}
-					</view>
-					<view class=" gzt-price-b">
-						<text
-							class="money">{{cardInfo.service_max_price}}</text>元/{{cardInfo.service_time_type_title && cardInfo.service_time_type_title.replace('每','')}}
-					</view>
-				</view>
-				<image :src="baseURL + '/resource/icon/model1/yrz.png'" mode="" class="rz"
-					v-if="cardInfo.is_type_audit == 1"></image>
-			</view>
-		</view>
-		<view class="content-text">
-			<view class="flex margin-b-20">
-				<view class="name">
-					自我评价
-				</view>
-				<image class="icon" :src="baseURL + '/resource/model/model3/tap13.png'" mode="widthFix"></image>
-			</view>
-			<view class="flex">
-				<view></view>
-				<image class="line" :src="baseURL + '/resource/model/model3/tap11.png'" mode="widthFix"></image>
-			</view>
-			<view class="text margin-t-20">
-				<rich-text :nodes="cardInfo.service_intro_content"></rich-text>
-			</view>
-			<view class="img-list flex">
-				<image :src="siiitem" mode="scaleToFill" v-for="siiitem in cardInfo.service_intro_imgs"></image>
-			</view>
-		</view>
-		
-		<view class="content-text" >
-			<view class="flex margin-b-20">
-				<view class="name">
-					我的证书
-				</view>
-				<image class="icon" :src="baseURL + '/resource/model/model3/tap13.png'" mode="widthFix"></image>
-			</view>
-			<view class="flex">
-				<view></view>
-				<image class="line" :src="baseURL + '/resource/model/model3/tap11.png'" mode="widthFix"></image>
-			</view>
-			<view class="img-list flex" >
-				<image :src="siiitem" mode="scaleToFill" v-for="siiitem in cardInfo.service_audit_imgs"></image>
-			</view>
-		</view>
-		<view class="content-text">
-			<view class="flex margin-b-20">
-				<view class="name">
-					服务内容
-				</view>
-				<image class="icon" :src="baseURL + '/resource/model/model3/tap13.png'" mode="widthFix"></image>
-			</view>
-			<view class="flex">
-				<view></view>
-				<image class="line" :src="baseURL + '/resource/model/model3/tap11.png'" mode="widthFix"></image>
-			</view>
-			<view class="card-content">
-				<view class="fw" v-for="spaitem in cardInfo.service_project_ar">
-					<view class="fw-tit">
-						<text class="yg"></text>{{spaitem.title}}
-					</view>
-					<view class="fw-content">
-						{{spaitem.content}}
-					</view>
-				</view>
-			</view>
-		</view>
-		<view class="content-text">
-			<view class="flex margin-b-20">
-				<view class="name">
-					服务照片
-				</view>
-				<image class="icon" :src="baseURL + '/resource/model/model3/tap13.png'" mode="widthFix"></image>
-			</view>
-			<view class="flex">
-				<view></view>
-				<image class="line" :src="baseURL + '/resource/model/model3/tap11.png'" mode="widthFix"></image>
-			</view>
-			<view class="img-list flex" >
-				<image :src="siiitem" mode="scaleToFill" v-for="siiitem in cardInfo.service_imgs"></image>
-			</view>
-		</view>
-	</view>
-</template>
-
-<script>
-	import {
-		mapState,
-	} from 'vuex';
-	export default {
-		props: {
-			// 浏览数量
-			shareNumber: {
-				type: Number,
-				default: 0
-			},
-			// 是否显示默认数据
-			isDefault: {
-				type: Boolean,
-				default: true
-			},
-			isShare: {
-				type: Boolean,
-				default: false
-			},
-			//1为模板2为用户
-			isLook: {
-				type: Number,
-				default: 0
-			},
-			templateDetail: {
-				type: Object,
-				default: () => {
-					return {}
-				}
-			}
-		},
-		data() {
-			return {
+					</view>
+				</view>
+			</view>
+			<view class="list-item padding-l-30 margin-b-30 flex-start">
+				<view class="fwdqTop">
+					服务地区:
+				</view>
+				<view>
+					<view class="fwdq" v-if="cardInfo.is_china == 1">
+						<view v-for="(fwitem,fwindex) in cardInfo.service_area_all">
+							{{fwitem}}{{fwindex ==(cardInfo.service_area_all.length -1) ?'': ''  }}
+						</view>
+					</view>
+					<view v-if="cardInfo.is_china == 0">
+						海外
+					</view>
+					<view v-if="cardInfo.is_china == 2">
+							全国
+					</view>
+				</view>
+			</view>
+			<view class="info-item-q flex-start ">
+				<text class="flex-shrink-false">服务价格: </text>
+				<view class="gzt">
+					<view class="line-box flex">
+						<view class="item" v-for="i in 18"></view>
+					</view>
+					<view class="gzt-price">
+						<text
+							class="money">{{cardInfo.service_min_price}}</text>元/{{ cardInfo.service_time_type_title && cardInfo.service_time_type_title.replace('每','')}}
+					</view>
+					<view class=" gzt-price-b">
+						<text
+							class="money">{{cardInfo.service_max_price}}</text>元/{{cardInfo.service_time_type_title && cardInfo.service_time_type_title.replace('每','')}}
+					</view>
+				</view>
+				<image :src="baseURL + '/resource/icon/model1/yrz.png'" mode="" class="rz"
+					v-if="cardInfo.is_type_audit == 1"></image>
+			</view>
+		</view>
+		<view class="content-text">
+			<view class="flex margin-b-20">
+				<view class="name">
+					自我评价
+				</view>
+				<image class="icon" :src="baseURL + '/resource/model/model3/tap13.png'" mode="widthFix"></image>
+			</view>
+			<view class="flex">
+				<view></view>
+				<image class="line" :src="baseURL + '/resource/model/model3/tap11.png'" mode="widthFix"></image>
+			</view>
+			<view class="text margin-t-20">
+				<rich-text :nodes="cardInfo.service_intro_content"></rich-text>
+			</view>
+			<view class="img-list flex">
+				<image  @click="$emit('openImage',siiitem)" :src="siiitem" mode="scaleToFill" v-for="siiitem in cardInfo.service_intro_imgs"></image>
+			</view>
+		</view>
+
+		<view class="content-text">
+			<view class="flex margin-b-20">
+				<view class="name">
+					我的证书
+				</view>
+				<image class="icon" :src="baseURL + '/resource/model/model3/tap13.png'" mode="widthFix"></image>
+			</view>
+			<view class="flex">
+				<view></view>
+				<image class="line" :src="baseURL + '/resource/model/model3/tap11.png'" mode="widthFix"></image>
+			</view>
+			<view class="img-list flex">
+				<image @click="$emit('openImage',siiitem)" :src="siiitem" mode="scaleToFill" v-for="siiitem in cardInfo.service_audit_imgs"></image>
+			</view>
+		</view>
+		<view class="content-text">
+			<view class="flex margin-b-20">
+				<view class="name">
+					服务内容
+				</view>
+				<image class="icon" :src="baseURL + '/resource/model/model3/tap13.png'" mode="widthFix"></image>
+			</view>
+			<view class="flex">
+				<view></view>
+				<image class="line" :src="baseURL + '/resource/model/model3/tap11.png'" mode="widthFix"></image>
+			</view>
+			<view class="card-content">
+				<view class="fw" v-for="spaitem in cardInfo.service_project_ar">
+					<view class="fw-tit">
+						<text class="yg"></text>{{spaitem.title}}
+					</view>
+					<view class="fw-content">
+						{{spaitem.content}}
+					</view>
+				</view>
+			</view>
+		</view>
+		<view class="content-text">
+			<view class="flex margin-b-20">
+				<view class="name">
+					服务照片
+				</view>
+				<image class="icon" :src="baseURL + '/resource/model/model3/tap13.png'" mode="widthFix"></image>
+			</view>
+			<view class="flex">
+				<view></view>
+				<image class="line" :src="baseURL + '/resource/model/model3/tap11.png'" mode="widthFix"></image>
+			</view>
+			<view class="img-list flex">
+				<image @click="$emit('openImage',siiitem)" :src="siiitem" mode="scaleToFill" v-for="siiitem in cardInfo.service_imgs"></image>
+			</view>
+		</view>
+	</view>
+</template>
+
+<script>
+	import {
+		mapState,
+	} from 'vuex';
+	export default {
+		props: {
+			// 浏览数量
+			shareNumber: {
+				type: Number,
+				default: 0
+			},
+			// 是否显示默认数据
+			isDefault: {
+				type: Boolean,
+				default: true
+			},
+			isShare: {
+				type: Boolean,
+				default: false
+			},
+			//1为模板2为用户
+			isLook: {
+				type: Number,
+				default: 0
+			},
+			templateDetail: {
+				type: Object,
+				default: () => {
+					return {}
+				}
+			}
+		},
+		data() {
+			return {
 				defaultDate: {
-					user_work_type_title: '母婴护理师',
-					name: '陈旦',
-					avatar: 'https://api.myjie.cn/resource/user/user3/ld.png',
-					age: '40',
-					twelve: '猪',
-					work_year: '9',
-					constellation: '处女座',
-					ancestral_place: '广西',
-					minority: '汉族',
-					education: '初中',
-					no: 'myj23031421',
-					service_area_all: ['上海市'],
-					service_min_price: 16800,
-					service_max_price: 19800,
-					user_work_type_title: '母婴师',
-					service_time_type_title: '每月',
-					service_intro_content: '本人从事月嫂工作已经9年多了,顺产剖腹产的妈妈都照顾过,宝宝方面的新生儿,早产儿足月生产儿、双胞胎都照顾过,累积了丰富的经验,现在对于月嫂的这份工作得心应手。我秉承着不怕苦,不怕累,对工作认真负责的态度,帮助过很多需要的家庭。这些年也一直靠客户的口碑宣传接单工作,很感谢客户对我工作的认可。我严格要求自己待客户如家人,视宝宝如己出,我会用自己的爱心,细心,耐心和学到的专业知识去赢得每一个客户的认可。',
-					service_intro_imgs: ['https://api.myjie.cn/resource/user/user3/zwpj1.png',
-						'https://api.myjie.cn/resource/user/user3/zwpj2.png',
-						'https://api.myjie.cn/resource/user/user3/zwpj3.png',
+					user_work_type_title: '母婴护理师',
+					name: '陈旦',
+					avatar: 'https://api.myjie.cn/resource/user/user3/ld.png',
+					age: '40',
+					twelve: '猪',
+					work_year: '9',
+					constellation: '处女座',
+					ancestral_place: '广西',
+					minority: '汉族',
+					education: '初中',
+					no: 'myj23031421',
+					service_area_all: ['上海市'],
+					service_min_price: 16800,
+					service_max_price: 19800,
+					user_work_type_title: '母婴师',
+					service_time_type_title: '每月',
+					service_intro_content: '本人从事月嫂工作已经9年多了,顺产剖腹产的妈妈都照顾过,宝宝方面的新生儿,早产儿足月生产儿、双胞胎都照顾过,累积了丰富的经验,现在对于月嫂的这份工作得心应手。我秉承着不怕苦,不怕累,对工作认真负责的态度,帮助过很多需要的家庭。这些年也一直靠客户的口碑宣传接单工作,很感谢客户对我工作的认可。我严格要求自己待客户如家人,视宝宝如己出,我会用自己的爱心,细心,耐心和学到的专业知识去赢得每一个客户的认可。',
+					service_intro_imgs: ['https://api.myjie.cn/resource/user/user3/zwpj1.png',
+						'https://api.myjie.cn/resource/user/user3/zwpj2.png',
+						'https://api.myjie.cn/resource/user/user3/zwpj3.png',
 						'https://api.myjie.cn/resource/user/user3/zwpj4.png',
 						'https://api.myjie.cn/resource/user/user3/zwpj5.png',
-						'https://api.myjie.cn/resource/user/user3/zwpj6.png'
-					],
-					service_audit_imgs: ['https://api.myjie.cn/resource/user/user3/zs1.png',
-						'https://api.myjie.cn/resource/user/user3/zs2.png',
-						'https://api.myjie.cn/resource/user/user3/zs3.png',
-						'https://api.myjie.cn/resource/user/user3/zs4.png'
-					],
-					service_project_ar: [{
-							title: '婴幼儿睡眠管理',
-							content: '如:日夜颠倒、睡眠不规律、乳头混淆、奶睡、抱睡等问题,帮助宝爸宝妈规律孩子作息、解决婴幼儿喂养困扰,培养良好的生活、学习习惯。'
-						}, {
-							title: '特色月子餐',
-							content: '套用客户的一句话“养眼、养心更养胃”!家常菜、面食、点心、甜品、靓汤、五谷杂粮粥、婴幼儿花样辅食等。'
-						},
-						{
-							title: '早产儿特殊护理',
-							content: '包括早产儿基础护理、安全喂养方法、追赶性生长、消化与免疫系统等技能,根据宝宝具体情况给予早产儿家长的科学入户指导。'
-						},
-						{
-							title: '0-6岁早期教育',
-							content: '在婴孩最敏感最能接受的时期进行事半功倍的适时教育,针对不同年龄段的孩子,开发婴幼儿潜能的教育,为孩子多元化和健康人格打下良好基础。'
-						}
+						'https://api.myjie.cn/resource/user/user3/zwpj6.png'
+					],
+					service_audit_imgs: ['https://api.myjie.cn/resource/user/user3/zs1.png',
+						'https://api.myjie.cn/resource/user/user3/zs2.png',
+						'https://api.myjie.cn/resource/user/user3/zs3.png',
+						'https://api.myjie.cn/resource/user/user3/zs4.png'
+					],
+					service_project_ar: [{
+							title: '婴幼儿睡眠管理',
+							content: '如:日夜颠倒、睡眠不规律、乳头混淆、奶睡、抱睡等问题,帮助宝爸宝妈规律孩子作息、解决婴幼儿喂养困扰,培养良好的生活、学习习惯。'
+						}, {
+							title: '特色月子餐',
+							content: '套用客户的一句话“养眼、养心更养胃”!家常菜、面食、点心、甜品、靓汤、五谷杂粮粥、婴幼儿花样辅食等。'
+						},
+						{
+							title: '早产儿特殊护理',
+							content: '包括早产儿基础护理、安全喂养方法、追赶性生长、消化与免疫系统等技能,根据宝宝具体情况给予早产儿家长的科学入户指导。'
+						},
+						{
+							title: '0-6岁早期教育',
+							content: '在婴孩最敏感最能接受的时期进行事半功倍的适时教育,针对不同年龄段的孩子,开发婴幼儿潜能的教育,为孩子多元化和健康人格打下良好基础。'
+						}
 					],
 					service_imgs: [
 						'https://api.myjie.cn/resource/user/user3/fw1.png',
@@ -264,399 +275,413 @@
 						'https://api.myjie.cn/resource/user/user3/fw4.png',
 						'https://api.myjie.cn/resource/user/user3/fw5.png',
 						'https://api.myjie.cn/resource/user/user3/fw6.png',
-					],
+					],
 					is_type_audit: 1,
 					service_count: 0,
-					is_china: 1
-				}
-			}
-		},
-		computed: {
-			...mapState(['baseURL']),
-			cardInfo() {
-				if (this.isDefault) {
-					return this.defaultDate
-				} else {
-					return this.templateDetail
-				}
-			}
-		},
-	}
-</script>
-
-<style lang="scss" scoped>
-	.mone {
-		padding-bottom: 150rpx;
-		background-color: #FFFFFF;
-		min-height: 100vh;
-		padding-top: 580rpx;
-		position: relative;
-		.top-left-icon-1 {
-			background-color: rgba(15, 61, 96, 1);
-			border-bottom-right-radius: 110rpx;
-			width: 250rpx;
-			height: 200rpx;
-			position: absolute;
-			top: -120rpx;
-			left: -130rpx;
-		}
-
-		.top-center-icon-1 {
-			border-radius: 100rpx;
-			width: 60rpx;
-			height: 60rpx;
-			position: absolute;
-			border: 1px solid rgba(43, 117, 180, 1);
-			top: 50rpx;
-			left: 310rpx;
-		}
-
-		.top-center-icon-2 {
-			border-radius: 100rpx;
-			width: 35rpx;
-			height: 35rpx;
-			position: absolute;
-			border: 1px solid rgba(215, 215, 215, 1);
-			top: 125rpx;
-			left: 525rpx;
-		}
-
-		.top-right-icon-1 {
-			padding: 30rpx;
-			width: 200rpx;
-			height: 200rpx;
-			border: 1px dashed rgba(215, 215, 215, 1);
-			top: -100rpx;
-			right: -50rpx;
-
-			.top-right-content {
-				background-color: rgba(215, 215, 215, 1);
-			}
-		}
-
-		.user-top-icon {
-			width: 106rpx;
-			height: 97rpx;
-			position: absolute;
-			top: 157rpx;
-			left: 205rpx;
-		}
-
-		.user-right-logo {
-			width: 235rpx;
-			position: absolute;
-			top: 246rpx;
-			right: 154rpx;
-		}
-
-		.user-img {
-			width: 280rpx;
-			height: 280rpx;
-			border: 3px solid #FFFFFF;
-			border-radius: 200rpx;
-			position: absolute;
-			top: 186rpx;
-			left: 50rpx;
-			overflow: hidden;
-
-			.image {
-				width: 100%;
-			}
-		}
-
-		.user-bottom-icon {
-			padding: 30rpx;
-			width: 210rpx;
-			height: 210rpx;
-			border: 1px dashed rgba(15, 61, 96, 1);
-			top: 380rpx;
-			left: 36rpx;
-
-			.user-bottom-content {
-				background-color: rgba(15, 61, 96, 1);
-			}
-		}
-
-		.share-number {
-			border-top-left-radius: 99rpx;
-			border-bottom-left-radius: 99rpx;
-			font-size: $font-base;
-			color: #266B9E;
-			border: 2px solid #266B9E;
-			position: absolute;
-			top: 150rpx;
-			right: 0rpx;
-			line-height: 1;
-			padding: 10rpx;
-			padding-left: 25rpx;
-		}
-
-		.right-content {
-			position: absolute;
-			right: 0;
-			top: 350rpx;
-			width: 390rpx;
-
-			.name {
-				font-size: 60rpx;
-				font-family: FZYanSongS-DB-GB;
-				color: #266B9E;
-			}
-
-			.career {
-				font-size: 30rpx;
-				font-family: FZYanSongS-DB-GB;
-				color: #266B9E;
-			}
-
-			.line-icon {
-				width: 360rpx;
-			}
-		}
-
-		.right-center-icon {
-			width: 190rpx;
-			position: absolute;
-			top: 900rpx;
-			right: 0;
-		}
-		.page-bottom-right{
-			width: 188rpx;
-			position: absolute;
-			bottom: 130rpx;
-			right: 0;
-		}
-	}
-
-	.icon-box-border {
-		border-radius: 1000rpx;
-		position: absolute;
-
-		.icon-box-content {
-			width: 100%;
-			height: 100%;
-			border-radius: 900rpx;
-		}
-	}
-	.content-left-icon{
-		width: 86rpx;
-		position: absolute;
-		top: 1800rpx;
-		left: 0rpx;
-	}
-	.content-text {
-		margin: 30rpx;
-		padding: 55rpx;
-		background-color: rgba(245, 248, 250, 1);
-		position: relative;
-		.card-content {
-			font-size: 26rpx;
-			font-weight: 500;
-			color: #2C2E35;
-			position: relative;
-			.fw {
-				font-size: 26rpx;
-				font-weight: 500;
-				color: #2C2E35;
-				padding: 10rpx 0;
-			
-				.fw-tit {
-					color: #266B9E;
-					display: flex;
-					align-items: center;
-			
-					.yg {
-						background-color: #266B9E;
-						display: inline-block;
-						width: 10rpx;
-						height: 10rpx;
-						border-radius: 50%;
-						margin-right: 10rpx;
-					}
-				}
-			
-				.fw-content {
-					padding-top: 10rpx;
-					padding-left: 18rpx;
+					is_china: 1
+				}
+			}
+		},
+		computed: {
+			...mapState(['baseURL']),
+			cardInfo() {
+				if (this.isDefault) {
+					return this.defaultDate
+				} else {
+					return this.templateDetail
+				}
+			}
+		},
+	}
+</script>
+
+<style lang="scss" scoped>
+	.mone {
+		padding-bottom: 150rpx;
+		background-color: #FFFFFF;
+		min-height: 100vh;
+		padding-top: 580rpx;
+		position: relative;
+
+		.top-left-icon-1 {
+			background-color: rgba(15, 61, 96, 1);
+			border-bottom-right-radius: 110rpx;
+			width: 250rpx;
+			height: 200rpx;
+			position: absolute;
+			top: -120rpx;
+			left: -130rpx;
+		}
+
+		.top-center-icon-1 {
+			border-radius: 100rpx;
+			width: 60rpx;
+			height: 60rpx;
+			position: absolute;
+			border: 1px solid rgba(43, 117, 180, 1);
+			top: 50rpx;
+			left: 310rpx;
+		}
+
+		.top-center-icon-2 {
+			border-radius: 100rpx;
+			width: 35rpx;
+			height: 35rpx;
+			position: absolute;
+			border: 1px solid rgba(215, 215, 215, 1);
+			top: 125rpx;
+			left: 525rpx;
+		}
+
+		.top-right-icon-1 {
+			padding: 30rpx;
+			width: 200rpx;
+			height: 200rpx;
+			border: 1px dashed rgba(215, 215, 215, 1);
+			top: -100rpx;
+			right: -50rpx;
+
+			.top-right-content {
+				background-color: rgba(215, 215, 215, 1);
+			}
+		}
+
+		.user-top-icon {
+			width: 106rpx;
+			height: 97rpx;
+			position: absolute;
+			top: 157rpx;
+			left: 205rpx;
+		}
+
+		.user-right-logo {
+			width: 235rpx;
+			position: absolute;
+			top: 246rpx;
+			right: 154rpx;
+		}
+
+		.user-img {
+			width: 280rpx;
+			height: 280rpx;
+			border: 3px solid #FFFFFF;
+			border-radius: 200rpx;
+			position: absolute;
+			top: 186rpx;
+			left: 50rpx;
+			overflow: hidden;
+
+			.image {
+				width: 100%;
+			}
+		}
+
+		.user-bottom-icon {
+			padding: 30rpx;
+			width: 210rpx;
+			height: 210rpx;
+			border: 1px dashed rgba(15, 61, 96, 1);
+			top: 380rpx;
+			left: 36rpx;
+
+			.user-bottom-content {
+				background-color: rgba(15, 61, 96, 1);
+			}
+		}
+
+		.share-number {
+			border-top-left-radius: 99rpx;
+			border-bottom-left-radius: 99rpx;
+			font-size: $font-base;
+			color: #266B9E;
+			border: 2px solid #266B9E;
+			position: absolute;
+			top: 150rpx;
+			right: 0rpx;
+			line-height: 1;
+			padding: 10rpx;
+			padding-left: 25rpx;
+		}
+
+		.right-content {
+			position: absolute;
+			right: 0;
+			top: 350rpx;
+			width: 390rpx;
+
+			.name {
+				font-size: 60rpx;
+				font-family: FZYanSongS-DB-GB;
+				color: #266B9E;
+			}
+
+			.career {
+				font-size: 30rpx;
+				font-family: FZYanSongS-DB-GB;
+				color: #266B9E;
+			}
+
+			.line-icon {
+				width: 360rpx;
+			}
+		}
+
+		.right-center-icon {
+			width: 190rpx;
+			position: absolute;
+			top: 900rpx;
+			right: 0;
+		}
+
+		.page-bottom-right {
+			width: 188rpx;
+			position: absolute;
+			bottom: 130rpx;
+			right: 0;
+		}
+	}
+
+	.icon-box-border {
+		border-radius: 1000rpx;
+		position: absolute;
+
+		.icon-box-content {
+			width: 100%;
+			height: 100%;
+			border-radius: 900rpx;
+		}
+	}
+
+	.content-left-icon {
+		width: 86rpx;
+		position: absolute;
+		top: 1800rpx;
+		left: 0rpx;
+	}
+
+	.content-text {
+		margin: 30rpx;
+		padding: 55rpx;
+		background-color: rgba(245, 248, 250, 1);
+		position: relative;
+
+		.card-content {
+			font-size: 26rpx;
+			font-weight: 500;
+			color: #2C2E35;
+			position: relative;
+
+			.fw {
+				font-size: 26rpx;
+				font-weight: 500;
+				color: #2C2E35;
+				padding: 10rpx 0;
+
+				.fw-tit {
+					color: #266B9E;
+					display: flex;
+					align-items: center;
+
+					.yg {
+						background-color: #266B9E;
+						display: inline-block;
+						width: 10rpx;
+						height: 10rpx;
+						border-radius: 50%;
+						margin-right: 10rpx;
+					}
+				}
+
+				.fw-content {
+					padding-top: 10rpx;
+					padding-left: 18rpx;
 					text-align: justify;
 					word-wrap: break-word;
-					white-space: pre-line;
-				}
-			
-			}
-		}
-		.name {
-			font-size: 65rpx;
-			font-family: FZYanSongS-DB-GB;
-			font-weight: bold;
-			background-color: #266B9E;
-			line-height: 60rpx;
-			padding: 20rpx 40rpx;
-			padding-bottom: 25rpx;
-			color: #FFF;
-		}
-
-		.icon {
-			width: 223rpx;
-		}
-
-		.line {
-			width: 400rpx;
-		}
-
-		.text {
-			line-height: 1.5;
-			font-size: 26rpx;
-			font-family: Adobe Heiti Std;
-		}
-	}
-
-	.content {
-		padding: 36rpx;
-		line-height: 1;
-		font-size: $font-base;
-		color: #266B9E;
-		font-weight: bold;
-		position: relative;
-		padding-bottom: 50rpx;
-		margin-bottom: 30rpx;
-
-		.content-icon-right {
-			position: absolute;
-			right: 50rpx;
-			top: 100rpx;
-			border: 1px solid #266B9E;
-			width: 75rpx;
-			height: 75rpx;
-			padding: 10rpx;
-
-			.content-right-content {
-				background-color: rgb(217, 217, 217);
-			}
-		}
-
-		.icon-round-min {
-			background-color: rgb(28, 109, 161);
-			border-radius: 100rpx;
-			width: 30rpx;
-			height: 30rpx;
-			position: absolute;
-			top: 30rpx;
-			left: 300rpx;
-		}
-
-		.icon-round-base {
-			background-color: rgb(28, 109, 161);
-			border-radius: 100rpx;
-			width: 60rpx;
-			height: 60rpx;
-			position: absolute;
-			top: 160rpx;
-			left: 280rpx;
-		}
-
-		.center-data {
-
-			align-items: flex-start;
-			border-left: 1px dashed #E6E6E6;
-
-			.left,
-			.right {
-				width: 50%;
-				padding-left: 30rpx;
-				text-align: left;
-			}
-
-			.list-item {
-				margin-bottom: 20rpx;
-			}
-		}
-
-		.info-item-q {
-			width: 100%;
-			display: flex;
-			align-items: flex-start;
-			justify-content: start;
-			padding-left: 30rpx;
-
-
-			.gzt {
-				width: 350rpx;
-				height: 24rpx;
-				position: relative;
-
-				.line-box {
-					width: 350rpx;
-					height: 24rpx;
-					position: relative;
-					background-color: rgb(36, 109, 179);
-					border-radius: 50rpx;
-					overflow: hidden;
-
-					.item {
-						margin-left: 10rpx;
-						background-color: #5294C9;
-						width: 10rpx;
-						height: 50rpx;
-						transform: rotate(18deg);
-					}
-				}
-
-				.gzt-price,
-				.gzt-price-b {
-					width: 200rpx;
-					text-align: center;
-					position: absolute;
-					padding-top: 20rpx;
-					color: $font-color-dark;
-
-					&::after {
-						content: '';
-						width: 0px;
-						height: 0rpx;
-						border: 14rpx solid;
-						border-color: transparent transparent #FEB8C6;
-						position: absolute;
-						top: -14rpx;
-						left: 0;
-						right: 0;
-						margin: auto;
-					}
-
-					text {
-						color: #236BA5;
-					}
-				}
-
-				.gzt-price {
-					left: -100rpx;
-				}
-
-				.gzt-price-b {
-					right: -100rpx;
-				}
-			}
-
-			.rz {
-				margin-left: 10rpx;
-				width: 87rpx;
-				height: 26rpx;
-			}
-		}
-	}
-
-	.img-list {
-		justify-content: space-between;
-		flex-wrap: wrap;
-		margin: auto;
-		position: relative;
-		padding-top: 50rpx;
-		image {
-			width: 270rpx;
-			height: 270rpx;
-			background-color: #fff;
-			margin-bottom: 30rpx;
-			box-shadow: 0px 0px 20rpx 0px rgba(50, 50, 52, 0.6);
-		}
-	}
-</style>
+					white-space: pre-line;
+				}
+
+			}
+		}
+
+		.name {
+			font-size: 65rpx;
+			font-family: FZYanSongS-DB-GB;
+			font-weight: bold;
+			background-color: #266B9E;
+			line-height: 60rpx;
+			padding: 20rpx 40rpx;
+			padding-bottom: 25rpx;
+			color: #FFF;
+		}
+
+		.icon {
+			width: 223rpx;
+		}
+
+		.line {
+			width: 400rpx;
+		}
+
+		.text {
+			line-height: 1.5;
+			font-size: 26rpx;
+			font-family: Adobe Heiti Std;
+		}
+	}
+
+	.content {
+		padding: 36rpx;
+		line-height: 1;
+		font-size: $font-base;
+		color: #266B9E;
+		font-weight: bold;
+		position: relative;
+		padding-bottom: 50rpx;
+		margin-bottom: 30rpx;
+
+		.content-icon-right {
+			position: absolute;
+			right: 50rpx;
+			top: 100rpx;
+			border: 1px solid #266B9E;
+			width: 75rpx;
+			height: 75rpx;
+			padding: 10rpx;
+
+			.content-right-content {
+				background-color: rgb(217, 217, 217);
+			}
+		}
+
+		.icon-round-min {
+			background-color: rgb(28, 109, 161);
+			border-radius: 100rpx;
+			width: 30rpx;
+			height: 30rpx;
+			position: absolute;
+			top: 30rpx;
+			left: 300rpx;
+		}
+
+		.icon-round-base {
+			background-color: rgb(28, 109, 161);
+			border-radius: 100rpx;
+			width: 60rpx;
+			height: 60rpx;
+			position: absolute;
+			top: 160rpx;
+			left: 280rpx;
+		}
+
+		.center-data {
+
+			align-items: flex-start;
+			border-left: 1px dashed #E6E6E6;
+
+			.left,
+			.right {
+				width: 50%;
+				padding-left: 30rpx;
+				text-align: left;
+			}
+
+			.list-item {
+				margin-bottom: 20rpx;
+				.fwdq {
+					flex-direction: column;
+				}
+			}
+		}
+
+		.info-item-q {
+			width: 100%;
+			display: flex;
+			align-items: flex-start;
+			justify-content: start;
+			padding-left: 30rpx;
+
+
+			.gzt {
+				width: 350rpx;
+				height: 24rpx;
+				position: relative;
+
+				.line-box {
+					width: 350rpx;
+					height: 24rpx;
+					position: relative;
+					background-color: rgb(36, 109, 179);
+					border-radius: 50rpx;
+					overflow: hidden;
+
+					.item {
+						margin-left: 10rpx;
+						background-color: #5294C9;
+						width: 10rpx;
+						height: 50rpx;
+						transform: rotate(18deg);
+					}
+				}
+
+				.gzt-price,
+				.gzt-price-b {
+					width: 200rpx;
+					text-align: center;
+					position: absolute;
+					padding-top: 20rpx;
+					color: $font-color-dark;
+
+					&::after {
+						content: '';
+						width: 0px;
+						height: 0rpx;
+						border: 14rpx solid;
+						border-color: transparent transparent #FEB8C6;
+						position: absolute;
+						top: -14rpx;
+						left: 0;
+						right: 0;
+						margin: auto;
+					}
+
+					text {
+						color: #236BA5;
+					}
+				}
+
+				.gzt-price {
+					left: -100rpx;
+				}
+
+				.gzt-price-b {
+					right: -100rpx;
+				}
+			}
+
+			.rz {
+				margin-left: 10rpx;
+				width: 87rpx;
+				height: 26rpx;
+			}
+		}
+	}
+
+	.img-list {
+		justify-content: space-between;
+		flex-wrap: wrap;
+		margin: auto;
+		position: relative;
+		padding-top: 50rpx;
+
+		image {
+			width: 270rpx;
+			height: 270rpx;
+			background-color: #fff;
+			margin-bottom: 30rpx;
+			box-shadow: 0px 0px 20rpx 0px rgba(50, 50, 52, 0.6);
+		}
+	}
+	.fwdqTop {
+		align-self: flex-start;
+	}
+</style>

+ 8 - 3
pages/public/artDetail.vue

@@ -15,7 +15,9 @@ export default {
 	data() {
 		return {
 			id: '',
-			item: ''
+			item: {
+				content:[]
+			}
 		};
 	},
 	onLoad(option) {
@@ -29,7 +31,7 @@ export default {
 		let url = currentPage.route; //当前页面url
 		let item = currentPage.options; //如果要获取url中所带的参数可以查看options
 		let shareObj = {
-			title: '水箱计算', // 默认是小程序的名称(可以写slogan等)
+			title: '母婴界数字名片', // 默认是小程序的名称(可以写slogan等)
 			path: url + '?id=' + item.id, // 默认是当前页面,必须是以‘/’开头的完整路径
 			imageUrl: '',
 			success: function(res) {
@@ -74,9 +76,12 @@ export default {
 			articleList.forEach((item, index) => {
 				if (item != '' && item != undefined) {
 					//  常见的标签渲染
+					if((index+1)%2==0){
+						item =  item + '</video>';
+					}
 					needArticleList.push({
 						type: 'rich-text',
-						value: item + '</video>'
+						value:item
 					});
 				}
 				let articleListLength = articleList.length; // 插入到原有video 标签位置

+ 138 - 0
pages/public/artDetailTab.vue

@@ -0,0 +1,138 @@
+<template>
+	<view class="center">
+<!-- 		<view class="title clamp">{{ item.title }}</view>
+		<view class="time">{{ item.add_time }}</view> -->
+		<view class="main" v-for="(ls, index) in item.content" :key="index">
+			<view v-if="ls.type == 'rich-text'" v-html="ls.value" class="main"></view>
+			<video v-if="ls.type == 'video' && ls.value" :src="ls.value" style="width:100%;height: 300px" frameborder="0"></video>
+		</view>
+	</view>
+</template>
+
+<script>
+import { getArtDetail } from '@/api/index.js'
+export default {
+	data() {
+		return {
+			id: '',
+			item: {
+				content:[]
+			}
+		};
+	},
+	onLoad(option) {
+		this.id = option.id;
+		this.loadData();
+	},
+	onShareAppMessage(options) {
+		// 设置菜单中的转发按钮触发转发事件时的转发内容
+		let pages = getCurrentPages(); //获取加载的页面
+		let currentPage = pages[pages.length - 1]; //获取当前页面的对象
+		let url = currentPage.route; //当前页面url
+		let item = currentPage.options; //如果要获取url中所带的参数可以查看options
+		let shareObj = {
+			title: '母婴界数字名片', // 默认是小程序的名称(可以写slogan等)
+			path: url + '?id=' + item.id, // 默认是当前页面,必须是以‘/’开头的完整路径
+			imageUrl: '',
+			success: function(res) {
+				// 转发成功之后的回调
+				if (res.errMsg == 'shareAppMessage:ok') {}
+			},
+			fail: function() {
+				// 转发失败之后的回调
+				if (res.errMsg == 'shareAppMessage:fail cancel') {
+					// 用户取消转发
+				} else if (res.errMsg == 'shareAppMessage:fail') {
+					// 转发失败,其中 detail message 为详细失败信息
+				}
+			}
+		};
+		return shareObj;
+	},
+	methods: {
+		loadData() {
+			getArtDetail({id:this.id}).then(({ data }) => {
+				let content = data.list[0]
+				content.content = content.content.replace(/<img/g, '<img class="rich-img"').replace(/<p>\s*<img/g, '<p class="pHeight"><img').replace(/<div/g, '<div style="max-width: 50% !important;"');
+				content.content = this.getVideo(content.content);
+				this.item = content;
+				uni.setNavigationBarTitle({
+					title: this.item.title
+				})
+			});
+		},
+		// 富文本视频解析
+		getVideo(data) {
+			let videoList = [];
+			let videoReg = /<video.*?(?:>|\/>)/gi; //匹配到字符串中的 video 标签
+			let srcReg = /src=[\'\"]?([^\'\"]*)[\'\"]?/i; //匹配到字符串中的 video 标签 的路径
+			let arr = data.match(videoReg) || []; // arr 为包含所有video标签的数组
+			let articleList = data.split('</video>'); // 把字符串  从视频标签分成数组
+			arr.forEach((item, index) => {
+				var src = item.match(srcReg);
+				videoList.push(src[1]); //所要显示的字符串中 所有的video 标签 的路径
+			});
+			let needArticleList = [];
+			articleList.forEach((item, index) => {
+				if (item != '' && item != undefined) {
+					//  常见的标签渲染
+					if((index+1)%2==0){
+						item =  item + '</video>';
+					}
+					needArticleList.push({
+						type: 'rich-text',
+						value:item
+					});
+				}
+				let articleListLength = articleList.length; // 插入到原有video 标签位置
+				if (index < articleListLength && videoList[index] != undefined) {
+					needArticleList.push({
+						type: 'video',
+						value: videoList[index]
+					});
+				}
+			});
+			return needArticleList;
+		}
+	}
+};
+</script>
+
+<style lang="scss">
+	page {
+		background-color: #fff;
+		min-height: 100%;
+		height: auto;
+	}
+.center {
+	min-height: 100%;
+	height: auto;
+	background: #ffffff;
+	padding: 30rpx 24rpx 0;
+}
+.title {
+	font-size: 32rpx;
+	font-family: PingFang SC;
+	font-weight: bold;
+	color: #333333;
+}
+.time {
+	font-size: 24rpx;
+	font-family: PingFangSC;
+	font-weight: 500;
+	color: #999999;
+	margin-top: 40rpx;
+}
+.main {
+	margin-top: 60rpx;
+}
+/deep/ .main {
+	.rich-img {
+		width: 100% !important;
+		height: auto;
+	}
+	* {
+		max-width: 100% !important;
+	}
+}
+</style>

+ 0 - 1
pages/public/domApp.vue

@@ -63,7 +63,6 @@
 				getAppBBH().then((res)=>{
 					uni.hideLoading()
 					let r = res.data;
-					console.log(r);
 					// 打开下载文件
 					window.open(r.file_url.app_file)
 				}).catch(()=>{

+ 2 - 2
pages/public/login.vue

@@ -161,8 +161,8 @@
 				}
 				obj.logining = true;
 				login({
-						account: obj.username,
-						password: obj.passward
+						uid: obj.username,
+						passwprd: obj.passward
 					})
 					.then(function(e) {
 						uni.setStorageSync('token', e.data.token);

+ 0 - 6
pages/public/loginMethods.vue

@@ -64,7 +64,6 @@
 			let obj = this;
 			// #ifdef APP-PLUS
 			let system = uni.getStorageSync('platform');
-			console.log(system);
 			// 判断是否为ios
 			if (system == 'ios') {
 				obj.is_ios = true;
@@ -93,15 +92,12 @@
 				uni.login({
 					provider: type,
 					success(e) {
-						console.log('授权返回结果',e);
 						uni.getUserInfo({
 							provider: type,
 							success(es) {
-								console.log('用户信息',es);
 								if (type === 'weixin') {
 									loginWx(es.userInfo)
 										.then(e => {
-											console.log(e,'回调数据');
 											uni.setStorageSync('token', e.data.token);
 											getUserInfo({}).then(e => {
 												obj.login();
@@ -122,12 +118,10 @@
 										});
 								}
 								if (type === 'apple') {
-									console.log(es.userInfo);
 									applelogin({
 											account: es.userInfo.openId,
 										})
 										.then(function(e) {
-											console.log(e, 'token')
 											uni.setStorageSync('token', e.data.token);
 											getUserInfo({}).then(e => {
 												obj.login();

+ 29 - 0
pages/public/video.vue

@@ -0,0 +1,29 @@
+<template>
+	<video class="video" :src='baseURL+url' autoplay loop></video>
+</template>
+
+<script>
+	import {
+		mapState
+	} from 'vuex';
+	export default {
+		computed: {
+			...mapState(['baseURL', 'urlFile'])
+		},
+		data() {
+			return {
+				url:'/static/viedo/jiaocheng.mp4'
+			};
+		},
+		onLoad(option) {
+			this.url = option.url;
+		}
+	};
+</script>
+
+<style>
+	.video{
+		width:750rpx;
+		height: 100vh;
+	}
+</style>

+ 0 - 8
pages/public/wxLogin.vue

@@ -65,16 +65,12 @@
 			};
 		},
 		onLoad(option) {
-			console.log(option, '船只');
 			this.loadData();
 		},
 		methods: {
 			...mapMutations('user', ['login', 'setUserInfo', 'logout']),
 			getUserInfos(e) {
-				console.log(e,'到这里');
 				if (e && e.detail) {
-					console.log('获取用户信息成功');
-					console.log(e.detail.userInfo);
 					this.userInfo = e.detail.userInfo;
 				}
 			},
@@ -88,7 +84,6 @@
 				// #endif
 				// #ifdef MP-WEIXIN
 				loginWinxinMp().then((e) => {
-					console.log(e, 'loginWinxinMp');
 					obj.code = e.code;
 				});
 				// #endif
@@ -141,7 +136,6 @@
 				const that = this;
 				wx.login({
 					success(e) {
-						console.log(e, 'loginWinxinMp');
 						that.code = e.code;
 					},
 					fill: function(e) {
@@ -183,7 +177,6 @@
 					}) => {
 						obj.loding = false;
 						obj.wchatAuth(data);
-						console.log(data, '授权数据');
 					})
 					.catch(e => {
 						obj.loding = false;
@@ -197,7 +190,6 @@
 				// 保存token
 				uni.setStorageSync('token', data.token);
 				obj.GetUser().then((data) => {
-					console.log(data, '返回用户的数据');
 					try {
 						uni.hideLoading();
 						obj.login();

+ 0 - 1
pages/set/address.vue

@@ -149,7 +149,6 @@
 				let that = this;
 				wx.chooseAddress({
 					success: function(data) {
-						console.log('获取地址',data);
 						that.addAddressOn(data)
 					},fail(e){
 						console.log(e);

+ 0 - 2
pages/set/addressManage.vue

@@ -86,7 +86,6 @@
 			if (option.type === 'edit') {
 				title = '编辑收货地址';
 				let data = JSON.parse(option.data);
-				console.log(data);
 
 				this.addressData = {
 					name: data.real_name,
@@ -122,7 +121,6 @@
 			chooseLocation() {
 				uni.chooseLocation({
 					success: data => {
-						console.log(data);
 						this.addressData.addressName = data.name;
 						this.addressData.address = data.name;
 					}

+ 1 - 5
pages/set/set.vue

@@ -18,7 +18,7 @@
 						<image class="img" src="../../static/icon/next1.png" mode="widthFix"></image>
 					</view>
 				</view>
-				<view class="flex listItem" >
+				<view class="flex listItem" v-if="userInfo.mobile" >
 					<view class="flex titleBox">
 						<text class="title">手机号</text>
 					</view>
@@ -71,10 +71,6 @@
 </template>
 
 <script>
-	import {
-		logout,
-		uploads
-	} from '@/api/set.js';
 	import {
 		mapMutations,
 		mapState

+ 0 - 4
pages/set/userinfo.vue

@@ -56,18 +56,15 @@
 			}
 		},
 		onLoad() {
-			console.log(this.userInfo)
 		},
 		computed: {
 			...mapState('user', ['userInfo'])
 		},
 		methods: {
 			imgsub() {
-				console.log('上传头像')
 				upload({
 					filename: ''
 				}).then(data => {
-					console.log("data", data);
 					this.userInfo.avatar = data[0].img;
 				})
 			},
@@ -83,7 +80,6 @@
 								url: '/pages/userhome/user'
 							});
 						}, 1000);
-						console.log(e);
 					})
 					.catch(e => {
 						console.log(e);

+ 0 - 1
pages/user/award/award.vue

@@ -166,7 +166,6 @@
 					}) => {
 						if (data.length > 0) {
 							navItem.orderList = navItem.orderList.concat(data[0].list);
-							console.log(navItem.orderList);
 							navItem.page++;
 						}
 						//判断是否还有数据, 有改为more, 没有改为noMore

+ 0 - 1
pages/user/award/awardList.vue

@@ -101,7 +101,6 @@
 					}) => {
 						if (data.length > 0) {
 							navItem.orderList = navItem.orderList.concat(data);
-							console.log(navItem.orderList);
 							navItem.page++;
 						}
 						if (navItem.limit == data.length) {

+ 1 - 1
pages/user/award/withdrawal.vue

@@ -196,7 +196,7 @@
 						});
 					})
 					.catch(e => {
-						console.log();
+						console.log(e);
 					});
 			}
 		}

+ 61 - 29
pages/user/model/model.vue

@@ -6,21 +6,30 @@
 			<button class="share" type="default" open-type="share">
 				分享名片
 			</button>
-			<view class="nav-model" @click="navto('/pages/user/model/model?mtype=' + mtype+'&type=0')" v-if="mtype != 3">
+			<view class="nav-model pink" @click="payPhone"
+				v-if="mtype ==5">
+				拨打电话
+			</view>
+			<view class="nav-model" @click="navto('/pages/user/model/model?mtype=' + mtype+'&type=0')"
+				v-if="mtype != 3">
 				生成我的名片
 			</view>
-				<view class="nav-model" @click="navto('/pages/user/model/modelrz?modelid='+userInfo.show_template_id)" v-if="mtype == 3 && hasLogin && userInfo.info_audit_status==-2">
+			<template v-else-if="mtype == 3">
+				<view class="nav-model" @click="navto('/pages/user/model/modelrz?modelid='+userInfo.show_template_id)"
+					v-if=" hasLogin && userInfo.info_audit_status==-2">
 					立即认证
 				</view>
-				<view class="nav-model" @click="navto('/pages/user/model/mymodellist')" v-if="mtype == 3 && hasLogin && userInfo.info_audit_status==1">
+				<view class="nav-model" @click="navto('/pages/user/model/mymodellist')"
+					v-if=" hasLogin && userInfo.info_audit_status==1">
 					查看我的名片
 				</view>
-				<view class="nav-model"  v-if="mtype == 3 && hasLogin && userInfo.info_audit_status==0">
+				<view class="nav-model" v-if=" hasLogin && userInfo.info_audit_status==0">
 					资料审核中
 				</view>
-				<view class="nav-model"  v-if="mtype == 3 && !hasLogin" @click="toLogin">
+				<view class="nav-model" v-if=" !hasLogin" @click="toLogin">
 					生成我的名片
 				</view>
+			</template>
 		</view>
 		<view class="fxmp flex bottom" v-if="type==3">
 			<button class="share" type="default" open-type="share">
@@ -29,20 +38,27 @@
 			<view class="nav-model " @click="navto('/pages/user/model/modelrz?type=1&modelid=' + mtype)">
 				修改名片
 			</view>
+			<view class="nav-model pink"
+				@click="navto('/pages/user/model/modelQr?modelid='+mtype+'&avatar='+userTemplate.avatar)">
+				保存分享图
+			</view>
 		</view>
+
+		<view style="height: 100rpx;" v-if="type==3"></view>
+
 		<block v-if="type==0">
 			<view class="ljrz bottom" v-if="userInfo.work_type_id <=0&&userInfo.info_audit_status != 1"
 				@click="navto('/pages/user/model/modelrz?modelid=' + mtype + '&type=2')">
 				生成我的名片
 			</view>
 			<view v-else class="create-model flex bottom">
-				<view class="price-show">
+				<view  v-if="systeam!='ios'"  class="price-show">
 					模板费用:<text>{{modelInfo.price*1}}</text>
 				</view>
 				<view class="to-show" @click="preview">
 					模板预览
 				</view>
-				<view class="by-now" @click="gobuy">
+				<view v-if="systeam!='ios'" class="by-now" @click="gobuy">
 					立即使用
 				</view>
 			</view>
@@ -95,29 +111,39 @@
 			}
 		},
 		onLoad(opt) {
-
+			const that = this;
 			// #ifndef MP
 			if (opt.spread) {
 				// 存储其他邀请人
 				uni.setStorageSync('spread', opt.spread);
 			}
-
 			// #endif
 			// #ifdef MP
+			if (opt.spread) {
+				// 存储其他邀请人
+				uni.setStorageSync('spread_code', opt.spread);
+			}
+			uni.hideShareMenu();
 			if (opt.scene) {
+				let arr = opt.scene.split('_')
+				this.isLook = 2;
+				this.type = 2;
+				this.mtype = arr[1]
+				this.shareId = arr[0];
 				// 存储小程序邀请人
 				uni.setStorage({
 					key: 'spread_code',
-					data: opt.scene
+					data: arr[0]
 				});
+				this.getCommonUserCardInfo(arr[0]);
+				return
 			}
-			uni.hideShareMenu();
 			// #endif
-
 			// 获取模板id
 			this.mtype = +opt.mtype
 			// 获取查看类型
 			this.type = +opt.type
+
 			// 是否首页进入
 			if (this.type === 0) {
 				this.isLook = 1;
@@ -138,15 +164,13 @@
 			}
 			//分享预览
 			if (this.type === 2) {
-				console.log(opt.type, 'opt.type');
 				this.isLook = 2;
-				this.shareId = opt.uid
+				this.shareId = opt.uid;
 				this.getCommonUserCardInfo(opt.uid);
 				return
 			}
 			//我的模板页进入预览
 			if (this.type === 3) {
-				console.log(opt.type, 'opt.type');
 				this.isShare = true;
 				this.isLook = 2;
 				this.shareId = this.userInfo.uid;
@@ -175,7 +199,10 @@
 		},
 		computed: {
 			...mapState(['baseURL']),
-			...mapState('user', ['userInfo','hasLogin']),
+			...mapState('user', ['userInfo', 'hasLogin']),
+			// #ifdef MP
+			...mapState(['systeam']),
+			// #endif
 		},
 		onShow() {
 
@@ -189,7 +216,6 @@
 			let url = currentPage.route; //当前页面url
 			let item = currentPage.options; //如果要获取url中所带的参数可以查看options
 			let shareObj = {}
-			console.log(url, 'url');
 			shareObj = {
 				title: this.userTemplate.name + '母婴界数字名片', // 默认是小程序的名称(可以写slogan等)
 				path: url + '?uid=' + this.shareId + '&mtype=' + this.mtype + '&type=2', // 默认是当前页面,必须是以‘/’开头的完整路径
@@ -207,14 +233,16 @@
 					}
 				}
 			};
-			console.log(shareObj)
+			// 判断是否可以邀请
+			if (this.userInfo.uid) {
+				shareObj.path += '&spread=' + this.userInfo.uid;
+			}
 			return shareObj;
 		},
 		// #endif
 		onUnload() {
 			let pages = getCurrentPages(); //获取加载的页面
 			let currentPage = pages[pages.length - 2]; //获取当前页面的对象
-			// console.log(currentPage.route)
 			if (currentPage.route == 'pages/public/wxLogin') {
 				uni.switchTab({
 					url: '/pages/index/index'
@@ -223,9 +251,14 @@
 		},
 		methods: {
 			...mapMutations('user', ['setUserInfo']),
+			payPhone(){
+				uni.makePhoneCall({
+					phoneNumber:this.userTemplate.mobile
+				})
+			},
 			toLogin() {
 				saveUrl();
-				interceptor(); 
+				interceptor();
 			},
 			// 模板预览
 			preview() {
@@ -271,10 +304,6 @@
 					return
 				}
 			},
-			// 监听web视图反馈
-			changeDate(base) {
-				console.log(base, 'mss');
-			},
 			navto(url) {
 				uni.navigateTo({
 					url
@@ -347,7 +376,6 @@
 									fail: () => {},
 									complete: () => {}
 								});
-								console.log('支付成功')
 							},
 							fail: (err) => {
 								console.log(err)
@@ -357,9 +385,7 @@
 								// });
 							}
 						};
-						console.log(data, 'timeStamp')
 						if (that.payType == 'wxpay') {
-							console.log('到这里')
 							wx.requestPayment(data)
 						}
 					}
@@ -390,10 +416,10 @@
 					let arr = []
 					let basearr = res.data.service_area_all
 					basearr.forEach(item => {
-						if(item.length == 3) {
+						if (item.length == 3) {
 							arr.push(item[0].name + item[1].name + item[2].name)
 						}
-						if(item.length == 2) {
+						if (item.length == 2) {
 							arr.push(item[0].name + item[1].name + '市辖区')
 						}
 					})
@@ -742,6 +768,11 @@
 			background-color: #FFF;
 			color: $base-color;
 			width: 50%;
+
+			&.pink {
+				color: #FFF;
+				background-color: #FEB8C6;
+			}
 		}
 	}
 
@@ -783,6 +814,7 @@
 
 		.to-show,
 		.by-now {
+			flex-grow: 1;
 			width: 223rpx;
 			background: #fa98b6;
 			flex-shrink: 0;

+ 423 - 0
pages/user/model/modelQr.vue

@@ -0,0 +1,423 @@
+<template>
+	<view class="container">
+		<view class="" style="height: 80rpx;">
+
+		</view>
+		<canvas :style="{ width:  canvasW + 'px', height: canvasH + 'px',}" canvas-id="myCanvas" id="myCanvas"
+			class="hb"></canvas>
+		<!-- #ifndef MP -->
+		<div class="preserve">
+			<div class="line"></div>
+			<div class="tip">长按保存图片</div>
+			<div class="line"></div>
+		</div>
+		<!-- #endif -->
+
+		<!-- #ifdef MP -->
+		<view class='keep' @click='saveShareQrcode' v-if="!loading">保存海报</view>
+		<!-- #endif -->
+
+	</view>
+</template>
+
+<script>
+	import {
+		getWxmpShowQrcode
+	} from '@/api/model.js';
+	import {
+		mapState
+	} from 'vuex';
+	export default {
+		// #ifdef MP
+		onShareAppMessage: function(res) {
+			// if (res.from === 'button') {
+
+			// 保存邀请人
+			let path = '/pages/index/index?' + 'spread=' + this.userInfo.uid;
+			let data = {
+				path: path,
+				imageUrl: this.poster,
+				title: this.userInfo.nickname + '邀请您进入母婴界严选'
+			};
+			return data;
+			// }
+		},
+		// #endif
+		data() {
+			return {
+				bl: 0.95, //画布比例
+				canvasW: '',
+				canvasH: '',
+				bgimg: '',
+				qrimg: '',
+				shareList: [],
+				swiperIndex: 0,
+				poster: '', // 当前海报
+				loading: true,
+				modelid: '',
+				avatar: '' //分享头像
+			}
+		},
+		onLoad(option) {
+			// 保存邀请图模版id
+			this.modelid = option.modelid;
+			this.avatar = option.avatar
+			this.loadData();
+		},
+		computed: {
+			...mapState('user', ['userInfo']),
+		},
+		methods: {
+			bindchange(e) {
+				let shareList = this.shareList;
+				this.swiperIndex = e.detail.current;
+				// #ifdef MP
+				this.poster = shareList[this.swiperIndex].poster;
+				// #endif 
+				// // #ifndef MP
+				// this.poster = shareList[this.swiperIndex].wap_poster;
+				// // #endif 
+			},
+
+			// 保存海报
+			savePosterPath: function() {
+				let that = this;
+				if (that.poster == '') {
+					// that.poster = that.shareList[0].poster;
+					that.poster = this.bgimg
+				}
+				uni.downloadFile({
+					url: that.poster,
+					success(resFile) {
+						if (resFile.statusCode === 200) {
+							uni.getSetting({
+								success(res) {
+									if (!res.authSetting['scope.writePhotosAlbum']) {
+										uni.authorize({
+											scope: 'scope.writePhotosAlbum',
+											success() {
+												uni.saveImageToPhotosAlbum({
+													filePath: resFile.tempFilePath,
+													success: function(res) {
+														return that.$api.msg(
+															'保存成功');
+													},
+													fail: function(res) {
+														return that.$api.msg(res
+															.errMsg);
+													},
+													complete: function(res) {},
+												})
+											},
+											fail() {
+												uni.showModal({
+													title: '您已拒绝获取相册权限',
+													content: '是否进入权限管理,调整授权?',
+													success(res) {
+														if (res.confirm) {
+															uni.openSetting({
+																success: function(
+																	res) {
+																	console
+																		.log(
+																			res
+																			.authSetting
+																		)
+																}
+															});
+														} else if (res.cancel) {
+															return that.$api.msg(
+																'已取消!');
+														}
+													}
+												})
+											}
+										})
+									} else {
+										uni.saveImageToPhotosAlbum({
+											filePath: resFile.tempFilePath,
+											success: function(res) {
+												return that.$api.msg('保存成功');
+											},
+											fail: function(res) {
+												return that.$api.msg(res.errMsg);
+											},
+											complete: function(res) {},
+										})
+									}
+								},
+								fail(res) {
+
+								}
+							})
+						} else {
+							return that.$api.msg(resFile.errMsg);
+						}
+					},
+					fail(res) {
+						return that.$api.msg(res.errMsg);
+					}
+				})
+			},
+
+			// #ifdef MP-WEIXIN
+			// 保存画图图片到本地
+			seav(url) {
+				uni.showLoading({
+					title: '生成中...',
+					mask: true
+				});
+				uni.saveImageToPhotosAlbum({
+					filePath: this.poster,
+					complete(result) {
+						uni.hideLoading();
+						uni.showToast({
+							title: '保存图片成功!',
+							duration: 2000,
+							icon: 'none'
+						});
+					}
+				});
+			},
+			// #endif
+
+			// 获取海报
+			loadData() {
+				let obj = this;
+				uni.showLoading({
+					title: '获取中',
+					mask: true,
+				});
+				getWxmpShowQrcode({
+					id: obj.modelid
+				}).then(res => {
+					obj.bgimg = "/static/image/modelQshare.png"
+					obj.qrcode = res.data.qrcode
+					uni.hideLoading();
+					obj.createPoster()
+
+				})
+			},
+			async createPoster() {
+				let that = this
+				// 获取设备信息,主要获取宽度,赋值给canvasW 也就是宽度:100%
+				this.SystemInfo = await this.getSystemInfo();
+				// 获取商品主图,二维码信息,APP端会返回图片的本地路径(H5端只能返回原路径)
+				this.goodsImg = await this.getImageInfo(that.bgimg);
+				this.ewmImg = await this.getImageInfo(that.qrcode);
+				this.avatarImg = await this.getImageInfo(that.avatar);
+				this.canvasW = this.SystemInfo.windowWidth * that.bl; // 画布宽度
+				this.ratio = this.SystemInfo.windowWidth / 750;
+				let x = 750 * this.goodsImg.height / this.goodsImg.width
+				// this.canvasW =750 * this.ratio;
+				this.canvasH = x * this.ratio * that.bl;
+				// 二维码宽度
+				let ewmW = 220 * this.ratio;
+				// 头像宽度
+				let avatarW = 320 * this.ratio;
+				// this.canvasH = this.goodsImg.height + this.ewmW + 200;  // 画布高度 = 主图高度+二维码高度 + 文字图片的间距(大概50)
+				// 如果主图,二维码图片,设备信息都获取成功,开始绘制海报,这里需要用setTimeout延时绘制,否则可能会出现图片不显示。
+				if (this.avatarImg.errMsg == 'getImageInfo:ok' && this.goodsImg.errMsg == 'getImageInfo:ok' && this
+					.ewmImg.errMsg == 'getImageInfo:ok' && this
+					.SystemInfo.errMsg == 'getSystemInfo:ok') {
+					uni.showToast({
+						icon: 'loading',
+						mask: true,
+						duration: 10000,
+						title: '海报绘制中',
+					});
+					setTimeout(() => {
+						var ctx = uni.createCanvasContext('myCanvas', this);
+						// 填充背景色,白色
+						ctx.setFillStyle('#FFF'); // 默认白色
+
+						ctx.fillRect(0, 0, this.canvasW, this.canvasH) // fillRect(x,y,宽度,高度)
+						// 绘制头像
+						ctx.drawImage(this.avatarImg.path, 195 * this.ratio, 165 * this.ratio, avatarW,
+							avatarW)
+						// 绘制商品主图
+						ctx.drawImage('/' + this.goodsImg.path, 0, 0, this.canvasW, this.canvasH)
+						// drawImage(图片路径,x,y,绘制图像的宽度,绘制图像的高度,二维码的宽,高)
+						// 二维码
+						ctx.drawImage(this.ewmImg.path, 40 * this.ratio, this.canvasH - 50 * this.ratio - ewmW,
+							ewmW, ewmW)
+						// 3、绘制商品标题,多余文字自动换行
+						ctx.setFontSize(14); // setFontSize() 设置字体字号
+						ctx.setFillStyle('#555'); // setFillStyle() 设置字体颜色
+						let name = this.userInfo.nickname
+						let len = 9;
+						if (name.length > len) {
+							name = name.substr(0, len) + '...'
+						}
+						ctx.fillText(name, 50 * this.ratio + ewmW, this.canvasH - ewmW / 2 - 80 * this.ratio)
+						ctx.fillText('邀请您加入母婴数字人才库', 50 * this.ratio + ewmW, this.canvasH - ewmW / 2 - 16 * this
+							.ratio)
+						ctx.draw(false, (ret) => { // draw方法 把以上内容画到 canvas 中。
+							uni.showToast({
+								icon: 'none',
+								title: '生成成功!',
+							});
+							that.loading = false
+							that.fina = true
+							uni.canvasToTempFilePath({ // 保存canvas为图片
+								canvasId: 'myCanvas',
+								quality: 1,
+								fileType: 'jpg',
+								complete: function(res) {
+									// 在H5平台下,tempFilePath 为 base64, // 图片提示跨域 H5保存base64失败,APP端正常输出临时路径
+									that.canvasShow = false
+									that.shareQrcodeUrl = res.tempFilePath
+									that.$forceUpdate()
+								},
+							})
+						});
+					}, 1500)
+				} else {
+					console.log('err')
+				}
+			},
+			// 获取设备信息
+			getSystemInfo() {
+				return new Promise((req, rej) => {
+					uni.getSystemInfo({
+						success: function(res) {
+							req(res)
+						}
+					});
+				})
+			},
+			// 获取图片信息
+			getImageInfo(image) {
+				return new Promise((req, rej) => {
+					uni.getImageInfo({
+						src: image,
+						success: function(res) {
+							req(res)
+						},
+						fail(ee) {
+							console.log(ee, 'ee')
+						}
+					});
+				})
+			},
+			//保存图片
+			saveShareQrcode() {
+				uni.saveImageToPhotosAlbum({
+					filePath: this.shareQrcodeUrl,
+					success: (res) => {
+						uni.showToast({
+							icon: 'none',
+							position: 'bottom',
+							title: "成功保存到相册",
+						});
+					},
+					fail: (err) => {
+						//重新提示用户打开保存图片的授权
+						if (err.errMsg === "saveImageToPhotosAlbum:fail auth deny") {
+							uni.showModal({
+								title: '提示',
+								content: '需要您授权保存相册',
+								showCancel: false,
+								success(res) {
+									if (res.confirm) {
+										uni.openSetting({
+											success(settingdata) {
+												if (settingdata.authSetting[
+														'scope.writePhotosAlbum']) {
+													uni.showModal({
+														title: '提示',
+														content: '获取权限成功,再次保存图片即可成功',
+														showCancel: false,
+													})
+												} else {
+													uni.showModal({
+														title: '提示',
+														content: '获取权限失败,无法保存到相册',
+														showCancel: false
+													})
+												}
+											}
+										})
+									}
+								}
+							})
+						}
+					},
+				})
+			}
+		}
+	}
+</script>
+
+<style lang="scss">
+	page {
+		background: #a3a3a3;
+		height: 100%;
+	}
+
+	.container {
+		width: 100%;
+		padding-bottom: 100rpx;
+
+		.posters-box {
+			width: 100%;
+			height: 1000rpx;
+			margin-top: 40rpx;
+
+			.slide-image {
+				width: 100%;
+				height: 100%;
+				border-radius: 15rpx;
+			}
+		}
+
+		.posters-box .slide-image.active {
+			transform: none;
+			transition: all 0.2s ease-in 0s;
+		}
+
+		.posters-box .slide-image.quiet {
+			transform: scale(0.8333333);
+			transition: all 0.2s ease-in 0s;
+		}
+
+		.keep {
+			font-size: 30rpx;
+			background: $base-color;
+			color: #fff;
+			width: 750rpx;
+			position: fixed;
+			height: 100rpx;
+			text-align: center;
+			line-height: 100rpx;
+			bottom: 0;
+			left: 0;
+		}
+	}
+
+	.preserve {
+		color: #fff;
+		text-align: center;
+		margin-top: 38rpx;
+		display: flex;
+		align-items: center;
+		justify-content: center;
+
+		.line {
+			width: 100rpx;
+			height: 1px;
+			background-color: #fff;
+		}
+
+		.tip {
+			margin: 0 20rpx;
+			font-size: 28rpx;
+		}
+	}
+
+	.hb {
+		margin: auto;
+		border-radius: 20rpx;
+		overflow: hidden;
+	}
+</style>

+ 224 - 136
pages/user/model/modelrz.vue

@@ -1,6 +1,8 @@
 <template>
 	<view class="content ">
-
+		<view class="errorIf" v-if="dataInitError">
+			初始化数据失败请重新填写数据
+		</view>
 		<view class="item-name">
 			上传头像
 		</view>
@@ -93,6 +95,26 @@
 							placeholder-class="placeholder" />
 					</view>
 				</view>
+				<view class="flex listItem">
+					<view class="flex titleBox">
+						<text class="title">身高</text>
+					</view>
+					<view class="right flex">
+						<input class="input" v-model="updata.height" type="number" placeholder="请填写身高"
+							placeholder-class="placeholder" />
+						<text class="margin-l-10 flex-shrink-false">厘米</text>
+					</view>
+				</view>
+				<view class="flex listItem">
+					<view class="flex titleBox">
+						<text class="title">体重</text>
+					</view>
+					<view class="right flex">
+						<input class="input" v-model="updata.weight" type="number" placeholder="请填写体重"
+							placeholder-class="placeholder" />
+						<text class="margin-l-10">kg</text>
+					</view>
+				</view>
 				<!-- <view class="flex listItem">
 					<view class="flex titleBox">
 						<text class="title">出生日期</text>
@@ -160,17 +182,18 @@
 				</view>
 				<view class="flex listItem">
 					<view class="flex titleBox">
-						<text class="font-color-red font-size-sm">✲</text><text class="title">服务区域是否海外</text>
+						<text class="title">服务区域</text>
 					</view>
 					<view class="right flex">
-						<picker class="input" :range='areaList' mode="selector" @change="changeAreaList">
+						<picker class="input" range-key='title' :range='areaType' mode="selector"
+							@change="changeAreaType">
 							<view>
-								{{updata.is_wm||'请选择是否海外'}}
+								{{areaType[actionAreaType].title}}
 							</view>
 						</picker>
 					</view>
 				</view>
-				<view class="flex listItem" v-if="updata.is_wm == '否'">
+				<view class="flex listItem" v-if="actionAreaType==1">
 					<view class="flex titleBox">
 						<text class="font-color-red font-size-sm">✲</text><text class="title">服务区域</text>
 					</view>
@@ -216,9 +239,9 @@
 		<view class="listBox">
 			<view class="list">
 				<view class="listItem">
-					<editor id='editor' class="textarea" auto-height :maxlength='-1' @blur='changeMyask' type="text"
-						placeholder="自我评价\n\n本人从业***年,已经服务***名客户\n成长经历:\n从事母婴工作之前是做***行业的,于***年经过专业培训后进入母婴行业;先后学习了***\n性格特征:\n本人性格直爽,具有很强的服务意识,做事认真负责,擅长……类工作\n服务格言:\n全心全意服务好每一位客户" >
-						</editor>
+					<editor id='editor' class="textarea" auto-height :maxlength='-1' @input='changeMyask' type="text"
+						placeholder="自我评价\n\n本人从业***年,已经服务***名客户\n成长经历:\n从事母婴工作之前是做***行业的,于***年经过专业培训后进入母婴行业;先后学习了***\n性格特征:\n本人性格直爽,具有很强的服务意识,做事认真负责,擅长……类工作\n服务格言:\n全心全意服务好每一位客户">
+					</editor>
 				</view>
 			</view>
 			<view class="con_box">
@@ -304,9 +327,12 @@
 		},
 		data() {
 			return {
+				// 初始化数据失败
+				dataInitError: false,
 				jgList: AllAddress,
 				// 上传数据
 				updata: {
+					is_global: 0, //是否全国0是否1是是
 					is_wm: '', //是否海外
 					avatar: '', //用户头像
 					name: '', //用户名称
@@ -314,6 +340,8 @@
 					cardId: '', //身份证号
 					minMoney: '', //最低价
 					maxMoney: '', //最高价
+					height: '', //身高
+					weight: '', //体重
 					checkedType: [], //选中的服务类型
 					time: '', //出生日期
 					timetype: {
@@ -344,25 +372,43 @@
 				userModelData: {}, //保存获取的用户模板
 				modelid: '', //保存要预览的模板id
 				educationList: ['小学', '初中', '高中', '大专', '本科', '研究生', '博士'], //学历列表
-				areaList: ['是', '否'],
-				editorCtx:''
+				areaList: ['是', '否'], //保存是否国内国外
+				areaType: [{
+						title: '国外',
+						type: 2
+					},
+					{
+						title: '国内',
+						type: 1
+					},
+					{
+						title: '全国',
+						type: 3
+					}
+				], //学历列表
+				editorCtx: '',
+				actionAreaType: 1
 			};
 		},
 		async onLoad(options) {
 			this.modelid = options.modelid
-			this.$nextTick(async ()=>{
-				if (options.type == 1) {
-					this.type = 1;
-					await this.getUserCardInfo()
-				} else if (options.type == 2) {
-					this.type = 0
-				}
-				this.init()
-			})
+			if (options.type == 1) {
+				this.type = 1;
+			} else if (options.type == 2) {
+				this.type = 0
+			}
 		},
 		onReady() {
+			const that = this;
 			// 保存对象
-			uni.createSelectorQuery().select('#editor').context((res) => {this.editorCtx = res.context}).exec()
+			uni.createSelectorQuery().select('#editor').context(async (res) => {
+				that.editorCtx = res.context
+				// console.log(that.editorCtx,'that.editorCtx');
+				if (that.type == 1) {
+					await that.getUserCardInfo()
+				}
+				that.init()
+			}).exec();
 		},
 		computed: {
 			// #ifdef H5
@@ -381,9 +427,16 @@
 				this.updata.education = this.educationList[res.detail.value];
 				// console.log(res);
 			},
-			changeAreaList(res) {
-				this.updata.is_wm = this.areaList[res.detail.value];
-				// console.log(res);
+			//修改地区类型
+			changeAreaType(re) {
+				this.actionAreaType = re.detail.value * 1;
+				if (re.detail.value == '1') {
+					this.updata.is_wm = this.areaList[1];
+					return
+				} else {
+					this.updata.is_wm = this.areaList[0];
+				}
+
 			},
 			// 初始化
 			init() {
@@ -415,16 +468,22 @@
 					(res) => {
 						that.typeList = res.data.list
 						if (that.type == 1) {
-							for (let i = 0; i < that.userModelData.service_project_ar.length; i++) {
-								for (let a = 0; a < that.typeList.length; a++) {
-									if (+that.typeList[a].id == +that.userModelData.service_project_ar[i].id) {
-										that.typeList[a].checked = true;
-										that.updata.checkedType.push('' + that.typeList[a].id)
+							try {
+								if (that.userModelData.service_project_ar) {
+									for (let i = 0; i < that.userModelData.service_project_ar.length; i++) {
+										for (let a = 0; a < that.typeList.length; a++) {
+											if (+that.typeList[a].id == +that.userModelData.service_project_ar[i].id) {
+												that.typeList[a].checked = true;
+												that.updata.checkedType.push('' + that.typeList[a].id)
+											}
+										}
 									}
 								}
+							} catch (e) {
+								//TODO handle the exception
 							}
+
 						}
-						// console.log(res, '服务');
 					}
 				).catch(
 					(res) => {
@@ -433,17 +492,23 @@
 				)
 				getUserWorkTypeList().then(
 					(res) => {
-						// console.log(res);
 						that.workTypeList = res.data.list
 						if (that.type == 0) {
 							that.updata.word = that.workTypeList[0];
 						} else if (that.type == 1) {
-							for (let i = 0; i < that.workTypeList.length; i++) {
-								console.log(that.userModelData.user_work_type_id, 'word', that.workTypeList[i].id);
-								if (that.workTypeList[i].id == that.userModelData.user_work_type_id) {
-									that.updata.word = that.workTypeList[i];
-									break
+							try {
+								if (that.userModelData.user_work_type_id) {
+									for (let i = 0; i < that.workTypeList.length; i++) {
+										if (that.workTypeList[i].id == that.userModelData.user_work_type_id) {
+											that.updata.word = that.workTypeList[i];
+											break
+										}
+									}
+								} else {
+									that.updata.word = that.workTypeList[0];
 								}
+							} catch (e) {
+								that.updata.word = that.workTypeList[0];
 							}
 						}
 					}
@@ -459,59 +524,66 @@
 				if (!that.rendl()) {
 					return
 				}
-				// 获取生日
-				const birthday = IdCard('' + that.updata.cardId, 1);
-				// 复制选中的服务数组
-				let arr = [...that.updata.checkedType]
-				let pushar = [];
-				that.typeList.forEach(
-					(re) => {
-						for (let i = 0; i < arr.length; i++) {
-							console.log(arr[i], '循环');
-							if (+arr[i] == +re.id) {
-								// 删除已选中的对象
-								arr.splice(i, 1)
-								pushar.push(re)
-								break
+				uni.showLoading({
+					title: "生成预览中。。。",
+					mask: true
+				})
+				setTimeout(function() {
+					uni.hideLoading()
+					// 获取生日
+					const birthday = IdCard('' + that.updata.cardId, 1);
+					// 复制选中的服务数组
+					let arr = [...that.updata.checkedType]
+					let pushar = [];
+					that.typeList.forEach(
+						(re) => {
+							for (let i = 0; i < arr.length; i++) {
+								if (+arr[i] == +re.id) {
+									// 删除已选中的对象
+									arr.splice(i, 1)
+									pushar.push(re)
+									break
+								}
 							}
 						}
+					)
+					let data = {
+						is_china: that.actionAreaType,
+						name: that.updata.name,
+						avatar: that.updata.avatar,
+						age: IdCard(that.updata.cardId, 3),
+						twelve: getShengXiao(birthday),
+						work_year: that.updata.work_year,
+						constellation: getAstro(...(birthday.split('-'))),
+						ancestral_place: that.updata.ancestral_place,
+						minority: that.updata.minority,
+						education: that.updata.education,
+						service_area_all: that.actionAreaType == 0 ? that.updata.onCity.map(
+							(item) => {
+								return item.province + item.city + item.district
+							}
+						) : (that.actionAreaType == 1 ? ['海外,海外,海外'] : ['全国,全国,全国']),
+						service_min_price: that.updata.minMoney,
+						service_max_price: that.updata.maxMoney,
+						service_time_type_title: that.updata.timetype.title,
+						service_intro_content: that.updata.mymask,
+						service_intro_imgs: that.updata.imageList,
+						service_audit_imgs: that.updata.service_audit_imgs,
+						service_project_ar: pushar,
+						service_imgs: that.updata.service_imgs,
+						no: that.updata.no,
+						user_work_type_title: that.updata.word.title,
+						service_count: that.updata.service_count,
+						weight: that.updata.weight,
+						height: that.updata.height
 					}
-				)
-				// console.log(that.updata);
-				let data = {
-					is_china: that.updata.is_wm == '是' ? 0 : 1,
-					name: that.updata.name,
-					avatar: that.updata.avatar,
-					age: IdCard(that.updata.cardId, 3),
-					twelve: getShengXiao(birthday),
-					work_year: that.updata.work_year,
-					constellation: getAstro(...(birthday.split('-'))),
-					ancestral_place: that.updata.ancestral_place,
-					minority: that.updata.minority,
-					education: that.updata.education,
-					service_area_all: that.updata.is_wm == '否' ? that.updata.onCity.map(
-						(item) => {
-							return item.province + item.city + item.district
-						}
-					) : ['海外,海外,海外'],
-					service_min_price: that.updata.minMoney,
-					service_max_price: that.updata.maxMoney,
-					service_time_type_title: that.updata.timetype.title,
-					service_intro_content: that.updata.mymask,
-					service_intro_imgs: that.updata.imageList,
-					service_audit_imgs: that.updata.service_audit_imgs,
-					service_project_ar: pushar,
-					service_imgs: that.updata.service_imgs,
-					no: that.updata.no,
-					user_work_type_title: that.updata.word.title,
-					service_count: that.updata.service_count
-				}
-				
-				// console.log('baocun',data);
-				uni.setStorageSync('modeldata', data)
-				uni.navigateTo({
-					url: '/pages/user/model/model?mtype=' + that.modelid + '&type=1'
-				})
+
+					uni.setStorageSync('modeldata', data)
+					uni.navigateTo({
+						url: '/pages/user/model/model?mtype=' + that.modelid + '&type=1'
+					})
+
+				}, 1000);
 			},
 			// 获取用户提交数据
 			getUserCardInfo() {
@@ -519,46 +591,60 @@
 				return new Promise((resolve, reject) => {
 					getUserCardInfo().then(
 						(data) => {
-							const res = data.data;
-							// console.log(res, '返回');
-							// 存储返回用户数据
-							that.userModelData = res;
-							that.updata = Object.assign(that.updata, {
-								is_wm: res.is_china == 1 ? '否' : '是',
-								avatar: res.avatar, //用户头像
-								name: res.name, //用户名称
-								phone: res.mobile, //手机号
-								cardId: res.idcard, //身份证号
-								minMoney: res.service_min_price, //最低价
-								maxMoney: res.service_max_price, //最高价
-								time: res.birthday, //出生日期
-								onCity: res.is_china == 1 ? res.service_area_all.map((arr) => {
-									return {
-										province: arr[0].name,
-										city: arr[1].name,
-										district: arr[2] ? arr[2].name : '市辖区'
+							try {
+								const res = data.data;
+								// 存储返回用户数据
+								that.userModelData = res;
+								that.actionAreaType =res.is_china;
+								let onCity = [];
+								if (res.is_china == 1) {
+									for (let i = 0; i < res.service_area_all.length; i++) {
+										let arr = res.service_area_all[i];
+										if (arr.length > 0) {
+											onCity.push({
+												province: arr[0].name,
+												city: arr[1].name,
+												district: arr[2] ? arr[2].name : '市辖区'
+											})
+										}
 									}
-								}) : [], //选中的城市
-								mymask: res.service_intro_content, //自评
-								imageList: res.service_intro_imgs, //自评上传图片列表
-								ancestral_place: res.ancestral_place, //籍贯
-								education: res.education, //学历
-								minority: res.minority, //民族
-
-								work_year: res.work_year, //从业时长
-								service_audit_imgs: res.service_audit_imgs, //我的证书
-								service_imgs: res.service_imgs, //服务展示
-								no: res.no,
-								service_count: res.service_count
-							})
-							this.editorCtx.setContents({
-								html:res.service_intro_content
-							})
-							// console.log(that.updata, 'that.updata');
-							resolve('初始化数据成功')
+								};
+								that.updata = Object.assign(that.updata, {
+									is_wm: res.is_china == 0 ? '是' : '否',
+									avatar: res.avatar, //用户头像
+									name: res.name, //用户名称
+									phone: res.mobile, //手机号
+									cardId: res.idcard, //身份证号
+									minMoney: res.service_min_price, //最低价
+									maxMoney: res.service_max_price, //最高价
+									time: res.birthday, //出生日期
+									onCity: onCity, //选中的城市
+									mymask: res.service_intro_content, //自评
+									imageList: res.service_intro_imgs, //自评上传图片列表
+									ancestral_place: res.ancestral_place, //籍贯
+									education: res.education, //学历
+									minority: res.minority, //民族
+									work_year: res.work_year, //从业时长
+									service_audit_imgs: res.service_audit_imgs, //我的证书
+									service_imgs: res.service_imgs, //服务展示
+									no: res.no,
+									service_count: res.service_count,
+									weight: res.weight * 1,
+									height: res.height
+								})
+								that.editorCtx.setContents({
+									html: res.service_intro_content
+								})
+								resolve('初始化数据成功')
+							} catch (e) {
+								console.log(e, 'eeee')
+								that.dataInitError = true;
+								//TODO handle the exception
+							}
 						}
 					).catch(
 						(res) => {
+							that.dataInitError = true;
 							reject(res)
 						}
 					)
@@ -568,12 +654,10 @@
 			// 选中的服务类型
 			checkTypeChange(type) {
 				this.updata.checkedType = type.detail.value;
-				// console.log(type)
 			},
 			// 选中的工作类型
 			changeWorkType(type) {
 				this.updata.word = this.workTypeList[type.detail.value];
-				// console.log(this.updata.word)
 			},
 			// 选择时间类型
 			changetimetype(res) {
@@ -582,7 +666,6 @@
 			// 时间选择
 			changetime(time) {
 				this.updata.time = time.detail.value;
-				// console.log(time);
 			},
 			// 选择籍贯
 			changeAncestralPlace(val) {
@@ -597,12 +680,8 @@
 				address.city = data[1];
 				address.district = data[2];
 				this.updata.onCity.push(address)
-				// console.log(this.onCity, 'cs');
 			},
 			upLoad(path) {
-				// #ifdef H5
-				console.log(path, 'h5');
-				// #endif
 				uni.showLoading({
 					title: '图片上传中',
 					mask: true
@@ -645,7 +724,6 @@
 						events: {
 							uploadSuccess(res) {
 								that.upLoad(res).then((urldata) => {
-									console.log(urldata);
 									if (type == 'one') {
 										that.updata.avatar = urldata.img
 									} else if (type == 'all') {
@@ -689,7 +767,6 @@
 							},
 							fail: function(res) {
 								erro(res)
-								console.log(res.errMsg);
 							}
 						});
 					}
@@ -717,12 +794,10 @@
 						sizeType: ['compressed'], //可以指定是原图还是压缩图,默认二者都有
 						sourceType: sourceType,
 						success(res) {
-							console.log(res);
 							// 缓存文件路径
 							ok(res.tempFiles[0])
 						},
 						fail(err) {
-							console.log(err, '’1111')
 							uni.showModal({
 								title: '文件打开错误',
 								content: '请设置授权文件存储权限',
@@ -761,7 +836,7 @@
 				}
 				that.loding = true;
 				subInfoAudit({
-						is_china: that.updata.is_wm == '是' ? 0 : 1,
+						is_china: that.actionAreaType,
 						avatar: that.updata.avatar,
 						name: that.updata.name,
 						mobile: that.updata.phone,
@@ -782,14 +857,21 @@
 						service_audit_imgs: that.updata.service_audit_imgs,
 						service_imgs: that.updata.service_imgs,
 						user_work_type_id: that.updata.word.id,
-						service_count: that.updata.service_count
+						service_count: that.updata.service_count,
+						weight: that.updata.weight,
+						height: that.updata.height
 					})
 					.then((e) => {
 						if (e.msg == '提交成功,数据已通过审核') {
 							this.$api.msg(e.msg);
 							setTimeout(
 								() => {
-									uni.navigateBack()
+									uni.switchTab({
+										url: "/pages/userhome/user",
+										fail(re) {
+											console.log(re)
+										}
+									})
 								}, 1000
 							)
 						} else {
@@ -877,7 +959,7 @@
 					});
 					return
 				}
-				if (that.updata.is_wm == '否' && that.updata.onCity.length == 0) {
+				if (that.actionAreaType == 1 && that.updata.onCity.length == 0) {
 					uni.showModal({
 						title: '错误',
 						content: '请选择服务区域',
@@ -1049,4 +1131,10 @@
 			color: $font-color-dark;
 		}
 	}
+
+	.errorIf {
+		font-size: $font-lg;
+		color: #F65486;
+		padding: 30rpx;
+	}
 </style>

+ 1 - 9
pages/user/model/phb.vue

@@ -81,8 +81,7 @@
 </template>
 
 <script>
-	import { getInviteCountRank } from '@/api/user.js'
-	import { getCardLookCountRank,getArtDetail } from '@/api/index.js'
+	import { getCardLookCountRank } from '@/api/index.js'
 	export default {
 		data() {
 			return {
@@ -110,14 +109,8 @@
 
 		},
 		onShow() {
-			console.log(this.$store.state.baseURL)
 			this.times = ((new Date().setHours(0, 0, 0) - (new Date().getDay() - 1) *24 * 60 * 60 *1000)/1000).toFixed(0)
 			this.getCardLookCountRank()
-			getArtDetail({
-				id: 4
-			}).then(res => {
-				console.log(res);
-			})
 		},
 		onReachBottom() {
 
@@ -152,7 +145,6 @@
 				})
 			},
 			navTo(url) {
-				console.log(url);
 				if (url) {
 					if (url.indexOf('http') > -1) {
 						// #ifdef H5

+ 0 - 3
pages/user/model/shoprz.vue

@@ -65,9 +65,6 @@
 				const that = this;
 			},
 			upLoad(path) {
-				// #ifdef H5
-				console.log(path, 'h5');
-				// #endif
 				uni.showLoading({
 					title: '图片上传中',
 					mask: true

+ 0 - 5
pages/user/money/recharge.vue

@@ -100,7 +100,6 @@
 		onLoad(options) {
 			this.rechargeIndex();
 			this.extractBank();
-			console.log("s");
 		},
 		computed:{
 			...mapState(['fx'])
@@ -129,7 +128,6 @@
 					});
 					// 设置默认金额值
 					this.money = this.moneyList[0].price
-					console.log(e);
 				})
 			},
 			// 跳转
@@ -202,7 +200,6 @@
 			alipay(pushData) {
 				const that = this;
 				aliPay(pushData).then((e) => {
-					console.log(e.data.data,'jie');
 					let orderInfo={};
 					that.payLoding = true;
 					uni.requestPayment({
@@ -225,7 +222,6 @@
 			wxpay(pushData) {
 				const that = this;
 				// #ifdef H5
-				console.log(pushData);
 				rechargeWechat(pushData)
 					.then(e => {
 						let da = e.data;
@@ -273,7 +269,6 @@
 				// #endif
 				// #ifdef APP
 				wxPay(pushData).then((res) => {
-					console.log(res.data,'充值');
 					that.payLoding = true;
 					uni.requestPayment({
 						provider: that.type,

+ 0 - 2
pages/user/money/wallet.vue

@@ -79,7 +79,6 @@
 		},
 		onLoad(options) {
 			this.loadData();
-			console.log('进入');
 		},
 		onShow() {
 			// 获取用户余额
@@ -128,7 +127,6 @@
 					}) => {
 						if (data.length > 0) {
 							navItem.orderList = navItem.orderList.concat(data[0].list);
-							console.log(navItem.orderList);
 							navItem.page++;
 						}
 						if (navItem.limit == data.length) {

+ 0 - 1
pages/user/money/walletList.vue

@@ -94,7 +94,6 @@
 					}) => {
 						if (data.length > 0) {
 							navItem.orderList = navItem.orderList.concat(data);
-							console.log(navItem.orderList);
 							navItem.page++;
 						}
 						if (navItem.limit == data.length) {

+ 0 - 1
pages/user/myteam.vue

@@ -62,7 +62,6 @@
 					query.select('.list-scroll-content').boundingClientRect();
 					query.exec(function(res) {
 						_this.maxheight = resu.windowHeight - res[0].top + 'px';
-						console.log('打印页面的剩余高度', _this.height);
 					});
 				},
 				fail: res => {}

+ 0 - 2
pages/user/realName/cropper.vue

@@ -32,14 +32,12 @@
 			that.eventChannel = that.getOpenerEventChannel();
 			// #endif
 			that.eventChannel.on('urlNext', function(data) {
-				console.log(data);
 				that.url = data.url.tempFilePath;
 			})
 		},
 		methods: {
 			oncancel(e) {
 				uni.navigateBack();
-				console.log(e, 'on');
 			},
 			// 3.定义自己的回调函数
 			uploadSuccess(tempFilePath) {

+ 0 - 4
pages/user/realName/realNameAuthentication.vue

@@ -118,9 +118,6 @@
 		},
 		methods: {
 			upLoad(path) {
-				// #ifdef H5
-				console.log(path,'h5');
-				// #endif
 				uni.showLoading({
 					title: '图片上传中',
 					mask: true
@@ -165,7 +162,6 @@
 								that.upLoad(res).then((urldata) => {
 									that[type] = urldata.url;
 								})
-								// console.log(e, '接受数据');
 							}
 						},
 						success: function(res) {

+ 0 - 41
pages/user/shareQrCode.vue

@@ -37,13 +37,11 @@
 
 			// 保存邀请人
 			let path = '/pages/index/index?' + 'spread=' + this.userInfo.uid;
-			console.log('path', path)
 			let data = {
 				path: path,
 				imageUrl: this.poster,
 				title: this.userInfo.nickname + '邀请您进入母婴界严选'
 			};
-			console.log('---data---', data)
 			return data;
 			// }
 		},
@@ -62,14 +60,6 @@
 			}
 		},
 		onLoad(option) {
-			// console.log('---option---',option)
-			// let path = '/pages/index/index?' + 'spread=' + this.userInfo.uid;
-			// console.log('path',path)
-			// if(option.scene){
-			// 	// 存储邀请人
-			// 	this.spread = opt.pid;
-			// 	uni.setStorageSync('spread', opt.pid);
-			// }
 			this.loadData();
 		},
 		computed: {
@@ -82,12 +72,6 @@
 				// #ifdef MP
 				this.poster = shareList[this.swiperIndex].poster;
 				// #endif 
-
-				// // #ifndef MP
-				// this.poster = shareList[this.swiperIndex].wap_poster;
-				// // #endif 
-
-				console.log(this.poster)
 			},
 
 			// 保存海报
@@ -182,7 +166,6 @@
 					filePath: this.poster,
 					complete(result) {
 						uni.hideLoading();
-						console.log(result);
 						uni.showToast({
 							title: '保存图片成功!',
 							duration: 2000,
@@ -200,22 +183,7 @@
 					title: '获取中',
 					mask: true,
 				});
-				// spreadBanner({
-				// 	// #ifdef H5
-				// 	type: 2,
-				// 	// #endif
-				// 	// #ifdef MP
-				// 	type: 1
-				// 	// #endif
-				// }).then(res =>{
-				// 	uni.hideLoading();
-				// 	obj.shareList = res.data;
-				// 	console.log('obj.shareList',obj.shareList);
-				// }).catch(err => {
-				// 	uni.hideLoading();
-				// });
 				getWxmpInviteQrcode().then(res => {
-					console.log(res)
 					obj.bgimg = res.data.bgimg
 					obj.qrcode = res.data.qrcode
 					uni.hideLoading();
@@ -239,13 +207,11 @@
 				this.ewmW = 220 * this.ratio;
 	
 				
-				console.log(this.canvasH, 'this.canvasH')
 				// this.canvasH = this.goodsImg.height + this.ewmW + 200;  // 画布高度 = 主图高度+二维码高度 + 文字图片的间距(大概50)
 			
 				// 如果主图,二维码图片,设备信息都获取成功,开始绘制海报,这里需要用setTimeout延时绘制,否则可能会出现图片不显示。
 				if (this.goodsImg.errMsg == 'getImageInfo:ok' && this.ewmImg.errMsg == 'getImageInfo:ok' && this
 					.SystemInfo.errMsg == 'getSystemInfo:ok') {
-					console.log('ok')
 					uni.showToast({
 						icon: 'loading',
 						mask: true,
@@ -274,7 +240,6 @@
 						ctx .fillText(name, 100*this.ratio + this.ewmW,this.canvasH- this.ewmW/2 - 80*this.ratio)
 						ctx .fillText('邀请您加入母婴严选', 100*this.ratio + this.ewmW,this.canvasH- this.ewmW/2  -16*this.ratio)
 						ctx.draw(false, (ret) => { // draw方法 把以上内容画到 canvas 中。
-							console.log(ret)
 							uni.showToast({
 								icon: 'none',
 								title: '生成成功!',
@@ -287,14 +252,9 @@
 								fileType: 'jpg',
 								complete: function(res) {
 									// 在H5平台下,tempFilePath 为 base64, // 图片提示跨域 H5保存base64失败,APP端正常输出临时路径
-									console.log(res)
 									that.canvasShow = false
 									that.shareQrcodeUrl = res.tempFilePath
 									that.$forceUpdate()
-									setTimeout(function() {
-										console.log(that.shareQrcodeUrl, that
-											.canvasShow)
-									}, 2000)
 								},
 							})
 						});
@@ -326,7 +286,6 @@
 			},
 			//保存图片
 			saveShareQrcode() {
-				console.log(this.shareQrcodeUrl)
 				uni.saveImageToPhotosAlbum({
 					filePath: this.shareQrcodeUrl,
 					success: (res) => {

+ 0 - 1
pages/user/teamph.vue

@@ -181,7 +181,6 @@
 					page: navitem.page,
 					pageSize: navitem.limit
 				}).then(res => {
-					console.log(res);
 					// let arr = res.data.list
 					let arr = res.data.list.sort(function(a, b) {
 						return b.count  -a.count

+ 78 - 40
pages/userhome/user.vue

@@ -52,7 +52,7 @@
 				</view>
 				<image class="next" src="../../static/icon/next2.png" mode="scaleToFill"></image>
 			</view>
-			<view class="nav-model-rz flex" v-if="user.work_type_id>0&&user.type_audit_status!=1"
+			<!-- <view class="nav-model-rz flex" v-if="user.work_type_id>0&&user.type_audit_status!=1"
 				@click="user.type_audit_status==0||navTo('/pages/user/model/shoprz')">
 				<view class="tiptext" v-if="user.type_audit_status==-2">
 					您未完成平台认证,请立即认证>>
@@ -72,7 +72,7 @@
 				<view class="rztext" v-else-if='user.type_audit_status==-3||user.type_audit_status==-1'>
 					重新生成
 				</view>
-			</view>
+			</view> -->
 			<view class="cover-container">
 				<view class="listBox">
 					<view class="list">
@@ -111,7 +111,7 @@
 						<view class="flex listItem" @click="navTo('/pages/user/model/mymodellist')">
 							<view class="flex titleBox">
 								<image class="listIconImg" src="../../static/icon/mymodel.png" mode="widthFix"></image>
-								<text class="title">已购模板</text>
+								<text class="title">我的模板</text>
 							</view>
 							<view class="right flex">
 								<text></text>
@@ -128,6 +128,16 @@
 								<image class="img" src="../../static/icon/next1.png" mode="widthFix"></image>
 							</view>
 						</view> -->
+						<view class="flex listItem" @click="openCode">
+							<view class="flex titleBox">
+								<image class="listIconImg" src="../../static/icon/myCode.png" mode="widthFix"></image>
+								<text class="title">激活模版</text>
+							</view>
+							<view class="right flex">
+								<text></text>
+								<image class="img" src="../../static/icon/next1.png" mode="widthFix"></image>
+							</view>
+						</view>
 						<!-- #ifdef MP -->
 						<button hover-class="none" class="flex listItem" open-type='contact'>
 							<view class="flex titleBox">
@@ -201,8 +211,13 @@
 		share
 	} from '@/api/wx';
 	import {
-		getUser
+		getUser,
+		useCode
 	} from '@/api/user.js';
+	// #ifdef MP
+	// 不要删,删除会导致修改资料页面报错无法引用到该对象
+	// import setAll from '@/api/set';
+	// #endif
 	import {
 		articleList,
 		notify
@@ -218,13 +233,16 @@
 					avatar: '', //头像
 					nickname: '', //昵称
 				},
-				shareData: {}
+				shareData: {},
 			};
 		},
 		computed: {
 			...mapState('user', ['userInfo', 'orderInfo', 'hasLogin']),
 			...mapState(['baseURL', 'urlFile']),
 			...mapState(['fx']),
+			// #ifdef MP
+			...mapState(['systeam']),
+			// #endif
 			// 总消息条数
 			notic() {
 				return this.user.question_sum + this.user.notice_sum;
@@ -232,39 +250,74 @@
 		},
 		// 创建时获取分享信息
 		onLoad() {
-			// share().then((res) => {
-			// 	this.shareData = res.data.data
-			// }).catch((res) => {
-			// 	console.log(res, '分享加载失败');
-			// })
 		},
 		onShow() {
 			this.getUser();
 		},
 		methods: {
 			...mapMutations('user', ['setUserInfo']),
+			// 激活验证码
+			openCode() {
+				uni.showModal({
+					title: '激活模版',
+					placeholderText: '请输入激活key',
+					editable: true,
+					confirmText: '激活',
+					success: res => {
+						if (res.confirm) {
+							useCode({
+								code: res.content
+							}).then((e) => {
+								uni.showToast({
+									title: '激活成功'
+								});
+							}).catch((e) => {
+								console.log(e)
+								uni.showToast({
+									title: e.msg,
+									icon:"error"
+								});
+							})
+						}
+					},
+					fail: () => {},
+					complete: () => {}
+				});
+			},
 			// 跳转卡片页面
 			navcard() {
-				// 判断是否已经认证
-				if (this.user.work_type_id <= 0) {
-					if (this.user.info_audit_status == 1) {
-						this.navTo('/pages/user/model/model?mtype=' + this.user.show_template_id + '&type=3')
+				if (this.hasLogin) {
+					// 判断是否已经认证
+					if (this.user.work_type_id <= 0) {
+						if (this.user.info_audit_status == 1) {
+							this.navTo('/pages/user/model/model?mtype=' + this.user.show_template_id + '&type=3')
+						} else {
+							this.navTo('/pages/user/model/modelrz?modelid=' + this.user.show_template_id)
+						}
 					} else {
-						this.navTo('/pages/user/model/modelrz?modelid=' + this.user.show_template_id)
+						if (this.user.show_template_id) {
+							this.navTo('/pages/user/model/model?mtype=' + this.user.show_template_id + '&type=3')
+						} else {
+							if (this.systeam == 'ios') {
+								uni.showModal({
+									title: '错误',
+									content: 'IOS暂不支持',
+									showCancel: false,
+								});
+							} else {
+								uni.showModal({
+									title: '错误',
+									content: '您未购买模板请先购买',
+									showCancel: false,
+								});
+							}
+						}
 					}
 				} else {
-					if (this.user.show_template_id) {
-						this.navTo('/pages/user/model/model?mtype=' + this.user.show_template_id + '&type=3')
-					} else {
-						uni.showModal({
-							title: '错误',
-							content: '您未购买模板请先购买',
-							showCancel: false,
-						});
-					}
+					saveUrl()
+					interceptor()
 				}
 			},
-
 			//#ifdef APP
 			shareDomApp() {
 				uni.share({
@@ -279,7 +332,6 @@
 			//#endif
 			// 获取用户数据
 			getUser() {
-				console.log('data')
 				const that = this;
 				getUser({}).then((e) => {
 					this.user = e.data;
@@ -288,25 +340,11 @@
 				}).catch((e) => {
 					console.log(e, 'sj');
 				})
-				// 系统消息
-				// articleList({}, 1).then((e) => {
-				// 	that.user.question_sum = e.data.count
-				// 	console.log(that, 1);
-				// }).catch((e) => {
-				// 	console.log(e);
-				// })
-				// 报警消息
-				// notify().then((e) => {
-				// 	that.user.notice_sum = e.data.count
-				// }).catch((e) => {
-				// 	console.log(e);
-				// })
 			},
 			changeTab() {
 				this.$emit('tab', true)
 			},
 			navTo(url) {
-				console.log(this.hasLogin, 'this.hasLogin');
 				if (!this.hasLogin) {
 					// 保存地址
 					saveUrl();

BIN
static/controller/baoxiu.png


BIN
static/controller/dianchi.png


BIN
static/controller/dingwei.png


BIN
static/controller/huanche.png


BIN
static/controller/kaisuo.png


BIN
static/controller/qidong.png


BIN
static/controller/shouquan.png


BIN
static/controller/witchMessage.png


BIN
static/controller/witchShop.png


BIN
static/controller/xincheng.png


BIN
static/controller/xunche.png


BIN
static/icon/appleIcon.png


BIN
static/icon/gpsW.png


BIN
static/icon/myAddress.png


BIN
static/icon/myCode.png


BIN
static/icon/mymoney.png


BIN
static/icon/orderAli.png


BIN
static/icon/orderWx.png


BIN
static/icon/scend.png


BIN
static/icon/search.png


BIN
static/icon/searchList.png


BIN
static/icon/yh.png


BIN
static/image/followButtom.png


BIN
static/image/followCenter.png


BIN
static/image/followTop.jpg


BIN
static/image/modelQshare.png


BIN
static/image/qybanner.jpg


BIN
static/image/qyweichat.jpg


BIN
static/image/realBm.png


BIN
static/image/realUser.png


BIN
static/image/realXyf.png


BIN
static/image/realZm.png


BIN
static/image/teimImg.jpg


BIN
static/img/b0c1028581f40a90b2454abfde489f9.png


BIN
static/img/bg.png


BIN
static/img/domLogo.png


BIN
static/img/e0caee5ee096efb49bed156878b1db1.png


BIN
static/tabBar/tab-xxjl-current.png


BIN
static/tabBar/tab-xxjl.png


+ 8 - 0
store/index.js

@@ -20,8 +20,16 @@ const store = new Vuex.Store({
 		// #ifdef APP-PLUS
 		fx:false,//是否显示分销
 		// #endif
+		// #ifdef MP
+		systeam:''
+		// #endif
 	},
 	mutations: {
+		// #ifdef MP
+		setSystem(state, provider){
+			state.systeam = provider;
+		},
+		// #endif
 		// 保存是否要加载引导图
 		setFirstUse(state, provider){
 			state.firstUse = provider;

+ 24 - 0
uni_modules/q-previewImage/changelog.md

@@ -0,0 +1,24 @@
+## 1.1.2(2024-04-24)
+优化长图显示
+## 1.1.0(2023-08-01)
+优化文档
+## 1.0.9(2023-07-10)
+优化文档
+## 1.0.8(2023-06-25)
+优化文档
+## 1.0.7(2023-06-25)
+优化文档
+## 1.0.6(2023-05-26)
+优化文档
+## 1.0.5(2023-05-22)
+优化文档
+## 1.0.4(2023-04-30)
+新增图片放大功能,解决原生组件和tabbar导航栏等无法覆盖的问题
+## 1.0.3(2023-04-28)
+优化文档
+## 1.0.2(2023-04-28)
+优化文档
+## 1.0.1(2023-04-28)
+新增长按事件
+## 1.0.0(2023-04-28)
+插件上线

+ 124 - 0
uni_modules/q-previewImage/components/q-previewImage/q-previewImage.vue

@@ -0,0 +1,124 @@
+<template>
+	<view class="previewImage" v-if="show" @tap="close">
+		<view class="page" v-if="urls.length > 0">
+			<text class="text">{{ current + 1 }} / {{ urls.length }}</text>
+		</view>
+		<swiper class="swiper" :current="current" @change="swiperChange"  @touchstart="handleTouchStart" @touchend="handleTouchEnd">
+			<swiper-item v-for="(item, index) in urls" :key="index">
+				<movable-area class="movable-area" scale-area>
+					<movable-view class="movable-view" direction="all" :inertia="true" damping="100" scale="true" scale-min="1" scale-max="4" :scale-value="scale">
+						<scroll-view scroll-y="true" class="uni-scroll-view">
+							<view class="scroll-view"><image :key="index" class="image" :src="item" mode="widthFix" @longpress="onLongpress(item)" /></view>
+						</scroll-view>
+					</movable-view>
+				</movable-area>
+			</swiper-item>
+		</swiper>
+	</view>
+</template>
+
+<script>
+export default {
+	props: {
+		urls: {
+			type: Array,
+			required: true,
+			default: () => {
+				return [];
+			}
+		}
+	},
+	data() {
+		return {
+			show: false,
+			current: 0, //当前页
+			scale: 1,
+			isZooming: false // 是否处于缩放状态
+		};
+	},
+	methods: {
+		//打开
+		open(current) {
+			this.current = this.urls.findIndex(item => item === current);
+			this.show = true;
+			this.$emit('open');
+		},
+		//关闭
+		close() {
+			if (!this.isZooming) {
+				this.show = false;
+				this.current = 0;
+				this.$emit('close');
+			}
+		},
+		//图片改变
+		swiperChange(e) {
+			this.current = e.detail.current;
+		},
+		//监听长按
+		onLongpress(e) {
+			this.$emit('onLongpress', e);
+		},
+		handleTouchStart() {
+			this.isZooming = true;
+		},
+		handleTouchEnd() {
+			this.isZooming = false;
+		}
+	}
+};
+</script>
+
+<style lang="scss" scoped>
+.previewImage {
+	z-index: 9999;
+	position: fixed;
+	top: 0;
+	left: 0;
+	width: 100%;
+	height: 100%;
+	background-color: #000000;
+	.swiper {
+		width: 100%;
+		height: 100vh;
+		swiper-item {
+			.movable-area {
+				height: 100%;
+				width: 100%;
+				.movable-view {
+					width: 100%;
+					min-height: 100%;
+					.uni-scroll-view{
+						height: 100vh;
+					}
+					.scroll-view {
+						display: flex;
+						align-items: center;
+						justify-content: center;
+						min-height: 100vh;
+						.image {
+							width: 100%;
+							height: auto;
+						}
+					}
+				}
+			}
+		}
+	}
+	.page {
+		position: absolute;
+		z-index: 9999;
+		width: 100%;
+		top: 60rpx;
+		text-align: center;
+		.text {
+			color: #fff;
+			font-size: 32rpx;
+			background-color: rgba(0, 0, 0, 0.5);
+			padding: 3rpx 16rpx;
+			border-radius: 20rpx;
+			user-select: none;
+		}
+	}
+}
+</style>

+ 82 - 0
uni_modules/q-previewImage/package.json

@@ -0,0 +1,82 @@
+{
+  "id": "q-previewImage",
+  "displayName": "图片预览、多图左右滑动、图片放大、支持覆盖原生组件、原生导航栏、tabbar",
+  "version": "1.1.2",
+  "description": "最简洁的模拟图片预览,支持长按事件,多图左右滑动,大图上下滑动查看,支持图片放大,支持覆盖原生组件/原生导航栏/tabbar  支持vue2/vue3/app/小程序/h5",
+  "keywords": [
+    "图片预览"
+],
+  "repository": "",
+  "engines": {
+    "HBuilderX": "^3.6.13"
+  },
+  "dcloudext": {
+    "type": "component-vue",
+    "sale": {
+      "regular": {
+        "price": "0.00"
+      },
+      "sourcecode": {
+        "price": "0.00"
+      }
+    },
+    "contact": {
+      "qq": ""
+    },
+    "declaration": {
+      "ads": "无",
+      "data": "无",
+      "permissions": "无"
+    },
+    "npmurl": ""
+  },
+  "uni_modules": {
+    "dependencies": [],
+    "encrypt": [],
+    "platforms": {
+      "cloud": {
+        "tcb": "y",
+        "aliyun": "y",
+        "alipay": "n"
+      },
+      "client": {
+        "Vue": {
+          "vue2": "y",
+          "vue3": "y"
+        },
+        "App": {
+          "app-vue": "y",
+          "app-nvue": "n"
+        },
+        "H5-mobile": {
+          "Safari": "y",
+          "Android Browser": "u",
+          "微信浏览器(Android)": "u",
+          "QQ浏览器(Android)": "u"
+        },
+        "H5-pc": {
+          "Chrome": "u",
+          "IE": "u",
+          "Edge": "u",
+          "Firefox": "u",
+          "Safari": "u"
+        },
+        "小程序": {
+          "微信": "y",
+          "阿里": "u",
+          "百度": "u",
+          "字节跳动": "u",
+          "QQ": "u",
+          "钉钉": "u",
+          "快手": "u",
+          "飞书": "u",
+          "京东": "u"
+        },
+        "快应用": {
+          "华为": "u",
+          "联盟": "u"
+        }
+      }
+    }
+  }
+}

+ 244 - 0
uni_modules/q-previewImage/readme.md

@@ -0,0 +1,244 @@
+# 最简洁的模拟图片预览,支持长按事件,多图左右滑动,大图上下滑动查看,支持图片放大,支持覆盖原生组件/原生导航栏/tabbar  支持vue2/vue3/app/小程序/h5
+
+  - 为了解决项目中因一些特殊原因无法使用uni.previewImage,例如App.onShow或者页面的oShow中写了方法。
+  - 如果用uni.previewImage,每次预览图片都会进到onShow的方法里
+  - 可以基本实现官方的预览图片功能,但是体验不如uni.previewImage()
+  - 如没有特殊原因,还是推荐官方的uni.previewImage()
+
+## 安装指引
+
+##1. 在插件市场打开本插件页面,在右侧点击`使用 HBuilderX 导入插件`,选择要导入的项目点击确定
+
+##2. 使用方法 vue2写法
+
+```
+<template>
+	<view>
+		<video v-if="videoShow" id="myVideo" src="https://img.cdn.aliyun.dcloud.net.cn/guide/uniapp/%E7%AC%AC1%E8%AE%B2%EF%BC%88uni-app%E4%BA%A7%E5%93%81%E4%BB%8B%E7%BB%8D%EF%BC%89-%20DCloud%E5%AE%98%E6%96%B9%E8%A7%86%E9%A2%91%E6%95%99%E7%A8%8B@20200317.mp4" controls></video>
+		<image v-for="(item, index) in imgs" :key="index" :src="item" @click="preview(item)"></image>
+		<q-previewImage ref="previewImage" :urls="imgs" @onLongpress="onLongpress" @open="open" @close="close"></q-previewImage>
+	</view>
+</template>
+
+<script>
+export default {
+ 	data() {
+ 		return {
+			videoShow:true,//video组件是否显示
+ 			imgs: [],
+ 		};
+ 	},
+
+ 	methods: {
+ 		preview(url) {
+			this.imgs = ['https://web-assets.dcloud.net.cn/unidoc/zh/multiport-20210812.png', 'https://web-assets.dcloud.net.cn/unidoc/zh/uni-function-diagram.png'] //设置图片数组
+			// #ifdef MP-WEIXIN
+			this.$nextTick(()=>{
+				 this.$refs.previewImage.open(url); // 传入当前选中的图片地址(小程序必须添加$nextTick,解决组件首次加载无图)
+			})
+			// #endif
+			
+			// #ifndef MP-WEIXIN
+			this.$refs.previewImage.open(url); // 传入当前选中的图片地址
+			// #endif
+ 		},
+		onLongpress(e){ //长按事件
+			console.log('当前长按的图片是' + e);
+			uni.showActionSheet({
+				itemList: ['转发给朋友', '保存到手机'],
+				success: function (res) {
+					console.log('选中了第' + (res.tapIndex + 1) + '个按钮');
+				},
+				fail: function (res) {
+					console.log(res.errMsg);
+				}
+			});
+		},
+		
+		/* open和close方法一般用不到,但是在一些特殊场景会用到,
+		 * 比如预览图片时你需要覆盖 NavigationBar和 TabBar,
+		 * 或者在app中需要预览图片时覆盖住原生组件,比如video或者map等,
+		 * 你可以根据open和close去做一些操作,例如隐藏导航栏或者隐藏一些原生组件等
+		 */
+		open(){ //监听组件显示 (隐藏TabBar和NavigationBar,隐藏video原生组件)
+			// uni.hideTabBar()
+			// uni.setNavigationBarColor({
+			//   frontColor: '#000000', // 设置前景色为黑色
+			//   backgroundColor: '#000000', // 设置背景色为黑色
+			// })
+			// this.videoShow = false 
+		},
+		close(){ //监听组件隐藏 (显示TabBar和NavigationBar,显示video原生组件)
+			// uni.showTabBar()
+			// uni.setNavigationBarColor({
+			//   frontColor: '#ffffff', // 设置前景色为白色
+			//   backgroundColor: '#000000', // 设置背景色为黑色
+			// })
+			// this.videoShow = true
+		}
+ 	}
+ };
+</script>
+
+
+```
+
+##3. vue3 setup写法
+
+```
+
+<template>
+	<view>
+		<video v-if="videoShow" id="myVideo" src="https://img.cdn.aliyun.dcloud.net.cn/guide/uniapp/%E7%AC%AC1%E8%AE%B2%EF%BC%88uni-app%E4%BA%A7%E5%93%81%E4%BB%8B%E7%BB%8D%EF%BC%89-%20DCloud%E5%AE%98%E6%96%B9%E8%A7%86%E9%A2%91%E6%95%99%E7%A8%8B@20200317.mp4" controls></video>
+		<image v-for="(item, index) in imgs" :key="index" :src="item" @click="preview(item)"></image>
+		<q-previewImage ref="previewImage" :urls="imgs"  @onLongpress="onLongpress" @open="open" @close="close"></q-previewImage>
+	</view>
+</template>
+
+<script setup>
+import { reactive, ref, toRefs,nextTick } from 'vue';
+
+const data = reactive({
+	videoShow:true,//video组件是否显示
+	imgs: [],
+});
+const previewImage = ref(null);
+
+const { imgs,videoShow } = toRefs(data)// 解构
+
+const preview = url => {
+	data.imgs = ['https://web-assets.dcloud.net.cn/unidoc/zh/multiport-20210812.png', 'https://web-assets.dcloud.net.cn/unidoc/zh/uni-function-diagram.png'] //设置图片数组
+	
+	
+	// #ifdef MP-WEIXIN
+	this.$nextTick(()=>{
+		 previewImage.value.open(url); // 传入当前选中的图片地址(小程序必须添加$nextTick,解决组件首次加载无图)
+	})
+	// #endif
+	
+	// #ifndef MP-WEIXIN
+	previewImage.value.open(url); // 传入当前选中的图片地址
+	// #endif
+};
+
+const onLongpress = e =>{
+	console.log('当前长按的图片是' + e);
+	uni.showActionSheet({
+		itemList: ['转发给朋友', '保存到手机'],
+		success: function (res) {
+			console.log('选中了第' + (res.tapIndex + 1) + '个按钮');
+		},
+		fail: function (res) {
+			console.log(res.errMsg);
+		}
+	});
+}
+
+/* open和close方法一般用不到,但是在一些特殊场景会用到,
+* 比如预览图片时你需要覆盖 NavigationBar和 TabBar,
+* 或者在app中需要预览图片时覆盖住原生组件,比如video或者map等,
+* 你可以根据open和close去做一些操作,例如隐藏导航栏或者隐藏一些原生组件等
+*/
+const open = () => { //监听组件显示 (隐藏TabBar和NavigationBar,隐藏video原生组件)
+	// uni.hideTabBar()
+	// uni.setNavigationBarColor({
+	// 	frontColor: '#000000', // 设置前景色为黑色
+	// 	backgroundColor: '#000000', // 设置背景色为黑色
+	// })
+	// data.videoShow = false 
+}
+
+const close = () => { //监听组件隐藏 (显示TabBar和NavigationBar,显示video原生组件)
+	// uni.showTabBar()
+	// uni.setNavigationBarColor({
+	// 	frontColor: '#ffffff', // 设置前景色为白色
+	// 	backgroundColor: '#000000', // 设置背景色为黑色
+	// })
+	// data.videoShow = true
+}
+
+</script>
+					
+```
+
+##4. 项目示例 (一般返回的数据图片是以逗号或特殊字符分割的字符串,点击时就需要传两个参数,一个是图片数组,一个是当前图片的index)
+## 注意q-previewImage不要写在循环体中,imgs其实就是用来存放当前图片的数组,每次点击每次赋值就行
+
+```
+<template>
+	<view>
+		<video v-if="videoShow" id="myVideo" src="https://img.cdn.aliyun.dcloud.net.cn/guide/uniapp/%E7%AC%AC1%E8%AE%B2%EF%BC%88uni-app%E4%BA%A7%E5%93%81%E4%BB%8B%E7%BB%8D%EF%BC%89-%20DCloud%E5%AE%98%E6%96%B9%E8%A7%86%E9%A2%91%E6%95%99%E7%A8%8B@20200317.mp4" controls></video>
+		<view v-for="(item, index) in list" :key="index" class="list">
+			<image :src="i"  mode="aspectFill" v-for="(i,imgindex) in item.urls.split(',')" @click.stop="preimg(item.urls.split(','),imgindex)"></image>
+		<view>
+		<q-previewImage ref="previewImage" :urls="imgs" @onLongpress="onLongpress" @open="open" @close="close"></q-previewImage>
+	</view>
+</template>
+
+<script>
+export default {
+ 	data() {
+ 		return {
+			videoShow:true,//是否显示video组件
+ 			imgs: [],//imgs其实就是用来存放当前图片的数组,每次点击每次赋值就行
+			
+ 		};
+ 	},
+
+ 	methods: {
+ 		preimg(urls,index){
+ 			this.imgs = urls //imgs其实就是用来存放当前图片的数组,每次点击每次赋值就行
+			// #ifdef MP-WEIXIN
+			this.$nextTick(()=>{
+				 this.$refs.previewImage.open(this.imgs[index]); // 传入当前选中的图片地址(小程序必须添加$nextTick,解决组件首次加载无图)
+			})
+			// #endif
+			
+			// #ifndef MP-WEIXIN
+			this.$refs.previewImage.open(this.imgs[index]); // 传入当前选中的图片地址
+			// #endif
+ 		},
+		onLongpress(e){ //长按事件
+			console.log('当前长按的图片是' + e);
+			uni.showActionSheet({
+				itemList: ['转发给朋友', '保存到手机'],
+				success: function (res) {
+					console.log('选中了第' + (res.tapIndex + 1) + '个按钮');
+				},
+				fail: function (res) {
+					console.log(res.errMsg);
+				}
+			});
+		},
+		/* open和close方法一般用不到,但是在一些特殊场景会用到,
+		 * 比如预览图片时你需要覆盖 NavigationBar和 TabBar,
+		 * 或者在app中需要预览图片时覆盖住原生组件,比如video或者map等,
+		 * 你可以根据open和close去做一些操作,例如隐藏导航栏或者隐藏一些原生组件等
+		 */
+		open(){ //监听组件显示 (隐藏TabBar和NavigationBar,隐藏video原生组件)
+			// uni.hideTabBar()
+			// uni.setNavigationBarColor({
+			//   frontColor: '#000000', // 设置前景色为黑色
+			//   backgroundColor: '#000000', // 设置背景色为黑色
+			// })
+			// this.videoShow = false 
+		},
+		close(){ //监听组件隐藏 (显示TabBar和NavigationBar,显示video原生组件)
+			// uni.showTabBar()
+			// uni.setNavigationBarColor({
+			//   frontColor: '#ffffff', // 设置前景色为白色
+			//   backgroundColor: '#000000', // 设置背景色为黑色
+			// })
+			// this.videoShow = true
+		}
+ 	}
+ };
+</script>
+
+```
+
+
+## 如果插件对您有一点帮助,请给个五星好评,感谢支持
+
+
+## 如有问题,请加qq 965969604

+ 18 - 0
uni_modules/uni-icons/changelog.md

@@ -1,3 +1,21 @@
+## 2.0.9(2024-01-12)
+fix: 修复图标大小默认值错误的问题
+## 2.0.8(2023-12-14)
+- 修复 项目未使用 ts 情况下,打包报错的bug
+## 2.0.7(2023-12-14)
+- 修复 size 属性为 string 时,不加单位导致尺寸异常的bug
+## 2.0.6(2023-12-11)
+- 优化 兼容老版本icon类型,如 top ,bottom 等
+## 2.0.5(2023-12-11)
+- 优化 兼容老版本icon类型,如 top ,bottom 等
+## 2.0.4(2023-12-06)
+- 优化 uni-app x 下示例项目图标排序
+## 2.0.3(2023-12-06)
+- 修复 nvue下引入组件报错的bug
+## 2.0.2(2023-12-05)
+-优化 size 属性支持单位
+## 2.0.1(2023-12-05)
+- 新增 uni-app x 支持定义图标
 ## 1.3.5(2022-01-24)
 - 优化 size 属性可以传入不带单位的字符串数值
 ## 1.3.4(2022-01-24)

+ 91 - 0
uni_modules/uni-icons/components/uni-icons/uni-icons.uvue

@@ -0,0 +1,91 @@
+<template>
+	<text class="uni-icons" :style="styleObj">
+		<slot>{{unicode}}</slot>
+	</text>
+</template>
+
+<script>
+	import { fontData, IconsDataItem } from './uniicons_file'
+
+	/**
+	 * Icons 图标
+	 * @description 用于展示 icon 图标
+	 * @tutorial https://ext.dcloud.net.cn/plugin?id=28
+	 * @property {Number} size 图标大小
+	 * @property {String} type 图标图案,参考示例
+	 * @property {String} color 图标颜色
+	 * @property {String} customPrefix 自定义图标
+	 * @event {Function} click 点击 Icon 触发事件
+	 */
+	export default {
+		name: "uni-icons",
+		props: {
+			type: {
+				type: String,
+				default: ''
+			},
+			color: {
+				type: String,
+				default: '#333333'
+			},
+			size: {
+				type: Object,
+				default: 16
+			},
+			fontFamily: {
+				type: String,
+				default: ''
+			}
+		},
+		data() {
+			return {};
+		},
+		computed: {
+			unicode() : string {
+				let codes = fontData.find((item : IconsDataItem) : boolean => { return item.font_class == this.type })
+				if (codes !== null) {
+					return codes.unicode
+				}
+				return ''
+			},
+			iconSize() : string {
+				const size = this.size
+				if (typeof size == 'string') {
+					const reg = /^[0-9]*$/g
+					return reg.test(size as string) ? '' + size + 'px' : '' + size;
+					// return '' + this.size
+				}
+				return this.getFontSize(size as number)
+			},
+			styleObj() : UTSJSONObject {
+				if (this.fontFamily !== '') {
+					return { color: this.color, fontSize: this.iconSize, fontFamily: this.fontFamily }
+				}
+				return { color: this.color, fontSize: this.iconSize }
+			}
+		},
+		created() { },
+		methods: {
+			/**
+			 * 字体大小
+			 */
+			getFontSize(size : number) : string {
+				return size + 'px';
+			},
+		},
+	}
+</script>
+
+<style scoped>
+	@font-face {
+		font-family: UniIconsFontFamily;
+		src: url('./uniicons.ttf');
+	}
+
+	.uni-icons {
+		font-family: UniIconsFontFamily;
+		font-size: 18px;
+		font-style: normal;
+		color: #333;
+	}
+</style>

+ 31 - 17
uni_modules/uni-icons/components/uni-icons/uni-icons.vue

@@ -1,24 +1,28 @@
 <template>
 	<!-- #ifdef APP-NVUE -->
-	<text :style="{ color: color, 'font-size': iconSize }" class="uni-icons" @click="_onClick">{{unicode}}</text>
+	<text :style="styleObj" class="uni-icons" @click="_onClick">{{unicode}}</text>
 	<!-- #endif -->
 	<!-- #ifndef APP-NVUE -->
-	<text :style="{ color: color, 'font-size': iconSize }" class="uni-icons" :class="['uniui-'+type,customPrefix,customPrefix?type:'']" @click="_onClick"></text>
+	<text :style="styleObj" class="uni-icons" :class="['uniui-'+type,customPrefix,customPrefix?type:'']" @click="_onClick">
+		<slot></slot>
+	</text>
 	<!-- #endif -->
 </template>
 
 <script>
-	import icons from './icons.js';
+	import { fontData } from './uniicons_file_vue.js';
+
 	const getVal = (val) => {
 		const reg = /^[0-9]*$/g
-		return (typeof val === 'number' || reg.test(val) )? val + 'px' : val;
-	} 
+		return (typeof val === 'number' || reg.test(val)) ? val + 'px' : val;
+	}
+
 	// #ifdef APP-NVUE
 	var domModule = weex.requireModule('dom');
 	import iconUrl from './uniicons.ttf'
 	domModule.addRule('fontFace', {
 		'fontFamily': "uniicons",
-		'src': "url('"+iconUrl+"')"
+		'src': "url('" + iconUrl + "')"
 	});
 	// #endif
 
@@ -34,7 +38,7 @@
 	 */
 	export default {
 		name: 'UniIcons',
-		emits:['click'],
+		emits: ['click'],
 		props: {
 			type: {
 				type: String,
@@ -48,26 +52,36 @@
 				type: [Number, String],
 				default: 16
 			},
-			customPrefix:{
+			customPrefix: {
+				type: String,
+				default: ''
+			},
+			fontFamily: {
 				type: String,
 				default: ''
 			}
 		},
 		data() {
 			return {
-				icons: icons.glyphs
+				icons: fontData
 			}
 		},
-		computed:{
-			unicode(){
-				let code = this.icons.find(v=>v.font_class === this.type)
-				if(code){
-					return unescape(`%u${code.unicode}`)
+		computed: {
+			unicode() {
+				let code = this.icons.find(v => v.font_class === this.type)
+				if (code) {
+					return code.unicode
 				}
 				return ''
 			},
-			iconSize(){
+			iconSize() {
 				return getVal(this.size)
+			},
+			styleObj() {
+				if (this.fontFamily !== '') {
+					return `color: ${this.color}; font-size: ${this.iconSize}; font-family: ${this.fontFamily};`
+				}
+				return `color: ${this.color}; font-size: ${this.iconSize};`
 			}
 		},
 		methods: {
@@ -81,9 +95,10 @@
 <style lang="scss">
 	/* #ifndef APP-NVUE */
 	@import './uniicons.css';
+
 	@font-face {
 		font-family: uniicons;
-		src: url('./uniicons.ttf') format('truetype');
+		src: url('./uniicons.ttf');
 	}
 
 	/* #endif */
@@ -92,5 +107,4 @@
 		text-decoration: none;
 		text-align: center;
 	}
-
 </style>

+ 32 - 31
uni_modules/uni-icons/components/uni-icons/uniicons.css

@@ -1,3 +1,12 @@
+
+.uniui-cart-filled:before {
+  content: "\e6d0";
+}
+
+.uniui-gift-filled:before {
+  content: "\e6c4";
+}
+
 .uniui-color:before {
   content: "\e6cf";
 }
@@ -58,10 +67,6 @@
   content: "\e6c3";
 }
 
-.uniui-gift-filled:before {
-  content: "\e6c4";
-}
-
 .uniui-fire-filled:before {
   content: "\e6c5";
 }
@@ -82,6 +87,18 @@
   content: "\e698";
 }
 
+.uniui-arrowthinleft:before {
+  content: "\e6d2";
+}
+
+.uniui-arrowthinup:before {
+  content: "\e6d3";
+}
+
+.uniui-arrowthindown:before {
+  content: "\e6d4";
+}
+
 .uniui-back:before {
   content: "\e6b9";
 }
@@ -94,55 +111,43 @@
   content: "\e6bb";
 }
 
-.uniui-arrowthinright:before {
-  content: "\e6bb";
-}
-
 .uniui-arrow-left:before {
   content: "\e6bc";
 }
 
-.uniui-arrowthinleft:before {
-  content: "\e6bc";
-}
-
 .uniui-arrow-up:before {
   content: "\e6bd";
 }
 
-.uniui-arrowthinup:before {
-  content: "\e6bd";
-}
-
 .uniui-arrow-down:before {
   content: "\e6be";
 }
 
-.uniui-arrowthindown:before {
-  content: "\e6be";
+.uniui-arrowthinright:before {
+  content: "\e6d1";
 }
 
-.uniui-bottom:before {
+.uniui-down:before {
   content: "\e6b8";
 }
 
-.uniui-arrowdown:before {
+.uniui-bottom:before {
   content: "\e6b8";
 }
 
-.uniui-right:before {
-  content: "\e6b5";
+.uniui-arrowright:before {
+  content: "\e6d5";
 }
 
-.uniui-arrowright:before {
+.uniui-right:before {
   content: "\e6b5";
 }
 
-.uniui-top:before {
+.uniui-up:before {
   content: "\e6b6";
 }
 
-.uniui-arrowup:before {
+.uniui-top:before {
   content: "\e6b6";
 }
 
@@ -150,8 +155,8 @@
   content: "\e6b7";
 }
 
-.uniui-arrowleft:before {
-  content: "\e6b7";
+.uniui-arrowup:before {
+  content: "\e6d6";
 }
 
 .uniui-eye:before {
@@ -638,10 +643,6 @@
   content: "\e627";
 }
 
-.uniui-cart-filled:before {
-  content: "\e629";
-}
-
 .uniui-checkbox:before {
   content: "\e62b";
 }

BIN
uni_modules/uni-icons/components/uni-icons/uniicons.ttf


+ 664 - 0
uni_modules/uni-icons/components/uni-icons/uniicons_file.ts

@@ -0,0 +1,664 @@
+
+export type IconsData = {
+	id : string
+	name : string
+	font_family : string
+	css_prefix_text : string
+	description : string
+	glyphs : Array<IconsDataItem>
+}
+
+export type IconsDataItem = {
+	font_class : string
+	unicode : string
+}
+
+
+export const fontData = [
+  {
+    "font_class": "arrow-down",
+    "unicode": "\ue6be"
+  },
+  {
+    "font_class": "arrow-left",
+    "unicode": "\ue6bc"
+  },
+  {
+    "font_class": "arrow-right",
+    "unicode": "\ue6bb"
+  },
+  {
+    "font_class": "arrow-up",
+    "unicode": "\ue6bd"
+  },
+  {
+    "font_class": "auth",
+    "unicode": "\ue6ab"
+  },
+  {
+    "font_class": "auth-filled",
+    "unicode": "\ue6cc"
+  },
+  {
+    "font_class": "back",
+    "unicode": "\ue6b9"
+  },
+  {
+    "font_class": "bars",
+    "unicode": "\ue627"
+  },
+  {
+    "font_class": "calendar",
+    "unicode": "\ue6a0"
+  },
+  {
+    "font_class": "calendar-filled",
+    "unicode": "\ue6c0"
+  },
+  {
+    "font_class": "camera",
+    "unicode": "\ue65a"
+  },
+  {
+    "font_class": "camera-filled",
+    "unicode": "\ue658"
+  },
+  {
+    "font_class": "cart",
+    "unicode": "\ue631"
+  },
+  {
+    "font_class": "cart-filled",
+    "unicode": "\ue6d0"
+  },
+  {
+    "font_class": "chat",
+    "unicode": "\ue65d"
+  },
+  {
+    "font_class": "chat-filled",
+    "unicode": "\ue659"
+  },
+  {
+    "font_class": "chatboxes",
+    "unicode": "\ue696"
+  },
+  {
+    "font_class": "chatboxes-filled",
+    "unicode": "\ue692"
+  },
+  {
+    "font_class": "chatbubble",
+    "unicode": "\ue697"
+  },
+  {
+    "font_class": "chatbubble-filled",
+    "unicode": "\ue694"
+  },
+  {
+    "font_class": "checkbox",
+    "unicode": "\ue62b"
+  },
+  {
+    "font_class": "checkbox-filled",
+    "unicode": "\ue62c"
+  },
+  {
+    "font_class": "checkmarkempty",
+    "unicode": "\ue65c"
+  },
+  {
+    "font_class": "circle",
+    "unicode": "\ue65b"
+  },
+  {
+    "font_class": "circle-filled",
+    "unicode": "\ue65e"
+  },
+  {
+    "font_class": "clear",
+    "unicode": "\ue66d"
+  },
+  {
+    "font_class": "close",
+    "unicode": "\ue673"
+  },
+  {
+    "font_class": "closeempty",
+    "unicode": "\ue66c"
+  },
+  {
+    "font_class": "cloud-download",
+    "unicode": "\ue647"
+  },
+  {
+    "font_class": "cloud-download-filled",
+    "unicode": "\ue646"
+  },
+  {
+    "font_class": "cloud-upload",
+    "unicode": "\ue645"
+  },
+  {
+    "font_class": "cloud-upload-filled",
+    "unicode": "\ue648"
+  },
+  {
+    "font_class": "color",
+    "unicode": "\ue6cf"
+  },
+  {
+    "font_class": "color-filled",
+    "unicode": "\ue6c9"
+  },
+  {
+    "font_class": "compose",
+    "unicode": "\ue67f"
+  },
+  {
+    "font_class": "contact",
+    "unicode": "\ue693"
+  },
+  {
+    "font_class": "contact-filled",
+    "unicode": "\ue695"
+  },
+  {
+    "font_class": "down",
+    "unicode": "\ue6b8"
+  },
+	{
+	  "font_class": "bottom",
+	  "unicode": "\ue6b8"
+	},
+  {
+    "font_class": "download",
+    "unicode": "\ue68d"
+  },
+  {
+    "font_class": "download-filled",
+    "unicode": "\ue681"
+  },
+  {
+    "font_class": "email",
+    "unicode": "\ue69e"
+  },
+  {
+    "font_class": "email-filled",
+    "unicode": "\ue69a"
+  },
+  {
+    "font_class": "eye",
+    "unicode": "\ue651"
+  },
+  {
+    "font_class": "eye-filled",
+    "unicode": "\ue66a"
+  },
+  {
+    "font_class": "eye-slash",
+    "unicode": "\ue6b3"
+  },
+  {
+    "font_class": "eye-slash-filled",
+    "unicode": "\ue6b4"
+  },
+  {
+    "font_class": "fire",
+    "unicode": "\ue6a1"
+  },
+  {
+    "font_class": "fire-filled",
+    "unicode": "\ue6c5"
+  },
+  {
+    "font_class": "flag",
+    "unicode": "\ue65f"
+  },
+  {
+    "font_class": "flag-filled",
+    "unicode": "\ue660"
+  },
+  {
+    "font_class": "folder-add",
+    "unicode": "\ue6a9"
+  },
+  {
+    "font_class": "folder-add-filled",
+    "unicode": "\ue6c8"
+  },
+  {
+    "font_class": "font",
+    "unicode": "\ue6a3"
+  },
+  {
+    "font_class": "forward",
+    "unicode": "\ue6ba"
+  },
+  {
+    "font_class": "gear",
+    "unicode": "\ue664"
+  },
+  {
+    "font_class": "gear-filled",
+    "unicode": "\ue661"
+  },
+  {
+    "font_class": "gift",
+    "unicode": "\ue6a4"
+  },
+  {
+    "font_class": "gift-filled",
+    "unicode": "\ue6c4"
+  },
+  {
+    "font_class": "hand-down",
+    "unicode": "\ue63d"
+  },
+  {
+    "font_class": "hand-down-filled",
+    "unicode": "\ue63c"
+  },
+  {
+    "font_class": "hand-up",
+    "unicode": "\ue63f"
+  },
+  {
+    "font_class": "hand-up-filled",
+    "unicode": "\ue63e"
+  },
+  {
+    "font_class": "headphones",
+    "unicode": "\ue630"
+  },
+  {
+    "font_class": "heart",
+    "unicode": "\ue639"
+  },
+  {
+    "font_class": "heart-filled",
+    "unicode": "\ue641"
+  },
+  {
+    "font_class": "help",
+    "unicode": "\ue679"
+  },
+  {
+    "font_class": "help-filled",
+    "unicode": "\ue674"
+  },
+  {
+    "font_class": "home",
+    "unicode": "\ue662"
+  },
+  {
+    "font_class": "home-filled",
+    "unicode": "\ue663"
+  },
+  {
+    "font_class": "image",
+    "unicode": "\ue670"
+  },
+  {
+    "font_class": "image-filled",
+    "unicode": "\ue678"
+  },
+  {
+    "font_class": "images",
+    "unicode": "\ue650"
+  },
+  {
+    "font_class": "images-filled",
+    "unicode": "\ue64b"
+  },
+  {
+    "font_class": "info",
+    "unicode": "\ue669"
+  },
+  {
+    "font_class": "info-filled",
+    "unicode": "\ue649"
+  },
+  {
+    "font_class": "left",
+    "unicode": "\ue6b7"
+  },
+  {
+    "font_class": "link",
+    "unicode": "\ue6a5"
+  },
+  {
+    "font_class": "list",
+    "unicode": "\ue644"
+  },
+  {
+    "font_class": "location",
+    "unicode": "\ue6ae"
+  },
+  {
+    "font_class": "location-filled",
+    "unicode": "\ue6af"
+  },
+  {
+    "font_class": "locked",
+    "unicode": "\ue66b"
+  },
+  {
+    "font_class": "locked-filled",
+    "unicode": "\ue668"
+  },
+  {
+    "font_class": "loop",
+    "unicode": "\ue633"
+  },
+  {
+    "font_class": "mail-open",
+    "unicode": "\ue643"
+  },
+  {
+    "font_class": "mail-open-filled",
+    "unicode": "\ue63a"
+  },
+  {
+    "font_class": "map",
+    "unicode": "\ue667"
+  },
+  {
+    "font_class": "map-filled",
+    "unicode": "\ue666"
+  },
+  {
+    "font_class": "map-pin",
+    "unicode": "\ue6ad"
+  },
+  {
+    "font_class": "map-pin-ellipse",
+    "unicode": "\ue6ac"
+  },
+  {
+    "font_class": "medal",
+    "unicode": "\ue6a2"
+  },
+  {
+    "font_class": "medal-filled",
+    "unicode": "\ue6c3"
+  },
+  {
+    "font_class": "mic",
+    "unicode": "\ue671"
+  },
+  {
+    "font_class": "mic-filled",
+    "unicode": "\ue677"
+  },
+  {
+    "font_class": "micoff",
+    "unicode": "\ue67e"
+  },
+  {
+    "font_class": "micoff-filled",
+    "unicode": "\ue6b0"
+  },
+  {
+    "font_class": "minus",
+    "unicode": "\ue66f"
+  },
+  {
+    "font_class": "minus-filled",
+    "unicode": "\ue67d"
+  },
+  {
+    "font_class": "more",
+    "unicode": "\ue64d"
+  },
+  {
+    "font_class": "more-filled",
+    "unicode": "\ue64e"
+  },
+  {
+    "font_class": "navigate",
+    "unicode": "\ue66e"
+  },
+  {
+    "font_class": "navigate-filled",
+    "unicode": "\ue67a"
+  },
+  {
+    "font_class": "notification",
+    "unicode": "\ue6a6"
+  },
+  {
+    "font_class": "notification-filled",
+    "unicode": "\ue6c1"
+  },
+  {
+    "font_class": "paperclip",
+    "unicode": "\ue652"
+  },
+  {
+    "font_class": "paperplane",
+    "unicode": "\ue672"
+  },
+  {
+    "font_class": "paperplane-filled",
+    "unicode": "\ue675"
+  },
+  {
+    "font_class": "person",
+    "unicode": "\ue699"
+  },
+  {
+    "font_class": "person-filled",
+    "unicode": "\ue69d"
+  },
+  {
+    "font_class": "personadd",
+    "unicode": "\ue69f"
+  },
+  {
+    "font_class": "personadd-filled",
+    "unicode": "\ue698"
+  },
+  {
+    "font_class": "personadd-filled-copy",
+    "unicode": "\ue6d1"
+  },
+  {
+    "font_class": "phone",
+    "unicode": "\ue69c"
+  },
+  {
+    "font_class": "phone-filled",
+    "unicode": "\ue69b"
+  },
+  {
+    "font_class": "plus",
+    "unicode": "\ue676"
+  },
+  {
+    "font_class": "plus-filled",
+    "unicode": "\ue6c7"
+  },
+  {
+    "font_class": "plusempty",
+    "unicode": "\ue67b"
+  },
+  {
+    "font_class": "pulldown",
+    "unicode": "\ue632"
+  },
+  {
+    "font_class": "pyq",
+    "unicode": "\ue682"
+  },
+  {
+    "font_class": "qq",
+    "unicode": "\ue680"
+  },
+  {
+    "font_class": "redo",
+    "unicode": "\ue64a"
+  },
+  {
+    "font_class": "redo-filled",
+    "unicode": "\ue655"
+  },
+  {
+    "font_class": "refresh",
+    "unicode": "\ue657"
+  },
+  {
+    "font_class": "refresh-filled",
+    "unicode": "\ue656"
+  },
+  {
+    "font_class": "refreshempty",
+    "unicode": "\ue6bf"
+  },
+  {
+    "font_class": "reload",
+    "unicode": "\ue6b2"
+  },
+  {
+    "font_class": "right",
+    "unicode": "\ue6b5"
+  },
+  {
+    "font_class": "scan",
+    "unicode": "\ue62a"
+  },
+  {
+    "font_class": "search",
+    "unicode": "\ue654"
+  },
+  {
+    "font_class": "settings",
+    "unicode": "\ue653"
+  },
+  {
+    "font_class": "settings-filled",
+    "unicode": "\ue6ce"
+  },
+  {
+    "font_class": "shop",
+    "unicode": "\ue62f"
+  },
+  {
+    "font_class": "shop-filled",
+    "unicode": "\ue6cd"
+  },
+  {
+    "font_class": "smallcircle",
+    "unicode": "\ue67c"
+  },
+  {
+    "font_class": "smallcircle-filled",
+    "unicode": "\ue665"
+  },
+  {
+    "font_class": "sound",
+    "unicode": "\ue684"
+  },
+  {
+    "font_class": "sound-filled",
+    "unicode": "\ue686"
+  },
+  {
+    "font_class": "spinner-cycle",
+    "unicode": "\ue68a"
+  },
+  {
+    "font_class": "staff",
+    "unicode": "\ue6a7"
+  },
+  {
+    "font_class": "staff-filled",
+    "unicode": "\ue6cb"
+  },
+  {
+    "font_class": "star",
+    "unicode": "\ue688"
+  },
+  {
+    "font_class": "star-filled",
+    "unicode": "\ue68f"
+  },
+  {
+    "font_class": "starhalf",
+    "unicode": "\ue683"
+  },
+  {
+    "font_class": "trash",
+    "unicode": "\ue687"
+  },
+  {
+    "font_class": "trash-filled",
+    "unicode": "\ue685"
+  },
+  {
+    "font_class": "tune",
+    "unicode": "\ue6aa"
+  },
+  {
+    "font_class": "tune-filled",
+    "unicode": "\ue6ca"
+  },
+  {
+    "font_class": "undo",
+    "unicode": "\ue64f"
+  },
+  {
+    "font_class": "undo-filled",
+    "unicode": "\ue64c"
+  },
+  {
+    "font_class": "up",
+    "unicode": "\ue6b6"
+  },
+	{
+	  "font_class": "top",
+	  "unicode": "\ue6b6"
+	},
+  {
+    "font_class": "upload",
+    "unicode": "\ue690"
+  },
+  {
+    "font_class": "upload-filled",
+    "unicode": "\ue68e"
+  },
+  {
+    "font_class": "videocam",
+    "unicode": "\ue68c"
+  },
+  {
+    "font_class": "videocam-filled",
+    "unicode": "\ue689"
+  },
+  {
+    "font_class": "vip",
+    "unicode": "\ue6a8"
+  },
+  {
+    "font_class": "vip-filled",
+    "unicode": "\ue6c6"
+  },
+  {
+    "font_class": "wallet",
+    "unicode": "\ue6b1"
+  },
+  {
+    "font_class": "wallet-filled",
+    "unicode": "\ue6c2"
+  },
+  {
+    "font_class": "weibo",
+    "unicode": "\ue68b"
+  },
+  {
+    "font_class": "weixin",
+    "unicode": "\ue691"
+  }
+] as IconsDataItem[]
+
+// export const fontData = JSON.parse<IconsDataItem>(fontDataJson)

+ 649 - 0
uni_modules/uni-icons/components/uni-icons/uniicons_file_vue.js

@@ -0,0 +1,649 @@
+
+export const fontData = [
+  {
+    "font_class": "arrow-down",
+    "unicode": "\ue6be"
+  },
+  {
+    "font_class": "arrow-left",
+    "unicode": "\ue6bc"
+  },
+  {
+    "font_class": "arrow-right",
+    "unicode": "\ue6bb"
+  },
+  {
+    "font_class": "arrow-up",
+    "unicode": "\ue6bd"
+  },
+  {
+    "font_class": "auth",
+    "unicode": "\ue6ab"
+  },
+  {
+    "font_class": "auth-filled",
+    "unicode": "\ue6cc"
+  },
+  {
+    "font_class": "back",
+    "unicode": "\ue6b9"
+  },
+  {
+    "font_class": "bars",
+    "unicode": "\ue627"
+  },
+  {
+    "font_class": "calendar",
+    "unicode": "\ue6a0"
+  },
+  {
+    "font_class": "calendar-filled",
+    "unicode": "\ue6c0"
+  },
+  {
+    "font_class": "camera",
+    "unicode": "\ue65a"
+  },
+  {
+    "font_class": "camera-filled",
+    "unicode": "\ue658"
+  },
+  {
+    "font_class": "cart",
+    "unicode": "\ue631"
+  },
+  {
+    "font_class": "cart-filled",
+    "unicode": "\ue6d0"
+  },
+  {
+    "font_class": "chat",
+    "unicode": "\ue65d"
+  },
+  {
+    "font_class": "chat-filled",
+    "unicode": "\ue659"
+  },
+  {
+    "font_class": "chatboxes",
+    "unicode": "\ue696"
+  },
+  {
+    "font_class": "chatboxes-filled",
+    "unicode": "\ue692"
+  },
+  {
+    "font_class": "chatbubble",
+    "unicode": "\ue697"
+  },
+  {
+    "font_class": "chatbubble-filled",
+    "unicode": "\ue694"
+  },
+  {
+    "font_class": "checkbox",
+    "unicode": "\ue62b"
+  },
+  {
+    "font_class": "checkbox-filled",
+    "unicode": "\ue62c"
+  },
+  {
+    "font_class": "checkmarkempty",
+    "unicode": "\ue65c"
+  },
+  {
+    "font_class": "circle",
+    "unicode": "\ue65b"
+  },
+  {
+    "font_class": "circle-filled",
+    "unicode": "\ue65e"
+  },
+  {
+    "font_class": "clear",
+    "unicode": "\ue66d"
+  },
+  {
+    "font_class": "close",
+    "unicode": "\ue673"
+  },
+  {
+    "font_class": "closeempty",
+    "unicode": "\ue66c"
+  },
+  {
+    "font_class": "cloud-download",
+    "unicode": "\ue647"
+  },
+  {
+    "font_class": "cloud-download-filled",
+    "unicode": "\ue646"
+  },
+  {
+    "font_class": "cloud-upload",
+    "unicode": "\ue645"
+  },
+  {
+    "font_class": "cloud-upload-filled",
+    "unicode": "\ue648"
+  },
+  {
+    "font_class": "color",
+    "unicode": "\ue6cf"
+  },
+  {
+    "font_class": "color-filled",
+    "unicode": "\ue6c9"
+  },
+  {
+    "font_class": "compose",
+    "unicode": "\ue67f"
+  },
+  {
+    "font_class": "contact",
+    "unicode": "\ue693"
+  },
+  {
+    "font_class": "contact-filled",
+    "unicode": "\ue695"
+  },
+  {
+    "font_class": "down",
+    "unicode": "\ue6b8"
+  },
+	{
+	  "font_class": "bottom",
+	  "unicode": "\ue6b8"
+	},
+  {
+    "font_class": "download",
+    "unicode": "\ue68d"
+  },
+  {
+    "font_class": "download-filled",
+    "unicode": "\ue681"
+  },
+  {
+    "font_class": "email",
+    "unicode": "\ue69e"
+  },
+  {
+    "font_class": "email-filled",
+    "unicode": "\ue69a"
+  },
+  {
+    "font_class": "eye",
+    "unicode": "\ue651"
+  },
+  {
+    "font_class": "eye-filled",
+    "unicode": "\ue66a"
+  },
+  {
+    "font_class": "eye-slash",
+    "unicode": "\ue6b3"
+  },
+  {
+    "font_class": "eye-slash-filled",
+    "unicode": "\ue6b4"
+  },
+  {
+    "font_class": "fire",
+    "unicode": "\ue6a1"
+  },
+  {
+    "font_class": "fire-filled",
+    "unicode": "\ue6c5"
+  },
+  {
+    "font_class": "flag",
+    "unicode": "\ue65f"
+  },
+  {
+    "font_class": "flag-filled",
+    "unicode": "\ue660"
+  },
+  {
+    "font_class": "folder-add",
+    "unicode": "\ue6a9"
+  },
+  {
+    "font_class": "folder-add-filled",
+    "unicode": "\ue6c8"
+  },
+  {
+    "font_class": "font",
+    "unicode": "\ue6a3"
+  },
+  {
+    "font_class": "forward",
+    "unicode": "\ue6ba"
+  },
+  {
+    "font_class": "gear",
+    "unicode": "\ue664"
+  },
+  {
+    "font_class": "gear-filled",
+    "unicode": "\ue661"
+  },
+  {
+    "font_class": "gift",
+    "unicode": "\ue6a4"
+  },
+  {
+    "font_class": "gift-filled",
+    "unicode": "\ue6c4"
+  },
+  {
+    "font_class": "hand-down",
+    "unicode": "\ue63d"
+  },
+  {
+    "font_class": "hand-down-filled",
+    "unicode": "\ue63c"
+  },
+  {
+    "font_class": "hand-up",
+    "unicode": "\ue63f"
+  },
+  {
+    "font_class": "hand-up-filled",
+    "unicode": "\ue63e"
+  },
+  {
+    "font_class": "headphones",
+    "unicode": "\ue630"
+  },
+  {
+    "font_class": "heart",
+    "unicode": "\ue639"
+  },
+  {
+    "font_class": "heart-filled",
+    "unicode": "\ue641"
+  },
+  {
+    "font_class": "help",
+    "unicode": "\ue679"
+  },
+  {
+    "font_class": "help-filled",
+    "unicode": "\ue674"
+  },
+  {
+    "font_class": "home",
+    "unicode": "\ue662"
+  },
+  {
+    "font_class": "home-filled",
+    "unicode": "\ue663"
+  },
+  {
+    "font_class": "image",
+    "unicode": "\ue670"
+  },
+  {
+    "font_class": "image-filled",
+    "unicode": "\ue678"
+  },
+  {
+    "font_class": "images",
+    "unicode": "\ue650"
+  },
+  {
+    "font_class": "images-filled",
+    "unicode": "\ue64b"
+  },
+  {
+    "font_class": "info",
+    "unicode": "\ue669"
+  },
+  {
+    "font_class": "info-filled",
+    "unicode": "\ue649"
+  },
+  {
+    "font_class": "left",
+    "unicode": "\ue6b7"
+  },
+  {
+    "font_class": "link",
+    "unicode": "\ue6a5"
+  },
+  {
+    "font_class": "list",
+    "unicode": "\ue644"
+  },
+  {
+    "font_class": "location",
+    "unicode": "\ue6ae"
+  },
+  {
+    "font_class": "location-filled",
+    "unicode": "\ue6af"
+  },
+  {
+    "font_class": "locked",
+    "unicode": "\ue66b"
+  },
+  {
+    "font_class": "locked-filled",
+    "unicode": "\ue668"
+  },
+  {
+    "font_class": "loop",
+    "unicode": "\ue633"
+  },
+  {
+    "font_class": "mail-open",
+    "unicode": "\ue643"
+  },
+  {
+    "font_class": "mail-open-filled",
+    "unicode": "\ue63a"
+  },
+  {
+    "font_class": "map",
+    "unicode": "\ue667"
+  },
+  {
+    "font_class": "map-filled",
+    "unicode": "\ue666"
+  },
+  {
+    "font_class": "map-pin",
+    "unicode": "\ue6ad"
+  },
+  {
+    "font_class": "map-pin-ellipse",
+    "unicode": "\ue6ac"
+  },
+  {
+    "font_class": "medal",
+    "unicode": "\ue6a2"
+  },
+  {
+    "font_class": "medal-filled",
+    "unicode": "\ue6c3"
+  },
+  {
+    "font_class": "mic",
+    "unicode": "\ue671"
+  },
+  {
+    "font_class": "mic-filled",
+    "unicode": "\ue677"
+  },
+  {
+    "font_class": "micoff",
+    "unicode": "\ue67e"
+  },
+  {
+    "font_class": "micoff-filled",
+    "unicode": "\ue6b0"
+  },
+  {
+    "font_class": "minus",
+    "unicode": "\ue66f"
+  },
+  {
+    "font_class": "minus-filled",
+    "unicode": "\ue67d"
+  },
+  {
+    "font_class": "more",
+    "unicode": "\ue64d"
+  },
+  {
+    "font_class": "more-filled",
+    "unicode": "\ue64e"
+  },
+  {
+    "font_class": "navigate",
+    "unicode": "\ue66e"
+  },
+  {
+    "font_class": "navigate-filled",
+    "unicode": "\ue67a"
+  },
+  {
+    "font_class": "notification",
+    "unicode": "\ue6a6"
+  },
+  {
+    "font_class": "notification-filled",
+    "unicode": "\ue6c1"
+  },
+  {
+    "font_class": "paperclip",
+    "unicode": "\ue652"
+  },
+  {
+    "font_class": "paperplane",
+    "unicode": "\ue672"
+  },
+  {
+    "font_class": "paperplane-filled",
+    "unicode": "\ue675"
+  },
+  {
+    "font_class": "person",
+    "unicode": "\ue699"
+  },
+  {
+    "font_class": "person-filled",
+    "unicode": "\ue69d"
+  },
+  {
+    "font_class": "personadd",
+    "unicode": "\ue69f"
+  },
+  {
+    "font_class": "personadd-filled",
+    "unicode": "\ue698"
+  },
+  {
+    "font_class": "personadd-filled-copy",
+    "unicode": "\ue6d1"
+  },
+  {
+    "font_class": "phone",
+    "unicode": "\ue69c"
+  },
+  {
+    "font_class": "phone-filled",
+    "unicode": "\ue69b"
+  },
+  {
+    "font_class": "plus",
+    "unicode": "\ue676"
+  },
+  {
+    "font_class": "plus-filled",
+    "unicode": "\ue6c7"
+  },
+  {
+    "font_class": "plusempty",
+    "unicode": "\ue67b"
+  },
+  {
+    "font_class": "pulldown",
+    "unicode": "\ue632"
+  },
+  {
+    "font_class": "pyq",
+    "unicode": "\ue682"
+  },
+  {
+    "font_class": "qq",
+    "unicode": "\ue680"
+  },
+  {
+    "font_class": "redo",
+    "unicode": "\ue64a"
+  },
+  {
+    "font_class": "redo-filled",
+    "unicode": "\ue655"
+  },
+  {
+    "font_class": "refresh",
+    "unicode": "\ue657"
+  },
+  {
+    "font_class": "refresh-filled",
+    "unicode": "\ue656"
+  },
+  {
+    "font_class": "refreshempty",
+    "unicode": "\ue6bf"
+  },
+  {
+    "font_class": "reload",
+    "unicode": "\ue6b2"
+  },
+  {
+    "font_class": "right",
+    "unicode": "\ue6b5"
+  },
+  {
+    "font_class": "scan",
+    "unicode": "\ue62a"
+  },
+  {
+    "font_class": "search",
+    "unicode": "\ue654"
+  },
+  {
+    "font_class": "settings",
+    "unicode": "\ue653"
+  },
+  {
+    "font_class": "settings-filled",
+    "unicode": "\ue6ce"
+  },
+  {
+    "font_class": "shop",
+    "unicode": "\ue62f"
+  },
+  {
+    "font_class": "shop-filled",
+    "unicode": "\ue6cd"
+  },
+  {
+    "font_class": "smallcircle",
+    "unicode": "\ue67c"
+  },
+  {
+    "font_class": "smallcircle-filled",
+    "unicode": "\ue665"
+  },
+  {
+    "font_class": "sound",
+    "unicode": "\ue684"
+  },
+  {
+    "font_class": "sound-filled",
+    "unicode": "\ue686"
+  },
+  {
+    "font_class": "spinner-cycle",
+    "unicode": "\ue68a"
+  },
+  {
+    "font_class": "staff",
+    "unicode": "\ue6a7"
+  },
+  {
+    "font_class": "staff-filled",
+    "unicode": "\ue6cb"
+  },
+  {
+    "font_class": "star",
+    "unicode": "\ue688"
+  },
+  {
+    "font_class": "star-filled",
+    "unicode": "\ue68f"
+  },
+  {
+    "font_class": "starhalf",
+    "unicode": "\ue683"
+  },
+  {
+    "font_class": "trash",
+    "unicode": "\ue687"
+  },
+  {
+    "font_class": "trash-filled",
+    "unicode": "\ue685"
+  },
+  {
+    "font_class": "tune",
+    "unicode": "\ue6aa"
+  },
+  {
+    "font_class": "tune-filled",
+    "unicode": "\ue6ca"
+  },
+  {
+    "font_class": "undo",
+    "unicode": "\ue64f"
+  },
+  {
+    "font_class": "undo-filled",
+    "unicode": "\ue64c"
+  },
+  {
+    "font_class": "up",
+    "unicode": "\ue6b6"
+  },
+	{
+	  "font_class": "top",
+	  "unicode": "\ue6b6"
+	},
+  {
+    "font_class": "upload",
+    "unicode": "\ue690"
+  },
+  {
+    "font_class": "upload-filled",
+    "unicode": "\ue68e"
+  },
+  {
+    "font_class": "videocam",
+    "unicode": "\ue68c"
+  },
+  {
+    "font_class": "videocam-filled",
+    "unicode": "\ue689"
+  },
+  {
+    "font_class": "vip",
+    "unicode": "\ue6a8"
+  },
+  {
+    "font_class": "vip-filled",
+    "unicode": "\ue6c6"
+  },
+  {
+    "font_class": "wallet",
+    "unicode": "\ue6b1"
+  },
+  {
+    "font_class": "wallet-filled",
+    "unicode": "\ue6c2"
+  },
+  {
+    "font_class": "weibo",
+    "unicode": "\ue68b"
+  },
+  {
+    "font_class": "weixin",
+    "unicode": "\ue691"
+  }
+]
+
+// export const fontData = JSON.parse<IconsDataItem>(fontDataJson)

+ 14 - 12
uni_modules/uni-icons/package.json

@@ -1,7 +1,7 @@
 {
   "id": "uni-icons",
   "displayName": "uni-icons 图标",
-  "version": "1.3.5",
+  "version": "2.0.9",
   "description": "图标组件,用于展示移动端常见的图标,可自定义颜色、大小。",
   "keywords": [
     "uni-ui",
@@ -16,11 +16,7 @@
   "directories": {
     "example": "../../temps/example_temps"
   },
-  "dcloudext": {
-    "category": [
-      "前端组件",
-      "通用组件"
-    ],
+"dcloudext": {
     "sale": {
       "regular": {
         "price": "0.00"
@@ -37,7 +33,8 @@
       "data": "无",
       "permissions": "无"
     },
-    "npmurl": "https://www.npmjs.com/package/@dcloudio/uni-ui"
+    "npmurl": "https://www.npmjs.com/package/@dcloudio/uni-ui",
+    "type": "component-vue"
   },
   "uni_modules": {
     "dependencies": ["uni-scss"],
@@ -50,7 +47,8 @@
       "client": {
         "App": {
           "app-vue": "y",
-          "app-nvue": "y"
+          "app-nvue": "y",
+          "app-uvue": "y"
         },
         "H5-mobile": {
           "Safari": "y",
@@ -70,11 +68,15 @@
           "阿里": "y",
           "百度": "y",
           "字节跳动": "y",
-          "QQ": "y"
+          "QQ": "y",
+					"钉钉": "y",
+					"快手": "y",
+					"飞书": "y",
+					"京东": "y"
         },
         "快应用": {
-          "华为": "u",
-          "联盟": "u"
+          "华为": "y",
+          "联盟": "y"
         },
         "Vue": {
             "vue2": "y",
@@ -83,4 +85,4 @@
       }
     }
   }
-}
+}

+ 4 - 0
uni_modules/uni-notice-bar/changelog.md

@@ -1,3 +1,7 @@
+## 1.2.2(2023-12-20)
+- 修复动态绑定title时,滚动速度不一致的问题
+## 1.2.1(2022-09-05)
+- 新增 属性 fontSize,可修改文字大小。
 ## 1.2.0(2021-11-19)
 - 优化 组件UI,并提供设计资源,详见:[https://uniapp.dcloud.io/component/uniui/resource](https://uniapp.dcloud.io/component/uniui/resource)
 - 文档迁移,详见:[https://uniapp.dcloud.io/component/uniui/uni-notice-bar](https://uniapp.dcloud.io/component/uniui/uni-notice-bar)

+ 54 - 18
uni_modules/uni-notice-bar/components/uni-notice-bar/uni-notice-bar.vue

@@ -1,24 +1,47 @@
 <template>
-	<view v-if="show" class="uni-noticebar" :style="{ backgroundColor: backgroundColor }" @click="onClick">
+	<view v-if="show" class="uni-noticebar" :style="{ backgroundColor }" @click="onClick">
 		<uni-icons v-if="showIcon === true || showIcon === 'true'" class="uni-noticebar-icon" type="sound"
-			:color="color" size="22" />
+			:color="color" :size="fontSize * 1.5" />
 		<view ref="textBox" class="uni-noticebar__content-wrapper"
-			:class="{'uni-noticebar__content-wrapper--scrollable':scrollable, 'uni-noticebar__content-wrapper--single':!scrollable && (single || moreText)}">
+			:class="{
+				'uni-noticebar__content-wrapper--scrollable': scrollable,
+				'uni-noticebar__content-wrapper--single': !scrollable && (single || moreText)
+			}"
+			:style="{ height: scrollable ? fontSize * 1.5 + 'px' : 'auto' }"
+		>
 			<view :id="elIdBox" class="uni-noticebar__content"
-				:class="{'uni-noticebar__content--scrollable':scrollable, 'uni-noticebar__content--single':!scrollable && (single || moreText)}">
-				<text :id="elId" ref="animationEle" class="uni-noticebar__content-text"
-					:class="{'uni-noticebar__content-text--scrollable':scrollable,'uni-noticebar__content-text--single':!scrollable && (single || showGetMore)}"
-					:style="{color:color, width:wrapWidth+'px', 'animationDuration': animationDuration, '-webkit-animationDuration': animationDuration ,animationPlayState: webviewHide?'paused':animationPlayState,'-webkit-animationPlayState':webviewHide?'paused':animationPlayState, animationDelay: animationDelay, '-webkit-animationDelay':animationDelay}">{{text}}</text>
+				:class="{
+					'uni-noticebar__content--scrollable': scrollable,
+					'uni-noticebar__content--single': !scrollable && (single || moreText)
+				}"
+			>
+				<text :id="elId" ref="animationEle" class="uni-noticebar__content-text" 
+					:class="{
+						'uni-noticebar__content-text--scrollable': scrollable,
+						'uni-noticebar__content-text--single': !scrollable && (single || showGetMore)
+					}" 
+					:style="{
+						color: color,
+						fontSize: fontSize + 'px',
+						lineHeight: fontSize * 1.5 + 'px',
+						width: wrapWidth + 'px',
+						'animationDuration': animationDuration,
+						'-webkit-animationDuration': animationDuration,
+						animationPlayState: webviewHide ? 'paused' : animationPlayState,
+						'-webkit-animationPlayState': webviewHide ? 'paused' : animationPlayState,
+						animationDelay: animationDelay,
+						'-webkit-animationDelay': animationDelay
+					}"
+				>{{text}}</text>
 			</view>
 		</view>
-		<view v-if="showGetMore === true || showGetMore === 'true'" class="uni-noticebar__more uni-cursor-point"
+		<view v-if="isShowGetMore" class="uni-noticebar__more uni-cursor-point"
 			@click="clickMore">
-			<text v-if="moreText.length > 0" :style="{ color: moreColor }" class="uni-noticebar__more-text">{{ moreText }}</text>
-			<uni-icons v-else type="right" :color="moreColor" size="16" />
+			<text v-if="moreText.length > 0" :style="{ color: moreColor, fontSize: fontSize + 'px' }">{{ moreText }}</text>
+			<uni-icons v-else type="right" :color="moreColor" :size="fontSize * 1.1" />
 		</view>
-		<view class="uni-noticebar-close uni-cursor-point" v-if="(showClose === true || showClose === 'true') && (showGetMore === false || showGetMore === 'false')">
-			<uni-icons
-				type="closeempty" :color="color" size="16" @click="close" />
+		<view class="uni-noticebar-close uni-cursor-point" v-if="isShowClose">
+			<uni-icons type="closeempty" :color="color" :size="fontSize * 1.1" @click="close" />
 		</view>
 	</view>
 </template>
@@ -74,6 +97,10 @@
 				type: String,
 				default: '#FF9A43'
 			},
+			fontSize: {
+				type: Number,
+				default: 14
+			},
 			moreColor: {
 				type: String,
 				default: '#FF9A43'
@@ -123,6 +150,20 @@
 				animationDelay: '0s'
 			}
 		},
+		watch:{
+			text:function(newValue,oldValue){
+				this.initSize();
+			}
+		},
+		computed: {
+			isShowGetMore() {
+				return this.showGetMore === true || this.showGetMore === 'true'
+			},
+			isShowClose() {
+				return (this.showClose === true || this.showClose === 'true') 
+					&& (this.showGetMore === false || this.showGetMore === 'false')
+			}
+		},
 		mounted() {
 			// #ifdef APP-PLUS
 			var pages = getCurrentPages();
@@ -310,7 +351,6 @@
 	/* #ifndef APP-NVUE */
 	.uni-noticebar__content-wrapper--scrollable {
 		position: relative;
-		height: 18px;
 	}
 
 	/* #endif */
@@ -383,10 +423,6 @@
 		padding-left: 5px;
 	}
 
-	.uni-noticebar__more-text {
-		font-size: 14px;
-	}
-
 	@keyframes notice {
 		100% {
 			transform: translate3d(-100%, 0, 0);

+ 4 - 7
uni_modules/uni-notice-bar/package.json

@@ -1,7 +1,7 @@
 {
   "id": "uni-notice-bar",
   "displayName": "uni-notice-bar 通告栏",
-  "version": "1.2.0",
+  "version": "1.2.2",
   "description": "NoticeBar 通告栏组件,常用于展示公告信息,可设为滚动公告",
   "keywords": [
     "uni-ui",
@@ -17,11 +17,7 @@
   "directories": {
     "example": "../../temps/example_temps"
   },
-  "dcloudext": {
-    "category": [
-      "前端组件",
-      "通用组件"
-    ],
+"dcloudext": {
     "sale": {
       "regular": {
         "price": "0.00"
@@ -38,7 +34,8 @@
       "data": "无",
       "permissions": "无"
     },
-    "npmurl": "https://www.npmjs.com/package/@dcloudio/uni-ui"
+    "npmurl": "https://www.npmjs.com/package/@dcloudio/uni-ui",
+    "type": "component-vue"
   },
   "uni_modules": {
     "dependencies": [

+ 13 - 12
utils/newRequest.js

@@ -44,17 +44,14 @@ let service = {
 		return await new Promise(function(resolve, reject) {
 			let requestData = ''; //保存处理完成后请求数据
 			let url =''//保存链接地址
-			//console.log(data);
 			// 请求前数据处理
 			requestData = service.request.success(data);
 			// #ifdef H5
 			
 			if(process.env.NODE_ENV === 'development'){
 				url= requestData.url;
-			    console.log('开发环境')
 			}else{
 				url=service.baseURL + requestData.url;
-			    console.log('生产环境')
 			}
 			// #endif
 			// #ifndef H5
@@ -98,10 +95,8 @@ let service = {
 			// #ifdef H5
 			if(process.env.NODE_ENV === 'development'){
 				url= requestData.url;
-			    console.log('开发环境')
 			}else{
 				url=service.baseURL + requestData.url;
-			    console.log('生产环境')
 			}
 			// #endif
 			// #ifndef H5
@@ -111,7 +106,7 @@ let service = {
 				// 上传图片的API
 				upload_img_url:url
 			}
-
+			
 			let Uploader = {
 				// 选择图片
 				choose(num) {
@@ -120,12 +115,10 @@ let service = {
 						uni.chooseImage({
 							count: num,
 							success(res) {
-								// console.log(res);
 								// 缓存文件路径
 								resolve(res.tempFilePaths)
 							},
 							fail(err) {
-								console.log(err,'’1111')
 								uni.showModal({
 									title: '文件打开错误',
 									content: '请设置授权文件存储权限',
@@ -136,13 +129,11 @@ let service = {
 						})
 						// #endif
 						// #ifdef MP-WEIXIN
-						console.log('233');
 						uni.chooseMedia({
 							count: num,
 							success(res) {
-								console.log(res);
 								// 缓存文件路径
-								resolve(res.tempFilePaths)
+								resolve(res.tempFiles)
 							},
 							fail(err) {
 								console.log(err,'’1111')
@@ -179,7 +170,11 @@ let service = {
 									resolve(uploadFileRes.data.data)
 								}
 							},
+							fail(err) {
+								console.log(err,"错误")
+							},
 							complete() {
+								
 								uni.hideLoading()
 							}
 						});
@@ -191,7 +186,13 @@ let service = {
 					return new Promise(async (resolve, reject) => {
 						let img_urls = []
 						for (let i = 0; i < num; i++) {
-							let img_url = await this.upload_one(path_arr[i]);
+							// #ifdef MP
+							let url=path_arr[i].tempFilePath
+							// #endif
+							// #ifndef MP
+							let url = path_arr[i]
+							// #endif
+							let img_url = await this.upload_one(url);
 							img_urls.push(img_url)
 						};
 						resolve(img_urls)

+ 0 - 2
utils/request.js

@@ -11,7 +11,6 @@ service.interceptors.response(
 			let res = response.data;
 			// 解析字符串为数字
 			if (res.code !== 200) {
-				console.log(res.code);
 				if (res.code == 410000) {
 					// 调用退出登录方法清空用户信息
 					store.commit('user/logout');
@@ -63,7 +62,6 @@ service.interceptors.response(
 service.interceptors.request(
 	config => {
 		let token = uni.getStorageSync('token') || '';
-		// console.log(config);
 		if (!config.header) {
 			config.header = {
 				"token":  token,

+ 0 - 2
utils/rocessor.js

@@ -4,7 +4,6 @@ export function isCardNo(card) {
 	var reg =
 		/(^[1-9]\d{5}(18|19|([23]\d))\d{2}((0[1-9])|(10|11|12))(([0-2][1-9])|10|20|30|31)\d{3}[0-9Xx]$)|(^[1-9]\d{5}\d{2}((0[1-9])|(10|11|12))(([0-2][1-9])|10|20|30|31)\d{2}$)/;
 	if (reg.test(card) === false) {
-		console.log(card);
 		return false;
 
 	}
@@ -151,7 +150,6 @@ export function openGetAddress(e) {
 								return false;
 							}
 							if(res.confirm){
-								console.log(openSettingAddress,'开启设置');
 								openSettingAddress().then(() => {
 									reject()
 								}).catch(() => {

Một số tệp đã không được hiển thị bởi vì quá nhiều tập tin thay đổi trong này khác