feat: Add poblacion_apta service to docker-compose, enhance API gateway for new service integration, and update README with service details. Introduce new database tables for poblacion_apta_jobs and poblacion_apta_rows, and implement functionality for handling cop/mod calculations in the cleaning service.
This commit is contained in:
@@ -65,6 +65,25 @@ ipcMain.handle("updater:install", async (_event, manifest) => {
|
||||
return autoUpdate.downloadAndInstall(manifest, sendUpdateProgress);
|
||||
});
|
||||
|
||||
ipcMain.handle("net:download-url", async (event, urlStr) => {
|
||||
const raw = String(urlStr || "").trim();
|
||||
let parsed;
|
||||
try {
|
||||
parsed = new URL(raw);
|
||||
} catch {
|
||||
throw new Error("URL de descarga inválida");
|
||||
}
|
||||
if (parsed.protocol !== "http:" && parsed.protocol !== "https:") {
|
||||
throw new Error("Solo se permiten descargas http(s)");
|
||||
}
|
||||
const win = BrowserWindow.fromWebContents(event.sender) || mainWindow;
|
||||
if (!win || win.isDestroyed()) {
|
||||
throw new Error("Ventana no disponible para iniciar la descarga");
|
||||
}
|
||||
win.webContents.downloadURL(parsed.toString());
|
||||
return { ok: true };
|
||||
});
|
||||
|
||||
app.whenReady().then(() => {
|
||||
if (process.platform === "win32") {
|
||||
app.setAppUserModelId("com.ipsextractor.desktop");
|
||||
|
||||
Reference in New Issue
Block a user