Commit af9426bd by sikang

4.8v2

parent e0ed45c1
......@@ -115,41 +115,41 @@ public class ReviewHookActivity extends BaseActivity {
startLogin();
});
Dialog ysDialog = DialogFactory.createCustomDialog(this, R.layout.dialog_collect_tip,
(dialog, viewHolder) -> {
CheckBox checkBox = viewHolder.getCheckBox(R.id.dialog_collect_checkbox);
checkBox.setOnCheckedChangeListener((buttonView, isChecked) -> {
if (isChecked) {
viewHolder.getButton(R.id.dialog_collect_sure_btn).setTextColor(getResources().getColor(R.color.color_blue));
} else {
viewHolder.getButton(R.id.dialog_collect_sure_btn).setTextColor(getResources().getColor(R.color.qmui_config_color_gray_5));
}
});
UIHelper.bindClickListener((ViewGroup) viewHolder.getItemView(),
new OnNoShakeClickListener() {
@Override
public void onEventClick(View v) {
if (v.getId() == R.id.dialog_collect_agree_tv) {
checkBox.setChecked(!checkBox.isChecked());
} else if (v.getId() == R.id.dialog_collect_cancel_btn) {
finish();
} else if (v.getId() == R.id.dialog_collect_sure_btn) {
if (!checkBox.isChecked()) {
DialogFactory.showMessageDialog(ReviewHookActivity.this, getString(R.string.check_the_checkbox));
return;
}
dialog.dismiss();
}
}
},
R.id.dialog_collect_agree_tv,
R.id.dialog_collect_cancel_btn,
R.id.dialog_collect_sure_btn);
});
ysDialog.setCancelable(false);
ysDialog.show();
// Dialog ysDialog = DialogFactory.createCustomDialog(this, R.layout.dialog_collect_tip,
// (dialog, viewHolder) -> {
// CheckBox checkBox = viewHolder.getCheckBox(R.id.dialog_collect_checkbox);
// checkBox.setOnCheckedChangeListener((buttonView, isChecked) -> {
// if (isChecked) {
// viewHolder.getButton(R.id.dialog_collect_sure_btn).setTextColor(getResources().getColor(R.color.color_blue));
// } else {
// viewHolder.getButton(R.id.dialog_collect_sure_btn).setTextColor(getResources().getColor(R.color.qmui_config_color_gray_5));
// }
// });
//
// UIHelper.bindClickListener((ViewGroup) viewHolder.getItemView(),
// new OnNoShakeClickListener() {
// @Override
// public void onEventClick(View v) {
// if (v.getId() == R.id.dialog_collect_agree_tv) {
// checkBox.setChecked(!checkBox.isChecked());
// } else if (v.getId() == R.id.dialog_collect_cancel_btn) {
// finish();
// } else if (v.getId() == R.id.dialog_collect_sure_btn) {
// if (!checkBox.isChecked()) {
// DialogFactory.showMessageDialog(ReviewHookActivity.this, getString(R.string.check_the_checkbox));
// return;
// }
// dialog.dismiss();
// }
// }
// },
// R.id.dialog_collect_agree_tv,
// R.id.dialog_collect_cancel_btn,
// R.id.dialog_collect_sure_btn);
// });
//
// ysDialog.setCancelable(false);
// ysDialog.show();
}
......@@ -227,9 +227,8 @@ public class ReviewHookActivity extends BaseActivity {
} else if (i == R.id.activity_review_helpCenter_btn) {
HelpCenterActivity.start(ReviewHookActivity.this);
return;
} else if (i == R.id.activity_review_aboutUs_btn) {
AboutUsActivity.start(ReviewHookActivity.this);
return;
} else if(i == R.id.activity_review_hotline_btn){
DialogFactory.showMessageDialog(ReviewHookActivity.this,LibConfig.HOTLINE);
}
//需要登录才能使用的功能
if (LoginManager.get().getTokenInfo() == null) {
......
......@@ -72,6 +72,7 @@ public class LibConfig {
public static boolean IS_COLLECT_MODE;
public static String TEST_TOKEN;
public static String LANGUAGE = "in";
public static String HOOK_SYMBOL = "Rp";
public static int HARVESTER_PORT;//
public static int LOADING_ICON;//loading图标
public static int LOADING_BACKGROUND;//loading旋转背景
......
......@@ -663,6 +663,14 @@ public class UserPresenter extends BasePresenter<UserApi> {
/**
* 获取SD权限后再调用一次display
* */
public void refreshDiaplay(String action) {
handleRequest(action,apiService.display());
}
/**
* 获取联系人信息
*/
public void getContactInfo(String action) {
......
......@@ -7,6 +7,7 @@ import com.common.bean.ProductBean;
import java.util.List;
import tech.starwin.LibConfig;
import tech.starwin.R;
import tech.starwin.base.BaseRecyclerAdapter;
import tech.starwin.base.RecyclerViewHolder;
......@@ -30,11 +31,12 @@ public class ReviewProductAdapter extends BaseRecyclerAdapter<ProductBean> {
holder.getTextView(R.id.item_review_product_productName_tv).setText(item.getName() + getContext().getString(R.string.text_interest_day));
//额度
String amount;
if (item.getMaxAmount() - item.getMinAmount() < 1 ) {
if (item.getMaxAmount() - item.getMinAmount() < 1) {
amount = StringFormat.moneyFormat(getContext(), item.getMinAmount());
} else {
amount = StringFormat.moneyFormat(getContext(), item.getMinAmount()) + " | " + StringFormat.moneyFormat(getContext(), item.getMaxAmount());
}
amount = amount.replace(getContext().getString(R.string.moneySymbol), LibConfig.HOOK_SYMBOL);
holder.getTextView(R.id.item_review_product_amount_tv).setText(amount);
//还款期限
String period;
......
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