Commit 11a97e36 by Lee Munkyeong

ユーザDAO追加,サーバURL修正

parent 60f5c344
......@@ -5,6 +5,7 @@ import java.util.List;
import jp.agentec.abook.abv.bl.common.db.Cursor;
import jp.agentec.abook.abv.bl.common.log.Logger;
import jp.agentec.abook.abv.bl.dto.ChatRoomDto;
import jp.agentec.abook.abv.bl.dto.MemberInfoDto;
import jp.agentec.abook.abv.bl.dto.ShopMemberDto;
import jp.agentec.adf.util.DateTimeFormat;
......@@ -53,7 +54,31 @@ public class ShopMemberDao extends AbstractDao {
return rawQueryGetDto("select * from m_shop_member where shop_member_id=?", new String[]{""+ shopMemberId}, ShopMemberDto.class);
}
public void insertShopMember(ShopMemberDto dto) {
insert("insert into m_shop_member (shop_member_id, shop_member_name, profile_url, favorite_register_date) values (?,?,?,?)", dto.getInsertValues());
insert("insert into m_shop_member (shop_member_id, shop_member_name, profile_url, favorite_register_date, self_flg) values (?,?,?,?,?)", dto.getInsertValues());
}
public ShopMemberDto getMyInfo() {
return rawQueryGetDto("select * from m_shop_member where self_flg = 1", null, ShopMemberDto.class);
}
public List<ShopMemberDto> getfavoriteUserList() {
return rawQueryGetDtoList("select * from m_shop_member where favorite_register_date NOT NULL", null, ShopMemberDto.class);
}
public List<ShopMemberDto> getUserListByGroupId(Integer groupId) {
StringBuffer sql = new StringBuffer();
sql.append(" SELECT ");
sql.append(" sm.shop_member_id ");
sql.append(" ,sm.shop_member_name ");
sql.append(" ,sm.profile_url");
sql.append(" FROM ");
sql.append(" m_shop_member AS sm ");
sql.append(" INNER JOIN r_shop_member_group AS rsmg ");
sql.append(" ON sm.shop_member_id = rsmg.shop_member_id ");
sql.append(" WHERE rsmg.group_id =?");
sql.append(" ORDER BY sm.shop_member_name DESC ");
List<ShopMemberDto> list = rawQueryGetDtoList(sql.toString(), new String[]{""+ groupId}, ShopMemberDto.class);
return list;
}
public boolean updateShopMember(MemberInfoDto dto) {
......
......@@ -20,6 +20,7 @@ public class MShopMember extends SQLiteTableScript {
sql.append(" , shop_member_name VARCHAR(64) ");
sql.append(" , profile_url VARCHAR(64) ");
sql.append(" , favorite_register_date VARCHAR2(64) ");
sql.append(" self_flg INTEGER NOT NULL ");
sql.append(" , PRIMARY KEY (shop_member_id) ");
sql.append(" ) ");
......
......@@ -7,10 +7,11 @@ public class ShopMemberDto extends AbstractDto {
public String shopMemberName;
public String profileUrl;
public String favoriteRegisterDate;
public Integer selfFlg;
@Override
public Object[] getInsertValues() {
return new Object[] { shopMemberId, shopMemberName, profileUrl, favoriteRegisterDate };
return new Object[] { shopMemberId, shopMemberName, profileUrl, favoriteRegisterDate, selfFlg };
}
@Override
......
......@@ -40,12 +40,12 @@ app_versioncode=1
#cms server
#acms_address=http://10.0.2.2:8081/acms
#download_server_address=http://10.0.2.2:8081/acms
acms_address=https://chatdev2.abook.bz/acms
download_server_address=https://chatdev2.abook.bz/acms
acms_address=https://chatdev2.agentec.jp/acms
download_server_address=https://chatdev2.agentec.jp/acms
#syncview server
websocket_server_http_url=https://chatdev2.abook.bz/v1
websocket_server_ws_url=wss://chatdev2.abook.bz/v1
websocket_server_http_url=https://chatdev2.agentec.jp/v1
websocket_server_ws_url=wss://chatdev2.agentec.jp/v1
#WebSocket debug出力
websocket_debug=false
......
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