#IF(#LineItemContainer.IsTaxClassRemoved)

{Notification}

{TaxClassRemoved}
#ENDIF #IF(#FormError)
#IF(#OBJECT_EXISTS)

{InputError}

{ObjectExists} #ELSIF(#FormErrors.Reason.No_Recipients) {NoCustomerEmail} #ELSIF(#FormErrors.Reason.NoShipping)

{InputError}

{NoShipping}

#ELSIF(#FormErrors.Reason.NoPayment)

{InputError}

{NoPayment}

#ELSIF(#FormErrors.Reason.OrderNoExists)

{InputError}

{OrderNoExists}

#ELSIF(#FormErrors.Reason.SEND_MAIL_FAILED OR #FormErrors.Reason.InactiveMailType OR #FormErrors.Reason.MISSING_FROM)

{Notification}

{SEND_MAIL_FAILED} #ELSIF(#FormErrors.Reason.Invalid_Recipient)

{Notification}

{Invalid_Recipient} (#Recipient) #ELSIF(#FormErrors.Reason.ShippingMethodChanged)

{InputError}

{ShippingMethodChanged}

#ELSIF(#FormErrors.Reason.PaymentMethodChanged)

{InputError}

{PaymentMethodChanged}

#ELSIF(#FormErrors.Reason.NoShippingMethod)

{InputError}

{NoShipping}

#ELSIF(#FormErrors.Reason.NoPaymentMethod)

{InputError}

{NoPayment}

#ELSIF(#FormErrors.Reason.ProductNoPrice)

{InputError}

{ProductNoPrice}

#ELSIF(#FormErrors.Reason.ProductCanNotAddToBasket)

{InputError}

{ProductCanNotAddToBasket}

#ELSIF(#FormErrors.Reason.ProductCanNotChangedAtBasket)

{InputError}

{ProductCanNotChangedAtBasket}

#ELSIF(#FormErrors.Reason.NotArchivedOrCancelled)

{Notification}

{CanNotDeleteOrder}

#ELSE

{InputError}

{PleaseCorrectErrors} #ENDIF
#ENDIF #IF(#No_SMTPConnection)

{Notification}

{SEND_MAIL_FAILED}
#ELSIF(#ORDERCONF_SEND_OK OR #SEND_MAIL_OK)

{EMailSendOk}

#ENDIF #IF(#EMAIL_MISSING)

{Notification}

{NoCustomerEmail}
#ENDIF #IF(#NOT_ARCHIVED_OR_CANCELLED)

{Notification}

{CanNotDeleteOrder}
#ENDIF #IF(#DELETE)

{Warning}

{AcceptAction}
#ENDIF #IF(#IsFraud)

{Conflict}

{ConflictInfo}
  {AmountOfOrder}: #LineItemContainer.GrandTotal[money]
  {AmountOfTransaction}: #LineItemContainer.Payment.Amount[money]

#ENDIF
#IF(NOT #OriginalOrder)

{Status}

#ViewedOn[datetime] #IF(NOT #DELETE)#ENDIF
#CancelledOn[datetime] #IF(NOT #DELETE)#ENDIF
#InProcessOn[datetime] #IF(NOT #DELETE)#ENDIF
#PendingOn[datetime] #IF(NOT #DELETE)#ENDIF
#ReadyForShippingOn[datetime] #IF(NOT #DELETE)#ENDIF
#PartlyDispatchedOn[datetime] #IF(NOT #DELETE)#ENDIF
#DispatchedOn[datetime] #IF(NOT #DELETE)#ENDIF
#ShippedOn[datetime] #IF(NOT #DELETE)#ENDIF
#PartlyInvoicedOn[datetime] #IF(NOT #DELETE)#ENDIF
#InvoicedOn[datetime] #IF(NOT #DELETE)#ENDIF
#PartlyPaidOn[datetime] #IF(NOT #DELETE)#ENDIF
#PaidOn[datetime] #IF(NOT #DELETE)#ENDIF
#ClosedOn[datetime] #IF(NOT #DELETE)#ENDIF
#ArchivedOn[datetime] #IF(NOT #DELETE)#ENDIF

{Customer} #IF(NOT #INPUT.PopUp) #IF(#Customer.BillingAddress)#WITH(#Customer.BillingAddress)#IF(#DisplayName)#DisplayName#ELSE#FullName#ENDIF#IF(#Company) - #Company#ENDIF#ENDWITH#ENDIF (#Customer.Alias) #ELSE #IF(#Customer.BillingAddress)#WITH(#Customer.BillingAddress)#IF(#DisplayName)#DisplayName#ELSE#FullName#ENDIF#IF(#Company) - #Company#ENDIF#ENDWITH#ENDIF (#Customer.Alias) #ENDIF
#BLOCK("WITH_FORM_ERROR", #FormError)
{OrderNumber}
{BubbleHelpOrderNumber} {ChangeNumberFormats}
{SendOrderConfirmationMail}
#MENU("AdditionalSendMailActions")#INCLUDE(#Template)#ENDMENU {PrintOrder}
#IF(#Shop.FeatureMaxValue.OrderDocument) {CreateAndPrintDocuments}
#LOCAL("HasInvoices",0) #LOOP(#Documents) #IF(#Parent.Alias EQ "Invoices")#SET("HasInvoices", 1)#ENDIF #ENDLOOP {SendInvoiceAsPDF} #ENDLOCAL
#ENDIF {ExportOrder}
#IF(#FUNCTION("MENU_COUNT", "AdditionalActions"))#MENU("AdditionalActions")#INCLUDE(#Template)#ENDMENU#ENDIF
#ENDBLOCK
#BLOCK("WITH_FORM_ERROR", #FormError)

{BillingAddress}

#IF(#BillingAddress)#WITH(#BillingAddress) #FUNCTION("LocaleInclude","Address", #Country.Code2)

#ENDWITH#ENDIF
{FurtherInformation} {FurtherInformation}
#IF(#BillingAddress)#WITH(#BillingAddress) #INCLUDE("INC-OrderInformationExtra") #ENDWITH#ENDIF
#IF(#ShippingAddress OR #FormError)

{ShippingAddress}

#IF(#ShippingAddress) #WITH(#ShippingAddress) #FUNCTION("LocaleInclude","Address", #Country.Code2)

{FurtherInformation} {FurtherInformation}
#INCLUDE("INC-OrderInformationExtra")
#ENDWITH #ENDIF #ENDIF

#ENDBLOCK #INCLUDE("INC-OrderInformationTable")

{Comment}
#IF(#DELETE) #ELSE
#IF(#INPUT.PopUp) #ELSE #ENDIF
#IF(#CancelledOn OR #ClosedOn OR #ArchivedOn)
 {EditImpossible}
#ENDIF
#ENDIF
#ELSE #IF(#UpdateNotApplied AND NOT #FormError)

{Notification}

{UpdateNotApplied}
#ENDIF #IF(#SKUNotExists)

{InputError}

{InvalidProduct}
#ENDIF
#BLOCK("WITH_FORM_ERROR", #FormError)

{BillingAddress}

#IF(#BillingAddress) #LOCAL("AddressPrefix","BillingAddress")#LOCAL("Address", #BillingAddress) #LOCAL("RegistrationField", #Shop.RegistrationField)#LOCAL("RegistrationSet", "BillingAddress") #FUNCTION("LocaleInclude","EditRegistrationField-Address") #ENDLOCAL#ENDLOCAL#ENDLOCAL#ENDLOCAL #ELSE

{NoBillingAddress}

#ENDIF

{ShippingAddress}

#LOCAL("AddressPrefix","ShippingAddress")#LOCAL("RegistrationField", #Shop.RegistrationField)#LOCAL("RegistrationSet", "ShippingAddress") #IF(#ShippingAddress OR #FormError) #LOCAL("Address", #ShippingAddress)#FUNCTION("LocaleInclude","EditRegistrationField-Address")#ENDLOCAL #ELSE #LOCAL("Address", #EmptyAddress)#FUNCTION("LocaleInclude","EditRegistrationField-Address")#ENDLOCAL #ENDIF #ENDLOCAL#ENDLOCAL#ENDLOCAL
#ENDBLOCK


#INCLUDE("INC-EditOrderInformationTable") #IF(#CustomerComment)

{CustomerComment}

#CustomerComment[preline]
#ENDIF
#ENDIF
{MandatoryFields}