1.新增一键加油功能

yj-dev
杨杰 3 years ago
parent f7e0dfa745
commit dece3803d4
  1. 16
      App.vue
  2. 6
      pages/goods/refuel-details/refuel-details.vue
  3. 20
      pages/goods/refuel/refuel.vue
  4. 9
      pages/tabBar/home/home.vue

@ -5,15 +5,15 @@
// brestUrl: 'http://192.168.3.4:9302/brest', // brestUrl: 'http://192.168.3.4:9302/brest',
// imgUrl: 'https://192.168.3.4:9301/filesystem/', // imgUrl: 'https://192.168.3.4:9301/filesystem/',
// //
// url: 'https://hsg.dctpay.com/crest', url: 'https://hsg.dctpay.com/crest',
// imgUrl: 'https://hsg.dctpay.com/filesystem/', imgUrl: 'https://hsg.dctpay.com/filesystem/',
// brestUrl : 'https://hsg.dctpay.com/brest', brestUrl : 'https://hsg.dctpay.com/brest',
// imageWxImg:'https://hsg.dctpay.com/filesystem/wxApplets/', imageWxImg:'https://hsg.dctpay.com/filesystem/wxApplets/',
// //
url: 'https://hsgcs.dctpay.com/crest', // url: 'https://hsgcs.dctpay.com/crest',
brestUrl : 'https://hsgcs.dctpay.com/brest', // brestUrl : 'https://hsgcs.dctpay.com/brest',
imgUrl: 'https://hsgcs.dctpay.com/filesystem/', // imgUrl: 'https://hsgcs.dctpay.com/filesystem/',
imageWxImg:'https://hsgcs.dctpay.com/filesystem/wxApplets/', // imageWxImg:'https://hsgcs.dctpay.com/filesystem/wxApplets/',
userInfo: "", userInfo: "",
brestUserInfo : '', brestUserInfo : '',
openId: '', openId: '',

@ -230,7 +230,7 @@
this.getDictionaryByCodeTypeMoney(); this.getDictionaryByCodeTypeMoney();
}, },
onShow() { onShow() {
this.user = app.globalData.userInfo; this.user = app.globalData.userInfo;
}, },
onUnload() { onUnload() {
if (app.globalData.accountType && app.globalData.accountType == '000000#/') { if (app.globalData.accountType && app.globalData.accountType == '000000#/') {
@ -266,7 +266,7 @@
isTyAgent: this.isTyAgent isTyAgent: this.isTyAgent
} }
recentGasStation(params).then(res => { recentGasStation(params).then(res => {
uni.hideLoading(); uni.hideLoading();
if (res.return_code == '000000') { if (res.return_code == '000000') {
this.storeList = res.return_data; this.storeList = res.return_data;
if (!this.oilNo) { if (!this.oilNo) {
@ -306,7 +306,7 @@
isTyAgent: this.isTyAgent isTyAgent: this.isTyAgent
} }
getGasDetailByStoreKey(params).then(res => { getGasDetailByStoreKey(params).then(res => {
uni.hideLoading(); uni.hideLoading();
if (res.return_code == '000000') { if (res.return_code == '000000') {
this.storeList = res.return_data; this.storeList = res.return_data;
if (!this.oilNo) { if (!this.oilNo) {

@ -161,14 +161,14 @@
if (app.globalData.accountId) { if (app.globalData.accountId) {
that.isTyAgent = true; that.isTyAgent = true;
} }
uni.getLocation({ that.getGasStoreList();
type: 'wgs84', // uni.getLocation({
success: function(res) { // type: 'wgs84',
that.latitudeful = res.latitude; // success: function(res) {
that.longitudeful = res.longitude; // that.latitudeful = res.latitude;
that.getGasStoreList(); // that.longitudeful = res.longitude;
} // }
}) // })
}, },
onReachBottom() { onReachBottom() {
this.getGasStoreList(); this.getGasStoreList();
@ -254,8 +254,8 @@
distance: this.distanceNum, distance: this.distanceNum,
regionId: app.globalData.cityId, regionId: app.globalData.cityId,
oilNoName: this.onilName, oilNoName: this.onilName,
latitude: this.latitudeful, latitude: app.globalData.latitude,
longitude: this.longitudeful, longitude: app.globalData.longitude,
pageNum: pagenum, pageNum: pagenum,
pageSize: this.pageSize, pageSize: this.pageSize,
isTyAgent: this.isTyAgent isTyAgent: this.isTyAgent

@ -249,12 +249,7 @@
}) })
// #endif // #endif
// //
// #ifdef MP
this.postionIng(); this.postionIng();
// #endif
// #ifdef H5
this.getCoordinates();
// #endif
uni.getStorage({ uni.getStorage({
key: "user", key: "user",
success(e) { success(e) {
@ -284,7 +279,7 @@
methods: { methods: {
jumpcdx() { jumpcdx() {
location.href = location.href =
'https://open.weixin.qq.com/connect/oauth2/authorize?appid=wxa075e8509802f826&redirect_uri=https%3A%2F%2Fhsgcs.dctpay.com%2FhsgH5%2Findex.html%23%2F&response_type=code&scope=snsapi_base&state=1#wechat_redirect'; 'https://open.weixin.qq.com/connect/oauth2/authorize?appid=wxa075e8509802f826&redirect_uri=https%3A%2F%2Fhsg.dctpay.com%2FhsgH5%2Findex.html%23%2F&response_type=code&scope=snsapi_base&state=1#wechat_redirect';
}, },
// //
getCmsContentcmsContent() { getCmsContentcmsContent() {
@ -388,7 +383,7 @@
type: 'wgs84', type: 'wgs84',
success: function(res) { success: function(res) {
app.globalData.latitude = res.latitude; app.globalData.latitude = res.latitude;
app.globalData.longitude = res.longitude; app.globalData.longitude = res.longitude;
// that.findByLatAndLng(res.longitude, res.latitude); // that.findByLatAndLng(res.longitude, res.latitude);
// #ifdef H5 // #ifdef H5
that.getUserLocation(res.longitude, res.latitude); that.getUserLocation(res.longitude, res.latitude);

Loading…
Cancel
Save