upd
This commit is contained in:
+4
-3
@@ -1,3 +1,4 @@
|
||||
# VITE_SERVER_URL=http://localhost:3001
|
||||
# VITE_SERVER_URL=http://192.168.1.170:3001
|
||||
VITE_SERVER_URL=https://crm.stream.graff.tech/api
|
||||
# VITE_API_URL=http://localhost:3001
|
||||
# VITE_API_URL=http://192.168.1.170:3001
|
||||
VITE_API_URL=https://crm.stream.graff.tech/api
|
||||
VITE_STREAM_URL=https://stream.graff.tech
|
||||
|
||||
@@ -104,7 +104,10 @@ function Card({
|
||||
|
||||
<div className="flex gap-2">
|
||||
{manager && (
|
||||
<Link to={`http://localhost:5001/scheduled/${scheduledSessionId}`} target="_blank">
|
||||
<Link
|
||||
to={`${import.meta.env.VITE_STREAM_URL}/scheduled/${scheduledSessionId}`}
|
||||
target="_blank"
|
||||
>
|
||||
<Button>Начать</Button>
|
||||
</Link>
|
||||
)}
|
||||
@@ -119,7 +122,7 @@ function Card({
|
||||
</div>
|
||||
|
||||
<div className="absolute bottom-[2px] left-[272px] z-10">
|
||||
{availableManagers?.length && (
|
||||
{availableManagers && availableManagers.length > 0 && (
|
||||
<SelectUser
|
||||
shown={isShow}
|
||||
selectedManagerId={manager?.id}
|
||||
|
||||
@@ -24,7 +24,7 @@ function LoginPage() {
|
||||
setisLoading(true);
|
||||
|
||||
const result: any = await ky
|
||||
.post(import.meta.env.VITE_SERVER_URL + "/login", {
|
||||
.post(import.meta.env.VITE_API_URL + "/login", {
|
||||
json: {
|
||||
username,
|
||||
password,
|
||||
|
||||
@@ -2,7 +2,7 @@ import ky from "ky";
|
||||
import useAuthStore from "../stores/useAuthStore";
|
||||
|
||||
const api = ky.extend({
|
||||
prefixUrl: `${import.meta.env.VITE_SERVER_URL}`,
|
||||
prefixUrl: `${import.meta.env.VITE_API_URL}`,
|
||||
hooks: {
|
||||
beforeRequest: [
|
||||
(request) => {
|
||||
|
||||
@@ -9,7 +9,7 @@ export default ({ mode }) => {
|
||||
server: {
|
||||
proxy: {
|
||||
"/api": {
|
||||
target: process.env.VITE_SERVER_URL,
|
||||
target: process.env.VITE_API_URL,
|
||||
changeOrigin: true,
|
||||
rewrite: (path) => path.replace(/^\/api/, ""),
|
||||
},
|
||||
|
||||
Reference in New Issue
Block a user