feat: 完善双端演示注册与红娘服务闭环
This commit is contained in:
@@ -5,6 +5,7 @@
|
||||
*/
|
||||
const { appStore } = require('../../stores');
|
||||
const { API_BASE_URL } = require('../../env');
|
||||
const { IS_DEV } = require('../../env');
|
||||
|
||||
Page({
|
||||
data: {
|
||||
@@ -13,6 +14,7 @@ Page({
|
||||
loading: false,
|
||||
error: '',
|
||||
platformName: getApp().globalData.platformName,
|
||||
demoEnabled: IS_DEV,
|
||||
},
|
||||
|
||||
onLoad() {
|
||||
@@ -51,10 +53,11 @@ Page({
|
||||
});
|
||||
|
||||
if (res.success) {
|
||||
const { accessToken, name } = res.data;
|
||||
const { accessToken, name, operatorId } = res.data;
|
||||
// 存储token
|
||||
wx.setStorageSync('operatorToken', accessToken);
|
||||
wx.setStorageSync('operatorName', name);
|
||||
wx.setStorageSync('operatorId', operatorId);
|
||||
|
||||
// 跳转到红娘工作台
|
||||
wx.reLaunch({ url: '/pages/matchmaker-workbench/matchmaker-workbench' });
|
||||
@@ -75,4 +78,8 @@ Page({
|
||||
showCancel: false,
|
||||
});
|
||||
},
|
||||
|
||||
onDemoRegister() {
|
||||
wx.navigateTo({ url: '/pages/matchmaker-register/matchmaker-register' });
|
||||
},
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user