Added Dockerfile and CI/CD for Imapsync

Added Core Functionality for Imapsync
This commit is contained in:
2023-11-29 19:52:37 +01:00
parent ff966418b2
commit d74d7abc90
574 changed files with 956 additions and 89559 deletions

View File

@@ -2,7 +2,11 @@
import * as JSPM from 'jsprintmanager'
let printers = []
let scanners = []
const doScanning = () => {
}
const doPrintZPL = () => {
/*if(this.selected_printer === '' && !this.print2default) {
@@ -44,6 +48,18 @@ const getPrinters = () => {
} else { console.warn("JSPM WS not open"); ok(printers); }
});
}
const getScanners = () => {
return new Promise((ok, err) => {
let scanners = [];
if(JSPM.JSPrintManager.websocket_status === JSPM.WSStatus.Open) {
JSPM.JSPrintManager.getScanners().then(function (myScanners) {
printers = myScanners;
console.log(scanners);
ok(scanners);
}).catch((e)=>err(e));
} else { console.warn("JSPM WS not open"); ok(printers); }
});
}
const initJSPM = () => {
JSPM.JSPrintManager.auto_reconnect = true
JSPM.JSPrintManager.start();
@@ -51,6 +67,8 @@ const initJSPM = () => {
JSPM.JSPrintManager.WS.onStatusChanged = () => {
console.log("Status Changed")
getPrinters().then(p => printers = p)
getScanners().then(s => scanners = s)
}
}
initJSPM()
@@ -58,6 +76,7 @@ initJSPM()
<template>
{{printers}}
{{scanners}}
<UButton @click="doPrintZPL">Print</UButton>