تخطي للذهاب إلى المحتوى
القائمة
لقد تم الإبلاغ عن هذا السؤال
1 الرد
9510 أدوات العرض

What I want as a result is the ability to reprint a pos order after the validation (set to paid).

Since I don't have a Ethernet thermal printer but just an USB one and I can't set a proxy printer, I need to exit the POS, enter the order and use the "reprint" button. Luckily, since I've installed the Report to printer module I am able to print directly to my thermal printer when I press the button.

I've already installed the modules Automated Action Rules and now I'm begging an help to identify the correct workflow and the syntax to reprint.

Edit:

Please have a look here for a workaround: bind a report to a workflow

الصورة الرمزية
إهمال
الكاتب أفضل إجابة

A little step forward... After reading this old doc

https://doc.odoo.com/6.0/developer/4_13_server_action/

I manage to replicate the function of the "reprint" button on POS Order.

Then I created an automated action to create (and print) the qweb report based on the order status "paid":

-Automated action-

Rule name: Kitchen_order

Related Document Model: Point of Sale

Active: yes

Sequence: 0

-Conditions-

When to Run: On Creation & Update

Filter: Paid

Actions:

Fields to Change

Set Responsible: Administrator

Add Followers: none

Server actions to run

Sequence: 1

Action Name: Reprint_Pos

Action To Do: Run a Client Action

-----------------------

Server Action:

Name: Reprint_Pos

Base Model: Point of Sale

Action To Do: Run a Client Action

Condition: True

Sequence: 1

Client Action: Receipt (Action Type is ir.actions.report.xml)

I've enable it on "More" tab and is working in both cases, I mean when I set it as a PDF or when I send it directly to my printer (using report to printer module).

Then I edit the "paid" function on Pos Workflow, adding my server action (Reprint_Pos) on Actions and leaving untouched all the other parameters.

Seems all good to me but the PDF is not generated automatically. Where I'm wrong?

الصورة الرمزية
إهمال
المنشورات ذات الصلة الردود أدوات العرض النشاط
0
أغسطس 24
6393
3
يناير 17
10621
5
أكتوبر 16
10707
9
نوفمبر 15
5868
1
مايو 15
3891