Zory 16 часов назад
Родитель
Сommit
24175c0193
3 измененных файлов с 12 добавлено и 13 удалено
  1. 6 9
      pages/index/index.vue
  2. 4 2
      pages/service/chat/chat.vue
  3. 2 2
      static/js/request.js

+ 6 - 9
pages/index/index.vue

@@ -104,17 +104,14 @@ export default {
 				size:10,
 				loading:false,
 				isMore:false
-			}
+			},
+			optionData:null
 		}
 	},
-	onLoad({store}) {
+	onLoad(options) {
 		app = this;
-		var poiId = uni.getStorageSync("poiId");
-		if (!poiId && !store) {
-			app.storeId = "7644106137976965139";
-		} else {
-			app.storeId = poiId;
-		}
+		app.storeId = options.store?options.store:'7644106137976965139';
+		app.optionData = options;
 		app.getData()
 	},
 	methods: {
@@ -158,7 +155,7 @@ export default {
 		getData(){
 			if (!app.storeId) return ;
 			app.loading = true;
-			Api.data({"store":app.storeId}).then((res)=>{
+			Api.data({"store":app.storeId,"option":JSON.stringify(app.optionData)}).then((res)=>{
 				app.loading = false;
 				if (res.code !== 1) {
 					return app.$dialog.showSuccess(res.msg)

+ 4 - 2
pages/service/chat/chat.vue

@@ -220,8 +220,10 @@ export default {
 			sendId:null,
 			myid:"",
 			pushObj:null,
-            wsAuth:"https://tran.jsshuita.cn/plugin/webman/push/auth",
-            wsUrl: 'wss://tran.jsshuita.cn/ws',
+            // wsAuth:"https://tran.jsshuita.cn/plugin/webman/push/auth",
+            // wsUrl: 'wss://tran.jsshuita.cn/ws',
+            wsAuth:"http://127.0.0.1:9881/plugin/webman/push/auth",
+            wsUrl: 'ws://127.0.0.1:3131',
 			page:2,
 			size:10,
 			orderPage:1,

+ 2 - 2
static/js/request.js

@@ -15,8 +15,8 @@ const axg = {
 		return '/api';
 		// #endif
 		// #ifdef MP
-		return 'https://tran.jsshuita.cn/dy'
-		// return 'http://127.0.0.1:9881/dy'
+		// return 'https://tran.jsshuita.cn/dy'
+		return 'http://127.0.0.1:9881/dy'
 		// #endif
 	},
 	toast: function(text, duration, success) {