Anonymous | Login
Project:
RSS
  
News | My View | View Issues | Roadmap | Summary

View Issue DetailsJump to Notes ] Issue History ] Print ]
ID
0048812
TypeCategorySeverityReproducibilityDate SubmittedLast Update
feature request[POS2] POSminorhave not tried2022-03-16 11:522022-03-22 13:20
ReporterebecerraView Statuspublic 
Assigned Toebecerra 
PrioritynormalResolutionfixedFixed in Version
StatusclosedFix in branchFixed in SCM revision
ProjectionnoneETAnoneTarget Version
OSAnyDatabaseAnyJava version
OS VersionDatabase versionAnt version
Product VersionSCM revision 
Review Assigned To
Regression level
Regression date
Regression introduced in release
Regression introduced by commit
Triggers an Emergency PackNo
Summary

0048812: Add a function to OB.App.PrintUtils to generate valid image tag for webUSB/HWM configurations

DescriptionAdd a new function to OB.App.PrintUtils to allow generate the TAG <image> in print templates based on the prinmter (webUSB or hardware manager)
Steps To ReproduceN/A
Proposed Solution/**
   * Get image TAG according printer type
   *
   * @param printerType {string} - Printer type (OB.App.TerminalProperty.get('terminal').printertype)
   * @param align {string} - Image align
   * @param base64Data {string} Image code in Base64
   * @returns {string} Tag: <image ...>...</image>
   */
  getImageTagFromBase64: (printerType, align, base64Data) => {
    const imgAlign = align ? ` align="${align}"` : '';
    const type = printerType === 'GENERICUSB' ? '' : ' type="data"';
    const prefix = printerType === 'GENERICUSB' ? 'data:png;base64,' : '';
    return `<image${imgAlign}${type}>${prefix}${base64Data}</image>`;
  }
TagsNo tags attached.
Attached Files

- Relationships Relation Graph ] Dependency Graph ]
has duplicate feature request 0048657 closedfermin_gascon Openbravo ERP Unable to print images stored on database on web usb printers 

-  Notes
(0135771)
hgbot (developer)
2022-03-16 12:00

Merge Request created: https://gitlab.com/openbravo/product/pmods/org.openbravo.retail.posterminal/-/merge_requests/747 [^]
(0135920)
hgbot (developer)
2022-03-22 13:20

Directly closing issue as related merge request is already approved.

Repository: https://gitlab.com/openbravo/product/pmods/org.openbravo.retail.posterminal [^]
Changeset: 9d2dd3261cbfc595c963777c74efec338d091dce
Author: Eduardo Becerra (OB) <eduardo.becerra@openbravo.com>
Date: 22-03-2022 12:20:15
URL: https://gitlab.com/openbravo/product/pmods/org.openbravo.retail.posterminal/-/commit/9d2dd3261cbfc595c963777c74efec338d091dce [^]

Fixes ISSUE-48812: Add a function to OB.App.PrintUtils
* Prints base64 encoded images in WebUSB. This makes equivalent printing base64 encoded images with the Hardware Manager and WebUSB.

---
M web/org.openbravo.retail.posterminal/app/webprinter/webprinter.js
---
(0135921)
hgbot (developer)
2022-03-22 13:20

Merge request merged: https://gitlab.com/openbravo/product/pmods/org.openbravo.retail.posterminal/-/merge_requests/747 [^]

- Issue History
Date Modified Username Field Change
2022-03-16 11:52 ebecerra New Issue
2022-03-16 11:52 ebecerra Assigned To => Retail
2022-03-16 11:52 ebecerra Triggers an Emergency Pack => No
2022-03-16 11:53 ebecerra Assigned To Retail => ebecerra
2022-03-16 11:53 ebecerra Status new => scheduled
2022-03-16 12:00 hgbot Note Added: 0135771
2022-03-16 12:55 guilleaer Summary Add a function to OB.App.PrintUtils => Add a function to OB.App.PrintUtils to generate valid image tag for webUSB/HWM configurations
2022-03-16 12:55 guilleaer Description Updated View Revisions
2022-03-22 13:20 hgbot Resolution open => fixed
2022-03-22 13:20 hgbot Status scheduled => closed
2022-03-22 13:20 hgbot Fixed in Version => RR22Q2
2022-03-22 13:20 hgbot Note Added: 0135920
2022-03-22 13:20 hgbot Note Added: 0135921
2022-03-30 09:48 fermin_gascon Relationship added has duplicate 0048657


Copyright © 2000 - 2009 MantisBT Group
Powered by Mantis Bugtracker