mirror of
https://github.com/etesync/android
synced 2024-11-25 17:38:13 +00:00
Journal entry list: mark malformed entries with a bug icon.
This is an indication that an entry failed to parse.
This commit is contained in:
parent
9f6b63620e
commit
20387612db
@ -104,6 +104,12 @@ class ListEntriesFragment : ListFragment(), AdapterView.OnItemClickListener {
|
||||
val info = journalEntity!!.info
|
||||
setJournalEntryView(v, info, entryEntity!!.content)
|
||||
|
||||
val entryError = data.select(EntryErrorEntity::class.java).where(EntryErrorEntity.ENTRY.eq(entryEntity)).limit(1).get().firstOrNull()
|
||||
if (entryError != null) {
|
||||
val errorIcon = v.findViewById<View>(R.id.error) as ImageView
|
||||
errorIcon.visibility = View.VISIBLE
|
||||
}
|
||||
|
||||
return v
|
||||
}
|
||||
}
|
||||
|
@ -31,4 +31,11 @@
|
||||
tools:text="Subtitle"/>
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/error"
|
||||
android:src="@drawable/ic_bug_report"
|
||||
android:layout_width="32dp"
|
||||
android:layout_height="32dp"
|
||||
android:visibility="gone" />
|
||||
</LinearLayout>
|
Loading…
Reference in New Issue
Block a user