Commit 4f6bf9b1 by Kim Peace

Merge branch 'refactoring/boolValueFromString' into 'develop'

Refactoring/bool value from string

See merge request !199
parents 8e1aea93 79decaa6
...@@ -8,7 +8,7 @@ ...@@ -8,7 +8,7 @@
content="width=device-width, initial-scale=1, shrink-to-fit=no, maximum-scale=1, user-scalable=0"> content="width=device-width, initial-scale=1, shrink-to-fit=no, maximum-scale=1, user-scalable=0">
<title>LiveTaskyell</title> <title>LiveTaskyell</title>
<link rel="stylesheet" href="./css/notosansjp.css"> <link rel="stylesheet" href="./css/notosansjp.css">
<link href="./fontawesome/css/all.css" rel="stylesheet"> <link rel="stylesheet" href="./fontawesome/css/all.css">
<link rel="stylesheet" href="./css/bootstrap.min.css"> <link rel="stylesheet" href="./css/bootstrap.min.css">
<link rel="stylesheet" href="./css/common.css"> <link rel="stylesheet" href="./css/common.css">
<link rel="stylesheet" href="./css/archive.css"> <link rel="stylesheet" href="./css/archive.css">
......
...@@ -8,7 +8,7 @@ ...@@ -8,7 +8,7 @@
content="width=device-width, initial-scale=1, shrink-to-fit=no, maximum-scale=1, user-scalable=0"> content="width=device-width, initial-scale=1, shrink-to-fit=no, maximum-scale=1, user-scalable=0">
<title>LiveTaskyell</title> <title>LiveTaskyell</title>
<link rel="stylesheet" href="./css/notosansjp.css"> <link rel="stylesheet" href="./css/notosansjp.css">
<link href="./fontawesome/css/all.css" rel="stylesheet"> <link rel="stylesheet" href="./fontawesome/css/all.css">
<link rel="stylesheet" href="./css/bootstrap.min.css"> <link rel="stylesheet" href="./css/bootstrap.min.css">
<link rel="stylesheet" href="./css/common.css"> <link rel="stylesheet" href="./css/common.css">
<link rel="stylesheet" href="./css/archive.css"> <link rel="stylesheet" href="./css/archive.css">
......
...@@ -8,7 +8,7 @@ ...@@ -8,7 +8,7 @@
content="width=device-width, initial-scale=1, shrink-to-fit=no, maximum-scale=1, user-scalable=0"> content="width=device-width, initial-scale=1, shrink-to-fit=no, maximum-scale=1, user-scalable=0">
<title>LiveTaskyell</title> <title>LiveTaskyell</title>
<link rel="stylesheet" href="./css/notosansjp.css"> <link rel="stylesheet" href="./css/notosansjp.css">
<link href="./fontawesome/css/all.css" rel="stylesheet"> <link rel="stylesheet" href="./fontawesome/css/all.css" >
<link rel="stylesheet" href="./css/bootstrap.min.css"> <link rel="stylesheet" href="./css/bootstrap.min.css">
<link rel="stylesheet" href="./css/common.css"> <link rel="stylesheet" href="./css/common.css">
<link rel="stylesheet" href="./css/chat.css"> <link rel="stylesheet" href="./css/chat.css">
......
...@@ -8,7 +8,7 @@ ...@@ -8,7 +8,7 @@
content="width=device-width, initial-scale=1, shrink-to-fit=no, maximum-scale=1, user-scalable=0"> content="width=device-width, initial-scale=1, shrink-to-fit=no, maximum-scale=1, user-scalable=0">
<title>LiveTaskyell</title> <title>LiveTaskyell</title>
<link rel="stylesheet" href="./css/notosansjp.css"> <link rel="stylesheet" href="./css/notosansjp.css">
<link href="./fontawesome/css/all.css" rel="stylesheet"> <link rel="stylesheet" href="./fontawesome/css/all.css" >
<link rel="stylesheet" href="./css/bootstrap.min.css"> <link rel="stylesheet" href="./css/bootstrap.min.css">
<link rel="stylesheet" href="./css/common.css"> <link rel="stylesheet" href="./css/common.css">
<link rel="stylesheet" href="./css/chat.css"> <link rel="stylesheet" href="./css/chat.css">
......
...@@ -8,7 +8,7 @@ ...@@ -8,7 +8,7 @@
content="width=device-width, initial-scale=1, shrink-to-fit=no, maximum-scale=1, user-scalable=0"> content="width=device-width, initial-scale=1, shrink-to-fit=no, maximum-scale=1, user-scalable=0">
<title>LiveTaskyell</title> <title>LiveTaskyell</title>
<link rel="stylesheet" href="./css/notosansjp.css"> <link rel="stylesheet" href="./css/notosansjp.css">
<link href="./fontawesome/css/all.css" rel="stylesheet"> <link rel="stylesheet" href="./fontawesome/css/all.css">
<link rel="stylesheet" href="./css/bootstrap.min.css"> <link rel="stylesheet" href="./css/bootstrap.min.css">
<link rel="stylesheet" href="./css/common.css"> <link rel="stylesheet" href="./css/common.css">
<link rel="stylesheet" href="./css/chat.css"> <link rel="stylesheet" href="./css/chat.css">
......
...@@ -8,7 +8,7 @@ ...@@ -8,7 +8,7 @@
content="width=device-width, initial-scale=1, shrink-to-fit=no, maximum-scale=1, user-scalable=0"> content="width=device-width, initial-scale=1, shrink-to-fit=no, maximum-scale=1, user-scalable=0">
<title>LiveTaskyell</title> <title>LiveTaskyell</title>
<link rel="stylesheet" href="./css/notosansjp.css"> <link rel="stylesheet" href="./css/notosansjp.css">
<link href="./fontawesome/css/all.css" rel="stylesheet"> <link rel="stylesheet" href="./fontawesome/css/all.css" >
<link rel="stylesheet" href="./css/bootstrap.min.css"> <link rel="stylesheet" href="./css/bootstrap.min.css">
<link rel="stylesheet" href="./css/common.css"> <link rel="stylesheet" href="./css/common.css">
<link rel="stylesheet" href="./css/chat.css"> <link rel="stylesheet" href="./css/chat.css">
......
...@@ -8,7 +8,7 @@ ...@@ -8,7 +8,7 @@
content="width=device-width, initial-scale=1, shrink-to-fit=no, maximum-scale=1, user-scalable=0"> content="width=device-width, initial-scale=1, shrink-to-fit=no, maximum-scale=1, user-scalable=0">
<title>LiveTaskyell</title> <title>LiveTaskyell</title>
<link rel="stylesheet" href="./css/notosansjp.css"> <link rel="stylesheet" href="./css/notosansjp.css">
<link href="./fontawesome/css/all.css" rel="stylesheet"> <link rel="stylesheet" href="./fontawesome/css/all.css" >
<link rel="stylesheet" href="./css/bootstrap.min.css"> <link rel="stylesheet" href="./css/bootstrap.min.css">
<link rel="stylesheet" href="./css/common.css"> <link rel="stylesheet" href="./css/common.css">
<link rel="stylesheet" href="./css/chat.css"> <link rel="stylesheet" href="./css/chat.css">
......
...@@ -8,7 +8,7 @@ ...@@ -8,7 +8,7 @@
content="width=device-width, initial-scale=1, shrink-to-fit=no, maximum-scale=1, user-scalable=0"> content="width=device-width, initial-scale=1, shrink-to-fit=no, maximum-scale=1, user-scalable=0">
<title>LiveTaskyell</title> <title>LiveTaskyell</title>
<link rel="stylesheet" href="./css/notosansjp.css"> <link rel="stylesheet" href="./css/notosansjp.css">
<link href="./fontawesome/css/all.css" rel="stylesheet"> <link rel="stylesheet" href="./fontawesome/css/all.css" >
<link rel="stylesheet" href="./css/bootstrap.min.css"> <link rel="stylesheet" href="./css/bootstrap.min.css">
<link rel="stylesheet" href="./css/common.css"> <link rel="stylesheet" href="./css/common.css">
<link rel="stylesheet" href="./css/chat.css"> <link rel="stylesheet" href="./css/chat.css">
......
...@@ -8,7 +8,7 @@ ...@@ -8,7 +8,7 @@
content="width=device-width, initial-scale=1, shrink-to-fit=no, maximum-scale=1, user-scalable=0"> content="width=device-width, initial-scale=1, shrink-to-fit=no, maximum-scale=1, user-scalable=0">
<title>LiveTaskyell</title> <title>LiveTaskyell</title>
<!--<link rel="stylesheet" href="./css/notosansjp.css">--> <!--<link rel="stylesheet" href="./css/notosansjp.css">-->
<link href="./fontawesome/css/all.css" rel="stylesheet"> <link rel="stylesheet" href="./fontawesome/css/all.css" >
<link rel="stylesheet" href="./css/bootstrap.min.css"> <link rel="stylesheet" href="./css/bootstrap.min.css">
<link rel="stylesheet" href="./css/jquery-ui.min.css"> <link rel="stylesheet" href="./css/jquery-ui.min.css">
<link rel="stylesheet" href="./css/common.css"> <link rel="stylesheet" href="./css/common.css">
......
...@@ -8,7 +8,7 @@ ...@@ -8,7 +8,7 @@
content="width=device-width, initial-scale=1, shrink-to-fit=no, maximum-scale=1, user-scalable=0"> content="width=device-width, initial-scale=1, shrink-to-fit=no, maximum-scale=1, user-scalable=0">
<title>LiveTaskyell</title> <title>LiveTaskyell</title>
<link rel="stylesheet" href="./css/notosansjp.css"> <link rel="stylesheet" href="./css/notosansjp.css">
<link href="./fontawesome/css/all.css" rel="stylesheet"> <link rel="stylesheet" href="./fontawesome/css/all.css" >
<link rel="stylesheet" href="./css/bootstrap.min.css"> <link rel="stylesheet" href="./css/bootstrap.min.css">
<link rel="stylesheet" href="./css/common.css"> <link rel="stylesheet" href="./css/common.css">
<link rel="stylesheet" href="./css/contact.css"> <link rel="stylesheet" href="./css/contact.css">
......
...@@ -8,7 +8,7 @@ ...@@ -8,7 +8,7 @@
content="width=device-width, initial-scale=1, shrink-to-fit=no, maximum-scale=1, user-scalable=0"> content="width=device-width, initial-scale=1, shrink-to-fit=no, maximum-scale=1, user-scalable=0">
<title>LiveTaskyell</title> <title>LiveTaskyell</title>
<link rel="stylesheet" href="./css/notosansjp.css"> <link rel="stylesheet" href="./css/notosansjp.css">
<link href="./fontawesome/css/all.css" rel="stylesheet"> <link rel="stylesheet" href="./fontawesome/css/all.css" >
<link rel="stylesheet" href="./css/bootstrap.min.css"> <link rel="stylesheet" href="./css/bootstrap.min.css">
<link rel="stylesheet" href="./css/common.css"> <link rel="stylesheet" href="./css/common.css">
<link rel="stylesheet" href="./css/contact.css"> <link rel="stylesheet" href="./css/contact.css">
......
...@@ -8,7 +8,7 @@ ...@@ -8,7 +8,7 @@
content="width=device-width, initial-scale=1, shrink-to-fit=no, maximum-scale=1, user-scalable=0"> content="width=device-width, initial-scale=1, shrink-to-fit=no, maximum-scale=1, user-scalable=0">
<title>LiveTaskyell</title> <title>LiveTaskyell</title>
<link rel="stylesheet" href="./css/notosansjp.css"> <link rel="stylesheet" href="./css/notosansjp.css">
<link href="./fontawesome/css/all.css" rel="stylesheet"> <link rel="stylesheet" href="./fontawesome/css/all.css" >
<link rel="stylesheet" href="./css/bootstrap.min.css"> <link rel="stylesheet" href="./css/bootstrap.min.css">
<link rel="stylesheet" href="./css/common.css"> <link rel="stylesheet" href="./css/common.css">
<link rel="stylesheet" href="./css/collaboration.css"> <link rel="stylesheet" href="./css/collaboration.css">
......
...@@ -8,7 +8,7 @@ ...@@ -8,7 +8,7 @@
content="width=device-width, initial-scale=1, shrink-to-fit=no, maximum-scale=1, user-scalable=0"> content="width=device-width, initial-scale=1, shrink-to-fit=no, maximum-scale=1, user-scalable=0">
<title>LiveTaskyell</title> <title>LiveTaskyell</title>
<link rel="stylesheet" href="./css/notosansjp.css"> <link rel="stylesheet" href="./css/notosansjp.css">
<link href="./fontawesome/css/all.css" rel="stylesheet"> <link rel="stylesheet" href="./fontawesome/css/all.css" >
<link rel="stylesheet" href="./css/bootstrap.min.css"> <link rel="stylesheet" href="./css/bootstrap.min.css">
<link rel="stylesheet" href="./css/common.css"> <link rel="stylesheet" href="./css/common.css">
<link rel="stylesheet" href="./css/collaboration.css"> <link rel="stylesheet" href="./css/collaboration.css">
......
...@@ -8,7 +8,7 @@ ...@@ -8,7 +8,7 @@
content="width=device-width, initial-scale=1, shrink-to-fit=no, maximum-scale=1, user-scalable=0"> content="width=device-width, initial-scale=1, shrink-to-fit=no, maximum-scale=1, user-scalable=0">
<title>LiveTaskyell</title> <title>LiveTaskyell</title>
<link rel="stylesheet" href="./css/notosansjp.css"> <link rel="stylesheet" href="./css/notosansjp.css">
<link href="./fontawesome/css/all.css" rel="stylesheet"> <link rel="stylesheet" href="./fontawesome/css/all.css" >
<link rel="stylesheet" href="./css/bootstrap.min.css"> <link rel="stylesheet" href="./css/bootstrap.min.css">
<link rel="stylesheet" href="./css/common.css"> <link rel="stylesheet" href="./css/common.css">
<link rel="stylesheet" href="./css/contact.css"> <link rel="stylesheet" href="./css/contact.css">
......
...@@ -8,7 +8,7 @@ ...@@ -8,7 +8,7 @@
content="width=device-width, initial-scale=1, shrink-to-fit=no, maximum-scale=1, user-scalable=0"> content="width=device-width, initial-scale=1, shrink-to-fit=no, maximum-scale=1, user-scalable=0">
<title>LiveTaskyell</title> <title>LiveTaskyell</title>
<link rel="stylesheet" href="./css/notosansjp.css"> <link rel="stylesheet" href="./css/notosansjp.css">
<link href="./fontawesome/css/all.css" rel="stylesheet"> <link rel="stylesheet" href="./fontawesome/css/all.css" >
<link rel="stylesheet" href="./css/bootstrap.min.css"> <link rel="stylesheet" href="./css/bootstrap.min.css">
<link rel="stylesheet" href="./css/common.css"> <link rel="stylesheet" href="./css/common.css">
<link rel="stylesheet" href="./css/collaboration.css"> <link rel="stylesheet" href="./css/collaboration.css">
......
...@@ -8,7 +8,7 @@ ...@@ -8,7 +8,7 @@
content="width=device-width, initial-scale=1, shrink-to-fit=no, maximum-scale=1, user-scalable=0"> content="width=device-width, initial-scale=1, shrink-to-fit=no, maximum-scale=1, user-scalable=0">
<title>LiveTaskyell</title> <title>LiveTaskyell</title>
<link rel="stylesheet" href="./css/notosansjp.css"> <link rel="stylesheet" href="./css/notosansjp.css">
<link href="./fontawesome/css/all.css" rel="stylesheet"> <link rel="stylesheet" href="./fontawesome/css/all.css">
<link rel="stylesheet" href="./css/bootstrap.min.css"> <link rel="stylesheet" href="./css/bootstrap.min.css">
<link rel="stylesheet" href="./css/common.css"> <link rel="stylesheet" href="./css/common.css">
<link rel="stylesheet" href="./css/chat.css"> <link rel="stylesheet" href="./css/chat.css">
......
...@@ -15,6 +15,10 @@ function callNativeApp(iosKey, jsonData) { ...@@ -15,6 +15,10 @@ function callNativeApp(iosKey, jsonData) {
return result; return result;
} }
function parseBoolStringToBool(str) {
return str == "true" ? true : false;
}
var NativeBridgeDataSource = {}; var NativeBridgeDataSource = {};
NativeBridgeDataSource.removeFavoriteGroup = function (groupID) { NativeBridgeDataSource.removeFavoriteGroup = function (groupID) {
...@@ -22,7 +26,7 @@ NativeBridgeDataSource.removeFavoriteGroup = function (groupID) { ...@@ -22,7 +26,7 @@ NativeBridgeDataSource.removeFavoriteGroup = function (groupID) {
const result = callNativeApp(NATIVE_KEY_IOS.removeFavoriteGroup, { const result = callNativeApp(NATIVE_KEY_IOS.removeFavoriteGroup, {
groupId: groupID, groupId: groupID,
}); });
return result == "true" ? true : false; return parseBoolStringToBool(result);
} else { } else {
return android.removeFavoriteGroup(groupID); return android.removeFavoriteGroup(groupID);
} }
...@@ -35,11 +39,7 @@ NativeBridgeDataSource.addFavoriteGroup = function (groupID) { ...@@ -35,11 +39,7 @@ NativeBridgeDataSource.addFavoriteGroup = function (groupID) {
const result = callNativeApp(NATIVE_KEY_IOS.addFavoriteGroup, { const result = callNativeApp(NATIVE_KEY_IOS.addFavoriteGroup, {
groupId: groupID, groupId: groupID,
}); });
if (result == "true") { return parseBoolStringToBool(result);
return true;
} else {
return false;
}
} }
}; };
...@@ -352,14 +352,10 @@ NativeBridgeDataSource.getBeforeRoomType = function () { ...@@ -352,14 +352,10 @@ NativeBridgeDataSource.getBeforeRoomType = function () {
NativeBridgeDataSource.removeFavoriteUser = function (shopMemberId) { NativeBridgeDataSource.removeFavoriteUser = function (shopMemberId) {
if (deviceInfo.isiOS()) { if (deviceInfo.isiOS()) {
var result = callNativeApp(NATIVE_KEY_IOS.removeFavoriteUser, { const result = callNativeApp(NATIVE_KEY_IOS.removeFavoriteUser, {
shopMemberId: shopMemberId, shopMemberId: shopMemberId,
}); });
if (result == "true") { return parseBoolStringToBool(result);
return true;
} else {
return false;
}
} else { } else {
return android.removeFavoriteUser(shopMemberId); return android.removeFavoriteUser(shopMemberId);
} }
...@@ -367,14 +363,10 @@ NativeBridgeDataSource.removeFavoriteUser = function (shopMemberId) { ...@@ -367,14 +363,10 @@ NativeBridgeDataSource.removeFavoriteUser = function (shopMemberId) {
NativeBridgeDataSource.addFavoriteUser = function (shopMemberId) { NativeBridgeDataSource.addFavoriteUser = function (shopMemberId) {
if (deviceInfo.isiOS()) { if (deviceInfo.isiOS()) {
var result = callNativeApp(NATIVE_KEY_IOS.addFavoriteUser, { const result = callNativeApp(NATIVE_KEY_IOS.addFavoriteUser, {
shopMemberId: shopMemberId, shopMemberId: shopMemberId,
}); });
if (result == "true") { return parseBoolStringToBool(result);
return true;
} else {
return false;
}
} else { } else {
return android.addFavoriteUser(shopMemberId); return android.addFavoriteUser(shopMemberId);
} }
...@@ -391,8 +383,6 @@ NativeBridgeDataSource.getJoinCollaborationType = function () { ...@@ -391,8 +383,6 @@ NativeBridgeDataSource.getJoinCollaborationType = function () {
} }
}; };
NativeBridgeDataSource.getUserInfoList = function (shopMemberId) { NativeBridgeDataSource.getUserInfoList = function (shopMemberId) {
if (deviceInfo.isiOS()) { if (deviceInfo.isiOS()) {
return callNativeApp(NATIVE_KEY_IOS.getUserInfoList, { return callNativeApp(NATIVE_KEY_IOS.getUserInfoList, {
......
...@@ -270,7 +270,7 @@ NativeBridgeDelegate.updateMessages = function (roomID) { ...@@ -270,7 +270,7 @@ NativeBridgeDelegate.updateMessages = function (roomID) {
NativeBridgeDelegate.saveVisitRoomInfo = function (roomID = "", roomName = "") { NativeBridgeDelegate.saveVisitRoomInfo = function (roomID = "", roomName = "") {
if (deviceInfo.isiOS()) { if (deviceInfo.isiOS()) {
webkit.messageHandlers.roomInfosaveMessageHandlerId.postMessage({ webkit.messageHandlers.roomInfoSaveMessageHandlerId.postMessage({
roomId: roomID, roomId: roomID,
roomName: roomName, roomName: roomName,
}); });
......
...@@ -22,7 +22,7 @@ ...@@ -22,7 +22,7 @@
<button type="button" class="border-0 bg_navy" <button type="button" class="border-0 bg_navy"
onclick="CollaborationUI.removeFavoriteUserInCollaboration({{shopMemberId}})" id="favoriteButton"> onclick="CollaborationUI.removeFavoriteUserInCollaboration({{shopMemberId}})" id="favoriteButton">
<div class="d-flex flex-column"> <div class="d-flex flex-column">
<span class="star active shopmember_890" onclick="CHAT_UI.favoriteUserChange(890,this)"></span> <span class="star active shopmember_{{shopMemberId}}" onclick="CHAT_UI.favoriteUserChange('{{shopMemberId}}',this)"></span>
<span>お気に入り解除</span> <span>お気に入り解除</span>
</div> </div>
</button> </button>
...@@ -31,7 +31,7 @@ ...@@ -31,7 +31,7 @@
<button type="button" class="border-0 bg_navy" <button type="button" class="border-0 bg_navy"
onclick="CollaborationUI.insertFavoriteUserInCollaboration({{shopMemberId}})" id="favoriteButton"> onclick="CollaborationUI.insertFavoriteUserInCollaboration({{shopMemberId}})" id="favoriteButton">
<div class="d-flex flex-column"> <div class="d-flex flex-column">
<span class="star disable shopmember_3690" onclick="Namecard.favoriteUserChange(3690,this)"></span> <span class="star disable shopmember_{{shopMemberId}}" onclick="Namecard.favoriteUserChange('{{shopMemberId}}',this)"></span>
<span>お気に入り登録</span> <span>お気に入り登録</span>
</div> </div>
</button> </button>
......
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