Commit a3787e8a by Lee Munkyeong

ルーム名変更に空欄を非許可する。

parent 2a5914e5
...@@ -12,8 +12,12 @@ window.onscroll = function() { ...@@ -12,8 +12,12 @@ window.onscroll = function() {
} }
$('#roomNameChangeBtn').click(function() { $('#roomNameChangeBtn').click(function() {
//TODO validation
var changeRoomName = $('#roomNameInput').val(); var changeRoomName = $('#roomNameInput').val();
var trimmedRoomName = $('#roomNameInput').val().trim();
if (trimmedRoomName.length == 0) {
alert(getLocalizedString("error_empty_room_name"));
return;
}
if (CHAT_UTIL.isIOS()) { if (CHAT_UTIL.isIOS()) {
webkit.messageHandlers.changeRoomName.postMessage(changeRoomName); webkit.messageHandlers.changeRoomName.postMessage(changeRoomName);
} else if (CHAT_UTIL.isAndroid()) { } else if (CHAT_UTIL.isAndroid()) {
......
...@@ -91,5 +91,6 @@ $.lang.en = { ...@@ -91,5 +91,6 @@ $.lang.en = {
"sunday":"sunday", "sunday":"sunday",
"collaboration_start":"collaboration start", "collaboration_start":"collaboration start",
"collaboration_end":"collaboration end", "collaboration_end":"collaboration end",
"notify_not_released" : "It will be released later." "notify_not_released" : "It will be released later.",
"error_empty_room_name" : "Please input room name."
} }
...@@ -91,5 +91,6 @@ $.lang.ja = { ...@@ -91,5 +91,6 @@ $.lang.ja = {
"sunday":"日曜日", "sunday":"日曜日",
"collaboration_start":"協業中", "collaboration_start":"協業中",
"collaboration_end":"協業終了", "collaboration_end":"協業終了",
"notify_not_released" : "今後リリース予定です。" "notify_not_released" : "今後リリース予定です。",
"error_empty_room_name" : "ルーム名を入力してください。"
} }
...@@ -91,5 +91,6 @@ $.lang.ko = { ...@@ -91,5 +91,6 @@ $.lang.ko = {
"sunday":"일요일", "sunday":"일요일",
"collaboration_start":"협업중", "collaboration_start":"협업중",
"collaboration_end":"협업종료", "collaboration_end":"협업종료",
"notify_not_released" : "추후 공개예정입니다." "notify_not_released" : "추후 공개예정입니다.",
"error_empty_room_name" : "룸명을 입력해주세요."
} }
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