[B2G][Helix][Date]The SMS is wrong when the time is set to old time

RESOLVED FIXED

Status

Firefox OS
Gaia::SMS
P2
normal
RESOLVED FIXED
5 years ago
5 years ago

People

(Reporter: lecky, Assigned: steveck)

Tracking

unspecified

Firefox Tracking Flags

(blocking-b2g:koi+, b2g-v1.2 fixed)

Details

Attachments

(2 attachments)

89.32 KB, application/octet-stream
Details
359 bytes, text/html
julienw
: review+
Details
(Reporter)

Description

5 years ago
User Agent: Mozilla/4.0 (compatible; MSIE 8.0; Windows NT 6.1; Trident/4.0; SLCC2; .NET CLR 2.0.50727; .NET CLR 3.5.30729; .NET CLR 3.0.30729; Media Center PC 6.0; aff-kingsoft-ciba; .NET4.0C; .NET4.0E)

Steps to reproduce:

gaia:8059864bd278645ab5d2598b5ed595154136c253
gecko:0265cd51b4dc64ca100353482ada2025df6f5f53
gonk-misc:ca9192d7ef6037016d4723647d86b72f7a410633

1、Auto set time such as 2013-9-12
2、Send a sms to Auxiliary Machine
3、Modify the time to a old time 2013-9-10
4、check the display in send box in attachment.
(Reporter)

Comment 1

5 years ago
Created attachment 809016 [details]
screenshots
(Reporter)

Updated

5 years ago
blocking-b2g: --- → hd?
Flags: needinfo?(wchang)
Flags: needinfo?(ehung)
Priority: -- → P2
(Reporter)

Comment 2

5 years ago
Hi evelyn&&wayne:
  We think this is a  bug in Gaia, could you help us to assign it , thanks!
blocking-b2g: hd? → ---
Hi Steve,

Can you check this?
Flags: needinfo?(wchang)
Flags: needinfo?(schung)
Flags: needinfo?(ehung)
Problem is probably at [1].

"shortDateTimeFormat" contains the date + the time. We should use '%x' only instead of getting "shortDateTimeFormat".

Steve do you want to do the patch or I can handle it if you want ?

[1] https://github.com/mozilla-b2g/gaia/blob/master/apps/sms/js/utils.js#L100-L105
(Assignee)

Comment 5

5 years ago
(In reply to Julien Wajsberg [:julienw] from comment #4)
> Problem is probably at [1].
> 
> "shortDateTimeFormat" contains the date + the time. We should use '%x' only
> instead of getting "shortDateTimeFormat".
> 
> Steve do you want to do the patch or I can handle it if you want ?
> 
> [1]
> https://github.com/mozilla-b2g/gaia/blob/master/apps/sms/js/utils.js#L100-
> L105

I will commit a patch later, thanks!
Flags: needinfo?(schung)
(Assignee)

Updated

5 years ago
Assignee: nobody → schung
blocking-b2g: --- → koi?
Steve, I don't think this should be a blocker.
(Assignee)

Comment 7

5 years ago
Created attachment 810447 [details]
pull-request.html

Yes, it's a rare case and not a serous issue, but this patch is small without side effect(and can help increasing test coverage :D). I think it's fine to have it in 1.2.
Attachment #810447 - Flags: review?(felash)
Comment on attachment 810447 [details]
pull-request.html

r=me

cheers !
Attachment #810447 - Flags: review?(felash) → review+
(Assignee)

Comment 9

5 years ago
Merged in master: 687961182b05f2327a871886d4d2066943c7db5a
Status: UNCONFIRMED → RESOLVED
Last Resolved: 5 years ago
Resolution: --- → FIXED
blocking-b2g: koi? → koi+
status-b2g-v1.2: --- → affected
Uplifted 687961182b05f2327a871886d4d2066943c7db5a to:
v1.2: 5a398a932a0957a948af5ddb4705b4c4dd1a8182
status-b2g-v1.2: affected → fixed
You need to log in before you can comment on or make changes to this bug.