Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
B
banma_credit
Overview
Overview
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
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
hik_rn
project
banma_credit
Commits
464ba6cd
Commit
464ba6cd
authored
Sep 29, 2020
by
肖亮
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
feat:更新修改昵称
parent
d1e314af
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
0 additions
and
7 deletions
+0
-7
src/utils/request.js
+0
-7
No files found.
src/utils/request.js
View file @
464ba6cd
...
@@ -24,7 +24,6 @@ const errorProcess = (resp, reject, errorToast) => {
...
@@ -24,7 +24,6 @@ const errorProcess = (resp, reject, errorToast) => {
const
resData
=
resp
.
data
||
{}
const
resData
=
resp
.
data
||
{}
let
message
=
resData
.
message
||
resData
.
msg
||
resp
.
statusText
let
message
=
resData
.
message
||
resData
.
msg
||
resp
.
statusText
const
status
=
resData
.
stats
||
resp
.
status
const
status
=
resData
.
stats
||
resp
.
status
console
.
log
(
'resData'
,
resData
);
if
(
ERROR_CODE_MAP
[
status
]
&&
ERROR_CODE_MAP
[
status
].
message
)
{
if
(
ERROR_CODE_MAP
[
status
]
&&
ERROR_CODE_MAP
[
status
].
message
)
{
message
=
ERROR_CODE_MAP
[
status
].
message
message
=
ERROR_CODE_MAP
[
status
].
message
}
}
...
@@ -94,10 +93,6 @@ export const $request = {
...
@@ -94,10 +93,6 @@ export const $request = {
method
,
method
,
headers
,
headers
,
}
}
console
.
log
(
'method'
,
method
);
console
.
log
(
'headers'
,
headers
);
console
.
log
(
'body'
,
body
);
console
.
log
(
'url'
,
url
);
if
(
method
===
'POST'
)
{
if
(
method
===
'POST'
)
{
fetchConfig
.
body
=
body
fetchConfig
.
body
=
body
}
}
...
@@ -107,11 +102,9 @@ export const $request = {
...
@@ -107,11 +102,9 @@ export const $request = {
if
(
res
.
ok
)
{
if
(
res
.
ok
)
{
return
res
.
json
()
return
res
.
json
()
}
}
console
.
log
(
'res1'
,
res
);
errorProcess
(
res
,
reject
,
errorToast
)
errorProcess
(
res
,
reject
,
errorToast
)
})
})
.
then
(
json
=>
{
.
then
(
json
=>
{
console
.
log
(
'json'
,
json
);
responseProcess
(
json
,
resolve
,
reject
,
isOutRequest
,
errorToast
)
responseProcess
(
json
,
resolve
,
reject
,
isOutRequest
,
errorToast
)
})
})
.
catch
(
e
=>
{
.
catch
(
e
=>
{
...
...
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