Status

defect
RESOLVED FIXED
5 years ago
4 years ago

People

(Reporter: pdol, Assigned: mai)

Tracking

({feature})

Dependency tree / graph

Firefox Tracking Flags

(feature-b2g:2.2+, tracking-b2g:backlog)

Details

(Whiteboard: [ucid:SMRTDATA-13-10][NaBfT])

User Story

As a user, I want to be able to reset my usage data in case I change my mobile plan/prepaid card, so that I can reconfigure the settings based on the new plan/card.

Acceptance Criteria:
1. Choosing to clear all data, as described by the UX spec, informs the user how much mobile data they will be clearing and gives them the opportunity to confirm or cancel the operation.
2. Canceling the operation, just returns the user to the previous screen.
3. Confirming the operation returns the user to the previous screen but all usage data is reset to zero.

Attachments

(2 attachments, 1 obsolete attachment)

No description provided.
Whiteboard: [ucid:SMRTDATA-13-10] → [ucid:SMRTDATA-13-10][NaBfT]
Blocks: 1095079
No longer blocks: 1089952
feature-b2g: --- → 2.2?
User Story: (updated)
Summary: [User Story] Reset plan [DRAFT] → [User Story] Reset usage data
blocking-b2g: --- → backlog
feature-b2g: 2.2? → 2.2+
Posted file patch v1.0
Hi Juwei, 
would you mind taking a look to the fix?

Best regards,
Mai
Attachment #8526628 - Flags: ui-review?(jhuang)
Assignee: nobody → marina.rodriguez.iglesias
Hi Mai,

It looks good! thanks

Only one thing left:
it would be better to show the current data usage when users are about to delete it.
So can the string be:

1. Mobile: Your current mobile data usage is XX MB. Clear it all?
2. Wifi: Your wifi data usage is XX MB. Clear it all?
3. Mobile & Wifi: Your current data usages are XX MB on mobile data, XX MB on Wifi. Clear them all?
Attachment #8526628 - Flags: ui-review?(jhuang)
Posted image screenshot confirm dialog (obsolete) —
Hi Juwei,
I've attached a screenshot with the last changes.
Regards
Attachment #8527692 - Flags: ui-review?(jhuang)
Comment on attachment 8526628 [details] [review]
patch v1.0

Hi Salva,
 would you mind taking a look?

Regards Mai
Attachment #8526628 - Flags: review?(salva)
Comment on attachment 8526628 [details] [review]
patch v1.0

First, let's convert this into a view class. Like others in [1]. This makes views testable. Second, let's refactor it a little bit and finally we could add some tests (maybe in a follow up but let's try in the same bug now).

[1] https://github.com/mozilla-b2g/gaia/tree/master/apps/costcontrol/js/views

Ask for my review once you're done!
Attachment #8526628 - Flags: review?(salva)
Comment on attachment 8527692 [details]
screenshot confirm dialog

Hi Marina,
The string on the 3rd screen is a bit different, it should be:

"Your current data usages are 2.10 KB on mobile, 4.77KB on Wifi. Clear them all?"

Thank you!
Attachment #8527692 - Flags: ui-review?(jhuang) → ui-review-
Comment on attachment 8526628 [details] [review]
patch v1.0

Hi Salva,
would you mind reviewing the patch?
Regards
Attachment #8526628 - Flags: review?(salva)
Comment on attachment 8526628 [details] [review]
patch v1.0

A couple of comments on GitHub but a really good work! Ask for my review when you're done and don't forget the follow up.
Attachment #8526628 - Flags: review?(salva)
Comment on attachment 8526628 [details] [review]
patch v1.0

Hi Salva,
would you mind reviewing the patch again?
Regards
Attachment #8526628 - Flags: review?(salva)
Comment on attachment 8526628 [details] [review]
patch v1.0

By passing the whole `costcontrol` object you have a lot of coupling. Please reduce it by passing only the data needed (you should rebase your patch as well).
Attachment #8526628 - Flags: review?(salva) → review-
Comment on attachment 8526628 [details] [review]
patch v1.0

Updated the PR with your comments.
Attachment #8526628 - Flags: review- → review?(salva)
Comment on attachment 8526628 [details] [review]
patch v1.0

Now it looks great to me but before merging, ask for ui-review again and address the couple of nits on GitHub.
Attachment #8526628 - Flags: review?(salva) → review+
Juwei, I've update the scren, Would you mind taking a look?
Regards
Attachment #8527692 - Attachment is obsolete: true
Attachment #8531912 - Flags: ui-review?(jhuang)
Comment on attachment 8531912 [details]
screenshot confirm dialog

Looks good!
Thank you Marina!
Attachment #8531912 - Flags: ui-review?(jhuang) → ui-review+
Master: 529c5fcd234ffd108b57629673ca97c2ef73376d
Status: NEW → RESOLVED
Closed: 5 years ago
Resolution: --- → FIXED
'Wi-Fi' is misspelled in at least two strings (not 'Wifi', 'Wi-Fi'). No need for new IDs to fix this.
Blocks: 1108951
blocking-b2g: backlog → ---
You need to log in before you can comment on or make changes to this bug.