Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
C
chat_webview
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
abookCommunication
chat_webview
Commits
139a0c52
Commit
139a0c52
authored
Apr 15, 2021
by
Takatoshi Miura
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
js連動
parent
bf3ec123
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
27 additions
and
3 deletions
+27
-3
public_new/js/chat-db.js
+3
-3
public_new/js/chat-ui.js
+24
-0
No files found.
public_new/js/chat-db.js
View file @
139a0c52
...
@@ -58,7 +58,7 @@ CHAT_DB.getMessages = function(roomId) {
...
@@ -58,7 +58,7 @@ CHAT_DB.getMessages = function(roomId) {
CHAT_DB
.
getFavoriteUsersNotInRoom
=
function
()
{
CHAT_DB
.
getFavoriteUsersNotInRoom
=
function
()
{
if
(
CHAT_UTIL
.
isIOS
())
{
if
(
CHAT_UTIL
.
isIOS
())
{
//TODO IOS処理追加必要
return
JSON
.
parse
(
callNativeApp
(
"getFavoriteUsersNotInRoom"
,
{}));
}
else
if
(
CHAT_UTIL
.
isAndroid
())
{
}
else
if
(
CHAT_UTIL
.
isAndroid
())
{
//String形式をJsonに変更してReturn
//String形式をJsonに変更してReturn
return
JSON
.
parse
(
android
.
getFavoriteUsersNotInRoom
());
return
JSON
.
parse
(
android
.
getFavoriteUsersNotInRoom
());
...
@@ -103,7 +103,7 @@ CHAT_DB.getGroupInfo = function(groupId) {
...
@@ -103,7 +103,7 @@ CHAT_DB.getGroupInfo = function(groupId) {
CHAT_DB
.
loadSelectedUsers
=
function
()
{
CHAT_DB
.
loadSelectedUsers
=
function
()
{
if
(
CHAT_UTIL
.
isIOS
())
{
if
(
CHAT_UTIL
.
isIOS
())
{
//TODO IOS処理追加必要
return
JSON
.
parse
(
callNativeApp
(
"getSelectedUserList"
,
{}));
}
else
if
(
CHAT_UTIL
.
isAndroid
())
{
}
else
if
(
CHAT_UTIL
.
isAndroid
())
{
//String形式をJsonに変更してReturn
//String形式をJsonに変更してReturn
console
.
log
(
JSON
.
parse
(
android
.
getSelectedUserList
()));
console
.
log
(
JSON
.
parse
(
android
.
getSelectedUserList
()));
...
@@ -218,7 +218,7 @@ CHAT_DB.updateArchiveDetail = function(archiveId) {
...
@@ -218,7 +218,7 @@ CHAT_DB.updateArchiveDetail = function(archiveId) {
CHAT_DB
.
searchMessages
=
function
(
keyword
,
userList
)
{
CHAT_DB
.
searchMessages
=
function
(
keyword
,
userList
)
{
if
(
CHAT_UTIL
.
isIOS
())
{
if
(
CHAT_UTIL
.
isIOS
())
{
// TODO
return
JSON
.
parse
(
callNativeApp
(
"searchMessages"
,
{
"keyWord"
:
keyword
,
"userList"
:
userList
}));
}
else
if
(
CHAT_UTIL
.
isAndroid
())
{
}
else
if
(
CHAT_UTIL
.
isAndroid
())
{
return
JSON
.
parse
(
android
.
searchMessages
(
keyword
,
userList
));
return
JSON
.
parse
(
android
.
searchMessages
(
keyword
,
userList
));
}
}
...
...
public_new/js/chat-ui.js
View file @
139a0c52
...
@@ -1316,12 +1316,22 @@ $('#tabAllGroupOnMakeRoom').on('click', function(e) {
...
@@ -1316,12 +1316,22 @@ $('#tabAllGroupOnMakeRoom').on('click', function(e) {
});
});
$
(
'#makeRoomConfirmBtn'
).
on
(
'click'
,
function
(
e
)
{
$
(
'#makeRoomConfirmBtn'
).
on
(
'click'
,
function
(
e
)
{
if
(
typeof
(
android
)
!=
"undefined"
)
{
android
.
saveSelectedUserList
(
CHAT
.
globalSelectedUserList
.
join
(
","
));
android
.
saveSelectedUserList
(
CHAT
.
globalSelectedUserList
.
join
(
","
));
}
else
{
var
userList
=
CHAT
.
globalSelectedUserList
.
join
(
","
);
webkit
.
messageHandlers
.
saveSelectedUserList
.
postMessage
({
userList
});
}
$
(
'#makeRoomForm'
).
submit
();
$
(
'#makeRoomForm'
).
submit
();
});
});
$
(
'#addUserConfirmBtn'
).
on
(
'click'
,
function
(
e
)
{
$
(
'#addUserConfirmBtn'
).
on
(
'click'
,
function
(
e
)
{
if
(
typeof
(
android
)
!=
"undefined"
)
{
android
.
saveSelectedUserList
(
CHAT
.
globalSelectedUserList
.
join
(
","
));
android
.
saveSelectedUserList
(
CHAT
.
globalSelectedUserList
.
join
(
","
));
}
else
{
var
userList
=
CHAT
.
globalSelectedUserList
.
join
(
","
);
webkit
.
messageHandlers
.
saveSelectedUserList
.
postMessage
({
userList
});
}
$
(
'#addUserForm'
).
submit
();
$
(
'#addUserForm'
).
submit
();
});
});
...
@@ -1751,10 +1761,17 @@ CHAT_UI.refreshMyGroupForMakeRoom = function() {
...
@@ -1751,10 +1761,17 @@ CHAT_UI.refreshMyGroupForMakeRoom = function() {
});
});
if
(
IS_ONLINE
==
'true'
)
{
if
(
IS_ONLINE
==
'true'
)
{
if
(
typeof
(
android
)
!=
"undefined"
)
{
android
.
updateGroupInfo
(
'0'
);
android
.
updateGroupInfo
(
'0'
);
android
.
updateMyInfo
();
android
.
updateMyInfo
();
android
.
updateGroupUser
();
android
.
updateGroupUser
();
android
.
updateFavorite
();
android
.
updateFavorite
();
}
else
{
webkit
.
messageHandlers
.
updateGroupInfo
.
postMessage
(
"0"
);
webkit
.
messageHandlers
.
updateMyInfo
.
postMessage
({});
webkit
.
messageHandlers
.
updateGroupUser
.
postMessage
({});
webkit
.
messageHandlers
.
updateFavorite
.
postMessage
({});
}
}
}
//お気に入りグループ取得。
//お気に入りグループ取得。
...
@@ -2108,10 +2125,17 @@ CHAT_UI.refreshMyGroupForAddUser = function() {
...
@@ -2108,10 +2125,17 @@ CHAT_UI.refreshMyGroupForAddUser = function() {
});
});
if
(
IS_ONLINE
==
'true'
)
{
if
(
IS_ONLINE
==
'true'
)
{
if
(
typeof
(
android
)
!=
"undefined"
)
{
android
.
updateGroupInfo
(
'0'
);
android
.
updateGroupInfo
(
'0'
);
android
.
updateMyInfo
();
android
.
updateMyInfo
();
android
.
updateGroupUser
();
android
.
updateGroupUser
();
android
.
updateFavorite
();
android
.
updateFavorite
();
}
else
{
webkit
.
messageHandlers
.
updateGroupInfo
.
postMessage
(
"0"
);
webkit
.
messageHandlers
.
updateMyInfo
.
postMessage
({});
webkit
.
messageHandlers
.
updateGroupUser
.
postMessage
({});
webkit
.
messageHandlers
.
updateFavorite
.
postMessage
({});
}
}
}
//お気に入りグループ取得。
//お気に入りグループ取得。
...
...
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