diff --git a/app/build.gradle b/app/build.gradle index 8912a88..2443cef 100644 --- a/app/build.gradle +++ b/app/build.gradle @@ -8,8 +8,8 @@ android { applicationId "com.streamplayer" minSdk 21 targetSdk 33 - versionCode 94000 - versionName "9.4.0" + versionCode 94100 + versionName "9.4.1" buildConfigField "String", "DEVICE_REGISTRY_URL", '"http://194.163.191.200:4000"' } diff --git a/app/src/main/java/com/streamplayer/PlayerActivity.java b/app/src/main/java/com/streamplayer/PlayerActivity.java index f9f14b0..dc60596 100644 --- a/app/src/main/java/com/streamplayer/PlayerActivity.java +++ b/app/src/main/java/com/streamplayer/PlayerActivity.java @@ -4,6 +4,7 @@ import android.content.Intent; import android.os.Bundle; import android.os.StrictMode; import android.view.View; +import android.view.WindowManager; import android.widget.Button; import android.widget.ProgressBar; import android.widget.TextView; @@ -58,6 +59,7 @@ public class PlayerActivity extends AppCompatActivity { ); setContentView(R.layout.activity_player); + getWindow().addFlags(WindowManager.LayoutParams.FLAG_KEEP_SCREEN_ON); Intent intent = getIntent(); if (intent == null) { @@ -254,6 +256,7 @@ public class PlayerActivity extends AppCompatActivity { protected void onDestroy() { super.onDestroy(); releasePlayer(); + getWindow().clearFlags(WindowManager.LayoutParams.FLAG_KEEP_SCREEN_ON); } private void toggleOverlay() { diff --git a/dashboard/data/devices.json b/dashboard/data/devices.json index c140778..96b7bae 100644 --- a/dashboard/data/devices.json +++ b/dashboard/data/devices.json @@ -6,22 +6,21 @@ "model": "SM-S928B", "manufacturer": "Samsung", "osVersion": "16 (API 36)", - "appVersionName": "9.3.1", - "appVersionCode": 93100, - "firstSeen": "2025-11-23T20:53:43.615Z", - "lastSeen": "2025-11-23T21:57:09.997Z", + "appVersionName": "9.4.0", + "appVersionCode": 94000, + "firstSeen": "2025-11-23T22:31:13.359Z", + "lastSeen": "2025-11-23T23:04:39.871Z", "blocked": false, - "notes": "no pagó", - "installs": 14, - "blockedAt": "2025-11-23T20:54:05.413Z", + "notes": "", + "installs": 3, "ip": "181.23.253.20", "country": "AR", "verification": { - "clientPart": "6e05a220abe0ed05", - "adminPart": "19d6ee4c992ee1a0", + "clientPart": "1714c2bb93670c3f", + "adminPart": "9924c7049211c58c", "status": "verified", - "createdAt": "2025-11-23T21:09:04.607Z", - "verifiedAt": "2025-11-23T21:57:05.081Z" + "createdAt": "2025-11-23T22:31:13.359Z", + "verifiedAt": "2025-11-23T22:33:11.942Z" } } ] \ No newline at end of file diff --git a/dashboard/public/app.js b/dashboard/public/app.js index 1febcb1..8c9e0f0 100644 --- a/dashboard/public/app.js +++ b/dashboard/public/app.js @@ -45,6 +45,7 @@ function renderTable(devices) { actions.push(''); } actions.push(device.blocked ? '' : ''); + actions.push(''); tr.innerHTML = ` @@ -97,6 +98,19 @@ async function unblockDevice(deviceId) { await fetchDevices(); } +async function deleteDevice(deviceId) { + const confirmation = confirm('¿Seguro que quieres borrar este dispositivo? Generará un nuevo token cuando se registre de nuevo.'); + if (!confirmation) { + return; + } + const response = await fetch(`/api/devices/${encodeURIComponent(deviceId)}`, { method: 'DELETE' }); + if (!response.ok) { + alert('No se pudo borrar el dispositivo'); + return; + } + await fetchDevices(); +} + async function verifyDevice(deviceId) { const clientTokenPart = prompt('Introduce el token que aparece en el dispositivo:'); if (clientTokenPart === null) { @@ -154,6 +168,8 @@ tableBody.addEventListener('click', async (event) => { await updateAlias(deviceId); } else if (action === 'verify') { await verifyDevice(deviceId); + } else if (action === 'delete') { + await deleteDevice(deviceId); } } catch (error) { console.error(error); diff --git a/update-manifest.json b/update-manifest.json index 1fc9cdc..27f3630 100644 --- a/update-manifest.json +++ b/update-manifest.json @@ -1,10 +1,10 @@ { - "versionCode": 93100, - "versionName": "9.3.1", + "versionCode": 94000, + "versionName": "9.4.0", "minSupportedVersionCode": 91000, "forceUpdate": false, - "downloadUrl": "https://gitea.cbcren.online/renato97/app/releases/download/v9.3.1/StreamPlayer-v9.3.1.apk", - "fileName": "StreamPlayer-v9.3.1.apk", - "sizeBytes": 5943075, - "notes": "StreamPlayer v9.3.1\n\nMejoras en esta versión:\n\n- Interfaz de usuario mejorada con nuevos controles\n- Funcionalidad de copiado mejorada\n- Diálogos más intuitivos y fáciles de usar\n- Mejor retroalimentación para el usuario\n- Configuración optimizada para mejor funcionamiento\n- Mayor estabilidad general de la aplicación\n- Correcciones menores de usabilidad\n\nEsta actualización mejora la experiencia de uso y facilita la interacción con las funcionalidades de verificación y seguridad." + "downloadUrl": "https://gitea.cbcren.online/renato97/app/releases/download/v9.4.0/StreamPlayer-v9.4.0.apk", + "fileName": "StreamPlayer-v9.4.0.apk", + "sizeBytes": 5944530, + "notes": "StreamPlayer v9.4.0\n\nMejoras significativas en esta versión:\n\n- Sistema de gestión remota completamente integrado\n- Interfaz de usuario rediseñada para mayor facilidad de uso\n- Diálogos interactivos con controles mejorados\n- Sistema de verificación optimizado y más accesible\n- Mejoras en la retroalimentación visual del usuario\n- Mayor accesibilidad en procesos de verificación\n- Optimización general del rendimiento\n- Mejor respuesta y tiempo de carga\n\nEsta actualización transforma la experiencia de gestión con controles remotos avanzados y una interfaz mucho más intuitiva." }