fix: System Data from API fpr dev
This commit is contained in:
@@ -6,5 +6,5 @@
|
||||
2: Patch oder Hotfix (Bugfixes oder kleine Änderungen).
|
||||
|
||||
*/
|
||||
const webVersion = "1.6.224";
|
||||
const webVersion = "1.6.225";
|
||||
export default webVersion;
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
// /pages/api/cpl/systemSettingsAPIHandler.ts
|
||||
// /pages/api/cpl/systemAPIHandler.ts
|
||||
|
||||
import { NextApiRequest, NextApiResponse } from "next";
|
||||
import path from "path";
|
||||
@@ -1,12 +1,12 @@
|
||||
// /redux/thunks/fetchSystemSettingsThunk.ts
|
||||
import { createAsyncThunk } from "@reduxjs/toolkit";
|
||||
import { fetchSystemSettings } from "../../services/fetchSystemSettingsService";
|
||||
import { fetchSystemService } from "../../services/fetchSystemService";
|
||||
import { setSystemSettings } from "../slices/systemSettingsSlice";
|
||||
|
||||
export const fetchSystemSettingsThunk = createAsyncThunk(
|
||||
"systemSettings/fetch",
|
||||
async (_, { dispatch }) => {
|
||||
const data = await fetchSystemSettings();
|
||||
const data = await fetchSystemService();
|
||||
if (data) dispatch(setSystemSettings(data));
|
||||
}
|
||||
);
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
// /services/fetchSystemSettingsService.ts
|
||||
export const fetchSystemSettingsService = async () => {
|
||||
// /services/fetchSystemService.ts
|
||||
export const fetchSystemService = async () => {
|
||||
try {
|
||||
if (typeof window === "undefined") return null;
|
||||
|
||||
Reference in New Issue
Block a user