Commit d0a8874b authored by fallenstardust's avatar fallenstardust

只在debug时显示本地卡组最后修改时间

parent 5689558d
package cn.garymb.ygomobile.ui.adapters;
import static cn.garymb.ygomobile.Constants.DEBUG;
import static cn.garymb.ygomobile.ui.cards.deck_square.DeckSquareFileUtil.convertToGMTDate;
import android.annotation.SuppressLint;
......@@ -111,6 +112,11 @@ public class DeckListAdapter<T extends TextSelect> extends BaseQuickAdapter<T, D
holder.side.setTextColor(Color.RED);
}
holder.file_time.setText(convertToGMTDate(deckFile.getDate()));
if (DEBUG) {
holder.file_time.setVisibility(View.VISIBLE);
} else {
holder.file_time.setVisibility(View.GONE);
}
if (deckFile.getTypeName().equals(YGOUtil.s(R.string.category_pack)) || deckFile.getPath().contains("cacheDeck")) {
//卡包展示时不显示额外和副卡组数量文本
holder.ll_extra_n_side.setVisibility(View.GONE);
......
......@@ -639,7 +639,7 @@ public class DeckSquareApiUtil {
backupDownloadDecks.addAll(onlineDecks);
for (MyOnlineDeckDetail onlineDeck : backupDownloadDecks) {
LogUtil.w(TAG, "synchronizeDecks(750) +要下载的 云备份卡组: " + onlineDeck.getDeckType() + "//" + onlineDeck.getDeckName() + "//" + onlineDeck.getDeckUpdateDate());
LogUtil.w(TAG, "synchronizeDecks +要下载的 云备份卡组: " + onlineDeck.getDeckType() + "//" + onlineDeck.getDeckName() + "//" + onlineDeck.getDeckUpdateDate());
// 确保文件名包含.ydk扩展名
String fileName = onlineDeck.getDeckName();
if (!fileName.toLowerCase().endsWith(Constants.YDK_FILE_EX)) {
......@@ -653,9 +653,9 @@ public class DeckSquareApiUtil {
// 保存在线卡组到本地
boolean saved = DeckSquareFileUtil.saveFileToPath(fileFullPath, onlineDeck.getDeckYdk(), onlineDeck.getDeckUpdateDate());
if (!saved) {
LogUtil.e(TAG, "synchronizeDecks(761) 保存失败!的 云备份卡组: " + fileFullPath);
LogUtil.e(TAG, "synchronizeDecks 保存失败!的 云备份卡组: " + fileFullPath);
} else {
LogUtil.i(TAG, "synchronizeDecks(763) 保存成功√的 云备份卡组: " + fileFullPath);
LogUtil.i(TAG, "synchronizeDecks 保存成功√的 云备份卡组: " + fileFullPath);
}
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment