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

hi all when i cancel a invoice with button ( cancel invoice ) action is  action_invoice_cancel, after build automatically draft invoice, how can i disable this ? i dont want build draft invoice after cancellation ?

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

1- on xml file inherit "set_to_draft" button and replace attributes to invisible

<button name="action_invoice_draft"position="attributes">
        <attribute name="invisible">1</attribute>
</button>

2- you can also inherit the method which apply draft action

@api.multi
def action_invoice_draft(self):
    pass

I Hope this answer help you
Ảnh đại diện
Huỷ bỏ
Bài viết liên quan Trả lời Lượt xem Hoạt động
0
thg 6 24
1428
8
thg 3 19
5287
0
thg 3 15
5021
2
thg 3 15
12579
2
thg 8 24
1581