@denevads/dnv-smo 1.0.22 → 1.0.23

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@denevads/dnv-smo",
3
- "version": "1.0.22",
3
+ "version": "1.0.23",
4
4
  "description": "SMO module",
5
5
  "main": "./src/index.js",
6
6
  "types": "./src/index.d.ts",
package/src/smo.ts CHANGED
@@ -49,7 +49,7 @@ export class SMO {
49
49
  if(window.objJS){
50
50
  // @ts-ignore
51
51
  window.sendToIframefromNet = (target, iframeID, objData) => {
52
- console.log("sendToIframefromNet->",target);
52
+ console.log("sendToIframefromNet->",JSON.stringify(target));
53
53
  switch (target) {
54
54
  case "SMO.setDatasource":
55
55
  this.events.setDatasource.next(objData)
@@ -653,7 +653,7 @@ class Utils{
653
653
  return (rejsn.indexOf('"parsererror": {') == -1) ? rejsn : 'Invalid XML format';
654
654
  }
655
655
  sendToParent(obj:any,dest:string){
656
- console.log('sendToParent->',obj);
656
+ console.log('sendToParent->',JSON.stringify(obj));
657
657
  //@ts-ignore
658
658
  if(window.objJS){
659
659
  switch (obj.target) {
@@ -664,19 +664,19 @@ class Utils{
664
664
 
665
665
  case "Dnv.smoCallbacks.printTextLine":
666
666
  // @ts-ignore
667
- window.objJS.printTextLine(objData.txt);
667
+ window.objJS.printTextLine(obj.txt);
668
668
  break;
669
669
  case "Dnv.smoCallbacks.printBarcode":
670
670
  // @ts-ignore
671
- window.objJS.printBarcode(objData.code, objData.width, objData.height);
671
+ window.objJS.printBarcode(obj.code, obj.width, obj.height);
672
672
  break;
673
673
  case "Dnv.smoCallbacks.cutPaper":
674
674
  // @ts-ignore
675
- window.objJS.cutPaper(objData.percent);
675
+ window.objJS.cutPaper(obj.percent);
676
676
  break;
677
677
  case "Dnv.smoCallbacks.printImage":
678
678
  // @ts-ignore
679
- window.objJS.printImage(obj.idSmo, objData.image);
679
+ window.objJS.printImage(obj.idSmo, obj.image);
680
680
  break;
681
681
  case "Dnv.smoCallbacks.checkHealthPrinter":
682
682
  console.log('llamo a checkhealthprinter');