Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in
Toggle navigation
X
XiTianSenMall
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
leiqingsong
XiTianSenMall
Commits
1ade4d25
Commit
1ade4d25
authored
4 years ago
by
leiqingsong
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
测试
parent
c30b7411
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
14 additions
and
5 deletions
+14
-5
App.vue
H5/src/App.vue
+11
-1
bridgeToAppFun.js
H5/src/utils/bridgeToAppFun.js
+1
-2
wallet.vue
H5/src/views/income/wallet.vue
+2
-2
No files found.
H5/src/App.vue
View file @
1ade4d25
...
...
@@ -6,6 +6,7 @@
</
template
>
<
script
>
import
{
getAuthToken
}
from
"@/utils/bridgeToAppFun"
;
import
BaseNavBar
from
"./components/BaseNavBar.vue"
;
export
default
{
components
:
{
...
...
@@ -20,7 +21,16 @@ export default {
$route
(
val
)
{
this
.
currentTitle
=
val
.
meta
.
title
;
}
}
},
mounted
()
{
getAuthToken
()
.
then
(
res
=>
{
console
.
log
(
'success'
,
res
);
})
.
catch
(
err
=>
{
console
.
log
(
'error'
,
err
);
});
},
};
</
script
>
...
...
This diff is collapsed.
Click to expand it.
H5/src/utils/bridgeToAppFun.js
View file @
1ade4d25
...
...
@@ -7,12 +7,11 @@ export function getAuthToken() {
console
.
log
(
"调用1"
);
jsBridge
.
callhandler
(
"getAuthToken"
,
null
,
data
=>
{
console
.
log
(
"调用2"
);
console
.
log
(
data
);
localStorage
.
setItem
(
'token'
,
data
);
console
.
log
(
"--------------"
);
if
(
data
)
{
alert
(
"获取到的token"
+
data
);
resolve
();
resolve
(
data
);
}
else
{
reject
(
"调用失败,未返回data"
);
}
...
...
This diff is collapsed.
Click to expand it.
H5/src/views/income/wallet.vue
View file @
1ade4d25
...
...
@@ -73,10 +73,10 @@ export default {
this
.
getWalletInfo
();
getAuthToken
()
.
then
(
res
=>
{
console
.
log
(
res
);
console
.
log
(
'success'
,
res
);
})
.
catch
(
err
=>
{
console
.
log
(
err
);
console
.
log
(
'error'
,
err
);
});
},
methods
:
{
...
...
This diff is collapsed.
Click to expand it.
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment