@conecli/cone-render 0.8.21-shop-beta.2 → 0.8.21-shop-beta.5

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1 +1 @@
1
- import Taro from '@tarojs/taro'
2
1
  urlCookie
3
2
  public config: {
4
3
  [key: string]: any
5
4
  }
6
5
  public lazyContainer: CommonInterFace.lazyContainer
7
6
  this.config = {}
8
7
  pin: cookie.get('pin') || ''
9
8
  })
10
9
  if(!this.checkStatusAndLoginPromise){
11
10
  this.checkStatusAndLoginPromise = new Promise(async (resolve, reject) => {
12
11
  try {
13
12
  const getLoginState = await this.doCheckLoginStateAndForApiCheck()
14
13
  if(getLoginState){
15
14
  resolve(true)
16
15
  }else {
17
16
  this.toLogin(options)
18
17
  reject(false)
19
18
  }
20
19
  }catch (e) {
21
20
  this.toLogin(options)
22
21
  reject(false)
23
22
  }
24
23
  })
25
24
  return this.checkStatusAndLoginPromise
26
25
  }else {
27
26
  return this.checkStatusAndLoginPromise.then(() => {
28
27
  return Promise.resolve(true)
29
28
  }).catch (() => {
30
29
  this.toLogin(options)
31
30
  return Promise.reject(true)
32
31
  })
33
32
  }
34
33
 
35
34
  doCheckLoginStateAndForApiCheck() {
36
35
  if(this.info.loginState){
37
36
  return Promise.resolve(true)
38
37
  }else {
39
38
  return new Promise((resolve, reject) => {
40
39
  if(this.info.isJingGouMiniViewState){
41
40
  const getWqAuthToken = cookie.get("wq_auth_token")
42
41
  if(getWqAuthToken){
43
42
  this.info.loginState = true
44
43
  resolve(true)
45
44
  }else {
46
45
  reject(false)
47
46
  }
48
47
  }else{
49
48
  Taro.request({
50
49
  url: api.isLogin,
51
50
  jsonp:true,
52
51
  timeout: 3000,
53
52
  success: (res) => {
54
53
  const {statusCode,data} = res
55
54
  if (statusCode === 200 && data?.islogin && Number(data.islogin) === 1) {
56
55
  this.info.loginState = true
57
56
  resolve(true);
58
57
  } else {
59
58
  reject(false)
60
59
  }
61
60
  },
62
61
  fail:(err) => {
63
62
  console.log("登录检查异常", err)
64
63
  reject(false)
65
64
  }
66
65
  })
67
66
  }
68
67
  })
69
68
  }
70
69
  }
71
70
 
72
71
  try {
73
72
  const getLoginState = await this.doCheckLoginStateAndForApiCheck()
74
73
  if(getLoginState){
75
74
  const { pin } = await this.getLoginCookie();
76
75
  this.info.userInfo = {
77
76
  pin,
78
77
  encodePin: encodeURIComponent(pin),
79
78
  ptkey: '',
80
79
  }
81
80
  resolve(true)
82
81
  }else {
83
82
  reject(false)
84
83
  }
85
84
  }catch (e) {
86
85
  reject(false)
87
86
  }
88
87
  })
89
88
  if(un_area && un_area.length > 0){
90
89
  this.info.pageInfo.address = un_area
91
90
  this.info.pageInfo.un_area = un_area
92
91
  this.info.pageInfo.addressCommaStr = un_area.replace(/_/g, ',')
93
92
  }
93
+ import Taro from '@tarojs/taro'
94
94
  urlCookie
95
95
  public config: {
96
96
  [key: string]: any
97
97
  }
98
98
  public lazyContainer: CommonInterFace.lazyContainer
99
99
  console.log('测试 containerWidth ====== 初始化=== _getConfig', this.info.sysInfo.containerWidth)
100
100
  this.config = {}
101
101
  pin: cookie.get('pin') || ''
102
102
  })
103
103
  if(!this.checkStatusAndLoginPromise){
104
104
  this.checkStatusAndLoginPromise = new Promise(async (resolve, reject) => {
105
105
  try {
106
106
  const getLoginState = await this.doCheckLoginStateAndForApiCheck()
107
107
  if(getLoginState){
108
108
  resolve(true)
109
109
  }else {
110
110
  this.toLogin(options)
111
111
  reject(false)
112
112
  }
113
113
  }catch (e) {
114
114
  this.toLogin(options)
115
115
  reject(false)
116
116
  }
117
117
  })
118
118
  return this.checkStatusAndLoginPromise
119
119
  }else {
120
120
  return this.checkStatusAndLoginPromise.then(() => {
121
121
  return Promise.resolve(true)
122
122
  }).catch (() => {
123
123
  this.toLogin(options)
124
124
  return Promise.reject(true)
125
125
  })
126
126
  }
127
127
 
128
128
  doCheckLoginStateAndForApiCheck() {
129
129
  if(this.info.loginState){
130
130
  return Promise.resolve(true)
131
131
  }else {
132
132
  return new Promise((resolve, reject) => {
133
133
  if(this.info.isJingGouMiniViewState){
134
134
  const getWqAuthToken = cookie.get("wq_auth_token")
135
135
  if(getWqAuthToken){
136
136
  this.info.loginState = true
137
137
  resolve(true)
138
138
  }else {
139
139
  reject(false)
140
140
  }
141
141
  }else{
142
142
  Taro.request({
143
143
  url: api.isLogin,
144
144
  jsonp:true,
145
145
  timeout: 3000,
146
146
  success: (res) => {
147
147
  const {statusCode,data} = res
148
148
  if (statusCode === 200 && data?.islogin && Number(data.islogin) === 1) {
149
149
  this.info.loginState = true
150
150
  resolve(true);
151
151
  } else {
152
152
  reject(false)
153
153
  }
154
154
  },
155
155
  fail:(err) => {
156
156
  console.log("登录检查异常", err)
157
157
  reject(false)
158
158
  }
159
159
  })
160
160
  }
161
161
  })
162
162
  }
163
163
  }
164
164
 
165
165
  try {
166
166
  const getLoginState = await this.doCheckLoginStateAndForApiCheck()
167
167
  if(getLoginState){
168
168
  const { pin } = await this.getLoginCookie();
169
169
  this.info.userInfo = {
170
170
  pin,
171
171
  encodePin: encodeURIComponent(pin),
172
172
  ptkey: '',
173
173
  }
174
174
  resolve(true)
175
175
  }else {
176
176
  reject(false)
177
177
  }
178
178
  }catch (e) {
179
179
  reject(false)
180
180
  }
181
181
  })
182
182
  if(un_area && un_area.length > 0){
183
183
  this.info.pageInfo.address = un_area
184
184
  this.info.pageInfo.un_area = un_area
185
185
  this.info.pageInfo.addressCommaStr = un_area.replace(/_/g, ',')
186
186
  }
@@ -1 +1 @@
1
- import Taro from '@tarojs/taro'
2
1
  public config: object
3
2
  this.config = {}
4
3
  return new Promise((resolve, reject) => {
5
4
  if (typeof jd !== 'undefined' && jd.requestWebCookie) {
6
5
  jd.requestWebCookie({
7
6
  needpin: 1,
8
7
  success: (res) => {
9
8
  console.log(res)
10
9
  const { ticket, pt_pin } = res
11
10
  console.log('requestWebCookie.success', res)
12
11
  this.info.userInfo = {
13
12
  pin: pt_pin,
14
13
  encodePin: encodeURIComponent(pt_pin),
15
14
  ptkey: ticket,
16
15
  }
17
16
  this.miniAppLogInstance &&
18
17
  this.miniAppLogInstance.set({
19
18
  account: pt_pin,
20
19
  })
21
20
  this.info.loginState = true
22
21
  resolve(res)
23
22
  },
24
23
  fail(res) {
25
24
  console.log('requestWebCookie.fail', res)
26
25
  reject(res)
27
26
  },
28
27
  })
29
28
  } else {
30
29
  resolve({
31
30
  pin: '',
32
31
  ptkey: '',
33
32
  mock: true
34
33
  })
35
34
  }
36
35
  })
37
36
  this.checkLoginStatus().then(res => {
38
37
  console.log(
39
38
  'jdLoadCheckStatusAndLogin hasUserLogined.success: ',
40
39
  res,
41
40
  )
42
41
  resolve(res)
43
42
  }).catch(err => {
44
43
  console.warn(
45
44
  'jdLoadCheckStatusAndLogin hasUserLogined.fail: ',
46
45
  err,
47
46
  )
48
47
  this.toLogin().then(res => {
49
48
  resolve(res)
50
49
  }).catch(err => {
51
50
  reject(err)
52
51
  })
53
52
  })
54
53
  return this.checkStatusAndLoginPromise
55
54
  return new Promise((resolve,reject) => {
56
55
  if (typeof jd !== 'undefined' && jd.hasUserLogined) {
57
56
  jd.hasUserLogined({
58
57
  success: (res) => {
59
58
  console.log('hasUserLogined.success: ', res)
60
59
  if (res.status === 1) {
61
60
  this.getLoginCookie()
62
61
  resolve(res)
63
62
  }else {
64
63
  reject(res)
65
64
  }
66
65
  },
67
66
  fail: (res) => {
68
67
  console.warn('hasUserLogined.fail: ', res)
69
68
  reject(res)
70
69
  },
71
70
  })
72
71
  } else {
73
72
  reject(false)
74
73
  }
75
74
  })
75
+ import Taro from '@tarojs/taro'
76
76
  public config: object
77
77
  this.config = {}
78
78
  console.log('测试 containerWidth ====== getSystemInfo 333333 == index.jd.ts')
79
79
  return new Promise((resolve, reject) => {
80
80
  if (typeof jd !== 'undefined' && jd.requestWebCookie) {
81
81
  jd.requestWebCookie({
82
82
  needpin: 1,
83
83
  success: (res) => {
84
84
  console.log(res)
85
85
  const { ticket, pt_pin } = res
86
86
  console.log('requestWebCookie.success', res)
87
87
  this.info.userInfo = {
88
88
  pin: pt_pin,
89
89
  encodePin: encodeURIComponent(pt_pin),
90
90
  ptkey: ticket,
91
91
  }
92
92
  this.miniAppLogInstance &&
93
93
  this.miniAppLogInstance.set({
94
94
  account: pt_pin,
95
95
  })
96
96
  this.info.loginState = true
97
97
  resolve(res)
98
98
  },
99
99
  fail(res) {
100
100
  console.log('requestWebCookie.fail', res)
101
101
  reject(res)
102
102
  },
103
103
  })
104
104
  } else {
105
105
  resolve({
106
106
  pin: '',
107
107
  ptkey: '',
108
108
  mock: true
109
109
  })
110
110
  }
111
111
  })
112
112
  this.checkLoginStatus().then(res => {
113
113
  console.log(
114
114
  'jdLoadCheckStatusAndLogin hasUserLogined.success: ',
115
115
  res,
116
116
  )
117
117
  resolve(res)
118
118
  }).catch(err => {
119
119
  console.warn(
120
120
  'jdLoadCheckStatusAndLogin hasUserLogined.fail: ',
121
121
  err,
122
122
  )
123
123
  this.toLogin().then(res => {
124
124
  resolve(res)
125
125
  }).catch(err => {
126
126
  reject(err)
127
127
  })
128
128
  })
129
129
  return this.checkStatusAndLoginPromise
130
130
  return new Promise((resolve,reject) => {
131
131
  if (typeof jd !== 'undefined' && jd.hasUserLogined) {
132
132
  jd.hasUserLogined({
133
133
  success: (res) => {
134
134
  console.log('hasUserLogined.success: ', res)
135
135
  if (res.status === 1) {
136
136
  this.getLoginCookie()
137
137
  resolve(res)
138
138
  }else {
139
139
  reject(res)
140
140
  }
141
141
  },
142
142
  fail: (res) => {
143
143
  console.warn('hasUserLogined.fail: ', res)
144
144
  reject(res)
145
145
  },
146
146
  })
147
147
  } else {
148
148
  reject(false)
149
149
  }
150
150
  })
@@ -1 +1 @@
1
- import Taro from '@tarojs/taro'
2
1
  public config: {
3
2
  [key: string]: any
4
3
  }
5
4
  public lazyContainer: CommonInterFace.lazyContainer
6
5
  this.config = {}
7
6
 
8
7
  getLoginCookie(updateKey = 'wxapp') {
9
8
  return new Promise((resolve) => {
10
9
  console.log("开始获取更新wxapp中的cookie信息", updateKey)
11
10
  if(this.config.wqCookie && this.config.wqCookieStr && this.config.getWqCookieKey === updateKey){
12
11
  console.log("已有存储wxapp中的cookie信息,直接返回",this.config)
13
12
  resolve({
14
13
  wqCookie: this.config.wqCookie,
15
14
  wqCookieStr: this.config.wqCookieStr,
16
15
  })
17
16
  }else {
18
17
  if (isPublishToWxapp) {
19
18
  const getWxappCookieObj = getTaroStorageKeyValue('cookies') || null
20
19
  if (getWxappCookieObj) {
21
20
  const getCookieObj = getWxappCookieObj['_data']
22
21
  const { wqCookie, wqCookieStr } = getWxAppCookieStr(getCookieObj)
23
22
  const { pin = '', visitkey = '-1', wq_unionid = '', wxapp_openid = '' } = wqCookie
24
23
  this.info.loginState = true
25
24
  this.info.userInfo.wqCookie = wqCookieStr
26
25
  this.info.userInfo.wqVisitkey = visitkey
27
26
  console.log('获取用户完整cookie信息', getCookieObj)
28
27
  const getUserAddress = this.wxAppUserInfoInstance.getAddress()
29
28
  console.log('获取微信用户地址信息', getUserAddress)
30
29
  if (getUserAddress) {
31
30
  this.info.pageInfo.address = getUserAddress?.areaId
32
31
  this.info.pageInfo.addressCommaStr = this.info.pageInfo
33
32
  .address
34
33
  ? this.info.pageInfo.address.replace(/_/g, ',')
35
34
  : ''
36
35
  this.info.pageInfo.un_area = this.info.pageInfo.address
37
36
  Taro.eventCenter.trigger(
38
37
  TaroEventType.USER_AREA_UPDATE,
39
38
  this.info.pageInfo.address,
40
39
  )
41
40
  }
42
41
  if(this.miniAppLogInstance){
43
42
  this.miniAppLogInstance.set({
44
43
  account: pin,
45
44
  unionid: wq_unionid,
46
45
  openid: wxapp_openid,
47
46
  })
48
47
  }
49
48
  this.config.wqCookie = wqCookie
50
49
  this.config.wqCookieStr = wqCookieStr
51
50
  this.config.getWqCookieKey = updateKey
52
51
  console.log("解析wxapp中的cookie信息成功,返回后存储",this.config)
53
52
  resolve({
54
53
  wqCookie,
55
54
  wqCookieStr,
56
55
  })
57
56
  }else {
58
57
  console.log("解析wxapp中的cookie信息异常,返回异常结果",this.config)
59
58
  resolve({
60
59
  wqCookie: false,
61
60
  wqCookieStr: false,
62
61
  })
63
62
  }
64
63
  }else {
65
64
  resolve({
66
65
  wqCookie: false,
67
66
  wqCookieStr: false,
68
67
  })
69
68
  }
70
69
  }
71
70
  })
72
71
  }
73
72
  return this.getLoginCookie()
73
+ import Taro from '@tarojs/taro'
74
74
  public config: {
75
75
  [key: string]: any
76
76
  }
77
77
  public lazyContainer: CommonInterFace.lazyContainer
78
78
  this.config = {}
79
79
  console.log('测试 containerWidth ====== getSystemInfo 444444 == index.ts')
80
80
 
81
81
  getLoginCookie(updateKey = 'wxapp') {
82
82
  return new Promise((resolve) => {
83
83
  console.log("开始获取更新wxapp中的cookie信息", updateKey)
84
84
  if(this.config.wqCookie && this.config.wqCookieStr && this.config.getWqCookieKey === updateKey){
85
85
  console.log("已有存储wxapp中的cookie信息,直接返回",this.config)
86
86
  resolve({
87
87
  wqCookie: this.config.wqCookie,
88
88
  wqCookieStr: this.config.wqCookieStr,
89
89
  })
90
90
  }else {
91
91
  if (isPublishToWxapp) {
92
92
  const getWxappCookieObj = getTaroStorageKeyValue('cookies') || null
93
93
  if (getWxappCookieObj) {
94
94
  const getCookieObj = getWxappCookieObj['_data']
95
95
  const { wqCookie, wqCookieStr } = getWxAppCookieStr(getCookieObj)
96
96
  const { pin = '', visitkey = '-1', wq_unionid = '', wxapp_openid = '' } = wqCookie
97
97
  this.info.loginState = true
98
98
  this.info.userInfo.wqCookie = wqCookieStr
99
99
  this.info.userInfo.wqVisitkey = visitkey
100
100
  console.log('获取用户完整cookie信息', getCookieObj)
101
101
  const getUserAddress = this.wxAppUserInfoInstance.getAddress()
102
102
  console.log('获取微信用户地址信息', getUserAddress)
103
103
  if (getUserAddress) {
104
104
  this.info.pageInfo.address = getUserAddress?.areaId
105
105
  this.info.pageInfo.addressCommaStr = this.info.pageInfo
106
106
  .address
107
107
  ? this.info.pageInfo.address.replace(/_/g, ',')
108
108
  : ''
109
109
  this.info.pageInfo.un_area = this.info.pageInfo.address
110
110
  Taro.eventCenter.trigger(
111
111
  TaroEventType.USER_AREA_UPDATE,
112
112
  this.info.pageInfo.address,
113
113
  )
114
114
  }
115
115
  if(this.miniAppLogInstance){
116
116
  this.miniAppLogInstance.set({
117
117
  account: pin,
118
118
  unionid: wq_unionid,
119
119
  openid: wxapp_openid,
120
120
  })
121
121
  }
122
122
  this.config.wqCookie = wqCookie
123
123
  this.config.wqCookieStr = wqCookieStr
124
124
  this.config.getWqCookieKey = updateKey
125
125
  console.log("解析wxapp中的cookie信息成功,返回后存储",this.config)
126
126
  resolve({
127
127
  wqCookie,
128
128
  wqCookieStr,
129
129
  })
130
130
  }else {
131
131
  console.log("解析wxapp中的cookie信息异常,返回异常结果",this.config)
132
132
  resolve({
133
133
  wqCookie: false,
134
134
  wqCookieStr: false,
135
135
  })
136
136
  }
137
137
  }else {
138
138
  resolve({
139
139
  wqCookie: false,
140
140
  wqCookieStr: false,
141
141
  })
142
142
  }
143
143
  }
144
144
  })
145
145
  }
146
146
  return this.getLoginCookie()
@@ -1 +1 @@
1
- import Taro from '@tarojs/taro'
2
1
  public config: {
3
2
  [key: string]: any
4
3
  }
5
4
  this.config = {}
6
5
  console.log('=================>', 'updateBusinessDomainAndApi')
7
6
 
8
7
  setTimeout(() => {
9
8
  console.log("微信app登录返回成功后,后台会写入cookie,有延迟,这里延迟500ms去获取最新cookie")
10
9
  this.getLoginCookie(`${Date.now()}`)
11
10
  },500)
12
11
  this.getLoginCookie(`${Date.now()}`)
13
12
  setTimeout(() => {
14
13
  console.log("微信强制登录后,后台会写入cookie,有延迟,这里延迟500ms去获取最新cookie")
15
14
  this.getLoginCookie(`${Date.now()}`)
16
15
  },500)
17
16
  return new Promise((resolve) => {
18
17
  console.log("开始获取更新wxapp中的cookie信息", updateKey)
19
18
  if(this.config.wqCookie && this.config.wqCookieStr && this.config.getWqCookieKey === updateKey){
20
19
  console.log("已有存储wxapp中的cookie信息,直接返回",this.config)
21
20
  resolve({
22
21
  wqCookie: this.config.wqCookie,
23
22
  wqCookieStr: this.config.wqCookieStr,
24
23
  })
25
24
  }else {
26
25
  if (isPublishToWxapp) {
27
26
  const getWxappCookieObj = getTaroStorageKeyValue('cookies') || null
28
27
  if (getWxappCookieObj) {
29
28
  const getCookieObj = getWxappCookieObj['_data']
30
29
  const { wqCookie, wqCookieStr } = getWxAppCookieStr(getCookieObj)
31
30
  const { pin = '', visitkey = '-1', wq_unionid = '', wxapp_openid = '' } = wqCookie
32
31
  this.info.loginState = true
33
32
  this.info.userInfo.wqCookie = wqCookieStr
34
33
  this.info.userInfo.wqVisitkey = visitkey
35
34
  console.log('获取用户完整cookie信息', getCookieObj)
36
35
  const getUserAddress = this.wxAppUserInfoInstance.getAddress()
37
36
  console.log('获取微信用户地址信息', getUserAddress)
38
37
  if (getUserAddress) {
39
38
  this.info.pageInfo.address = getUserAddress?.areaId
40
39
  this.info.pageInfo.addressCommaStr = this.info.pageInfo
41
40
  .address
42
41
  ? this.info.pageInfo.address.replace(/_/g, ',')
43
42
  : ''
44
43
  this.info.pageInfo.un_area = this.info.pageInfo.address
45
44
  Taro.eventCenter.trigger(
46
45
  TaroEventType.USER_AREA_UPDATE,
47
46
  this.info.pageInfo.address,
48
47
  )
49
48
  }
50
49
  if(this.miniAppLogInstance){
51
50
  this.miniAppLogInstance.set({
52
51
  account: pin,
53
52
  unionid: wq_unionid,
54
53
  openid: wxapp_openid,
55
54
  })
56
55
  }
57
56
  this.config.wqCookie = wqCookie
58
57
  this.config.wqCookieStr = wqCookieStr
59
58
  this.config.getWqCookieKey = updateKey
60
59
  console.log("解析wxapp中的cookie信息成功,返回后存储",this.config)
61
60
  resolve({
62
61
  wqCookie,
63
62
  wqCookieStr,
64
63
  })
65
64
  }else {
66
65
  console.log("解析wxapp中的cookie信息异常,返回异常结果",this.config)
67
66
  resolve({
68
67
  wqCookie: false,
69
68
  wqCookieStr: false,
70
69
  })
71
70
  }
72
71
  }else {
73
72
  resolve({
74
73
  wqCookie: false,
75
74
  wqCookieStr: false,
76
75
  })
77
76
  }
78
77
  }
79
78
  })
79
+ import Taro from '@tarojs/taro'
80
80
  public config: {
81
81
  [key: string]: any
82
82
  }
83
83
  this.config = {}
84
84
  console.log('=================>', 'updateBusinessDomainAndApi')
85
85
  console.log('测试 containerWidth ====== getSystemInfo 555555 == index.weapp.ts')
86
86
 
87
87
  setTimeout(() => {
88
88
  console.log("微信app登录返回成功后,后台会写入cookie,有延迟,这里延迟500ms去获取最新cookie")
89
89
  this.getLoginCookie(`${Date.now()}`)
90
90
  },500)
91
91
  this.getLoginCookie(`${Date.now()}`)
92
92
  setTimeout(() => {
93
93
  console.log("微信强制登录后,后台会写入cookie,有延迟,这里延迟500ms去获取最新cookie")
94
94
  this.getLoginCookie(`${Date.now()}`)
95
95
  },500)
96
96
  return new Promise((resolve) => {
97
97
  console.log("开始获取更新wxapp中的cookie信息", updateKey)
98
98
  if(this.config.wqCookie && this.config.wqCookieStr && this.config.getWqCookieKey === updateKey){
99
99
  console.log("已有存储wxapp中的cookie信息,直接返回",this.config)
100
100
  resolve({
101
101
  wqCookie: this.config.wqCookie,
102
102
  wqCookieStr: this.config.wqCookieStr,
103
103
  })
104
104
  }else {
105
105
  if (isPublishToWxapp) {
106
106
  const getWxappCookieObj = getTaroStorageKeyValue('cookies') || null
107
107
  if (getWxappCookieObj) {
108
108
  const getCookieObj = getWxappCookieObj['_data']
109
109
  const { wqCookie, wqCookieStr } = getWxAppCookieStr(getCookieObj)
110
110
  const { pin = '', visitkey = '-1', wq_unionid = '', wxapp_openid = '' } = wqCookie
111
111
  this.info.loginState = true
112
112
  this.info.userInfo.wqCookie = wqCookieStr
113
113
  this.info.userInfo.wqVisitkey = visitkey
114
114
  console.log('获取用户完整cookie信息', getCookieObj)
115
115
  const getUserAddress = this.wxAppUserInfoInstance.getAddress()
116
116
  console.log('获取微信用户地址信息', getUserAddress)
117
117
  if (getUserAddress) {
118
118
  this.info.pageInfo.address = getUserAddress?.areaId
119
119
  this.info.pageInfo.addressCommaStr = this.info.pageInfo
120
120
  .address
121
121
  ? this.info.pageInfo.address.replace(/_/g, ',')
122
122
  : ''
123
123
  this.info.pageInfo.un_area = this.info.pageInfo.address
124
124
  Taro.eventCenter.trigger(
125
125
  TaroEventType.USER_AREA_UPDATE,
126
126
  this.info.pageInfo.address,
127
127
  )
128
128
  }
129
129
  if(this.miniAppLogInstance){
130
130
  this.miniAppLogInstance.set({
131
131
  account: pin,
132
132
  unionid: wq_unionid,
133
133
  openid: wxapp_openid,
134
134
  })
135
135
  }
136
136
  this.config.wqCookie = wqCookie
137
137
  this.config.wqCookieStr = wqCookieStr
138
138
  this.config.getWqCookieKey = updateKey
139
139
  console.log("解析wxapp中的cookie信息成功,返回后存储",this.config)
140
140
  resolve({
141
141
  wqCookie,
142
142
  wqCookieStr,
143
143
  })
144
144
  }else {
145
145
  console.log("解析wxapp中的cookie信息异常,返回异常结果",this.config)
146
146
  resolve({
147
147
  wqCookie: false,
148
148
  wqCookieStr: false,
149
149
  })
150
150
  }
151
151
  }else {
152
152
  resolve({
153
153
  wqCookie: false,
154
154
  wqCookieStr: false,
155
155
  })
156
156
  }
157
157
  }
158
158
  })