confirm => t8('Do you really want to cancel this invoice?'),
disabled => !$::form->{id} ? t8('This invoice has not been posted yet.')
: $has_storno ? t8('This invoice has been canceled already.')
: $is_storno ? t8('Reversal invoices cannot be canceled.')
: $::form->{totalpaid} ? t8('Invoices with payments cannot be canceled.')
confirm => t8('Do you really want to cancel this invoice?'),
disabled => !$::form->{id} ? t8('This invoice has not been posted yet.')
: $has_storno ? t8('This invoice has been canceled already.')
: $is_storno ? t8('Reversal invoices cannot be canceled.')
: $::form->{totalpaid} ? t8('Invoices with payments cannot be canceled.')