-  this.setup = function() {
-    $('#create_button').click(kivi.MassInvoiceCreatePrint.submitMassCreationForm);
-    $('#create_print_all_button').click(kivi.MassInvoiceCreatePrint.createPrintAllInitialize);
-    $('#action_print').click(kivi.MassInvoiceCreatePrint.checkInvoiceSelection);
+  ns.showMassPrintOptions = function() {
+    $('#printer_options_printer_id').val($('#printer_id').val());
+
+    kivi.popup_dialog({
+      id: 'print_options',
+      dialog: {
+        title: kivi.t8('Print options'),
+        width:  600,
+        height: 200
+      }
+    });
+
+    return true;
+  };
+
+  ns.showMassPrintOptionsOrDownloadDirectly = function() {
+    if (!kivi.MassInvoiceCreatePrint.checkInvoiceSelection())
+      return false;
+
+    if ($('#print_options_printer_id').length === 0)
+      return kivi.MassInvoiceCreatePrint.massPrint();
+    return kivi.MassInvoiceCreatePrint.showMassPrintOptions();