From dce0e33693e3a73419fa0f982c72016fd5ce0a6d Mon Sep 17 00:00:00 2001 From: Esteban Date: Wed, 7 Jan 2026 00:20:52 -0600 Subject: [PATCH 1/2] Vite config tunnel and Enpoint changes --- src/api/concentrators.ts | 2 +- src/api/meters.ts | 2 +- src/api/projects.ts | 4 +--- vite.config.ts | 1 + 4 files changed, 4 insertions(+), 5 deletions(-) diff --git a/src/api/concentrators.ts b/src/api/concentrators.ts index 5f8034a..461fcba 100644 --- a/src/api/concentrators.ts +++ b/src/api/concentrators.ts @@ -1,5 +1,5 @@ const API_BASE_URL = import.meta.env.VITE_API_BASE_URL; -export const CONCENTRATORS_API_URL = `${API_BASE_URL}/api/v3/data/ppfu31vhv5gf6i0/mqqvi3woqdw5ziq/records`; +export const CONCENTRATORS_API_URL = `${API_BASE_URL}/api/v3/data/pirzzp3t8kclgo3/mheif1vdgnyt8x2/records`; const API_TOKEN = import.meta.env.VITE_API_TOKEN; const getAuthHeaders = () => ({ diff --git a/src/api/meters.ts b/src/api/meters.ts index b5f880b..bf1fe1a 100644 --- a/src/api/meters.ts +++ b/src/api/meters.ts @@ -1,5 +1,5 @@ const API_BASE_URL = import.meta.env.VITE_API_BASE_URL; -export const METERS_API_URL = `${API_BASE_URL}/api/v3/data/ppfu31vhv5gf6i0/mp1izvcpok5rk6s/records`; +export const METERS_API_URL = `${API_BASE_URL}/api/v3/data/pirzzp3t8kclgo3/m4hzpnopjkppaav/records`; const API_TOKEN = import.meta.env.VITE_API_TOKEN; const getAuthHeaders = () => ({ diff --git a/src/api/projects.ts b/src/api/projects.ts index 755cbec..a64054c 100644 --- a/src/api/projects.ts +++ b/src/api/projects.ts @@ -1,5 +1,5 @@ const API_BASE_URL = import.meta.env.VITE_API_BASE_URL; -export const PROJECTS_API_URL = `${API_BASE_URL}/api/v3/data/ppfu31vhv5gf6i0/m05u6wpquvdbv3c/records`; +export const PROJECTS_API_URL = `${API_BASE_URL}/api/v3/data/pirzzp3t8kclgo3/m9882vn3xb31e29/records`; const API_TOKEN = import.meta.env.VITE_API_TOKEN; export const getAuthHeaders = () => ({ @@ -125,7 +125,6 @@ export const createProject = async ( Operator: projectData.operator, "Installed Time": projectData.installedTime, "Communication Time": projectData.communicationTime, - "Instruction Manual": projectData.instructionManual, }, }), }); @@ -184,7 +183,6 @@ export const updateProject = async ( Operator: projectData.operator, "Installed Time": projectData.installedTime, "Communication Time": projectData.communicationTime, - "Instruction Manual": projectData.instructionManual, }, }), }); diff --git a/vite.config.ts b/vite.config.ts index ef01ba3..3ffb65d 100644 --- a/vite.config.ts +++ b/vite.config.ts @@ -11,6 +11,7 @@ export default defineConfig({ "localhost", "127.0.0.1", "reyna-compressive-shaunna.ngrok-free.dev", + "https://sistema.gestionrecursoshidricos.com/" ], port: 5173, }, From 8bb4942caf3d45327a035c20bc0e80c0819e51e7 Mon Sep 17 00:00:00 2001 From: Esteban Date: Wed, 7 Jan 2026 00:49:37 -0600 Subject: [PATCH 2/2] vite config fix --- vite.config.ts | 35 ++++++++++++++++++++++++----------- 1 file changed, 24 insertions(+), 11 deletions(-) diff --git a/vite.config.ts b/vite.config.ts index 3ffb65d..b29be24 100644 --- a/vite.config.ts +++ b/vite.config.ts @@ -1,18 +1,31 @@ import { defineConfig } from "vite"; import react from "@vitejs/plugin-react"; -import tailwindcss from "@tailwindcss/vite"; -// https://vitejs.dev/config/ +// https://vite.dev/config/ export default defineConfig({ - plugins: [react(), tailwindcss()], - + plugins: [ + react({ + jsxRuntime: 'automatic', + }) + ], server: { - allowedHosts: [ - "localhost", - "127.0.0.1", - "reyna-compressive-shaunna.ngrok-free.dev", - "https://sistema.gestionrecursoshidricos.com/" - ], + host: true, port: 5173, + allowedHosts: [ + 'sistema.gestionrecursoshidricos.com' + ], + hmr: { + overlay: true, + }, + // proxy:{ + // '/api':{ + // target: 'http://localhost:4000/', + // changeOrigin : true, + // secure: false, + // } + // } }, -}); + optimizeDeps: { + include: ['react', 'react-dom', 'react-router-dom'], + }, +}) \ No newline at end of file