yanjie 4 anni fa
parent
commit
b6408c9ab2

+ 2 - 1
common/env.js

xqd
@@ -2,4 +2,5 @@
 export const envHost = 'https://wechat.fresherbaby.com'
 // export const imgHost='https://www.juyinzhengxin.com/';
 // export const imgHost = 'https://t5.9026.com/upload/';
-export const imgHost = 'https://wechat.fresherbaby.com/upload/'
+export const imgHost = 'https://wechat.fresherbaby.com/upload/'
+export const imgHost2 = 'https://wechat.fresherbaby.com/'

+ 17 - 1
common/util.js

xqd xqd
@@ -1,3 +1,18 @@
+import request from '@/common/request'
+
+function getAgreement() {
+	return new Promise(function(resolve, reject) {
+		request.post("/api/v1/common/configList").then(res => {
+			if (res.status == 0) {
+				resolve(res)
+			}
+		}).catch(err => {
+			reject(err)
+		})
+	})
+
+}
+
 function ViewImage(imgList, e) {
 	uni.previewImage({
 		urls: imgList,
@@ -223,5 +238,6 @@ module.exports = {
 	ViewImage: ViewImage,
 	isEmail: isEmail,
 	isNum: isNum,
-	formatDate: formatDate
+	formatDate: formatDate,
+	getAgreement: getAgreement
 }

+ 3 - 1
main.js

xqd xqd
@@ -4,7 +4,8 @@ import store from '@/store/index'
 import request from '@/common/request'
 import util from '@/common/util.js';
 import {
-	imgHost
+	imgHost,
+	imgHost2
 } from '@/common/env';
 import uView from "uview-ui";
 Vue.use(uView);
@@ -15,6 +16,7 @@ Vue.config.productionTip = false;
 Vue.prototype.$request = request
 Vue.prototype.$util = util
 Vue.prototype.$imgHost = imgHost
+Vue.prototype.$imgHost2 = imgHost2
 // 引入colorUI
 Vue.config.productionTip = false
 

+ 6 - 0
pages.json

xqd
@@ -28,6 +28,12 @@
 				"navigationBarTitleText": "我的"
 			}
 		},
+		{
+			"path": "pages/index/agreement",
+			"style": {
+				"navigationBarTitleText": ""
+			}
+		},
 		// {
 		// 	"path": "pages/doctor_related/select_doctor",
 		// 	"style": {

+ 10 - 2
pages/childcare/child_care.vue

xqd xqd xqd xqd
@@ -48,6 +48,9 @@
 					<text class="text-grey text-sm">{{yuyuevalue}}</text>
 				</view>
 			</view>
+			<view class="text-gray text-sm" style="margin: 25rpx 37rpx;line-height: 38rpx;">
+				{{nurse_notice}}
+			</view>
 		</view>
 		<!-- <u-picker mode="multiSelector" @confirm="callbacktime" v-model="show" range-key="start_time_period" :range="multiSelector"></u-picker> -->
 		<u-popup v-model="showpeople" mode="bottom" border-radius="14" length="50%">
@@ -112,7 +115,11 @@
 			datepicker
 		},
 		onLoad() {
+			this.$util.getAgreement().then(res => {
+				this.nurse_notice = res.data.nurse_notice
+			}).catch(err => {
 
+			})
 		},
 		onShow() {
 			let price = 0
@@ -151,7 +158,8 @@
 				time: "",
 				childcare: [],
 				dateshow: false,
-				is_Scheduling: true
+				is_Scheduling: true,
+				nurse_notice: ""
 			}
 		},
 		methods: {
@@ -190,7 +198,7 @@
 						this.is_Scheduling = false
 						return false
 					}
-					let nian = res.data.data.map((item,index) => {
+					let nian = res.data.data.map((item, index) => {
 						if (item.schedule_period.length != 0) {
 							return {
 								date: item.schedule_date,

+ 19 - 0
pages/doctor_related/info_write.vue

xqd xqd xqd
@@ -112,6 +112,15 @@
 					</view>
 				</view>
 			</view>
+			<view class="text-gray text-sm" style="margin: 25rpx 37rpx;line-height: 38rpx;" v-if="type == 1">
+				{{phone_notice}}
+			</view>
+			<view class="text-gray text-sm" style="margin: 25rpx 37rpx;line-height: 38rpx;" v-else-if="type == 2">
+				{{chat_notice}}
+			</view>
+			<view class="text-gray text-sm" style="margin: 25rpx 37rpx;line-height: 38rpx;" v-else>
+				{{clinic_notice}}
+			</view>
 		<view class="cu-bar bg-white tabbar" style="position: fixed;bottom: 0;width: 100%;">
 			<view class="submit" style="background-color: #0B73B9;color: white;" @click="gotopay">
 				立即咨询
@@ -205,6 +214,13 @@
 			}else{
 				this.price = this.doctor.appoint_price
 			}
+			this.$util.getAgreement().then(res => {
+				this.phone_notice = res.data.phone_notice
+				this.chat_notice = res.data.chat_notice
+				this.clinic_notice = res.data.clinic_notice
+			}).catch(err => {
+			
+			})
 		},
 		onShow() {
 			this.getarchives()
@@ -249,6 +265,9 @@
 				yearid:"",
 				upimg:[],
 				isdescribe:false,
+				phone_notice:"",
+				chat_notice:"",
+				clinic_notice:""
 			}
 		},
 		methods: {

+ 24 - 0
pages/index/agreement.vue

xqd
@@ -0,0 +1,24 @@
+<template>
+	<view class="main">
+		<rich-text :nodes="nodeEl"></rich-text>
+	</view>
+</template>
+
+<script>
+	export default {
+		data() {
+			return {
+				nodeEl: ""
+			}
+		},
+		onLoad(op) {
+			this.nodeEl = op.data
+		}
+	}
+</script>
+
+<style scoped>
+	.main {
+		min-height: 100vh;
+	}
+</style>

+ 14 - 2
pages/login/login.vue

xqd xqd xqd
@@ -53,7 +53,7 @@
 			<view class="footer">
 				<view class="flex align-center" @click="isqueren">
 					<image :src="imgitem.name" mode="" style="width: 30rpx;height: 30rpx;"></image>
-					<text style="color: #0B73B9;">《熙宝HMO》</text>
+					<text style="color: #0B73B9;" @click.stop="gotoxieyi">《熙宝HMO》</text>
 					<text style="color: #999999;">服务协议</text>
 				</view>
 			</view>
@@ -96,7 +96,8 @@
 					name: "https://zhengda.oss-cn-chengdu.aliyuncs.com/baoma/static/img/xieyi.png"
 				},
 				show: false,
-				isphoneNum: false
+				isphoneNum: false,
+				nodeEl: ""
 			}
 		},
 		// onShow() {
@@ -121,8 +122,19 @@
 		},
 		onLoad() {
 			this.isphone()
+			this.$util.getAgreement().then(res => {
+				this.nodeEl = res.data.login_protocol
+			}).catch(err => {
+
+			})
+
 		},
 		methods: {
+			gotoxieyi() {
+				uni.navigateTo({
+					url: "../index/agreement?data=" + this.nodeEl
+				})
+			},
 			isShowAgree() {
 				//是否选择协议
 				_this.showAgree = !_this.showAgree;

+ 15 - 2
pages/personal/recharge.vue

xqd xqd xqd xqd
@@ -34,12 +34,12 @@
 				温馨提示
 			</view>
 			<view class="text-sm" style="color: #999999;font-weight: 400;margin-top: 15rpx;">
-				温馨提示信息后台编辑温馨提示信息后台编辑温馨提示信息后台编辑温馨提示信息后台编辑温馨提示信息后台编辑温馨提示信息后台编辑温馨提示信息后。
+				{{recharge_notice}}
 			</view>
 		</view>
 		<view class="margin-lr" style="margin-top: 210rpx;">
 			<view class="text-sm margin-bottom" style="color: #999999;text-align: center;">
-				点击充值按钮即表示已阅读并同意 <text style="color: #0B73B9;">《充值规则》</text>
+				点击充值按钮即表示已阅读并同意 <text style="color: #0B73B9;" @click.stop="gotoxieyi">《充值规则》</text>
 			</view>
 			<u-button size="default" :ripple="true" @click="recharge" :custom-style="customStyle">充值</u-button>
 		</view>
@@ -52,6 +52,12 @@
 		onLoad() {
 			this.paymentMoney = this.moneyList[0].price
 			this.accountMoney = this.moneyList[0].price
+			this.$util.getAgreement().then(res => {
+				this.recharge_protocol = res.data.recharge_protocol
+				this.recharge_notice = res.data.recharge_notice
+			}).catch(err => {
+
+			})
 		},
 		data() {
 			return {
@@ -84,6 +90,8 @@
 					backgroundColor: '#0B73B9',
 					color: '#FFFFFF'
 				},
+				recharge_protocol: "",
+				recharge_notice: ""
 			};
 		},
 		watch: {
@@ -96,6 +104,11 @@
 			}
 		},
 		methods: {
+			gotoxieyi() {
+				uni.navigateTo({
+					url: "../index/agreement?data=" + this.recharge_protocol
+				})
+			},
 			replaceMoney(item) {
 				this.paymentMoney = item.price
 				this.accountMoney = item.price

+ 21 - 8
pages/service_packs/introduce.vue

xqd xqd xqd xqd
@@ -1,7 +1,7 @@
 <template>
 	<view class="container">
 		<view class="body">
-			<image src="https://zhengda.oss-cn-chengdu.aliyuncs.com/baoma/static/竖占位图.png" class="img"></image>
+			<image :src="imghos+nodeEl" class="img"></image>
 		</view>
 		<view class="footer">
 			<view class="cu-bar bg-white tabbar border shop" style="width: 100%;">
@@ -13,7 +13,7 @@
 				<view class="submit" @click="next" style="background-color: #0B73B9; color: #FFFFFF;">选购服务包</view>
 			</view>
 		</view>
-		<u-popup v-model="show" mode="bottom" border-radius="14"  height="300rpx">
+		<u-popup v-model="show" mode="bottom" border-radius="14" height="300rpx">
 			<u-button open-type="contact" :custom-style="customStyle">在线咨询</u-button>
 			<u-button @click="playphone" :custom-style="customStyle">电话咨询</u-button>
 		</u-popup>
@@ -37,13 +37,26 @@
 		data() {
 			return {
 				show: false,
-				customStyle:{
-					width:'600rpx',
-					marginTop:"35rpx"
-				}
+				customStyle: {
+					width: '600rpx',
+					marginTop: "35rpx"
+				},
+				nodeEl: "",
+				imghos: "",
+				phone: ""
 			}
 		},
+		onLoad() {
+			this.imghos = this.$imgHost2
+			this.$util.getAgreement().then(res => {
+				this.nodeEl = res.data.poster
+				this.phone = res.data.phone
+			}).catch(err => {
+
+			})
+		},
 		methods: {
+
 			next(e) {
 				if (this.hasLogin) {
 					uni.navigateTo({
@@ -63,9 +76,9 @@
 					})
 				}
 			},
-			playphone(){
+			playphone() {
 				uni.makePhoneCall({
-					phoneNumber:"123456"
+					phoneNumber: this.phone
 				})
 				this.show = false
 			}

+ 21 - 6
pages/service_packs/packs_details.vue

xqd xqd xqd xqd xqd
@@ -5,7 +5,7 @@
 			<view class="card_view">
 				<!-- 放图片 标题 -->
 				<view class="title">
-					<image src="https://zhengda.oss-cn-chengdu.aliyuncs.com/baoma/static/横占位图.png" class="img"></image>
+					<image :src="imghos+packs.image" class="img"></image>
 				</view>
 				<!-- 放描述 -->
 				<view class="describe">
@@ -58,7 +58,7 @@
 			<view @click="isqueren" style="height: 35rpx;width: auto;font-size: 24rpx;margin-left: 30rpx;display: flex;align-items: center;">
 				<image :src="imgitem.name" mode="" style="width: 30rpx;height: 30rpx;margin-right: 10rpx;"></image>
 				<text style="color: #999999;">已阅读并同意</text>
-				<text style="color: #0B73B9;">《熙宝HMO》</text>
+				<text style="color: #0B73B9;" @click.stop="gotoxieyi">《熙宝HMO》</text>
 				<text style="color: #999999;">服务协议</text>
 			</view>
 		</view>
@@ -77,8 +77,8 @@
 			</view>
 		</view>
 		<u-popup v-model="show" mode="bottom" border-radius="14" height="300rpx">
-			<u-button open-type="contact" :custom-style="customStyle">会话客服</u-button>
-			<u-button @click="playphone" :custom-style="customStyle">电话客服</u-button>
+			<u-button open-type="contact" :custom-style="customStyle">在线咨询</u-button>
+			<u-button @click="playphone" :custom-style="customStyle">电话咨询</u-button>
 		</u-popup>
 	</view>
 </template>
@@ -88,6 +88,13 @@
 		name: 'productdetailspage',
 		onLoad(op) {
 			this.serviceid = op.id
+			this.$util.getAgreement().then(res => {
+				this.service_protocol = res.data.service_protocol
+				this.phone = res.data.phone
+			}).catch(err => {
+			
+			})
+			this.imghos = this.$imgHost
 		},
 		mounted() {
 			this.getservice()
@@ -108,13 +115,21 @@
 				customStyle: {
 					width: '600rpx',
 					marginTop: "35rpx"
-				}
+				},
+				service_protocol:"",
+				phone:"",
+				imghos:""
 			}
 		},
 		methods: {
+			gotoxieyi(){
+				uni.navigateTo({
+					url: "../index/agreement?data=" + this.service_protocol
+				})
+			},
 			playphone() {
 				uni.makePhoneCall({
-					phoneNumber: "123456"
+					phoneNumber: this.phone
 				})
 				this.show = false
 			},

+ 6 - 1
pages/service_packs/packs_information.vue

xqd xqd
@@ -137,7 +137,7 @@
 			<view class="flex align-center padding bg-white" v-if="packs.is_need_insure==1">
 				<u-switch v-model="checked" size="40"></u-switch>
 				<view class="margin-left-sm">
-					本服务包赠送一份保险服务,是否领取保险。如领取保险需要同意<text class="text-blue">《保单协议》</text>
+					本服务包赠送一份保险服务,是否领取保险。如领取保险需要同意<text class="text-blue" @click.stop="gotoxieyi">《保单协议》</text>
 				</view>
 			</view>
 		</view>
@@ -247,6 +247,11 @@
 			}
 		},
 		methods: {
+			gotoxieyi(){
+				uni.navigateTo({
+					url:"../index/agreement?data="
+				})
+			},
 			getarchives: async function() {
 				let res = await this.$request.post("/api/v1/patient/patientList")
 				if (res.status == 0) {

+ 10 - 2
pages/vaccines/vaccines_info.vue

xqd xqd xqd
@@ -47,6 +47,9 @@
 					<text class="text-grey text-sm">{{yuyuevalue}}</text>
 				</view>
 			</view>
+			<view class="text-gray text-sm" style="margin: 25rpx 37rpx;line-height: 38rpx;">
+				{{vaccine_notice}}
+			</view>
 		</view>
 		<!-- <u-picker mode="multiSelector" @confirm="callbacktime" v-model="show" :default-selector='[0, 1]' range-key="start_time_period"
 		 :range="multiSelector"></u-picker> -->
@@ -97,7 +100,11 @@
 	var user = require('../../common/user.js');
 	export default {
 		onLoad() {
-
+			this.$util.getAgreement().then(res => {
+				this.vaccine_notice = res.data.vaccine_notice
+			}).catch(err => {
+			
+			})
 		},
 		components: {
 			datepicker
@@ -131,7 +138,8 @@
 				yimiaoInfo: "",
 				time: "",
 				dateshow: false,
-				is_Scheduling: true
+				is_Scheduling: true,
+				vaccine_notice:""
 			}
 		},
 		methods: {