1.新增门店进件添加经纬度和地址

huipay-master
杨杰 2 years ago
parent 14abcdac7a
commit 021def2f1a
  1. 1
      pages/index/map/map.vue
  2. 2
      pages/index/mcc-list/mcc-list.vue
  3. 56
      pages/index/merchant-incoming-parts/merchant-incoming-parts.vue

@ -117,7 +117,6 @@
}, },
// //
handleConfirm() { handleConfirm() {
console.log('======-----------' + JSON.stringify(this.address));
uni.$emit('onAddressChange', this.address); uni.$emit('onAddressChange', this.address);
app.globalData.storeMessage = this.address; app.globalData.storeMessage = this.address;
setTimeout(function() { setTimeout(function() {

@ -53,7 +53,7 @@
this.getMccList(); this.getMccList();
}, },
//mcc //mcc
changemcc(item) { changemcc(item) {
app.globalData.mccid = item.maccCode; app.globalData.mccid = item.maccCode;
app.globalData.mccname = item.name; app.globalData.mccname = item.name;
uni.navigateBack({}) uni.navigateBack({})

@ -633,9 +633,10 @@
</view> </view>
<view class="username"> <view class="username">
<view class="namecont">门店地址</view> <view class="namecont">门店地址</view>
<input placeholder="请选择门店或者输入地址" v-model="storeAddress" style="width: 70%;" <input placeholder="请选择门店或者输入地址" @blur="formSubmit()" v-model="storeAddress" style="width: 70%;"
placeholder-style="color: #bfbfbf;font-size:14px;padding-top:2px;" /> placeholder-style="color: #bfbfbf;font-size:14px;padding-top:2px;" />
<image src="../../../static/img/location.png" mode="widthFix" class="iconw" @click="jumpChangeAddress()"> <image src="../../../static/img/location.png" mode="widthFix" class="iconw"
@click="jumpChangeAddress()">
</image> </image>
</view> </view>
<view class="notes font16" style="border-bottom: 0px;"> <view class="notes font16" style="border-bottom: 0px;">
@ -765,6 +766,10 @@
getBankCardBin, getBankCardBin,
recognizeBankAccount recognizeBankAccount
} from '../../../Utils/Api.js'; } from '../../../Utils/Api.js';
const QQMapWX = require('../../../Utils/js/qqmap-wx-jssdk');
const qqmapsdk = new QQMapWX({
key: '7UMBZ-HFEHX-HSD4Q-Z3QY6-OQKN7-2QBDB'
})
let app = getApp(); let app = getApp();
export default { export default {
components: { components: {
@ -859,7 +864,7 @@
merId: '', //id merId: '', //id
merDetailInfo: '', // merDetailInfo: '', //
rateCodeList: [], // rateCodeList: [], //
merRateList: [] // merRateList: [], //
} }
}, },
computed: { computed: {
@ -916,7 +921,7 @@
app.globalData.mccname = ''; app.globalData.mccname = '';
app.globalData.branchBankNo = ''; app.globalData.branchBankNo = '';
app.globalData.clearNo = ''; app.globalData.clearNo = '';
app.globalData.storeMessage = ''; app.globalData.storeMessage = '';
app.globalData.depositaryBank = ''; app.globalData.depositaryBank = '';
}, },
methods: { methods: {
@ -1604,6 +1609,10 @@
// this.storeaccount = res.return_data.storeModel.account.loginName; // this.storeaccount = res.return_data.storeModel.account.loginName;
this.storename = res.return_data.storeModel.name; this.storename = res.return_data.storeModel.name;
this.storephone = res.return_data.storeModel.telephone; this.storephone = res.return_data.storeModel.telephone;
this.storeAddress = res.return_data.storeModel.storeRegion.address;
this.storeareaCode = res.return_data.storeModel.storeRegion.areaCode;
this.storelongitude = res.return_data.storeModel.storeRegion.longitude;
this.storelatitude = res.return_data.storeModel.storeRegion.latitude;
this.getImgSignedUrl(6, res.return_data.storeModel.doorHeadImg, 2); this.getImgSignedUrl(6, res.return_data.storeModel.doorHeadImg, 2);
this.getImgSignedUrl(7, res.return_data.storeModel.cashRegisterImg, 2); this.getImgSignedUrl(7, res.return_data.storeModel.cashRegisterImg, 2);
this.getImgSignedUrl(8, res.return_data.storeModel.internalImg, 2); this.getImgSignedUrl(8, res.return_data.storeModel.internalImg, 2);
@ -2141,6 +2150,26 @@
url: '/pages/index/map/map' url: '/pages/index/map/map'
}) })
}, },
//
formSubmit() {
//
qqmapsdk.geocoder({
//
address: this.storeAddress, // address: '西74'
success: res => { //
this.storeareaCode = res.result.ad_info.adcode;
this.storelongitude = res.result.location.lng;
this.storelatitude = res.result.location.lat;
},
fail: function(error) {
console.error(error);
},
complete: function(res) {
console.log(res);
}
})
},
// //
submitsotre() { submitsotre() {
let that = this; let that = this;
@ -2176,6 +2205,14 @@
}); });
return; return;
} }
if (!that.storeareaCode) {
uni.showToast({
title: '请输入正确的门店地址',
icon: "none",
duration: 2000
});
return;
}
if (!that.storeimg1) { if (!that.storeimg1) {
uni.showToast({ uni.showToast({
title: '请上传门头照片', title: '请上传门头照片',
@ -2218,10 +2255,13 @@
"doorHeadImg": that.uploadstoreimg1, "doorHeadImg": that.uploadstoreimg1,
"cashRegisterImg": that.uploadstoreimg2, "cashRegisterImg": that.uploadstoreimg2,
"internalImg": that.uploadstoreimg3, "internalImg": that.uploadstoreimg3,
"address": that.storeAddress, "storeRegion": {
"areaCode": that.storeareaCode, "address": that.storeAddress,
"longitude": that.storelongitude, "areaCode": that.storeareaCode,
"latitude": that.storelatitude "longitude": that.storelongitude,
"latitude": that.storelatitude
}
} }
configMerStore(datas).then(res => { configMerStore(datas).then(res => {
uni.hideLoading(); uni.hideLoading();

Loading…
Cancel
Save