@@ -298,7 +300,7 @@ const SectionUpload = ({
onCheckedChange={setProcessNow}
/>
diff --git a/ui/src/pages/deployment-details/deployment-details-form/deployment-details-form.tsx b/ui/src/pages/deployment-details/deployment-details-form/deployment-details-form.tsx
index 92cf18526..7b42ae7a3 100644
--- a/ui/src/pages/deployment-details/deployment-details-form/deployment-details-form.tsx
+++ b/ui/src/pages/deployment-details/deployment-details-form/deployment-details-form.tsx
@@ -145,7 +145,7 @@ const FormStepper = () => {
},
{
id: Section.SourceImages,
- label: translate(STRING.FIELD_LABEL_SOURCE_IMAGES),
+ label: translate(STRING.FIELD_LABEL_CAPTURES),
},
]}
currentItemId={currentSection}
diff --git a/ui/src/pages/deployment-details/deployment-details-info.tsx b/ui/src/pages/deployment-details/deployment-details-info.tsx
index 6e8f65da7..7cd477082 100644
--- a/ui/src/pages/deployment-details/deployment-details-info.tsx
+++ b/ui/src/pages/deployment-details/deployment-details-info.tsx
@@ -80,7 +80,7 @@ export const DeploymentDetailsInfo = ({
-
+
-
diff --git a/ui/src/pages/job-details/job-details.tsx b/ui/src/pages/job-details/job-details.tsx
index 4ab5f5c37..341359f5e 100644
--- a/ui/src/pages/job-details/job-details.tsx
+++ b/ui/src/pages/job-details/job-details.tsx
@@ -114,7 +114,7 @@ const JobSummary = ({ job }: { job: Job }) => {
) : null}
{job.sourceImage ? (
{
/>
) : job.sourceImages ? (
) : null}
diff --git a/ui/src/pages/jobs/jobs-columns.tsx b/ui/src/pages/jobs/jobs-columns.tsx
index 93731aa6b..f46767a55 100644
--- a/ui/src/pages/jobs/jobs-columns.tsx
+++ b/ui/src/pages/jobs/jobs-columns.tsx
@@ -76,7 +76,7 @@ export const columns: (projectId: string) => TableColumn[] = (
},
{
id: 'source-image',
- name: translate(STRING.FIELD_LABEL_SOURCE_IMAGE),
+ name: translate(STRING.FIELD_LABEL_CAPTURE),
renderCell: (item: Job) =>
item.sourceImage?.sessionId ? (
TableColumn[] = (
{
id: 'source-image-collection',
sortField: 'source_image_collection',
- name: translate(STRING.FIELD_LABEL_SOURCE_IMAGES_COLLECTION),
+ name: translate(STRING.FIELD_LABEL_CAPTURE_SET),
renderCell: (item: Job) => (
),
diff --git a/ui/src/pages/project/collections/collection-columns.tsx b/ui/src/pages/project/capture-sets/capture-set-columns.tsx
similarity index 78%
rename from ui/src/pages/project/collections/collection-columns.tsx
rename to ui/src/pages/project/capture-sets/capture-set-columns.tsx
index a3ee5018b..2172046c0 100644
--- a/ui/src/pages/project/collections/collection-columns.tsx
+++ b/ui/src/pages/project/capture-sets/capture-set-columns.tsx
@@ -1,5 +1,5 @@
import { API_ROUTES } from 'data-services/constants'
-import { Collection } from 'data-services/models/collection'
+import { CaptureSet } from 'data-services/models/capture-set'
import { BasicTableCell } from 'design-system/components/table/basic-table-cell/basic-table-cell'
import { StatusTableCell } from 'design-system/components/table/status-table-cell/status-table-cell'
import {
@@ -14,28 +14,28 @@ import { Link } from 'react-router-dom'
import { APP_ROUTES } from 'utils/constants'
import { getAppRoute } from 'utils/getAppRoute'
import { STRING, translate } from 'utils/language'
-import { PopulateCollection } from './collection-actions'
import { SERVER_SAMPLING_METHODS } from './constants'
+import { PopulateCaptureSet } from './populate-capture-set'
-export const columns: (projectId: string) => TableColumn[] = (
+export const columns: (projectId: string) => TableColumn[] = (
projectId: string
) => [
{
id: 'id',
name: translate(STRING.FIELD_LABEL_ID),
sortField: 'id',
- renderCell: (item: Collection) => ,
+ renderCell: (item: CaptureSet) => ,
},
{
id: 'name',
name: translate(STRING.FIELD_LABEL_NAME),
sortField: 'name',
- renderCell: (item: Collection) => ,
+ renderCell: (item: CaptureSet) => ,
},
{
id: 'settings',
name: 'Settings',
- renderCell: (item: Collection) => (
+ renderCell: (item: CaptureSet) => (
TableColumn[] = (
{
id: 'status',
name: 'Latest job status',
- renderCell: (item: Collection) => {
+ renderCell: (item: CaptureSet) => {
if (!item.currentJob) {
return <>>
}
@@ -65,7 +65,7 @@ export const columns: (projectId: string) => TableColumn[] = (
styles: {
textAlign: TextAlign.Right,
},
- renderCell: (item: Collection) => (
+ renderCell: (item: CaptureSet) => (
TableColumn[] = (
styles: {
textAlign: TextAlign.Right,
},
- renderCell: (item: Collection) => (
+ renderCell: (item: CaptureSet) => (
TableColumn[] = (
styles: {
textAlign: TextAlign.Right,
},
- renderCell: (item: Collection) => (
+ renderCell: (item: CaptureSet) => (
),
},
@@ -111,7 +111,7 @@ export const columns: (projectId: string) => TableColumn[] = (
styles: {
textAlign: TextAlign.Right,
},
- renderCell: (item: Collection) => (
+ renderCell: (item: CaptureSet) => (
TableColumn[] = (
styles: {
textAlign: TextAlign.Right,
},
- renderCell: (item: Collection) => ,
+ renderCell: (item: CaptureSet) => ,
},
{
id: 'created-at',
name: translate(STRING.FIELD_LABEL_CREATED_AT),
sortField: 'created_at',
- renderCell: (item: Collection) => ,
+ renderCell: (item: CaptureSet) => ,
},
{
id: 'updated-at',
name: translate(STRING.FIELD_LABEL_UPDATED_AT),
sortField: 'updated_at',
- renderCell: (item: Collection) => ,
+ renderCell: (item: CaptureSet) => ,
},
{
id: 'actions',
@@ -150,21 +150,21 @@ export const columns: (projectId: string) => TableColumn[] = (
padding: '16px',
width: '100%',
},
- renderCell: (item: Collection) => (
+ renderCell: (item: CaptureSet) => (
- {item.canPopulate &&
}
+ {item.canPopulate &&
}
{item.canUpdate && SERVER_SAMPLING_METHODS.includes(item.method) && (
)}
{item.canDelete && (
)}
diff --git a/ui/src/pages/project/collections/collections.tsx b/ui/src/pages/project/capture-sets/capture-sets.tsx
similarity index 79%
rename from ui/src/pages/project/collections/collections.tsx
rename to ui/src/pages/project/capture-sets/capture-sets.tsx
index efbcb59fd..3f7c1f8d2 100644
--- a/ui/src/pages/project/collections/collections.tsx
+++ b/ui/src/pages/project/capture-sets/capture-sets.tsx
@@ -1,5 +1,5 @@
import { API_ROUTES } from 'data-services/constants'
-import { useCollections } from 'data-services/hooks/collections/useCollections'
+import { useCaptureSets } from 'data-services/hooks/capture-sets/useCaptureSets'
import { PageHeader } from 'design-system/components/page-header/page-header'
import { PaginationBar } from 'design-system/components/pagination-bar/pagination-bar'
import { ColumnSettings } from 'design-system/components/table/column-settings/column-settings'
@@ -12,16 +12,16 @@ import { STRING, translate } from 'utils/language'
import { useColumnSettings } from 'utils/useColumnSettings'
import { usePagination } from 'utils/usePagination'
import { UserPermission } from 'utils/user/types'
-import { columns } from './collection-columns'
+import { columns } from './capture-set-columns'
-export const Collections = () => {
+export const CaptureSets = () => {
const { projectId } = useParams()
const [sort, setSort] = useState({
field: 'id',
order: 'asc',
})
const { columnSettings, setColumnSettings } = useColumnSettings(
- 'collections',
+ 'capture-sets',
{
id: true,
name: true,
@@ -36,8 +36,8 @@ export const Collections = () => {
const countColumnVisible = columnSettings.occurrences || columnSettings.taxa
const sortByCountActive =
sort?.field === 'occurrences_count' || sort?.field === 'taxa_count'
- const { collections, userPermissions, total, isLoading, isFetching, error } =
- useCollections(
+ const { captureSets, userPermissions, total, isLoading, isFetching, error } =
+ useCaptureSets(
{
projectId,
pagination,
@@ -49,24 +49,24 @@ export const Collections = () => {
const canCreate = userPermissions?.includes(UserPermission.Create)
useEffect(() => {
- // If any collection has a job in progress, we want to poll the endpoint so we can show job updates
- if (collections?.some(({ hasJobInProgress }) => hasJobInProgress)) {
+ // If any capture set has a job in progress, we want to poll the endpoint so we can show job updates
+ if (captureSets?.some(({ hasJobInProgress }) => hasJobInProgress)) {
setPoll(true)
} else {
setPoll(false)
}
- }, [collections])
+ }, [captureSets])
return (
<>
{
/>
{canCreate && (
)}
@@ -91,12 +91,12 @@ export const Collections = () => {
})}
error={error}
isLoading={isLoading}
- items={collections}
+ items={captureSets}
onSortSettingsChange={setSort}
sortable
sortSettings={sort}
/>
- {collections?.length ? (
+ {captureSets?.length ? (
{
- const { populateCollection, isLoading, error } = usePopulateCollection()
+ const { populateCaptureSet, isLoading, error } = usePopulateCaptureSet()
return (