| 
									
										
										
										
											2025-04-24 10:06:53 +08:00
										 |  |  | 
 | 
					
						
							| 
									
										
										
										
											2025-03-23 09:29:40 +08:00
										 |  |  | <template> | 
					
						
							|  |  |  |   <view class="contain"> | 
					
						
							|  |  |  |     <view class="logOut" @click="loginOut">退出登录</view> | 
					
						
							|  |  |  |     <view class="formed"> | 
					
						
							|  |  |  |       <u-form :model="form" | 
					
						
							|  |  |  |               labelAlign="right" | 
					
						
							|  |  |  |               labelWidth="75" | 
					
						
							|  |  |  |               :rules="rules" | 
					
						
							|  |  |  |               ref="uForm"> | 
					
						
							| 
									
										
										
										
											2025-04-01 21:35:18 +08:00
										 |  |  |         <u-form-item :label="'会员姓名'" | 
					
						
							| 
									
										
										
										
											2025-03-23 09:29:40 +08:00
										 |  |  |                      prop="recName"> | 
					
						
							| 
									
										
										
										
											2025-04-01 21:35:18 +08:00
										 |  |  |           <u-input :placeholder="'请输入联系人'" | 
					
						
							| 
									
										
										
										
											2025-03-23 09:29:40 +08:00
										 |  |  |                    v-model.trim="form.recName" /> | 
					
						
							|  |  |  |         </u-form-item> | 
					
						
							| 
									
										
										
										
											2025-04-01 21:35:18 +08:00
										 |  |  |         <u-form-item :label="'联系方式'" | 
					
						
							| 
									
										
										
										
											2025-03-23 09:29:40 +08:00
										 |  |  |                      prop="recPhone"> | 
					
						
							| 
									
										
										
										
											2025-04-01 21:35:18 +08:00
										 |  |  |           <u-input :placeholder="'请输入联系方式'" type="number" maxlength="20" | 
					
						
							| 
									
										
										
										
											2025-03-23 09:29:40 +08:00
										 |  |  |                    v-model.trim="form.recPhone" /> | 
					
						
							|  |  |  |         </u-form-item> | 
					
						
							| 
									
										
										
										
											2025-04-01 21:35:18 +08:00
										 |  |  |         <u-form-item :label="'收货地址'" | 
					
						
							| 
									
										
										
										
											2025-03-23 09:29:40 +08:00
										 |  |  |                      prop="diqu" | 
					
						
							|  |  |  |                      @click='getDiqu'> | 
					
						
							|  |  |  |           <view class="picker"> | 
					
						
							|  |  |  |             <u-input v-model.trim="form.diqu" | 
					
						
							| 
									
										
										
										
											2025-04-01 21:35:18 +08:00
										 |  |  |                      :placeholder="'请选收货地址'" | 
					
						
							| 
									
										
										
										
											2025-03-23 09:29:40 +08:00
										 |  |  |                      border="none"></u-input> | 
					
						
							|  |  |  |             <u-icon name="arrow-down"></u-icon> | 
					
						
							|  |  |  |           </view> | 
					
						
							|  |  |  |         </u-form-item> | 
					
						
							| 
									
										
										
										
											2025-04-01 21:35:18 +08:00
										 |  |  |         <u-form-item :label="'详细地址'" | 
					
						
							| 
									
										
										
										
											2025-03-23 09:29:40 +08:00
										 |  |  |                      prop="recAddress"> | 
					
						
							| 
									
										
										
										
											2025-04-01 21:35:18 +08:00
										 |  |  |           <u-input :placeholder="'请输入详细地址'" | 
					
						
							| 
									
										
										
										
											2025-03-23 09:29:40 +08:00
										 |  |  |                    v-model.trim="form.recAddress" /> | 
					
						
							|  |  |  |         </u-form-item> | 
					
						
							|  |  |  |       </u-form> | 
					
						
							|  |  |  |       <u-button style="margin-top:20px" | 
					
						
							|  |  |  |                 @click="submit" | 
					
						
							|  |  |  |                 text="查询" | 
					
						
							|  |  |  |                 color="#d61820"></u-button> | 
					
						
							|  |  |  |     </view> | 
					
						
							|  |  |  |     <v-address ref="address" | 
					
						
							|  |  |  |                :defaultCode="defaultCode" | 
					
						
							|  |  |  |                @addressData="addressData"></v-address> | 
					
						
							|  |  |  |   </view> | 
					
						
							|  |  |  | </template> | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  | <script> | 
					
						
							|  |  |  | import address from '@/components/address.vue' | 
					
						
							|  |  |  | import * as api from '@/config/regiest' | 
					
						
							|  |  |  | export default { | 
					
						
							|  |  |  |   components: { | 
					
						
							|  |  |  |     'v-address': address, | 
					
						
							|  |  |  |   }, | 
					
						
							|  |  |  |   data() { | 
					
						
							|  |  |  |     return { | 
					
						
							|  |  |  |       defaultCode: [], | 
					
						
							|  |  |  |       form: { | 
					
						
							|  |  |  |         dizhi: [], | 
					
						
							|  |  |  |         recName: '', | 
					
						
							|  |  |  |         recPhone: '', | 
					
						
							|  |  |  |       }, | 
					
						
							|  |  |  |       rules: { | 
					
						
							|  |  |  |         recName: [ | 
					
						
							| 
									
										
										
										
											2025-04-01 21:35:18 +08:00
										 |  |  |           { required: true, trigger: 'blur', message: '请输入联系人' }, | 
					
						
							| 
									
										
										
										
											2025-03-23 09:29:40 +08:00
										 |  |  |         ], | 
					
						
							|  |  |  |         recPhone: [ | 
					
						
							| 
									
										
										
										
											2025-04-01 21:35:18 +08:00
										 |  |  |           { required: true, trigger: 'blur', message: '请输入联系方式' }, | 
					
						
							| 
									
										
										
										
											2025-03-23 09:29:40 +08:00
										 |  |  |         ], | 
					
						
							|  |  |  |         recAddress: [ | 
					
						
							| 
									
										
										
										
											2025-04-01 21:35:18 +08:00
										 |  |  |           { required: true, trigger: 'blur', message: '请输入详细地址' }, | 
					
						
							| 
									
										
										
										
											2025-03-23 09:29:40 +08:00
										 |  |  |         ], | 
					
						
							|  |  |  |         diqu: [ | 
					
						
							| 
									
										
										
										
											2025-04-01 21:35:18 +08:00
										 |  |  |           { required: true, trigger: 'change', message: '请选择收货地址' }, | 
					
						
							| 
									
										
										
										
											2025-03-23 09:29:40 +08:00
										 |  |  |         ], | 
					
						
							|  |  |  |       }, | 
					
						
							|  |  |  |     } | 
					
						
							|  |  |  |   }, | 
					
						
							|  |  |  |   onLoad(options) { | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  |   }, | 
					
						
							|  |  |  |   methods: { | 
					
						
							|  |  |  |     loginOut() { | 
					
						
							|  |  |  | 				uni.setStorageSync('pkCountry', '') | 
					
						
							|  |  |  | 				this.$store.dispatch('LogOut') | 
					
						
							|  |  |  | 				uni.reLaunch({ | 
					
						
							|  |  |  | 					url: '/pages/login/index' | 
					
						
							|  |  |  | 				}) | 
					
						
							|  |  |  | 			}, | 
					
						
							|  |  |  |     submit() { | 
					
						
							|  |  |  |       this.$refs.uForm.validate().then((res) => { | 
					
						
							|  |  |  |         api | 
					
						
							|  |  |  |           .saveSpecial(this.form) | 
					
						
							|  |  |  |           .then((res) => { | 
					
						
							|  |  |  |             if (res.code == 200) { | 
					
						
							|  |  |  |               // // 获取列表
 | 
					
						
							|  |  |  |               // this.getDataList()
 | 
					
						
							|  |  |  |               uni.navigateTo({ url: '/pages/specialMember/list?recName=' + this.form.recName + '&recPhone=' + this.form.recPhone}) | 
					
						
							|  |  |  |             } | 
					
						
							|  |  |  |           }) | 
					
						
							|  |  |  |           .catch((err) => { | 
					
						
							|  |  |  |           }) | 
					
						
							|  |  |  |       }) | 
					
						
							|  |  |  |     }, | 
					
						
							|  |  |  |     getDiqu() { | 
					
						
							|  |  |  |       this.$refs.address.setShow() | 
					
						
							|  |  |  |     }, | 
					
						
							|  |  |  |     addressData(diqu, obj) { | 
					
						
							|  |  |  |       this.form.diqu = diqu | 
					
						
							|  |  |  |       this.form.recProvince = obj.province | 
					
						
							|  |  |  |       this.form.recCity = obj.city | 
					
						
							|  |  |  |       this.form.recCounty = obj.county | 
					
						
							|  |  |  |       this.$forceUpdate() | 
					
						
							|  |  |  |     }, | 
					
						
							|  |  |  |   }, | 
					
						
							|  |  |  | } | 
					
						
							|  |  |  | </script> | 
					
						
							|  |  |  | <style lang="scss" scoped> | 
					
						
							|  |  |  | .contain { | 
					
						
							|  |  |  |   background: url('@/static/images/specialMem.jpg') no-repeat; | 
					
						
							|  |  |  |   background-size: 100% 100%; | 
					
						
							|  |  |  |   height: 100vh; | 
					
						
							|  |  |  |   .formed { | 
					
						
							|  |  |  |     position: absolute; | 
					
						
							|  |  |  |     width: 70%; | 
					
						
							|  |  |  |     left: 50%; | 
					
						
							|  |  |  |     right: 50%; | 
					
						
							|  |  |  |     transform: translateX(-50%); | 
					
						
							|  |  |  |     top: 35%; | 
					
						
							|  |  |  |   } | 
					
						
							|  |  |  |   .logOut{ | 
					
						
							|  |  |  |     text-align: right; | 
					
						
							|  |  |  |     padding: 12rpx; | 
					
						
							|  |  |  |     font-size: 14px; | 
					
						
							|  |  |  |   } | 
					
						
							|  |  |  | } | 
					
						
							|  |  |  | .picker { | 
					
						
							|  |  |  |   display: flex; | 
					
						
							|  |  |  |   justify-content: space-between; | 
					
						
							|  |  |  |   width: 100%; | 
					
						
							|  |  |  |   border-width: 0.5px !important; | 
					
						
							|  |  |  |   border-color: #dadbde !important; | 
					
						
							|  |  |  |   border-style: solid; | 
					
						
							|  |  |  |   border-radius: 4px; | 
					
						
							|  |  |  |   padding: 6px 9px; | 
					
						
							|  |  |  | } | 
					
						
							|  |  |  | </style> |