Bỏ qua để đến Nội dung
Menu
Câu hỏi này đã bị gắn cờ
2 Trả lời
1535 Lượt xem

I am using Odoo 15 CE. The pdf invoices after generation gets stored in the filestore and makes the odoo backup file too big. I see that the pdf invoice can be generated again if required hence see not  much utility in keeping the copy in the filestore.


Is there anyway to avoid storage of the pdf invoice in odoo?


How to delete the exiting pdf invoices which are in the file store?

Ảnh đại diện
Huỷ bỏ
Câu trả lời hay nhất

Hi,
If you don't want to store the printed reports, try unticking "Reload from Attachment?" and "Save as Attachment Prefix" empty in the reports menu.

* Enable debug mode
* Navigate to Reports menu under settings -> technical

* search and open report and apply the change for above mentioned fields

Thanks

Ảnh đại diện
Huỷ bỏ
Tác giả

Whether this will delete the existing pdf already generated?

Tác giả

i have written a cronjob to delete the invoice pdfs in the filestore.

1.use query SELECT store_fname FROM ir_attachment WHERE res_model= 'account.move' to get the location of the invoice pdf
2.delete the file from the file store.
3. use DELETE FROM ir_attachment WHERE res_model= 'account.move' to delete the record in ir_attachment table

Tác giả Câu trả lời hay nhất

i have written a cronjob to delete the invoice pdfs in the filestore.

1.use query SELECT store_fname FROM ir_attachment WHERE res_model= 'account.move' to get the location of the invoice pdf

2.delete the file from the file store.

3. use DELETE FROM ir_attachment WHERE res_model= 'account.move' to delete the record in ir_attachment table


Ảnh đại diện
Huỷ bỏ
Bài viết liên quan Trả lời Lượt xem Hoạt động
0
thg 12 24
588
1
thg 6 24
1522
0
thg 1 25
417
0
thg 10 24
999
11
thg 10 24
26358