Closed
Bug 872987
Opened 12 years ago
Closed 11 years ago
[WebPayment] Expose ICC info to the payment provider
Categories
(Core :: DOM: Device Interfaces, defect)
Tracking
()
People
(Reporter: ferjm, Assigned: ferjm)
References
Details
Attachments
(1 file, 1 obsolete file)
See bug 871591
Assignee | ||
Updated•12 years ago
|
Blocks: PayId-v1next
Comment 1•12 years ago
|
||
How critical is this for 1.01? Can we workaround this for 1.01?
Assignee | ||
Comment 2•12 years ago
|
||
If I am not wrong, during the discussion about this functionality with product the decision was to nominate this for leo+.
blocking-b2g: --- → leo?
Assignee | ||
Comment 3•12 years ago
|
||
This patch introduces:
* The injection of a new 'mozPaymentProvider' object within the payment flow that includes the old 'paymentSuccess' and 'paymentFailed' functions. So now the payment provider will need to call 'mozPaymentProvider.paymentSuccess' (or paymentFailed) to end the payment flow. The reason for injecting the 'mozPaymentProvider' object instead of the old plain 'paymentSuccess' and 'paymentFailed' is to not pollute the global scope too much and avoid possible collisions with functions already defined within the payment provider scope. Kumar, do you think that you can easily change this in the server side?
* It also adds the new 'mozPaymentProvider.getIccId()' function that returns the ICC ID if available.
Attachment #751735 -
Flags: review?(fabrice)
Attachment #751735 -
Flags: feedback?(kumar.mcmillan)
Assignee | ||
Comment 4•12 years ago
|
||
(In reply to Fernando Jiménez Moreno [:ferjm] (needinfo instead of CC, please) from comment #3)
> * It also adds the new 'mozPaymentProvider.getIccId()' function that returns
> the ICC ID if available.
Actually, it returns an *array* of ICC IDs, so we won't need to change the API once we support multiple SIMs.
Comment 5•12 years ago
|
||
Comment on attachment 751735 [details] [diff] [review]
v1
Review of attachment 751735 [details] [diff] [review]:
-----------------------------------------------------------------
Let's make sure everyone likes mozPaymentProvider.iccIds. Also, this should probably go in 1.0.1 if we don't want users to have to support both versions of the API.
::: b2g/chrome/content/payment.js
@@ +32,3 @@
> const kClosePaymentFlowEvent = "close-payment-flow-dialog";
>
> +let _requestId = null;
Nit: it will be undefined by default, and this seems good enough.
@@ +102,2 @@
>
> + getIccId: function getIccId() {
I would rather have this be a property:
iccIds get() {
...
}
Attachment #751735 -
Flags: review?(fabrice)
Attachment #751735 -
Flags: feedback?(kumar.mcmillan)
Attachment #751735 -
Flags: feedback+
Assignee | ||
Comment 6•12 years ago
|
||
Thanks Fabrice!
I'll wait for Kumar's feedback before pushing this patch.
Attachment #751735 -
Attachment is obsolete: true
Attachment #752099 -
Flags: review?(fabrice)
Attachment #752099 -
Flags: feedback?(kumar.mcmillan)
Comment 7•12 years ago
|
||
(In reply to Fabrice Desré [:fabrice] from comment #5)
> Comment on attachment 751735 [details] [diff] [review]
> v1
>
> Review of attachment 751735 [details] [diff] [review]:
> -----------------------------------------------------------------
>
> Let's make sure everyone likes mozPaymentProvider.iccIds. Also, this should
> probably go in 1.0.1 if we don't want users to have to support both versions
> of the API.
Sadly, we're out of time to take fixes like these to 1.01 unless it's absolutely ship stopping. We're probably going to have a make a breaking API change here across 1.01 and 1.1 or we need to continue to support the legacy fallback mechanism along with this new approach.
Comment 8•12 years ago
|
||
Comment on attachment 752099 [details] [diff] [review]
v2
Review of attachment 752099 [details] [diff] [review]:
-----------------------------------------------------------------
I still think we should ship that in 1.0.1 if possible. Who is using the "old" api currently?
Attachment #752099 -
Flags: review?(fabrice) → review+
Comment 9•12 years ago
|
||
(In reply to Fabrice Desré [:fabrice] from comment #8)
> Comment on attachment 752099 [details] [diff] [review]
> v2
>
> Review of attachment 752099 [details] [diff] [review]:
> -----------------------------------------------------------------
>
> I still think we should ship that in 1.0.1 if possible. Who is using the
> "old" api currently?
Marketplace is at the moment.
Still feels risky though IMO to flip this around this late in the game for 1.01. I do understand this poses a compatibility issue, but given only marketplace is dependent on it, we would just need marketplace to have the ability to be able to work with the old API vs. new API.
Comment 10•12 years ago
|
||
I don't think the change is risky, but I agree with the "late in the game" argument. :(
I don't think it's a big deal to ask the marketplace to support two versions of the API. This API will be slowly evolving for some time to come I suspect.
Comment 12•12 years ago
|
||
Comment on attachment 752099 [details] [diff] [review]
v2
Review of attachment 752099 [details] [diff] [review]:
-----------------------------------------------------------------
Thanks ferjm, r+ from me. The iccIds array should be all we need for Bango to remember/forget mobile accounts for payment.
However, I was under the impression that the process running the Trusted UI (system app?) does not currently have permissions for the mobileConnection API. If so, does this need a Gaia patch?
Attachment #752099 -
Flags: review+
Attachment #752099 -
Flags: feedback+
Updated•12 years ago
|
blocking-b2g: leo? → leo+
Assignee | ||
Comment 13•12 years ago
|
||
Thanks Kumar!
(In reply to Kumar McMillan [:kumar] from comment #12)
> However, I was under the impression that the process running the Trusted UI
> (system app?) does not currently have permissions for the mobileConnection
> API. If so, does this need a Gaia patch?
There is no need for a Gaia patch. The required usage of the mobileConnection API is done in the chrome side, so there is no need to request permissions in this case.
I'll wait for you to have the server side ready before landing this patch.
Assignee | ||
Updated•12 years ago
|
Attachment #752099 -
Flags: feedback?(kumar.mcmillan)
Assignee | ||
Comment 14•12 years ago
|
||
I've filed Bug 877103 and proposed a fix for the server side.
Assignee | ||
Updated•12 years ago
|
Assignee | ||
Comment 15•12 years ago
|
||
Bug 877103 landed, so I'm pushing this patch to birch.
http://hg.mozilla.org/projects/birch/rev/40bea9a5a19e
Comment 16•11 years ago
|
||
Status: NEW → RESOLVED
Closed: 11 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla24
Comment 17•11 years ago
|
||
status-b2g18:
--- → fixed
status-b2g18-v1.0.0:
--- → wontfix
status-b2g18-v1.0.1:
--- → wontfix
status-b2g-v1.1hd:
--- → affected
status-firefox22:
--- → wontfix
status-firefox23:
--- → wontfix
status-firefox24:
--- → fixed
Comment 18•11 years ago
|
||
Updated•11 years ago
|
Flags: in-moztrap-
You need to log in
before you can comment on or make changes to this bug.
Description
•