Merge branch 'master' of https://gitee.com/renjianbo0118/HouseProperty
This commit is contained in:
1
.idea/runConfigurations.xml
generated
1
.idea/runConfigurations.xml
generated
@@ -3,6 +3,7 @@
|
|||||||
<component name="RunConfigurationProducerService">
|
<component name="RunConfigurationProducerService">
|
||||||
<option name="ignoredProducers">
|
<option name="ignoredProducers">
|
||||||
<set>
|
<set>
|
||||||
|
<option value="com.android.tools.idea.compose.preview.runconfiguration.ComposePreviewRunConfigurationProducer" />
|
||||||
<option value="org.jetbrains.plugins.gradle.execution.test.runner.AllInPackageGradleConfigurationProducer" />
|
<option value="org.jetbrains.plugins.gradle.execution.test.runner.AllInPackageGradleConfigurationProducer" />
|
||||||
<option value="org.jetbrains.plugins.gradle.execution.test.runner.TestClassGradleConfigurationProducer" />
|
<option value="org.jetbrains.plugins.gradle.execution.test.runner.TestClassGradleConfigurationProducer" />
|
||||||
<option value="org.jetbrains.plugins.gradle.execution.test.runner.TestMethodGradleConfigurationProducer" />
|
<option value="org.jetbrains.plugins.gradle.execution.test.runner.TestMethodGradleConfigurationProducer" />
|
||||||
|
|||||||
@@ -46,6 +46,11 @@ android {
|
|||||||
abiFilters 'armeabi-v7a'
|
abiFilters 'armeabi-v7a'
|
||||||
|
|
||||||
}
|
}
|
||||||
|
manifestPlaceholders = [
|
||||||
|
JPUSH_PKGNAME : applicationId,
|
||||||
|
JPUSH_APPKEY : "4b6e03f9cc9466efbc0b2528", //JPush 上注册的包名对应的 Appkey.
|
||||||
|
JPUSH_CHANNEL : "developer-default", //暂时填写默认值即可.
|
||||||
|
]
|
||||||
}
|
}
|
||||||
buildTypes {
|
buildTypes {
|
||||||
release {
|
release {
|
||||||
@@ -149,6 +154,8 @@ android {
|
|||||||
|
|
||||||
|
|
||||||
implementation 'com.lzy.net:okgo:3.0.4'
|
implementation 'com.lzy.net:okgo:3.0.4'
|
||||||
|
implementation 'cn.jiguang.sdk:jpush:3.6.6'
|
||||||
|
implementation 'cn.jiguang.sdk:jcore:2.3.8'
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -78,6 +78,26 @@
|
|||||||
<!-- <queries>-->
|
<!-- <queries>-->
|
||||||
<!-- <package android:name="com.tencent.mm" />-->
|
<!-- <package android:name="com.tencent.mm" />-->
|
||||||
<!-- </queries>-->
|
<!-- </queries>-->
|
||||||
|
<receiver
|
||||||
|
android:name=".push.MyReceiver"
|
||||||
|
android:enabled="true"
|
||||||
|
android:exported="false">
|
||||||
|
<intent-filter>
|
||||||
|
<action android:name="cn.jpush.android.intent.RECEIVE_MESSAGE" />
|
||||||
|
|
||||||
|
<category android:name="com.sl.house_property" />
|
||||||
|
</intent-filter>
|
||||||
|
</receiver>
|
||||||
|
|
||||||
|
<service
|
||||||
|
android:name=".push.XService"
|
||||||
|
android:enabled="true"
|
||||||
|
android:exported="false"
|
||||||
|
android:process=":pushcore">
|
||||||
|
<intent-filter>
|
||||||
|
<action android:name="cn.jiguang.user.service.action" />
|
||||||
|
</intent-filter>
|
||||||
|
</service>
|
||||||
<provider
|
<provider
|
||||||
android:name="com.sl.house_property.ImagePickerProvider"
|
android:name="com.sl.house_property.ImagePickerProvider"
|
||||||
android:authorities="${applicationId}.provider"
|
android:authorities="${applicationId}.provider"
|
||||||
|
|||||||
@@ -19,6 +19,7 @@ import java.util.ArrayList;
|
|||||||
import java.util.HashMap;
|
import java.util.HashMap;
|
||||||
import java.util.Map;
|
import java.util.Map;
|
||||||
|
|
||||||
|
import cn.jpush.android.api.JPushInterface;
|
||||||
import entity.RegisterUser;
|
import entity.RegisterUser;
|
||||||
import my_loader.Loader;
|
import my_loader.Loader;
|
||||||
import my_loader.Resultcode;
|
import my_loader.Resultcode;
|
||||||
@@ -157,6 +158,7 @@ public class LoginActivity extends BaseActivity<ActivityLoginBinding> implements
|
|||||||
LinkedTreeMap adta = (LinkedTreeMap) resultcode.data;
|
LinkedTreeMap adta = (LinkedTreeMap) resultcode.data;
|
||||||
String s = gs.toJson(adta);
|
String s = gs.toJson(adta);
|
||||||
RegisterUser user = gs.fromJson(s, RegisterUser.class);//把JSON字符串转为对象
|
RegisterUser user = gs.fromJson(s, RegisterUser.class);//把JSON字符串转为对象
|
||||||
|
JPushInterface.setAlias(getApplicationContext(),0,user.getUserid());
|
||||||
Config.getInstance(LoginActivity.this).putUser(user);
|
Config.getInstance(LoginActivity.this).putUser(user);
|
||||||
Config.getInstance(LoginActivity.this).put("username", mDataBinding.phone.getText().toString().trim());
|
Config.getInstance(LoginActivity.this).put("username", mDataBinding.phone.getText().toString().trim());
|
||||||
|
|
||||||
|
|||||||
@@ -42,13 +42,16 @@ import com.scwang.smartrefresh.layout.api.RefreshLayout;
|
|||||||
import com.scwang.smartrefresh.layout.listener.OnRefreshLoadMoreListener;
|
import com.scwang.smartrefresh.layout.listener.OnRefreshLoadMoreListener;
|
||||||
import com.selectpicker.OptionsPopupWindow;
|
import com.selectpicker.OptionsPopupWindow;
|
||||||
import com.sl.house_property.databinding.FragmentMainBinding;
|
import com.sl.house_property.databinding.FragmentMainBinding;
|
||||||
|
|
||||||
import com.sl.house_property.databinding.ItemCommentBinding;
|
import com.sl.house_property.databinding.ItemCommentBinding;
|
||||||
import com.sl.house_property.databinding.ItemDiscoveryBinding;
|
import com.sl.house_property.databinding.ItemDiscoveryBinding;
|
||||||
import com.sl.house_property.db.CommentBeanData;
|
import com.sl.house_property.db.CommentBeanData;
|
||||||
import com.sl.house_property.db.dao.CommentDao;
|
import com.sl.house_property.db.dao.CommentDao;
|
||||||
|
import com.sl.house_property.discovery.DeleteCommentDialog;
|
||||||
import com.sl.house_property.discovery.GoodsInfoDialog;
|
import com.sl.house_property.discovery.GoodsInfoDialog;
|
||||||
import com.sl.house_property.discovery.HistoryRecordActivity;
|
import com.sl.house_property.discovery.HistoryRecordActivity;
|
||||||
import com.sl.house_property.discovery.HistoryRecordActivitytwo;
|
import com.sl.house_property.discovery.HistoryRecordActivitytwo;
|
||||||
|
import com.sl.house_property.discovery.SelectDialog;
|
||||||
import com.sl.house_property.okgonet.HttpConstants;
|
import com.sl.house_property.okgonet.HttpConstants;
|
||||||
import com.sl.house_property.okgonet.Observer;
|
import com.sl.house_property.okgonet.Observer;
|
||||||
import com.sl.house_property.order.SettleActivity;
|
import com.sl.house_property.order.SettleActivity;
|
||||||
@@ -788,12 +791,15 @@ public class MainFragment extends BaseFragment<FragmentMainBinding> implements V
|
|||||||
commentDialog.dismiss();
|
commentDialog.dismiss();
|
||||||
like(discoveryListEntity.getGoods_id(), position);
|
like(discoveryListEntity.getGoods_id(), position);
|
||||||
} else if (type == 3) {
|
} else if (type == 3) {
|
||||||
|
itemIndex = -1;
|
||||||
mDataBinding.llComment.setVisibility(View.VISIBLE);
|
mDataBinding.llComment.setVisibility(View.VISIBLE);
|
||||||
mDataBinding.etComment.requestFocus();
|
mDataBinding.etComment.requestFocus();
|
||||||
mDataBinding.etComment.setHint("评论");
|
mDataBinding.etComment.setHint("评论");
|
||||||
MainTabActivity activity = (MainTabActivity) getActivity();
|
if (getActivity() instanceof MainTabActivity) {
|
||||||
|
MainTabActivity activity = (MainTabActivity) getActivity();
|
||||||
|
activity.visibilyBottom(View.GONE);
|
||||||
|
}
|
||||||
KeyboardUtil.showSoftInput(getContext());
|
KeyboardUtil.showSoftInput(getContext());
|
||||||
activity.visibilyBottom(View.GONE);
|
|
||||||
commentPosition = position;
|
commentPosition = position;
|
||||||
commentDialog.dismiss();
|
commentDialog.dismiss();
|
||||||
mDataBinding.etComment.setText("");
|
mDataBinding.etComment.setText("");
|
||||||
@@ -805,6 +811,23 @@ public class MainFragment extends BaseFragment<FragmentMainBinding> implements V
|
|||||||
mDataBinding.scrollViewExtend.smoothScrollBy(0, mBottomY - y);
|
mDataBinding.scrollViewExtend.smoothScrollBy(0, mBottomY - y);
|
||||||
}
|
}
|
||||||
}, 300);
|
}, 300);
|
||||||
|
// mDataBinding.llComment.setVisibility(View.VISIBLE);
|
||||||
|
// mDataBinding.etComment.requestFocus();
|
||||||
|
// mDataBinding.etComment.setHint("评论");
|
||||||
|
// MainTabActivity activity = (MainTabActivity) getActivity();
|
||||||
|
// KeyboardUtil.showSoftInput(getContext());
|
||||||
|
// activity.visibilyBottom(View.GONE);
|
||||||
|
// commentPosition = position;
|
||||||
|
// commentDialog.dismiss();
|
||||||
|
// mDataBinding.etComment.setText("");
|
||||||
|
// homeGridAdapterItemBinding.ivComment.postDelayed(new Runnable() {
|
||||||
|
// @Override
|
||||||
|
// public void run() {
|
||||||
|
// int y = getCoordinateY(mDataBinding.llComment) - 20;
|
||||||
|
// //评论时滑动到对应item底部和输入框顶部对齐
|
||||||
|
// mDataBinding.scrollViewExtend.smoothScrollBy(0, mBottomY - y);
|
||||||
|
// }
|
||||||
|
// }, 300);
|
||||||
|
|
||||||
|
|
||||||
} else if (type == 4) {
|
} else if (type == 4) {
|
||||||
@@ -857,21 +880,72 @@ public class MainFragment extends BaseFragment<FragmentMainBinding> implements V
|
|||||||
final ArrayList<DiscoveryListEntity.Dis_content> dis_content = discoveryListEntity.getDis_content();
|
final ArrayList<DiscoveryListEntity.Dis_content> dis_content = discoveryListEntity.getDis_content();
|
||||||
baseRecycleViewAdapter.setOnBindViewHolder(new BaseRecycleViewAdapter.BindView() {
|
baseRecycleViewAdapter.setOnBindViewHolder(new BaseRecycleViewAdapter.BindView() {
|
||||||
@Override
|
@Override
|
||||||
public void onBindViewHolder(Object b, int position) {
|
public void onBindViewHolder(Object b, final int itemPosition) {
|
||||||
ItemCommentBinding itemCommentBinding = (ItemCommentBinding) b;
|
ItemCommentBinding itemCommentBinding = (ItemCommentBinding) b;
|
||||||
itemCommentBinding.tvName.setText(dis_content.get(position).getNickname() + ": ");
|
if (dis_content.get(itemPosition).getReply().isEmpty()) {
|
||||||
itemCommentBinding.tvInfo.setText(dis_content.get(position).getContents());
|
|
||||||
if (dis_content.get(position).getReply().isEmpty()) {
|
|
||||||
itemCommentBinding.llHf.setVisibility(View.GONE);
|
itemCommentBinding.llHf.setVisibility(View.GONE);
|
||||||
|
itemCommentBinding.ll.setVisibility(View.VISIBLE);
|
||||||
|
itemCommentBinding.tvName.setText(dis_content.get(itemPosition).getNickname() + ": ");
|
||||||
|
itemCommentBinding.tvInfo.setText(dis_content.get(itemPosition).getContents());
|
||||||
} else {
|
} else {
|
||||||
|
|
||||||
|
itemCommentBinding.ll.setVisibility(View.GONE);
|
||||||
itemCommentBinding.llHf.setVisibility(View.VISIBLE);
|
itemCommentBinding.llHf.setVisibility(View.VISIBLE);
|
||||||
itemCommentBinding.tvName2.setText(discoveryListEntity.getNickname());
|
itemCommentBinding.tvName2.setText(dis_content.get(itemPosition).getNickname());
|
||||||
itemCommentBinding.tvInfo2.setText("回复");
|
itemCommentBinding.tvInfo2.setText("回复");
|
||||||
itemCommentBinding.tvName3.setText(dis_content.get(position).getNickname() + ":");
|
itemCommentBinding.tvName3.setText(dis_content.get(itemPosition).getReply() + ":");
|
||||||
itemCommentBinding.tvInfo3.setText(dis_content.get(position).getReply());
|
itemCommentBinding.tvInfo3.setText(dis_content.get(itemPosition).getContents());
|
||||||
|
|
||||||
}
|
}
|
||||||
|
itemCommentBinding.llItem.setOnClickListener(new View.OnClickListener() {
|
||||||
|
@Override
|
||||||
|
public void onClick(View v) {
|
||||||
|
|
||||||
|
final RegisterUser registerUser = Config.getInstance(getContext()).getUser();
|
||||||
|
if (registerUser == null) {
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
final int mBottomY = getCoordinateY(homeGridAdapterItemBinding.ivComment) + homeGridAdapterItemBinding.ivComment.getHeight();
|
||||||
|
if (dis_content.get(itemPosition).getFrom_id()==null
|
||||||
|
||registerUser.getUserid().equals(dis_content.get(itemPosition).getFrom_id())){
|
||||||
|
mDataBinding.llComment.setVisibility(View.GONE);
|
||||||
|
DeleteCommentDialog deleteCommentDialog = new DeleteCommentDialog(getContext());
|
||||||
|
deleteCommentDialog.setOnSelectListener(new SelectDialog.OnSelectListener() {
|
||||||
|
@Override
|
||||||
|
public void select(int type) {
|
||||||
|
deleteComment(dis_content.get(itemPosition).getDis_id(),registerUser.getUserid(),position,itemPosition);
|
||||||
|
}
|
||||||
|
});
|
||||||
|
new XPopup.Builder(getContext()).asCustom(deleteCommentDialog).show();
|
||||||
|
}else {
|
||||||
|
itemIndex =itemPosition;
|
||||||
|
|
||||||
|
mDataBinding.llComment.setVisibility(View.VISIBLE);
|
||||||
|
mDataBinding.etComment.requestFocus();
|
||||||
|
mDataBinding.etComment.setHint("回复 " + dis_content.get(itemPosition).getNickname());
|
||||||
|
if (getActivity() instanceof MainTabActivity) {
|
||||||
|
MainTabActivity activity = (MainTabActivity) getActivity();
|
||||||
|
activity.visibilyBottom(View.GONE);
|
||||||
|
}
|
||||||
|
KeyboardUtil.showSoftInput(getContext());
|
||||||
|
commentPosition = position;
|
||||||
|
// commentDialog.dismiss();
|
||||||
|
mDataBinding.etComment.setText("");
|
||||||
|
homeGridAdapterItemBinding.ivComment.postDelayed(new Runnable() {
|
||||||
|
@Override
|
||||||
|
public void run() {
|
||||||
|
int y = getCoordinateY(mDataBinding.llComment) - 20;
|
||||||
|
//评论时滑动到对应item底部和输入框顶部对齐
|
||||||
|
mDataBinding.scrollViewExtend.smoothScrollBy(0, mBottomY - y);
|
||||||
|
}
|
||||||
|
}, 300);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
}
|
||||||
|
});
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
baseRecycleViewAdapter.setData(dis_content);
|
baseRecycleViewAdapter.setData(dis_content);
|
||||||
@@ -943,12 +1017,13 @@ public class MainFragment extends BaseFragment<FragmentMainBinding> implements V
|
|||||||
mDataBinding.llComment.setVisibility(View.GONE);
|
mDataBinding.llComment.setVisibility(View.GONE);
|
||||||
activity.visibilyBottom(View.VISIBLE);
|
activity.visibilyBottom(View.VISIBLE);
|
||||||
Log.e("xxx", discoveryListEntities.get(commentPosition).getGoods_id());
|
Log.e("xxx", discoveryListEntities.get(commentPosition).getGoods_id());
|
||||||
comment(discoveryListEntities.get(commentPosition).getGoods_id(), commentPosition, "", mDataBinding.etComment.getText().toString());
|
comment(discoveryListEntities.get(commentPosition).getGoods_id(), commentPosition, itemIndex, mDataBinding.etComment.getText().toString());
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
private int commentPosition = -1;
|
private int commentPosition = -1;
|
||||||
|
private int itemIndex = -1;
|
||||||
@Override
|
@Override
|
||||||
public boolean onTouch(MotionEvent ev) {
|
public boolean onTouch(MotionEvent ev) {
|
||||||
switch (ev.getAction()) {
|
switch (ev.getAction()) {
|
||||||
@@ -1042,7 +1117,7 @@ public class MainFragment extends BaseFragment<FragmentMainBinding> implements V
|
|||||||
baseActivity.addSubscription(subscription);
|
baseActivity.addSubscription(subscription);
|
||||||
}
|
}
|
||||||
|
|
||||||
private void comment(String goodsId, final int position, String reply_id, final String content) {
|
private void comment(String goodsId, final int position, final int itemIndex, final String content) {
|
||||||
final RegisterUser user =
|
final RegisterUser user =
|
||||||
Config.getInstance(getContext()).getUser();
|
Config.getInstance(getContext()).getUser();
|
||||||
Map<String, String> map = new HashMap<>();
|
Map<String, String> map = new HashMap<>();
|
||||||
@@ -1054,8 +1129,13 @@ public class MainFragment extends BaseFragment<FragmentMainBinding> implements V
|
|||||||
map.put("app", "Goods");
|
map.put("app", "Goods");
|
||||||
map.put("class", "DisGoods");
|
map.put("class", "DisGoods");
|
||||||
map.put("goods_id", goodsId);
|
map.put("goods_id", goodsId);
|
||||||
if (!TextUtils.isEmpty(reply_id)) {
|
if (itemIndex!=-1){
|
||||||
map.put("reply_id", reply_id);
|
DiscoveryListEntity discoveryListEntity = discoveryListEntities.get(position);
|
||||||
|
ArrayList<DiscoveryListEntity.Dis_content> dis_content1 = discoveryListEntity.getDis_content();
|
||||||
|
String from_id = dis_content1.get(itemIndex).getFrom_id();
|
||||||
|
if (!TextUtils.isEmpty(from_id)) {
|
||||||
|
map.put("reply_id", from_id);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
map.put("contents", content);
|
map.put("contents", content);
|
||||||
@@ -1076,18 +1156,21 @@ public class MainFragment extends BaseFragment<FragmentMainBinding> implements V
|
|||||||
baseActivity.setToast(1, resultcode.msg);
|
baseActivity.setToast(1, resultcode.msg);
|
||||||
}
|
}
|
||||||
if (resultcode.status == 0) {
|
if (resultcode.status == 0) {
|
||||||
|
|
||||||
String nickname = user.getNickname();
|
String nickname = user.getNickname();
|
||||||
BaseRecycleViewAdapter adapter = (BaseRecycleViewAdapter) mDataBinding.recyView.getAdapter();
|
BaseRecycleViewAdapter adapter = (BaseRecycleViewAdapter) mDataBinding.recyView.getAdapter();
|
||||||
DiscoveryListEntity.Dis_content dis_content = new DiscoveryListEntity.Dis_content();
|
DiscoveryListEntity.Dis_content dis_content = new DiscoveryListEntity.Dis_content();
|
||||||
dis_content.setContents(content);
|
dis_content.setContents(content);
|
||||||
dis_content.setNickname(nickname);
|
dis_content.setNickname(nickname);
|
||||||
dis_content.setReply("");
|
|
||||||
DiscoveryListEntity discoveryListEntity = discoveryListEntities.get(position);
|
DiscoveryListEntity discoveryListEntity = discoveryListEntities.get(position);
|
||||||
ArrayList<DiscoveryListEntity.Dis_content> dis_content1 = discoveryListEntity.getDis_content();
|
ArrayList<DiscoveryListEntity.Dis_content> dis_content1 = discoveryListEntity.getDis_content();
|
||||||
|
if (itemIndex!=-1){
|
||||||
|
dis_content.setReply(dis_content1.get(itemIndex).getNickname());
|
||||||
|
}
|
||||||
dis_content1.add(dis_content);
|
dis_content1.add(dis_content);
|
||||||
|
|
||||||
discoveryListEntity.setDis_content(dis_content1);
|
discoveryListEntity.setDis_content(dis_content1);
|
||||||
adapter.upDateOne(position,discoveryListEntity);
|
adapter.upDateOne(position, discoveryListEntity);
|
||||||
// BaseRecycleViewAdapter adapter = (BaseRecycleViewAdapter) mDataBinding.recyView.getAdapter();
|
// BaseRecycleViewAdapter adapter = (BaseRecycleViewAdapter) mDataBinding.recyView.getAdapter();
|
||||||
// if (discoveryListEntities.get(position).getDis_content().isEmpty()) {
|
// if (discoveryListEntities.get(position).getDis_content().isEmpty()) {
|
||||||
// DiscoveryListEntity.Dis_content dis_content = new DiscoveryListEntity.Dis_content();
|
// DiscoveryListEntity.Dis_content dis_content = new DiscoveryListEntity.Dis_content();
|
||||||
@@ -1513,4 +1596,36 @@ public class MainFragment extends BaseFragment<FragmentMainBinding> implements V
|
|||||||
});
|
});
|
||||||
|
|
||||||
}
|
}
|
||||||
|
private void deleteComment(String dis_id, String userid, final int superPosition, final int itemPosition) {
|
||||||
|
Map<String, String> map = new HashMap<>();
|
||||||
|
|
||||||
|
progressDialog.show();
|
||||||
|
map.put("app", "Goods");
|
||||||
|
|
||||||
|
map.put("class", "DelDis");
|
||||||
|
map.put("sign", Md5.md5("Goods" + "DelDis" + Md5.secret));
|
||||||
|
map.put("dis_id", dis_id);
|
||||||
|
map.put("userid", userid);
|
||||||
|
mGankLoader.getMovie(ApiConfig.BASE_URL, map).subscribe(new Action1<Resultcode>() {
|
||||||
|
@Override
|
||||||
|
public void call(Resultcode resultcode) {
|
||||||
|
progressDialog.dismiss();
|
||||||
|
if (!(resultcode.status == 0)) {
|
||||||
|
Toast.makeText(getContext(), resultcode.msg, Toast.LENGTH_SHORT).show();
|
||||||
|
} else {
|
||||||
|
BaseRecycleViewAdapter adapter = (BaseRecycleViewAdapter) mDataBinding.recyView.getAdapter();
|
||||||
|
DiscoveryListEntity discoveryListEntity = discoveryListEntities.get(superPosition);
|
||||||
|
ArrayList<DiscoveryListEntity.Dis_content> dis_content1 = discoveryListEntity.getDis_content();
|
||||||
|
dis_content1.remove(itemPosition);
|
||||||
|
discoveryListEntity.setDis_content(dis_content1);
|
||||||
|
adapter.upDateOne(superPosition, discoveryListEntity);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}, new Action1<Throwable>() {
|
||||||
|
@Override
|
||||||
|
public void call(Throwable throwable) {
|
||||||
|
Toast.makeText(getContext(), getString(R.string.getdatafailure), Toast.LENGTH_SHORT).show();
|
||||||
|
}
|
||||||
|
});
|
||||||
|
}
|
||||||
}
|
}
|
||||||
@@ -98,7 +98,7 @@ public class MainTabActivity extends BaseActivity<ActivityMainTabBinding>
|
|||||||
@Override
|
@Override
|
||||||
public boolean dispatchTouchEvent(MotionEvent ev) {
|
public boolean dispatchTouchEvent(MotionEvent ev) {
|
||||||
for (MyOnTouchListener listener : onTouchListeners) {
|
for (MyOnTouchListener listener : onTouchListeners) {
|
||||||
// listener.onTouch(ev);
|
//listener.onTouch(ev);
|
||||||
}
|
}
|
||||||
return super.dispatchTouchEvent(ev);
|
return super.dispatchTouchEvent(ev);
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -31,6 +31,7 @@ import javax.net.ssl.HostnameVerifier;
|
|||||||
import javax.net.ssl.SSLSession;
|
import javax.net.ssl.SSLSession;
|
||||||
import javax.net.ssl.X509TrustManager;
|
import javax.net.ssl.X509TrustManager;
|
||||||
|
|
||||||
|
import cn.jpush.android.api.JPushInterface;
|
||||||
import okhttp3.OkHttpClient;
|
import okhttp3.OkHttpClient;
|
||||||
import tools.CrashHandler;
|
import tools.CrashHandler;
|
||||||
import fm.jiecao.jcvideoplayer_lib.JCVideoPlayerStandard;
|
import fm.jiecao.jcvideoplayer_lib.JCVideoPlayerStandard;
|
||||||
@@ -84,6 +85,8 @@ public class MyApplication extends Application{
|
|||||||
super.onCreate();
|
super.onCreate();
|
||||||
instance = this;
|
instance = this;
|
||||||
initOkGo();
|
initOkGo();
|
||||||
|
JPushInterface.init(this);
|
||||||
|
JPushInterface.setDebugMode(true);
|
||||||
//
|
//
|
||||||
// CrashHandler crashHandler = CrashHandler.getInstance();
|
// CrashHandler crashHandler = CrashHandler.getInstance();
|
||||||
// crashHandler.init(this);
|
// crashHandler.init(this);
|
||||||
|
|||||||
@@ -9,6 +9,7 @@ import android.widget.Toast;
|
|||||||
|
|
||||||
import com.sl.house_property.databinding.ActivitySettingBinding;
|
import com.sl.house_property.databinding.ActivitySettingBinding;
|
||||||
|
|
||||||
|
import cn.jpush.android.api.JPushInterface;
|
||||||
import tools.APKVersionCodeUtils;
|
import tools.APKVersionCodeUtils;
|
||||||
import tools.Config;
|
import tools.Config;
|
||||||
import utils.CacheDataManager;
|
import utils.CacheDataManager;
|
||||||
@@ -92,6 +93,7 @@ public class SettingActivity extends BaseActivity<ActivitySettingBinding> implem
|
|||||||
|
|
||||||
break;
|
break;
|
||||||
case R.id.loginout:
|
case R.id.loginout:
|
||||||
|
JPushInterface.deleteAlias(getApplicationContext(),0);
|
||||||
Config.getInstance(SettingActivity.this).DeleteUser();
|
Config.getInstance(SettingActivity.this).DeleteUser();
|
||||||
MyApplication.getApp().existActivitys();
|
MyApplication.getApp().existActivitys();
|
||||||
intent = new Intent(SettingActivity.this, LoginActivity.class);
|
intent = new Intent(SettingActivity.this, LoginActivity.class);
|
||||||
|
|||||||
@@ -0,0 +1,50 @@
|
|||||||
|
package com.sl.house_property.discovery;
|
||||||
|
|
||||||
|
import android.content.Context;
|
||||||
|
import android.support.annotation.NonNull;
|
||||||
|
import android.view.View;
|
||||||
|
import android.widget.TextView;
|
||||||
|
|
||||||
|
import com.lxj.xpopup.core.BottomPopupView;
|
||||||
|
import com.sl.house_property.R;
|
||||||
|
|
||||||
|
import org.jetbrains.annotations.NotNull;
|
||||||
|
|
||||||
|
public class DeleteCommentDialog extends BottomPopupView {
|
||||||
|
private SelectDialog.OnSelectListener listener;
|
||||||
|
private TextView tv1;
|
||||||
|
|
||||||
|
public DeleteCommentDialog(@NonNull @NotNull Context context) {
|
||||||
|
super(context);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
@Override
|
||||||
|
protected int getImplLayoutId() {
|
||||||
|
return R.layout.dialog_select_delete;
|
||||||
|
|
||||||
|
}
|
||||||
|
public void setOnSelectListener(SelectDialog.OnSelectListener listener) {
|
||||||
|
this.listener = listener;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
protected void onCreate() {
|
||||||
|
super.onCreate();
|
||||||
|
findViewById(R.id.btn_delete).setOnClickListener(new OnClickListener() {
|
||||||
|
@Override
|
||||||
|
public void onClick(View v) {
|
||||||
|
if (listener!=null){
|
||||||
|
listener.select(1);
|
||||||
|
dismiss();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
});
|
||||||
|
findViewById(R.id.btn_cancel).setOnClickListener(new OnClickListener() {
|
||||||
|
@Override
|
||||||
|
public void onClick(View v) {
|
||||||
|
dismiss();
|
||||||
|
}
|
||||||
|
});
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -15,6 +15,7 @@ import android.view.LayoutInflater;
|
|||||||
import android.view.MotionEvent;
|
import android.view.MotionEvent;
|
||||||
import android.view.View;
|
import android.view.View;
|
||||||
import android.view.ViewTreeObserver;
|
import android.view.ViewTreeObserver;
|
||||||
|
import android.widget.Toast;
|
||||||
|
|
||||||
import com.bumptech.glide.Glide;
|
import com.bumptech.glide.Glide;
|
||||||
import com.bumptech.glide.request.RequestOptions;
|
import com.bumptech.glide.request.RequestOptions;
|
||||||
@@ -385,26 +386,47 @@ public class DiscoveryFragment extends BaseFragment<FragmentDiscoveryBinding> im
|
|||||||
commentDialog.dismiss();
|
commentDialog.dismiss();
|
||||||
like(discoveryListEntity.getGoods_id(), position);
|
like(discoveryListEntity.getGoods_id(), position);
|
||||||
} else if (type == 3) {
|
} else if (type == 3) {
|
||||||
|
itemIndex = -1;
|
||||||
mDataBinding.llComment.setVisibility(View.VISIBLE);
|
mDataBinding.llComment.setVisibility(View.VISIBLE);
|
||||||
mDataBinding.etComment.requestFocus();
|
mDataBinding.etComment.requestFocus();
|
||||||
mDataBinding.etComment.setHint("评论");
|
mDataBinding.etComment.setHint("评论");
|
||||||
MainTabActivity activity = (MainTabActivity) getActivity();
|
if (getActivity() instanceof MainTabActivity) {
|
||||||
|
MainTabActivity activity = (MainTabActivity) getActivity();
|
||||||
|
activity.visibilyBottom(View.GONE);
|
||||||
|
}
|
||||||
KeyboardUtil.showSoftInput(getContext());
|
KeyboardUtil.showSoftInput(getContext());
|
||||||
activity.visibilyBottom(View.GONE);
|
commentPosition = position;
|
||||||
|
|
||||||
commentDialog.dismiss();
|
commentDialog.dismiss();
|
||||||
mDataBinding.etComment.setText("");
|
mDataBinding.etComment.setText("");
|
||||||
commentPosition = position;
|
|
||||||
homeGridAdapterItemBinding.ivComment.postDelayed(new Runnable() {
|
homeGridAdapterItemBinding.ivComment.postDelayed(new Runnable() {
|
||||||
@Override
|
@Override
|
||||||
public void run() {
|
public void run() {
|
||||||
int y = getCoordinateY(mDataBinding.llComment) - 20;
|
int y = getCoordinateY(mDataBinding.llComment) - 20;
|
||||||
//评论时滑动到对应item底部和输入框顶部对齐
|
//评论时滑动到对应item底部和输入框顶部对齐
|
||||||
mDataBinding.sv.smoothScrollBy(0, mBottomY - y);
|
mDataBinding.sv.smoothScrollBy(0, mBottomY - y);
|
||||||
|
|
||||||
}
|
}
|
||||||
}, 300);
|
}, 300);
|
||||||
|
|
||||||
|
// mDataBinding.llComment.setVisibility(View.VISIBLE);
|
||||||
|
// mDataBinding.etComment.requestFocus();
|
||||||
|
// mDataBinding.etComment.setHint("评论");
|
||||||
|
// MainTabActivity activity = (MainTabActivity) getActivity();
|
||||||
|
// KeyboardUtil.showSoftInput(getContext());
|
||||||
|
// activity.visibilyBottom(View.GONE);
|
||||||
|
//
|
||||||
|
// commentDialog.dismiss();
|
||||||
|
// mDataBinding.etComment.setText("");
|
||||||
|
// commentPosition = position;
|
||||||
|
// homeGridAdapterItemBinding.ivComment.postDelayed(new Runnable() {
|
||||||
|
// @Override
|
||||||
|
// public void run() {
|
||||||
|
// int y = getCoordinateY(mDataBinding.llComment) - 20;
|
||||||
|
// //评论时滑动到对应item底部和输入框顶部对齐
|
||||||
|
// mDataBinding.sv.smoothScrollBy(0, mBottomY - y);
|
||||||
|
//
|
||||||
|
// }
|
||||||
|
// }, 300);
|
||||||
|
|
||||||
|
|
||||||
} else if (type == 4) {
|
} else if (type == 4) {
|
||||||
// addCart(discoveryListEntity.getGoods_id(),discoveryListEntity.)
|
// addCart(discoveryListEntity.getGoods_id(),discoveryListEntity.)
|
||||||
@@ -431,13 +453,13 @@ public class DiscoveryFragment extends BaseFragment<FragmentDiscoveryBinding> im
|
|||||||
homeGridAdapterItemBinding.tvLike.setVisibility(View.VISIBLE);
|
homeGridAdapterItemBinding.tvLike.setVisibility(View.VISIBLE);
|
||||||
StringBuilder likeString = new StringBuilder();
|
StringBuilder likeString = new StringBuilder();
|
||||||
for (int i = 0; i < discoveryListEntity.getLike().size(); i++) {
|
for (int i = 0; i < discoveryListEntity.getLike().size(); i++) {
|
||||||
// if (i != 0 && i != discoveryListEntity.getLike().size() - 1) {
|
// if (i != 0 && i != discoveryListEntity.getLike().size() - 1) {
|
||||||
// likeString.append(",");
|
// likeString.append(",");
|
||||||
// }
|
// }
|
||||||
|
|
||||||
if (i != 0) {
|
if (i != 0) {
|
||||||
likeString.append(",");
|
likeString.append(",");
|
||||||
}
|
}
|
||||||
likeString.append(discoveryListEntity.getLike().get(i).getNickname());
|
likeString.append(discoveryListEntity.getLike().get(i).getNickname());
|
||||||
|
|
||||||
}
|
}
|
||||||
@@ -459,21 +481,84 @@ public class DiscoveryFragment extends BaseFragment<FragmentDiscoveryBinding> im
|
|||||||
final ArrayList<DiscoveryListEntity.Dis_content> dis_content = discoveryListEntity.getDis_content();
|
final ArrayList<DiscoveryListEntity.Dis_content> dis_content = discoveryListEntity.getDis_content();
|
||||||
baseRecycleViewAdapter.setOnBindViewHolder(new BaseRecycleViewAdapter.BindView() {
|
baseRecycleViewAdapter.setOnBindViewHolder(new BaseRecycleViewAdapter.BindView() {
|
||||||
@Override
|
@Override
|
||||||
public void onBindViewHolder(Object b, int position) {
|
public void onBindViewHolder(Object b, final int itemPosition) {
|
||||||
ItemCommentBinding itemCommentBinding = (ItemCommentBinding) b;
|
ItemCommentBinding itemCommentBinding = (ItemCommentBinding) b;
|
||||||
itemCommentBinding.tvName.setText(dis_content.get(position).getNickname() + ": ");
|
// itemCommentBinding.tvName.setText(dis_content.get(position).getNickname() + ": ");
|
||||||
itemCommentBinding.tvInfo.setText(dis_content.get(position).getContents());
|
// itemCommentBinding.tvInfo.setText(dis_content.get(position).getContents());
|
||||||
if (dis_content.get(position).getReply().isEmpty()) {
|
// if (dis_content.get(position).getReply().isEmpty()) {
|
||||||
|
// itemCommentBinding.llHf.setVisibility(View.GONE);
|
||||||
|
//
|
||||||
|
// } else {
|
||||||
|
// itemCommentBinding.llHf.setVisibility(View.VISIBLE);
|
||||||
|
// itemCommentBinding.tvName2.setText(discoveryListEntity.getNickname());
|
||||||
|
// itemCommentBinding.tvInfo2.setText("回复");
|
||||||
|
// itemCommentBinding.tvName3.setText(dis_content.get(position).getNickname() + ":");
|
||||||
|
// itemCommentBinding.tvInfo3.setText(dis_content.get(position).getReply());
|
||||||
|
//
|
||||||
|
// }
|
||||||
|
if (dis_content.get(itemPosition).getReply().isEmpty()) {
|
||||||
itemCommentBinding.llHf.setVisibility(View.GONE);
|
itemCommentBinding.llHf.setVisibility(View.GONE);
|
||||||
|
itemCommentBinding.ll.setVisibility(View.VISIBLE);
|
||||||
|
itemCommentBinding.tvName.setText(dis_content.get(itemPosition).getNickname() + ": ");
|
||||||
|
itemCommentBinding.tvInfo.setText(dis_content.get(itemPosition).getContents());
|
||||||
} else {
|
} else {
|
||||||
|
itemCommentBinding.ll.setVisibility(View.GONE);
|
||||||
itemCommentBinding.llHf.setVisibility(View.VISIBLE);
|
itemCommentBinding.llHf.setVisibility(View.VISIBLE);
|
||||||
itemCommentBinding.tvName2.setText(discoveryListEntity.getNickname());
|
itemCommentBinding.tvName2.setText(dis_content.get(itemPosition).getNickname());
|
||||||
itemCommentBinding.tvInfo2.setText("回复");
|
itemCommentBinding.tvInfo2.setText("回复");
|
||||||
itemCommentBinding.tvName3.setText(dis_content.get(position).getNickname() + ":");
|
itemCommentBinding.tvName3.setText(dis_content.get(itemPosition).getReply() + ":");
|
||||||
itemCommentBinding.tvInfo3.setText(dis_content.get(position).getReply());
|
itemCommentBinding.tvInfo3.setText(dis_content.get(itemPosition).getContents());
|
||||||
|
|
||||||
}
|
}
|
||||||
|
itemCommentBinding.llItem.setOnClickListener(new View.OnClickListener() {
|
||||||
|
@Override
|
||||||
|
public void onClick(View v) {
|
||||||
|
final RegisterUser registerUser = Config.getInstance(getContext()).getUser();
|
||||||
|
if (registerUser == null) {
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
final int mBottomY = getCoordinateY(homeGridAdapterItemBinding.ivComment) + homeGridAdapterItemBinding.ivComment.getHeight();
|
||||||
|
|
||||||
|
if (dis_content.get(itemPosition).getFrom_id() == null
|
||||||
|
|| registerUser.getUserid().equals(dis_content.get(itemPosition).getFrom_id())) {
|
||||||
|
mDataBinding.llComment.setVisibility(View.GONE);
|
||||||
|
DeleteCommentDialog deleteCommentDialog = new DeleteCommentDialog(getContext());
|
||||||
|
deleteCommentDialog.setOnSelectListener(new SelectDialog.OnSelectListener() {
|
||||||
|
@Override
|
||||||
|
public void select(int type) {
|
||||||
|
deleteComment(dis_content.get(itemPosition).getDis_id(), registerUser.getUserid(), position, itemPosition);
|
||||||
|
}
|
||||||
|
});
|
||||||
|
new XPopup.Builder(getContext()).asCustom(deleteCommentDialog).show();
|
||||||
|
} else {
|
||||||
|
itemIndex = itemPosition;
|
||||||
|
|
||||||
|
mDataBinding.llComment.setVisibility(View.VISIBLE);
|
||||||
|
mDataBinding.etComment.requestFocus();
|
||||||
|
mDataBinding.etComment.setHint("回复 " + dis_content.get(itemPosition).getNickname());
|
||||||
|
if (getActivity() instanceof MainTabActivity) {
|
||||||
|
MainTabActivity activity = (MainTabActivity) getActivity();
|
||||||
|
activity.visibilyBottom(View.GONE);
|
||||||
|
}
|
||||||
|
KeyboardUtil.showSoftInput(getContext());
|
||||||
|
commentPosition = position;
|
||||||
|
// commentDialog.dismiss();
|
||||||
|
mDataBinding.etComment.setText("");
|
||||||
|
homeGridAdapterItemBinding.ivComment.postDelayed(new Runnable() {
|
||||||
|
@Override
|
||||||
|
public void run() {
|
||||||
|
int y = getCoordinateY(mDataBinding.llComment) - 20;
|
||||||
|
//评论时滑动到对应item底部和输入框顶部对齐
|
||||||
|
mDataBinding.sv.smoothScrollBy(0, mBottomY - y);
|
||||||
|
}
|
||||||
|
}, 300);
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
}
|
||||||
|
});
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
baseRecycleViewAdapter.setData(dis_content);
|
baseRecycleViewAdapter.setData(dis_content);
|
||||||
@@ -544,7 +629,7 @@ public class DiscoveryFragment extends BaseFragment<FragmentDiscoveryBinding> im
|
|||||||
mDataBinding.llComment.setVisibility(View.GONE);
|
mDataBinding.llComment.setVisibility(View.GONE);
|
||||||
activity.visibilyBottom(View.VISIBLE);
|
activity.visibilyBottom(View.VISIBLE);
|
||||||
Log.e("xxx", discoveryListEntities.get(commentPosition).getGoods_id());
|
Log.e("xxx", discoveryListEntities.get(commentPosition).getGoods_id());
|
||||||
comment(discoveryListEntities.get(commentPosition).getGoods_id(), commentPosition, "", mDataBinding.etComment.getText().toString());
|
comment(discoveryListEntities.get(commentPosition).getGoods_id(), commentPosition, itemIndex, mDataBinding.etComment.getText().toString());
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
@@ -575,25 +660,25 @@ public class DiscoveryFragment extends BaseFragment<FragmentDiscoveryBinding> im
|
|||||||
if (resultcode.status == 0) {
|
if (resultcode.status == 0) {
|
||||||
// intRecycleView();
|
// intRecycleView();
|
||||||
Gson gs = new Gson();
|
Gson gs = new Gson();
|
||||||
LinkedTreeMap adta = (LinkedTreeMap) resultcode.data;
|
LinkedTreeMap adta = (LinkedTreeMap) resultcode.data;
|
||||||
String s = gs.toJson(adta);
|
String s = gs.toJson(adta);
|
||||||
|
|
||||||
// String s = new GetJsonDataUtil().getJson(getActivity(), "controlStatus.json");//获取assets目录下的json文件数据
|
// String s = new GetJsonDataUtil().getJson(getActivity(), "controlStatus.json");//获取assets目录下的json文件数据
|
||||||
try {
|
try {
|
||||||
DiscoverEntity discoverEntity = gs.fromJson(s, DiscoverEntity.class);
|
DiscoverEntity discoverEntity = gs.fromJson(s, DiscoverEntity.class);
|
||||||
// JSONObject jsonObject = new JSONObject(s);
|
// JSONObject jsonObject = new JSONObject(s);
|
||||||
// org.json.JSONArray array = jsonObject.getJSONArray("info");
|
// org.json.JSONArray array = jsonObject.getJSONArray("info");
|
||||||
// Type type = new TypeToken<ArrayList<DiscoveryListEntity>>() {
|
// Type type = new TypeToken<ArrayList<DiscoveryListEntity>>() {
|
||||||
// }.getType();
|
// }.getType();
|
||||||
if (page == 1) {
|
if (page == 1) {
|
||||||
String fengmian = discoverEntity.getFengmian();
|
String fengmian = discoverEntity.getFengmian();
|
||||||
String avatar = discoverEntity.getAvatar();
|
String avatar = discoverEntity.getAvatar();
|
||||||
if (!TextUtils.isEmpty(fengmian)){
|
if (!TextUtils.isEmpty(fengmian)) {
|
||||||
Picasso.with(getActivity()).load(fengmian)
|
Picasso.with(getActivity()).load(fengmian)
|
||||||
.placeholder(R.mipmap.icon_default_rectangle)
|
.placeholder(R.mipmap.icon_default_rectangle)
|
||||||
.into(target);
|
.into(target);
|
||||||
}
|
}
|
||||||
if (!TextUtils.isEmpty(avatar)){
|
if (!TextUtils.isEmpty(avatar)) {
|
||||||
Picasso.with(getActivity()).load(avatar)
|
Picasso.with(getActivity()).load(avatar)
|
||||||
.placeholder(R.mipmap.icon_default_rectangle)
|
.placeholder(R.mipmap.icon_default_rectangle)
|
||||||
.transform(new PicassoRoundTransform())
|
.transform(new PicassoRoundTransform())
|
||||||
@@ -607,7 +692,7 @@ public class DiscoveryFragment extends BaseFragment<FragmentDiscoveryBinding> im
|
|||||||
baseRecycleViewAdapter.setData(discoveryListEntities);
|
baseRecycleViewAdapter.setData(discoveryListEntities);
|
||||||
page++;
|
page++;
|
||||||
} else {
|
} else {
|
||||||
// ArrayList<DiscoveryListEntity> o = new Gson().fromJson(array.toString(), type);
|
// ArrayList<DiscoveryListEntity> o = new Gson().fromJson(array.toString(), type);
|
||||||
List<DiscoveryListEntity> info = discoverEntity.getInfo();
|
List<DiscoveryListEntity> info = discoverEntity.getInfo();
|
||||||
discoveryListEntities.addAll(info);
|
discoveryListEntities.addAll(info);
|
||||||
|
|
||||||
@@ -777,7 +862,9 @@ public class DiscoveryFragment extends BaseFragment<FragmentDiscoveryBinding> im
|
|||||||
baseActivity.addSubscription(subscription);
|
baseActivity.addSubscription(subscription);
|
||||||
}
|
}
|
||||||
|
|
||||||
private void comment(String goodsId, final int position, String reply_id, final String content) {
|
private int itemIndex = -1;
|
||||||
|
|
||||||
|
private void comment(String goodsId, final int position, final int itemIndex, final String content) {
|
||||||
final RegisterUser user =
|
final RegisterUser user =
|
||||||
Config.getInstance(getContext()).getUser();
|
Config.getInstance(getContext()).getUser();
|
||||||
Map<String, String> map = new HashMap<>();
|
Map<String, String> map = new HashMap<>();
|
||||||
@@ -790,8 +877,13 @@ public class DiscoveryFragment extends BaseFragment<FragmentDiscoveryBinding> im
|
|||||||
map.put("app", "Goods");
|
map.put("app", "Goods");
|
||||||
map.put("class", "DisGoods");
|
map.put("class", "DisGoods");
|
||||||
map.put("goods_id", goodsId);
|
map.put("goods_id", goodsId);
|
||||||
if (!TextUtils.isEmpty(reply_id)) {
|
if (itemIndex != -1) {
|
||||||
map.put("reply_id", reply_id);
|
DiscoveryListEntity discoveryListEntity = discoveryListEntities.get(position);
|
||||||
|
ArrayList<DiscoveryListEntity.Dis_content> dis_content1 = discoveryListEntity.getDis_content();
|
||||||
|
String from_id = dis_content1.get(itemIndex).getFrom_id();
|
||||||
|
if (!TextUtils.isEmpty(from_id)) {
|
||||||
|
map.put("reply_id", from_id);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
map.put("contents", content);
|
map.put("contents", content);
|
||||||
@@ -817,13 +909,27 @@ public class DiscoveryFragment extends BaseFragment<FragmentDiscoveryBinding> im
|
|||||||
DiscoveryListEntity.Dis_content dis_content = new DiscoveryListEntity.Dis_content();
|
DiscoveryListEntity.Dis_content dis_content = new DiscoveryListEntity.Dis_content();
|
||||||
dis_content.setContents(content);
|
dis_content.setContents(content);
|
||||||
dis_content.setNickname(nickname);
|
dis_content.setNickname(nickname);
|
||||||
dis_content.setReply("");
|
|
||||||
DiscoveryListEntity discoveryListEntity = discoveryListEntities.get(position);
|
DiscoveryListEntity discoveryListEntity = discoveryListEntities.get(position);
|
||||||
ArrayList<DiscoveryListEntity.Dis_content> dis_content1 = discoveryListEntity.getDis_content();
|
ArrayList<DiscoveryListEntity.Dis_content> dis_content1 = discoveryListEntity.getDis_content();
|
||||||
|
if (itemIndex != -1) {
|
||||||
|
dis_content.setReply(dis_content1.get(itemIndex).getNickname());
|
||||||
|
}
|
||||||
dis_content1.add(dis_content);
|
dis_content1.add(dis_content);
|
||||||
|
|
||||||
discoveryListEntity.setDis_content(dis_content1);
|
discoveryListEntity.setDis_content(dis_content1);
|
||||||
adapter.upDateOne(position, discoveryListEntity);
|
adapter.upDateOne(position, discoveryListEntity);
|
||||||
|
// String nickname = user.getNickname();
|
||||||
|
// BaseRecycleViewAdapter adapter = (BaseRecycleViewAdapter) mDataBinding.recyView.getAdapter();
|
||||||
|
// DiscoveryListEntity.Dis_content dis_content = new DiscoveryListEntity.Dis_content();
|
||||||
|
// dis_content.setContents(content);
|
||||||
|
// dis_content.setNickname(nickname);
|
||||||
|
// dis_content.setReply("");
|
||||||
|
// DiscoveryListEntity discoveryListEntity = discoveryListEntities.get(position);
|
||||||
|
// ArrayList<DiscoveryListEntity.Dis_content> dis_content1 = discoveryListEntity.getDis_content();
|
||||||
|
// dis_content1.add(dis_content);
|
||||||
|
//
|
||||||
|
// discoveryListEntity.setDis_content(dis_content1);
|
||||||
|
// adapter.upDateOne(position, discoveryListEntity);
|
||||||
// BaseRecycleViewAdapter adapter = (BaseRecycleViewAdapter) mDataBinding.recyView.getAdapter();
|
// BaseRecycleViewAdapter adapter = (BaseRecycleViewAdapter) mDataBinding.recyView.getAdapter();
|
||||||
// if (discoveryListEntities.get(position).getDis_content().isEmpty()) {
|
// if (discoveryListEntities.get(position).getDis_content().isEmpty()) {
|
||||||
// DiscoveryListEntity.Dis_content dis_content = new DiscoveryListEntity.Dis_content();
|
// DiscoveryListEntity.Dis_content dis_content = new DiscoveryListEntity.Dis_content();
|
||||||
@@ -860,4 +966,36 @@ public class DiscoveryFragment extends BaseFragment<FragmentDiscoveryBinding> im
|
|||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
private void deleteComment(String dis_id, String userid, final int superPosition, final int itemPosition) {
|
||||||
|
Map<String, String> map = new HashMap<>();
|
||||||
|
|
||||||
|
progressDialog.show();
|
||||||
|
map.put("app", "Goods");
|
||||||
|
|
||||||
|
map.put("class", "DelDis");
|
||||||
|
map.put("sign", Md5.md5("Goods" + "DelDis" + Md5.secret));
|
||||||
|
map.put("dis_id", dis_id);
|
||||||
|
map.put("userid", userid);
|
||||||
|
mGankLoader.getMovie(ApiConfig.BASE_URL, map).subscribe(new Action1<Resultcode>() {
|
||||||
|
@Override
|
||||||
|
public void call(Resultcode resultcode) {
|
||||||
|
progressDialog.dismiss();
|
||||||
|
if (!(resultcode.status == 0)) {
|
||||||
|
Toast.makeText(getContext(), resultcode.msg, Toast.LENGTH_SHORT).show();
|
||||||
|
} else {
|
||||||
|
BaseRecycleViewAdapter adapter = (BaseRecycleViewAdapter) mDataBinding.recyView.getAdapter();
|
||||||
|
DiscoveryListEntity discoveryListEntity = discoveryListEntities.get(superPosition);
|
||||||
|
ArrayList<DiscoveryListEntity.Dis_content> dis_content1 = discoveryListEntity.getDis_content();
|
||||||
|
dis_content1.remove(itemPosition);
|
||||||
|
discoveryListEntity.setDis_content(dis_content1);
|
||||||
|
adapter.upDateOne(superPosition, discoveryListEntity);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}, new Action1<Throwable>() {
|
||||||
|
@Override
|
||||||
|
public void call(Throwable throwable) {
|
||||||
|
Toast.makeText(getContext(), getString(R.string.getdatafailure), Toast.LENGTH_SHORT).show();
|
||||||
|
}
|
||||||
|
});
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -84,14 +84,14 @@ public class HistoryRecordFragment extends BaseFragment<FragmentHistoryRecordBin
|
|||||||
return R.layout.fragment_history_record;
|
return R.layout.fragment_history_record;
|
||||||
}
|
}
|
||||||
|
|
||||||
public static HistoryRecordFragment newInstance(int param1, String param2, int i, int num,String wy_id) {
|
public static HistoryRecordFragment newInstance(int param1, String param2, int i, int num, String wy_id) {
|
||||||
HistoryRecordFragment fragment = new HistoryRecordFragment();
|
HistoryRecordFragment fragment = new HistoryRecordFragment();
|
||||||
Bundle args = new Bundle();
|
Bundle args = new Bundle();
|
||||||
args.putInt("param1", param1);
|
args.putInt("param1", param1);
|
||||||
args.putString("param2", param2);
|
args.putString("param2", param2);
|
||||||
args.putInt("num",i);
|
args.putInt("num", i);
|
||||||
args.putInt("dataType",num);
|
args.putInt("dataType", num);
|
||||||
args.putString("wy_id",wy_id);
|
args.putString("wy_id", wy_id);
|
||||||
fragment.setArguments(args);
|
fragment.setArguments(args);
|
||||||
return fragment;
|
return fragment;
|
||||||
}
|
}
|
||||||
@@ -113,9 +113,9 @@ public class HistoryRecordFragment extends BaseFragment<FragmentHistoryRecordBin
|
|||||||
activity.registerMyOnTouchListener(this);
|
activity.registerMyOnTouchListener(this);
|
||||||
} else if (getActivity() instanceof HistoryRecordActivity) {
|
} else if (getActivity() instanceof HistoryRecordActivity) {
|
||||||
((HistoryRecordActivity) getActivity()).registerMyOnTouchListener(this);
|
((HistoryRecordActivity) getActivity()).registerMyOnTouchListener(this);
|
||||||
}else if (getActivity() instanceof LikeActivity){
|
} else if (getActivity() instanceof LikeActivity) {
|
||||||
((LikeActivity) getActivity()).registerMyOnTouchListener(this);
|
((LikeActivity) getActivity()).registerMyOnTouchListener(this);
|
||||||
}else if (getActivity() instanceof HistoryRecordActivitytwo){
|
} else if (getActivity() instanceof HistoryRecordActivitytwo) {
|
||||||
((HistoryRecordActivitytwo) getActivity()).registerMyOnTouchListener(this);
|
((HistoryRecordActivitytwo) getActivity()).registerMyOnTouchListener(this);
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -160,6 +160,7 @@ public class HistoryRecordFragment extends BaseFragment<FragmentHistoryRecordBin
|
|||||||
MainTabActivity activity = (MainTabActivity) getActivity();
|
MainTabActivity activity = (MainTabActivity) getActivity();
|
||||||
activity.visibilyBottom(View.VISIBLE);
|
activity.visibilyBottom(View.VISIBLE);
|
||||||
}
|
}
|
||||||
|
|
||||||
mDataBinding.llComment.setVisibility(View.GONE);
|
mDataBinding.llComment.setVisibility(View.GONE);
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
@@ -207,8 +208,23 @@ public class HistoryRecordFragment extends BaseFragment<FragmentHistoryRecordBin
|
|||||||
|
|
||||||
} else if (View.GONE == visibility) {
|
} else if (View.GONE == visibility) {
|
||||||
//隐藏键盘
|
//隐藏键盘
|
||||||
MainTabActivity activity = (MainTabActivity) getActivity();
|
|
||||||
activity.visibilyBottom(View.VISIBLE);
|
// if (getActivity() instanceof MainTabActivity) {
|
||||||
|
// final MainTabActivity activity = (MainTabActivity) getActivity();
|
||||||
|
// activity.registerMyOnTouchListener(this);
|
||||||
|
// } else if (getActivity() instanceof HistoryRecordActivity) {
|
||||||
|
// ((HistoryRecordActivity) getActivity()).registerMyOnTouchListener(this);
|
||||||
|
// } else if (getActivity() instanceof LikeActivity) {
|
||||||
|
// ((LikeActivity) getActivity()).registerMyOnTouchListener(this);
|
||||||
|
// } else if (getActivity() instanceof HistoryRecordActivitytwo) {
|
||||||
|
// ((HistoryRecordActivitytwo) getActivity()).registerMyOnTouchListener(this);
|
||||||
|
// }
|
||||||
|
|
||||||
|
if (getActivity() instanceof MainTabActivity) {
|
||||||
|
MainTabActivity activity = (MainTabActivity) getActivity();
|
||||||
|
activity.visibilyBottom(View.VISIBLE);
|
||||||
|
|
||||||
|
}
|
||||||
CommonUtils.hideSoftInput(mDataBinding.etComment.getContext(), mDataBinding.etComment);
|
CommonUtils.hideSoftInput(mDataBinding.etComment.getContext(), mDataBinding.etComment);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -256,7 +272,7 @@ public class HistoryRecordFragment extends BaseFragment<FragmentHistoryRecordBin
|
|||||||
homeGridAdapterItemBinding.tvLike.setVisibility(View.VISIBLE);
|
homeGridAdapterItemBinding.tvLike.setVisibility(View.VISIBLE);
|
||||||
StringBuilder likeString = new StringBuilder();
|
StringBuilder likeString = new StringBuilder();
|
||||||
for (int i = 0; i < discoveryListEntity.getLike().size(); i++) {
|
for (int i = 0; i < discoveryListEntity.getLike().size(); i++) {
|
||||||
if (i != 0 ) {
|
if (i != 0) {
|
||||||
likeString.append(",");
|
likeString.append(",");
|
||||||
}
|
}
|
||||||
likeString.append(discoveryListEntity.getLike().get(i).getNickname());
|
likeString.append(discoveryListEntity.getLike().get(i).getNickname());
|
||||||
@@ -280,23 +296,75 @@ public class HistoryRecordFragment extends BaseFragment<FragmentHistoryRecordBin
|
|||||||
final ArrayList<DiscoveryListEntity.Dis_content> dis_content = discoveryListEntity.getDis_content();
|
final ArrayList<DiscoveryListEntity.Dis_content> dis_content = discoveryListEntity.getDis_content();
|
||||||
baseRecycleViewAdapter.setOnBindViewHolder(new BaseRecycleViewAdapter.BindView() {
|
baseRecycleViewAdapter.setOnBindViewHolder(new BaseRecycleViewAdapter.BindView() {
|
||||||
@Override
|
@Override
|
||||||
public void onBindViewHolder(Object b, int position) {
|
public void onBindViewHolder(Object b, final int itemPosition) {
|
||||||
ItemCommentBinding itemCommentBinding = (ItemCommentBinding) b;
|
ItemCommentBinding itemCommentBinding = (ItemCommentBinding) b;
|
||||||
itemCommentBinding.tvName.setText(dis_content.get(position).getNickname() + ": ");
|
|
||||||
itemCommentBinding.tvInfo.setText(dis_content.get(position).getContents());
|
|
||||||
if (dis_content.get(position).getReply().isEmpty()) {
|
|
||||||
itemCommentBinding.llHf.setVisibility(View.GONE);
|
|
||||||
|
|
||||||
|
if (dis_content.get(itemPosition).getReply().isEmpty()) {
|
||||||
|
itemCommentBinding.llHf.setVisibility(View.GONE);
|
||||||
|
itemCommentBinding.ll.setVisibility(View.VISIBLE);
|
||||||
|
itemCommentBinding.tvName.setText(dis_content.get(itemPosition).getNickname() + ": ");
|
||||||
|
itemCommentBinding.tvInfo.setText(dis_content.get(itemPosition).getContents());
|
||||||
} else {
|
} else {
|
||||||
|
itemCommentBinding.ll.setVisibility(View.GONE);
|
||||||
itemCommentBinding.llHf.setVisibility(View.VISIBLE);
|
itemCommentBinding.llHf.setVisibility(View.VISIBLE);
|
||||||
itemCommentBinding.tvName2.setText(discoveryListEntity.getNickname());
|
itemCommentBinding.tvName2.setText(dis_content.get(itemPosition).getNickname());
|
||||||
itemCommentBinding.tvInfo2.setText("回复");
|
itemCommentBinding.tvInfo2.setText("回复");
|
||||||
itemCommentBinding.tvName3.setText(dis_content.get(position).getNickname() + ":");
|
itemCommentBinding.tvName3.setText(dis_content.get(itemPosition).getReply() + ":");
|
||||||
itemCommentBinding.tvInfo3.setText(dis_content.get(position).getReply());
|
itemCommentBinding.tvInfo3.setText(dis_content.get(itemPosition).getContents());
|
||||||
|
|
||||||
}
|
}
|
||||||
|
itemCommentBinding.llItem.setOnClickListener(new View.OnClickListener() {
|
||||||
|
@Override
|
||||||
|
public void onClick(View v) {
|
||||||
|
final RegisterUser registerUser = Config.getInstance(getContext()).getUser();
|
||||||
|
if (registerUser == null) {
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
final int mBottomY = getCoordinateY(homeGridAdapterItemBinding.ivComment) + homeGridAdapterItemBinding.ivComment.getHeight();
|
||||||
|
if (dis_content.get(itemPosition).getFrom_id()==null
|
||||||
|
||registerUser.getUserid().equals(dis_content.get(itemPosition).getFrom_id())){
|
||||||
|
mDataBinding.llComment.setVisibility(View.GONE);
|
||||||
|
DeleteCommentDialog deleteCommentDialog = new DeleteCommentDialog(getContext());
|
||||||
|
deleteCommentDialog.setOnSelectListener(new SelectDialog.OnSelectListener() {
|
||||||
|
@Override
|
||||||
|
public void select(int type) {
|
||||||
|
deleteComment(dis_content.get(itemPosition).getDis_id(),registerUser.getUserid(),position,itemPosition);
|
||||||
|
}
|
||||||
|
});
|
||||||
|
new XPopup.Builder(getContext()).asCustom(deleteCommentDialog).show();
|
||||||
|
}else {
|
||||||
|
itemIndex = itemPosition;
|
||||||
|
|
||||||
|
mDataBinding.llComment.setVisibility(View.VISIBLE);
|
||||||
|
mDataBinding.etComment.requestFocus();
|
||||||
|
mDataBinding.etComment.setHint("回复 " + dis_content.get(itemPosition).getNickname());
|
||||||
|
if (getActivity() instanceof MainTabActivity) {
|
||||||
|
MainTabActivity activity = (MainTabActivity) getActivity();
|
||||||
|
activity.visibilyBottom(View.GONE);
|
||||||
|
}
|
||||||
|
KeyboardUtil.showSoftInput(getContext());
|
||||||
|
commentPosition = position;
|
||||||
|
// commentDialog.dismiss();
|
||||||
|
mDataBinding.etComment.setText("");
|
||||||
|
homeGridAdapterItemBinding.ivComment.postDelayed(new Runnable() {
|
||||||
|
@Override
|
||||||
|
public void run() {
|
||||||
|
int y = getCoordinateY(mDataBinding.llComment) - 20;
|
||||||
|
//评论时滑动到对应item底部和输入框顶部对齐
|
||||||
|
mDataBinding.sv.smoothScrollBy(0, mBottomY - y);
|
||||||
|
}
|
||||||
|
}, 300);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
}
|
||||||
|
});
|
||||||
|
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
baseRecycleViewAdapter.setData(dis_content);
|
baseRecycleViewAdapter.setData(dis_content);
|
||||||
|
|
||||||
}
|
}
|
||||||
@@ -331,7 +399,7 @@ public class HistoryRecordFragment extends BaseFragment<FragmentHistoryRecordBin
|
|||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
} else if (!TextUtils.isEmpty(discoveryListEntity.getThumb())){
|
} else if (!TextUtils.isEmpty(discoveryListEntity.getThumb())) {
|
||||||
ImageInfo imageInfo = new ImageInfo();
|
ImageInfo imageInfo = new ImageInfo();
|
||||||
imageInfo.setType(1);
|
imageInfo.setType(1);
|
||||||
imageInfo.setBigImageUrl(discoveryListEntity.getThumb());
|
imageInfo.setBigImageUrl(discoveryListEntity.getThumb());
|
||||||
@@ -360,6 +428,7 @@ public class HistoryRecordFragment extends BaseFragment<FragmentHistoryRecordBin
|
|||||||
commentDialog.dismiss();
|
commentDialog.dismiss();
|
||||||
like(discoveryListEntity.getGoods_id(), position);
|
like(discoveryListEntity.getGoods_id(), position);
|
||||||
} else if (type == 3) {
|
} else if (type == 3) {
|
||||||
|
itemIndex = -1;
|
||||||
mDataBinding.llComment.setVisibility(View.VISIBLE);
|
mDataBinding.llComment.setVisibility(View.VISIBLE);
|
||||||
mDataBinding.etComment.requestFocus();
|
mDataBinding.etComment.requestFocus();
|
||||||
mDataBinding.etComment.setHint("评论");
|
mDataBinding.etComment.setHint("评论");
|
||||||
@@ -412,22 +481,22 @@ public class HistoryRecordFragment extends BaseFragment<FragmentHistoryRecordBin
|
|||||||
CommonUtils.hideSoftInput(getContext(), mDataBinding.etComment);
|
CommonUtils.hideSoftInput(getContext(), mDataBinding.etComment);
|
||||||
mDataBinding.llComment.setVisibility(View.GONE);
|
mDataBinding.llComment.setVisibility(View.GONE);
|
||||||
activity.visibilyBottom(View.VISIBLE);
|
activity.visibilyBottom(View.VISIBLE);
|
||||||
comment(discoveryListEntities.get(commentPosition).getGoods_id(), commentPosition, "", mDataBinding.etComment.getText().toString());
|
comment(discoveryListEntities.get(commentPosition).getGoods_id(), commentPosition, itemIndex, mDataBinding.etComment.getText().toString());
|
||||||
|
|
||||||
} else if (getActivity() instanceof HistoryRecordActivity) {
|
} else if (getActivity() instanceof HistoryRecordActivity) {
|
||||||
CommonUtils.hideSoftInput(getContext(), mDataBinding.etComment);
|
CommonUtils.hideSoftInput(getContext(), mDataBinding.etComment);
|
||||||
mDataBinding.llComment.setVisibility(View.GONE);
|
mDataBinding.llComment.setVisibility(View.GONE);
|
||||||
comment(discoveryListEntities.get(commentPosition).getGoods_id(), commentPosition, "", mDataBinding.etComment.getText().toString());
|
comment(discoveryListEntities.get(commentPosition).getGoods_id(), commentPosition, itemIndex, mDataBinding.etComment.getText().toString());
|
||||||
|
|
||||||
}else if (getActivity() instanceof LikeActivity){
|
} else if (getActivity() instanceof LikeActivity) {
|
||||||
CommonUtils.hideSoftInput(getContext(), mDataBinding.etComment);
|
CommonUtils.hideSoftInput(getContext(), mDataBinding.etComment);
|
||||||
mDataBinding.llComment.setVisibility(View.GONE);
|
mDataBinding.llComment.setVisibility(View.GONE);
|
||||||
comment(discoveryListEntities.get(commentPosition).getGoods_id(), commentPosition, "", mDataBinding.etComment.getText().toString());
|
comment(discoveryListEntities.get(commentPosition).getGoods_id(), commentPosition, itemIndex, mDataBinding.etComment.getText().toString());
|
||||||
|
|
||||||
}else if (getActivity() instanceof HistoryRecordActivitytwo){
|
} else if (getActivity() instanceof HistoryRecordActivitytwo) {
|
||||||
CommonUtils.hideSoftInput(getContext(), mDataBinding.etComment);
|
CommonUtils.hideSoftInput(getContext(), mDataBinding.etComment);
|
||||||
mDataBinding.llComment.setVisibility(View.GONE);
|
mDataBinding.llComment.setVisibility(View.GONE);
|
||||||
comment(discoveryListEntities.get(commentPosition).getGoods_id(), commentPosition, "", mDataBinding.etComment.getText().toString());
|
comment(discoveryListEntities.get(commentPosition).getGoods_id(), commentPosition, itemIndex, mDataBinding.etComment.getText().toString());
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -436,8 +505,9 @@ public class HistoryRecordFragment extends BaseFragment<FragmentHistoryRecordBin
|
|||||||
}
|
}
|
||||||
|
|
||||||
private int commentPosition = -1;
|
private int commentPosition = -1;
|
||||||
|
private int itemIndex = -1;
|
||||||
|
|
||||||
private void comment(String goodsId, final int position, String reply_id, final String content) {
|
private void comment(String goodsId, final int position, final int itemIndex, final String content) {
|
||||||
final RegisterUser user =
|
final RegisterUser user =
|
||||||
Config.getInstance(getContext()).getUser();
|
Config.getInstance(getContext()).getUser();
|
||||||
Map<String, String> map = new HashMap<>();
|
Map<String, String> map = new HashMap<>();
|
||||||
@@ -449,10 +519,16 @@ public class HistoryRecordFragment extends BaseFragment<FragmentHistoryRecordBin
|
|||||||
map.put("app", "Goods");
|
map.put("app", "Goods");
|
||||||
map.put("class", "DisGoods");
|
map.put("class", "DisGoods");
|
||||||
map.put("goods_id", goodsId);
|
map.put("goods_id", goodsId);
|
||||||
if (!TextUtils.isEmpty(reply_id)) {
|
if (itemIndex != -1) {
|
||||||
map.put("reply_id", reply_id);
|
DiscoveryListEntity discoveryListEntity = discoveryListEntities.get(position);
|
||||||
|
ArrayList<DiscoveryListEntity.Dis_content> dis_content1 = discoveryListEntity.getDis_content();
|
||||||
|
String from_id = dis_content1.get(itemIndex).getFrom_id();
|
||||||
|
if (!TextUtils.isEmpty(from_id)) {
|
||||||
|
map.put("reply_id", from_id);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
map.put("contents", content);
|
map.put("contents", content);
|
||||||
map.put("sign", Md5.md5("Goods" + "DisGoods" + Md5.secret));
|
map.put("sign", Md5.md5("Goods" + "DisGoods" + Md5.secret));
|
||||||
progressDialog.setMessage("提交中");
|
progressDialog.setMessage("提交中");
|
||||||
@@ -477,11 +553,13 @@ public class HistoryRecordFragment extends BaseFragment<FragmentHistoryRecordBin
|
|||||||
DiscoveryListEntity.Dis_content dis_content = new DiscoveryListEntity.Dis_content();
|
DiscoveryListEntity.Dis_content dis_content = new DiscoveryListEntity.Dis_content();
|
||||||
dis_content.setContents(content);
|
dis_content.setContents(content);
|
||||||
dis_content.setNickname(nickname);
|
dis_content.setNickname(nickname);
|
||||||
dis_content.setReply("");
|
|
||||||
DiscoveryListEntity discoveryListEntity = discoveryListEntities.get(position);
|
DiscoveryListEntity discoveryListEntity = discoveryListEntities.get(position);
|
||||||
ArrayList<DiscoveryListEntity.Dis_content> dis_content1 = discoveryListEntity.getDis_content();
|
ArrayList<DiscoveryListEntity.Dis_content> dis_content1 = discoveryListEntity.getDis_content();
|
||||||
|
if (itemIndex != -1) {
|
||||||
|
dis_content.setReply(dis_content1.get(itemIndex).getNickname());
|
||||||
|
}
|
||||||
dis_content1.add(dis_content);
|
dis_content1.add(dis_content);
|
||||||
|
|
||||||
discoveryListEntity.setDis_content(dis_content1);
|
discoveryListEntity.setDis_content(dis_content1);
|
||||||
adapter.upDateOne(position, discoveryListEntity);
|
adapter.upDateOne(position, discoveryListEntity);
|
||||||
}
|
}
|
||||||
@@ -645,10 +723,10 @@ public class HistoryRecordFragment extends BaseFragment<FragmentHistoryRecordBin
|
|||||||
if (resultcode.status == 0) {
|
if (resultcode.status == 0) {
|
||||||
BaseRecycleViewAdapter adapter = (BaseRecycleViewAdapter) mDataBinding.recyView.getAdapter();
|
BaseRecycleViewAdapter adapter = (BaseRecycleViewAdapter) mDataBinding.recyView.getAdapter();
|
||||||
if (discoveryListEntities.get(position).getIs_like() == 1) {
|
if (discoveryListEntities.get(position).getIs_like() == 1) {
|
||||||
if (getArguments().getInt("dataType")==3){
|
if (getArguments().getInt("dataType") == 3) {
|
||||||
discoveryListEntities.remove(position);
|
discoveryListEntities.remove(position);
|
||||||
adapter.notifyDataSetChanged();
|
adapter.notifyDataSetChanged();
|
||||||
}else {
|
} else {
|
||||||
discoveryListEntities.get(position).setIs_like(0);
|
discoveryListEntities.get(position).setIs_like(0);
|
||||||
ArrayList<DiscoveryListEntity.Like> like = discoveryListEntities.get(position).getLike();
|
ArrayList<DiscoveryListEntity.Like> like = discoveryListEntities.get(position).getLike();
|
||||||
for (int i = 0; i < like.size(); i++) {
|
for (int i = 0; i < like.size(); i++) {
|
||||||
@@ -704,17 +782,17 @@ public class HistoryRecordFragment extends BaseFragment<FragmentHistoryRecordBin
|
|||||||
|
|
||||||
map.put("type", type + "");
|
map.put("type", type + "");
|
||||||
map.put("app", "Goods");
|
map.put("app", "Goods");
|
||||||
if (getArguments().getInt("dataType")==1){
|
if (getArguments().getInt("dataType") == 1) {
|
||||||
// String wy_id=(String) SPUtils.getSp(getActivity(), DoConfig.MY_HOUST_WYID,"");
|
// String wy_id=(String) SPUtils.getSp(getActivity(), DoConfig.MY_HOUST_WYID,"");
|
||||||
Log.e("物业id",wy_id);
|
Log.e("物业id", wy_id);
|
||||||
map.put("userid", wy_id);
|
map.put("userid", wy_id);
|
||||||
map.put("class", "WyGoodsLists");
|
map.put("class", "WyGoodsLists");
|
||||||
map.put("sign", Md5.md5("Goods" + "WyGoodsLists" + Md5.secret));
|
map.put("sign", Md5.md5("Goods" + "WyGoodsLists" + Md5.secret));
|
||||||
} else if (getArguments().getInt("dataType")==3) {
|
} else if (getArguments().getInt("dataType") == 3) {
|
||||||
map.put("userid", userId);
|
map.put("userid", userId);
|
||||||
map.put("class", "UpGoodsLists");
|
map.put("class", "UpGoodsLists");
|
||||||
map.put("sign", Md5.md5("Goods" + "UpGoodsLists" + Md5.secret));
|
map.put("sign", Md5.md5("Goods" + "UpGoodsLists" + Md5.secret));
|
||||||
}else {
|
} else {
|
||||||
map.put("userid", userId);
|
map.put("userid", userId);
|
||||||
map.put("class", "MyGoodsLists");
|
map.put("class", "MyGoodsLists");
|
||||||
map.put("sign", Md5.md5("Goods" + "MyGoodsLists" + Md5.secret));
|
map.put("sign", Md5.md5("Goods" + "MyGoodsLists" + Md5.secret));
|
||||||
@@ -750,65 +828,64 @@ public class HistoryRecordFragment extends BaseFragment<FragmentHistoryRecordBin
|
|||||||
e.printStackTrace();
|
e.printStackTrace();
|
||||||
}
|
}
|
||||||
Type type = new TypeToken<ArrayList<DiscoveryListEntity>>() {
|
Type type = new TypeToken<ArrayList<DiscoveryListEntity>>() {
|
||||||
}.getType();
|
}.getType();
|
||||||
if (page == 1) {
|
if (page == 1) {
|
||||||
if (num == 1) {
|
if (num == 1) {
|
||||||
mDataBinding.rl1.setVisibility(View.GONE);
|
mDataBinding.rl1.setVisibility(View.GONE);
|
||||||
} else {
|
|
||||||
mDataBinding.rl1.setVisibility(View.VISIBLE);
|
|
||||||
String fengmian = null;
|
|
||||||
try {
|
|
||||||
fengmian = jsonObject.getString("fengmian");
|
|
||||||
} catch (JSONException e) {
|
|
||||||
e.printStackTrace();
|
|
||||||
}
|
|
||||||
String avatar = null;
|
|
||||||
try {
|
|
||||||
avatar = jsonObject.getString("avatar");
|
|
||||||
} catch (JSONException e) {
|
|
||||||
e.printStackTrace();
|
|
||||||
}
|
|
||||||
if (!TextUtils.isEmpty(fengmian)){
|
|
||||||
Picasso.with(context).load(fengmian)
|
|
||||||
.placeholder(R.mipmap.icon_default_rectangle)
|
|
||||||
.into(target);
|
|
||||||
}
|
|
||||||
if (!TextUtils.isEmpty(avatar)){
|
|
||||||
Picasso.with(context).load(avatar)
|
|
||||||
.placeholder(R.mipmap.icon_default_rectangle)
|
|
||||||
.transform(new PicassoRoundTransform())
|
|
||||||
.into(mDataBinding.head);
|
|
||||||
}
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|
||||||
ArrayList<DiscoveryListEntity> o = new Gson().fromJson(array.toString(), type);
|
|
||||||
discoveryListEntities.clear();
|
|
||||||
discoveryListEntities.addAll(o);
|
|
||||||
BaseRecycleViewAdapter baseRecycleViewAdapter = (BaseRecycleViewAdapter) mDataBinding.recyView.getAdapter();
|
|
||||||
baseRecycleViewAdapter.setData(discoveryListEntities);
|
|
||||||
page++;
|
|
||||||
} else {
|
} else {
|
||||||
ArrayList<DiscoveryListEntity> o = new Gson().fromJson(array.toString(), type);
|
mDataBinding.rl1.setVisibility(View.VISIBLE);
|
||||||
discoveryListEntities.addAll(o);
|
String fengmian = null;
|
||||||
|
try {
|
||||||
BaseRecycleViewAdapter baseRecycleViewAdapter = (BaseRecycleViewAdapter) mDataBinding.recyView.getAdapter();
|
fengmian = jsonObject.getString("fengmian");
|
||||||
baseRecycleViewAdapter.setData(discoveryListEntities);
|
} catch (JSONException e) {
|
||||||
Log.e("sizi", discoveryListEntities.size() + "");
|
e.printStackTrace();
|
||||||
// int count = jsonObject.getInt("count");
|
|
||||||
if (o.isEmpty()) {
|
|
||||||
mDataBinding.dw.finishLoadMoreWithNoMoreData();
|
|
||||||
} else {
|
|
||||||
|
|
||||||
page++;
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
String avatar = null;
|
||||||
|
try {
|
||||||
|
avatar = jsonObject.getString("avatar");
|
||||||
|
} catch (JSONException e) {
|
||||||
|
e.printStackTrace();
|
||||||
|
}
|
||||||
|
if (!TextUtils.isEmpty(fengmian)) {
|
||||||
|
Picasso.with(context).load(fengmian)
|
||||||
|
.placeholder(R.mipmap.icon_default_rectangle)
|
||||||
|
.into(target);
|
||||||
|
}
|
||||||
|
if (!TextUtils.isEmpty(avatar)) {
|
||||||
|
Picasso.with(context).load(avatar)
|
||||||
|
.placeholder(R.mipmap.icon_default_rectangle)
|
||||||
|
.transform(new PicassoRoundTransform())
|
||||||
|
.into(mDataBinding.head);
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
ArrayList<DiscoveryListEntity> o = new Gson().fromJson(array.toString(), type);
|
||||||
|
discoveryListEntities.clear();
|
||||||
|
discoveryListEntities.addAll(o);
|
||||||
|
BaseRecycleViewAdapter baseRecycleViewAdapter = (BaseRecycleViewAdapter) mDataBinding.recyView.getAdapter();
|
||||||
|
baseRecycleViewAdapter.setData(discoveryListEntities);
|
||||||
|
page++;
|
||||||
|
} else {
|
||||||
|
ArrayList<DiscoveryListEntity> o = new Gson().fromJson(array.toString(), type);
|
||||||
|
discoveryListEntities.addAll(o);
|
||||||
|
|
||||||
|
BaseRecycleViewAdapter baseRecycleViewAdapter = (BaseRecycleViewAdapter) mDataBinding.recyView.getAdapter();
|
||||||
|
baseRecycleViewAdapter.setData(discoveryListEntities);
|
||||||
|
Log.e("sizi", discoveryListEntities.size() + "");
|
||||||
|
// int count = jsonObject.getInt("count");
|
||||||
|
if (o.isEmpty()) {
|
||||||
|
mDataBinding.dw.finishLoadMoreWithNoMoreData();
|
||||||
|
} else {
|
||||||
|
|
||||||
|
page++;
|
||||||
|
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
}else {
|
} else {
|
||||||
Log.e("xxxxx","fffff");
|
Log.e("xxxxx", "fffff");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}, new Action1<Throwable>() {
|
}, new Action1<Throwable>() {
|
||||||
@@ -843,5 +920,37 @@ public class HistoryRecordFragment extends BaseFragment<FragmentHistoryRecordBin
|
|||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
|
private void deleteComment(String dis_id, String userid, final int superPosition, final int itemPosition) {
|
||||||
|
Map<String, String> map = new HashMap<>();
|
||||||
|
|
||||||
|
progressDialog.show();
|
||||||
|
map.put("app", "Goods");
|
||||||
|
|
||||||
|
map.put("class", "DelDis");
|
||||||
|
map.put("sign", Md5.md5("Goods" + "DelDis" + Md5.secret));
|
||||||
|
map.put("dis_id", dis_id);
|
||||||
|
map.put("userid", userid);
|
||||||
|
loader.getMovie(ApiConfig.BASE_URL, map).subscribe(new Action1<Resultcode>() {
|
||||||
|
@Override
|
||||||
|
public void call(Resultcode resultcode) {
|
||||||
|
progressDialog.dismiss();
|
||||||
|
if (!(resultcode.status == 0)) {
|
||||||
|
Toast.makeText(context, resultcode.msg, Toast.LENGTH_SHORT).show();
|
||||||
|
} else {
|
||||||
|
BaseRecycleViewAdapter adapter = (BaseRecycleViewAdapter) mDataBinding.recyView.getAdapter();
|
||||||
|
DiscoveryListEntity discoveryListEntity = discoveryListEntities.get(superPosition);
|
||||||
|
ArrayList<DiscoveryListEntity.Dis_content> dis_content1 = discoveryListEntity.getDis_content();
|
||||||
|
dis_content1.remove(itemPosition);
|
||||||
|
discoveryListEntity.setDis_content(dis_content1);
|
||||||
|
adapter.upDateOne(superPosition, discoveryListEntity);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}, new Action1<Throwable>() {
|
||||||
|
@Override
|
||||||
|
public void call(Throwable throwable) {
|
||||||
|
Toast.makeText(context, getString(R.string.getdatafailure), Toast.LENGTH_SHORT).show();
|
||||||
|
}
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|||||||
32
app/src/main/java/com/sl/house_property/push/MyReceiver.java
Normal file
32
app/src/main/java/com/sl/house_property/push/MyReceiver.java
Normal file
@@ -0,0 +1,32 @@
|
|||||||
|
package com.sl.house_property.push;
|
||||||
|
|
||||||
|
import android.content.Context;
|
||||||
|
import android.util.Log;
|
||||||
|
import android.widget.Toast;
|
||||||
|
|
||||||
|
|
||||||
|
import cn.jpush.android.api.CustomMessage;
|
||||||
|
import cn.jpush.android.api.NotificationMessage;
|
||||||
|
import cn.jpush.android.service.JPushMessageReceiver;
|
||||||
|
|
||||||
|
public class MyReceiver extends JPushMessageReceiver {
|
||||||
|
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void onRegister(Context context, String s) {
|
||||||
|
super.onRegister(context, s);
|
||||||
|
Log.e("xxxx", s);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void onMessage(Context context, CustomMessage customMessage) {
|
||||||
|
super.onMessage(context, customMessage);
|
||||||
|
Log.e("message", customMessage.toString());
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void onNotifyMessageArrived(Context context, NotificationMessage notificationMessage) {
|
||||||
|
super.onNotifyMessageArrived(context, notificationMessage);
|
||||||
|
Log.e("极光" , "收到了推送消息");
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -0,0 +1,7 @@
|
|||||||
|
package com.sl.house_property.push;
|
||||||
|
|
||||||
|
import cn.jpush.android.service.JCommonService;
|
||||||
|
|
||||||
|
public class XService extends JCommonService {
|
||||||
|
|
||||||
|
}
|
||||||
@@ -474,7 +474,6 @@ public class MyPropertyActivity extends BaseActivity<ActivityMyPropertyBinding>
|
|||||||
mDataBinding.myaddress.setOnClickListener(new View.OnClickListener() {
|
mDataBinding.myaddress.setOnClickListener(new View.OnClickListener() {
|
||||||
@Override
|
@Override
|
||||||
public void onClick(View view) {
|
public void onClick(View view) {
|
||||||
Log.e("dsfsdfdsfs",adding+"");
|
|
||||||
if (!adding) {
|
if (!adding) {
|
||||||
adding = true;
|
adding = true;
|
||||||
SimpleEntity simpleEntity = new SimpleEntity();
|
SimpleEntity simpleEntity = new SimpleEntity();
|
||||||
|
|||||||
@@ -113,13 +113,13 @@
|
|||||||
|
|
||||||
<RelativeLayout
|
<RelativeLayout
|
||||||
android:id="@+id/rlzhuce"
|
android:id="@+id/rlzhuce"
|
||||||
android:visibility="gone"
|
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:layout_marginLeft="20dip"
|
android:layout_marginLeft="20dip"
|
||||||
android:layout_marginRight="20dip"
|
android:layout_marginRight="20dip"
|
||||||
android:layout_marginTop="16dp"
|
android:layout_marginTop="16dp"
|
||||||
android:gravity="center"
|
android:gravity="center"
|
||||||
|
android:visibility="gone"
|
||||||
android:textColor="@color/white">
|
android:textColor="@color/white">
|
||||||
|
|
||||||
<TextView
|
<TextView
|
||||||
@@ -189,7 +189,7 @@
|
|||||||
android:id="@+id/agreewhitemegy"
|
android:id="@+id/agreewhitemegy"
|
||||||
android:button="@drawable/checkbox_style"
|
android:button="@drawable/checkbox_style"
|
||||||
android:layout_width="wrap_content"
|
android:layout_width="wrap_content"
|
||||||
android:checked="false"
|
android:checked="true"
|
||||||
android:layout_height="wrap_content" />
|
android:layout_height="wrap_content" />
|
||||||
<TextView
|
<TextView
|
||||||
android:layout_marginStart="10dp"
|
android:layout_marginStart="10dp"
|
||||||
|
|||||||
@@ -227,7 +227,7 @@
|
|||||||
android:id="@+id/agreewhitemeg"
|
android:id="@+id/agreewhitemeg"
|
||||||
android:button="@drawable/checkbox_style"
|
android:button="@drawable/checkbox_style"
|
||||||
android:layout_width="wrap_content"
|
android:layout_width="wrap_content"
|
||||||
android:checked="true"
|
android:checked="false"
|
||||||
android:layout_height="wrap_content" />
|
android:layout_height="wrap_content" />
|
||||||
<TextView
|
<TextView
|
||||||
android:layout_marginStart="10dp"
|
android:layout_marginStart="10dp"
|
||||||
@@ -255,7 +255,7 @@
|
|||||||
android:id="@+id/agreewhitemegy"
|
android:id="@+id/agreewhitemegy"
|
||||||
android:button="@drawable/checkbox_style"
|
android:button="@drawable/checkbox_style"
|
||||||
android:layout_width="wrap_content"
|
android:layout_width="wrap_content"
|
||||||
android:checked="true"
|
android:checked="false"
|
||||||
android:layout_height="wrap_content" />
|
android:layout_height="wrap_content" />
|
||||||
<TextView
|
<TextView
|
||||||
android:layout_marginStart="10dp"
|
android:layout_marginStart="10dp"
|
||||||
@@ -267,7 +267,7 @@
|
|||||||
android:onClick="yinagreementEvent"
|
android:onClick="yinagreementEvent"
|
||||||
android:layout_gravity="center_vertical"
|
android:layout_gravity="center_vertical"
|
||||||
android:gravity="center_vertical"
|
android:gravity="center_vertical"
|
||||||
android:text="@string/agreewhitemeg1"
|
android:text="@string/agreewhitemeg2"
|
||||||
android:textSize="16sp"/>
|
android:textSize="16sp"/>
|
||||||
|
|
||||||
</LinearLayout>
|
</LinearLayout>
|
||||||
|
|||||||
50
app/src/main/res/layout/dialog_select_delete.xml
Normal file
50
app/src/main/res/layout/dialog_select_delete.xml
Normal file
@@ -0,0 +1,50 @@
|
|||||||
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:orientation="vertical">
|
||||||
|
|
||||||
|
|
||||||
|
<Button
|
||||||
|
android:id="@+id/btn_edit"
|
||||||
|
style="?android:attr/borderlessButtonStyle"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="50dp"
|
||||||
|
android:background="@drawable/selector_bottom_dialog_btn"
|
||||||
|
android:paddingBottom="5dp"
|
||||||
|
android:text="删除我的评论"
|
||||||
|
android:textColor="@color/darkgray"
|
||||||
|
android:textAllCaps="false"
|
||||||
|
android:textSize="12sp" />
|
||||||
|
|
||||||
|
<View
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="0.5dip"
|
||||||
|
android:background="@color/LightGray" />
|
||||||
|
|
||||||
|
<Button
|
||||||
|
android:id="@+id/btn_delete"
|
||||||
|
style="?android:attr/borderlessButtonStyle"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="50dp"
|
||||||
|
android:background="@drawable/selector_bottom_dialog_btn"
|
||||||
|
android:paddingBottom="5dp"
|
||||||
|
android:text="删除"
|
||||||
|
android:textColor="@color/red"
|
||||||
|
android:textAllCaps="false"
|
||||||
|
android:textSize="16sp" />
|
||||||
|
|
||||||
|
|
||||||
|
<Button
|
||||||
|
android:id="@+id/btn_cancel"
|
||||||
|
style="?android:attr/borderlessButtonStyle"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="50dp"
|
||||||
|
android:layout_marginTop="15dp"
|
||||||
|
android:background="@drawable/selector_bottom_dialog_btn"
|
||||||
|
android:paddingTop="5dp"
|
||||||
|
android:text="取消"
|
||||||
|
android:textAllCaps="false"
|
||||||
|
android:textSize="16sp" />
|
||||||
|
|
||||||
|
</LinearLayout>
|
||||||
@@ -2,11 +2,14 @@
|
|||||||
<layout xmlns:android="http://schemas.android.com/apk/res/android">
|
<layout xmlns:android="http://schemas.android.com/apk/res/android">
|
||||||
|
|
||||||
<LinearLayout
|
<LinearLayout
|
||||||
|
android:id="@+id/ll_item"
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:orientation="vertical">
|
android:orientation="vertical">
|
||||||
|
|
||||||
<LinearLayout
|
<LinearLayout
|
||||||
|
android:id="@+id/ll"
|
||||||
|
android:visibility="gone"
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:orientation="horizontal">
|
android:orientation="horizontal">
|
||||||
@@ -38,11 +41,12 @@
|
|||||||
android:id="@+id/tv_name2"
|
android:id="@+id/tv_name2"
|
||||||
android:layout_width="wrap_content"
|
android:layout_width="wrap_content"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:textColor="@color/light_color_blue"
|
android:text="1111"
|
||||||
|
android:textColor="@color/text_name"
|
||||||
android:textSize="14sp" />
|
android:textSize="14sp" />
|
||||||
|
|
||||||
<TextView
|
<TextView
|
||||||
|
android:text="回复"
|
||||||
android:id="@+id/tv_info2"
|
android:id="@+id/tv_info2"
|
||||||
android:layout_width="wrap_content"
|
android:layout_width="wrap_content"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
@@ -50,14 +54,15 @@
|
|||||||
android:textSize="14sp" />
|
android:textSize="14sp" />
|
||||||
|
|
||||||
<TextView
|
<TextView
|
||||||
|
android:text="3333"
|
||||||
android:id="@+id/tv_name3"
|
android:id="@+id/tv_name3"
|
||||||
android:layout_width="wrap_content"
|
android:layout_width="wrap_content"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:textColor="@color/light_color_blue"
|
android:textColor="@color/text_name"
|
||||||
android:textSize="14sp" />
|
android:textSize="14sp" />
|
||||||
|
|
||||||
<TextView
|
<TextView
|
||||||
|
android:text="12163"
|
||||||
android:id="@+id/tv_info3"
|
android:id="@+id/tv_info3"
|
||||||
android:layout_width="wrap_content"
|
android:layout_width="wrap_content"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
|
|||||||
24
工作记录
24
工作记录
@@ -1,24 +0,0 @@
|
|||||||
1.图片白边,下边调窄一点
|
|
||||||
2.门禁,房产跳转
|
|
||||||
3.门禁,房产跳转登录页面
|
|
||||||
4.物业界面
|
|
||||||
5.删除家庭成员 删除成功 你提示的获取数据失败
|
|
||||||
6.房产那个 重复
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
__________________________________________________________________
|
|
||||||
1 临时门禁 添加1天期限的临时密码
|
|
||||||
CodeActivity
|
|
||||||
ShareCodeActivity
|
|
||||||
|
|
||||||
2.物业服务
|
|
||||||
map.put("userid", "19");写死的
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
17
开发文档
17
开发文档
@@ -1,17 +0,0 @@
|
|||||||
1.支付宝支付
|
|
||||||
MyPayActivity
|
|
||||||
下载官方demo,传入appid 和RSA2_PRIVATE两个参数即可实现支付,demo下载地址:https://opendocs.alipay.com/open/54/104509
|
|
||||||
alipay_demo保存在
|
|
||||||
|
|
||||||
|
|
||||||
Main4Fragment 187
|
|
||||||
|
|
||||||
2.首页点赞中间没有逗号修改的地方MainFragment
|
|
||||||
// if (i != 0 && i != discoveryListEntity.getLike().size() - 1) {
|
|
||||||
if (i != 0 ) {
|
|
||||||
likeString.append(",");
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
Reference in New Issue
Block a user