Skip to content
Merged

Dev #160

Show file tree
Hide file tree
Changes from 2 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 6 additions & 2 deletions ui/src/components/Modal/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -18,8 +18,9 @@ import { Field as FinalField, Form as FinalForm } from 'react-final-form';
import { ProjectModalProps } from './modal.interface';

// Services
import { createProject } from '../../services/api/project.service';
import { useState } from 'react';
import { createProject } from '../../services/api/project.service';


const Modal = (props: ProjectModalProps) => {
const {
Expand All @@ -42,7 +43,10 @@ const Modal = (props: ProjectModalProps) => {
// const payload = {name: values?.name, description: values?.description || ''}

const res = await createProject(selectedOrg?.uid || '', values);

if (res?.status === 201) {
const projectId = res?.data?.project?.id
window.location.href = `/projects/${projectId}/migration/steps/1`;
}
return res?.error ? false : res;
};

Expand Down
2 changes: 1 addition & 1 deletion uplaode-api/.env
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
PORT=4002
NODE_BACKEND_API =http://localhost:5001
NODE_BACKEND_API =http://localhost:5000
4 changes: 2 additions & 2 deletions uplaode-api/src/config/index.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
export default {
cmsType: 'sitecore',
cmsType: 'Sitecore',
isLocalPath: true,
awsData: {
awsRegion: 'us-east-2',
Expand All @@ -9,5 +9,5 @@ export default {
bucketName: 'migartion-test',
buketKey: 'project/package 45.zip'
},
localPath: '/Users/umesh.more/Downloads/package 45.zip'
localPath: '/Users/snehal.pimple/Desktop/package 45.zip'
};