修复个人信息历史信用分bug

master
Vin 4 years ago
parent c5b58c41e1
commit 13324a773d
  1. 7
      app/src/main/java/com/community/pocket/ui/main/ui/info/InfoFragment.java

@ -256,6 +256,8 @@ public class InfoFragment extends BaseFragment {
if (myInfo.getScoreHistory() != null && myInfo.getScoreHistory().size() >= MIN_HISTORY) {
loadChart(myInfo.getScoreHistory());
}else{
Toast.makeText(getContext(),R.string.no_score_history,Toast.LENGTH_SHORT).show();
}
}
@ -629,7 +631,10 @@ public class InfoFragment extends BaseFragment {
xAxis.setValueFormatter(new ValueFormatter() {
@Override
public String getFormattedValue(float value) {
int index = (int) (value - 1);
int index = (int) (value);
if(index==values.size()){
return "";
}
return formatUnix(values.get(index).getTime());
}
});

Loading…
Cancel
Save