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
541d030a
Commit
541d030a
authored
Apr 16, 2021
by
Takatoshi Miura
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'release_sp3' into 'features/#525'
# Conflicts: # public_new/js/chat-ui.js
parents
862e02b5
e65f703a
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
19 additions
and
10 deletions
+19
-10
public_new/css/chat.css
+1
-2
public_new/js/chat-ui.js
+13
-8
public_new/js/constant.js
+5
-0
No files found.
public_new/css/chat.css
View file @
541d030a
...
@@ -220,8 +220,7 @@ input[name="tab_item"] {
...
@@ -220,8 +220,7 @@ input[name="tab_item"] {
}
}
.category_name
{
.category_name
{
white-space
:
nowrap
;
white-space
:
nowrap
;
overflow
:
hidden
;
overflow
:
scroll
;
text-overflow
:
ellipsis
;
width
:
90%
;
width
:
90%
;
}
}
.chat_list
.category.open
::after
{
.chat_list
.category.open
::after
{
...
...
public_new/js/chat-ui.js
View file @
541d030a
...
@@ -691,7 +691,7 @@ CHAT_UI.showConfirmView = function(isInvite) {
...
@@ -691,7 +691,7 @@ CHAT_UI.showConfirmView = function(isInvite) {
//todo android create room api
//todo android create room api
if
(
typeof
(
android
)
!=
"undefined"
)
{
if
(
typeof
(
android
)
!=
"undefined"
)
{
android
.
createChatRoom
(
"1"
,
userIdList
.
join
(
','
),
newRoomName
);
android
.
createChatRoom
(
"1"
,
userIdList
.
join
(
','
),
newRoomName
,
makeRoomFlg
.
MAKE_ROOM
);
}
else
{
}
else
{
webkit
.
messageHandlers
.
createChatRoom
.
postMessage
({
"roomType"
:
"1"
,
"userIdList"
:
userIdList
.
join
(
','
),
"roomName"
:
newRoomName
});
webkit
.
messageHandlers
.
createChatRoom
.
postMessage
({
"roomType"
:
"1"
,
"userIdList"
:
userIdList
.
join
(
','
),
"roomName"
:
newRoomName
});
}
}
...
@@ -785,11 +785,11 @@ CHAT_UI.showConfirmView = function(isInvite) {
...
@@ -785,11 +785,11 @@ CHAT_UI.showConfirmView = function(isInvite) {
// ルーム名のtrimmingした後、URIencodingを行う
// ルーム名のtrimmingした後、URIencodingを行う
const
encodedRoomName
=
encodeURIComponent
(
trimmedRoomName
);
const
encodedRoomName
=
encodeURIComponent
(
trimmedRoomName
);
if
(
typeof
(
android
)
!=
"undefined"
)
{
if
(
typeof
(
android
)
!=
"undefined"
)
{
android
.
createChatRoom
(
"1"
,
userIdList
.
join
(
','
),
encodedRoomName
);
android
.
createChatRoom
(
"1"
,
userIdList
.
join
(
','
),
encodedRoomName
,
makeRoomFlg
.
MAKE_ROOM
);
}
else
{
}
else
{
//TODO
webkit
.
messageHandlers
.
createChatRoom
.
postMessage
({
"roomType"
:
"1"
,
"userIdList"
:
userIdList
.
join
(
','
),
"roomName"
:
encodedRoomName
});
webkit
.
messageHandlers
.
createChatRoom
.
postMessage
({
"roomType"
:
"1"
,
"userIdList"
:
userIdList
.
join
(
','
),
"roomName"
:
encodedRoomName
});
}
}
}
}
}
}
}
}
...
@@ -1534,7 +1534,7 @@ CHAT_UI.startChat = function(userShopMemberId,userName) {
...
@@ -1534,7 +1534,7 @@ CHAT_UI.startChat = function(userShopMemberId,userName) {
// 参加ユーザ名でルーム名を生成
// 参加ユーザ名でルーム名を生成
let
newRoomName
=
CHAT
.
globalLoginParameter
.
loginId
+
','
+
userName
;
let
newRoomName
=
CHAT
.
globalLoginParameter
.
loginId
+
','
+
userName
;
if
(
typeof
(
android
)
!=
"undefined"
)
{
if
(
typeof
(
android
)
!=
"undefined"
)
{
android
.
createChatRoom
(
chatRoomType
.
DM
,
userIdList
.
join
(
','
),
newRoomName
);
android
.
createChatRoom
(
chatRoomType
.
DM
,
userIdList
.
join
(
','
),
newRoomName
,
makeRoomFlg
.
NAME_CARD
);
}
else
{
}
else
{
webkit
.
messageHandlers
.
createChatRoom
.
postMessage
({
"roomType"
:
chatRoomType
.
DM
,
"userIdList"
:
userIdList
.
join
(
','
),
"roomName"
:
newRoomName
});
webkit
.
messageHandlers
.
createChatRoom
.
postMessage
({
"roomType"
:
chatRoomType
.
DM
,
"userIdList"
:
userIdList
.
join
(
','
),
"roomName"
:
newRoomName
});
}
}
...
@@ -1547,6 +1547,9 @@ CHAT_UI.startVoice = function() {
...
@@ -1547,6 +1547,9 @@ CHAT_UI.startVoice = function() {
CHAT_UI
.
makeNameCard
=
function
(
shopMemberId
)
{
CHAT_UI
.
makeNameCard
=
function
(
shopMemberId
)
{
if
(
CHAT
.
globalLoginParameter
.
shopMemberId
==
shopMemberId
)
{
return
;
}
var
nameCardInfo
=
CHAT_DB
.
getNameCardData
(
shopMemberId
);
var
nameCardInfo
=
CHAT_DB
.
getNameCardData
(
shopMemberId
);
var
namecardTemplate
;
var
namecardTemplate
;
$
.
get
({
url
:
"./template/template_user_name_card.html"
,
async
:
false
}
$
.
get
({
url
:
"./template/template_user_name_card.html"
,
async
:
false
}
...
@@ -2016,11 +2019,11 @@ CHAT_UI.showMakeRoomConfirmView = function() {
...
@@ -2016,11 +2019,11 @@ CHAT_UI.showMakeRoomConfirmView = function() {
// 参加ユーザ名でルーム名を生成
// 参加ユーザ名でルーム名を生成
let
newRoomName
=
CHAT
.
globalLoginParameter
.
loginId
+
','
+
userNameList
.
join
(
','
);
let
newRoomName
=
CHAT
.
globalLoginParameter
.
loginId
+
','
+
userNameList
.
join
(
','
);
if
(
typeof
(
android
)
!=
"undefined"
)
{
if
(
typeof
(
android
)
!=
"undefined"
)
{
android
.
createChatRoom
(
"1"
,
userIdList
.
join
(
','
),
newRoomName
);
android
.
createChatRoom
(
"1"
,
userIdList
.
join
(
','
),
newRoomName
,
makeRoomFlg
.
MAKE_ROOM
);
}
else
{
}
else
{
//TODO
webkit
.
messageHandlers
.
createChatRoom
.
postMessage
({
"roomType"
:
"1"
,
"userIdList"
:
userIdList
.
join
(
','
),
"roomName"
:
newRoomName
});
webkit
.
messageHandlers
.
createChatRoom
.
postMessage
({
"roomType"
:
"1"
,
"userIdList"
:
userIdList
.
join
(
','
),
"roomName"
:
newRoomName
});
}
}
}
else
if
(
trimmedRoomName
.
includes
(
';'
)
||
trimmedRoomName
.
includes
(
'/'
)
||
trimmedRoomName
.
includes
(
'?'
)
||
trimmedRoomName
.
includes
(
':'
)
||
trimmedRoomName
.
includes
(
"@"
)
}
else
if
(
trimmedRoomName
.
includes
(
';'
)
||
trimmedRoomName
.
includes
(
'/'
)
||
trimmedRoomName
.
includes
(
'?'
)
||
trimmedRoomName
.
includes
(
':'
)
||
trimmedRoomName
.
includes
(
"@"
)
||
trimmedRoomName
.
includes
(
'&'
)
||
trimmedRoomName
.
includes
(
'='
)
||
trimmedRoomName
.
includes
(
"+"
)
||
trimmedRoomName
.
includes
(
'$'
)
||
trimmedRoomName
.
includes
(
","
)
||
trimmedRoomName
.
includes
(
'-'
)
||
trimmedRoomName
.
includes
(
'&'
)
||
trimmedRoomName
.
includes
(
'='
)
||
trimmedRoomName
.
includes
(
"+"
)
||
trimmedRoomName
.
includes
(
'$'
)
||
trimmedRoomName
.
includes
(
","
)
||
trimmedRoomName
.
includes
(
'-'
)
||
trimmedRoomName
.
includes
(
'_'
)
||
trimmedRoomName
.
includes
(
'.'
)
||
trimmedRoomName
.
includes
(
'!'
)
||
trimmedRoomName
.
includes
(
'~'
)
||
trimmedRoomName
.
includes
(
'*'
)
||
trimmedRoomName
.
includes
(
"
\
'"
)
||
trimmedRoomName
.
includes
(
'_'
)
||
trimmedRoomName
.
includes
(
'.'
)
||
trimmedRoomName
.
includes
(
'!'
)
||
trimmedRoomName
.
includes
(
'~'
)
||
trimmedRoomName
.
includes
(
'*'
)
||
trimmedRoomName
.
includes
(
"
\
'"
)
...
@@ -2064,11 +2067,10 @@ CHAT_UI.showMakeRoomConfirmView = function() {
...
@@ -2064,11 +2067,10 @@ CHAT_UI.showMakeRoomConfirmView = function() {
// ルーム名のtrimmingした後、URIencodingを行う
// ルーム名のtrimmingした後、URIencodingを行う
const
encodedRoomName
=
encodeURIComponent
(
trimmedRoomName
);
const
encodedRoomName
=
encodeURIComponent
(
trimmedRoomName
);
if
(
typeof
(
android
)
!=
"undefined"
)
{
if
(
typeof
(
android
)
!=
"undefined"
)
{
android
.
createChatRoom
(
"1"
,
userIdList
.
join
(
','
),
encodedRoomName
);
android
.
createChatRoom
(
"1"
,
userIdList
.
join
(
','
),
encodedRoomName
,
makeRoomFlg
.
MAKE_ROOM
);
}
else
{
}
else
{
webkit
.
messageHandlers
.
createChatRoom
.
postMessage
({
"roomType"
:
"1"
,
"userIdList"
:
userIdList
.
join
(
','
),
"roomName"
:
encodedRoomName
});
webkit
.
messageHandlers
.
createChatRoom
.
postMessage
({
"roomType"
:
"1"
,
"userIdList"
:
userIdList
.
join
(
','
),
"roomName"
:
encodedRoomName
});
}
}
}
}
});
});
}
}
...
@@ -2209,6 +2211,7 @@ CHAT_UI.refreshForOnline = function() {
...
@@ -2209,6 +2211,7 @@ CHAT_UI.refreshForOnline = function() {
$
(
'#roomMenu'
).
show
();
$
(
'#roomMenu'
).
show
();
$
(
'.attach_file'
).
show
();
$
(
'.attach_file'
).
show
();
$
(
'.fa-download'
).
show
();
$
(
'.fa-download'
).
show
();
$
(
'.chat_room_footer'
).
show
();
if
(
typeof
$
(
'#roomTitle'
).
val
()
!=
'undefined'
)
{
if
(
typeof
$
(
'#roomTitle'
).
val
()
!=
'undefined'
)
{
CHAT_SOCKET
.
connectSocket
();
CHAT_SOCKET
.
connectSocket
();
socket
.
emit
(
'join'
,
CHAT
.
globalLoginParameter
,
function
()
{
socket
.
emit
(
'join'
,
CHAT
.
globalLoginParameter
,
function
()
{
...
@@ -2225,4 +2228,5 @@ CHAT_UI.refreshForOffline = function() {
...
@@ -2225,4 +2228,5 @@ CHAT_UI.refreshForOffline = function() {
$
(
'#roomMenu'
).
hide
();
$
(
'#roomMenu'
).
hide
();
$
(
'.attach_file'
).
hide
();
$
(
'.attach_file'
).
hide
();
$
(
'.fa-download'
).
hide
();
$
(
'.fa-download'
).
hide
();
$
(
'.chat_room_footer'
).
hide
();
}
}
\ No newline at end of file
public_new/js/constant.js
View file @
541d030a
...
@@ -36,5 +36,10 @@ const nameCardAreaId = {
...
@@ -36,5 +36,10 @@ const nameCardAreaId = {
USER
:
"userNamecard"
USER
:
"userNamecard"
}
}
const
makeRoomFlg
=
{
NAME_CARD
:
0
,
MAKE_ROOM
:
1
}
const
messageSeperator
=
"<::split>"
;
const
messageSeperator
=
"<::split>"
;
const
dataMessageScheme
=
"::NOT_MESSAGE"
;
const
dataMessageScheme
=
"::NOT_MESSAGE"
;
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