赵明涛
9 months ago
4 changed files with 332 additions and 13 deletions
-
291src/subpackage/party/components/popup-content/miniapp-change-name-certify.vue
-
BINsrc/subpackage/party/components/popup-content/miniapp-change-name-certify.zip
-
10src/subpackage/party/pages/index/index.vue
-
44src/subpackage/party/pages/miniapp/certify.vue
@ -0,0 +1,291 @@ |
|||
<template> |
|||
<!-- 弹窗 --> |
|||
<view class="m-popup b-popup " v-if="true" :class="[directionClass,{'b-popup-round':round},{'b-popup-animation':animation}]"> |
|||
<view class="b-popup-shade" @click=""></view> |
|||
<view class="b-popup-content"> |
|||
|
|||
<view class="b-content-view b-flex-y b-flex-c"> |
|||
<!-- 右上角关闭按钮 --> |
|||
<view class="b-flex-x b-flex-e b-mb-20 b-flex-as-e"> |
|||
<text class="b-icon icon-close b-t-gray b-t-44" @click="closeChange"></text> |
|||
</view> |
|||
<view class="b-t-B b-t-36 b-mb-40">小程序认证账号名称设置</view> |
|||
<input class="bc-input b-mb-50" v-model="inputValue" type="text" placeholder="请输入" |
|||
placeholder-class="input-hold-class"></input> |
|||
|
|||
<!-- 账号类型 --> |
|||
<!-- <view class="rb-radio b-flex-x b-mb-40"> |
|||
<radio-group @change="idTimeChange"> |
|||
<radio value="1" checked style="transform:scale(0.9)" color="#009876">组织号</radio> |
|||
<radio value="2" style="transform:scale(0.9);margin-left: 40rpx;" color="#009876">个人号</radio> |
|||
</radio-group> |
|||
</view> --> |
|||
<block v-if="hit_txt"> |
|||
<view class="rb-line"></view> |
|||
<view class="rb-text b-t-24 b-t-red b-p-40"> |
|||
<text>{{hit_txt}}</text> |
|||
<!-- <text>你申请的名称涉及特定地域范围或地理名称,需要经过平台审核后才可使用,你可以直接提交审核,或提供《商标注册证》等材料,以证明你可使用该地域范围或地理名称作为账号名称,否则可能审核不通过。</text> --> |
|||
</view> |
|||
</block> |
|||
|
|||
|
|||
<!-- 补充材料上传 --> |
|||
<!-- <view class="rb-upload-list b-flex-x b-flex-a b-mt-50"> |
|||
<view class="b-flex-y b-flex-c"> |
|||
<view class="b-mb-30">拍照上传</view> |
|||
<view class="rb-upload-item b-flex-y b-flex-c"> |
|||
<image class="rb-upload-bg" src="../../static/regist/upload_bg.png"></image> |
|||
<image class="rb-upload-cam" src="../../static/regist/camera.png"></image> |
|||
<text class="rb-input-img-text">点击上传</text> |
|||
</view> |
|||
</view> |
|||
<view class="b-flex-y b-flex-c"> |
|||
<view class="b-mb-30">关键词补充材料</view> |
|||
<view class="rb-upload-item b-flex-y b-flex-c"> |
|||
<image class="rb-upload-bg" src="../../static/regist/upload_bg.png"></image> |
|||
<image class="rb-upload-cam" src="../../static/regist/camera.png"></image> |
|||
<text class="rb-input-img-text">点击上传</text> |
|||
</view> |
|||
</view> |
|||
<view class="b-flex-as-e b-ml-40 b-t-24 b-t-green b-t-B b-t-U">重新上传</view> |
|||
</view> --> |
|||
|
|||
<view class="rb-btns b-flex-x b-mt-40 b-mb-50"> |
|||
<block v-if="!checkNameRes"> |
|||
<button class="b-btn b-btn-green b-mr-40" @click="checkName">下一步</button> |
|||
</block> |
|||
<block v-else> |
|||
<button class="b-btn b-btn-green b-mr-40" @click="closeChange">取消</button> |
|||
<button v-if="checkNameRes&&checkNameRes.code==0" class="b-btn b-btn-green " @click="sureChange">确定填入</button> |
|||
</block> |
|||
|
|||
</view> |
|||
|
|||
|
|||
</view> |
|||
</view> |
|||
</view> |
|||
</template> |
|||
|
|||
<script> |
|||
import util from '@/utils/util'; |
|||
import { servers } from '@/js/server'; |
|||
import party_api from '../../js/api.js'; |
|||
|
|||
import { mapState } from 'vuex'; |
|||
|
|||
export default { |
|||
props: { |
|||
nameInfo: { |
|||
type: Object, |
|||
default: ()=>({}) |
|||
}, |
|||
appid: { |
|||
type: String, |
|||
default: '' |
|||
}, |
|||
// hit_txt: { |
|||
// type: String, |
|||
// default: '' |
|||
// }, |
|||
|
|||
}, |
|||
computed: { |
|||
...mapState(['brandInfo']), |
|||
hit_txt(){ |
|||
// if(this.checkNameRes.data && this.checkNameRes.data.hit_condition){ |
|||
// return this.checkNameRes.data.hit_condition |
|||
// } |
|||
if(this.checkNameRes.message){ |
|||
return this.checkNameRes.message |
|||
} |
|||
if(this.checkNameRes.data && this.checkNameRes.data.hit_condition){ |
|||
return this.checkNameRes.data.wording |
|||
} |
|||
return '' |
|||
} |
|||
}, |
|||
onmounted(){ |
|||
console.log("onmounted123",this.nameInfo) |
|||
}, |
|||
data() { |
|||
return { |
|||
showPopup:true, |
|||
inputValue: '', |
|||
checkNameRes: "", |
|||
} |
|||
}, |
|||
methods: { |
|||
moveHandle(){}, |
|||
async checkName(){ |
|||
let check_res= await this.checkwxverifynickname() |
|||
console.log("check_res:",check_res) |
|||
// this.$emit('sure',this.inputValue); |
|||
}, |
|||
sureChange(){ |
|||
this.$emit('sure',{ |
|||
name: this.inputValue, |
|||
checkNameRes: this.checkNameRes, |
|||
}); |
|||
}, |
|||
closeChange(){ |
|||
this.$emit('close'); |
|||
}, |
|||
|
|||
checkwxverifynickname(){ |
|||
this.checkNameRes = {} |
|||
let _data = this.getGateWayJson('checkwxverifynickname') |
|||
_data.form.nick_name = this.inputValue |
|||
console.log("getaccountbasicinfo:",_data) |
|||
return servers.post({ |
|||
url: party_api.gatewayDo, |
|||
data: _data, |
|||
isDefaultGet: false, |
|||
}) |
|||
.then(res=>{ |
|||
console.log("checkwxverifynickname:", res.data) |
|||
this.checkNameRes = res.data |
|||
if(res.data.code!=0){ |
|||
util.showNone("名称不可用") |
|||
console.log("checkwxverifynickname-err", res.data) |
|||
}else{ |
|||
util.showNone('名称可用') |
|||
if(!res.data.data.hit_condition){ |
|||
res.data.message = '名称可用(注意:改名次数将在自然年 1 月 1 日和微信认证审核通过后重置为 2 次.请慎重修改.)' |
|||
} |
|||
} |
|||
this.checkNameRes = res.data |
|||
console.log("checkwxverifynickname123123:", this.checkNameRes) |
|||
|
|||
}) |
|||
.catch(err=>{ |
|||
console.log("checkwxverifynickname-err", err) |
|||
}) |
|||
|
|||
}, |
|||
getGateWayJson(jname){ |
|||
let appid = this.appid |
|||
let _data = party_api["gatewayDoJson"][jname] |
|||
if(!appid){ |
|||
console.error("当前page中: this.appid不存在") |
|||
return util.showNone("appid不存在") |
|||
} |
|||
if(!_data){ |
|||
console.error("先去api.js定义透传数据:",jname) |
|||
return util.showNone("接口不存在") |
|||
} |
|||
_data.appid = appid; |
|||
return _data |
|||
}, |
|||
selectBtn(type){ |
|||
this.selectType = type |
|||
}, |
|||
}, |
|||
} |
|||
|
|||
</script> |
|||
|
|||
<style lang="scss" > |
|||
@import '~style/public.scss'; |
|||
@import '../../ui/maincss.scss'; |
|||
|
|||
.m-popup{ |
|||
.b-popup-shade{ |
|||
background: rgba(0,0,0,0.5); |
|||
position: fixed; |
|||
top: 0; |
|||
left: 0; |
|||
width: 100%; |
|||
height: 100%; |
|||
z-index: 100; |
|||
} |
|||
.b-popup-content{ |
|||
position: fixed; |
|||
top: 50%; |
|||
left: 50%; |
|||
transform: translate(-50%,-50%); |
|||
background: #fff; |
|||
border-radius: 5rpx; |
|||
z-index: 101; |
|||
.b-content-view{ |
|||
width: 620rpx; |
|||
padding: 20rpx; |
|||
.b-content-title{ |
|||
|
|||
} |
|||
.bc-input{ |
|||
width: 538rpx; |
|||
height: 88rpx; |
|||
background: #FFFFFF; |
|||
border: 2rpx solid #D8D8D8; |
|||
border-radius: 10rpx; |
|||
padding-left: 30rpx; |
|||
} |
|||
.input-hold-class{ |
|||
font-size: 28rpx; |
|||
} |
|||
.rb-line{ |
|||
border-bottom: 1rpx solid #E5E5E5; |
|||
width: 100%; |
|||
} |
|||
.rb-btns{ |
|||
>button{ |
|||
width: 240rpx; |
|||
height: 88rpx; |
|||
} |
|||
>button:first-child{ |
|||
background: #fff; |
|||
color: $b-color-green; |
|||
// border: 1rpx solid $b-color-green; |
|||
} |
|||
} |
|||
.rb-text{ |
|||
>text{ |
|||
line-height: 40rpx; |
|||
} |
|||
} |
|||
.rb-upload-list{ |
|||
width: 100%; |
|||
|
|||
.rb-upload-item{ |
|||
width: 168rpx; |
|||
height: 168rpx; |
|||
// position: relative; |
|||
|
|||
.rb-upload-bg{ |
|||
width: 168rpx; |
|||
height: 168rpx; |
|||
position: absolute; |
|||
} |
|||
|
|||
.rb-upload-cam{ |
|||
width: 48rpx; |
|||
height: 40rpx; |
|||
} |
|||
.rb-input-img-text{ |
|||
font-size: 24rpx; |
|||
margin-top: 24rpx; |
|||
color: #1A1A1A; |
|||
z-index: 2; |
|||
} |
|||
} |
|||
.idcard-width-170{ |
|||
width: 280rpx; |
|||
height: 170rpx; |
|||
.rb-upload-bg{ |
|||
width: 280rpx; |
|||
height: 170rpx; |
|||
position: absolute; |
|||
} |
|||
} |
|||
} |
|||
|
|||
} |
|||
} |
|||
.popup-demo{ |
|||
font-size: 32rpx; |
|||
color: #333333; |
|||
} |
|||
|
|||
} |
|||
</style> |
Write
Preview
Loading…
Cancel
Save
Reference in new issue