|
@@ -55,11 +55,20 @@
|
|
|
<view class="div" slot="right">
|
|
|
<view class="div user-avatar-wrapper">
|
|
|
<view class="div user-avatar">
|
|
|
- <uni-file-picker class="common-avatar" v-model="imageValue" fileMediatype="image" mode="grid" :limit="1" :auto-upload="false" @select="uploadImage" @delete="dropImage()" :image-styles="{
|
|
|
+ <uni-file-picker
|
|
|
+ class="common-avatar"
|
|
|
+ v-model="business_licence_number_electronic_lsit"
|
|
|
+ fileMediatype="image"
|
|
|
+ mode="grid"
|
|
|
+ :limit="1"
|
|
|
+ :auto-upload="false"
|
|
|
+ @select="uploadSelectImg('business_licence_number_electronic', $event)"
|
|
|
+ @delete="dropImage('business_licence_number_electronic')"
|
|
|
+ :image-styles="{
|
|
|
width:'200px',
|
|
|
height:'160px',
|
|
|
- }"></uni-file-picker>
|
|
|
- </view>
|
|
|
+ }"></uni-file-picker>
|
|
|
+ </view>
|
|
|
</view>
|
|
|
</view>
|
|
|
</flex-line>
|
|
@@ -72,11 +81,21 @@
|
|
|
<view class="div" slot="right">
|
|
|
<view class="div user-avatar-wrapper">
|
|
|
<view class="div user-avatar">
|
|
|
- <uni-file-picker class="common-avatar" v-model="imageValue1" fileMediatype="image" mode="grid" :limit="1" :auto-upload="false" @select="uploadImage1" @delete="dropImage1()" :image-styles="{
|
|
|
- width:'200px',
|
|
|
- height:'160px',
|
|
|
- }"></uni-file-picker>
|
|
|
- </view>
|
|
|
+ <uni-file-picker
|
|
|
+ class="common-avatar"
|
|
|
+ v-model="business_author_letter_list"
|
|
|
+ fileMediatype="image"
|
|
|
+ mode="grid"
|
|
|
+ :limit="1"
|
|
|
+ :auto-upload="false"
|
|
|
+ @select="uploadSelectImg('business_author_letter', $event)"
|
|
|
+ @delete="dropImage('business_author_letter')"
|
|
|
+ :image-styles="{
|
|
|
+ width:'200px',
|
|
|
+ height:'160px',
|
|
|
+ }">
|
|
|
+ </uni-file-picker>
|
|
|
+ </view>
|
|
|
</view>
|
|
|
|
|
|
</view>
|
|
@@ -112,8 +131,8 @@
|
|
|
</view>
|
|
|
</view>
|
|
|
</uni-popup>
|
|
|
- <tui-picture-cropper v-if="cropperOption.imgUrl" :width="cropperOption.autoCropWidth" :height="cropperOption.autoCropHeight" :imageUrl="cropperOption.img" @ready="cropReady" @cropper="useCrop" @back="cropBack"></tui-picture-cropper>
|
|
|
- <tui-picture-cropper v-if="cropperOption1.imgUrl" :width="cropperOption1.autoCropWidth" :height="cropperOption1.autoCropHeight" :imageUrl="cropperOption1.img" @ready="cropReady1" @cropper="useCrop1" @back="cropBack1"></tui-picture-cropper>
|
|
|
+ <!-- <tui-picture-cropper v-if="cropperOption.imgUrl" :width="cropperOption.autoCropWidth" :height="cropperOption.autoCropHeight" :imageUrl="cropperOption.img" @ready="cropReady" @cropper="useCrop" @back="cropBack"></tui-picture-cropper> -->
|
|
|
+ <!-- <tui-picture-cropper v-if="cropperOption1.imgUrl" :width="cropperOption1.autoCropWidth" :height="cropperOption1.autoCropHeight" :imageUrl="cropperOption1.img" @ready="cropReady1" @cropper="useCrop1" @back="cropBack1"></tui-picture-cropper> -->
|
|
|
</view>
|
|
|
</view></member-base>
|
|
|
</template>
|
|
@@ -142,28 +161,28 @@ export default {
|
|
|
data(){
|
|
|
return {
|
|
|
navHeight: 0,
|
|
|
- imageValue:[],
|
|
|
- imageValue1:[],
|
|
|
+ business_author_letter_list:[],
|
|
|
+ business_licence_number_electronic_lsit:[],
|
|
|
screenWidth:0,
|
|
|
screenHeight:0,
|
|
|
- cropperOption: {
|
|
|
- img: '',
|
|
|
- canMove: false,
|
|
|
- autoCrop: true,
|
|
|
- autoCropWidth: 100,
|
|
|
- autoCropHeight: 50,
|
|
|
- maxImgSize: 500,
|
|
|
- outputType: 'png'
|
|
|
- },
|
|
|
- cropperOption1: {
|
|
|
- img: '',
|
|
|
- canMove: false,
|
|
|
- autoCrop: true,
|
|
|
- autoCropWidth: 100,
|
|
|
- autoCropHeight: 50,
|
|
|
- maxImgSize: 500,
|
|
|
- outputType: 'png'
|
|
|
- },
|
|
|
+ // cropperOption: {
|
|
|
+ // img: '',
|
|
|
+ // canMove: false,
|
|
|
+ // autoCrop: true,
|
|
|
+ // autoCropWidth: 100,
|
|
|
+ // autoCropHeight: 50,
|
|
|
+ // maxImgSize: 500,
|
|
|
+ // outputType: 'png'
|
|
|
+ // },
|
|
|
+ // cropperOption1: {
|
|
|
+ // img: '',
|
|
|
+ // canMove: false,
|
|
|
+ // autoCrop: true,
|
|
|
+ // autoCropWidth: 100,
|
|
|
+ // autoCropHeight: 50,
|
|
|
+ // maxImgSize: 500,
|
|
|
+ // outputType: 'png'
|
|
|
+ // },
|
|
|
options: [{ title: '公司资质' }, { title: '财务资质' }, { title: '店铺信息' }, { title: '合同签订' }],
|
|
|
showimage: '',
|
|
|
selectData: '',
|
|
@@ -197,14 +216,14 @@ export default {
|
|
|
data = this.storeJoinin0
|
|
|
}
|
|
|
if(data.business_licence_number_electronic_url){
|
|
|
- this.imageValue = [{
|
|
|
+ this.business_licence_number_electronic_list = [{
|
|
|
name: 'business_licence_number_electronic',
|
|
|
extname: 'jpg',
|
|
|
url: data.business_licence_number_electronic_url
|
|
|
}]
|
|
|
}
|
|
|
if(data.business_author_letter_url){
|
|
|
- this.imageValue1 = [{
|
|
|
+ this.business_author_letter_list = [{
|
|
|
name: 'business_author_letter',
|
|
|
extname: 'jpg',
|
|
|
url: data.business_author_letter_url
|
|
@@ -279,7 +298,6 @@ export default {
|
|
|
sellerJoininSave: 'sellerJoininSave'
|
|
|
}),
|
|
|
nextStep () {
|
|
|
- console.log('this.storeJoinin' ,this.storeJoinin)
|
|
|
saveStoreJoinin2(this.storeJoinin).then(res => {
|
|
|
this.sellerJoininSave({ storeJoinin: this.storeJoinin })
|
|
|
uni.navigateTo({url:'/pages/member/sellerjoinin/Step3'})
|
|
@@ -333,105 +351,143 @@ export default {
|
|
|
loop:false,
|
|
|
})
|
|
|
},
|
|
|
- dropImage () {
|
|
|
- this.storeJoinin.business_licence_number_electronic = ''
|
|
|
+ dropImage (type) {
|
|
|
+ this.storeJoinin[type] = this.storeJoinin[type + '_url'] = ''
|
|
|
+ // 缓存也要清除下
|
|
|
this.$forceUpdate()
|
|
|
},
|
|
|
- dropImage1 () {
|
|
|
- this.storeJoinin.business_author_letter = ''
|
|
|
- this.$forceUpdate()
|
|
|
+ // dropImage1 () {
|
|
|
+ // this.storeJoinin.business_author_letter = ''
|
|
|
+ // this.$forceUpdate()
|
|
|
+ // },
|
|
|
+ // uploadImage(type,event) {
|
|
|
+ // var file = event.tempFiles[0]
|
|
|
+ // var that = this
|
|
|
+ // that.cropperOption.imgUrl = file.path
|
|
|
+ // that.cropperOption.autoCropWidth = uni.getSystemInfoSync().windowWidth
|
|
|
+ // that.cropperOption.autoCropHeight =( uni.getSystemInfoSync().windowWidth) * (this.storeJoinin.store_type==0 ? 1 :.63)
|
|
|
+ // that.cropperOption.maxImgSize = uni.getSystemInfoSync().windowHeight - 40
|
|
|
+ // that.$forceUpdate()
|
|
|
+ // },
|
|
|
+ uploadSelectImg(type,event){
|
|
|
+ const that = this
|
|
|
+ const file = event.tempFiles[0]
|
|
|
+ const formdata = {
|
|
|
+ filePath: file.path,
|
|
|
+ name: 'file'
|
|
|
+ }
|
|
|
+ uni.showLoading({
|
|
|
+ title: 'lodding....'
|
|
|
+ })
|
|
|
+ uploadInfoFile(formdata).then(res => {
|
|
|
+ that.storeJoinin[type] = res.result.path
|
|
|
+ that.storeJoinin[type + '_url'] = res.result.url
|
|
|
+
|
|
|
+ that[type + '_list'] = [{
|
|
|
+ name: type,
|
|
|
+ extname: 'jpg',
|
|
|
+ url: that.storeJoinin[type + '_url']
|
|
|
+ }]
|
|
|
+ // this.cropperOption.imgUrl = ''
|
|
|
+ that.$forceUpdate()
|
|
|
+ uni.hideLoading()
|
|
|
+ }).catch(function(error) {
|
|
|
+ uni.showToast({
|
|
|
+ icon: 'none',
|
|
|
+ title: error.message
|
|
|
+ })
|
|
|
+ uni.hideLoading()
|
|
|
+ // this.cropperOption.imgUrl = ''
|
|
|
+ that.$forceUpdate()
|
|
|
+ })
|
|
|
},
|
|
|
- uploadImage(event) {
|
|
|
- var file = event.tempFiles[0]
|
|
|
- var that = this
|
|
|
- that.cropperOption.imgUrl = file.path
|
|
|
- that.cropperOption.autoCropWidth = uni.getSystemInfoSync().windowWidth
|
|
|
- that.cropperOption.autoCropHeight =( uni.getSystemInfoSync().windowWidth) * (this.storeJoinin.store_type==0 ? 1 :.63)
|
|
|
- that.cropperOption.maxImgSize = uni.getSystemInfoSync().windowHeight - 40
|
|
|
- that.$forceUpdate()
|
|
|
- },
|
|
|
- uploadImage1(event) {
|
|
|
- var file = event.tempFiles[0]
|
|
|
- var that = this
|
|
|
- that.cropperOption1.imgUrl = file.path
|
|
|
- that.cropperOption1.autoCropWidth = uni.getSystemInfoSync().windowWidth
|
|
|
- that.cropperOption1.autoCropHeight = uni.getSystemInfoSync().windowWidth * (this.storeJoinin.store_type==0 ? 1.6 :.63)
|
|
|
- that.cropperOption1.maxImgSize =uni.getSystemInfoSync().windowHeight -40
|
|
|
- that.$forceUpdate()
|
|
|
- },
|
|
|
- useCrop(res) {
|
|
|
- var formdata = {
|
|
|
- filePath: res.url,
|
|
|
- name: 'file'
|
|
|
- }
|
|
|
- uni.showLoading({
|
|
|
- title: '加载中'
|
|
|
- })
|
|
|
- uploadInfoFile(formdata).then(res => {
|
|
|
- this.storeJoinin.business_licence_number_electronic = res.result.path
|
|
|
- this.storeJoinin.business_licence_number_electronic_url = res.result.url
|
|
|
- this.imageValue = [{
|
|
|
- name: 'business_licence_number_electronic',
|
|
|
- extname: 'jpg',
|
|
|
- url: this.storeJoinin.business_licence_number_electronic_url
|
|
|
- }]
|
|
|
- this.cropperOption.imgUrl = ''
|
|
|
- this.$forceUpdate()
|
|
|
- uni.hideLoading()
|
|
|
- }).catch(function(error) {
|
|
|
- uni.showToast({
|
|
|
- icon: 'none',
|
|
|
- title: error.message
|
|
|
- })
|
|
|
- uni.hideLoading()
|
|
|
- this.cropperOption.imgUrl = ''
|
|
|
- this.$forceUpdate()
|
|
|
- })
|
|
|
- },
|
|
|
+
|
|
|
+
|
|
|
+
|
|
|
+
|
|
|
+ // uploadImage1(event) {
|
|
|
+ // var file = event.tempFiles[0]
|
|
|
+ // console.log('这是我上传的图片',file)
|
|
|
+ // var that = this
|
|
|
+ // that.cropperOption1.imgUrl = file.path
|
|
|
+ // that.cropperOption1.autoCropWidth = uni.getSystemInfoSync().windowWidth
|
|
|
+ // that.cropperOption1.autoCropHeight = uni.getSystemInfoSync().windowWidth * (this.storeJoinin.store_type==0 ? 1.6 :.63)
|
|
|
+ // that.cropperOption1.maxImgSize =uni.getSystemInfoSync().windowHeight -40
|
|
|
+ // that.$forceUpdate()
|
|
|
+ // },
|
|
|
+ // useCrop(res) {
|
|
|
+ // var formdata = {
|
|
|
+ // filePath: res.url,
|
|
|
+ // name: 'file'
|
|
|
+ // }
|
|
|
+ // uni.showLoading({
|
|
|
+ // title: '加载中'
|
|
|
+ // })
|
|
|
+ // uploadInfoFile(formdata).then(res => {
|
|
|
+ // this.storeJoinin.business_licence_number_electronic = res.result.path
|
|
|
+ // this.storeJoinin.business_licence_number_electronic_url = res.result.url
|
|
|
+ // this.imageValue = [{
|
|
|
+ // name: 'business_licence_number_electronic',
|
|
|
+ // extname: 'jpg',
|
|
|
+ // url: this.storeJoinin.business_licence_number_electronic_url
|
|
|
+ // }]
|
|
|
+ // this.cropperOption.imgUrl = ''
|
|
|
+ // this.$forceUpdate()
|
|
|
+ // uni.hideLoading()
|
|
|
+ // }).catch(function(error) {
|
|
|
+ // uni.showToast({
|
|
|
+ // icon: 'none',
|
|
|
+ // title: error.message
|
|
|
+ // })
|
|
|
+ // uni.hideLoading()
|
|
|
+ // this.cropperOption.imgUrl = ''
|
|
|
+ // this.$forceUpdate()
|
|
|
+ // })
|
|
|
+ // },
|
|
|
|
|
|
- useCrop1(res) {
|
|
|
- var formdata = {
|
|
|
- filePath: res.url,
|
|
|
- name: 'file'
|
|
|
- }
|
|
|
- uni.showLoading({
|
|
|
- title: '加载中'
|
|
|
- })
|
|
|
- uploadInfoFile(formdata).then(res => {
|
|
|
- this.storeJoinin.business_author_letter = res.result.path
|
|
|
- this.storeJoinin.business_author_letter_url = res.result.url
|
|
|
- this.imageValue1 = [{
|
|
|
- name: 'business_author_letter',
|
|
|
- extname: 'jpg',
|
|
|
- url: this.storeJoinin.business_author_letter_url
|
|
|
- }]
|
|
|
- this.cropperOption1.imgUrl = ''
|
|
|
- this.$forceUpdate()
|
|
|
- uni.hideLoading()
|
|
|
- }).catch(function(error) {
|
|
|
- uni.showToast({
|
|
|
- icon: 'none',
|
|
|
- title: error.message
|
|
|
- })
|
|
|
- uni.hideLoading()
|
|
|
- this.cropperOption1.imgUrl = ''
|
|
|
- this.$forceUpdate()
|
|
|
- })
|
|
|
- },
|
|
|
- cropReady() {
|
|
|
- this.cropperOption.img = this.cropperOption.imgUrl
|
|
|
- },
|
|
|
- cropReady1() {
|
|
|
- this.cropperOption1.img = this.cropperOption1.imgUrl
|
|
|
- },
|
|
|
- cropBack(){
|
|
|
- this.cropperOption.imgUrl=''
|
|
|
- this.$forceUpdate()
|
|
|
- },
|
|
|
- cropBack1(){
|
|
|
- this.cropperOption1.imgUrl=''
|
|
|
- this.$forceUpdate()
|
|
|
- },
|
|
|
+ // useCrop1(res) {
|
|
|
+ // var formdata = {
|
|
|
+ // filePath: res.url,
|
|
|
+ // name: 'file'
|
|
|
+ // }
|
|
|
+ // uni.showLoading({
|
|
|
+ // title: '加载中'
|
|
|
+ // })
|
|
|
+ // uploadInfoFile(formdata).then(res => {
|
|
|
+ // this.storeJoinin.business_author_letter = res.result.path
|
|
|
+ // this.storeJoinin.business_author_letter_url = res.result.url
|
|
|
+ // this.imageValue1 = [{
|
|
|
+ // name: 'business_author_letter',
|
|
|
+ // extname: 'jpg',
|
|
|
+ // url: this.storeJoinin.business_author_letter_url
|
|
|
+ // }]
|
|
|
+ // this.cropperOption1.imgUrl = ''
|
|
|
+ // this.$forceUpdate()
|
|
|
+ // uni.hideLoading()
|
|
|
+ // }).catch(function(error) {
|
|
|
+ // uni.showToast({
|
|
|
+ // icon: 'none',
|
|
|
+ // title: error.message
|
|
|
+ // })
|
|
|
+ // uni.hideLoading()
|
|
|
+ // this.cropperOption1.imgUrl = ''
|
|
|
+ // this.$forceUpdate()
|
|
|
+ // })
|
|
|
+ // },
|
|
|
+ // cropReady() {
|
|
|
+ // this.cropperOption.img = this.cropperOption.imgUrl
|
|
|
+ // },
|
|
|
+ // cropReady1() {
|
|
|
+ // this.cropperOption1.img = this.cropperOption1.imgUrl
|
|
|
+ // },
|
|
|
+ //cropBack(){
|
|
|
+ // this.cropperOption.imgUrl=''
|
|
|
+ // this.$forceUpdate()
|
|
|
+ // },
|
|
|
+ // cropBack1(){
|
|
|
+ // this.cropperOption1.imgUrl=''
|
|
|
+ // this.$forceUpdate()
|
|
|
+ // },
|
|
|
selectCity (city_name) {
|
|
|
getPointByAddress(city_name).then(res => {
|
|
|
if (res.result.location) {
|