/*
 * COPYRIGHT (c) 2018 All rights reserved by HANWHA LIFE.
 */
package kr.co.zumo.app.lifeplus.view.presenter.signup;

import java.util.ArrayList;
import java.util.Arrays;

import kr.co.zumo.app.R;
import kr.co.zumo.app.lifeplus.view.presenter.SignUpPresenter;
import kr.co.zumo.app.lifeplus.bean.SignUpBenefitBean;
import kr.co.zumo.app.lifeplus.bean.SignUpBenefitListBean;

/**
 * SignUpStepBenefit
 * <pre>
 * </pre>
 *
 * @author 민효동
 * @version 1.0
 * @history 민효동   [2018. 9. 14.]   [최초 작성]
 * @since 2018. 9. 14.
 */
public class SignUpStepBenefit extends SignUpStep {
  public SignUpStepBenefit(SignUpPresenter model) {
    super(model);
  }

  @Override
  void __start() {
    SignUpBenefitBean bean = new SignUpBenefitBean("1 번째 텍스트", R.drawable.circle_full, "benefit text1", "category text1");
    SignUpBenefitBean bean2 = new SignUpBenefitBean("2 번째 텍스트", R.drawable.circle_full, "benefit text2", "category text2");
    SignUpBenefitBean bean3 = new SignUpBenefitBean("3 번째 텍스트", R.drawable.circle_full, "benefit text3", "category text3");
    ArrayList<SignUpBenefitBean> list = new ArrayList<>(Arrays.asList(bean, bean2, bean3));
    presenter.addItem(new SignUpItem(SignUpItem.SIGN_UP_BENEFIT, SignUpItem.ALIGN_CENTER, new SignUpBenefitListBean(list).toJson()));

    timeout(1000, this::callNextStep);
  }

  @Override
  void __validate() {
    isValidated = true;
  }

  @Override
  void __dispose() {
  }
}
