Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
M
max_android_panel
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
Zhang Xin
max_android_panel
Commits
2fbb5a9f
Commit
2fbb5a9f
authored
Nov 15, 2019
by
niuxinyu
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
关门优化9
parent
c6c2347e
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
13 additions
and
6 deletions
+13
-6
client/containers/HomePageContainer/HomePageContainer.jsx
+13
-6
No files found.
client/containers/HomePageContainer/HomePageContainer.jsx
View file @
2fbb5a9f
...
@@ -3,8 +3,7 @@ import HeaderComponent from '../../components/CommonComponent/HeaderComponent/He
...
@@ -3,8 +3,7 @@ import HeaderComponent from '../../components/CommonComponent/HeaderComponent/He
import
Button
from
'../../components/CommonComponent/ButtonComponent/ButtonComponent'
import
Button
from
'../../components/CommonComponent/ButtonComponent/ButtonComponent'
import
PopModel
from
'../../components/CommonComponent/PopupComponent/PopupChildComponent'
import
PopModel
from
'../../components/CommonComponent/PopupComponent/PopupChildComponent'
import
{
sendMsg
}
from
"../../util/socket"
;
import
{
sendMsg
}
from
"../../util/socket"
;
import
axios
from
'axios'
import
fetch
from
'isomorphic-fetch'
axios
.
defaults
.
withCredentials
=
true
require
(
'./index.css'
);
require
(
'./index.css'
);
let
domain
=
ENV
.
domain
;
let
domain
=
ENV
.
domain
;
export
default
class
HomePageContainer
extends
React
.
Component
{
export
default
class
HomePageContainer
extends
React
.
Component
{
...
@@ -66,17 +65,25 @@ export default class HomePageContainer extends React.Component{
...
@@ -66,17 +65,25 @@ export default class HomePageContainer extends React.Component{
}
else
{
}
else
{
//正常调用
//正常调用
try
{
axios
.
post
(
domain
+
'machine_pad/finish_task.action'
,{
try
{
fetch
(
domain
+
'machine_pad/finish_task.action'
,{
credentials
:
'include'
,
method
:
'POST'
,
mode
:
'cors'
,
headers
:{
'Access-Control-Allow-Origin'
:
'*'
,
'Content-Type'
:
'application/json; charset=UTF-8'
},
body
:
JSON
.
stringify
({
area
:
this
.
props
.
headerInfo
.
taskInfo
.
area
,
area
:
this
.
props
.
headerInfo
.
taskInfo
.
area
,
storeId
:
this
.
props
.
headerInfo
.
storeInfo
.
id
,
storeId
:
this
.
props
.
headerInfo
.
storeInfo
.
id
,
taskId
:
this
.
props
.
headerInfo
.
taskInfo
.
taskId
,
taskId
:
this
.
props
.
headerInfo
.
taskInfo
.
taskId
,
taskType
:
this
.
props
.
headerInfo
.
taskInfo
.
currentTaskType
,
taskType
:
this
.
props
.
headerInfo
.
taskInfo
.
currentTaskType
,
userId
:
this
.
props
.
headerInfo
.
userInfo
.
employeeId
userId
:
this
.
props
.
headerInfo
.
userInfo
.
employeeId
})}
}
).
then
((
res
)
=>
{
).
then
((
res
)
=>
{
if
(
res
.
status
!=
200
){
if
(
res
.
status
!=
200
){
var
error
=
new
Error
(
response
.
statusText
)
var
error
=
new
Error
(
response
.
statusText
)
error
.
response
=
response
error
.
response
=
response
...
...
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