<!--pages/login/login.wxml-->
<view class="topNavBox" style="height:{{statusBarHeight + (408 - statusBarHeight)}}rpx;width:100%;"></view>
<view class="contenBox">
	<view class="userImg">
		<open-data type="userAvatarUrl"></open-data>
	</view>
	<view class="userName">
		<!-- <open-data type="userNickName"></open-data> -->
	</view>
	<view class="button_1" catchtap="getUserProfileTap" wx:if="{{canIUseGetUserProfile}}">
		授权登录
		<button catchtap="getUserProfileTap"></button>
	</view>
	<view class="button_1" wx:else>
		授权登录
		<button open-type="getUserInfo" bindgetuserinfo="getUserProfileTap" class="button"></button>
	</view>
	<view class="button_2" catchtap="gomember">
		暂不登录
		<button catchtap="gomember"></button>
	</view>
</view>
<view style="margin:37rpx 0 26rpx 29rpx;font-size: 30rpx;color: #202020;">申请获取以下权限</view>
<view style="margin:0 0 0 29rpx;font-size: 28rpx;color: #666666;">获得你的公开信息（昵称、头像等）</view>
<view class="agreementBox" wx:if="{{PlatformAgreement}}">
	<van-checkbox value="{{ tapSelectAgreement }}" bind:change="PlatformAgreementOnChange" icon-size="13px"
		checked-color="#07c160"></van-checkbox>
	我已阅读、理解并接受《<text catchtap="PlatformAgreementTap">{{agreement_name}}</text>》
</view>

<!-- 平台协议 -->
<van-popup show="{{openPlatformAgreement}}" bind:close="PlatformAgreementClose" custom-style="border-radius: 35rpx;">
	<view style="width:600rpx;height:700rpx;display: flex;flex-direction: column;">
		<van-nav-bar title="{{agreement_name}}" />
		<view style="flex:1;overflow-y: scroll;padding:0 20rpx;">
			<rich-text nodes="{{PlatformAgreement}}"></rich-text>
		</view>
		<view style="width: 100%;height: 120rpx;display: flex;justify-content: center;align-items: center;">
			<view
				style="width: 80%;height: 70%;background: red;color: #fff;display: flex;justify-content: center;align-items: center;border-radius: 10rpx;"
				catchtap="PlatformAgreementClose">确定</view>
		</view>
	</view>
</van-popup>
<!-- end -->

<!-- 授权登录自动绑定手机号 (应用-小程序插件-设置开关)-->
<van-dialog
  use-slot
  title="绑定手机号"
	show="{{ showAutoBindPhone }}"
	confirm-button-text='选择授权手机号'
  confirm-button-open-type="getPhoneNumber"
  bind:getphonenumber="getPhoneNumber"
	confirm-button-color='#fff'
	class='autoBindPhone-dialog'
>
</van-dialog>
<van-popup show="{{showChangeID}}" round close-on-click-overlay="{{false}}">
	<view class="changeId_main">
		<icon class="iconfont icon-toast_warn"></icon>
		<view class="changeId_warnTitel">重要提示</view>
		<view class="changeId_warnText">
			当前绑定绑定操作会导致用户ID变更：原会员ID:{{ changidInfo.uid }}，变更后会员ID:{{ changidInfo.change_uid }}；绑定后所有数据记录以变更后会员ID{{ changidInfo.change_uid }}为准，<text style="color:#d53125;">原会员ID{{ changidInfo.uid }}数据将被删除，数据不会进行合并，且不可找回！</text>请谨慎操作！
			<view>绑定后请注意重新生成推广海报、重新发送推广链接！</view>
		</view>
		<view class="changeId_Btn" catchtap="setBindPhone">确认合并</view>
		<!-- <view class="changeId_Btn changeId_Btn_other" catchtap="closeChangeId">取消</view> -->
	</view>
</van-popup>

<!--完善个人信息-->
<van-popup show="{{is_show_user_info_edit_popup}}" round close-on-click-overlay="{{false}}">
	<view class="popup_box">
		<view class="h1">
			完善个人信息
			<icon class="iconfont icon-close11" catchtap="closeNickAvatar"></icon>
		</view>
		<view class="info">
			<button class="userAvatar" open-type="chooseAvatar" bind:chooseavatar="onChooseAvatar">
				<image class="avatar" src="{{avatar_image}}"></image>
			</button>
			<view class="row">
				<view class="text1">昵称：</view>
				<input type="nickname" bind:change="nicknameblur" class="weui-input" border="{{ false }}" value="{{nickname}}" data-nickname="{{nickname}}" placeholder="请输入昵称" />
			</view>
		</view>
		<view class="btn">
			<view class="button" catchtap="updateInfo">保存</view>
		</view>
	</view>
</van-popup>