跳至内容
菜单
此问题已终结
1 回复
389 查看

Hi Odooers


Not sure if I'm doing anything wrong... but when I print a Purchase Order after confirming, it prints the RFQ document, even though it is in status "Purchase Order".


If I send the order, it sends the proper Purchase Order, not the RFQ.


Any ideas?

形象
丢弃
最佳答案

Steps to fix this issue :- 

1. Ensure Correct Report Template Configuration

  • Navigate to Settings > Technical > Reporting > Reports.
  • Locate the Purchase Order report (it may be named purchase.order or purchase.report_order).
  • Verify it’s linked to the purchase.order model, while the RFQ report should be linked to purchase.order.request.


2. Check Reporting Action for Purchase Order

  • Go to Settings > Technical > Actions > Reports.
  • Find the action for Purchase Order (usually named purchase.order or purchase.report_order).
  • Ensure this action triggers the correct Purchase Order report for confirmed orders, not for RFQs.


3. Ensure Correct Condition Based on Status

  • The print action might be linked to the RFQ stage instead of the confirmed Purchase Order.
  • Go to Settings > Technical > Workflow and check the conditions for the Purchase Order workflow.
  • Ensure the print action is only triggered for orders in the "purchase" state (confirmed), not when they are in the "draft" or "sent" stages.


4. Update or Add Custom QWeb Template (if necessary)

  • If you have custom templates, go to Settings > Technical > User Interface > Views and search for the Purchase Order report template.
  • Add conditions in the template to differentiate between RFQs and confirmed orders:

​[ <t t-if="o.state == 'purchase'">

    ​<!-- Purchase Order Template -->

​</t>


​<t t-if="o.state == 'draft' or o.state == 'sent'">

​    ​<!-- RFQ Template -->

​</t>    ]


5. Verify Print Action Logic

  • Ensure the print action is set correctly to trigger the Purchase Order template only when the order is in the "purchase" state (confirmed), not for draft or sent states.
  • You can find this under Settings > Technical > Actions > Reports.


6. Test the Configuration

  • Confirm a Purchase Order, then try printing it.
  • Ensure that the correct Purchase Order template is printed, not the RFQ.


7. Double Check Email Action

  • Since email actions are working correctly (sending the right Purchase Order), make sure that the print action is aligned with the same logic, ensuring it prints only for confirmed orders.



Thanks & Regards ;


Company : DataInteger Consultancy Services LLP

形象
丢弃
相关帖文 回复 查看 活动
2
5月 25
491
0
5月 25
291
1
4月 25
414
1
4月 25
401
0
4月 25
288