[.env update]

This commit is contained in:
2024-08-20 14:52:13 +05:30
parent 4516c70406
commit cfda3264fc
13 changed files with 22 additions and 17 deletions

View File

@@ -404,7 +404,7 @@ const FormField = ({
w={6}
h={6}
src={
" https://tanami.betadelivery.com/" +
import.meta.env.VITE_IMAGE_URL +
item?.logo
}
/>

View File

@@ -26,7 +26,7 @@ const ImageViewer = ({ src, isOpen, onClose }) => {
rounded={6}
w={"100%"}
h={"100%"}
src={"https://tanami.betadelivery.com/" + src}
src={import.meta.env.VITE_IMAGE_URL + src}
/>
</ModalBody>
</ModalContent>

View File

@@ -229,7 +229,7 @@ const filteredData = data?.data?.rows
colorScheme={"forestGreen"}
>
<Link
href={"https://tanami.betadelivery.com/" + item?.supporting_FileName}
href={import.meta.env.VITE_IMAGE_URL + item?.supporting_FileName}
isExternal
>
<Box

View File

@@ -180,7 +180,7 @@ const IOArtifacts = ({ enableNextTab, index, data }) => {
colorScheme={"forestGreen"}
>
<Link
href={"https://tanami.betadelivery.com/" + item?.artifactPathName}
href={import.meta.env.VITE_IMAGE_URL + item?.artifactPathName}
isExternal
>
<Box

View File

@@ -37,7 +37,7 @@ import SetDisplayOrder from "./SetDisplayOrder";
const downloadFile = (filePath, fileName) => {
fetch("https://tanami.betadelivery.com/" + filePath)
fetch(import.meta.env.VITE_IMAGE_URL+filePath)
.then((response) => {
if (!response.ok) {
throw new Error("Network response was not ok");

View File

@@ -135,7 +135,7 @@ const KeyMerits = ({ enableNextTab, index, data: prepopData }) => {
p={1}
justifyContent={"center"}
alignItems={"center"}
src={" https://tanami.betadelivery.com/" + item?.icon?.iconFilePath}
src={import.meta.env.VITE_IMAGE_URL+ item?.icon?.iconFilePath}
w={8}
h={8}
/>

View File

@@ -63,7 +63,7 @@ const SetDisplayOrder = ({ data }) => {
p={1}
justifyContent={"center"}
alignItems={"center"}
src={"https://tanami.betadelivery.com/" + item?.icon?.iconFilePath}
src={import.meta.env.VITE_IMAGE_URL + item?.icon?.iconFilePath}
w={8}
h={8}
/>

View File

@@ -260,7 +260,7 @@ const IOArtifactsAdd = ({
<Image
rounded={"md"}
src={
"https://tanami.betadelivery.com/" +
import.meta.env.VITE_IMAGE_URL +
watch()?.artifactPathName
}
alt="Image Preview"

View File

@@ -285,7 +285,7 @@ const KeyMeritsAdd = ({ isOpen, onClose, firstField, id, icons }) => {
>
<Box display="flex" alignItems="center">
{selectedImageIcon && <Image
src={`https://tanami.betadelivery.com/${selectedImageIcon}`}
src={`${import.meta.env.VITE_IMAGE_URL}${selectedImageIcon}`}
alt={selectedImageIcon}
boxSize="1rem"
mr="12px"
@@ -305,7 +305,7 @@ const KeyMeritsAdd = ({ isOpen, onClose, firstField, id, icons }) => {
>
<Box display="flex" alignItems="center">
<Image
src={`https://tanami.betadelivery.com/${iconFilePath}`}
src={`${import.meta.env.VITE_IMAGE_URL}${iconFilePath}`}
alt={iconName}
boxSize="1rem"
mr="12px"

View File

@@ -284,7 +284,7 @@ const KeyMeritsEdit = ({
>
<Box display="flex" alignItems="center">
{selectedImageIcon&&<Image
src={`https://tanami.betadelivery.com/${selectedImageIcon}`}
src={`${import.meta.env.VITE_IMAGE_URL}${selectedImageIcon}`}
alt={selectedImageIcon}
boxSize="1rem"
mr="12px"
@@ -304,7 +304,7 @@ const KeyMeritsEdit = ({
>
<Box display="flex" alignItems="center">
<Image
src={`https://tanami.betadelivery.com/${iconFilePath}`}
src={`${import.meta.env.VITE_IMAGE_URL}${iconFilePath}`}
alt={iconName}
boxSize="1rem"
mr="12px"

View File

@@ -51,6 +51,7 @@ const ViewIOdataHeader = ({data, isLoading}) => {
const btnRef = useRef();
const { IODetails, isIOloading } = useContext(GlobalStateContext);
const {
isOpen: isInvestmentOpen,
onOpen: onInvestmentOpen,
@@ -104,6 +105,10 @@ const ViewIOdataHeader = ({data, isLoading}) => {
};
console.log(import.meta.env.VITE_IMAGE_URL +
IODetails?.artifactsImage?.[0]?.artifactPathName);
const menu = [
{
@@ -208,7 +213,7 @@ const filteredMenu = menu?.filter(item => apiTransactionTitles?.includes(item.id
w={"100%"}
objectFit={"cover"}
src={
" https://tanami.betadelivery.com/" +
import.meta.env.VITE_IMAGE_URL +
IODetails?.artifactsImage?.[0]?.artifactPathName
}
alt={IODetails?.ioName}

View File

@@ -3,7 +3,7 @@ import axios from "axios";
// Create an Axios instance for API calls
export const api = axios.create({
// baseURL: `https://tanami.betadelivery.com/api/v1`,
baseURL: `https://sprint4.tanami.betadelivery.com/api/v1`, // Replace with your API base URL
baseURL: import.meta.env.VITE_BAS_URL, // Replace with your API base URL
timeout: 10000, // Adjust timeout as needed
headers: {
"Content-Type": "application/json",

View File

@@ -15,7 +15,7 @@ import { createApi, fetchBaseQuery } from "@reduxjs/toolkit/query/react";
// Define a base query function with token refresh logic
export const baseQuery = async (args, api, extraOptions) => {
let result = await fetchBaseQuery({
baseUrl: "https://sprint4.tanami.betadelivery.com/api/v1",
baseUrl: import.meta.env.VITE_BAS_URL,
prepareHeaders: (headers) => {
const token = localStorage.getItem("accessToken");
if (token) {
@@ -31,7 +31,7 @@ export const baseQuery = async (args, api, extraOptions) => {
if (refreshToken) {
try {
const refreshResult = await fetchBaseQuery({
baseUrl: "https://sprint4.tanami.betadelivery.com/api/v1",
baseUrl: import.meta.env.VITE_BAS_URL,
})(
{
url: "/auth/user/regenerate-token",
@@ -56,7 +56,7 @@ export const baseQuery = async (args, api, extraOptions) => {
// Retry the original request with the new token
result = await fetchBaseQuery({
baseUrl: "https://sprint4.tanami.betadelivery.com/api/v1",
baseUrl: import.meta.env.VITE_BAS_URL,
prepareHeaders: (headers) => {
const token = localStorage.getItem("accessToken");
if (token) {