Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Contribute to GitLab
Sign in / Register
Toggle navigation
G
g4proxy
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
Administrator
g4proxy
Commits
5b7c8235
Commit
5b7c8235
authored
Apr 30, 2019
by
Administrator
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
udapte
parent
5a8b3ca0
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
1 addition
and
33 deletions
+1
-33
MainActivity.java
app/src/main/java/com/virjar/g4proxy/MainActivity.java
+1
-33
No files found.
app/src/main/java/com/virjar/g4proxy/MainActivity.java
View file @
5b7c8235
...
...
@@ -81,39 +81,7 @@ public class MainActivity extends AppCompatActivity implements View.OnClickListe
textView
.
setText
(
SchedulerTaskService
.
msgReportlUrl
);
textView
.
append
(
"\r\n"
+
deviceMsg
);
// Request request = HttpClientUtils.postRequest("http://taskcenter.beta.qunar.com/api/phone/report", deviceMsg);
//https://hotelcrawl.qunar.com/api/phone/report
Request
request
=
HttpClientUtils
.
postRequest
(
SchedulerTaskService
.
msgReportlUrl
,
deviceMsg
);
HttpClientUtils
.
getClient
().
newCall
(
request
).
enqueue
(
new
Callback
()
{
@Override
public
void
onFailure
(
@javax
.
annotation
.
Nullable
Call
call
,
@javax
.
annotation
.
Nullable
IOException
e
)
{
Log
.
e
(
Constant
.
TAG
,
"report device msg failed"
,
e
);
}
@Override
public
void
onResponse
(
@javax
.
annotation
.
Nullable
Call
call
,
@javax
.
annotation
.
Nullable
Response
response
)
{
try
{
if
(
response
!=
null
)
{
ResponseBody
body
=
response
.
body
();
if
(
body
!=
null
)
{
final
String
responseStr
=
body
.
string
();
MainActivity
.
this
.
runOnUiThread
(
new
Runnable
()
{
@Override
public
void
run
()
{
textView
.
append
(
"\r\n"
+
responseStr
);
}
});
Log
.
e
(
"report response"
,
responseStr
);
}
}
}
catch
(
IOException
e
)
{
e
.
printStackTrace
();
}
}
});
SchedulerTaskService
.
runReportMessageTask
(
this
);
}
}
}
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