woocommerce-ios icon indicating copy to clipboard operation
woocommerce-ios copied to clipboard

[HACK Week] Other payment methods

Open toupper opened this issue 1 year ago • 2 comments
trafficstars

Description

With this PR we add support for other payment methods, where the merchant can add a note to the order specifying their method. This is useful when they receive a payment with a different method -e.g. checks, gift cards, house accounts, etc- than those currently displayed in the payment methods screen, and they want to add a record of it.

Testing instructions

  1. Go to orders
  2. Tap on + to create a new order
  3. Add products to the order. Tap on create.
  4. Tap on Collect Payment
  5. Select Other Payment Methods
  6. Add a note and mark the order as complete.
  7. See that the order is set as complete and the order details are shown.
  8. Refresh the order. See that a note is added with the text you entered.

Try also without adding a note (no note should be added to the order). See that the events are tracked as well: when tapping on the Other Payment Methods row:

🔵 Tracked payments_flow_collect, properties: [AnyHashable("is_wpcom_store"): true, AnyHashable("site_url"): "https://americanwootester.wpcomstaging.com", AnyHashable("order_id"): 1898, AnyHashable("payment_method"): "other_payment_methods", AnyHashable("was_ecommerce_trial"): false, AnyHashable("plan"): "business-bundle", AnyHashable("blog_id"): 214354650, AnyHashable("flow"): "order_payment"]

("payment_method"): "other_payment_methods"

When adding a note:

🔵 Tracked other_payment_methods_note_added, properties: [AnyHashable("site_url"): "https://americanwootester.wpcomstaging.com", AnyHashable("was_ecommerce_trial"): false, AnyHashable("is_wpcom_store"): true, AnyHashable("blog_id"): 214354650, AnyHashable("plan"): "business-bundle"]

Please also check that the event payments_flow_completed is tracked with the right payment method.

Screenshots

https://github.com/woocommerce/woocommerce-ios/assets/1864060/fc9f8360-e300-4ab3-8e96-258fea70b768


  • [ ] I have considered if this change warrants user-facing release notes and have added them to RELEASE-NOTES.txt if necessary.

toupper avatar Dec 06 '23 10:12 toupper

Warnings
:warning: PR is not assigned to a milestone.

Generated by :no_entry_sign: dangerJS

peril-woocommerce[bot] avatar Dec 06 '23 10:12 peril-woocommerce[bot]

WooCommerce iOS📲 You can test the changes from this Pull Request in WooCommerce iOS by scanning the QR code below to install the corresponding build.

App NameWooCommerce iOS WooCommerce iOS
Build Numberpr11366-c46b45c
Version16.4
Bundle IDcom.automattic.alpha.woocommerce
Commitc46b45c99096c2c154237c897cb648068f8a876c
App Center BuildWooCommerce - Prototype Builds #7085
Automatticians: You can use our internal self-serve MC tool to give yourself access to App Center if needed.

wpmobilebot avatar Dec 06 '23 11:12 wpmobilebot