Currently, an admin user can access the receipt page via the corresponding operation available on the admin Orders list page. It would be useful and consistent to have that operation available on the POS Order Lookup form, especially since some users, such as cashiers, may not have access to the Orders page; to find the receipt for a POS order they would first have to go to the order's view page and then click the Show receipt button.

Comments

krystalcode created an issue. See original summary.

krystalcode’s picture

Status: Active » Needs review
StatusFileSize
new3.53 KB

Patch provides a "Show receipt" operation on the lookup table.
Additionally, it renames the column name from "Action" to "Operations" to be consistent with the convention in both core and commerce. Feel free to rename it to "Actions" if that is the preference.
Lastly, I added an access check to the Edit operation as well.

Status: Needs review » Needs work
gmem’s picture

Status: Needs work » Reviewed & tested by the community

Interesting that the patch crashes on the CI[1], manages to pass just fine on my local machine. Works as described.

smccabe’s picture

StatusFileSize
new218.71 KB

Doesn't pass on my local, the CI runs the newest version of drupal, so possibly it passes on an older version.

The error the test outputs is attached.

smccabe’s picture

Status: Reviewed & tested by the community » Needs work
gmem’s picture

Fixed test, looks like clickLink() couldn't find the right Edit link. Also loaded commerce_pos_receipt in PosReturnFormTest. Wasn't able to replicate the SetOrdercustomerTest failure. (also small reroll)

gmem’s picture

Status: Needs work » Needs review

  • smccabe committed 7bd8a5c on 8.x-2.x authored by krystalcode
    Issue #2984967 by krystalcode, gmem, smccabe: Show receipts operation on...
smccabe’s picture

Status: Needs review » Fixed

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.