光环助手V3.5 RELEASE(20181029-1825)测试问题汇总(前端)(1.11.12.13.14.15.16.17.19.20.21.22.23.25.27.28.29.30(禁止输入空格).31.32.34)https://gitlab.ghzhushou.com/pm/halo-app-issues/issues/380
This commit is contained in:
@ -372,7 +372,7 @@ public class DialogUtils {
|
||||
return false;
|
||||
}
|
||||
String mb = size.toUpperCase().replaceAll("MB", "").trim();
|
||||
Integer i = Integer.valueOf(mb);
|
||||
Float i = Float.valueOf(mb);
|
||||
if (NetworkUtils.isWifiOr4GConnected(context) && i <= 50) {
|
||||
Utils.toast(context, "当前使用移动流量下载");
|
||||
return true;
|
||||
|
||||
@ -4,12 +4,17 @@ import android.content.Context;
|
||||
import android.content.Intent;
|
||||
import android.os.Bundle;
|
||||
import android.support.annotation.NonNull;
|
||||
import android.text.TextUtils;
|
||||
import android.view.View;
|
||||
import android.widget.TextView;
|
||||
|
||||
import com.gh.base.BaseActivity;
|
||||
import com.gh.common.constant.Config;
|
||||
import com.gh.common.util.DirectUtils;
|
||||
import com.gh.gamecenter.entity.SettingsEntity;
|
||||
import com.gh.gamecenter.suggest.SuggestType;
|
||||
|
||||
import butterknife.BindView;
|
||||
import butterknife.OnClick;
|
||||
|
||||
/**
|
||||
@ -19,6 +24,11 @@ public class SuggestSelectActivity extends BaseActivity {
|
||||
|
||||
public final static int SUGGEST_TYPE_REQUEST = 11; // 只要进入反馈页面(下一个), 无论怎么回退当前页面都会退出
|
||||
|
||||
@BindView(R.id.suggest_qqun)
|
||||
public TextView qQun;
|
||||
|
||||
private SettingsEntity mSettings;
|
||||
|
||||
@NonNull
|
||||
public static Intent getIntent(Context context) {
|
||||
Intent intent = new Intent(context, SuggestSelectActivity.class);
|
||||
@ -42,6 +52,12 @@ public class SuggestSelectActivity extends BaseActivity {
|
||||
protected void onCreate(Bundle savedInstanceState) {
|
||||
super.onCreate(savedInstanceState);
|
||||
setNavigationTitle(getString(R.string.title_suggest_select));
|
||||
|
||||
mSettings = Config.getSettings();
|
||||
if (mSettings != null && mSettings.getSupport() != null &&
|
||||
!TextUtils.isEmpty(mSettings.getSupport().getqQun())) {
|
||||
qQun.setText(mSettings.getSupport().getqQun());
|
||||
}
|
||||
}
|
||||
|
||||
@OnClick({R.id.suggest_type1, R.id.suggest_type2, R.id.suggest_type3, R.id.suggest_type4,
|
||||
@ -68,7 +84,12 @@ public class SuggestSelectActivity extends BaseActivity {
|
||||
type = SuggestType.articleCollect;
|
||||
break;
|
||||
case R.id.suggest_qqun_rl:
|
||||
DirectUtils.directToQqGroup(this, "vd754P2_uNUJqDcgX4V-pyXEGZZVH0DE"); // Q群:367541038 KEY
|
||||
String groupNumber = "vd754P2_uNUJqDcgX4V-pyXEGZZVH0DE";
|
||||
if (mSettings != null && mSettings.getSupport() != null &&
|
||||
!TextUtils.isEmpty(mSettings.getSupport().getqQunKey())) {
|
||||
groupNumber = mSettings.getSupport().getqQunKey();
|
||||
}
|
||||
DirectUtils.directToQqGroup(this, groupNumber); // Q群:367541038 KEY
|
||||
return;
|
||||
}
|
||||
|
||||
|
||||
@ -63,7 +63,7 @@ class GameDetailEntity : Parcelable {
|
||||
var fulishuoming: String? = null
|
||||
|
||||
@SerializedName("show_comment")
|
||||
val showComment: Boolean? = true
|
||||
val showComment: Boolean = false
|
||||
|
||||
@SerializedName("me")
|
||||
var me: MeEntity = MeEntity()
|
||||
|
||||
@ -71,6 +71,9 @@ class MeEntity(@SerializedName("is_community_voted")
|
||||
@SerializedName("is_voted")
|
||||
var isVoted: Boolean = false,
|
||||
|
||||
@SerializedName("is_commented")
|
||||
val isCommented: Boolean = false,
|
||||
|
||||
@SerializedName("libao")
|
||||
var userDataLibaoList: List<UserDataLibaoEntity>? = null) : Parcelable {
|
||||
}
|
||||
@ -3,8 +3,7 @@ package com.gh.gamecenter.entity
|
||||
class Rating(val star: Star = Star(),
|
||||
val device: String = "",
|
||||
val me: MeEntity = MeEntity(),
|
||||
var isExistComment: Boolean = true,
|
||||
val comment: RatingComment? = null)
|
||||
var isExistComment: Boolean = true)
|
||||
|
||||
class Star(var average: Float = 0F,
|
||||
val total: Int = 0,
|
||||
|
||||
@ -20,6 +20,8 @@ public class SettingsEntity {
|
||||
|
||||
private Image image;
|
||||
|
||||
private Support support;
|
||||
|
||||
public List<Download> getDownload() {
|
||||
return download;
|
||||
}
|
||||
@ -60,6 +62,14 @@ public class SettingsEntity {
|
||||
this.image = image;
|
||||
}
|
||||
|
||||
public Support getSupport() {
|
||||
return support;
|
||||
}
|
||||
|
||||
public void setSupport(Support support) {
|
||||
this.support = support;
|
||||
}
|
||||
|
||||
public class Download {
|
||||
private String game;
|
||||
|
||||
@ -313,4 +323,28 @@ public class SettingsEntity {
|
||||
}
|
||||
}
|
||||
|
||||
public class Support {
|
||||
@SerializedName("qq-group")
|
||||
private String qQun;
|
||||
|
||||
@SerializedName("qq-group-key")
|
||||
private String qQunKey;
|
||||
|
||||
public String getqQun() {
|
||||
return qQun;
|
||||
}
|
||||
|
||||
public void setqQun(String qQun) {
|
||||
this.qQun = qQun;
|
||||
}
|
||||
|
||||
public String getqQunKey() {
|
||||
return qQunKey;
|
||||
}
|
||||
|
||||
public void setqQunKey(String qQunKey) {
|
||||
this.qQunKey = qQunKey;
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@ -14,6 +14,7 @@ import com.gh.gamecenter.baselist.ListAdapter
|
||||
import com.gh.gamecenter.databinding.RatingCommentItemBinding
|
||||
import com.gh.gamecenter.entity.RatingComment
|
||||
import com.gh.gamecenter.gamedetail.rating.RatingCommentItemViewHolder
|
||||
import com.lightgame.utils.Utils
|
||||
|
||||
class DescCommentsAdapter(context: Context,
|
||||
var mViewModel: DescViewModel,
|
||||
@ -49,11 +50,15 @@ class DescCommentsAdapter(context: Context,
|
||||
binding.run {
|
||||
vote.setOnClickListener {
|
||||
CheckLoginUtils.checkLogin(mContext) {
|
||||
mViewModel.voteComment(comment.id, callback = {
|
||||
MtaHelper.onEvent("游戏详情", "玩家评论_点赞", mViewModel.game?.name)
|
||||
vote.text = (comment.vote + 1).toString()
|
||||
vote.isChecked = true
|
||||
})
|
||||
if (!vote.isChecked) {
|
||||
mViewModel.voteComment(comment.id, callback = {
|
||||
MtaHelper.onEvent("游戏详情", "玩家评论_点赞", mViewModel.game?.name)
|
||||
vote.text = (comment.vote + 1).toString()
|
||||
vote.isChecked = true
|
||||
})
|
||||
} else {
|
||||
Utils.toast(mContext, "已经点赞了哟~")
|
||||
}
|
||||
}
|
||||
}
|
||||
commentItem.setOnClickListener {
|
||||
|
||||
@ -19,6 +19,8 @@ import com.gh.gamecenter.databinding.RatingItemBinding
|
||||
import com.gh.gamecenter.entity.Rating
|
||||
import com.gh.gamecenter.entity.RatingComment
|
||||
import com.gh.gamecenter.gamedetail.rating.edit.RatingEditActivity
|
||||
import com.gh.gamecenter.manager.InstallManager
|
||||
import com.lightgame.utils.Utils
|
||||
|
||||
class RatingAdapter(context: Context,
|
||||
private val mListViewModel: RatingViewModel,
|
||||
@ -91,11 +93,6 @@ class RatingAdapter(context: Context,
|
||||
MtaHelper.onEvent("游戏详情", "评论Tab_点击我来评论", mListViewModel.game.name)
|
||||
skipRatingEdit(0.0F)
|
||||
}
|
||||
includeComment.run {
|
||||
if (this != null && ratingData?.comment != null) {
|
||||
setCommentClick(this, ratingData?.comment!!)
|
||||
}
|
||||
}
|
||||
}
|
||||
} else if (holder is RatingCommentItemViewHolder) {
|
||||
holder.binding.run {
|
||||
@ -110,14 +107,14 @@ class RatingAdapter(context: Context,
|
||||
|
||||
private fun skipRatingEdit(starCount: Float) {
|
||||
CheckLoginUtils.checkLogin(mContext) {
|
||||
// if (InstallManager(mContext).findInstallById(mListViewModel.game.id) != null) {
|
||||
if (InstallManager(mContext).findInstallById(mListViewModel.game.id) != null) {
|
||||
if (mContext is Activity) {
|
||||
val intent = RatingEditActivity.getIntent(mContext, mListViewModel.game.id!!, ratingData?.device, starCount)
|
||||
val intent = RatingEditActivity.getIntent(mContext, mListViewModel.game, ratingData?.device, starCount)
|
||||
(mContext as Activity).startActivityForResult(intent, RatingFragment.RATING_EDIT_REQUEST)
|
||||
}
|
||||
// } else {
|
||||
// Utils.toast(mContext, "安装游戏后才能评论哦")
|
||||
// }
|
||||
} else {
|
||||
Utils.toast(mContext, "安装游戏后才能评论哦")
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@ -125,11 +122,15 @@ class RatingAdapter(context: Context,
|
||||
binding.run {
|
||||
vote.setOnClickListener {
|
||||
CheckLoginUtils.checkLogin(mContext) {
|
||||
mListViewModel.voteComment(comment.id, callback = {
|
||||
vote.text = (comment.vote + 1).toString()
|
||||
vote.isChecked = true
|
||||
MtaHelper.onEvent("游戏详情", "评论Tab_点赞", mListViewModel.game.name)
|
||||
})
|
||||
if (!vote.isChecked) {
|
||||
mListViewModel.voteComment(comment.id, callback = {
|
||||
vote.text = (comment.vote + 1).toString()
|
||||
vote.isChecked = true
|
||||
MtaHelper.onEvent("游戏详情", "评论Tab_点赞", mListViewModel.game.name)
|
||||
})
|
||||
} else {
|
||||
Utils.toast(mContext, "已经点赞了哟~")
|
||||
}
|
||||
}
|
||||
}
|
||||
commentItem.setOnClickListener {
|
||||
|
||||
@ -15,8 +15,12 @@ import com.gh.gamecenter.baselist.LoadStatus
|
||||
import com.gh.gamecenter.entity.GameEntity
|
||||
import com.gh.gamecenter.entity.RatingComment
|
||||
import com.gh.gamecenter.entity.Star
|
||||
import com.gh.gamecenter.eventbus.EBReuse
|
||||
import com.gh.gamecenter.gamedetail.GameDetailFragment
|
||||
import com.gh.gamecenter.personal.PersonalFragment.LOGIN_TAG
|
||||
import com.halo.assistant.HaloApp
|
||||
import org.greenrobot.eventbus.Subscribe
|
||||
import org.greenrobot.eventbus.ThreadMode
|
||||
|
||||
class RatingFragment : ListFragment<RatingComment, RatingViewModel>() {
|
||||
|
||||
@ -97,6 +101,12 @@ class RatingFragment : ListFragment<RatingComment, RatingViewModel>() {
|
||||
}
|
||||
}
|
||||
|
||||
@Subscribe(threadMode = ThreadMode.MAIN)
|
||||
fun onEventMainThread(changed: EBReuse) {
|
||||
if (LOGIN_TAG == changed.type) { // 登入
|
||||
onLoadRefresh()
|
||||
}
|
||||
}
|
||||
|
||||
companion object {
|
||||
@BindingAdapter("setRatingScore")
|
||||
|
||||
@ -13,6 +13,7 @@ import com.gh.common.util.EntranceUtils
|
||||
import com.gh.common.util.LoginUtils
|
||||
import com.gh.gamecenter.R
|
||||
import com.gh.gamecenter.databinding.ActivityRatingEditBinding
|
||||
import com.gh.gamecenter.entity.GameEntity
|
||||
import com.gh.gamecenter.retrofit.Response
|
||||
import com.gh.gamecenter.retrofit.RetrofitManager
|
||||
import io.reactivex.android.schedulers.AndroidSchedulers
|
||||
@ -27,9 +28,9 @@ class RatingEditActivity : BaseActivity() {
|
||||
|
||||
private var mBinding: ActivityRatingEditBinding? = null
|
||||
|
||||
private var postDialog: WaitingDialogFragment? = null
|
||||
private var mPostDialog: WaitingDialogFragment? = null
|
||||
|
||||
private var mGameId = ""
|
||||
private var mGame: GameEntity? = null
|
||||
|
||||
override fun getLayoutId(): Int {
|
||||
return R.layout.activity_rating_edit
|
||||
@ -39,10 +40,11 @@ class RatingEditActivity : BaseActivity() {
|
||||
super.onCreate(savedInstanceState)
|
||||
setNavigationTitle("评论")
|
||||
setToolbarMenu(R.menu.menu_game_comment)
|
||||
mGameId = intent.getStringExtra(EntranceUtils.KEY_GAMEID)
|
||||
mGame = intent.getParcelableExtra(GameEntity.TAG)
|
||||
mBinding = ActivityRatingEditBinding.bind(mContentView)
|
||||
mBinding?.ratingScore?.rating = intent.getFloatExtra(EntranceUtils.KEY_RATING_STAR_COUNT, 1.0F)
|
||||
mBinding?.deviceName?.text = intent.getStringExtra(EntranceUtils.KEY_DEVICE_NAME)
|
||||
mBinding?.content?.hint = "你觉得${mGame?.name}怎么样..."
|
||||
}
|
||||
|
||||
override fun onMenuItemClick(item: MenuItem?): Boolean {
|
||||
@ -53,19 +55,18 @@ class RatingEditActivity : BaseActivity() {
|
||||
}
|
||||
|
||||
private fun postGameComment() {
|
||||
val content = mBinding?.content?.text.toString()
|
||||
if (TextUtils.isEmpty(content)) {
|
||||
toast("请先评论")
|
||||
return
|
||||
}
|
||||
val rating = mBinding?.ratingScore?.rating
|
||||
if (rating == null || rating == 0F) {
|
||||
toast("请评分再提交")
|
||||
toast("请先给游戏打分")
|
||||
return
|
||||
}
|
||||
|
||||
postDialog = WaitingDialogFragment.newInstance(getString(R.string.vote_post))
|
||||
postDialog?.show(supportFragmentManager, null)
|
||||
val content = mBinding?.content?.text.toString()
|
||||
if (TextUtils.isEmpty(content)) {
|
||||
toast("请填写评论内容")
|
||||
return
|
||||
}
|
||||
mPostDialog = WaitingDialogFragment.newInstance(getString(R.string.vote_post))
|
||||
mPostDialog?.show(supportFragmentManager, null)
|
||||
|
||||
val jsonObject = JSONObject()
|
||||
jsonObject.put("star", rating)
|
||||
@ -74,18 +75,19 @@ class RatingEditActivity : BaseActivity() {
|
||||
jsonObject.put("device", DeviceUtils.getLoginDevice(this))
|
||||
|
||||
val body = RequestBody.create(MediaType.parse("application/json"), jsonObject.toString())
|
||||
RetrofitManager.getInstance(this).api.postGameComment(mGameId, body)
|
||||
RetrofitManager.getInstance(this).api.postGameComment(mGame?.id, body)
|
||||
.subscribeOn(Schedulers.io())
|
||||
.observeOn(AndroidSchedulers.mainThread())
|
||||
.subscribe(object : Response<ResponseBody>() {
|
||||
override fun onResponse(response: ResponseBody?) {
|
||||
postDialog?.dismiss()
|
||||
mPostDialog?.dismiss()
|
||||
setResult(Activity.RESULT_OK)
|
||||
toast("提交成功")
|
||||
finish()
|
||||
}
|
||||
|
||||
override fun onFailure(e: HttpException?) {
|
||||
postDialog?.dismiss()
|
||||
mPostDialog?.dismiss()
|
||||
var errorString: String? = null
|
||||
try {
|
||||
errorString = e?.response()?.errorBody()?.string()
|
||||
@ -98,9 +100,9 @@ class RatingEditActivity : BaseActivity() {
|
||||
}
|
||||
|
||||
companion object {
|
||||
fun getIntent(context: Context, gameId: String, deviceName: String?, starCount: Float): Intent {
|
||||
fun getIntent(context: Context, game: GameEntity, deviceName: String?, starCount: Float): Intent {
|
||||
val intent = Intent(context, RatingEditActivity::class.java)
|
||||
intent.putExtra(EntranceUtils.KEY_GAMEID, gameId)
|
||||
intent.putExtra(GameEntity.TAG, game)
|
||||
intent.putExtra(EntranceUtils.KEY_DEVICE_NAME, deviceName)
|
||||
intent.putExtra(EntranceUtils.KEY_RATING_STAR_COUNT, starCount)
|
||||
return intent
|
||||
|
||||
@ -175,7 +175,7 @@ public class MessageItemViewHolder extends BaseRecyclerViewHolder<MessageEntity>
|
||||
mBinding.messageArticleIcon.setVisibility(View.GONE);
|
||||
break;
|
||||
case "community_article_vote":
|
||||
mBinding.messageCommand.setText("赞同了我的文章");
|
||||
mBinding.messageCommand.setText("赞同你的文章");
|
||||
mBinding.messageContent.setVisibility(View.GONE);
|
||||
mBinding.messageOriginalTitle.setText(messageEntity.getArticle().getTitle());
|
||||
mBinding.messageArticleIcon.setVisibility(View.GONE);
|
||||
@ -192,7 +192,7 @@ public class MessageItemViewHolder extends BaseRecyclerViewHolder<MessageEntity>
|
||||
mBinding.messageContent.setMaxLines(Integer.MAX_VALUE);
|
||||
mBinding.messageContent.setText(messageEntity.getComment().getContent());
|
||||
mBinding.messageOriginalTitle.setText(messageEntity.getArticle().getTitle());
|
||||
images = messageEntity.getAnswer().getImages();
|
||||
images = messageEntity.getArticle().getImages();
|
||||
if (images.size() > 0) {
|
||||
targetUrl = images.get(0);
|
||||
}
|
||||
@ -204,7 +204,7 @@ public class MessageItemViewHolder extends BaseRecyclerViewHolder<MessageEntity>
|
||||
mBinding.messageCommand.setText("赞了你的评论");
|
||||
mBinding.messageContent.setVisibility(View.GONE);
|
||||
mBinding.messageOriginalTitle.setText(messageEntity.getArticle().getTitle());
|
||||
images = messageEntity.getAnswer().getImages();
|
||||
images = messageEntity.getArticle().getImages();
|
||||
if (images.size() > 0) {
|
||||
targetUrl = images.get(0);
|
||||
}
|
||||
|
||||
@ -171,7 +171,8 @@ class ArticleDetailActivity : BaseActivity() {
|
||||
when (v.id) {
|
||||
R.id.article_detail_comment_count_container -> {
|
||||
val intent = CommentActivity.getArticleCommentIntent(this, mViewModel.articleId!!
|
||||
, mViewModel.detailEntity?.count?.comment, "", false, mViewModel.community?.id!!)
|
||||
, mViewModel.detailEntity?.count?.comment, "", false
|
||||
, mViewModel.detailEntity?.community?.id!!)
|
||||
startActivityForResult(intent, CommentActivity.REQUEST_CODE)
|
||||
}
|
||||
R.id.article_detail_like_container -> {
|
||||
@ -354,7 +355,7 @@ class ArticleDetailActivity : BaseActivity() {
|
||||
}
|
||||
|
||||
mBinding.articleDetailTags.removeAllViews()
|
||||
addTag(mViewModel.community?.name.toString())
|
||||
addTag(mViewModel.detailEntity?.community?.name.toString())
|
||||
for (tag in mViewModel.detailEntity!!.tags) {
|
||||
addTag(tag)
|
||||
}
|
||||
|
||||
@ -25,13 +25,12 @@ class ArticleDetailViewModel(application: Application) : AndroidViewModel(applic
|
||||
val articleLiveData = MutableLiveData<Resource<ArticleDetailEntity>>()
|
||||
|
||||
private val mFollowLiveData = MutableLiveData<Boolean>()
|
||||
private var community: CommunityEntity? = null // 社区名称可能为空
|
||||
|
||||
val followLiveData: LiveData<Boolean>
|
||||
get() = mFollowLiveData
|
||||
|
||||
var articleId: String? = null
|
||||
var community: CommunityEntity? = null
|
||||
|
||||
|
||||
fun initData(community: CommunityEntity, articleId: String) {
|
||||
this.articleId = articleId
|
||||
@ -44,7 +43,6 @@ class ArticleDetailViewModel(application: Application) : AndroidViewModel(applic
|
||||
.subscribeOn(Schedulers.io())
|
||||
.subscribe(object : Response<ArticleDetailEntity>() {
|
||||
override fun onResponse(response: ArticleDetailEntity?) {
|
||||
response?.community = community!!
|
||||
detailEntity = response
|
||||
articleLiveData.postValue(Resource.success(response))
|
||||
}
|
||||
|
||||
@ -27,7 +27,7 @@ class ArticleDraftFragment : ListFragment<ArticleDraftEntity, NormalListViewMode
|
||||
|
||||
override fun onActivityResult(requestCode: Int, resultCode: Int, data: Intent?) {
|
||||
super.onActivityResult(requestCode, resultCode, data)
|
||||
if (requestCode == ARTICLE_DRAFT_REQUEST && resultCode == Activity.RESULT_OK) {
|
||||
if (requestCode == ARTICLE_DRAFT_REQUEST /*&& resultCode == Activity.RESULT_OK*/) {
|
||||
mListViewModel?.load(LoadType.REFRESH)
|
||||
}
|
||||
}
|
||||
|
||||
@ -218,7 +218,7 @@ class ArticleEditActivity : BaseActivity() {
|
||||
mViewModel?.mSelectCommunityData = mViewModel?.draftEntity?.community
|
||||
mEditTitle.setText(mViewModel?.draftEntity?.title)
|
||||
mDraftBtn.visibility = View.GONE
|
||||
mGameName.isEnabled = false
|
||||
mGameName.isEnabled = true
|
||||
setGameName()
|
||||
mViewModel?.getArticleDraftsContent(mViewModel?.draftEntity?.id!!)
|
||||
mViewModel?.getDefaultTag()
|
||||
@ -289,7 +289,7 @@ class ArticleEditActivity : BaseActivity() {
|
||||
}
|
||||
|
||||
private fun setGameName() {
|
||||
mGameName.text = mViewModel?.mSelectCommunityData?.name
|
||||
mGameName.text = ("所属游戏 - " + mViewModel?.mSelectCommunityData?.name)
|
||||
mGameName.gravity = Gravity.LEFT or Gravity.CENTER_VERTICAL
|
||||
mGameName.setBackgroundDrawable(ColorDrawable(0))
|
||||
mGameName.setTextColor(Color.BLACK)
|
||||
@ -306,8 +306,8 @@ class ArticleEditActivity : BaseActivity() {
|
||||
|
||||
private fun setEditTextInputSpace() {
|
||||
val filterArray = arrayOfNulls<InputFilter>(2)
|
||||
val filter = InputFilter { source, start, end, dest, dstart, dend ->
|
||||
if (source.toString().contentEquals("\n")) {
|
||||
val filter = InputFilter { source, _, _, _, _, _ ->
|
||||
if (source.toString().contentEquals("\n") || source.toString().contentEquals(" ")) {
|
||||
""
|
||||
} else {
|
||||
null
|
||||
|
||||
@ -109,7 +109,7 @@ class MyDraftAdapter extends ListAdapter<AnswerEntity> {
|
||||
mContext.startActivity(QuestionsDetailActivity.getIntent(mContext, questions.getId(), mEntrance, "我的问答-我的草稿"));
|
||||
});
|
||||
binding.answerDraftItemDelete.setOnClickListener(v -> {
|
||||
DialogUtils.showAlertDialog(mContext, "删除草稿", "答案尚未发布,确定删除?"
|
||||
DialogUtils.showAlertDialog(mContext, "警告", "确定要删除回答草稿吗?删除之后不可恢复"
|
||||
, "确定", "取消"
|
||||
, () -> deleteAnswerDraft(answerEntity), null);
|
||||
});
|
||||
|
||||
@ -102,6 +102,7 @@ public class AnswerViewHolder extends BaseRecyclerViewHolder<AnswerEntity> {
|
||||
mQuestionTitle.setVisibility(View.VISIBLE);
|
||||
mQuestionTitle.setText(entity.getQuestions().getTitle());
|
||||
mVotecount.setText(mVotecount.getContext().getString(R.string.ask_vote_count, NumberUtils.transSimpleCount(entity.getVote())));
|
||||
mCommentCount.setText(String.format("%s 评论", NumberUtils.transSimpleCount(entity.getCommentCount())));
|
||||
mCommunityName.setVisibility(View.VISIBLE);
|
||||
mCommunityName.setText(entity.getCommunityName());
|
||||
UserEntity user = entity.getUser();
|
||||
|
||||
Reference in New Issue
Block a user