changed crypto to uuid as crypto not working in non secure area

main
alex 2023-06-28 00:40:57 +02:00
parent 85f3559862
commit 6c691e243a
2 changed files with 14 additions and 6 deletions

View File

@ -10,7 +10,11 @@ import {
Tag, Tag,
notification, notification,
} from "antd"; } from "antd";
import { WebSocketContext, SentMessagesCommands } from "../../../utils"; import {
WebSocketContext,
SentMessagesCommands,
GetUuid,
} from "../../../utils";
import { useContext } from "react"; import { useContext } from "react";
import { InfoCircleOutlined } from "@ant-design/icons"; import { InfoCircleOutlined } from "@ant-design/icons";
import TextArea from "antd/es/input/TextArea"; import TextArea from "antd/es/input/TextArea";
@ -123,7 +127,7 @@ export default function GroupTypeSelectionModal({
} }
}); });
const rememberId = window.crypto.randomUUID(); const rememberId = GetUuid();
webSocketContext.StartGroupTasksOpenModalRememberIdRef.current = rememberId; webSocketContext.StartGroupTasksOpenModalRememberIdRef.current = rememberId;

View File

@ -15,9 +15,9 @@ export const Constants = {
ICON_INFO: "#08c", ICON_INFO: "#08c",
}, },
TEXT_EMPTY_PLACEHOLDER: "-/-", TEXT_EMPTY_PLACEHOLDER: "-/-",
API_ADDRESS: "http://localhost:8080/v1", API_ADDRESS: "http://84.118.101.110:58659/api/v1",
STATIC_CONTENT_ADDRESS: "http://localhost:8080/", STATIC_CONTENT_ADDRESS: "http://84.118.101.110:58659/",
WS_ADDRESS: "ws://localhost:8080/ws", WS_ADDRESS: "ws://84.118.101.110:58659/api/ws",
ROUTE_PATHS: { ROUTE_PATHS: {
GROUP_TASKS: "/group-tasks", GROUP_TASKS: "/group-tasks",
GROUP_TASKS_VIEW: "/group-tasks/", GROUP_TASKS_VIEW: "/group-tasks/",
@ -80,7 +80,11 @@ export const Constants = {
This ID is needed because the message is sent to all clients connected to the backend server when a task is locked and unlocked. This ID is needed because the message is sent to all clients connected to the backend server when a task is locked and unlocked.
With this ID the client checks if the respective browser tab of the user is the initiator of the lock. With this ID the client checks if the respective browser tab of the user is the initiator of the lock.
*/ */
export const GroupTasksStepsLockedAndUserUpdateInputValueRememberId = uuidv4(); export const GroupTasksStepsLockedAndUserUpdateInputValueRememberId = GetUuid();
export function GetUuid() {
return uuidv4();
}
/** /**
* user session * user session