@ -1,395 +1,417 @@ | |||||
<template> | <template> | ||||
<view class="registerShop"> | |||||
<navbar :title="titleList[titleIndex]" leftClick @leftClick="$utils.navigateBack"/> | |||||
<view class="frame"> | |||||
<!--基本信息--> | |||||
<view class="basicInfo"> | |||||
<!--用户名--> | |||||
<view class="item"> | |||||
<view>{{ $t('components.username')}}</view> | |||||
<view> | |||||
<input v-model="form.userName" :placeholder="$t('components.enterUserName')" clearable></input> | |||||
</view> | |||||
</view> | |||||
<!--密码--> | |||||
<view class="item"> | |||||
<view>{{ $t('components.password')}}</view> | |||||
<view> | |||||
<input v-model="form.password" password clearable :placeholder="$t('components.enterYourPassword')" clearable></input> | |||||
</view> | |||||
</view> | |||||
<!--公司名称--> | |||||
<view class="item"> | |||||
<view>{{ $t('other.companyName')}}</view> | |||||
<view> | |||||
<input v-model="form.companyName" type="number" :placeholder="$t('other.enterCompanyName')" clearable></input> | |||||
</view> | |||||
</view> | |||||
<!--税收编码--> | |||||
<view class="item"> | |||||
<view>{{ $t('other.taxCode')}}</view> | |||||
<view> | |||||
<input v-model="form.taxCode" :placeholder="$t('other.enterTaxCode')" clearable></input> | |||||
</view> | |||||
</view> | |||||
<!--公司地址--> | |||||
<view class="item"> | |||||
<view>{{ $t('other.companyAddress')}}</view> | |||||
<view> | |||||
<input v-model="form.address" :placeholder="$t('other.enterCompanyAddress')" clearable></input> | |||||
</view> | |||||
</view> | |||||
<!--联系电话--> | |||||
<view class="item"> | |||||
<view>{{ $t('components.lxPhone')}}</view> | |||||
<view> | |||||
<input v-model="form.phone" :placeholder="$t('components.plePhoneNumber')" clearable></input> | |||||
</view> | |||||
</view> | |||||
<!----> | |||||
<view class="item"> | |||||
<view>{{ $t('other.companyAccount')}}</view> | |||||
<view> | |||||
<input v-model="form.bankAccount" :placeholder="$t('other.enterCompanyAccount')" clearable></input> | |||||
</view> | |||||
</view> | |||||
<view class="item"> | |||||
<view>{{ $t('components.bankName')}}</view> | |||||
<view> | |||||
<input v-model="form.bankNama" :placeholder="$t('components.enterBankName')" clearable></input> | |||||
</view> | |||||
</view> | |||||
</view> | |||||
<!--证件信息--> | |||||
<view class="certificateInfo"> | |||||
<!--营业执照--> | |||||
<view class="certificateInfoItem"> | |||||
<view class="title"> | |||||
<span | |||||
style="width: 10rpx;height: 40rpx;background-color: #f78142;border-radius: 10rpx;overflow: hidden;"></span> | |||||
<span>{{ $t('components.businessLicense')}}</span> | |||||
</view> | |||||
<view class="upload"> | |||||
<uv-upload | |||||
:fileList="yyzzfileList" | |||||
:maxCount="4" | |||||
multiple | |||||
width="150rpx" | |||||
height="150rpx" | |||||
@delete="(file) => deleteImage(0, file)" | |||||
@afterRead="(file) => afterRead(0, file)" | |||||
:previewFullImage="true"></uv-upload> | |||||
</view> | |||||
</view> | |||||
<!--基本户信息--> | |||||
<view class="certificateInfoItem"> | |||||
<view class="title"> | |||||
<span | |||||
style="width: 10rpx;height: 40rpx;background-color: #f78142;border-radius: 10rpx;overflow: hidden;"></span> | |||||
<span>{{ $t('components.basicAccountInfo')}}</span> | |||||
</view> | |||||
<view class="upload"> | |||||
<uv-upload | |||||
:fileList="jbhxxfileList" | |||||
:maxCount="4" | |||||
multiple | |||||
width="150rpx" | |||||
height="150rpx" | |||||
@delete="(file) => deleteImage(1, file)" | |||||
@afterRead="(file) => afterRead(1, file)" | |||||
:previewFullImage="true"></uv-upload> | |||||
</view> | |||||
</view> | |||||
<!--收款银行--> | |||||
<view class="certificateInfoItem"> | |||||
<view class="title"> | |||||
<span | |||||
style="width: 10rpx;height: 40rpx;background-color: #f78142;border-radius: 10rpx;overflow: hidden;"></span> | |||||
<span>{{ $t('components.receivingBank')}}</span> | |||||
</view> | |||||
<view class="upload"> | |||||
<uv-upload | |||||
:fileList="skyhfileList" | |||||
:maxCount="4" | |||||
multiple | |||||
width="150rpx" | |||||
height="150rpx" | |||||
@delete="(file) => deleteImage(2, file)" | |||||
@afterRead="(file) => afterRead(2, file)" | |||||
:previewFullImage="true"></uv-upload> | |||||
</view> | |||||
</view> | |||||
</view> | |||||
</view> | |||||
<view class="bottom"> | |||||
<view class="btns"> | |||||
<!--申请审核--> | |||||
<span @click="applyReview" class="sqsh"> | |||||
{{ $t('components.submitReview') }} | |||||
</span> | |||||
<!--联系我们--> | |||||
<span @click="contactUs" class="lxwm"> | |||||
{{ $t('components.contactUs') }} | |||||
</span> | |||||
</view> | |||||
<view class="others"> | |||||
<!--注册须知--> | |||||
<span @click="applyReview" class="zcxz"> | |||||
{{ $t('components.registrationNotice') }} | |||||
</span> | |||||
<!--框架合同预览--> | |||||
<span @click="contactUs" class="kjhtyl"> | |||||
{{ $t('other.frameworkContractPreview') }} | |||||
</span> | |||||
</view> | |||||
</view> | |||||
<!-- 联系客服弹框 --> | |||||
<customerServicePopup ref="customerServicePopup" /> | |||||
</view> | |||||
<view class="registerShop"> | |||||
<navbar :title="titleList[titleIndex]" leftClick @leftClick="$utils.navigateBack" /> | |||||
<view class="frame"> | |||||
<!--基本信息--> | |||||
<view class="basicInfo"> | |||||
<!--用户名--> | |||||
<view class="item"> | |||||
<view>{{ $t('components.username')}}</view> | |||||
<view> | |||||
<input v-model="form.userName" :placeholder="$t('components.enterUserName')" clearable></input> | |||||
</view> | |||||
</view> | |||||
<!--密码--> | |||||
<view class="item"> | |||||
<view>{{ $t('components.password')}}</view> | |||||
<view> | |||||
<input v-model="form.password" password clearable | |||||
:placeholder="$t('components.enterYourPassword')" clearable></input> | |||||
</view> | |||||
</view> | |||||
<!--公司名称--> | |||||
<view class="item"> | |||||
<view>{{ $t('other.companyName')}}</view> | |||||
<view> | |||||
<input v-model="form.companyName" type="number" :placeholder="$t('other.enterCompanyName')" | |||||
clearable></input> | |||||
</view> | |||||
</view> | |||||
<!--税收编码--> | |||||
<view class="item"> | |||||
<view>{{ $t('other.taxCode')}}</view> | |||||
<view> | |||||
<input v-model="form.taxCode" :placeholder="$t('other.enterTaxCode')" clearable></input> | |||||
</view> | |||||
</view> | |||||
<!--公司地址--> | |||||
<view class="item"> | |||||
<view>{{ $t('other.companyAddress')}}</view> | |||||
<view> | |||||
<input v-model="form.address" :placeholder="$t('other.enterCompanyAddress')" clearable></input> | |||||
</view> | |||||
</view> | |||||
<!--联系电话--> | |||||
<view class="item"> | |||||
<view>{{ $t('components.lxPhone')}}</view> | |||||
<view> | |||||
<input v-model="form.phone" :placeholder="$t('components.plePhoneNumber')" clearable></input> | |||||
</view> | |||||
</view> | |||||
<!----> | |||||
<view class="item"> | |||||
<view>{{ $t('other.companyAccount')}}</view> | |||||
<view> | |||||
<input v-model="form.bankAccount" :placeholder="$t('other.enterCompanyAccount')" | |||||
clearable></input> | |||||
</view> | |||||
</view> | |||||
<view class="item"> | |||||
<view>{{ $t('components.bankName')}}</view> | |||||
<view> | |||||
<input v-model="form.bankNama" :placeholder="$t('components.enterBankName')" clearable></input> | |||||
</view> | |||||
</view> | |||||
</view> | |||||
<!--证件信息--> | |||||
<view class="certificateInfo"> | |||||
<!--营业执照--> | |||||
<view class="certificateInfoItem"> | |||||
<view class="title"> | |||||
<span | |||||
style="width: 10rpx;height: 40rpx;background-color: #f78142;border-radius: 10rpx;overflow: hidden;"></span> | |||||
<span>{{ $t('components.businessLicense')}}</span> | |||||
</view> | |||||
<view class="upload"> | |||||
<uv-upload :fileList="yyzzfileList" :maxCount="4" multiple width="150rpx" height="150rpx" | |||||
@delete="(file) => deleteImage(0, file)" @afterRead="(file) => afterRead(0, file)" | |||||
:previewFullImage="true"></uv-upload> | |||||
</view> | |||||
</view> | |||||
<!--基本户信息--> | |||||
<view class="certificateInfoItem"> | |||||
<view class="title"> | |||||
<span | |||||
style="width: 10rpx;height: 40rpx;background-color: #f78142;border-radius: 10rpx;overflow: hidden;"></span> | |||||
<span>{{ $t('components.basicAccountInfo')}}</span> | |||||
</view> | |||||
<view class="upload"> | |||||
<uv-upload :fileList="jbhxxfileList" :maxCount="4" multiple width="150rpx" height="150rpx" | |||||
@delete="(file) => deleteImage(1, file)" @afterRead="(file) => afterRead(1, file)" | |||||
:previewFullImage="true"></uv-upload> | |||||
</view> | |||||
</view> | |||||
<!--收款银行--> | |||||
<view class="certificateInfoItem"> | |||||
<view class="title"> | |||||
<span | |||||
style="width: 10rpx;height: 40rpx;background-color: #f78142;border-radius: 10rpx;overflow: hidden;"></span> | |||||
<span>{{ $t('components.receivingBank')}}</span> | |||||
</view> | |||||
<view class="upload"> | |||||
<uv-upload :fileList="skyhfileList" :maxCount="4" multiple width="150rpx" height="150rpx" | |||||
@delete="(file) => deleteImage(2, file)" @afterRead="(file) => afterRead(2, file)" | |||||
:previewFullImage="true"></uv-upload> | |||||
</view> | |||||
</view> | |||||
</view> | |||||
</view> | |||||
<view class="bottom"> | |||||
<view class="btns"> | |||||
<!--申请审核--> | |||||
<span @click="applyReview" class="sqsh"> | |||||
{{ $t('components.submitReview') }} | |||||
</span> | |||||
<!--联系我们--> | |||||
<span @click="contactUs" class="lxwm"> | |||||
{{ $t('components.contactUs') }} | |||||
</span> | |||||
</view> | |||||
<view class="others"> | |||||
<!--注册须知--> | |||||
<span @click="applyReview" class="zcxz"> | |||||
{{ $t('components.registrationNotice') }} | |||||
</span> | |||||
<!--框架合同预览--> | |||||
<span @click="contactUs" class="kjhtyl"> | |||||
{{ $t('other.frameworkContractPreview') }} | |||||
</span> | |||||
</view> | |||||
</view> | |||||
<!-- 联系客服弹框 --> | |||||
<customerServicePopup ref="customerServicePopup" /> | |||||
</view> | |||||
</template> | </template> | ||||
<script> | <script> | ||||
import customerServicePopup from "@/components/config/customerServicePopup.vue"; | |||||
export default { | |||||
components: {customerServicePopup}, | |||||
onLoad(option) { | |||||
this.titleIndex = option.identity | |||||
}, | |||||
data() { | |||||
return { | |||||
titleIndex: 0, | |||||
titleList: [ | |||||
// 采购商注册 供应商注册 国内清关申请 | |||||
this.$t('other.buyerRegistration'), | |||||
this.$t('other.supplierRegistration'), | |||||
this.$t('other.domesticCustomsClearanceApplication') | |||||
], | |||||
form: { | |||||
"address": "", | |||||
"auditStatus": 0, | |||||
"bankAccount": "", | |||||
"bankInfo": "", | |||||
"bankNama": "", | |||||
"basicAccount": "", | |||||
"businessLicense": "", | |||||
"companyName": "", | |||||
"password": "", | |||||
"phone": "", | |||||
"role": 0, | |||||
"taxCode": "", | |||||
"userName": "" | |||||
}, | |||||
yyzzfileList: [], | |||||
jbhxxfileList: [], | |||||
skyhfileList: [], | |||||
} | |||||
}, | |||||
methods: { | |||||
// 申请审核 | |||||
applyReview() { | |||||
this.$api('roleOption',this.form, res => { | |||||
if (res.code == 200) { | |||||
uni.removeStorageSync('token') | |||||
this.$store.state.userInfo = {} | |||||
uni.redirectTo({ | |||||
url: '/pages/index/index' | |||||
}) | |||||
} | |||||
}) | |||||
}, | |||||
// 联系我们 | |||||
contactUs() { | |||||
console.log("打开客服弹框") | |||||
this.$refs.customerServicePopup.open(); | |||||
}, | |||||
// 上传图片 | |||||
afterRead(type, e) { | |||||
let self = this | |||||
e.file.forEach(file => { | |||||
self.$Oss.ossUpload(file.url).then(url => { | |||||
if (type == 0) { | |||||
self.yyzzfileList.push({url}) | |||||
} else if (type == 1) { | |||||
self.jbhxxfileList.push({url}) | |||||
} else if (type == 2) { | |||||
self.skyhfileList.push({url}) | |||||
} | |||||
}) | |||||
}) | |||||
}, | |||||
// 删除图片 | |||||
deleteImage(type, e) { | |||||
console.log(e, type, "===========") | |||||
if (type == 0) { | |||||
this.yyzzfileList.splice(e.index, 1) | |||||
} else if (type == 1) { | |||||
this.jbhxxfileList.splice(e.index, 1) | |||||
} else if (type == 2) { | |||||
this.skyhfileList.splice(e.index, 1) | |||||
} | |||||
}, | |||||
} | |||||
} | |||||
import customerServicePopup from "@/components/config/customerServicePopup.vue"; | |||||
export default { | |||||
components: { | |||||
customerServicePopup | |||||
}, | |||||
onLoad(option) { | |||||
this.titleIndex = option.identity | |||||
this.form.role = option.identity | |||||
}, | |||||
data() { | |||||
return { | |||||
titleIndex: 0, | |||||
titleList: [ | |||||
// 采购商注册 供应商注册 国内清关申请 | |||||
this.$t('other.buyerRegistration'), | |||||
this.$t('other.supplierRegistration'), | |||||
this.$t('other.domesticCustomsClearanceApplication') | |||||
], | |||||
form: { | |||||
"address": "", | |||||
"auditStatus": 0, | |||||
"bankAccount": "", | |||||
"bankInfo": "", | |||||
"bankNama": "", | |||||
"basicAccount": "", | |||||
"businessLicense": "", | |||||
"companyName": "", | |||||
"password": "", | |||||
"phone": "", | |||||
"role": 0, | |||||
"taxCode": "", | |||||
"userName": "" | |||||
}, | |||||
yyzzfileList: [],//营业执照 | |||||
jbhxxfileList: [],//基本户信息 | |||||
skyhfileList: [],//收款银行 | |||||
} | |||||
}, | |||||
methods: { | |||||
// 申请审核 | |||||
applyReview() { | |||||
let data = JSON.parse(JSON.stringify(this.form)) | |||||
data.businessLicense = this.yyzzfileList.map((item) => item.url).join(",") | |||||
data.basicAccount = this.jbhxxfileList.map((item) => item.url).join(",") | |||||
data.bankInfo = this.skyhfileList.map((item) => item.url).join(",") | |||||
if(this.$utils.verificationAll(data, { | |||||
"userName": this.$t('components.enterUserName'), | |||||
"password": this.$t('components.enterYourPassword'), | |||||
"companyName": this.$t('other.enterCompanyName'), | |||||
"taxCode": this.$t('other.enterTaxCode'), | |||||
"address": this.$t('other.enterCompanyAddress'), | |||||
"phone": this.$t('components.plePhoneNumber'), | |||||
"bankAccount": this.$t('other.enterCompanyAccount'), | |||||
"bankNama": this.$t('components.enterBankName'), | |||||
"businessLicense": '请上传营业执照', | |||||
"basicAccount": '请上传基本户信息照片', | |||||
"bankInfo": '请上传收款银行照片', | |||||
})){ | |||||
return | |||||
} | |||||
this.$api(this.titleIndex == 2 ? | |||||
'addCustoms' | |||||
: 'roleOption', this.form, res => { | |||||
if (res.code == 200) { | |||||
uni.removeStorageSync('token') | |||||
this.$store.state.userInfo = {} | |||||
// uni.redirectTo({ | |||||
// url: '/pages/index/index' | |||||
// }) | |||||
uni.showToast({ | |||||
title: '提交成功!耐心等待审核', | |||||
icon: 'none' | |||||
}) | |||||
} | |||||
}) | |||||
}, | |||||
// 联系我们 | |||||
contactUs() { | |||||
console.log("打开客服弹框") | |||||
this.$refs.customerServicePopup.open(); | |||||
}, | |||||
// 上传图片 | |||||
afterRead(type, e) { | |||||
let self = this | |||||
e.file.forEach(file => { | |||||
self.$Oss.ossUpload(file.url).then(url => { | |||||
if (type == 0) { | |||||
self.yyzzfileList.push({ | |||||
url | |||||
}) | |||||
} else if (type == 1) { | |||||
self.jbhxxfileList.push({ | |||||
url | |||||
}) | |||||
} else if (type == 2) { | |||||
self.skyhfileList.push({ | |||||
url | |||||
}) | |||||
} | |||||
}) | |||||
}) | |||||
}, | |||||
// 删除图片 | |||||
deleteImage(type, e) { | |||||
console.log(e, type, "===========") | |||||
if (type == 0) { | |||||
this.yyzzfileList.splice(e.index, 1) | |||||
} else if (type == 1) { | |||||
this.jbhxxfileList.splice(e.index, 1) | |||||
} else if (type == 2) { | |||||
this.skyhfileList.splice(e.index, 1) | |||||
} | |||||
}, | |||||
} | |||||
} | |||||
</script> | </script> | ||||
<style scoped lang="scss"> | <style scoped lang="scss"> | ||||
.registerShop { | |||||
.frame { | |||||
height: 79vh; | |||||
overflow: auto; | |||||
.basicInfo { | |||||
display: flex; | |||||
flex-direction: column; | |||||
gap: 5rpx; | |||||
background-color: #FFF; | |||||
margin-top: 20rpx; | |||||
padding: 20rpx; | |||||
.item { | |||||
display: flex; | |||||
align-items: center; | |||||
background-color: #FFF; | |||||
height: 80rpx; | |||||
// margin: 10rpx 0 0 0; | |||||
padding: 10rpx 0 0 20rpx; | |||||
> view:nth-of-type(1) { | |||||
width: 30%; | |||||
// font-weight: 700; | |||||
} | |||||
> view:nth-of-type(2) { | |||||
width: 70%; | |||||
border-radius: 10rpx; | |||||
overflow: hidden; | |||||
input { | |||||
background-color: #f5f5f5; | |||||
font-size: 28rpx; | |||||
padding: 16rpx 8rpx 16rpx 15rpx; | |||||
} | |||||
} | |||||
} | |||||
} | |||||
.certificateInfo { | |||||
display: flex; | |||||
flex-direction: column; | |||||
gap: 20rpx; | |||||
background-color: #FFF; | |||||
margin-top: 20rpx; | |||||
padding: 20rpx; | |||||
.certificateInfoItem { | |||||
.title { | |||||
display: flex; | |||||
// padding-top: 40rpx; | |||||
font-size: 30rpx; | |||||
font-weight: 700; | |||||
padding: 0 0 0 20rpx; | |||||
> span:nth-of-type(1) { | |||||
margin: 4rpx 0 0 8rpx; | |||||
background-color: #FFF; | |||||
} | |||||
> span:nth-of-type(2) { | |||||
margin: 0 0 0 8rpx; | |||||
background-color: #FFF; | |||||
} | |||||
} | |||||
.upload { | |||||
margin: 5rpx 0 0 40rpx; | |||||
} | |||||
} | |||||
} | |||||
} | |||||
.bottom { | |||||
position: fixed; | |||||
bottom: 10rpx; | |||||
left: 0; | |||||
right: 0; | |||||
background-color: #FFF; | |||||
.btns { | |||||
display: flex; | |||||
justify-content: center; | |||||
align-items: center; | |||||
gap: 40rpx; | |||||
.sqsh { | |||||
display: flex; | |||||
align-items: center; | |||||
justify-content: center; | |||||
width: 40%; | |||||
height: 70rpx; | |||||
border-radius: 40rpx; | |||||
color: white; | |||||
font-size: 28rpx; | |||||
margin: 20rpx 10rpx 0 0; | |||||
background: #293143; | |||||
//margin-top: 20rpx; | |||||
border-radius: 40rpx; | |||||
} | |||||
.lxwm { | |||||
display: flex; | |||||
align-items: center; | |||||
justify-content: center; | |||||
width: 40%; | |||||
height: 70rpx; | |||||
border-radius: 40rpx; | |||||
color: #000000; | |||||
font-size: 28rpx; | |||||
margin: 20rpx 10rpx 0 0; | |||||
background: #f2f2f2; | |||||
//margin-top: 20rpx; | |||||
border-radius: 40rpx; | |||||
} | |||||
} | |||||
.others { | |||||
display: flex; | |||||
justify-content: center; | |||||
align-items: center; | |||||
gap: 200rpx; | |||||
color: #707070; | |||||
font-size: 24rpx; | |||||
.zcxz { | |||||
text-decoration: underline; | |||||
} | |||||
.kjhtyl { | |||||
text-decoration: underline; | |||||
} | |||||
} | |||||
} | |||||
} | |||||
</style> | |||||
.registerShop { | |||||
.frame { | |||||
height: 79vh; | |||||
overflow: auto; | |||||
.basicInfo { | |||||
display: flex; | |||||
flex-direction: column; | |||||
gap: 5rpx; | |||||
background-color: #FFF; | |||||
margin-top: 20rpx; | |||||
padding: 20rpx; | |||||
.item { | |||||
display: flex; | |||||
align-items: center; | |||||
background-color: #FFF; | |||||
height: 80rpx; | |||||
// margin: 10rpx 0 0 0; | |||||
padding: 10rpx 0 0 20rpx; | |||||
>view:nth-of-type(1) { | |||||
width: 30%; | |||||
// font-weight: 700; | |||||
} | |||||
>view:nth-of-type(2) { | |||||
width: 70%; | |||||
border-radius: 10rpx; | |||||
overflow: hidden; | |||||
input { | |||||
background-color: #f5f5f5; | |||||
font-size: 28rpx; | |||||
padding: 16rpx 8rpx 16rpx 15rpx; | |||||
} | |||||
} | |||||
} | |||||
} | |||||
.certificateInfo { | |||||
display: flex; | |||||
flex-direction: column; | |||||
gap: 20rpx; | |||||
background-color: #FFF; | |||||
margin-top: 20rpx; | |||||
padding: 20rpx; | |||||
.certificateInfoItem { | |||||
.title { | |||||
display: flex; | |||||
// padding-top: 40rpx; | |||||
font-size: 30rpx; | |||||
font-weight: 700; | |||||
padding: 0 0 0 20rpx; | |||||
>span:nth-of-type(1) { | |||||
margin: 4rpx 0 0 8rpx; | |||||
background-color: #FFF; | |||||
} | |||||
>span:nth-of-type(2) { | |||||
margin: 0 0 0 8rpx; | |||||
background-color: #FFF; | |||||
} | |||||
} | |||||
.upload { | |||||
margin: 5rpx 0 0 40rpx; | |||||
} | |||||
} | |||||
} | |||||
} | |||||
.bottom { | |||||
position: fixed; | |||||
bottom: 10rpx; | |||||
left: 0; | |||||
right: 0; | |||||
background-color: #FFF; | |||||
.btns { | |||||
display: flex; | |||||
justify-content: center; | |||||
align-items: center; | |||||
gap: 40rpx; | |||||
.sqsh { | |||||
display: flex; | |||||
align-items: center; | |||||
justify-content: center; | |||||
width: 40%; | |||||
height: 70rpx; | |||||
border-radius: 40rpx; | |||||
color: white; | |||||
font-size: 28rpx; | |||||
margin: 20rpx 10rpx 0 0; | |||||
background: #293143; | |||||
//margin-top: 20rpx; | |||||
border-radius: 40rpx; | |||||
} | |||||
.lxwm { | |||||
display: flex; | |||||
align-items: center; | |||||
justify-content: center; | |||||
width: 40%; | |||||
height: 70rpx; | |||||
border-radius: 40rpx; | |||||
color: #000000; | |||||
font-size: 28rpx; | |||||
margin: 20rpx 10rpx 0 0; | |||||
background: #f2f2f2; | |||||
//margin-top: 20rpx; | |||||
border-radius: 40rpx; | |||||
} | |||||
} | |||||
.others { | |||||
display: flex; | |||||
justify-content: center; | |||||
align-items: center; | |||||
gap: 200rpx; | |||||
color: #707070; | |||||
font-size: 24rpx; | |||||
.zcxz { | |||||
text-decoration: underline; | |||||
} | |||||
.kjhtyl { | |||||
text-decoration: underline; | |||||
} | |||||
} | |||||
} | |||||
} | |||||
</style> |
@ -1,100 +1,107 @@ | |||||
<template> | <template> | ||||
<view> | |||||
<view> | |||||
<navbar :title="$t('pageTitle.selectIdentity')" | |||||
:leftClick="!$route.query.back" @leftClick="$utils.navigateBack"/> | |||||
<navbar :title="$t('pageTitle.selectIdentity')" :leftClick="!$route.query.back" | |||||
@leftClick="$utils.navigateBack" /> | |||||
<view class="container"> | |||||
<view class="container"> | |||||
<view class="title">{{ $t('components.selectIdentity') }}</view> | |||||
<view class="button-group"> | |||||
<!--供应商--> | |||||
<view class="identity-button" @click="selectIdentity(0)"> | |||||
<view class="identity-text"> {{ $t('other.iAmBuyer') }}</view> | |||||
<view class="identity-icon"> | |||||
<img src="../../static/image/index/5.png" style="width: 100%; height: 100%;"> | |||||
</view> | |||||
</view> | |||||
<!--采购--> | |||||
<view class="identity-button" @click="selectIdentity(1)"> | |||||
<view class="identity-text"> {{ $t('other.iAmSupplier') }}</view> | |||||
<view class="identity-icon"> | |||||
<img src="../../static/image/index/6.png" style="width: 100%; height: 100%;"> | |||||
</view> | |||||
</view> | |||||
</view> | |||||
</view> | |||||
</view> | |||||
<view class="title">{{ $t('components.selectIdentity') }}</view> | |||||
<view class="button-group"> | |||||
<!--供应商--> | |||||
<view class="identity-button" @click="selectIdentity(0)"> | |||||
<view class="identity-text"> {{ $t('other.iAmBuyer') }}</view> | |||||
<view class="identity-icon"> | |||||
<img src="../../static/image/index/5.png" style="width: 100%; height: 100%;"> | |||||
</view> | |||||
</view> | |||||
<!--采购--> | |||||
<view class="identity-button" @click="selectIdentity(1)"> | |||||
<view class="identity-text"> {{ $t('other.iAmSupplier') }}</view> | |||||
<view class="identity-icon"> | |||||
<img src="../../static/image/index/6.png" style="width: 100%; height: 100%;"> | |||||
</view> | |||||
</view> | |||||
</view> | |||||
</view> | |||||
</view> | |||||
</template> | </template> | ||||
<script> | <script> | ||||
import {mapGetters} from 'vuex' | |||||
import { | |||||
mapGetters | |||||
} from 'vuex' | |||||
export default { | |||||
computed: { | |||||
...mapGetters(['userShop', "userInfo"]), | |||||
}, | |||||
methods: { | |||||
selectIdentity(identity) { | |||||
// if (userInfo) | |||||
uni.navigateTo({ | |||||
url: `/pages_order/auth/registerShop?identity=${identity}` | |||||
}) | |||||
}, | |||||
} | |||||
} | |||||
export default { | |||||
computed: { | |||||
...mapGetters(['userShop', "userInfo", 'buy', 'shopData']), | |||||
}, | |||||
methods: { | |||||
selectIdentity(identity) { | |||||
// if (userInfo) | |||||
if (identity == 0 && this.buy) { | |||||
this.$store.commit('setShop', false) | |||||
} else if (identity == 1 && this.shopData) { | |||||
this.$store.commit('setShop', true) | |||||
} else { | |||||
uni.navigateTo({ | |||||
url: `/pages_order/auth/registerShop?identity=${identity}` | |||||
}) | |||||
} | |||||
}, | |||||
} | |||||
} | |||||
</script> | </script> | ||||
<style scoped lang="scss"> | <style scoped lang="scss"> | ||||
* { | |||||
box-sizing: border-box; | |||||
} | |||||
* { | |||||
box-sizing: border-box; | |||||
} | |||||
.container { | |||||
display: flex; | |||||
flex-direction: column; | |||||
align-items: center; | |||||
justify-content: center; | |||||
//height: 100vh; | |||||
background-color: #f5f5f5; | |||||
.container { | |||||
display: flex; | |||||
flex-direction: column; | |||||
align-items: center; | |||||
justify-content: center; | |||||
//height: 100vh; | |||||
background-color: #f5f5f5; | |||||
.title { | |||||
font-size: 40rpx; | |||||
color: #333; | |||||
margin: 80rpx 0; | |||||
} | |||||
.title { | |||||
font-size: 40rpx; | |||||
color: #333; | |||||
margin: 80rpx 0; | |||||
} | |||||
.button-group { | |||||
display: flex; | |||||
flex-direction: column; | |||||
align-items: center; | |||||
justify-content: center; | |||||
.button-group { | |||||
display: flex; | |||||
flex-direction: column; | |||||
align-items: center; | |||||
justify-content: center; | |||||
width: 100vw; | |||||
//padding: 0 20px; | |||||
width: 100vw; | |||||
//padding: 0 20px; | |||||
.identity-button { | |||||
display: flex; | |||||
align-items: center; | |||||
justify-content: space-between; | |||||
width: 80%; | |||||
margin-bottom: 40rpx; | |||||
padding: 40rpx 50rpx; | |||||
background-color: #2d2f59; | |||||
border-radius: 20rpx; | |||||
color: white; | |||||
.identity-button { | |||||
display: flex; | |||||
align-items: center; | |||||
justify-content: space-between; | |||||
width: 80%; | |||||
margin-bottom: 40rpx; | |||||
padding: 40rpx 50rpx; | |||||
background-color: #2d2f59; | |||||
border-radius: 20rpx; | |||||
color: white; | |||||
.identity-text { | |||||
font-size: 40rpx; | |||||
} | |||||
.identity-text { | |||||
font-size: 40rpx; | |||||
} | |||||
.identity-icon { | |||||
width: 130rpx; | |||||
height: 130rpx; | |||||
} | |||||
} | |||||
} | |||||
} | |||||
.identity-icon { | |||||
width: 130rpx; | |||||
height: 130rpx; | |||||
} | |||||
} | |||||
} | |||||
} | |||||
</style> | </style> |
@ -1,221 +1,239 @@ | |||||
<template> | <template> | ||||
<view class="page"> | |||||
<navbar :title="$t('components.helpFeedback')" leftClick @leftClick="$utils.navigateBack"/> | |||||
<view class="frame"> | |||||
<!--帮助与反馈--> | |||||
<view class="helpFeedback"> | |||||
<view class="title"> {{ $t('components.helpAndFeedback') }} <span style="color: red;">*</span></view> | |||||
<view class="desc"> | |||||
<textarea :placeholder="$t('components.pleaseSubmit')"/> | |||||
</view> | |||||
</view> | |||||
<!--问题截图--> | |||||
<view class="problemImg"> | |||||
<view class="title">{{ $t('components.screenshot') }} <span style="color: red;">*</span></view> | |||||
<view class="img"> | |||||
<uv-upload | |||||
:fileList="fileList" | |||||
:maxCount="5" | |||||
multiple | |||||
width="150rpx" | |||||
height="150rpx" | |||||
@delete="deleteImage" | |||||
@afterRead="afterRead" | |||||
:previewFullImage="true"> | |||||
</uv-upload> | |||||
</view> | |||||
</view> | |||||
<!--联系方式--> | |||||
<view class="name_phone"> | |||||
<view class="title">{{ $t('components.contactInfo') }} <span style="color: red;">*</span></view> | |||||
<view class="items"> | |||||
<view class="item"> | |||||
<view>{{ $t('components.contactName') }}</view> | |||||
<view> | |||||
<input :placeholder="$t('components.enterContactName')" clearable></input> | |||||
</view> | |||||
</view> | |||||
<view class="item"> | |||||
<view>{{ $t('components.lxPhone') }}</view> | |||||
<view> | |||||
<input :placeholder="$t('components.plePhoneNumber')" clearable></input> | |||||
</view> | |||||
</view> | |||||
</view> | |||||
</view> | |||||
<!--提交反馈--> | |||||
<view class="btns"> | |||||
<view @click="submitFeedback" class="btn"> | |||||
{{ $t('components.submitFeedback') }} | |||||
</view> | |||||
</view> | |||||
</view> | |||||
</view> | |||||
<view class="page"> | |||||
<navbar :title="$t('components.helpFeedback')" leftClick @leftClick="$utils.navigateBack" /> | |||||
<view class="frame"> | |||||
<!--帮助与反馈--> | |||||
<view class="helpFeedback"> | |||||
<view class="title"> {{ $t('components.helpAndFeedback') }} <span style="color: red;">*</span></view> | |||||
<view class="desc"> | |||||
<textarea :placeholder="$t('components.pleaseSubmit')" v-model="form.content"/> | |||||
</view> | |||||
</view> | |||||
<!--问题截图--> | |||||
<view class="problemImg"> | |||||
<view class="title">{{ $t('components.screenshot') }} <span style="color: red;">*</span></view> | |||||
<view class="img"> | |||||
<uv-upload :fileList="fileList" :maxCount="5" multiple width="150rpx" height="150rpx" | |||||
@delete="deleteImage" @afterRead="afterRead" :previewFullImage="true"> | |||||
</uv-upload> | |||||
</view> | |||||
</view> | |||||
<!--联系方式--> | |||||
<view class="name_phone"> | |||||
<view class="title">{{ $t('components.contactInfo') }} <span style="color: red;">*</span></view> | |||||
<view class="items"> | |||||
<view class="item"> | |||||
<view>{{ $t('components.contactName') }}</view> | |||||
<view> | |||||
<input :placeholder="$t('components.enterContactName')" clearable v-model="form.userName"></input> | |||||
</view> | |||||
</view> | |||||
<view class="item"> | |||||
<view>{{ $t('components.lxPhone') }}</view> | |||||
<view> | |||||
<input :placeholder="$t('components.plePhoneNumber')" clearable v-model="form.userPhone"></input> | |||||
</view> | |||||
</view> | |||||
</view> | |||||
</view> | |||||
<!--提交反馈--> | |||||
<view class="btns"> | |||||
<view @click="submitFeedback" class="btn"> | |||||
{{ $t('components.submitFeedback') }} | |||||
</view> | |||||
</view> | |||||
</view> | |||||
</view> | |||||
</template> | </template> | ||||
<script> | <script> | ||||
import topbar from "@/components/base/topbar.vue"; | |||||
import tabber from "@/components/base/tabbar.vue"; | |||||
export default { | |||||
name: "helpFeedback", | |||||
components: {tabber, topbar}, | |||||
data() { | |||||
return { | |||||
fileList: [], | |||||
form: { | |||||
"content": "", | |||||
"proofImg": "", | |||||
"userName": "", | |||||
"userPhone": "" | |||||
} | |||||
} | |||||
}, | |||||
methods: { | |||||
// 提交反馈 | |||||
submitFeedback() { | |||||
this.form.proofImg = this.fileList.join(",") | |||||
this.$api('addSuggest', this.form, res => { | |||||
if (res.code === 200) { | |||||
uni.showToast({ | |||||
title: '', | |||||
icon: 'success', | |||||
duration: 2000 | |||||
}) | |||||
setTimeout(() => { | |||||
uni.navigateBack(-1) | |||||
}, 1000) | |||||
} | |||||
}) | |||||
}, | |||||
deleteImage(e) { | |||||
this.fileList.splice(e.index, 1) | |||||
}, | |||||
afterRead(e) { | |||||
let self = this | |||||
e.file.forEach(file => { | |||||
self.$Oss.ossUpload(file.url).then(url => { | |||||
self.fileList.push({ | |||||
url | |||||
}) | |||||
}) | |||||
}) | |||||
}, | |||||
}, | |||||
} | |||||
import topbar from "@/components/base/topbar.vue"; | |||||
import tabber from "@/components/base/tabbar.vue"; | |||||
export default { | |||||
name: "helpFeedback", | |||||
components: { | |||||
tabber, | |||||
topbar | |||||
}, | |||||
data() { | |||||
return { | |||||
fileList: [], | |||||
form: { | |||||
"content": "", | |||||
"proofImg": "", | |||||
"userName": "", | |||||
"userPhone": "" | |||||
} | |||||
} | |||||
}, | |||||
methods: { | |||||
// 提交反馈 | |||||
// submitFeedback() { | |||||
// this.form.proofImg = this.fileList.join(",") | |||||
// this.$api('addSuggest', this.form, res => { | |||||
// if (res.code === 200) { | |||||
// uni.showToast({ | |||||
// title: '', | |||||
// icon: 'success', | |||||
// duration: 2000 | |||||
// }) | |||||
// setTimeout(() => { | |||||
// uni.navigateBack(-1) | |||||
// }, 1000) | |||||
// } | |||||
// }) | |||||
// }, | |||||
submitFeedback(){ | |||||
let data = JSON.parse(JSON.stringify(this.form)) | |||||
data.proofImg = this.fileList.map((item) => item.url).join(",") | |||||
if(this.$utils.verificationAll(data, { | |||||
content : this.$t('components.pleaseSubmit'),//问题和意见 | |||||
proofImg : this.$t('components.screenshot'),// | |||||
userName : this.$t('components.enterContactName'),// | |||||
userPhone : this.$t('components.plePhoneNumber'),//手机号码 | |||||
})){ | |||||
return | |||||
} | |||||
this.$api('addSuggest', data, res => { | |||||
if(res.code == 200){ | |||||
uni.showToast({ | |||||
title: res.message, | |||||
icon:'none' | |||||
}) | |||||
setTimeout(uni.navigateBack, 800, -1) | |||||
} | |||||
}) | |||||
}, | |||||
deleteImage(e) { | |||||
this.fileList.splice(e.index, 1) | |||||
}, | |||||
afterRead(e) { | |||||
let self = this | |||||
e.file.forEach(file => { | |||||
self.$Oss.ossUpload(file.url).then(url => { | |||||
self.fileList.push({ | |||||
url | |||||
}) | |||||
}) | |||||
}) | |||||
}, | |||||
}, | |||||
} | |||||
</script> | </script> | ||||
<style scoped lang="scss"> | <style scoped lang="scss"> | ||||
.page { | |||||
height: 100vh; | |||||
background-color: #f2f5f5; | |||||
.frame { | |||||
padding: 40rpx; | |||||
display: flex; | |||||
flex-direction: column; | |||||
justify-content: center; | |||||
gap: 40rpx; | |||||
.helpFeedback { | |||||
.title { | |||||
} | |||||
.desc { | |||||
margin-top: 20rpx; | |||||
height: 300rpx; | |||||
border-radius: 40rpx; | |||||
overflow: hidden; | |||||
padding: 20rpx; | |||||
font-size: 28rpx; | |||||
background-color: #fff; | |||||
} | |||||
} | |||||
.problemImg { | |||||
.img { | |||||
margin-top: 20rpx; | |||||
height: 150rpx; | |||||
border-radius: 40rpx; | |||||
overflow: hidden; | |||||
padding: 20rpx; | |||||
font-size: 28rpx; | |||||
background-color: #fff; | |||||
} | |||||
} | |||||
.name_phone { | |||||
.title { | |||||
} | |||||
.items { | |||||
margin-top: 20rpx; | |||||
.item { | |||||
display: flex; | |||||
align-items: center; | |||||
background-color: #FFF; | |||||
height: 80rpx; | |||||
padding: 10rpx 0 0 20rpx; | |||||
border-bottom: 1px solid #efefef; | |||||
> view:nth-of-type(1) { | |||||
width: 30%; | |||||
// font-weight: 700; | |||||
} | |||||
> view:nth-of-type(2) { | |||||
width: 70%; | |||||
border-radius: 10rpx; | |||||
overflow: hidden; | |||||
input { | |||||
background-color: #FFF; | |||||
font-size: 28rpx; | |||||
padding: 16rpx 8rpx 16rpx 15rpx; | |||||
} | |||||
} | |||||
} | |||||
} | |||||
} | |||||
.btns { | |||||
width: 100%; | |||||
display: flex; | |||||
flex-direction: column; | |||||
align-items: center; | |||||
justify-content: center; | |||||
gap: 20rpx; | |||||
.btn { | |||||
display: flex; | |||||
align-items: center; | |||||
justify-content: center; | |||||
width: 500rpx; | |||||
height: 70rpx; | |||||
border-radius: 40rpx; | |||||
color: #FFF; | |||||
font-size: 28rpx; | |||||
margin: 20rpx 10rpx 0 0; | |||||
background: $uni-color; | |||||
//margin-top: 20rpx; | |||||
border-radius: 40rpx; | |||||
} | |||||
} | |||||
} | |||||
} | |||||
.page { | |||||
height: 100vh; | |||||
background-color: #f2f5f5; | |||||
.frame { | |||||
padding: 40rpx; | |||||
display: flex; | |||||
flex-direction: column; | |||||
justify-content: center; | |||||
gap: 40rpx; | |||||
.helpFeedback { | |||||
.title {} | |||||
.desc { | |||||
margin-top: 20rpx; | |||||
height: 300rpx; | |||||
border-radius: 40rpx; | |||||
overflow: hidden; | |||||
padding: 20rpx; | |||||
font-size: 28rpx; | |||||
background-color: #fff; | |||||
} | |||||
} | |||||
.problemImg { | |||||
.img { | |||||
margin-top: 20rpx; | |||||
height: 150rpx; | |||||
border-radius: 40rpx; | |||||
overflow: hidden; | |||||
padding: 20rpx; | |||||
font-size: 28rpx; | |||||
background-color: #fff; | |||||
} | |||||
} | |||||
.name_phone { | |||||
.title {} | |||||
.items { | |||||
margin-top: 20rpx; | |||||
.item { | |||||
display: flex; | |||||
align-items: center; | |||||
background-color: #FFF; | |||||
height: 80rpx; | |||||
padding: 10rpx 0 0 20rpx; | |||||
border-bottom: 1px solid #efefef; | |||||
>view:nth-of-type(1) { | |||||
width: 30%; | |||||
// font-weight: 700; | |||||
} | |||||
>view:nth-of-type(2) { | |||||
width: 70%; | |||||
border-radius: 10rpx; | |||||
overflow: hidden; | |||||
input { | |||||
background-color: #FFF; | |||||
font-size: 28rpx; | |||||
padding: 16rpx 8rpx 16rpx 15rpx; | |||||
} | |||||
} | |||||
} | |||||
} | |||||
} | |||||
.btns { | |||||
width: 100%; | |||||
display: flex; | |||||
flex-direction: column; | |||||
align-items: center; | |||||
justify-content: center; | |||||
gap: 20rpx; | |||||
.btn { | |||||
display: flex; | |||||
align-items: center; | |||||
justify-content: center; | |||||
width: 500rpx; | |||||
height: 70rpx; | |||||
border-radius: 40rpx; | |||||
color: #FFF; | |||||
font-size: 28rpx; | |||||
margin: 20rpx 10rpx 0 0; | |||||
background: $uni-color; | |||||
//margin-top: 20rpx; | |||||
border-radius: 40rpx; | |||||
} | |||||
} | |||||
} | |||||
} | |||||
</style> | </style> |
@ -1,138 +1,180 @@ | |||||
<template> | <template> | ||||
<view class="page"> | |||||
<navbar :title="$t('pageTitle.systemSettings')" leftClick @leftClick="$utils.navigateBack"/> | |||||
<view class="frame"> | |||||
<view class="content" v-for="(item, index) in list" :key="index"> | |||||
<view class="title">{{ item.title }}</view> | |||||
<view class="item" v-for="(item2, index) in item.itemList" :key="index" @click="tapItem(item2, index)"> | |||||
<view class="key"> | |||||
<view class="img"> | |||||
<img :src="item2.leftIcon" style="width: 100%; height: 100%;"/> | |||||
</view> | |||||
<view class="text"> | |||||
{{ item2.text }} | |||||
</view> | |||||
</view> | |||||
<view class="value"> | |||||
{{ item.rightIcon }} | |||||
</view> | |||||
</view> | |||||
</view> | |||||
</view> | |||||
<!-- 语言切换 --> | |||||
<!--<view style="padding: 20rpx;"--> | |||||
<!-- @click="$refs.changeLanguage.open()">--> | |||||
<!-- {{ $t('pages.index.index.language') }}--> | |||||
<!--</view>--> | |||||
<changeLanguage ref="changeLanguage"/> | |||||
</view> | |||||
<view class="page"> | |||||
<navbar :title="$t('pageTitle.systemSettings')" leftClick @leftClick="$utils.navigateBack" /> | |||||
<view class="frame"> | |||||
<view class="content" v-for="(item, index) in list" :key="index"> | |||||
<view class="title">{{ item.title }}</view> | |||||
<view class="item" v-for="(item2, index) in item.itemList" :key="index" @click="tapItem(item2, index)"> | |||||
<view class="key"> | |||||
<view class="img"> | |||||
<img :src="item2.leftIcon" style="width: 100%; height: 100%;" /> | |||||
</view> | |||||
<view class="text"> | |||||
{{ item2.text }} | |||||
</view> | |||||
</view> | |||||
<view class="value"> | |||||
{{ item.rightIcon }} | |||||
</view> | |||||
</view> | |||||
</view> | |||||
</view> | |||||
<!-- 语言切换 --> | |||||
<!--<view style="padding: 20rpx;"--> | |||||
<!-- @click="$refs.changeLanguage.open()">--> | |||||
<!-- {{ $t('pages.index.index.language') }}--> | |||||
<!--</view>--> | |||||
<changeLanguage ref="changeLanguage" /> | |||||
</view> | |||||
</template> | </template> | ||||
<script> | <script> | ||||
import topbar from "@/components/base/topbar.vue"; | |||||
import tabber from "@/components/base/tabbar.vue"; | |||||
import ChangeLanguage from "@/components/base/changeLanguage.vue"; | |||||
import {navigateTo} from "@/utils/utils"; | |||||
export default { | |||||
name: "systemSet", | |||||
components: {ChangeLanguage, tabber, topbar}, | |||||
data() { | |||||
return { | |||||
list: [ | |||||
{ | |||||
title: `${this.$t('pageTitle.accountSetting')}`, | |||||
itemList: [ | |||||
// text: `${this.$t('pageTitle.switchAccount')}` | |||||
{leftIcon: "../../static/image/center/1.svg", text: `${this.$t('pageTitle.switchAccount')}`, rightIcon: ">"}, | |||||
{leftIcon: "../../static/image/center/2.svg", text: `${this.$t('pageTitle.changePassword')}`, rightIcon: ">"}, | |||||
{leftIcon: "../../static/image/center/3.svg", text: this.$t('pageTitle.logout'), rightIcon: ">"}, | |||||
{leftIcon: "../../static/image/center/4.svg", text: this.$t('pageTitle.addressList'), rightIcon: ">",toUrl:'/pages_order/center/addressListManage'}, | |||||
] | |||||
}, | |||||
{ | |||||
title: `${this.$t('pageTitle.systemSetting')}`, | |||||
itemList: [ | |||||
{leftIcon: "../../static/image/center/1.svg", text: `${this.$t('pageTitle.languageSwitch')}`, rightIcon: ">"}, | |||||
{leftIcon: "../../static/image/center/2.svg", text: `${this.$t('pageTitle.versionUpdate')}`, rightIcon: ">"}, | |||||
{leftIcon: "../../static/image/center/3.svg", text: this.$t('pageTitle.clearCache'), rightIcon: ">"}, | |||||
] | |||||
}, | |||||
{ | |||||
title: `${this.$t('pageTitle.identitySetting')}`, | |||||
itemList: [ | |||||
{leftIcon: "../../static/image/center/1.svg", text: this.$t('pageTitle.switchIdentity'), rightIcon: ">"}, | |||||
] | |||||
} | |||||
], | |||||
} | |||||
}, | |||||
methods: { | |||||
tapItem(item, index) { | |||||
if (item.text === this.$t('pageTitle.languageSwitch')) { | |||||
this.$refs.changeLanguage.open(); | |||||
} | |||||
uni.navigateTo({ | |||||
url: item.toUrl | |||||
}) | |||||
} | |||||
}, | |||||
} | |||||
import topbar from "@/components/base/topbar.vue"; | |||||
import tabber from "@/components/base/tabbar.vue"; | |||||
import ChangeLanguage from "@/components/base/changeLanguage.vue"; | |||||
import { | |||||
navigateTo | |||||
} from "@/utils/utils"; | |||||
export default { | |||||
name: "systemSet", | |||||
components: { | |||||
ChangeLanguage, | |||||
tabber, | |||||
topbar | |||||
}, | |||||
data() { | |||||
return { | |||||
list: [{ | |||||
title: `${this.$t('pageTitle.accountSetting')}`, | |||||
itemList: [ | |||||
// text: `${this.$t('pageTitle.switchAccount')}` | |||||
{ | |||||
leftIcon: "../../static/image/center/1.svg", | |||||
text: `${this.$t('pageTitle.switchAccount')}`, | |||||
rightIcon: ">" | |||||
}, | |||||
{ | |||||
leftIcon: "../../static/image/center/2.svg", | |||||
text: `${this.$t('pageTitle.changePassword')}`, | |||||
rightIcon: ">" | |||||
}, | |||||
{ | |||||
leftIcon: "../../static/image/center/3.svg", | |||||
text: this.$t('pageTitle.logout'), | |||||
rightIcon: ">", | |||||
type : 'logout', | |||||
}, | |||||
{ | |||||
leftIcon: "../../static/image/center/4.svg", | |||||
text: this.$t('pageTitle.addressList'), | |||||
rightIcon: ">", | |||||
toUrl: '/pages_order/center/addressListManage' | |||||
}, | |||||
] | |||||
}, | |||||
{ | |||||
title: `${this.$t('pageTitle.systemSetting')}`, | |||||
itemList: [{ | |||||
leftIcon: "../../static/image/center/1.svg", | |||||
text: `${this.$t('pageTitle.languageSwitch')}`, | |||||
rightIcon: ">" | |||||
}, | |||||
{ | |||||
leftIcon: "../../static/image/center/2.svg", | |||||
text: `${this.$t('pageTitle.versionUpdate')}`, | |||||
rightIcon: ">" | |||||
}, | |||||
{ | |||||
leftIcon: "../../static/image/center/3.svg", | |||||
text: this.$t('pageTitle.clearCache'), | |||||
rightIcon: ">" | |||||
}, | |||||
] | |||||
}, | |||||
{ | |||||
title: `${this.$t('pageTitle.identitySetting')}`, | |||||
itemList: [{ | |||||
leftIcon: "../../static/image/center/1.svg", | |||||
text: this.$t('pageTitle.switchIdentity'), | |||||
rightIcon: ">" | |||||
}, ] | |||||
} | |||||
], | |||||
} | |||||
}, | |||||
methods: { | |||||
tapItem(item, index) { | |||||
if (item.text === this.$t('pageTitle.languageSwitch')) { | |||||
this.$refs.changeLanguage.open(); | |||||
}else if(item.type){ | |||||
this[item.type]() | |||||
}else{ | |||||
uni.navigateTo({ | |||||
url: item.toUrl | |||||
}) | |||||
} | |||||
}, | |||||
logout(){ | |||||
this.$store.commit('logout') | |||||
}, | |||||
}, | |||||
} | |||||
</script> | </script> | ||||
<style scoped lang="scss"> | <style scoped lang="scss"> | ||||
.page { | |||||
background-color: #FFF; | |||||
height: 100vh; | |||||
.frame { | |||||
padding: 40rpx; | |||||
.content { | |||||
margin-bottom: 40rpx; | |||||
.title { | |||||
font-size: 30rpx; | |||||
color: #b0b0b0; | |||||
} | |||||
.item { | |||||
display: flex; | |||||
justify-content: space-between; | |||||
align-items: center; | |||||
padding: 20rpx 40rpx; | |||||
.key { | |||||
display: flex; | |||||
justify-content: center; | |||||
align-items: center; | |||||
color: #333333; | |||||
font-size: 32rpx; | |||||
.img { | |||||
width: 40rpx; | |||||
height: 40rpx; | |||||
} | |||||
.text { | |||||
margin-left: 20rpx; | |||||
} | |||||
} | |||||
.value { | |||||
color: #999999; | |||||
font-size: 36rpx; | |||||
} | |||||
} | |||||
} | |||||
} | |||||
} | |||||
.page { | |||||
background-color: #FFF; | |||||
height: 100vh; | |||||
.frame { | |||||
padding: 40rpx; | |||||
.content { | |||||
margin-bottom: 40rpx; | |||||
.title { | |||||
font-size: 30rpx; | |||||
color: #b0b0b0; | |||||
} | |||||
.item { | |||||
display: flex; | |||||
justify-content: space-between; | |||||
align-items: center; | |||||
padding: 20rpx 40rpx; | |||||
.key { | |||||
display: flex; | |||||
justify-content: center; | |||||
align-items: center; | |||||
color: #333333; | |||||
font-size: 32rpx; | |||||
.img { | |||||
width: 40rpx; | |||||
height: 40rpx; | |||||
} | |||||
.text { | |||||
margin-left: 20rpx; | |||||
} | |||||
} | |||||
.value { | |||||
color: #999999; | |||||
font-size: 36rpx; | |||||
} | |||||
} | |||||
} | |||||
} | |||||
} | |||||
</style> | </style> |