<template>
	<view class="renzheng" style="padding-bottom: 300rpx;" v-if="XCXIsSelect != '否'">
		<view class="text-center text-red bg-white">{{form.remek}}</view>
		<view class=" radius margin">
			<u-form :model="form" ref="uForm" label-position="top" :label-style='lableStyle'>
				<u-form-item label="真实姓名" :border-bottom='false'>
					<u-input placeholder="请输入真实姓名" v-model="form.name" maxlength="11" />
				</u-form-item>
				<view style="width: 100%;height:1rpx;background: #f4f5f6;position: relative;top: -25rpx;"></view>
				<u-form-item label="证件号码" :border-bottom='false'>
					<u-input placeholder="请输入身份证号码" v-model="form.idNumber" />
				</u-form-item>
				<view style="width: 100%;height:1rpx;background: #f4f5f6;position: relative;top: -25rpx;"></view>
				<u-form-item label="地址" :border-bottom='false'>
					<u-input placeholder="请选择当前位置" v-model="form.address" @click="getAddress()" />
				</u-form-item>
				<view style="width: 100%;height:1rpx;background: #f4f5f6;position: relative;top: -25rpx;"></view>
				<u-form-item label="出生日期" :border-bottom='false'>
					<u-input placeholder="请填写（必填）" v-model="form.birthdate" type="select" @click="birthData()" />
				</u-form-item>
				<view style="width: 100%;height:1rpx;background: #f4f5f6;position: relative;top: -25rpx;"></view>
				<u-form-item label="性别" :border-bottom='false'>
					<u-input placeholder="请填写（必填）" v-model="form.sex" type="select" @click="bindSex()" />
				</u-form-item>
				<view style="width: 100%;height:1rpx;background: #f4f5f6;position: relative;top: -25rpx;"></view>
				<u-form-item label="联系方式" :border-bottom='false'>
					<u-input placeholder="请填写（必填）" v-model="form.phone" type="number" maxlength="11" />
				</u-form-item>
				<view style="width: 100%;height:1rpx;background: #f4f5f6;position: relative;top: -25rpx;"></view>
			</u-form>
		</view>
		<view class=" margin">
			<view class="text-lg">自我介绍</view>
			<view class="margin-tb-sm">
				<u-input v-model="form.describes" type="textarea" height="200" placeholde="请描述一下您的特长" maxlengt="200"
					:clearable="false" style="border-radius: 32rpx;" />
			</view>
			<view class="text-lg margin-top-sm">头像上传</view>
			<view class="flex" style="overflow: hidden;flex-wrap: wrap;">
				<view class="margin-top flex margin-right-sm flex-wrap" v-if="form.headImg && form.headImg.length">
					<view class="flex" style="width: 200rpx;height: 200rpx;margin-right: 5rpx;position: relative;">
						<image :src="form.headImg" style="width: 100%;height: 100%;"></image>
						<view style="z-index: 9;position: absolute;top: -15rpx;right: -15rpx;"
							@click="headImgremove(index)">
							<u-icon name="close-circle-fill" color="#2FB57A" size="50rpx"></u-icon>
						</view>
						<!-- <image :src="form.headImg" style="width: 100%;height: 100%;"></image>
						<view style="z-index: 9;position: absolute;top: -15rpx;right: -15rpx;"
							@click="headImgremove(index)">
							<u-icon name="close-circle-fill" color="#2979ff" size="50rpx"></u-icon>
						</view> -->
					</view>
				</view>
				<view class="margin-top" @click="addImage(4)" v-if="form.headImg.length<=0">
					<view style="width: 200rpx;height: 200rpx;background: #f4f5f6;"
						class="flex justify-center align-center">
						<view>
							<view class="text-center">
								<image src="../../static/images/my/add.png" style="width: 65rpx;height: 55rpx;">
								</image>
							</view>
							<view class="text-center">添加图片</view>
						</view>
					</view>
				</view>
			</view>
		<!-- 	<view class="text-lg margin-top-sm">持有资质证书（可多张）</view>
			<view class="flex" style="overflow: hidden;flex-wrap: wrap;">
				<view class="margin-top flex margin-right-sm flex-wrap" v-if="certificateImg.length">
					<view class="flex" style="width: 200rpx;height: 200rpx;margin-right: 2rpx;position: relative;"
						v-for="(image,index) in certificateImg" :key="index">
						<image :src="image" style="width: 100%;height: 100%;"></image>
						<view style="z-index: 9;position: absolute;top: -15rpx;right: -15rpx;"
							@click="removeImg(index)">
							<u-icon name="close-circle-fill" color="#2FB57A" size="50rpx"></u-icon>
						</view>
					</view>
				</view>
				<view class="margin-top" @click="addImages(2)" v-if="certificateImg.length<6">
					<view style="width: 200rpx;height: 200rpx;background: #f4f5f6;"
						class="flex justify-center align-center">
						<view>
							<view class="text-center">
								<image src="../../static/images/my/add.png" style="width: 65rpx;height: 55rpx;">
								</image>
							</view>
							<view class="text-center">添加图片</view>
						</view>
					</view>
				</view>
			</view>

			<view class="text-lg margin-top-sm">形象照（可多张）</view>
			<view class="flex" style="overflow: hidden;flex-wrap: wrap;">
				<view class="margin-top flex margin-right-sm flex-wrap" v-if="infantImg.length">
					<view class="flex" style="width: 200rpx;height: 200rpx;margin-right: 5rpx;position: relative;"
						v-for="(image,index) in  infantImg" :key="index">
						<image :src="image" style="width: 100%;height: 100%;"></image>
						<view style="z-index: 9;position: absolute;top: -15rpx;right: -15rpx;"
							@click="infantImgremove(index)">
							<u-icon name="close-circle-fill" color="#2FB57A" size="50rpx"></u-icon>
						</view>
					</view>
				</view>
				<view class="margin-top" @click="addImages(3)" v-if="infantImg.length<6">
					<view style="width: 200rpx;height: 200rpx;background: #f4f5f6;"
						class="flex justify-center align-center">
						<view>
							<view class="text-center">
								<image src="../../static/images/my/add.png" style="width: 65rpx;height: 55rpx;">
								</image>
							</view>
							<view class="text-center">添加图片</view>
						</view>
					</view>
				</view>
			</view> -->

		</view>
		<view style="text-align: center;">
			<view class="footer">
				<image v-if="showAgree" @tap="isShowAgree"
					src="/static/image/selected.png"
					style="width: 30upx;height: 30upx;"></image>
				<image v-else @tap="isShowAgree"
					src="/static/image/noselect.png"
					style="width: 30upx;height: 30upx;"></image>
				<text style="margin-left: 10upx;margin-right: 0;" @tap="isShowAgree">我阅读并同意</text>
				<!-- 协议地址 -->
				<navigator url="/my/setting/xieyi?id=374" open-type="navigate">《技师入驻协议》</navigator>
			</view>
		</view>
		<view class="btn-box" v-if="renzheng == 0||renzheng==3">
			<view class="tabbar" @click="submit()">提交发布</view>
		</view>

		<!-- 性别选择 -->
		<u-action-sheet :list="actionSheetList" v-model="show" @click="actionSheetCallback"></u-action-sheet>
		<!-- 出生日期 -->
		<u-picker v-model="showData" :params="params" @confirm="bindData"></u-picker>
		<!-- 支付方式 -->
		<u-popup v-model="showpay" mode="bottom" :closeable="closeable">
			<view class="popup_pay">
				<view style="background-color: #fff;">
					<view style="padding: 0 20upx;margin-top: 60rpx;margin-bottom: 20rpx;">
						<view
							style="display: flex;height: 100upx;align-items: center;padding: 20upx 0;justify-content: center;"
							v-for="(item,index) in openLists" :key='index'>
							<image :src="item.image" style="width: 55upx;height: 55upx;border-radius: 50upx;">
							</image>
							<view style="font-size: 30upx;margin-left: 20upx;width: 70%;">
								{{item.text}}
							</view>
							<radio-group name="openWay" style="margin-left: 45upx;" @tap='selectWay(item)'>
								<label class="tui-radio">
									<radio color="#2FB57A" :checked="openWay === item.id ? true : false" />
								</label>
							</radio-group>
						</view>
					</view>
				</view>
				<view class="pay_btn" @click="pay()">确认支付</view>
			</view>
		</u-popup>
	</view>
</template>

<script>
	import configdata from '../../common/config.js';

	export default {
		data() {
			return {
				showAgree: false,
				form: {
					name: '',
					idNumber: '',
					remek: '',
					address: '',
					sex: '',
					birthdate: '',
					phone: '',
					front: '',
					back: '',
					//母婴护理师证
					infant: [],
					//头像上传
					headImg: '',
					//资质证书
					certificateImg: [],
					longitude: '',
					latitude: ''

				},
				// disabled: false,
				lableStyle: {
					color: '#222',
					fontSize: '32rpx',
					fontWeight: 'bold'
				},
				customStyle: {
					backgroundColor: '#005DFF',
					color: '#ffffff',
					border: 0
				},
				customStyle1: {
					backgroundColor: '#ccc',
					color: '#000000',
					border: 0
				},
				renzheng: '',

				show: false,
				actionSheetList: [{
					text: '男',
					label: '1',
				}, {
					text: '女',
					label: '2',
				}],
				showData: false,
				params: {
					year: true,
					month: true,
					day: true,
					hour: false,
					minute: false,
					second: false
				},
				//母婴护理师证
				infantImg: [],
				//头像上传
				headImg: [],
				//资质证书
				certificateImg: [],
				money: 0,
				showpay: false,
				openLists: [],
				openWay: 1,
				typeId: '',
				sex: 0,
				closeable: true,
				XCXIsSelect: '否'
			}
		},
		onLoad(e) {
			this.XCXIsSelect = this.$queue.getData("XCXIsSelect");
			if (this.XCXIsSelect != '否') {
				uni.setNavigationBarTitle({
					title: '实名认证'
				})
			} else {
				uni.setNavigationBarTitle({
					title: '关于我们'
				})
			}
			if (e.id) {
				this.typeId = e.id;
			}
			this.getUserInfo()

			this.renzheng = uni.getStorageSync("renzheng")
			// #ifdef APP
			this.openLists = [{
					image: '../../static/images/icon_weixin.png',
					text: '微信',
					id: 1
				}, {
					image: '../../static/images/zhifubao.png',
					text: '支付宝',
					id: 2
				}],
				this.openWay = 1;
			// #endif

			// #ifdef MP-WEIXIN
			this.openLists = [{
					image: '../../static/images/icon_weixin.png',
					text: '微信',
					id: 1
				}],
				this.openWay = 1;
			// #endif

			// #ifdef H5
			this.openLists = [{
				image: '../../static/images/zhifubao.png',
				text: '支付宝',
				id: 2
			}]
			this.openWay = 2;
			// #endif
		},
		onShow() {
			// this.Getmoney()

		},
		methods: {
			isShowAgree() {
				//是否选择协议
				this.showAgree = !this.showAgree;
			},
			getAddress() {
				let that = this
				uni.chooseLocation({
					success: function(res) {
						console.log('位置名称：' + res.name);
						console.log('详细地址：' + res.address);
						console.log('纬度：' + res.latitude);
						console.log('经度：' + res.longitude);
						that.form.address = res.address
						that.form.latitude = res.latitude
						that.form.longitude = res.longitude
					}
				});
			},
			//日期弹框
			birthData() {
				this.showData = true
			},
			//性别选择
			bindSex() {
				this.show = true
			},
			//支付方式
			selectWay(item) {
				this.openWay = item.id;
			},
			// 保证金
			Getmoney() {
				this.$Request.get("/app/common/type/239").then(res => {
					console.log(res)
					if (res.code == 0) {
						this.money = res.data.value
					}
				});
			},
			// 点击actionSheet回调 性别
			actionSheetCallback(index) {
				console.log(index)
				this.sex = this.actionSheetList[index].label;
				this.form.sex = this.actionSheetList[index].text;
				// this.from.sexs =  this.actionSheetList[index].label;
				console.log(this.sex)
			},
			//出生日期
			bindData(e) {
				console.log(e)
				this.form.birthdate = e.year + '年' + e.month + '月' + e.day + '日'
				this.form.birth = e.year + '-' + e.month + '-' + e.day

			},
			//身份证删除
			frontRemove(index) {
				if (index == 1) {
					this.form.front = ''
				} else if (index == 2) {
					this.forms.front = ''
				}
			},
			//资质证书删除
			removeImg(index) {
				this.certificateImg.splice(index, 1)
			},
			backRemove() {
				this.form.back = ''
			},
			infantImgremove(index) {
				this.infantImg.splice(index, 1)
			},
			headImgremove(index) {
				this.form.headImg = ''
			},
			submit() {
				this.form.infantImg = this.infantImg
				this.form.infantImg = this.form.infantImg.toString();

				this.form.certificateImg = this.certificateImg
				this.form.certificateImg = this.form.certificateImg.toString();

				// this.form.headImg = this.headImg
				// this.form.headImg = this.form.headImg.toString();
				if(!this.showAgree){
					uni.showToast({
						title: '请阅读并同意《技师入驻协议》',
						icon: 'none',
						duration: 1000
					})
					return;
				}
				
				if (!this.form.name) {
					uni.showToast({
						title: '请输入真实姓名',
						icon: 'none',
						duration: 1000
					})
					return;
				}

				if (!this.form.idNumber) {
					uni.showToast({
						title: '请输入身份证号',
						icon: 'none',
						duration: 1000
					})
					return;
				}
				let regX =
					/^[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]$/;
				if (!regX.test(this.form.idNumber)) {
					uni.showToast({
						title: '请输入正确的身份证号',
						icon: 'none',
						duration: 1000
					})
					return;
				}
				if (!this.form.address) {
					uni.showToast({
						title: '请选择地址',
						icon: 'none',
						duration: 1000
					})
					return;
				}
				if (!this.form.birthdate) {
					uni.showToast({
						title: '请输入出生日期',
						icon: 'none',
						duration: 1000
					})
					return;
				}
				if (!this.form.sex) {
					uni.showToast({
						title: '请输入性别',
						icon: 'none',
						duration: 1000
					})
					return;
				}
				if (!this.form.phone) {
					uni.showToast({
						title: '请输入联系方式',
						icon: 'none',
						duration: 1000
					})
					return;
				}
				if (!this.form.describes) {
					uni.showToast({
						title: '请填写自我介绍',
						icon: 'none',
						duration: 1000
					})
					return
				}
				// if (!this.form.front) {
				// 	uni.showToast({
				// 		title: '请上传身份证正面',
				// 		icon: 'none',
				// 		duration: 1000
				// 	})
				// 	return;
				// }
				// if (!this.form.back) {
				// 	uni.showToast({
				// 		title: '请上传身份证反面',
				// 		icon: 'none',
				// 		duration: 1000
				// 	})
				// 	return;
				// }
				if (!this.form.headImg) {
					uni.showToast({
						title: '请上传头像',
						icon: 'none',
						duration: 1000
					})
					return;
				}
				// if (!this.form.certificateImg) {
				// 	uni.showToast({
				// 		title: '请上传资质证书',
				// 		icon: 'none',
				// 		duration: 1000
				// 	})
				// 	return;
				// }
				// if (!this.form.infantImg) {
				// 	uni.showToast({
				// 		title: '请上传生活照',
				// 		icon: 'none',
				// 		duration: 1000
				// 	})
				// 	return;
				// }
				let data = {
					userId: uni.getStorageSync("userId"),
					name: this.form.name,
					idNumber: this.form.idNumber,
					birthdate: this.form.birthdate,
					classifyId: this.typeId,
					sex: this.sex,
					phone: this.form.phone,
					address: this.form.address,
					front: this.form.front,
					back: this.form.back,
					remek: this.form.remek,
					certification: this.form.certificateImg,
					imagePhoto: this.form.infantImg,
					avatar: this.form.headImg,
					individualResume: this.form.describes,
					latitude: this.form.latitude,
					longitude: this.form.longitude
				}
				this.$Request.postJson("/app/realname/auditRealName", data).then(res => {
					if (res.code == 0) {
						uni.showToast({
							title: '认证提交成功！',
							icon: 'none'
						})
						setTimeout(function() {
							uni.switchTab({
								url: '/pages/my/index'
							})
						}, 1000)
					} else {
						uni.showToast({
							title: res.msg,
							icon: 'none'
						})
					}
				});


			},

			getUserInfo() {
				let data = {
					userId: uni.getStorageSync('userId')
				}
				this.$Request.get("/app/realname/selectRealName", data).then(res => {
					console.log(res)
					if (res.code == 0 && res.data) {
						this.typeId = res.data.classifyId ? res.data.classifyId : ''
						this.form.name = res.data.name ? res.data.name : ''
						this.form.idNumber = res.data.idNumber ? res.data.idNumber : ''
						this.form.front = res.data.front ? res.data.front : ''
						this.form.back = res.data.back ? res.data.back : ''
						this.classify = res.data.classify
						this.form.address = res.data.address
						this.form.describes = res.data.individualResume
						this.form.birthdate = res.data.birthdate
						this.sex = res.data.sex
						if (res.data.sex == 1) {
							this.form.sex = '男'
						} else if (res.data.sex == 2) {
							this.form.sex = '女'
						}
						this.form.phone = res.data.phone
						if (res.data.imagePhoto) {
							this.infantImg = res.data.imagePhoto.split(',')
							this.form.infantImg = res.data.imagePhoto
						}
						if (res.data.certification) {
							this.certificateImg = res.data.certification.split(',')
							this.form.certificateImg = res.data.certification
						}

						this.headImg = res.data.avatar
						this.form.headImg = res.data.avatar;

						if (res.data.status == 1) {
							this.disabled = true
						}
						if (res.data.status == 2) {
							this.form.remek = res.data.remek ? res.data.remek : ''
						}
					}
				});
			},

			addImages(e) {
				let that = this
				let urlName = this.config("APIHOST1") + '/alioss/upload';
				if (e == 2) {
					urlName = this.config("APIHOST1") + '/alioss/uploadWatermark';
				}
				uni.chooseImage({
					count: 6,
					sourceType: ['album', 'camera'],
					success: res => {
						for (let i = 0; i < res.tempFilePaths.length; i++) {
							that.$queue.showLoading("上传中...");
							uni.uploadFile({ // 上传接口
								// url: that.config("APIHOST1") + '/alioss/upload', //真实的接口地址
								url: urlName,
								filePath: res.tempFilePaths[i],
								name: 'file',
								success: (uploadFileRes) => {
									if (e == 3) {
										if (that.infantImg.length <= 5) {
											that.infantImg.push(JSON.parse(uploadFileRes.data)
												.data)
										}
									} else if (e == 2) {
										if (that.certificateImg.length <= 5) {
											that.certificateImg.push(JSON.parse(uploadFileRes.data)
												.data)
										}
									}

									uni.hideLoading();
								}
							});
						}
					}
				})
			},
			addImage(e) {
				let that = this
				uni.chooseImage({
					count: 1,
					sourceType: ['album', 'camera'],
					success: res => {
						for (let i = 0; i < res.tempFilePaths.length; i++) {
							that.$queue.showLoading("上传中...");
							uni.uploadFile({ // 上传接口
								url: that.config("APIHOST1") + '/alioss/upload', //真实的接口地址
								filePath: res.tempFilePaths[i],
								name: 'file',
								success: (uploadFileRes) => {
									if (e == 1) {
										that.form.front = JSON.parse(uploadFileRes.data).data
									} else if (e == 2) {
										that.form.back = JSON.parse(uploadFileRes.data).data
									} else if (e == 4) {
										that.form.headImg = JSON.parse(uploadFileRes.data).data
										console.log(that.form.headImg)
									}
									uni.hideLoading();

								}
							});
						}
					}
				})
			},
			config: function(name) {
				var info = null;
				if (name) {
					var name2 = name.split("."); //字符分割
					if (name2.length > 1) {
						info = configdata[name2[0]][name2[1]] || null;
					} else {
						info = configdata[name] || null;
					}
					if (info == null) {
						let web_config = cache.get("web_config");
						if (web_config) {
							if (name2.length > 1) {
								info = web_config[name2[0]][name2[1]] || null;
							} else {
								info = web_config[name] || null;
							}
						}
					}
				}
				return info;
			},

			pay() {
				let userId = uni.getStorageSync('userId')
				data = {
					name: this.form.name,
					idNumber: this.form.idNumber,
					birthdate: this.form.birth,
					sex: this.sex,
					phone: this.form.phone,
					front: this.form.front,
					back: this.form.back,
					remek: this.form.remek,
					infantImg: this.form.infantImg,
					infantImgs: this.form.infantImgs,
					classify: this.classify,
					userId: userId
				}

				console.log(data, 'pppp1')
				this.showpay = false
				if (this.openWay == 1) { //微信支付
					// #ifdef MP-WEIXIN
					this.$Request.postJson('/app/wxPay/wxPayJsApiUserCertification', data).then(res => {
						console.log(res)

						if (res.code == 0) {
							// this.isCheckPay(res.code, 'wxpay', JSON.stringify(res.data));

							uni.requestPayment({
								provider: 'wxpay',
								timeStamp: res.data.timestamp,
								nonceStr: res.data.noncestr,
								package: res.data.package,
								signType: res.data.signType,
								paySign: res.data.sign,
								success: function(res) {
									console.log(res)
									// uni.showLoading({
									// 	title: '支付成功',
									// 	icon:'nones'
									// });
									// this.$queue.showToast('支付成功');

									uni.switchTab({
										url: '/pages/my/index'
									})
								},
								fail: function(err) {

									this.$queue.showToast('支付失败');
								}
							});
						}
					});
					// #endif


					// #ifdef H5
					this.$Request.postJson('/app/wxPay/wxPayMpUserCertification', data).then(res => {
						this.showpay = false
						that.callPay(res);
					});
					// #endif

					// #ifdef APP
					this.$Request.postJson('/app/wxPay/payAppUserCertification', data).then(res => {
						console.log(res)
						this.showpay = false
						if (res.code == 0) {

							this.isCheckPay(res.code, 'wxpay', JSON.stringify(res.data));
						}
					});
					// #endif


				} else if (this.openWay == 2) { //支付宝支付
					// #ifdef H5
					this.$Request.postJson('/app/aliPay/payOrderUserCertification', data).then(
						res => {
							this.showpay = false
							const div = document.createElement('div')
							div.innerHTML = res.data //此处form就是后台返回接收到的数据
							document.body.appendChild(div)
							document.forms[0].submit()
						});
					// #endif

					// #ifdef APP-PLUS
					this.$Request.postJson('/app/aliPay/payAppUserCertification', data).then(

						res => {
							this.showpay = false
							this.setPayment('alipay', res.data);
						});
					// #endif

				}
			},
			callPay: function(response) {
				if (typeof WeixinJSBridge === "undefined") {
					if (document.addEventListener) {
						document.addEventListener('WeixinJSBridgeReady', this.onBridgeReady(response), false);
					} else if (document.attachEvent) {
						document.attachEvent('WeixinJSBridgeReady', this.onBridgeReady(response));
						document.attachEvent('onWeixinJSBridgeReady', this.onBridgeReady(response));
					}
				} else {
					this.onBridgeReady(response);
				}
			},
			onBridgeReady: function(response) {
				let that = this;
				if (!response.package) {
					return;
				}
				WeixinJSBridge.invoke(
					'getBrandWCPayRequest', {
						"appId": response.appid, //公众号名称，由商户传入
						"timeStamp": response.timestamp, //时间戳，自1970年以来的秒数
						"nonceStr": response.noncestr, //随机串
						"package": response.package,
						"signType": response.signType, //微信签名方式：
						"paySign": response.sign //微信签名
					},
					function(res) {
						if (res.err_msg === "get_brand_wcpay_request:ok") {
							// 使用以上方式判断前端返回,微信团队郑重提示：
							//res.err_msg将在用户支付成功后返回ok，但并不保证它绝对可靠。
							uni.showLoading({
								title: '支付成功'
							});
							uni.hideLoading();

							uni.navigateTo({
								url: '/pages/my/index'
							})
						} else {
							uni.hideLoading();
						}
						WeixinJSBridge.log(response.err_msg);
					}
				);
			},
			isCheckPay(code, name, order) {
				if (code == 0) {
					console.log('999999999999')
					this.setPayment(name, order);
				} else {
					uni.hideLoading();
					uni.showToast({
						title: '支付信息有误'
					});
				}
			},
			setPayment(name, order) {
				console.log(777777777, name, order)
				uni.requestPayment({
					provider: name,
					orderInfo: order, //微信、支付宝订单数据
					success: function(res) {
						uni.hideLoading();
						uni.showLoading({
							title: '支付成功'
						});
						uni.switchTab({
							url: '/pages/my/index'
						})
					},
					fail: function(err) {
						uni.hideLoading();
					},
					complete() {
						uni.hideLoading();
					}
				});
			}
		}
	}
</script>

<style lang="scss">
	.renzheng {
		background: #FFFFFF;
	}

	.bg {
		background-color: #FFFFFF;
	}

	.footer {
		padding-left: 30upx;
		font-size: 24upx;
		color: #666666;
		text-align: center;
		display: flex;
		margin-bottom: 20rpx;
	}

	.u-input__input {
		color: balck !important;
	}

	.title_btn {
		height: 78upx;
		line-height: 78upx;
		/* background: #f7f7f7; */
	}
	
	.btn-box{
		width: 750rpx;
		height: 166rpx;
		background: #FFFFFF;
		box-shadow: 0rpx -6rpx 12rpx 2rpx rgba(0,0,0,0.09);
		border-radius: 32rpx 32rpx 0rpx 0rpx;
		position: fixed;
		bottom: 0%;
		left: 0%;
		box-sizing: border-box;
		padding: 20rpx 32rpx;
		.tabbar {
			width: 686rpx;
			height: 100rpx;
			line-height: 100rpx;
			text-align: center;
			background: #1EDA94;
			border-radius: 60rpx 60rpx 60rpx 60rpx;
			font-weight: bold;
			font-size: 32rpx;
			color: #FFFFFF;
		}
	}


	.popup_pay {

		width: 100%;
		position: relative;
		padding-bottom: 45rpx;
		/* height: 160px; */
		/* #ifndef MP-WEIXIN */
		/* height: 130px; */
		/* #endif */

	}

	.pay_btn {
		width: 90%;
		margin: 0 auto;
		text-align: center;
		background: #1777FF;
		height: 80rpx;
		border-radius: 16rpx;
		color: #ffffff;
		line-height: 80rpx;

	}

	.hb {
		/* #ifdef H5 */
		padding-bottom: 180rpx;
		/* #endif */
	}

	.bgCol2 {
		color: #557EFD;
	}
</style>
