浏览代码

[마이][New] '지금 보러가기' 버튼 이미지 로딩 시 표시

hyodong.min 6 年之前
父节点
当前提交
be3b5decfe

+ 3 - 0
app/src/main/java/kr/co/zumo/app/lifeplus/view/screen/my/main/MyMainFragment.java

@@ -87,6 +87,7 @@ public abstract class MyMainFragment extends FragmentBase<MyMainPresenter> imple
   private TextView textRecommendSubTitle;
   private ImageView imageRecommend;
   private View viewForTouchOfRecommend;
+  private View textRecommendButton;
 
   @Override
   protected View onAfterCreateView(@NonNull LayoutInflater inflater, @Nullable ViewGroup container, @Nullable Bundle savedInstanceState) {
@@ -115,6 +116,7 @@ public abstract class MyMainFragment extends FragmentBase<MyMainPresenter> imple
     textRecommendSubTitle = findViewById(R.id.text_recommend_sub_title);
     imageRecommend = findViewById(R.id.image_view_recommend);
     viewForTouchOfRecommend = findViewById(R.id.view_for_touch_of_recommend);
+    textRecommendButton = findViewById(R.id.text_recommend_button);
 
     textCouponCount = findViewById(R.id.text_view_coupon_count);
     textPurchaseCount = findViewById(R.id.text_view_purchase_count);
@@ -218,6 +220,7 @@ public abstract class MyMainFragment extends FragmentBase<MyMainPresenter> imple
   @Override
   public void setRecommendContents(MyRecommendContentsBean bean) {
     if (null != bean && StringUtil.isFull(bean.getImageUrl())) {
+      textRecommendButton.setVisibility(View.VISIBLE);
       textRecommendTitle.setText(bean.getTitle());
       textRecommendSubTitle.setText(bean.getSubTitle());
 

+ 0 - 17
app/src/main/java/kr/co/zumo/app/lifeplus/view/screen/my/main/MyMainModel.java

@@ -120,23 +120,6 @@ public class MyMainModel extends Model {
 
   public void loadPurchaseCount(IEventListener listener) {
     listener.onEvent(new Event.Builder(Event.SUCCESS).integer(0).build());
-//    disposableEvent = new APIEventMyListModule().call(new RequestBean(), new APIModuleListener<EventListResultBean>() {
-//      @Override
-//      public void onApiSuccess(EventListResultBean resultBean) {
-//        if (null != resultBean.getData()) {
-//          int count = resultBean.getData().size();
-//          listener.onEvent(new Event.Builder(Event.SUCCESS).integer(count).build());
-//        }
-//        else {
-//          this.onApiError("invalid result", new APIError(APIError.ERROR_INVAlID_RESULT));
-//        }
-//      }
-//
-//      @Override
-//      public void onApiError(String errorMessage, APIError error) {
-//        listener.onEvent(new Event.Builder(Event.ERROR).integer(0).build());
-//      }
-//    });
   }
 
   public MyRecommendContentsBean getMyRecommendContentsBean() {

+ 4 - 2
app/src/main/res/layout/fragment_my_main.xml

@@ -423,7 +423,7 @@
         android:textColor="@color/CFFFFFF"
         android:textSize="21sp"
         app:layout_constrainedHeight="true"
-        app:layout_constraintBottom_toTopOf="@+id/textView8"
+        app:layout_constraintBottom_toTopOf="@+id/text_recommend_button"
         app:layout_constraintEnd_toEndOf="parent"
         app:layout_constraintHorizontal_bias="0"
         app:layout_constraintStart_toStartOf="parent"
@@ -432,7 +432,7 @@
         tools:text="주목해야할 어드벤쳐 여행지 10선 주목해야할  "/>
 
       <TextView
-        android:id="@+id/textView8"
+        android:id="@+id/text_recommend_button"
         android:layout_width="wrap_content"
         android:layout_height="wrap_content"
         android:layout_marginStart="31dp"
@@ -447,6 +447,8 @@
         android:text="@string/go_contents"
         android:textColor="@color/CFFFFFF"
         android:textSize="12sp"
+        android:visibility="gone"
+        tools:visibility="visible"
         app:layout_constraintBottom_toBottomOf="parent"
         app:layout_constraintStart_toStartOf="parent"/>