puyao před 2 týdny
rodič
revize
c715ce3c69

+ 4 - 0
api/courseAuto.js

@@ -86,6 +86,10 @@ export function getConcept() {
 	return request('/course_auto/app/index/getConcept', null, 'GET');
 }
 
+// 获取配置
+export function getConfigByKey(data) {
+	return request('/course_auto/app/common/getConfigByKey', data, 'GET');
+}
  export function getTypeTree(data) {
  	return request('/course_auto/app/user/complaint/getTypeTree', null, 'GET');
  }

+ 2 - 2
api/courseLook.js

@@ -69,8 +69,8 @@ export function getRealLink(data) {
  //h5授权登录
  export function H5logoinApp(data,type) {
 	 if(type&&type==1) {
-		return request('/app/wx/h5/mp/courseLoginByMp',data,'POST','application/json;charset=UTF-8'); 
+		return request('/course_auto/app/wx/h5/mp/courseLoginByMp',data,'POST','application/json;charset=UTF-8'); 
 	 } else {
-		return request('/app/wx/h5/mp/loginByMp',data,'POST','application/json;charset=UTF-8'); 
+		return request('/course_auto/app/wx/h5/mp/loginByMp',data,'POST','application/json;charset=UTF-8'); 
 	 }
  }

+ 3 - 3
common/request.js

@@ -7,7 +7,7 @@ export default class Request {
 		// let path ='http://k26a55d9.natappfree.cc/'//本地
 		// let path = 'https://userapp.kangniantangyiyao.top/store'//臻选
 		let path = 'https://userappB.kangniantangyiyao.top/store'//惠选和其他小程序
-		//let path = 'http://192.168.110.59:8113/store'
+		// let path = 'http://192.168.110.247:8113/store'
 		// let path2 = 'https://userapp.kangniantangyiyao.top'//直播
 		let path2 = 'https://userappB.kangniantangyiyao.top'//本地(直播)
 		let type = 0
@@ -55,7 +55,7 @@ export default class Request {
 			router =router.replace('/course_auto','')
 			// path = 'http://w43fa358.natappfree.cc'
 			// path = 'https://userapp.kangniantangyiyao.top'//臻选
-			path = 'https://userappB.kangniantangyiyao.top'//惠选
+			path = 'https://userapp.jnmyunl.com'//惠选
 			token =uni.getStorageSync(TOKEN_KEYAuto)
 			console.log("TOKEN_KEYAuto===",TOKEN_KEYAuto,token)
 		}
@@ -63,7 +63,7 @@ export default class Request {
 			type = 3
 			router =router.replace('/course_uniapp','')
 			// path = 'https://userapp.kangniantangyiyao.top'//臻选
-			path = 'https://userappB.kangniantangyiyao.top'//惠选
+			path = 'https://userapp.jnmyunl.com'//惠选
 			token =uni.getStorageSync('TOKEN_WEXIN')
 		}
 		return new Promise((resolve, reject) => {

+ 17 - 3
pages.json

@@ -24,8 +24,8 @@
 		{
 			"path": "pages/home/index",
 			"style": {
-				// "navigationBarTitleText": "德信严选 ",
-				"navigationBarTitleText": "德信严选 ",
+				// "navigationBarTitleText": "康年惠选 ",
+				"navigationBarTitleText": "康年惠选 ",
 				"enablePullDownRefresh": false,
 				"navigationStyle": "custom",
 				"app-plus": {
@@ -1399,6 +1399,20 @@
 						"enablePullDownRefresh": false
 					}
 				},
+				{
+					"path" : "feedback",
+					"style" :                                                                                    
+					{
+						"navigationBarTitleText": "投诉反馈",
+						"navigationStyle": "custom",
+						"scrollIndicator": "none",
+						"app-plus": {
+							"bounce": "none",
+							"softinputMode": "adjustResize"
+						}
+					}
+					
+				},
 				{
 					"path": "video",
 					"style": {
@@ -1439,7 +1453,7 @@
 	],
 	"globalStyle": {
 		"navigationBarTextStyle": "black",
-		"navigationBarTitleText": "德信严选 ",
+		"navigationBarTitleText": "康年惠选 ",
 		"navigationBarBackgroundColor": "#FFFFFF",
 		"backgroundColor": "#FFFFFF"
 	},

+ 2 - 2
pages/auth/login.vue

@@ -7,8 +7,8 @@
 		  	<view class="logo-img">
 				<image  :src="logoimg"></image>
 		  	</view>
-		  	<!-- <view class="title">德信严选 </view> -->
-			<view class="title">德信严选 </view>
+		  	<!-- <view class="title">康年惠选 </view> -->
+			<view class="title">康年惠选 </view>
 		  </view>
         <!-- <open-data class="user-avatar" type="userAvatarUrl"></open-data>
         <open-data class="user-name" type="userNickName"></open-data> -->

+ 1 - 1
pages/common/launch.vue

@@ -5,7 +5,7 @@
 				<view class="circle"></view>
 				<image :src="logoimg"></image>
 			</view>
-			<text class="text">德信严选 </text>
+			<text class="text">康年惠选 </text>
 		</view>
 	</view>
 </template>

+ 20 - 6
pages/home/index.vue

@@ -8,7 +8,7 @@
 					<!-- 这里是状态栏 -->
 					<view class="status_bar" :style="{height: statusBarHeight}"></view>
 					<view class="top-title">
-						<view class="name">德信严选 </view>
+						<view class="name">康年惠选 </view>
 						<!-- <view class="dot">•</view><view class="sub-name">七彩互联网医院</view> -->
 					</view>
 					<!-- 搜索框、购物车、客服 -->
@@ -70,7 +70,7 @@
 				</view> -->
 			</view>
 		</view>
-		<view class="open-class bgf radius12">
+		<!-- <view class="open-class bgf radius12">
 			<view class="title-box">
 				<text class="title">健康大讲堂</text>
 				<view class="more" @click="goClassList(1)">
@@ -87,7 +87,7 @@
 					<view>{{item.courseName}}</view>
 				</view>
 			</view>
-		</view>
+		</view> -->
 		<view class="modules">
 			<view class="module">
 				<!--养生有道-->
@@ -245,6 +245,18 @@
 				<image :src="activity.logoUrl" @tap="showActivity()" />
 			</view>
 		</view>
+		<!-- 左侧悬浮按钮,自定义图标和颜色 -->
+		<!-- <FloatingActionButton
+		  :menuItems="[
+		    { text: '扫一扫', icon: '??' },
+		    { text: '添加', icon: '➕' }
+		  ]"
+		  icon="☰"
+		  bgColor="#ff6b6b"
+		  :bottom="150"
+		  :right="30"
+		  @menuItemClick="handleAction"
+		/> -->
 		<z-modal :show="tuiModalControl" placeholderText="请输入邀请码" :btnGroup="btnGroup" :contentType="2"
 			titleText="填写邀请码" @cancle="cancleTui" @sure="submitTui"></z-modal>
 		<!-- <tabbar :actindex="0"></tabbar> -->
@@ -294,6 +306,7 @@
 		bindPromoter
 	} from '@/api/user'
 	import { mapGetters } from 'vuex';
+	import FloatingActionButton from '@/components/FloatingActionButton/FloatingActionButton.vue'
 	export default {
 		components: {
 			zModal,
@@ -301,7 +314,8 @@
 			Menu,
 			HotProduct,
 			NewProduct,
-			TuiProduct
+			TuiProduct,
+			FloatingActionButton
 		},
 		data() {
 			return {
@@ -457,7 +471,7 @@
 		},
 		onShareAppMessage(res) {
 			return {
-				title: '德信严选 -您的专属健康解决方案',
+				title: '康年惠选 -您的专属健康解决方案',
 				path: `/pages/common/launch`,
 				imageUrl:this.logoimg//分享图标,路径可以是本地文件路径、代码包文件路径或者网络图片路径.支持PNG及JPG。显示图片长宽比是 5:4
 			}
@@ -469,7 +483,7 @@
 		//分享到朋友圈
 		onShareTimeline(res) {
 			return {
-				title: '德信严选 -您的专属健康解决方案',
+				title: '康年惠选 -您的专属健康解决方案',
 				query: '', //页面参数
 				imageUrl: this.logoimg//分享图标,路径可以是本地文件路径、代码包文件路径或者网络图片路径.支持PNG及JPG。显示图片长宽比是 5:4
 			}

+ 57 - 23
pages_course/video.vue

@@ -6,7 +6,7 @@
 				<u-icon name="arrow-left" size='22' color="#222" bold></u-icon>
 			</view>
 			<view class="arrow-left-warning" v-else @click="feedback">
-				<image :src="imgPath+'/app/image/warning.png'"></image>
+				<image src="/static/warning.png"></image>
 				<text>投诉</text>
 			</view>
 			<view class="header-title" :style="{width:menuButtonLeft + 'px',height:menuButtonH+'px',lineHeight:menuButtonH+'px'}">{{courseInfo.title}}</view>
@@ -257,6 +257,9 @@
 				<button class="send" @click="handleChatInput">发送</button>
 			</view>
 		</view>
+		<ykscreenRecord></ykscreenRecord>
+		<courseExpiration v-if="showExpiration" :code="resCode" :msg="resMsg" :qrcode="qrcode"
+		:userId="user && user.userId ? user.userId : ''"></courseExpiration>
 	</view>
 </template>
 
@@ -279,11 +282,14 @@
 		getIntegralByH5Video,
 		sendReward,
 		loginByMp,
-		getRealLink
-	} from "@/api/courseAuto.js"
-	import {
+		getRealLink,
 		getConfigByKey
-	} from "@/api/user.js"
+	} from "@/api/courseAuto.js"
+	import ykscreenRecord from "@/components/yk-screenRecord/yk-screenRecord.vue"
+	import courseExpiration from './components/courseExpiration.vue'
+	// import {
+	// 	getConfigByKey
+	// } from "@/api/user.js"
 	import {handleFsUserWx} from '@/api/courseLook.js'
 	export default {
 		components: {
@@ -291,9 +297,14 @@
 			descInfo,
 			commentBox,
 			ques,
+			ykscreenRecord,
+			courseExpiration
 		},
 		data() {
 			return {
+				resMsg :'',
+				resCode:"",
+				showExpiration:false,
 				code: '',
 				baseUrl:uni.getStorageSync('requestPath'),
 				// 1 红包 2 积分
@@ -487,7 +498,7 @@
 			}else {
 				this.isOpen = 0
 				console.log(option)
-				this.urlOption = option.course ? JSON.parse(option.course) : {}
+				this.urlOption = option.course ? JSON.parse(decodeURIComponent(option.course)) : {}
 				console.log(this.urlOption)
 			}
 			uni.$on('usercode',(data)=>{
@@ -683,6 +694,14 @@
 				this.isFinish = 1
 				this.showProgress = true
 				this.getFinishCourseVideo()
+				if(this.quesList==null||this.quesList&&this.quesList.length==0) {
+					const param = {
+						...this.urlOption,
+						source: 2,
+						appId: this.appid
+					}
+					this.sendRewardFun(param)
+				}
 			},
 			fullscreenchange(event) {
 				this.isfull = event.detail.fullScreen
@@ -1057,25 +1076,30 @@
 							appId: this.appid
 						}
 					}
-					sendReward(param).then(res => {
-						if(res.isNew&&res.isNew==1) {
-							const packageInfo = res.data.packageInfo || ''
-							if(packageInfo) {
-								uni.setStorageSync('receive_package',packageInfo);
-								if(res.mchId) uni.setStorageSync('mchId',res.mchId);
-								uni.navigateTo({
-									url: '/pages_course/reward'
-								})
-							}
-						} else {
-							uni.showToast({
-								title: res.msg,
-								icon: 'none'
+					this.sendRewardFun(param)
+				}
+			},
+			sendRewardFun(param){
+				sendReward(param).then(res => {
+					uni.hideLoading()
+					if(res.isNew&&res.isNew==1) {
+						const packageInfo = res.data.packageInfo || ''
+						if(packageInfo) {
+							uni.setStorageSync('receive_package',packageInfo);
+							if(res.mchId) uni.setStorageSync('mchId',res.mchId);
+							uni.navigateTo({
+								url: '/pages_course/reward'
 							})
 						}
-					})
-				}
+					} else {
+						uni.showToast({
+							title: res.msg,
+							icon: 'none'
+						})
+					}
+				})
 			},
+			
 			// 线路
 			openPop() {
 				this.$refs.popup.open('bottom')
@@ -1139,9 +1163,11 @@
 							this.qrcode = res.qrcode
 							this.qrcodeMsg = res.msg
 							this.$refs.kfPopup.open()
+							this.initExpiration(res.msg,res.code)
 						} else if (res.code == 504) {
 							// 登录
-							// this.goLogin()
+							this.goLogin()
+							this.initExpiration(res.msg,res.code)
 						} else if (res.code == 566) {
 							// 官方群发通用链接
 							const url = res.courseLink.realLink.split('?course=')[1]
@@ -1162,11 +1188,18 @@
 								title: res.msg,
 								icon: 'none'
 							});
+							this.initExpiration(res.msg,res.code)
 						}
 					},
 					err => {}
 				);
 			},
+			initExpiration(resMsg,resCode) {
+				if(resCode==401) return;
+				this.resMsg = resMsg
+				this.resCode = resCode
+				this.showExpiration = true
+			},
 			closeKFPop() {
 				this.$refs.kfPopup.close()
 			},
@@ -1467,6 +1500,7 @@
 				}
 			},
 			feedback() {
+				console.log(111)
 				const userId = this.user.userId || ''
 				const courseId = this.urlOption.courseId || ''
 				const videoId = this.urlOption.videoId || ''

+ 2 - 2
pages_user/user/pay.vue

@@ -4,7 +4,7 @@
 			<view class="inner">
 				<view class="pay">
 					<view class="title">
-						<text class="name">付款给 德信严选 </text>
+						<text class="name">付款给 康年惠选 </text>
 						<text class="desc">微信收款</text>
 					</view>
 					<view class="pay-money">
@@ -62,7 +62,7 @@
 		},
 		onShareAppMessage(res) {
 			return {
-				title: '德信严选 -收款',
+				title: '康年惠选 -收款',
 				path: `/pages_user/user/pay?companyId=`+this.companyId+"&companyUserId="+this.companyUserId
 			}
 		},

+ 2 - 2
pages_user/user/userTuiAdd.vue

@@ -1,12 +1,12 @@
 <template>
   <view>
 		<view class="form-box">
-			<view class="title">你为什么想成为德信严选 健康推广?</view>
+			<view class="title">你为什么想成为康年惠选 健康推广?</view>
 			<view class="textarea-box">
 				<textarea v-model="question1" value="" placeholder="请输入..." maxlength="200" placeholder-class="textarea-place" />
 				<view class="num-box">{{ question1.length }}/200</view>
 			</view>
-			<view class="title">你是否了解德信严选 健康推广大使?</view>
+			<view class="title">你是否了解康年惠选 健康推广大使?</view>
 			<view class="textarea-box">
 				<textarea v-model="question2" value="" placeholder="请输入..." maxlength="200" placeholder-class="textarea-place" />
 				<view class="num-box">{{ question1.length }}/200</view>