             selectOptions : methods.map (method) ->
               title       : KD.utils.getPaymentMethodTitle method
               value       : method.paymentMethodId
-            callback      : (paymentMethodId) =>
+            callback      : (paymentMethodId) ->
               chosenMethod = methodsByPaymentMethodId[paymentMethodId]
-              @choiceForm.addCustomData 'paymentMethod', chosenMethod
+              choiceForm.addCustomData 'paymentMethod', chosenMethod
 
 
           paymentField.addSubView select


    return form

  getFormNames: ->
    [
      'productForm'
      'choiceForm'
      'entryForm'
      'confirmForm'
    ]

  hideForms: (forms = @getFormNames()) -> @[form]?.hide() for form in forms

  setState: (state) ->
    @hideForms()
    switch state
      when 'product'    then @productForm.show()
      when 'choice'     then @choiceForm.show()
      when 'entry'      then @entryForm.show()
      when 'confirm'
        confirmData = @utils.extend {}, @aggregatedData
        @confirmForm.setData confirmData
        @confirmForm.show()

  viewAppended:-> @prepareWorkflow()


class PaymentWorkflow extends FormWorkflow

  constructor: (options = {}, data) ->
    unless options.confirmForm
