s-code">
}
if (datas.size() == 0) {
ll_tishi.setVisibility(View.VISIBLE);
@ -345,7 +329,7 @@ public class ZhanCommentFragment extends Fragment {
}
private void getPullToRefreshData(final boolean isClear) {
String url = MainApplication.url + "/zhannew/basic/web/index.php/tpappcomments/get-comments?zhanid=" + NewZhanDetailsActivity.zhan_id + "&page=" + index;
String url = MainApplication.url + "/zhannew/basic/web/index.php/tpappcomments/get-comments?zhanid=" + NewZhanDetailsActivity.zhan_id + "&page=" + index+"&version_code=" + BuildConfig.VERSION_NAME;
OkHttpUtils.get().url(url)
.build().connTimeOut(6000).readTimeOut(6000)
.execute(new StringCallback() {
@ -374,15 +358,7 @@ public class ZhanCommentFragment extends Fragment {
for (int j = 0; j < jsonArray.length(); j++) {
JSONObject jsonObject = (JSONObject) jsonArray.opt(j);
String is_play = TextUtils.isEmpty( jsonObject.getString("is_play"))?"": jsonObject.getString("is_play") ; //0 审核未通过 item隐藏,1 审核通过,item显示
String type = TextUtils.isEmpty(jsonObject.getString("type"))?"":jsonObject.getString("type"); //23 视频,24 图片
if (type.equals("23")){
if (is_play.equals("1")){
datas.add(jsonObject);
}
}else{
datas.add(jsonObject);
}
datas.add(jsonObject);
}
if (isClear == false) {