Merge pull request #801 from alnviana/patch-1
Some checks are pending
docker / docker_dev (push) Waiting to run

Fixes to work using a reverse proxy
This commit is contained in:
jokob-sk
2024-09-23 11:25:39 +10:00
committed by GitHub
3 changed files with 4 additions and 4 deletions

View File

@@ -17,7 +17,7 @@ showSpinner()
$(document).ready(function() { $(document).ready(function() {
// Load JSON data from the provided URL // Load JSON data from the provided URL
$.getJSON('/api/table_appevents.json', function(data) { $.getJSON('api/table_appevents.json', function(data) {
// Process the JSON data and generate UI dynamically // Process the JSON data and generate UI dynamically
processData(data) processData(data)

View File

@@ -99,7 +99,7 @@
// Function to update the displayed data and timestamp based on the selected format and index // Function to update the displayed data and timestamp based on the selected format and index
function updateData(format, index) { function updateData(format, index) {
// Fetch data from the API endpoint // Fetch data from the API endpoint
fetch('/api/table_notifications.json?nocache=' + Date.now()) fetch('api/table_notifications.json?nocache=' + Date.now())
.then(response => response.json()) .then(response => response.json())
.then(data => { .then(data => {
if (index < 0) { if (index < 0) {
@@ -163,7 +163,7 @@
const urlParams = new URLSearchParams(window.location.search); const urlParams = new URLSearchParams(window.location.search);
if (urlParams.has('guid')) { if (urlParams.has('guid')) {
const guid = urlParams.get('guid'); const guid = urlParams.get('guid');
fetch('/api/table_notifications.json') fetch('api/table_notifications.json')
.then(response => response.json()) .then(response => response.json())
.then(data => { .then(data => {
const index = findIndexByGUID(data.data, guid); const index = findIndexByGUID(data.data, guid);

View File

@@ -60,7 +60,7 @@ require 'php/templates/header.php';
<script> <script>
function fetchData(callback) { function fetchData(callback) {
$.ajax({ $.ajax({
url: '/api/user_notifications.json?nocache=' + Date.now(), url: 'api/user_notifications.json?nocache=' + Date.now(),
method: 'GET', method: 'GET',
dataType: 'json', dataType: 'json',
success: function(response) { success: function(response) {