Commit Graph

8 Commits

Author SHA1 Message Date
Yi-Ling Chuang
682a30f4c9 Clean up unused DB columns.
Remove some columns from Contextual Card DB as they are never used.

Fixes: 143058171
Test: robotests
Change-Id: Ic618ccba16c3ed9f0a85b905535916e5d062d79e
2020-02-14 19:59:35 +08:00
Raff Tsai
3881e2986c Do not log Contextual card display when card is dismissed
If the db change comes from dismiss card uri. We don't
need to log card display again.

Fixes: 121196921
Test: Robolectric
Change-Id: I4e222187fafa8325e803fa6ee17ebb0b51fb8cb2
2019-02-27 10:36:03 +08:00
Jason Chiu
93d4993556 Micro cleanup and refactoring
- organize import
- remove unused code in ContextualCardLoaderTest
- refactor CardDatabaseHelper

Test: robotest
Change-Id: I1a5a49bee1c4edb34f1c59f3dbe37cb22f01b0d4
2018-12-17 17:13:08 +08:00
Emily Chuang
1e24cb02dc Add contextual card dismissal implementation
When users clcik on the remove button in dismissal view, the card should
be marked as dismissed in the database, and the UI should be refreshed.

Bug: 113783548, 119594116
Test: robotests
Change-Id: I980600c4c0753ad5abc52ae63bac7196a4b818f1
2018-11-20 12:53:19 +08:00
Fan Zhang
6735a3f07e Rank cards in descending score when loading from db.
Test: robotest
Change-Id: Ic40f6ed9e702a60f51d4ec6700e663f1689f0009
2018-11-08 15:31:37 -08:00
Sunny Shao
647d3e3047 Added card_dismissed field into cards table
Added card_dismissed field to keep user dismissal behavior and filter it when cards loaded

Bug: 113783548
Test: manual test
Change-Id: I27549eca95c2e49fcc92fa59a5c02da73814a522
2018-11-06 20:59:46 +08:00
Fan Zhang
7775f67053 Remove db restriction for category column.
SettingsIntelligence should be able to extend support to more categories
without changing Settings.

Bug: 118708391
Test: rebuild
Change-Id: I420394f718bb3712e94040fb3e3c4f66cca629af
2018-11-01 16:31:13 -07:00
Fan Zhang
5e6e6a14f2 Move all contextual card related classes.
... from homepage to contextualcards.

Test: rebuild
Change-Id: Id7889566ce1e7257eb699d963ae996906fdb58ff
2018-10-26 10:02:04 -07:00