Jump to content

Query based on custom fields for order templates based on Demo 2


alexm
 Share

Recommended Posts

@kongondo sorry about all the questions... 

Continuing on with this discount solution I've made, I'm trying to show the discount code on the padloper-order page opposed to the order item. I've edited your PadloperProcessOrder::orderSaved hook to suit and when I edit the order page from the page tree I see that the discount code is saved to the text field however it doesn't display if I view the order page via the shop dashboard. I assume it's due to this rendering a customised page edit view, so wondering if there is an easy solution to get this custom field outputting on the shop's order page?

  • Like 1
Link to comment
Share on other sites

Hi @alexm,

3 hours ago, alexm said:

I assume it's due to this rendering a customised page edit view

That's correct. PadloperProcessRenderOrders renders the GUI. It has lots of hookable render methods. For instance, in demo-2, we hook into PadloperProcessRenderOrders::getSingleViewTableRow (line#29 ) to display the details of the 'customise' text field for the line item. The hookable methods are not yet documented (sorry). Please find them in that file and inject your markup using one of the hooks. Let me know how you get on.

  • Thanks 1
Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...