Fix loading of zebra printers to modal and some other small fixes [SCI-7244] (#4463)

* Fix loading of zebra printers to modal and some other small fixes [SCI-7244]

* Fix zebra printing [SCI-7244]
This commit is contained in:
ajugo 2022-09-27 09:58:22 +02:00 committed by GitHub
parent 936814b054
commit aa10259d40
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
4 changed files with 5 additions and 4 deletions

View file

@ -154,7 +154,7 @@
},
submitPrint() {
if (this.selectedPrinter.attributes.type_of === 'zebra') {
zebraPrinters.print(
this.zebraPrinters.print(
this.urls.zebraProgress,
'.label-printing-progress-modal',
'#modal-print-repository-row-label',
@ -179,7 +179,7 @@
initZebraPrinter() {
this.zebraPrinters = zebraPrint.init($('#LabelPrinterSelector'), {
clearSelectorOnFirstDevice: false,
appendDevice: function(device) {
appendDevice: (device) => {
this.printers.push({
id: `zebra${this.printers.length}`,
attributes: {

View file

@ -39,6 +39,6 @@ class LabelTemplatesPreviewService
private
def sanitize_zpl_code(zpl_code)
zpl_code.gsub!('_', '_5F')
zpl_code.gsub('_', '_5F')
end
end

View file

@ -35,7 +35,7 @@
<div class="description">
<%= t('users.settings.account.addons.zebra_printer.description') %>
</div>
<%= link_to t('users.settings.account.addons.printers.printer_details'), zebra_settings_path(), class: 'printer-details' %>
<%= link_to t('users.settings.account.addons.printers.details'), zebra_settings_path(), class: 'printer-details' %>
</div>
</div>
<% end %>

View file

@ -2252,6 +2252,7 @@ en:
ready: "Ready"
not_ready: "Not ready"
printer_details: "Printer details"
details: "Details"
enter_api_key: "Enter API key"
enabled: "Enabled"
fluics_printer: