|
@@ -8,29 +8,29 @@
|
|
|
@on-error="uploadError" max-count="1"></u-upload>
|
|
|
</view>
|
|
|
</u-cell-item>
|
|
|
- <u-cell-item title="请上传店铺主图(0/3)" :arrow="false">
|
|
|
+ <u-cell-item title="请上传店铺主图(0/3)" :arrow="false" class="all-width">
|
|
|
<view slot="label">
|
|
|
<u-upload :action="uploadUrl" :file-list="defaultList2" :form-data="uploadData" @on-success="uploadSuccess"
|
|
|
@on-error="uploadError" @on-remove="uploadRemove" max-count="3"></u-upload>
|
|
|
</view>
|
|
|
</u-cell-item>
|
|
|
- <u-cell-item title="请上传身份证正反面" :arrow="false">
|
|
|
+ <u-cell-item title="请上传身份证正反面" :arrow="false" class="all-width">
|
|
|
<view slot="label" class="id-card-box">
|
|
|
<u-upload :action="uploadUrl" :file-list="defaultList3" :form-data="uploadData" @on-success="uploadIdCardSuccess1"
|
|
|
- @on-error="uploadError" :custom-btn="true" max-count="1">
|
|
|
- <view slot="addBtn" class="id-card card-img1">拍摄正面</view>
|
|
|
+ @on-error="uploadError" :custom-btn="true" max-count="1" :style="{width: cWidth + 'px'}">
|
|
|
+ <view slot="addBtn" class="id-card card-img1" :style="{width: cWidth + 'px'}">拍摄正面</view>
|
|
|
</u-upload>
|
|
|
<u-upload :action="uploadUrl" :file-list="defaultList4" :form-data="uploadData" @on-success="uploadIdCardSuccess2"
|
|
|
- @on-error="uploadError" :custom-btn="true" max-count="1">
|
|
|
- <view slot="addBtn" class="id-card card-img1">拍摄反面</view>
|
|
|
+ @on-error="uploadError" :custom-btn="true" max-count="1" :style="{width: cWidth + 'px'}">
|
|
|
+ <view slot="addBtn" class="id-card card-img1" :style="{width: cWidth + 'px'}">拍摄反面</view>
|
|
|
</u-upload>
|
|
|
</view>
|
|
|
</u-cell-item>
|
|
|
- <u-cell-item title="请上传营业执照照片" :arrow="false">
|
|
|
+ <u-cell-item title="请上传营业执照照片" :arrow="false" class="all-width">
|
|
|
<view slot="label" class="license-box">
|
|
|
<u-upload :action="uploadUrl" :file-list="defaultList5" :form-data="uploadData" @on-success="uploadLicenseSuccess"
|
|
|
- @on-error="uploadError" :custom-btn="true" max-count="1">
|
|
|
- <view slot="addBtn" class="license-img"></view>
|
|
|
+ @on-error="uploadError" :custom-btn="true" max-count="1" class="diy-upload">
|
|
|
+ <image slot="addBtn" class="license-img" src="../../static/images/license-img.png"></image>
|
|
|
</u-upload>
|
|
|
<view class="license-text"> 营业执照</view>
|
|
|
</view>
|
|
@@ -59,6 +59,7 @@
|
|
|
export default {
|
|
|
data() {
|
|
|
return {
|
|
|
+ cWidth: 0,
|
|
|
type: '',
|
|
|
shopInfo: {
|
|
|
name: '',
|
|
@@ -90,6 +91,7 @@
|
|
|
}
|
|
|
},
|
|
|
onLoad(options) {
|
|
|
+ this.cWidth = (uni.upx2px(750) - 40) / 2;
|
|
|
this.uploadUrl = API.uploadFile
|
|
|
this.type = options.type
|
|
|
if (options.type == 'edit') {
|
|
@@ -225,7 +227,8 @@
|
|
|
NET.request(API.editShopRegisterInfo, {
|
|
|
...this.shopInfo,
|
|
|
address: this.shopInfo.companyAddressProvince + '-' + this.shopInfo.companyAddressCity + '-' + this.shopInfo.companyAddressDistrict,
|
|
|
- companyAddress: this.shopInfo.companyAddressProvince + '-' + this.shopInfo.companyAddressCity + '-' + this.shopInfo.companyAddressDistrict,
|
|
|
+ companyAddress: this.shopInfo.companyAddressProvince + '-' + this.shopInfo.companyAddressCity + '-' + this.shopInfo
|
|
|
+ .companyAddressDistrict,
|
|
|
storeImgUrl: this.fileList.join(',')
|
|
|
}, 'PUT').then(res => {
|
|
|
this.$refs.uTips.show({
|
|
@@ -233,7 +236,7 @@
|
|
|
type: 'success',
|
|
|
})
|
|
|
setTimeout(() => {
|
|
|
- uni.switchTab({
|
|
|
+ uni.redirectTo({
|
|
|
url: '/pages/index/registerState'
|
|
|
});
|
|
|
}, 1000)
|
|
@@ -247,7 +250,8 @@
|
|
|
NET.request(API.submitShopRegisterInfo, {
|
|
|
...this.shopInfo,
|
|
|
address: this.shopInfo.companyAddressProvince + '-' + this.shopInfo.companyAddressCity + '-' + this.shopInfo.companyAddressDistrict,
|
|
|
- companyAddress: this.shopInfo.companyAddressProvince + '-' + this.shopInfo.companyAddressCity + '-' + this.shopInfo.companyAddressDistrict,
|
|
|
+ companyAddress: this.shopInfo.companyAddressProvince + '-' + this.shopInfo.companyAddressCity + '-' + this.shopInfo
|
|
|
+ .companyAddressDistrict,
|
|
|
storeImgUrl: this.fileList.join(',')
|
|
|
}, 'POST').then(res => {
|
|
|
this.$refs.uTips.show({
|
|
@@ -255,7 +259,7 @@
|
|
|
type: 'success',
|
|
|
})
|
|
|
setTimeout(() => {
|
|
|
- uni.navigateTo({
|
|
|
+ uni.redirectTo({
|
|
|
url: '/pages/index/registerState'
|
|
|
});
|
|
|
}, 1000)
|
|
@@ -299,13 +303,12 @@
|
|
|
display: flex;
|
|
|
|
|
|
.id-card {
|
|
|
- width: 164px;
|
|
|
height: 140px;
|
|
|
+ margin-right: 10px;
|
|
|
box-sizing: border-box;
|
|
|
padding-top: 110px;
|
|
|
- margin-right: 14px;
|
|
|
background-color: #51A539;
|
|
|
- background-size: 164px 110px;
|
|
|
+ background-size: 100% 110px;
|
|
|
background-position: center top;
|
|
|
background-repeat: no-repeat;
|
|
|
border-radius: 6px;
|
|
@@ -325,30 +328,36 @@
|
|
|
}
|
|
|
|
|
|
/deep/.u-list-item {
|
|
|
- width: 164px !important;
|
|
|
+ width: 100% !important;
|
|
|
height: 110px !important;
|
|
|
}
|
|
|
}
|
|
|
|
|
|
.license-box {
|
|
|
+ width: 100%;
|
|
|
+ height: 175px;
|
|
|
+ position: relative;
|
|
|
+
|
|
|
+ .diy-upload {
|
|
|
+ width: 100%;
|
|
|
+ height: 145px;
|
|
|
+ position: absolute;
|
|
|
+ }
|
|
|
|
|
|
.license-img {
|
|
|
- width: 345px;
|
|
|
+ width: 100%;
|
|
|
height: 145px;
|
|
|
- background-size: 345px 145px;
|
|
|
- background-position: center top;
|
|
|
- background-repeat: no-repeat;
|
|
|
- background-image: url(@/static/images/license-img.png);
|
|
|
+ position: absolute;
|
|
|
}
|
|
|
|
|
|
/deep/.u-list-item {
|
|
|
- width: 345px !important;
|
|
|
+ width: 100% !important;
|
|
|
height: 145px !important;
|
|
|
}
|
|
|
}
|
|
|
|
|
|
.license-text {
|
|
|
- width: 345px;
|
|
|
+ width: 100%;
|
|
|
height: 30px;
|
|
|
margin-top: 5px;
|
|
|
font-size: 15px;
|
|
@@ -356,6 +365,8 @@
|
|
|
color: #656565;
|
|
|
line-height: 30px;
|
|
|
text-align: center;
|
|
|
+ position: relative;
|
|
|
+ top: 145px;
|
|
|
}
|
|
|
}
|
|
|
|
|
@@ -375,4 +386,10 @@
|
|
|
// }
|
|
|
}
|
|
|
}
|
|
|
+
|
|
|
+ .all-width {
|
|
|
+ /deep/.u-cell_title {
|
|
|
+ width: 100% !important;
|
|
|
+ }
|
|
|
+ }
|
|
|
</style>
|