Переглянути джерело

[이벤트][Common] 당첨자 발표 API 필드 추가

Hasemi 6 роки тому
батько
коміт
b332aa8e5b

+ 6 - 6
app/src/main/java/kr/co/zumo/app/lifeplus/bean/api/EventWinnerListBean.java

@@ -20,17 +20,17 @@ import java.util.List;
 public class EventWinnerListBean extends EventBean {
   @SerializedName("winPreDate")
   private String winnerDate; // 당첨자발표일, 2019-01-21
-  @SerializedName("description")
-  private String description; // 이벤트 설명 추후 반영
+  @SerializedName("notice")
+  private String notice; // 이벤트 설명 추후 반영
   @SerializedName("eventWinnerList")
   private List<EventWinnerBean> winnerList;
 
-  public String getDescription() {
-    return description;
+  public String getNotice() {
+    return notice;
   }
 
-  public void setDescription(String description) {
-    this.description = description;
+  public void setNotice(String notice) {
+    this.notice = notice;
   }
 
   public String getWinnerDate() {

+ 1 - 3
app/src/main/java/kr/co/zumo/app/lifeplus/view/screen/event/EventWinnerFragment.java

@@ -96,9 +96,7 @@ public class EventWinnerFragment extends FragmentBase<EventWinnerPresenter> impl
 
     textViewEventDate.setText(ResourceUtil.getString(R.string.event_period, EventBean.getTermString(bean)));
     textViewWinnerDate.setText(ResourceUtil.getString(R.string.event_announce, winnerDate));
-
-    // TODO: 당첨자 발표 내용 API 보완 필요함
-    textViewAnnouncementNotice.setText(bean.getDescription());
+    textViewAnnouncementNotice.setText(bean.getNotice());
 
     int emailId = R.id.text_view_email;
     int nameId = R.id.text_view_name;

+ 4 - 4
app/src/test/java/kr/co/zumo/app/lifeplus/bean/api/EventWinnerListBeanTest.java

@@ -22,8 +22,8 @@ public class EventWinnerListBeanTest {
   @Test
   public void setDescription() {
     EventWinnerListBean bean = new EventWinnerListBean();
-    bean.setDescription("description");
-    Assert.assertEquals("description", bean.getDescription());
+    bean.setNotice("description");
+    Assert.assertEquals("description", bean.getNotice());
     Assert.assertEquals(null, bean.getWinnerDate());
     Assert.assertEquals(null, bean.getWinnerList());
   }
@@ -32,7 +32,7 @@ public class EventWinnerListBeanTest {
   public void setWinnerDate() {
     EventWinnerListBean bean = new EventWinnerListBean();
     bean.setWinnerDate("date");
-    Assert.assertEquals(null, bean.getDescription());
+    Assert.assertEquals(null, bean.getNotice());
     Assert.assertEquals("date", bean.getWinnerDate());
     Assert.assertEquals(null, bean.getWinnerList());
   }
@@ -44,7 +44,7 @@ public class EventWinnerListBeanTest {
 
     bean.setWinnerList(winnerList);
 
-    Assert.assertEquals(null, bean.getDescription());
+    Assert.assertEquals(null, bean.getNotice());
     Assert.assertEquals(null, bean.getWinnerDate());
     Assert.assertEquals(winnerList, bean.getWinnerList());
   }