Browse Source

代码同步

juhuiH5
杨豪 3 years ago
parent
commit
27b6c40a4d
  1. 11
      App.vue
  2. 4
      common/config.js
  3. 2
      main.js
  4. 2
      manifest.json
  5. 14
      pages/index/index.vue
  6. 47
      pages/index/selectCampus.vue
  7. 2
      pages/index/taskDetail.vue
  8. 2
      pages/index/tuijianList.vue
  9. 2
      pages/my/channelshop.vue
  10. 2
      pages/my/index.vue
  11. 2
      pages/my/myVIP.vue
  12. 2
      pages/my/mychannel.vue
  13. 2
      pages/my/shareFriends.vue
  14. 2
      pages/my/teamList.vue
  15. 2
      pages/order/index.vue
  16. 2
      pages/task/search.vue
  17. 2
      pages/task/tasklist.vue
  18. 1
      wsl.txt

11
App.vue

@ -55,7 +55,16 @@
}); });
}, },
onShow: function() { onShow: function(e) {
console.log(e.query.code)
if(e && e.query.code){ //h5code
let code = e.query.code
this.$queue.setData('wxCode', code);
}
if(e && e.query.latng){ //h5
this.$queue.setData('latH', e.query.latng.split(',')[0]);
this.$queue.setData('lngH', e.query.latng.split(',')[1]);
}
}, },
onHide: function() {} onHide: function() {}
}; };

4
common/config.js

@ -1,6 +1,6 @@
// const ROOTPATH1 = "http://10.11.32.109:8891/sqx_fast"; // const ROOTPATH1 = "http://10.11.32.109:8891/sqx_fast";
const ROOTPATH1 = "http://10.11.32.107:8891/sqx_fast"; // const ROOTPATH1 = "http://10.11.32.107:8891/sqx_fast";
// const ROOTPATH1 = "http://waimai.n.gznl.top/sqx_fast"; const ROOTPATH1 = "http://waimai.admin.service.yiqihuiju.com/sqx_fast";
const ROOTPATH = "https://bwc.xianmxkj.com/sqx_fast"; const ROOTPATH = "https://bwc.xianmxkj.com/sqx_fast";
module.exports = { module.exports = {
APIHOST: ROOTPATH, APIHOST: ROOTPATH,

2
main.js

@ -27,6 +27,8 @@ Vue.config.productionTip = false
Vue.prototype.$Request = HttpRequest; Vue.prototype.$Request = HttpRequest;
Vue.prototype.$queue = queue; Vue.prototype.$queue = queue;
Vue.prototype.$WechatUrl = 'http://waimai.admin.service.yiqihuiju.com';
Vue.prototype.$Sysconf = HttpRequest.config; Vue.prototype.$Sysconf = HttpRequest.config;
Vue.prototype.$SysCache = HttpCache; Vue.prototype.$SysCache = HttpCache;
Vue.mixin(share) Vue.mixin(share)

2
manifest.json

@ -166,7 +166,7 @@
}, },
"h5" : { "h5" : {
"title" : "惠聚", "title" : "惠聚",
"domain" : "https://bwc.xianmxkj.com", "domain" : "http://waimai.admin.service.yiqihuiju.com",
"router" : { "router" : {
"mode" : "history" "mode" : "history"
}, },

14
pages/index/index.vue

@ -4,7 +4,7 @@
<view class="header"> <view class="header">
<view class="nav"> <view class="nav">
<view class="navLeft" @tap="goSelectCity"> <view class="navLeft" @tap="goSelectCity">
<view class="localName">{{ city }}</view> <view class="localName">{{ localCampus }}</view>
<image src="../../static/img/home/xia.png" style="width: 20rpx;height: 14rpx;"></image> <image src="../../static/img/home/xia.png" style="width: 20rpx;height: 14rpx;"></image>
<!-- <text class="cuIcon-unfold"></text> --> <!-- <text class="cuIcon-unfold"></text> -->
</view> </view>
@ -134,9 +134,6 @@
}, },
onLoad(e) { onLoad(e) {
let that = this; let that = this;
// #ifdef H5
that.initMyPosition();
// #endif
if (e.userByinvitationId) { if (e.userByinvitationId) {
this.$queue.setData('userByinvitationId', e.userByinvitationId); this.$queue.setData('userByinvitationId', e.userByinvitationId);
} }
@ -215,6 +212,7 @@
let that = this; let that = this;
var city = this.$queue.getData('city'); var city = this.$queue.getData('city');
var localCampus = this.$queue.getData('localCampus'); var localCampus = this.$queue.getData('localCampus');
console.log(localCampus)
if (city && localCampus) { if (city && localCampus) {
console.log(city) console.log(city)
this.latitude = this.$queue.getData('latitude'); this.latitude = this.$queue.getData('latitude');
@ -225,6 +223,10 @@
this.page = 1; this.page = 1;
this.getHaoDianTuiJian1(); this.getHaoDianTuiJian1();
this.getHaoDianTuiJian(); this.getHaoDianTuiJian();
} else{
// #ifdef H5
that.initMyPosition();
// #endif
} }
let userId = this.$queue.getData('userId'); let userId = this.$queue.getData('userId');
@ -506,12 +508,14 @@
}, },
// //
wxGetLocation(){ wxGetLocation(){
var that = this;
var pageUrl = encodeURIComponent(window.location.href); var pageUrl = encodeURIComponent(window.location.href);
jweixin.wxGetLocation(pageUrl).then((result)=>{ jweixin.wxGetLocation(pageUrl).then((result)=>{
let str = `output=jsonp&location=${result.latitude},${result.longitude}&key=LH3BZ-NYN62-2SIUW-CGKY5-K5MXT-FWFOI` let str = `output=jsonp&location=${result.latitude},${result.longitude}&key=LH3BZ-NYN62-2SIUW-CGKY5-K5MXT-FWFOI`
this.$jsonp('https://apis.map.qq.com/ws/geocoder/v1/?'+str).then(res=>{ this.$jsonp('https://apis.map.qq.com/ws/geocoder/v1/?'+str).then(res=>{
uni.hideLoading(); uni.hideLoading();
if(res.status == 0){ if(res.status == 0){
console.log(res)
that.setLocation(result.latitude, result.longitude, res) that.setLocation(result.latitude, result.longitude, res)
} }
}) })
@ -699,7 +703,7 @@
}); });
//#endif //#endif
//#ifdef H5 //#ifdef H5
window.location.href = 'http://waimai.n.gznl.top/sqx_fast/appLogin/wechatLogin'; window.location.href = this.$WechatUrl + '/sqx_fast/appLogin/wechatLogin';
//#endif //#endif
}, },
navClick: function(res) { navClick: function(res) {

47
pages/index/selectCampus.vue

@ -28,6 +28,7 @@
<script> <script>
import ZhToPinYin from '@/js_sdk/tui-zh-pinyin/tui-zh-pinyin.js'; import ZhToPinYin from '@/js_sdk/tui-zh-pinyin/tui-zh-pinyin.js';
import jweixin from '@/common/jweixin.js'
var QQMapWX = require('@/js_sdk/qqmap-wx-jssdk1.2/qqmap-wx-jssdk.js'); var QQMapWX = require('@/js_sdk/qqmap-wx-jssdk1.2/qqmap-wx-jssdk.js');
var qqmapsdk; var qqmapsdk;
// #ifdef MP-WEIXIN // #ifdef MP-WEIXIN
@ -51,6 +52,11 @@
}, },
onLoad: function(options) { onLoad: function(options) {
const that = this; const that = this;
var city = this.$queue.getData("city")
console.log(this.$queue.getData("city"))
if (city != '') {
this.city = city
}
// #ifdef MP-WEIXIN // #ifdef MP-WEIXIN
// API // API
qqmapsdk = new QQMapWX({ qqmapsdk = new QQMapWX({
@ -73,12 +79,29 @@
this.$queue.setData('localCampus', item.name); this.$queue.setData('localCampus', item.name);
} }
//#endif //#endif
//#ifdef H5
var city = this.$queue.getData("city") let lat = this.$queue.getData("latH")
console.log(this.$queue.getData("city")) let lng = this.$queue.getData("lngH")
if (city != '') { console.log(lat,'latlatlatlat')
this.city = city if(lat){
let str = `output=jsonp&location=${lat},${lng}&key=LH3BZ-NYN62-2SIUW-CGKY5-K5MXT-FWFOI`
this.$jsonp('https://apis.map.qq.com/ws/geocoder/v1/?'+str).then(res=>{
if(res.status == 0){
console.log(res,'resresresresres')
this.latitude = res.result.location.lat;
this.longitude = res.result.location.lng;
this.weizhi.names = res.result.formatted_addresses.recommend;
this.weizhi.dizhi = res.result.address
this.city = res.result.address_component.city
this.$queue.setData('latitude', this.latitude);
this.$queue.setData('longitude', this.longitude);
this.$queue.setData('city', res.result.address_component.city);
this.$queue.setData('localCampus', res.result.formatted_addresses.recommend);
}
})
} }
//#endif
}, },
methods: { methods: {
gocity() { gocity() {
@ -95,11 +118,14 @@
}, },
saveAddress() { saveAddress() {
console.log("this.city____:" + this.city) console.log("this.city____:" + this.city)
console.log("this.this.weizhi.names:" + this.weizhi.names)
this.$queue.setData('latitude', this.latitude); this.$queue.setData('latitude', this.latitude);
this.$queue.setData('longitude', this.longitude); this.$queue.setData('longitude', this.longitude);
this.$queue.setData('city', this.city); this.$queue.setData('city', this.city);
this.$queue.setData('localCampus', this.weizhi.names); // this.$queue.setData('localCampus', this.weizhi.names);
uni.navigateBack(); uni.switchTab({
url: '/pages/index/index'
})
}, },
initLocation(latitude, longitude) { initLocation(latitude, longitude) {
var that = this; var that = this;
@ -127,6 +153,7 @@
}, },
dingwei() { dingwei() {
const that = this; const that = this;
//#ifdef MP-WEIXIN
uni.chooseLocation({ uni.chooseLocation({
success: function(res) { success: function(res) {
console.log(res) console.log(res)
@ -145,6 +172,12 @@
} }
} }
}); });
//#endif
//#ifdef H5
var pageUrl = window.location.href;
var url1 = `https://apis.map.qq.com/tools/locpicker?search=1&type=0&backurl=${pageUrl}&key=LH3BZ-NYN62-2SIUW-CGKY5-K5MXT-FWFOI&referer=myapp`
location.href= url1;
//#endif
} }
} }
} }

2
pages/index/taskDetail.vue

@ -747,7 +747,7 @@
}); });
//#endif //#endif
//#ifdef H5 //#ifdef H5
window.location.href = 'http://waimai.n.gznl.top/sqx_fast/appLogin/wechatLogin'; window.location.href = 'http://waimai.admin.service.yiqihuiju.com/sqx_fast/appLogin/wechatLogin';
//#endif //#endif
}, },
} }

2
pages/index/tuijianList.vue

@ -134,7 +134,7 @@
}); });
//#endif //#endif
//#ifdef H5 //#ifdef H5
window.location.href = 'http://waimai.n.gznl.top/sqx_fast/appLogin/wechatLogin'; window.location.href = 'http://waimai.admin.service.yiqihuiju.com/sqx_fast/appLogin/wechatLogin';
//#endif //#endif
}, },
goDetail(nav) { goDetail(nav) {

2
pages/my/channelshop.vue

@ -44,7 +44,7 @@
}); });
//#endif //#endif
//#ifdef H5 //#ifdef H5
window.location.href = 'http://waimai.n.gznl.top/sqx_fast/appLogin/wechatLogin'; window.location.href = 'http://waimai.admin.service.yiqihuiju.com/sqx_fast/appLogin/wechatLogin';
//#endif //#endif
}, },
clickItem: function(options) { clickItem: function(options) {

2
pages/my/index.vue

@ -665,7 +665,7 @@
}); });
//#endif //#endif
//#ifdef H5 //#ifdef H5
window.location.href = 'http://waimai.n.gznl.top/sqx_fast/appLogin/wechatLogin'; window.location.href = this.$WechatUrl + '/sqx_fast/appLogin/wechatLogin';
//#endif //#endif
}, },
//退 //退

2
pages/my/myVIP.vue

@ -173,7 +173,7 @@
}); });
//#endif //#endif
//#ifdef H5 //#ifdef H5
window.location.href = 'http://waimai.n.gznl.top/sqx_fast/appLogin/wechatLogin'; window.location.href = 'http://waimai.admin.service.yiqihuiju.com/sqx_fast/appLogin/wechatLogin';
//#endif //#endif
}, },
btns() { btns() {

2
pages/my/mychannel.vue

@ -48,7 +48,7 @@
}); });
//#endif //#endif
//#ifdef H5 //#ifdef H5
window.location.href = 'http://waimai.n.gznl.top/sqx_fast/appLogin/wechatLogin'; window.location.href = 'http://waimai.admin.service.yiqihuiju.com/sqx_fast/appLogin/wechatLogin';
//#endif //#endif
} }
} }

2
pages/my/shareFriends.vue

@ -179,7 +179,7 @@
}); });
//#endif //#endif
//#ifdef H5 //#ifdef H5
window.location.href = 'http://waimai.n.gznl.top/sqx_fast/appLogin/wechatLogin'; window.location.href = 'http://waimai.admin.service.yiqihuiju.com/sqx_fast/appLogin/wechatLogin';
//#endif //#endif
}, },
showModal() { showModal() {

2
pages/my/teamList.vue

@ -55,7 +55,7 @@
}); });
//#endif //#endif
//#ifdef H5 //#ifdef H5
window.location.href = 'http://waimai.n.gznl.top/sqx_fast/appLogin/wechatLogin'; window.location.href = 'http://waimai.admin.service.yiqihuiju.com/sqx_fast/appLogin/wechatLogin';
//#endif //#endif
} }
} }

2
pages/order/index.vue

@ -209,7 +209,7 @@
}); });
//#endif //#endif
//#ifdef H5 //#ifdef H5
window.location.href = 'http://waimai.n.gznl.top/sqx_fast/appLogin/wechatLogin'; window.location.href = 'http://waimai.admin.service.yiqihuiju.com/sqx_fast/appLogin/wechatLogin';
//#endif //#endif
}, },
goDetail(id) { goDetail(id) {

2
pages/task/search.vue

@ -67,7 +67,7 @@
}); });
//#endif //#endif
//#ifdef H5 //#ifdef H5
window.location.href = 'http://waimai.n.gznl.top/sqx_fast/appLogin/wechatLogin'; window.location.href = 'http://waimai.admin.service.yiqihuiju.com/sqx_fast/appLogin/wechatLogin';
//#endif //#endif
}, },
rtBubble() { rtBubble() {

2
pages/task/tasklist.vue

@ -122,7 +122,7 @@
}); });
//#endif //#endif
//#ifdef H5 //#ifdef H5
window.location.href = 'http://waimai.n.gznl.top/sqx_fast/appLogin/wechatLogin'; window.location.href = 'http://waimai.admin.service.yiqihuiju.com/sqx_fast/appLogin/wechatLogin';
//#endif //#endif
}, },
// //

1
wsl.txt

@ -0,0 +1 @@
rsync -r ./ root@39.105.46.0:/root/html/huiju_h5
Loading…
Cancel
Save