mirror of
https://gitee.com/ShopeX/ECShopX_mobile-frontend
synced 2026-08-12 06:15:38 +08:00
注册添加千人千码参数
This commit is contained in:
@@ -86,6 +86,7 @@ function SpLogin(props, ref) {
|
||||
// const { uid } = entryLaunch.getLaunchParams()
|
||||
const { uid, dtid } = Taro.getStorageSync(SG_ROUTER_PARAMS)
|
||||
const { gu_user_id, gu } = Taro.getStorageSync(SG_GUIDE_PARAMS)
|
||||
const { source_id, monitor_id, latest_source_id, latest_monitor_id } = Taro.getStorageSync('sourceInfo') // 千人千码参数
|
||||
if (uid) {
|
||||
// 分销绑定
|
||||
params['uid'] = uid
|
||||
@@ -110,6 +111,19 @@ function SpLogin(props, ref) {
|
||||
params['work_userid'] = work_userid
|
||||
}
|
||||
|
||||
if (source_id) {
|
||||
params['source_id'] = source_id
|
||||
}
|
||||
if (monitor_id) {
|
||||
params['monitor_id'] = monitor_id
|
||||
}
|
||||
if (latest_source_id) {
|
||||
params['latest_source_id'] = latest_source_id
|
||||
}
|
||||
if (latest_monitor_id) {
|
||||
params['latest_monitor_id'] = latest_monitor_id
|
||||
}
|
||||
|
||||
try {
|
||||
const { token, is_new } = await api.wx.newlogin(params)
|
||||
if (token) {
|
||||
|
||||
@@ -110,6 +110,7 @@ export default class Login extends Component {
|
||||
}
|
||||
|
||||
async handleSubmit() {
|
||||
const { source_id, monitor_id, latest_source_id, latest_monitor_id } = Taro.getStorageSync('sourceInfo') // 千人千码参数
|
||||
const { redirect } = this.$instance.router.params
|
||||
const { loginType } = this.state
|
||||
const { mobile, password, vcode } = this.state.info
|
||||
@@ -145,6 +146,19 @@ export default class Login extends Component {
|
||||
|
||||
params['auth_type'] = 'local'
|
||||
|
||||
if (source_id) {
|
||||
params['source_id'] = source_id
|
||||
}
|
||||
if (monitor_id) {
|
||||
params['monitor_id'] = monitor_id
|
||||
}
|
||||
if (latest_source_id) {
|
||||
params['latest_source_id'] = latest_source_id
|
||||
}
|
||||
if (latest_monitor_id) {
|
||||
params['latest_monitor_id'] = latest_monitor_id
|
||||
}
|
||||
|
||||
try {
|
||||
const { token, error_message } = await api.wx.newloginh5(params)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user