...
|
...
|
@@ -5,6 +5,7 @@ import android.content.Intent; |
|
|
import android.os.Bundle;
|
|
|
import android.support.annotation.Nullable;
|
|
|
import android.support.v4.app.FragmentTransaction;
|
|
|
import android.text.TextUtils;
|
|
|
import android.util.Log;
|
|
|
import android.view.LayoutInflater;
|
|
|
import android.view.View;
|
...
|
...
|
@@ -133,14 +134,26 @@ public class MineFragment extends BaseMvpFragment<CommonPresenter, PersonalModel |
|
|
Log.e("getUserName", bean.getUserName().trim());
|
|
|
if (bean.getLoginName() != null)
|
|
|
SharedPrefrenceUtils.saveString(getActivity(), "LoginName", bean.getLoginName());
|
|
|
if (bean.getHeadPic() != null && !bean.getHeadPic().equals("")) {
|
|
|
String headPic = SharedPrefrenceUtils.getString(getActivity(), "HeadPic");
|
|
|
Glide.with(getActivity()).load(headPic).into(imgUser);
|
|
|
} else {
|
|
|
SharedPrefrenceUtils.saveString(getActivity(), "ReallHeader", bean.getHeadPic());
|
|
|
|
|
|
String reallHeader = SharedPrefrenceUtils.getString(getContext(), "ReallHeader");
|
|
|
String headPic = SharedPrefrenceUtils.getString(getContext(), "HeadPic");
|
|
|
|
|
|
if (!TextUtils.isEmpty(headPic)) {
|
|
|
Glide.with(this).load(headPic).into(imgUser);
|
|
|
} else if (!TextUtils.isEmpty(reallHeader)) {
|
|
|
Glide.with(this).load(reallHeader).into(imgUser);
|
|
|
}else if(bean.getHeadPic() != null && !bean.getHeadPic().equals("")){
|
|
|
Glide.with(getActivity()).load(bean.getHeadPic()).into(imgUser);
|
|
|
}
|
|
|
|
|
|
// if (bean.getHeadPic() != null && !bean.getHeadPic().equals("")) {
|
|
|
// String headPic = SharedPrefrenceUtils.getString(getActivity(), "HeadPic");
|
|
|
// Glide.with(getActivity()).load(headPic).into(imgUser);
|
|
|
// } else {
|
|
|
// SharedPrefrenceUtils.saveString(getActivity(), "ReallHeader", bean.getHeadPic());
|
|
|
// Glide.with(getActivity()).load(bean.getHeadPic()).into(imgUser);
|
|
|
// }
|
|
|
|
|
|
}
|
|
|
}
|
|
|
|
...
|
...
|
|