diff --git a/src/apps/companies/apps/company-overview/client/CompanyOverview.jsx b/src/client/modules/Companies/CompanyOverview/CompanyOverview.jsx similarity index 88% rename from src/apps/companies/apps/company-overview/client/CompanyOverview.jsx rename to src/client/modules/Companies/CompanyOverview/CompanyOverview.jsx index 266fe8dd9d2..f155b92e7bb 100644 --- a/src/apps/companies/apps/company-overview/client/CompanyOverview.jsx +++ b/src/client/modules/Companies/CompanyOverview/CompanyOverview.jsx @@ -10,10 +10,10 @@ import { BusinessDetailsCard, ExportStatusCard, InvestmentStatusCard, -} from '../overview-table-cards' -import { FILTER_FEED_TYPE } from '../../activity-feed/constants' -import { CompanyResource } from '../../../../../client/components/Resource/index' -import CompanyLayoutNew from '../../../../../client/components/Layout/CompanyLayoutNew' +} from './TableCards' +import { FILTER_FEED_TYPE } from '../../../../apps/companies/apps/activity-feed/constants' +import { CompanyResource } from '../../../components/Resource/index' +import CompanyLayoutNew from '../../../components/Layout/CompanyLayoutNew' const CardContainer = styled('div')` border: 1px solid #b1b4b6; diff --git a/src/apps/companies/apps/company-overview/overview-table-cards/AccountManagementCard.jsx b/src/client/modules/Companies/CompanyOverview/TableCards/AccountManagementCard.jsx similarity index 96% rename from src/apps/companies/apps/company-overview/overview-table-cards/AccountManagementCard.jsx rename to src/client/modules/Companies/CompanyOverview/TableCards/AccountManagementCard.jsx index d7a90ab8bf6..71d5a36151f 100644 --- a/src/apps/companies/apps/company-overview/overview-table-cards/AccountManagementCard.jsx +++ b/src/client/modules/Companies/CompanyOverview/TableCards/AccountManagementCard.jsx @@ -4,8 +4,8 @@ import PropTypes from 'prop-types' import styled from 'styled-components' import pluralize from 'pluralize' -import { SummaryTable } from '../../../../../client/components' -import { isItaTierDAccount } from '../../../../../client/modules/Companies/utils' +import { SummaryTable } from '../../../../components' +import { isItaTierDAccount } from '../../utils' import urls from '../../../../../lib/urls' import { buildCellContents } from './transformers' import { diff --git a/src/apps/companies/apps/company-overview/overview-table-cards/ActiveInvestmentProjectsCard.jsx b/src/client/modules/Companies/CompanyOverview/TableCards/ActiveInvestmentProjectsCard.jsx similarity index 98% rename from src/apps/companies/apps/company-overview/overview-table-cards/ActiveInvestmentProjectsCard.jsx rename to src/client/modules/Companies/CompanyOverview/TableCards/ActiveInvestmentProjectsCard.jsx index 33f1108e5a5..5d0a2378170 100644 --- a/src/apps/companies/apps/company-overview/overview-table-cards/ActiveInvestmentProjectsCard.jsx +++ b/src/client/modules/Companies/CompanyOverview/TableCards/ActiveInvestmentProjectsCard.jsx @@ -6,9 +6,9 @@ import { connect } from 'react-redux' import { kebabCase } from 'lodash' import { companies, investments } from '../../../../../lib/urls' -import { Tag } from '../../../../../client/components' +import { Tag } from '../../../../components' import { companyProjectsState2props } from './state' -import { BLUE, GREY_2 } from '../../../../../client/utils/colours' +import { BLUE, GREY_2 } from '../../../../utils/colours' import { buildCellContents } from './transformers' import { StyledSummaryTable, StyledTableRow } from './components' diff --git a/src/apps/companies/apps/company-overview/overview-table-cards/ActivityCard.jsx b/src/client/modules/Companies/CompanyOverview/TableCards/ActivityCard.jsx similarity index 88% rename from src/apps/companies/apps/company-overview/overview-table-cards/ActivityCard.jsx rename to src/client/modules/Companies/CompanyOverview/TableCards/ActivityCard.jsx index 89889bf46df..3ad8ae4fcc0 100644 --- a/src/apps/companies/apps/company-overview/overview-table-cards/ActivityCard.jsx +++ b/src/client/modules/Companies/CompanyOverview/TableCards/ActivityCard.jsx @@ -4,15 +4,15 @@ import PropTypes from 'prop-types' import camelCase from 'camelcase' import styled from 'styled-components' -import { ActivityFeedApp, SummaryTable } from '../../../../../client/components' +import { ActivityFeedApp, SummaryTable } from '../../../../components' import { companies } from '../../../../../lib/urls' -import CompanyActivityFeed from '../../activity-feed/client/CompanyActivityFeed' +import CompanyActivityFeed from '../../../../../apps/companies/apps/activity-feed/client/CompanyActivityFeed' import { StyledLastTableCell, StyledTableCell, StyledTableRow, } from './components' -import { FILTER_KEYS } from '../../activity-feed/constants' +import { FILTER_KEYS } from '../../../../../apps/companies/apps/activity-feed/constants' const StyledSummaryTable = styled(SummaryTable)` margin: 0; diff --git a/src/apps/companies/apps/company-overview/overview-table-cards/BusinessDetailsCard.jsx b/src/client/modules/Companies/CompanyOverview/TableCards/BusinessDetailsCard.jsx similarity index 95% rename from src/apps/companies/apps/company-overview/overview-table-cards/BusinessDetailsCard.jsx rename to src/client/modules/Companies/CompanyOverview/TableCards/BusinessDetailsCard.jsx index 2136173d4f8..12326cf65d5 100644 --- a/src/apps/companies/apps/company-overview/overview-table-cards/BusinessDetailsCard.jsx +++ b/src/client/modules/Companies/CompanyOverview/TableCards/BusinessDetailsCard.jsx @@ -4,8 +4,8 @@ import PropTypes from 'prop-types' import styled from 'styled-components' import { UNITED_KINGDOM_ID } from '../../../../../common/constants' -import { NewWindowLink, SummaryTable } from '../../../../../client/components' -import { currencyGBP } from '../../../../../client/utils/number-utils' +import { NewWindowLink, SummaryTable } from '../../../../components' +import { currencyGBP } from '../../../../utils/number-utils' import urls from '../../../../../lib/urls' import { buildCellContents } from './transformers' import { diff --git a/src/apps/companies/apps/company-overview/overview-table-cards/ExportStatusCard.jsx b/src/client/modules/Companies/CompanyOverview/TableCards/ExportStatusCard.jsx similarity index 96% rename from src/apps/companies/apps/company-overview/overview-table-cards/ExportStatusCard.jsx rename to src/client/modules/Companies/CompanyOverview/TableCards/ExportStatusCard.jsx index b41c721adb4..cb2286d3eda 100644 --- a/src/apps/companies/apps/company-overview/overview-table-cards/ExportStatusCard.jsx +++ b/src/client/modules/Companies/CompanyOverview/TableCards/ExportStatusCard.jsx @@ -5,16 +5,16 @@ import styled from 'styled-components' import { connect } from 'react-redux' import { kebabCase } from 'lodash' -import { SummaryTable, Tag } from '../../../../../client/components' -import Task from '../../../../../client/components/Task' +import { SummaryTable, Tag } from '../../../../components' +import Task from '../../../../components/Task' import { TASK_GET_LATEST_EXPORT_WINS, OVERVIEW_COMPANY_EXPORT_WINS_LIST_ID, exportWinsState2props, } from './state' -import { OVERVIEW__EXPORT_WINS_SUMMARY } from '../../../../../client/actions' -import { format } from '../../../../../client/utils/date' -import { transformExportCountries } from '../../exports/transformer' +import { OVERVIEW__EXPORT_WINS_SUMMARY } from '../../../../actions' +import { format } from '../../../../utils/date' +import { transformExportCountries } from '../../../../../apps/companies/apps/exports/transformer' import { companies } from '../../../../../lib/urls' import { buildCellContents } from './transformers' import { diff --git a/src/apps/companies/apps/company-overview/overview-table-cards/InvestmentStatusCard.jsx b/src/client/modules/Companies/CompanyOverview/TableCards/InvestmentStatusCard.jsx similarity index 95% rename from src/apps/companies/apps/company-overview/overview-table-cards/InvestmentStatusCard.jsx rename to src/client/modules/Companies/CompanyOverview/TableCards/InvestmentStatusCard.jsx index b96d31cd934..9ede240db0d 100644 --- a/src/apps/companies/apps/company-overview/overview-table-cards/InvestmentStatusCard.jsx +++ b/src/client/modules/Companies/CompanyOverview/TableCards/InvestmentStatusCard.jsx @@ -3,15 +3,15 @@ import { Link } from 'govuk-react' import PropTypes from 'prop-types' import { connect } from 'react-redux' -import { SummaryTable } from '../../../../../client/components' +import { SummaryTable } from '../../../../components' import { TASK_GET_PROJECT_WON_COUNT, OVERVIEW_COMPANY_PROJECTS_LIST_ID, companyProjectsState2props, } from './state' -import { OVERVIEW__COMPANY_INVESTMENT_WON_COUNT } from '../../../../../client/actions' +import { OVERVIEW__COMPANY_INVESTMENT_WON_COUNT } from '../../../../actions' import urls from '../../../../../lib/urls' -import Task from '../../../../../client/components/Task' +import Task from '../../../../components/Task' import { StyledLastTableCell, StyledSpan, @@ -19,7 +19,7 @@ import { StyledTableRow, } from './components' -const { format } = require('../../../../../client/utils/date') +const { format } = require('../../../../utils/date') const buildProjectStatusUrl = (companyId, param) => urls.companies.investments.companyInvestmentProjects(companyId) + param diff --git a/src/apps/companies/apps/company-overview/overview-table-cards/components.jsx b/src/client/modules/Companies/CompanyOverview/TableCards/components.jsx similarity index 81% rename from src/apps/companies/apps/company-overview/overview-table-cards/components.jsx rename to src/client/modules/Companies/CompanyOverview/TableCards/components.jsx index 30d80bbd1f1..c0ff10828af 100644 --- a/src/apps/companies/apps/company-overview/overview-table-cards/components.jsx +++ b/src/client/modules/Companies/CompanyOverview/TableCards/components.jsx @@ -5,8 +5,8 @@ import styled from 'styled-components' import { Table } from 'govuk-react' -import { SummaryTable } from '../../../../../client/components' -import { GREY_1 } from '../../../../../client/utils/colours' +import { SummaryTable } from '../../../../components' +import { GREY_1 } from '../../../../utils/colours' export const StyledTableCell = styled(Table.Cell)` border: 0; diff --git a/src/apps/companies/apps/company-overview/overview-table-cards/exportStatusReducer.js b/src/client/modules/Companies/CompanyOverview/TableCards/exportStatusReducer.js similarity index 81% rename from src/apps/companies/apps/company-overview/overview-table-cards/exportStatusReducer.js rename to src/client/modules/Companies/CompanyOverview/TableCards/exportStatusReducer.js index f9cc4ee7d6a..6915c0aed58 100644 --- a/src/apps/companies/apps/company-overview/overview-table-cards/exportStatusReducer.js +++ b/src/client/modules/Companies/CompanyOverview/TableCards/exportStatusReducer.js @@ -1,4 +1,4 @@ -import { OVERVIEW__EXPORT_WINS_SUMMARY } from '../../../../../client/actions' +import { OVERVIEW__EXPORT_WINS_SUMMARY } from '../../../../actions' const initialState = { results: [], diff --git a/src/apps/companies/apps/company-overview/overview-table-cards/index.jsx b/src/client/modules/Companies/CompanyOverview/TableCards/index.jsx similarity index 100% rename from src/apps/companies/apps/company-overview/overview-table-cards/index.jsx rename to src/client/modules/Companies/CompanyOverview/TableCards/index.jsx diff --git a/src/apps/companies/apps/company-overview/overview-table-cards/reducer.js b/src/client/modules/Companies/CompanyOverview/TableCards/reducer.js similarity index 95% rename from src/apps/companies/apps/company-overview/overview-table-cards/reducer.js rename to src/client/modules/Companies/CompanyOverview/TableCards/reducer.js index 6a33a4d6b85..4d7289362b8 100644 --- a/src/apps/companies/apps/company-overview/overview-table-cards/reducer.js +++ b/src/client/modules/Companies/CompanyOverview/TableCards/reducer.js @@ -1,7 +1,7 @@ import { camelCase } from 'lodash' -import { OVERVIEW__COMPANY_INVESTMENT_WON_COUNT } from '../../../../../client/actions' -import { STAGE_ACTIVE } from '../../../../../client/modules/Investments/Projects/constants' +import { OVERVIEW__COMPANY_INVESTMENT_WON_COUNT } from '../../../../actions' +import { STAGE_ACTIVE } from '../../../Investments/Projects/constants' const initialState = { results: [], diff --git a/src/apps/companies/apps/company-overview/overview-table-cards/state.js b/src/client/modules/Companies/CompanyOverview/TableCards/state.js similarity index 86% rename from src/apps/companies/apps/company-overview/overview-table-cards/state.js rename to src/client/modules/Companies/CompanyOverview/TableCards/state.js index e04f9ea5777..93fadc211b2 100644 --- a/src/apps/companies/apps/company-overview/overview-table-cards/state.js +++ b/src/client/modules/Companies/CompanyOverview/TableCards/state.js @@ -1,5 +1,5 @@ -import { SORT_OPTIONS } from '../../../../../client/modules/Contacts/CollectionList/constants' -import { parseQueryString } from '../../../../../client/utils' +import { SORT_OPTIONS } from '../../../Contacts/CollectionList/constants' +import { parseQueryString } from '../../../../utils' export const OVERVIEW_COMPANY_PROJECTS_LIST_ID = 'overviewCompanyProjectsList' export const TASK_GET_PROJECT_WON_COUNT = 'TASK_GET_PROJECT_WON_COUNT' diff --git a/src/apps/companies/apps/company-overview/overview-table-cards/tasks.js b/src/client/modules/Companies/CompanyOverview/TableCards/tasks.js similarity index 86% rename from src/apps/companies/apps/company-overview/overview-table-cards/tasks.js rename to src/client/modules/Companies/CompanyOverview/TableCards/tasks.js index 34e2295504c..1f366da3d18 100644 --- a/src/apps/companies/apps/company-overview/overview-table-cards/tasks.js +++ b/src/client/modules/Companies/CompanyOverview/TableCards/tasks.js @@ -1,7 +1,7 @@ import axios from 'axios' -import { apiProxyAxios } from '../../../../../client/components/Task/utils' -import { NOT_IMPLEMENTED } from '../../exports/client/ExportWins/state' +import { apiProxyAxios } from '../../../../components/Task/utils' +import { NOT_IMPLEMENTED } from '../../../../../apps/companies/apps/exports/client/ExportWins/state' export const getProjectsWon = async ({ companyId }) => { return await apiProxyAxios diff --git a/src/apps/companies/apps/company-overview/overview-table-cards/transformers.js b/src/client/modules/Companies/CompanyOverview/TableCards/transformers.js similarity index 100% rename from src/apps/companies/apps/company-overview/overview-table-cards/transformers.js rename to src/client/modules/Companies/CompanyOverview/TableCards/transformers.js diff --git a/src/client/reducers.js b/src/client/reducers.js index 8b34ae01f3f..0e06712df9d 100644 --- a/src/client/reducers.js +++ b/src/client/reducers.js @@ -49,12 +49,12 @@ import { import { OVERVIEW_COMPANY_EXPORT_WINS_LIST_ID, OVERVIEW_COMPANY_PROJECTS_LIST_ID, -} from '../apps/companies/apps/company-overview/overview-table-cards/state' +} from './modules/Companies/CompanyOverview/TableCards/state.js' import investmentProjectsReducer from './modules/Investments/Projects/reducer' import investmentProjectReducer from './modules/Investments/Projects/investmentProjectReducer' -import overviewInvestmentProjectReducer from '../apps/companies/apps/company-overview/overview-table-cards/reducer' -import overviewExportWinsReducer from '../apps/companies/apps/company-overview/overview-table-cards/exportStatusReducer' +import overviewInvestmentProjectReducer from './modules/Companies/CompanyOverview/TableCards/reducer.js' +import overviewExportWinsReducer from './modules/Companies/CompanyOverview/TableCards/exportStatusReducer.js' import { ID as COMPANIES_ID } from './modules/Companies/CollectionList/state' import companiesReducer from './modules/Companies/CollectionList/reducer' diff --git a/src/client/routes.js b/src/client/routes.js index 76932f24881..4f00c04146e 100644 --- a/src/client/routes.js +++ b/src/client/routes.js @@ -81,7 +81,7 @@ import SelectOrderCompany from './modules/Omis/CreateOrder/CompanySelect' import CreateOrder from './modules/Omis/CreateOrder/CreateOrder' import PaymentReceipt from './modules/Omis/PaymentReceipt' import { TaskFormAdd, TaskFormEdit } from './modules/Tasks/TaskForm' -import CompanyOverview from '../apps/companies/apps/company-overview/client/CompanyOverview' +import CompanyOverview from './modules/Companies/CompanyOverview/CompanyOverview' const routes = { companies: [ diff --git a/src/client/tasks.js b/src/client/tasks.js index 8e0a448f03c..9a4f1ef6aa2 100644 --- a/src/client/tasks.js +++ b/src/client/tasks.js @@ -104,8 +104,8 @@ import * as investmentProjectTasks from './modules/Investments/Projects/tasks' import { TASK_GET_LATEST_EXPORT_WINS, TASK_GET_PROJECT_WON_COUNT, -} from '../apps/companies/apps/company-overview/overview-table-cards/state' -import * as overviewInvestmentProjectTasks from '../apps/companies/apps/company-overview/overview-table-cards/tasks' +} from './modules/Companies/CompanyOverview/TableCards/state.js' +import * as overviewInvestmentProjectTasks from './modules/Companies/CompanyOverview/TableCards/tasks.js' import { TASK_SEARCH_COMPANY,