Skip to content
Toggle navigation
P
Projects
G
Groups
S
Snippets
Help
yotta
/
pictogram
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
60
Merge Requests
0
Pipelines
Wiki
Settings
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit
a87e4ab1
authored
Sep 19, 2017
by
Fernando Martínez Santiago
Browse files
Options
_('Browse Files')
Download
Email Patches
Plain Diff
working on
#328
(sigue sin ir via websockets)
parent
87d59c1e
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
4 additions
and
3 deletions
android/Pictogram/commonlibrary/src/main/java/com/yottacode/pictogram/net/NetService.java
android/Pictogram/commonlibrary/src/main/java/com/yottacode/pictogram/net/websockets/StudentTalk.java
android/Pictogram/commonlibrary/src/main/java/com/yottacode/pictogram/net/NetService.java
View file @
a87e4ab1
...
...
@@ -218,7 +218,8 @@ public class NetService implements Runnable, RestapiWrapper.iSilentLogin {
public
void
synchronizeStudentAttributes
()
{
int
id
=
PCBcontext
.
getPcbdb
().
getCurrentUser
().
get_id_stu
();
PCBcontext
.
getRestapiWrapper
().
ask
(
"stu/"
+
id
,
new
RestapiWrapper
.
iRestapiListener
()
{
final
String
request
=
"stu/"
+
id
;
PCBcontext
.
getRestapiWrapper
().
ask
(
request
,
new
RestapiWrapper
.
iRestapiListener
()
{
@Override
public
void
preExecute
()
{
...
...
android/Pictogram/commonlibrary/src/main/java/com/yottacode/pictogram/net/websockets/StudentTalk.java
View file @
a87e4ab1
...
...
@@ -30,7 +30,7 @@ public class StudentTalk implements Emitter.Listener {
public
void
call
(
Object
...
args
)
{
if
(
PCBcontext
.
getPcbdb
()!=
null
)
try
{
JSONObject
msg
=
((
JSONObject
)
args
[
0
]).
getJSONObject
(
"student"
);
JSONObject
msg
=
((
JSONObject
)
args
[
0
]).
getJSONObject
(
"student"
);
Log
.
d
(
this
.
getClass
().
getName
(),
"raw Received message "
+
msg
.
toString
());
int
id
=
msg
.
getInt
(
"id"
);
String
username
=
msg
.
getString
(
"username"
);
...
...
@@ -52,7 +52,7 @@ public class StudentTalk implements Emitter.Listener {
listener
.
change
(
updatedUser
,
license
);
}
catch
(
JSONException
e
)
{
Log
.
e
(
this
.
getClass
().
getCanonicalName
(),
e
.
getClass
().
getCanonicalName
()
+
"--"
+
e
);
Log
.
e
(
this
.
getClass
().
getCanonicalName
(),
e
.
getClass
().
getCanonicalName
()
+
"--"
+
e
+
" at "
+
args
[
0
].
toString
()
);
}
}
...
...
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