[% sections.title = dw.ml( '.title' ) %] [% IF showform %] [% widget %]
[% dw.form_auth() %] [% IF cart.total_cash > 0.00 %]

[% dw.ml( '.confirm', { sitename => site.name, total => "${cart.display_total_cash}" } ) %]

[% dw.ml(".confirm.$paymentmethod") %]

[% ELSIF cart.total_points > 0 %]

[% dw.ml( '.confirm.onlypoints', { sitename => site.name } ) %]

[% END %] [% UNLESS cart.userid %]

[% dw.ml('.confirm.email') %]

[% form.textbox( name => 'email', value => email, label = dw.ml('.confirm.email.label') ) %]

[% IF email_errors %]

join( '
', @email_errors ) %]

if ( $email_checkbox ) { }
[% END %] [% END %]

[% form.submit( name => 'confirm', value => dw.ml('.btn.confirm') ) %] [% dw.ml('.btn.cancel') %]

[% ELSE %] [% IF confirm == 1 %]

[% dw.ml(".success.${paymentmethod}.immediate") %]

[% ELSIF confirm == 2 %] [% address = "

${site.company}
Order #${cart.id}
${site.address}

" %]

[% dw.ml( ".success.${paymentmethod}.processing", { sitecompany => "${site.company}", address => address } ) %]

[% END %]

[% dw.ml(".btn.viewreceipt") %]
[% dw.ml('.btn.back') %]

[% END %]