From a987eccb27891bbfaae334b7fa0e892ee2640271 Mon Sep 17 00:00:00 2001
From: MrShi <1878285526@qq.com>
Date: 星期一, 20 四月 2026 17:20:13 +0800
Subject: [PATCH] 调接口加页面

---
 small-program/pages/store-apply/store-apply.vue |  817 +++++++++++++++++++++++++++++++++++++++++++++++++++++----
 1 files changed, 749 insertions(+), 68 deletions(-)

diff --git a/small-program/pages/store-apply/store-apply.vue b/small-program/pages/store-apply/store-apply.vue
index bfeeddf..698109b 100644
--- a/small-program/pages/store-apply/store-apply.vue
+++ b/small-program/pages/store-apply/store-apply.vue
@@ -16,27 +16,37 @@
 
 		<view v-if="currentStep === 1" class="form-card">
 			<text class="card-title">闂ㄥ簵淇℃伅</text>
-			<text class="register-no">娉ㄥ唽鎵嬫満鍙凤細18155114565</text>
+			<text class="register-no">娉ㄥ唽鎵嬫満鍙凤細{{ userInfo.telephone || '' }}</text>
 
 			<view class="form-group">
 				<view class="label-row"><text class="label">闂ㄥ簵鍚嶇О</text><text class="required">*</text></view>
-				<input class="text-input" :value="previewMode === 'filled' ? '涓搧蹇繍鍗楃珯鏃楄埌搴�' : ''" placeholder="璇疯緭鍏ラ棬搴楀悕绉�" placeholder-class="placeholder" />
+				<input class="text-input" v-model="form.name" placeholder="璇疯緭鍏ラ棬搴楀悕绉�" placeholder-style="color: #c1c7d0;" />
 			</view>
 			<view class="divider"></view>
 
 			<view class="form-group select-group">
 				<view class="label-row"><text class="label">鎵�鍦ㄥ煄甯�</text><text class="required">*</text></view>
-				<view class="select-row">
-					<text class="select-text" :class="{ placeholder: previewMode === 'empty' }">{{ previewMode === 'filled' ? '瀹夊窘鐪�/鍚堣偉甯�/搴愰槼鍖�' : '璇烽�夋嫨鐪佸競鍖�' }}</text>
+				<view class="select-row" @click="showAreaPicker = true">
+					<text class="select-text" :class="{ placeholder: !form.areaName }">{{ form.areaName || '璇烽�夋嫨鐪佸競鍖�' }}</text>
 					<u-icon name="arrow-right" size="18" color="#9FA6B2"></u-icon>
 				</view>
 			</view>
+			<u-picker
+				:show="showAreaPicker"
+				v-if="areaList && areaList.length > 0"
+				ref="uPicker"
+				confirmColor="#10B2FA"
+				keyName="text"
+				:columns="areaColumns"
+				@confirm="confirmArea"
+				@change="changeAreaHandler"
+				@cancel="showAreaPicker = false" />
 			<view class="divider"></view>
 
 			<view class="form-group select-group">
 				<view class="label-row"><text class="label">闂ㄥ簵鍦板潃</text><text class="required">*</text></view>
-				<view class="select-row">
-					<text class="select-text" :class="{ placeholder: previewMode === 'empty' }">{{ previewMode === 'filled' ? '涔濆崕灞辫矾201鍙�' : '璇烽�夋嫨鍦板潃' }}</text>
+				<view class="select-row" @click="chooseAddress">
+					<text class="select-text" :class="{ placeholder: !form.address }">{{ form.address || '璇烽�夋嫨鍦板潃' }}</text>
 					<u-icon name="arrow-right" size="18" color="#9FA6B2"></u-icon>
 				</view>
 			</view>
@@ -44,14 +54,14 @@
 
 			<view class="form-group">
 				<view class="label-row"><text class="label">鑱旂郴浜�</text><text class="required">*</text></view>
-				<input class="text-input" :value="previewMode === 'filled' ? '鑻忕湢鐪�' : ''" placeholder="璇疯緭鍏ヨ仈绯讳汉濮撳悕" placeholder-class="placeholder" />
+				<input class="text-input" v-model="form.linkName" placeholder="璇疯緭鍏ヨ仈绯讳汉濮撳悕" placeholder-style="color: #c1c7d0;" />
 			</view>
 			<view class="divider"></view>
 
 			<view class="form-group phone-group">
 				<view class="label-row"><text class="label">鑱旂郴浜虹數璇�</text><text class="required">*</text></view>
 				<view class="input-with-icon">
-					<input class="text-input" :value="previewMode === 'filled' ? '18155114565' : '18155114565'" placeholder="璇疯緭鍏ヨ仈绯讳汉鐢佃瘽" placeholder-class="placeholder" />
+					<input class="text-input" type="number" maxlength="11" v-model="form.linkPhone" placeholder="璇疯緭鍏ヨ仈绯讳汉鐢佃瘽" placeholder-style="color: #c1c7d0;" />
 					<view class="clear-icon"></view>
 				</view>
 			</view>
@@ -59,7 +69,7 @@
 
 			<view class="form-group">
 				<view class="label-row"><text class="label">鑱旂郴浜鸿韩浠借瘉鍙�</text><text class="required">*</text></view>
-				<input class="text-input" :value="previewMode === 'filled' ? '340198273482934298' : ''" placeholder="璇疯緭鍏ヨ仈绯讳汉鐢佃瘽" placeholder-class="placeholder" />
+				<input class="text-input" type="idcard" maxlength="18" v-model="form.idcard" placeholder="璇疯緭鍏ヨ仈绯讳汉韬唤璇佸彿" placeholder-style="color: #c1c7d0;" />
 			</view>
 			<view class="divider"></view>
 
@@ -69,15 +79,13 @@
 					<text class="upload-tip">鏈�澶氫笂浼�3寮犵収鐗�</text>
 				</view>
 				<view class="upload-grid">
-					<view class="upload-box">
+					<view class="upload-box" @click="chooseStoreFrontImage">
 						<image class="upload-icon" src="/static/image/btn_upload@2x.png" mode="widthFix"></image>
 					</view>
-					<template v-if="previewMode === 'filled'">
-						<view v-for="n in 2" :key="n" class="image-box">
-							<image class="preview-image" src="" mode="aspectFill"></image>
-							<text class="image-mark">鍒犳帀</text>
-						</view>
-					</template>
+					<view v-for="(item, index) in uploadedImagesStoreFront" :key="index" class="image-box" @click="deleteStoreFrontImage(index)">
+						<image class="preview-image" :src="item.url" mode="aspectFill"></image>
+						<text class="image-mark">鍒犳帀</text>
+					</view>
 				</view>
 			</view>
 
@@ -87,15 +95,13 @@
 					<text class="upload-tip">鏈�澶氫笂浼�3寮犵収鐗�</text>
 				</view>
 				<view class="upload-grid">
-					<view class="upload-box">
+					<view class="upload-box" @click="chooseIdCardImage">
 						<image class="upload-icon" src="/static/image/btn_upload@2x.png" mode="widthFix"></image>
 					</view>
-					<template v-if="previewMode === 'filled'">
-						<view v-for="n in 3" :key="n" class="image-box">
-							<image class="preview-image" src="" mode="aspectFill"></image>
-							<text class="image-mark">鍒犳帀</text>
-						</view>
-					</template>
+					<view v-for="(item, index) in uploadedImagesIdCard" :key="index" class="image-box" @click="deleteIdCardImage(index)">
+						<image class="preview-image" :src="item.url" mode="aspectFill"></image>
+						<text class="image-mark">鍒犳帀</text>
+					</view>
 				</view>
 			</view>
 
@@ -105,8 +111,12 @@
 					<text class="upload-tip">鏈�澶氫笂浼�3寮犵収鐗�</text>
 				</view>
 				<view class="upload-grid">
-					<view class="upload-box">
+					<view class="upload-box" @click="choosePermitImage">
 						<image class="upload-icon" src="/static/image/btn_upload@2x.png" mode="widthFix"></image>
+					</view>
+					<view v-for="(item, index) in uploadedImagesPermit" :key="index" class="image-box" @click="deletePermitImage(index)">
+						<image class="preview-image" :src="item.url" mode="aspectFill"></image>
+						<text class="image-mark">鍒犳帀</text>
 					</view>
 				</view>
 			</view>
@@ -118,15 +128,15 @@
 			<view class="form-group subject-first-group">
 				<view class="label-row"><text class="label">闂ㄥ簵绫诲瀷</text><text class="required">*</text></view>
 				<view class="switch-row type-switch-row">
-					<view class="switch-pill" :class="{ active: qualificationType === 'personal' }" @tap="qualificationType = 'personal'">涓汉</view>
-					<view class="switch-pill" :class="{ active: qualificationType === 'company' }" @tap="qualificationType = 'company'">浼佷笟</view>
+					<view class="switch-pill" :class="{ active: qualificationType === 'personal' }" @tap="switchQualification('personal')">涓汉</view>
+					<view class="switch-pill" :class="{ active: qualificationType === 'company' }" @tap="switchQualification('company')">浼佷笟</view>
 				</view>
 			</view>
 
 			<template v-if="qualificationType === 'personal'">
 				<view class="form-group compact-group">
 					<view class="label-row"><text class="label">鏀粯瀹濊处鍙�</text><text class="required">*</text></view>
-					<input class="text-input" :value="previewMode === 'filled' ? '18155114565@alipay.com' : ''" placeholder="璇疯緭鍏ヤ釜浜烘敮浠樺疂璐﹀彿" placeholder-class="placeholder" />
+					<input class="text-input" v-model="form.aliAccount" placeholder="璇疯緭鍏ヤ釜浜烘敮浠樺疂璐﹀彿" placeholder-class="placeholder" />
 				</view>
 				<view class="divider"></view>
 
@@ -135,13 +145,15 @@
 						<view class="label-row"><text class="label">韬唤璇佹鍙嶉潰</text><text class="required">*</text></view>
 					</view>
 					<view class="upload-grid double-upload-grid">
-						<view class="upload-box id-upload-box">
-							<image class="camera-icon" src="/static/icon/ic_camera@2x.png" mode="widthFix"></image>
-							<text class="upload-text">涓婁紶浜哄儚闈�</text>
+						<view class="upload-box id-upload-box" @click="chooseIdCardFront">
+							<image v-if="!form.idcardImg" class="camera-icon" src="/static/icon/ic_camera@2x.png" mode="widthFix"></image>
+							<image v-else class="preview-image" :src="getFullPath(form.idcardImg)" mode="aspectFill"></image>
+							<text v-if="!form.idcardImg" class="upload-text">涓婁紶浜哄儚闈�</text>
 						</view>
-						<view class="upload-box id-upload-box">
-							<image class="camera-icon" src="/static/icon/ic_camera@2x.png" mode="widthFix"></image>
-							<text class="upload-text">涓婁紶鍥藉窘闈�</text>
+						<view class="upload-box id-upload-box" @click="chooseIdCardBack">
+							<image v-if="!form.idcardImgBack" class="camera-icon" src="/static/icon/ic_camera@2x.png" mode="widthFix"></image>
+							<image v-else class="preview-image" :src="getFullPath(form.idcardImgBack)" mode="aspectFill"></image>
+							<text v-if="!form.idcardImgBack" class="upload-text">涓婁紶鍥藉窘闈�</text>
 						</view>
 					</view>
 				</view>
@@ -152,15 +164,13 @@
 						<text class="upload-tip">鏈�澶氫笂浼�3寮犵収鐗�</text>
 					</view>
 					<view class="upload-grid">
-						<view class="upload-box">
+						<view class="upload-box" @click="chooseLaborContractImage">
 							<image class="upload-icon" src="/static/image/btn_upload@2x.png" mode="widthFix"></image>
 						</view>
-						<template v-if="previewMode === 'filled'">
-							<view v-for="n in 3" :key="n" class="image-box">
-								<image class="preview-image" src="" mode="aspectFill"></image>
-								<text class="image-mark">鍒犳帀</text>
-							</view>
-						</template>
+						<view v-for="(item, index) in uploadedLaborContractImages" :key="index" class="image-box" @click="deleteLaborContractImage(index)">
+							<image class="preview-image" :src="item.url" mode="aspectFill"></image>
+							<text class="image-mark">鍒犳帀</text>
+						</view>
 					</view>
 				</view>
 
@@ -170,15 +180,13 @@
 						<text class="upload-tip">鏈�澶氫笂浼�3寮犵収鐗�</text>
 					</view>
 					<view class="upload-grid">
-						<view class="upload-box">
+						<view class="upload-box" @click="chooseSocialSecurityImage">
 							<image class="upload-icon" src="/static/image/btn_upload@2x.png" mode="widthFix"></image>
 						</view>
-						<template v-if="previewMode === 'filled'">
-							<view class="image-box">
-								<image class="preview-image" src="" mode="aspectFill"></image>
-								<text class="image-mark">鍒犳帀</text>
-							</view>
-						</template>
+						<view v-for="(item, index) in uploadedSocialSecurityImages" :key="index" class="image-box" @click="deleteSocialSecurityImage(index)">
+							<image class="preview-image" :src="item.url" mode="aspectFill"></image>
+							<text class="image-mark">鍒犳帀</text>
+						</view>
 					</view>
 				</view>
 			</template>
@@ -186,19 +194,19 @@
 			<template v-else>
 				<view class="form-group compact-group">
 					<view class="label-row"><text class="label">娉曚汉濮撳悕</text><text class="required">*</text></view>
-					<input class="text-input" :value="previewMode === 'filled' ? '寮犲厜瀹�' : ''" placeholder="璇疯緭鍏ユ硶浜哄鍚�" placeholder-class="placeholder" />
+					<input class="text-input" v-model="form.legalPersonName" placeholder="璇疯緭鍏ユ硶浜哄鍚�" placeholder-style="color: #c1c7d0;" />
 				</view>
 				<view class="divider"></view>
 
 				<view class="form-group compact-group">
 					<view class="label-row"><text class="label">浼佷笟鏀粯瀹濊处鍙�</text><text class="required">*</text></view>
-					<input class="text-input" :value="previewMode === 'filled' ? 'company@alipay.com' : ''" placeholder="璇疯緭鍏ヤ紒涓氭敮浠樺疂璐﹀彿" placeholder-class="placeholder" />
+					<input class="text-input" v-model="form.aliAccount" placeholder="璇疯緭鍏ヤ紒涓氭敮浠樺疂璐﹀彿" placeholder-style="color: #c1c7d0;" />
 				</view>
 				<view class="divider"></view>
 
 				<view class="form-group compact-group">
 					<view class="label-row"><text class="label">娉曚汉韬唤璇佸彿</text><text class="required">*</text></view>
-					<input class="text-input" :value="previewMode === 'filled' ? '340198273482934298' : ''" placeholder="璇疯緭鍏ユ硶浜鸿韩浠借瘉鍙风爜" placeholder-class="placeholder" />
+					<input class="text-input" v-model="form.legalPersonCard" placeholder="璇疯緭鍏ユ硶浜鸿韩浠借瘉鍙风爜" placeholder-style="color: #c1c7d0;" />
 				</view>
 				<view class="divider"></view>
 
@@ -207,13 +215,15 @@
 						<view class="label-row"><text class="label">娉曚汉韬唤璇佹鍙嶉潰</text><text class="required">*</text></view>
 					</view>
 					<view class="upload-grid double-upload-grid">
-						<view class="upload-box id-upload-box">
-							<image class="camera-icon" src="/static/icon/ic_camera@2x.png" mode="widthFix"></image>
-							<text class="upload-text">涓婁紶浜哄儚闈�</text>
+						<view class="upload-box id-upload-box" @click="chooseLegalPersonCardFront">
+							<image v-if="!form.legalPersonCard" class="camera-icon" src="/static/icon/ic_camera@2x.png" mode="widthFix"></image>
+							<image v-else class="preview-image" :src="getFullPath(form.legalPersonCard)" mode="aspectFill"></image>
+							<text v-if="!form.legalPersonCard" class="upload-text">涓婁紶浜哄儚闈�</text>
 						</view>
-						<view class="upload-box id-upload-box">
-							<image class="camera-icon" src="/static/icon/ic_camera@2x.png" mode="widthFix"></image>
-							<text class="upload-text">涓婁紶鍥藉窘闈�</text>
+						<view class="upload-box id-upload-box" @click="chooseLegalPersonCardBack">
+							<image v-if="!form.legalPersonCardBack" class="camera-icon" src="/static/icon/ic_camera@2x.png" mode="widthFix"></image>
+							<image v-else class="preview-image" :src="getFullPath(form.legalPersonCardBack)" mode="aspectFill"></image>
+							<text v-if="!form.legalPersonCardBack" class="upload-text">涓婁紶鍥藉窘闈�</text>
 						</view>
 					</view>
 				</view>
@@ -223,9 +233,10 @@
 						<view class="label-row"><text class="label">钀ヤ笟鎵х収</text><text class="required">*</text></view>
 					</view>
 					<view class="upload-grid">
-						<view class="upload-box license-upload-box">
-							<image class="camera-icon" src="/static/icon/ic_camera@2x.png" mode="widthFix"></image>
-							<text class="upload-text">鐐瑰嚮涓婁紶</text>
+						<view class="upload-box license-upload-box" @click="chooseBusinessImage">
+							<image v-if="!form.businessImg" class="camera-icon" src="/static/icon/ic_camera@2x.png" mode="widthFix"></image>
+							<image v-else class="preview-image" :src="getFullPath(form.businessImg)" mode="aspectFill"></image>
+							<text v-if="!form.businessImg" class="upload-text">鐐瑰嚮涓婁紶</text>
 						</view>
 					</view>
 				</view>
@@ -234,23 +245,693 @@
 
 		<view class="bottom-btn-wrap">
 			<template v-if="currentStep === 1">
-				<view class="next-btn">涓嬩竴姝�</view>
+				<view class="next-btn" @click="goToStep2">涓嬩竴姝�</view>
 			</template>
 			<template v-else>
-				<view class="footer-btn footer-plain-btn">涓婁竴姝�</view>
-				<view class="footer-btn footer-primary-btn">鎻愪氦鍏ラ┗鐢宠</view>
+				<view class="footer-btn footer-plain-btn" @click="currentStep = 1">涓婁竴姝�</view>
+				<view class="footer-btn footer-primary-btn" @click="submitApply">鎻愪氦鍏ラ┗鐢宠</view>
 			</template>
 		</view>
 	</view>
 </template>
 
 <script>
+	import { mapState } from 'vuex'
 	export default {
+		computed: {
+			...mapState(['userInfo'])
+		},
 		data() {
 			return {
+				form: {
+					telephone: '',
+					companyType: 0,
+					name: '',
+					areaId: '',
+					longitude: '',
+					latitude: '',
+					address: '',
+					linkName: '',
+					linkPhone: '',
+					idcard: '',
+					storeFrontImgs: [],
+					storeInteriorImgs: [],
+					otherMaterialImgs: [],
+					idcardImg: '',
+					idcardImgBack: '',
+					laborContractImgs: [],
+					socialSecurityImgs: [],
+					legalPersonCard: '',
+					legalPersonCardBack: '',
+					legalPersonName: '',
+					legalPersonPhone: '',
+					aliAccount: '',
+					businessImg: ''
+				},
+
 				previewMode: 'filled',
-				currentStep: 2,
-				qualificationType: 'company'
+				currentStep: 1,
+				qualificationType: 'company',
+				showAreaPicker: false,
+				areaList: [],
+				areaColumns: [],
+				uploadedImagesStoreFront: [],
+				uploadedImagesIdCard: [],
+				uploadedImagesBusiness: [],
+				uploadedImagesPermit: [],
+				uploadedLaborContractImages: [],
+				uploadedSocialSecurityImages: [],
+				storeFrontImages: [],
+				idCardImages: [],
+				businessImages: [],
+				permitImages: [],
+				laborContractImages: [],
+				socialSecurityImages: []
+			}
+		},
+		onLoad() {
+			this.form.telephone = this.userInfo.telephone || ''
+			this.getAreaList()
+			this.getMyShopData()
+		},
+		methods: {
+			goToStep2() {
+				if (!this.form.name) {
+					uni.showToast({ title: '璇疯緭鍏ラ棬搴楀悕绉�', icon: 'none' })
+					return
+				}
+				if (!this.form.areaId) {
+					uni.showToast({ title: '璇烽�夋嫨鎵�鍦ㄥ煄甯�', icon: 'none' })
+					return
+				}
+				if (!this.form.address) {
+					uni.showToast({ title: '璇烽�夋嫨闂ㄥ簵鍦板潃', icon: 'none' })
+					return
+				}
+				if (!this.form.linkName) {
+					uni.showToast({ title: '璇疯緭鍏ヨ仈绯讳汉', icon: 'none' })
+					return
+				}
+				if (!this.form.linkPhone) {
+					uni.showToast({ title: '璇疯緭鍏ヨ仈绯讳汉鐢佃瘽', icon: 'none' })
+					return
+				}
+				if (!this.form.idcard) {
+					uni.showToast({ title: '璇疯緭鍏ヨ仈绯讳汉韬唤璇佸彿', icon: 'none' })
+					return
+				}
+				if (!this.form.storeFrontImgs || this.form.storeFrontImgs.length === 0) {
+					uni.showToast({ title: '璇蜂笂浼犻棬搴楅棬澶寸収鐗�', icon: 'none' })
+					return
+				}
+				if (!this.form.storeInteriorImgs || this.form.storeInteriorImgs.length === 0) {
+					uni.showToast({ title: '璇蜂笂浼犻棬搴楀唴閮ㄦ嫑鐗�', icon: 'none' })
+					return
+				}
+				this.currentStep = 2
+			},
+			switchQualification(type) {
+				this.qualificationType = type
+				this.form.companyType = type === 'personal' ? 0 : 1
+			},
+			async submitApply() {
+				if (this.form.companyType === 0) {
+					if (!this.form.idcardImg) {
+						uni.showToast({ title: '璇蜂笂浼犺韩浠借瘉浜哄儚闈�', icon: 'none' })
+						return
+					}
+					if (!this.form.idcardImgBack) {
+						uni.showToast({ title: '璇蜂笂浼犺韩浠借瘉鍥藉窘闈�', icon: 'none' })
+						return
+					}
+					if (!this.form.laborContractImgs || this.form.laborContractImgs.length === 0) {
+						uni.showToast({ title: '璇蜂笂浼犲姵鍔ㄥ悎鍚�', icon: 'none' })
+						return
+					}
+					if (!this.form.socialSecurityImgs || this.form.socialSecurityImgs.length === 0) {
+						uni.showToast({ title: '璇蜂笂浼犵ぞ淇濈即绾宠瘉鏄�', icon: 'none' })
+						return
+					}
+				} else {
+					if (!this.form.legalPersonName) {
+						uni.showToast({ title: '璇疯緭鍏ユ硶浜哄鍚�', icon: 'none' })
+						return
+					}
+					if (!this.form.aliAccount) {
+						uni.showToast({ title: '璇疯緭鍏ヤ紒涓氭敮浠樺疂璐﹀彿', icon: 'none' })
+						return
+					}
+					if (!this.form.legalPersonCard) {
+						uni.showToast({ title: '璇蜂笂浼犳硶浜鸿韩浠借瘉浜哄儚闈�', icon: 'none' })
+						return
+					}
+					if (!this.form.legalPersonCardBack) {
+						uni.showToast({ title: '璇蜂笂浼犳硶浜鸿韩浠借瘉鍥藉窘闈�', icon: 'none' })
+						return
+					}
+					if (!this.form.businessImg) {
+						uni.showToast({ title: '璇蜂笂浼犺惀涓氭墽鐓�', icon: 'none' })
+						return
+					}
+				}
+				uni.showLoading({ title: '鎻愪氦涓�...', mask: true })
+				try {
+					const res = await this.$u.api.applyShop(this.form)
+					uni.hideLoading()
+					if (res.code === 200) {
+						uni.showToast({ title: '鎻愪氦鎴愬姛', icon: 'success' })
+						setTimeout(() => {
+							uni.navigateBack()
+						}, 1500)
+					} else {
+						uni.showToast({ title: res.msg || '鎻愪氦澶辫触', icon: 'none' })
+					}
+				} catch (error) {
+					uni.hideLoading()
+					uni.showToast({ title: '鎻愪氦澶辫触', icon: 'none' })
+				}
+			},
+			async getMyShopData() {
+				try {
+					const res = await this.$u.api.getMyShop()
+					if (res.code === 200 && res.data) {
+						const data = res.data
+						const imgPrefix = data.imgPrefix || ''
+						this.form.name = data.name || ''
+						this.form.areaId = data.areaId || ''
+						this.form.areaName = data.areaName || ''
+						this.form.address = data.address || ''
+						this.form.longitude = data.longitude || ''
+						this.form.latitude = data.latitude || ''
+						this.form.linkName = data.linkName || ''
+						this.form.linkPhone = data.linkPhone || ''
+						this.form.idcard = data.idcard || ''
+						this.form.aliAccount = data.aliAccount || ''
+						this.form.companyType = data.companyType || 0
+						this.form.telephone = data.telephone || this.userInfo.telephone || ''
+						this.form.legalPersonName = data.legalPersonName || ''
+						this.form.legalPersonPhone = data.legalPersonPhone || ''
+						this.qualificationType = data.companyType === 0 ? 'personal' : 'company'
+						if (data.storeFrontImgs) {
+							let storeFrontImgs = data.storeFrontImgs
+							if (typeof storeFrontImgs === 'string') {
+								storeFrontImgs = storeFrontImgs.split(',')
+							}
+							this.storeFrontImages = storeFrontImgs
+							this.uploadedImagesStoreFront = storeFrontImgs.map(url => ({ url: imgPrefix + url }))
+							this.form.storeFrontImgs = storeFrontImgs
+						}
+						if (data.storeInteriorImgs) {
+							let storeInteriorImgs = data.storeInteriorImgs
+							if (typeof storeInteriorImgs === 'string') {
+								storeInteriorImgs = storeInteriorImgs.split(',')
+							}
+							this.idCardImages = storeInteriorImgs
+							this.uploadedImagesIdCard = storeInteriorImgs.map(url => ({ url: imgPrefix + url }))
+							this.form.storeInteriorImgs = storeInteriorImgs
+						}
+						if (data.otherMaterialImgs) {
+							let otherMaterialImgs = data.otherMaterialImgs
+							if (typeof otherMaterialImgs === 'string') {
+								otherMaterialImgs = otherMaterialImgs.split(',')
+							}
+							this.permitImages = otherMaterialImgs
+							this.uploadedImagesPermit = otherMaterialImgs.map(url => ({ url: imgPrefix + url }))
+							this.form.otherMaterialImgs = otherMaterialImgs
+						}
+						this.form.idcardImg = data.idcardImg ? imgPrefix + data.idcardImg : ''
+						this.form.idcardImgBack = data.idcardImgBack ? imgPrefix + data.idcardImgBack : ''
+						if (data.laborContractImgs) {
+							let laborContractImgs = data.laborContractImgs
+							if (typeof laborContractImgs === 'string') {
+								laborContractImgs = laborContractImgs.split(',')
+							}
+							this.laborContractImages = laborContractImgs
+							this.uploadedLaborContractImages = laborContractImgs.map(url => ({ url: imgPrefix + url }))
+							this.form.laborContractImgs = laborContractImgs
+						}
+						if (data.socialSecurityImgs) {
+							let socialSecurityImgs = data.socialSecurityImgs
+							if (typeof socialSecurityImgs === 'string') {
+								socialSecurityImgs = socialSecurityImgs.split(',')
+							}
+							this.socialSecurityImages = socialSecurityImgs
+							this.uploadedSocialSecurityImages = socialSecurityImgs.map(url => ({ url: imgPrefix + url }))
+							this.form.socialSecurityImgs = socialSecurityImgs
+						}
+						this.form.legalPersonCard = data.legalPersonCard ? imgPrefix + data.legalPersonCard : ''
+						this.form.legalPersonCardBack = data.legalPersonCardBack ? imgPrefix + data.legalPersonCardBack : ''
+						this.form.businessImg = data.businessImg ? imgPrefix + data.businessImg : ''
+						if (data.businessImg) {
+							this.businessImages = [data.businessImg]
+						}
+					}
+				} catch (error) {
+					console.log('鑾峰彇搴楅摵淇℃伅澶辫触', error)
+				}
+			},
+			getAreaList() {
+				this.$u.api.treeList({
+					type: 0,
+					flag: 1
+				}).then(res => {
+					if (res.code === 200) {
+						this.areaList = res.data
+						this.areaColumns[0] = this.areaList.map(item => {
+							return {
+								id: item.id,
+								text: item.name
+							}
+						})
+						this.areaColumns[1] = this.areaList[0].childList.map(item => {
+							return {
+								id: item.id,
+								text: item.name
+							}
+						})
+						this.areaColumns[2] = this.areaList[0].childList[0].childList.map(item => {
+							return {
+								id: item.id,
+								text: item.name
+							}
+						})
+					}
+				})
+			},
+			confirmArea(e) {
+				this.form.areaId = e.value[e.value.length - 1].id
+				this.form.areaName = e.value[0].text + '/' + e.value[1].text + '/' + e.value[2].text
+				this.showAreaPicker = false
+			},
+			chooseAddress() {
+				uni.chooseLocation({
+					success: (res) => {
+						this.form.address = res.address
+						this.form.longitude = res.longitude
+						this.form.latitude = res.latitude
+					}
+				})
+			},
+			changeAreaHandler(e) {
+				const { columnIndex, indexs, picker = this.$refs.uPicker } = e
+				if (columnIndex === 0) {
+					let city = this.areaList[indexs[0]].childList.map(item => {
+						return {
+							id: item.id,
+							text: item.name
+						}
+					})
+					let qu = this.areaList[indexs[0]].childList[0].childList.map(item => {
+						return {
+							id: item.id,
+							text: item.name
+						}
+					})
+					picker.setColumnValues(1, city)
+					picker.setColumnValues(2, qu)
+				} else if (columnIndex === 1) {
+					let qu = this.areaList[indexs[0]].childList[indexs[1]].childList.map(item => {
+						return {
+							id: item.id,
+							text: item.name
+						}
+					})
+					picker.setColumnValues(2, qu)
+				}
+			},
+			async uploadFiles(filePaths, maxCount = 9) {
+				if (!filePaths || filePaths.length === 0) {
+					return []
+				}
+				const limitedPaths = filePaths.slice(0, maxCount)
+				const uploadTasks = limitedPaths.map(filePath => {
+					return new Promise((resolve, reject) => {
+						uni.uploadFile({
+							url: this.$baseUrl + '/web/public/upload',
+							filePath: filePath,
+							name: 'file',
+							formData: {
+								folder: 'shop'
+							},
+							success: (res) => {
+								if (res.statusCode === 200) {
+									const data = JSON.parse(res.data)
+									if (data.code === 200) {
+										resolve(data.data)
+									} else {
+										reject(new Error(data.msg || '涓婁紶澶辫触'))
+									}
+								} else {
+									reject(new Error('涓婁紶澶辫触'))
+								}
+							},
+							fail: (err) => {
+								reject(err)
+							}
+						})
+					})
+				})
+				try {
+					const results = await Promise.all(uploadTasks)
+					return results
+				} catch (error) {
+					uni.showToast({
+						title: '涓婁紶澶辫触',
+						icon: 'none'
+					})
+					throw error
+				}
+			},
+			deleteStoreFrontImage(index) {
+				this.uploadedImagesStoreFront.splice(index, 1)
+				this.storeFrontImages.splice(index, 1)
+				this.form.storeFrontImgs = this.storeFrontImages.map(url => this.getShortPath(url))
+			},
+			async chooseStoreFrontImage() {
+				const maxCount = 3
+				const currentCount = this.storeFrontImages.length
+				const remainingCount = maxCount - currentCount
+				if (remainingCount <= 0) {
+					uni.showToast({
+						title: `鏈�澶氫笂浼�${maxCount}寮犲浘鐗嘸,
+						icon: 'none'
+					})
+					return
+				}
+				uni.chooseImage({
+					count: remainingCount,
+					sizeType: ['compressed'],
+					sourceType: ['album', 'camera'],
+					success: async (res) => {
+						const tempFilePaths = res.tempFilePaths
+						uni.showLoading({
+							title: '涓婁紶涓�...',
+							mask: true
+						})
+						try {
+							const uploadResults = await this.uploadFiles(tempFilePaths, maxCount)
+							const fullPaths = uploadResults.map(item => item.url || item.path || item)
+							this.uploadedImagesStoreFront = [...this.uploadedImagesStoreFront, ...fullPaths.map(url => ({ url }))]
+							this.storeFrontImages = [...this.storeFrontImages, ...fullPaths]
+							this.form.storeFrontImgs = this.storeFrontImages.map(url => this.getShortPath(url))
+							uni.hideLoading()
+							uni.showToast({
+								title: '涓婁紶鎴愬姛',
+								icon: 'success'
+							})
+						} catch (error) {
+							uni.hideLoading()
+						}
+					}
+				})
+			},
+			deleteIdCardImage(index) {
+				this.uploadedImagesIdCard.splice(index, 1)
+				this.idCardImages.splice(index, 1)
+				this.form.storeInteriorImgs = this.idCardImages.map(url => this.getShortPath(url))
+			},
+			async chooseIdCardImage() {
+				const maxCount = 2
+				const currentCount = this.idCardImages.length
+				const remainingCount = maxCount - currentCount
+				if (remainingCount <= 0) {
+					uni.showToast({
+						title: `鏈�澶氫笂浼�${maxCount}寮犲浘鐗嘸,
+						icon: 'none'
+					})
+					return
+				}
+				uni.chooseImage({
+					count: remainingCount,
+					sizeType: ['compressed'],
+					sourceType: ['album', 'camera'],
+					success: async (res) => {
+						const tempFilePaths = res.tempFilePaths
+						uni.showLoading({
+							title: '涓婁紶涓�...',
+							mask: true
+						})
+						try {
+							const uploadResults = await this.uploadFiles(tempFilePaths, maxCount)
+							const fullPaths = uploadResults.map(item => item.url || item.path || item)
+							this.uploadedImagesIdCard = [...this.uploadedImagesIdCard, ...fullPaths.map(url => ({ url }))]
+							this.idCardImages = [...this.idCardImages, ...fullPaths]
+							this.form.storeInteriorImgs = this.idCardImages.map(url => this.getShortPath(url))
+							uni.hideLoading()
+							uni.showToast({
+								title: '涓婁紶鎴愬姛',
+								icon: 'success'
+							})
+						} catch (error) {
+							uni.hideLoading()
+						}
+					}
+				})
+			},
+			deleteBusinessImage(index) {
+				this.uploadedImagesBusiness.splice(index, 1)
+				this.businessImages.splice(index, 1)
+				this.form.businessImg = this.businessImages.map(url => this.getShortPath(url)).join(',')
+			},
+			async chooseBusinessImage() {
+				const maxCount = 3
+				const currentCount = this.businessImages.length
+				const remainingCount = maxCount - currentCount
+				if (remainingCount <= 0) {
+					uni.showToast({
+						title: `鏈�澶氫笂浼�${maxCount}寮犲浘鐗嘸,
+						icon: 'none'
+					})
+					return
+				}
+				uni.chooseImage({
+					count: remainingCount,
+					sizeType: ['compressed'],
+					sourceType: ['album', 'camera'],
+					success: async (res) => {
+						const tempFilePaths = res.tempFilePaths
+						uni.showLoading({
+							title: '涓婁紶涓�...',
+							mask: true
+						})
+						try {
+							const uploadResults = await this.uploadFiles(tempFilePaths, maxCount)
+							const fullPaths = uploadResults.map(item => item.url || item.path || item)
+							this.uploadedImagesBusiness = [...this.uploadedImagesBusiness, ...fullPaths.map(url => ({ url }))]
+							this.businessImages = [...this.businessImages, ...fullPaths]
+							this.form.businessImg = this.businessImages.map(url => this.getShortPath(url)).join(',')
+							uni.hideLoading()
+							uni.showToast({
+								title: '涓婁紶鎴愬姛',
+								icon: 'success'
+							})
+						} catch (error) {
+							uni.hideLoading()
+						}
+					}
+				})
+			},
+			deletePermitImage(index) {
+				this.uploadedImagesPermit.splice(index, 1)
+				this.permitImages.splice(index, 1)
+				this.form.otherMaterialImgs = this.permitImages.map(url => this.getShortPath(url))
+			},
+			async choosePermitImage() {
+				const maxCount = 3
+				const currentCount = this.permitImages.length
+				const remainingCount = maxCount - currentCount
+				if (remainingCount <= 0) {
+					uni.showToast({
+						title: `鏈�澶氫笂浼�${maxCount}寮犲浘鐗嘸,
+						icon: 'none'
+					})
+					return
+				}
+				uni.chooseImage({
+					count: remainingCount,
+					sizeType: ['compressed'],
+					sourceType: ['album', 'camera'],
+					success: async (res) => {
+						const tempFilePaths = res.tempFilePaths
+						uni.showLoading({
+							title: '涓婁紶涓�...',
+							mask: true
+						})
+						try {
+							const uploadResults = await this.uploadFiles(tempFilePaths, maxCount)
+							const fullPaths = uploadResults.map(item => item.url || item.path || item)
+							this.uploadedImagesPermit = [...this.uploadedImagesPermit, ...fullPaths.map(url => ({ url }))]
+							this.permitImages = [...this.permitImages, ...fullPaths]
+							this.form.otherMaterialImgs = this.permitImages.map(url => this.getShortPath(url))
+							uni.hideLoading()
+							uni.showToast({
+								title: '涓婁紶鎴愬姛',
+								icon: 'success'
+							})
+						} catch (error) {
+							uni.hideLoading()
+						}
+					}
+				})
+			},
+			chooseIdCardFront() {
+				uni.chooseImage({
+					count: 1,
+					sizeType: ['compressed'],
+					sourceType: ['album', 'camera'],
+					success: async (res) => {
+						const tempFilePaths = res.tempFilePaths
+						uni.showLoading({ title: '涓婁紶涓�...', mask: true })
+						try {
+							const uploadResults = await this.uploadFiles(tempFilePaths, 1)
+							this.form.idcardImg = this.getShortPath(uploadResults[0].url || uploadResults[0].path || uploadResults[0])
+							uni.hideLoading()
+							uni.showToast({ title: '涓婁紶鎴愬姛', icon: 'success' })
+						} catch (error) {
+							uni.hideLoading()
+						}
+					}
+				})
+			},
+			chooseIdCardBack() {
+				uni.chooseImage({
+					count: 1,
+					sizeType: ['compressed'],
+					sourceType: ['album', 'camera'],
+					success: async (res) => {
+						const tempFilePaths = res.tempFilePaths
+						uni.showLoading({ title: '涓婁紶涓�...', mask: true })
+						try {
+							const uploadResults = await this.uploadFiles(tempFilePaths, 1)
+							this.form.idcardImgBack = this.getShortPath(uploadResults[0].url || uploadResults[0].path || uploadResults[0])
+							uni.hideLoading()
+							uni.showToast({ title: '涓婁紶鎴愬姛', icon: 'success' })
+						} catch (error) {
+							uni.hideLoading()
+						}
+					}
+				})
+			},
+			chooseLegalPersonCardFront() {
+				uni.chooseImage({
+					count: 1,
+					sizeType: ['compressed'],
+					sourceType: ['album', 'camera'],
+					success: async (res) => {
+						const tempFilePaths = res.tempFilePaths
+						uni.showLoading({ title: '涓婁紶涓�...', mask: true })
+						try {
+							const uploadResults = await this.uploadFiles(tempFilePaths, 1)
+							this.form.legalPersonCard = this.getShortPath(uploadResults[0].url || uploadResults[0].path || uploadResults[0])
+							uni.hideLoading()
+							uni.showToast({ title: '涓婁紶鎴愬姛', icon: 'success' })
+						} catch (error) {
+							uni.hideLoading()
+						}
+					}
+				})
+			},
+			chooseLegalPersonCardBack() {
+				uni.chooseImage({
+					count: 1,
+					sizeType: ['compressed'],
+					sourceType: ['album', 'camera'],
+					success: async (res) => {
+						const tempFilePaths = res.tempFilePaths
+						uni.showLoading({ title: '涓婁紶涓�...', mask: true })
+						try {
+							const uploadResults = await this.uploadFiles(tempFilePaths, 1)
+							this.form.legalPersonCardBack = this.getShortPath(uploadResults[0].url || uploadResults[0].path || uploadResults[0])
+							uni.hideLoading()
+							uni.showToast({ title: '涓婁紶鎴愬姛', icon: 'success' })
+						} catch (error) {
+							uni.hideLoading()
+						}
+					}
+				})
+			},
+			deleteLaborContractImage(index) {
+				this.uploadedLaborContractImages.splice(index, 1)
+				this.laborContractImages.splice(index, 1)
+				this.form.laborContractImgs = this.laborContractImages.map(url => this.getShortPath(url))
+			},
+			async chooseLaborContractImage() {
+				const maxCount = 3
+				const currentCount = this.laborContractImages.length
+				const remainingCount = maxCount - currentCount
+				if (remainingCount <= 0) {
+					uni.showToast({ title: `鏈�澶氫笂浼�${maxCount}寮犲浘鐗嘸, icon: 'none' })
+					return
+				}
+				uni.chooseImage({
+					count: remainingCount,
+					sizeType: ['compressed'],
+					sourceType: ['album', 'camera'],
+					success: async (res) => {
+						const tempFilePaths = res.tempFilePaths
+						uni.showLoading({ title: '涓婁紶涓�...', mask: true })
+						try {
+							const uploadResults = await this.uploadFiles(tempFilePaths, maxCount)
+							const fullPaths = uploadResults.map(item => item.url || item.path || item)
+							this.uploadedLaborContractImages = [...this.uploadedLaborContractImages, ...fullPaths.map(url => ({ url }))]
+							this.laborContractImages = [...this.laborContractImages, ...fullPaths]
+							this.form.laborContractImgs = this.laborContractImages.map(url => this.getShortPath(url))
+							uni.hideLoading()
+							uni.showToast({ title: '涓婁紶鎴愬姛', icon: 'success' })
+						} catch (error) {
+							uni.hideLoading()
+						}
+					}
+				})
+			},
+			deleteSocialSecurityImage(index) {
+				this.uploadedSocialSecurityImages.splice(index, 1)
+				this.socialSecurityImages.splice(index, 1)
+				this.form.socialSecurityImgs = this.socialSecurityImages.map(url => this.getShortPath(url))
+			},
+			getShortPath(url) {
+				if (!url) return ''
+				const baseUrl = this.$baseUrl || ''
+				if (url.startsWith('http')) {
+					return url
+				}
+				return url.replace(baseUrl, '')
+			},
+			getFullPath(url) {
+				if (!url) return ''
+				if (url.startsWith('http')) {
+					return url
+				}
+				return (this.$baseUrl || '') + url
+			},
+			async chooseSocialSecurityImage() {
+				const maxCount = 3
+				const currentCount = this.socialSecurityImages.length
+				const remainingCount = maxCount - currentCount
+				if (remainingCount <= 0) {
+					uni.showToast({ title: `鏈�澶氫笂浼�${maxCount}寮犲浘鐗嘸, icon: 'none' })
+					return
+				}
+				uni.chooseImage({
+					count: remainingCount,
+					sizeType: ['compressed'],
+					sourceType: ['album', 'camera'],
+					success: async (res) => {
+						const tempFilePaths = res.tempFilePaths
+						uni.showLoading({ title: '涓婁紶涓�...', mask: true })
+						try {
+							const uploadResults = await this.uploadFiles(tempFilePaths, maxCount)
+							const fullPaths = uploadResults.map(item => item.url || item.path || item)
+							this.uploadedSocialSecurityImages = [...this.uploadedSocialSecurityImages, ...fullPaths.map(url => ({ url }))]
+							this.socialSecurityImages = [...this.socialSecurityImages, ...fullPaths]
+							this.form.socialSecurityImgs = this.socialSecurityImages.map(url => this.getShortPath(url))
+							uni.hideLoading()
+							uni.showToast({ title: '涓婁紶鎴愬姛', icon: 'success' })
+						} catch (error) {
+							uni.hideLoading()
+						}
+					}
+				})
 			}
 		}
 	}
@@ -600,12 +1281,12 @@
 		left: 0;
 		right: 0;
 		bottom: 0;
-		height: 24rpx;
-		line-height: 24rpx;
+		height: 40rpx;
+		line-height: 40rpx;	
 		text-align: center;
-		font-size: 16rpx;
+		font-size: 24rpx;
 		color: #ffffff;
-		background: rgba(0, 0, 0, 0.4);
+		background: rgba(0,0,0,0.5);
 	}
 
 	.bottom-btn-wrap {

--
Gitblit v1.9.3