Commit eecd5a9f by Lee Munkyeong

#42144

parent 79ee277a
......@@ -47,11 +47,9 @@
<main id="chat">
<!-- ユーザー検索 -->
<div class="search_form">
<form>
<input type="search" name="search" placeholder="ルーム検索">
<span class="src_icon"></span>
<a href="#" class="cancel none">キャンセル</a>
</form>
</div>
<!-- タブ -->
<div class="content tabs">
......
......@@ -45,11 +45,10 @@
<form id="addUserForm" action="chat_add_user_confirm.html" method="post">
<!-- ユーザー検索 -->
<div class="search_form my-2">
<form>
<input type="search" name="search" placeholder="ユーザー検索">
<span class="src_icon"></span>
<a href="#" class="cancel none">キャンセル</a>
</form>
<input type="input" name="hidden_for_prevent_submit" hidden>
</div>
<!-- タブ -->
......
......@@ -106,8 +106,8 @@
</div>
</a>
</li>
<div id="childGroupListAreaForMakeRoom"></div>
<div id="userInGroupListForMakeRoom"></div>
<div id="childGroupListAreaForMakeRoom" class="chat_make_room"></div>
<div id="userInGroupListForMakeRoom" class="chat_make_room"></div>
</ul>
</div>
</div>
......
......@@ -177,6 +177,9 @@ input[name="tab_item"] {
.chat_list a {
color: #323743;
}
.chat_make_room a {
color: #323743;
}
/* タイトル(グループ名、個人名) */
.chat_item_ttl,
.chat_item_num {
......
$(function() {
// メンバー検索
$('#chat_add_user .search_form input[type="search"]').keyup(function(){
$('#chat_add_user .search_form input[type="search"]').keyup(function(e){
if (e.key == "Enter" || e.KeyCode == 13) {
$('#chat_add_user .search_form input[type="search"]').blur();
return false;
}
var isAllGroup = $('#tabAllGroupOnMakeRoom').is(':checked');
$('.overlay_src_msg').empty();
......@@ -51,7 +55,11 @@ $(function() {
});
let obj = jQuery.parseHTML(html);
$('.overlay_src_msg').append(obj);
if (userList.length == 0 && groupList.length == 0) {
const noResultMsg = $('<div/>',{width:'auto', style:'text-align: center'});
noResultMsg.append(getLocalizedString("noResult"))
$('.overlay_src_msg').append(noResultMsg);
}
  //連絡先画面
} else {
var keyword = $('#chat_add_user .search_form input[type="search"]').val();
......@@ -78,6 +86,11 @@ $(function() {
});
let obj = jQuery.parseHTML(html);
$('.overlay_src_msg').html(obj);
if (userList.length == 0) {
const noResultMsg = $('<div/>',{width:'auto', style:'text-align: center'});
noResultMsg.append(getLocalizedString("noResult"))
$('.overlay_src_msg').append(noResultMsg);
}
}
});
});
......@@ -1923,10 +1923,8 @@ CHAT_UI.showMakeRoomConfirmView = function() {
userNameList.push(user.shopMemberName);
})
//TODO DB作業が終わったら自分のユーザ名を表示するかを判断し、修正予定。
// 参加ユーザ名でルーム名を生成
let newRoomName = CHAT.globalLoginParameter.loginId + ',' + userNameList.join(',');
//todo android create room api
android.createChatRoom("1",userIdList.join(','),newRoomName);
} else if(trimmedRoomName.includes(';') || trimmedRoomName.includes('/') || trimmedRoomName.includes('?') || trimmedRoomName.includes(':') || trimmedRoomName.includes("@")
......
......@@ -338,7 +338,13 @@ $(function() {
});
// チャットメンバー検索
$('#chat .search_form input[type="search"]').keyup(function(){
$('#chat .search_form input[type="search"]').keyup(function(e){
if (e.key == "Enter" || e.KeyCode == 13) {
$('#chat .search_form input[type="search"]').blur();
return ;
}
$('.overlay_src_msg').empty();
var keyword = $('#chat .search_form input[type="search"]').val();
if (keyword == '' || keyword.length < 2) { return; }
......@@ -385,25 +391,27 @@ $(function() {
let obj = jQuery.parseHTML(html);
$('.overlay_src_msg').append(obj);
});
if (rooms.length == 0) {
const noResultMsg = $('<div/>',{width:'auto', style:'text-align: center'});
noResultMsg.append(getLocalizedString("noResult"))
$('.overlay_src_msg').append(noResultMsg);
}
if (CHAT_UI.isLandscapeMode()) {
$(".chat_list").removeClass("col-12").addClass("col-6");
}
});
// ルームメンバー検索
$('#chat_room .search_form input[type="search"]').keyup(function(){
$.ajax({
url: 'search_message_user_list.html',
type: 'POST',
datatype: 'html'
}).done(function (data) {
$('.overlay_src_msg').html(data);
})
});
// チャットルーム
// メッセージ検索イベント
$('.chat_room_src_form input[type="search"]').keyup(function(){
$('.chat_room_src_form input[type="search"]').keyup(function(e){
if (e.key == "Enter" || e.KeyCode == 13) {
$('.chat_room_src_form input[type="search"]').blur();
return ;
}
let workVal = "";
var keyword = $('.chat_room_src_form input[type="search"]').val();
$('.overlay_src_msg').empty();
......@@ -456,6 +464,11 @@ $(function() {
workVal = html + workVal;
})
jQueryMessages.prepend(workVal);
if (messages.length == 0) {
const noResultMsg = $('<div/>',{width:'auto', style:'text-align: center'});
noResultMsg.append(getLocalizedString("noResult"))
jQueryMessages.append(noResultMsg);
}
});
$('.filter_img').on('click', function() {
......
......@@ -56,7 +56,11 @@ $(function() {
});
let obj = jQuery.parseHTML(html);
$('.overlay_src_msg').append(obj);
if (groupList.length == 0 && userList.length == 0) {
const noResultMsg = $('<div/>',{width:'auto', style:'text-align: center'});
noResultMsg.append(getLocalizedString("noResult"))
$('.overlay_src_msg').append(noResultMsg);
}
  //連絡先画面
} else {
var keyword = $('#chatMakeRoom .search_form input[type="search"]').val();
......@@ -83,6 +87,11 @@ $(function() {
});
let obj = jQuery.parseHTML(html);
$('.overlay_src_msg').html(obj);
if (userList.length == 0) {
const noResultMsg = $('<div/>',{width:'auto', style:'text-align: center'});
noResultMsg.append(getLocalizedString("noResult"))
$('.overlay_src_msg').append(noResultMsg);
}
}
});
});
......@@ -48,8 +48,13 @@ $(function () {
userList: userList
});
let obj = jQuery.parseHTML(html);
$('.overlay_src_msg').append(obj);
$('.overlay_src_msg').append(obj);
if (userList.length == 0 && groupList.length == 0) {
const noResultMsg = $('<div/>',{width:'auto', style:'text-align: center'});
noResultMsg.append(getLocalizedString("noResult"))
$('.overlay_src_msg').append(noResultMsg);
}
  //連絡先画面
} else {
var keyword = $('#contact .search_form input[type="search"]').val();
......@@ -70,6 +75,11 @@ $(function () {
});
let obj = jQuery.parseHTML(html);
$('.overlay_src_msg').html(obj);
if (userList.length == 0) {
const noResultMsg = $('<div/>',{width:'auto', style:'text-align: center'});
noResultMsg.append(getLocalizedString("noResult"))
$('.overlay_src_msg').append(noResultMsg);
}
}
});
});
......@@ -76,5 +76,6 @@ $.lang.en = {
"archiveInsertDate":"Save Date",
"archiveRoomName":"ChatRoom Name",
"archiveSaveUser":"Save User",
"archiveAttendUser":"Attend User"
"archiveAttendUser":"Attend User",
"noResult":"there is no search result."
}
......@@ -76,5 +76,6 @@ $.lang.ja = {
"archiveInsertDate":"保存日",
"archiveRoomName":"チャットルーム名",
"archiveSaveUser":"保存ユーザー",
"archiveAttendUser":"参加ユーザー"
"archiveAttendUser":"参加ユーザー",
"noResult":"検索結果がありませんでした。"
}
......@@ -76,5 +76,6 @@ $.lang.ko = {
"archiveInsertDate":"저장 일",
"archiveRoomName":"대화방 이름",
"archiveSaveUser":"저장 사용자",
"archiveAttendUser":"참여자"
"archiveAttendUser":"참여자",
"noResult":"검색결과가 존재하지않습니다"
}
......@@ -6,7 +6,7 @@
<div class="chat_item d-flex flex-row align-items-center">
<div class="chat_item_l">
<div class="thumbnail">
<div class="img_wrap"><img src="{{profileImagePath}}" onError="this.src='./img/noImage.png'"/></div>
<div class="img_wrap"><img src="{{profileUrl}}" onError="this.src='./img/noImage.png'"/></div>
</div>
</div>
<div class="chat_item_m px-0">
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment