geonetwork-ui 2.4.1-dev.89bb09dfa → 2.4.1-dev.9ee0df3df

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (121) hide show
  1. package/esm2022/libs/api/metadata-converter/src/lib/gn4/gn4.converter.mjs +3 -4
  2. package/esm2022/libs/api/metadata-converter/src/lib/gn4/gn4.field.mapper.mjs +2 -5
  3. package/esm2022/libs/api/metadata-converter/src/lib/gn4/types/metadata.model.mjs +1 -1
  4. package/esm2022/libs/api/repository/src/lib/gn4/gn4-repository.mjs +16 -27
  5. package/esm2022/libs/common/domain/src/lib/repository/records-repository.interface.mjs +1 -1
  6. package/esm2022/libs/data-access/gn4/src/openapi/api/records.api.service.mjs +1 -7
  7. package/esm2022/libs/feature/editor/src/lib/+state/editor.actions.mjs +1 -3
  8. package/esm2022/libs/feature/editor/src/lib/+state/editor.effects.mjs +14 -18
  9. package/esm2022/libs/feature/editor/src/lib/+state/editor.facade.mjs +5 -15
  10. package/esm2022/libs/feature/editor/src/lib/+state/editor.reducer.mjs +4 -10
  11. package/esm2022/libs/feature/editor/src/lib/+state/editor.selectors.mjs +5 -6
  12. package/esm2022/libs/feature/editor/src/lib/components/online-service-resource-input/online-service-resource-input.component.mjs +10 -57
  13. package/esm2022/libs/feature/editor/src/lib/components/record-form/form-field/form-field-license/form-field-license.component.mjs +23 -36
  14. package/esm2022/libs/feature/editor/src/lib/components/record-form/form-field/form-field-online-link-resources/form-field-online-link-resources.component.mjs +12 -7
  15. package/esm2022/libs/feature/editor/src/lib/components/record-form/form-field/form-field-online-resources/form-field-online-resources.component.mjs +12 -8
  16. package/esm2022/libs/feature/editor/src/lib/components/record-form/form-field/form-field-overviews/form-field-overviews.component.mjs +12 -6
  17. package/esm2022/libs/feature/editor/src/lib/components/record-form/form-field/form-field.component.mjs +3 -3
  18. package/esm2022/libs/feature/editor/src/lib/services/editor.service.mjs +5 -9
  19. package/esm2022/libs/feature/search/src/lib/results-table/results-table-container.component.mjs +4 -3
  20. package/esm2022/libs/ui/dataviz/src/lib/figure/figure.component.mjs +3 -3
  21. package/esm2022/libs/ui/inputs/src/lib/file-input/file-input.component.mjs +4 -4
  22. package/esm2022/libs/ui/layout/src/lib/interactive-table/interactive-table.component.mjs +4 -9
  23. package/esm2022/libs/ui/search/src/lib/results-table/results-table.component.mjs +10 -10
  24. package/esm2022/libs/util/shared/src/lib/links/link-utils.mjs +1 -40
  25. package/esm2022/translations/de.json +6 -29
  26. package/esm2022/translations/en.json +9 -13
  27. package/esm2022/translations/es.json +4 -27
  28. package/esm2022/translations/fr.json +9 -13
  29. package/esm2022/translations/it.json +218 -243
  30. package/esm2022/translations/nl.json +4 -27
  31. package/esm2022/translations/pt.json +4 -27
  32. package/fesm2022/geonetwork-ui.mjs +616 -883
  33. package/fesm2022/geonetwork-ui.mjs.map +1 -1
  34. package/libs/api/metadata-converter/src/lib/gn4/gn4.converter.d.ts.map +1 -1
  35. package/libs/api/metadata-converter/src/lib/gn4/gn4.field.mapper.d.ts.map +1 -1
  36. package/libs/api/metadata-converter/src/lib/gn4/types/metadata.model.d.ts +0 -1
  37. package/libs/api/metadata-converter/src/lib/gn4/types/metadata.model.d.ts.map +1 -1
  38. package/libs/api/repository/src/lib/gn4/gn4-repository.d.ts +3 -4
  39. package/libs/api/repository/src/lib/gn4/gn4-repository.d.ts.map +1 -1
  40. package/libs/common/domain/src/lib/repository/records-repository.interface.d.ts +3 -4
  41. package/libs/common/domain/src/lib/repository/records-repository.interface.d.ts.map +1 -1
  42. package/libs/data-access/gn4/src/openapi/api/records.api.service.d.ts +0 -3
  43. package/libs/data-access/gn4/src/openapi/api/records.api.service.d.ts.map +1 -1
  44. package/libs/feature/editor/src/lib/+state/editor.actions.d.ts +2 -10
  45. package/libs/feature/editor/src/lib/+state/editor.actions.d.ts.map +1 -1
  46. package/libs/feature/editor/src/lib/+state/editor.effects.d.ts +2 -6
  47. package/libs/feature/editor/src/lib/+state/editor.effects.d.ts.map +1 -1
  48. package/libs/feature/editor/src/lib/+state/editor.facade.d.ts +2 -5
  49. package/libs/feature/editor/src/lib/+state/editor.facade.d.ts.map +1 -1
  50. package/libs/feature/editor/src/lib/+state/editor.reducer.d.ts +1 -2
  51. package/libs/feature/editor/src/lib/+state/editor.reducer.d.ts.map +1 -1
  52. package/libs/feature/editor/src/lib/+state/editor.selectors.d.ts +1 -2
  53. package/libs/feature/editor/src/lib/+state/editor.selectors.d.ts.map +1 -1
  54. package/libs/feature/editor/src/lib/components/online-service-resource-input/online-service-resource-input.component.d.ts +5 -16
  55. package/libs/feature/editor/src/lib/components/online-service-resource-input/online-service-resource-input.component.d.ts.map +1 -1
  56. package/libs/feature/editor/src/lib/components/record-form/form-field/form-field-license/form-field-license.component.d.ts +4 -4
  57. package/libs/feature/editor/src/lib/components/record-form/form-field/form-field-license/form-field-license.component.d.ts.map +1 -1
  58. package/libs/feature/editor/src/lib/components/record-form/form-field/form-field-online-link-resources/form-field-online-link-resources.component.d.ts +4 -1
  59. package/libs/feature/editor/src/lib/components/record-form/form-field/form-field-online-link-resources/form-field-online-link-resources.component.d.ts.map +1 -1
  60. package/libs/feature/editor/src/lib/components/record-form/form-field/form-field-online-resources/form-field-online-resources.component.d.ts +5 -2
  61. package/libs/feature/editor/src/lib/components/record-form/form-field/form-field-online-resources/form-field-online-resources.component.d.ts.map +1 -1
  62. package/libs/feature/editor/src/lib/components/record-form/form-field/form-field-overviews/form-field-overviews.component.d.ts +4 -1
  63. package/libs/feature/editor/src/lib/components/record-form/form-field/form-field-overviews/form-field-overviews.component.d.ts.map +1 -1
  64. package/libs/feature/editor/src/lib/services/editor.service.d.ts +1 -1
  65. package/libs/feature/editor/src/lib/services/editor.service.d.ts.map +1 -1
  66. package/libs/feature/search/src/lib/results-table/results-table-container.component.d.ts +1 -0
  67. package/libs/feature/search/src/lib/results-table/results-table-container.component.d.ts.map +1 -1
  68. package/libs/ui/elements/src/lib/record-api-form/record-api-form.component.d.ts +1 -1
  69. package/libs/ui/inputs/src/lib/file-input/file-input.component.d.ts +1 -1
  70. package/libs/ui/inputs/src/lib/file-input/file-input.component.d.ts.map +1 -1
  71. package/libs/ui/layout/src/lib/interactive-table/interactive-table.component.d.ts +1 -2
  72. package/libs/ui/layout/src/lib/interactive-table/interactive-table.component.d.ts.map +1 -1
  73. package/libs/ui/search/src/lib/results-table/results-table.component.d.ts +3 -3
  74. package/libs/ui/search/src/lib/results-table/results-table.component.d.ts.map +1 -1
  75. package/libs/util/shared/src/lib/links/link-utils.d.ts +1 -2
  76. package/libs/util/shared/src/lib/links/link-utils.d.ts.map +1 -1
  77. package/package.json +1 -1
  78. package/src/libs/api/metadata-converter/src/lib/gn4/gn4.converter.ts +3 -4
  79. package/src/libs/api/metadata-converter/src/lib/gn4/gn4.field.mapper.ts +1 -8
  80. package/src/libs/api/metadata-converter/src/lib/gn4/types/metadata.model.ts +0 -1
  81. package/src/libs/api/repository/src/lib/gn4/gn4-repository.ts +27 -53
  82. package/src/libs/common/domain/src/lib/repository/records-repository.interface.ts +4 -5
  83. package/src/libs/common/fixtures/src/lib/elasticsearch/full-response.fixtures.ts +2 -2
  84. package/src/libs/common/fixtures/src/lib/elasticsearch/search-responses.fixtures.ts +16 -16
  85. package/src/libs/common/fixtures/src/lib/records.fixtures.ts +0 -163
  86. package/src/libs/data-access/gn4/src/openapi/api/records.api.service.ts +4 -24
  87. package/src/libs/feature/editor/src/lib/+state/editor.actions.ts +1 -10
  88. package/src/libs/feature/editor/src/lib/+state/editor.effects.ts +31 -57
  89. package/src/libs/feature/editor/src/lib/+state/editor.facade.ts +9 -15
  90. package/src/libs/feature/editor/src/lib/+state/editor.reducer.ts +12 -18
  91. package/src/libs/feature/editor/src/lib/+state/editor.selectors.ts +8 -13
  92. package/src/libs/feature/editor/src/lib/components/online-service-resource-input/online-service-resource-input.component.html +7 -38
  93. package/src/libs/feature/editor/src/lib/components/online-service-resource-input/online-service-resource-input.component.ts +3 -62
  94. package/src/libs/feature/editor/src/lib/components/record-form/form-field/form-field-license/form-field-license.component.html +1 -1
  95. package/src/libs/feature/editor/src/lib/components/record-form/form-field/form-field-license/form-field-license.component.ts +19 -31
  96. package/src/libs/feature/editor/src/lib/components/record-form/form-field/form-field-online-link-resources/form-field-online-link-resources.component.html +10 -1
  97. package/src/libs/feature/editor/src/lib/components/record-form/form-field/form-field-online-link-resources/form-field-online-link-resources.component.ts +7 -1
  98. package/src/libs/feature/editor/src/lib/components/record-form/form-field/form-field-online-resources/form-field-online-resources.component.html +20 -11
  99. package/src/libs/feature/editor/src/lib/components/record-form/form-field/form-field-online-resources/form-field-online-resources.component.ts +10 -5
  100. package/src/libs/feature/editor/src/lib/components/record-form/form-field/form-field-overviews/form-field-overviews.component.html +9 -0
  101. package/src/libs/feature/editor/src/lib/components/record-form/form-field/form-field-overviews/form-field-overviews.component.ts +8 -2
  102. package/src/libs/feature/editor/src/lib/components/record-form/form-field/form-field.component.html +2 -2
  103. package/src/libs/feature/editor/src/lib/services/editor.service.ts +16 -18
  104. package/src/libs/feature/search/src/lib/results-table/results-table-container.component.html +1 -0
  105. package/src/libs/feature/search/src/lib/results-table/results-table-container.component.ts +3 -0
  106. package/src/libs/ui/dataviz/src/lib/figure/figure.component.html +0 -1
  107. package/src/libs/ui/inputs/src/lib/file-input/file-input.component.ts +1 -1
  108. package/src/libs/ui/layout/src/lib/interactive-table/interactive-table.component.html +1 -12
  109. package/src/libs/ui/layout/src/lib/interactive-table/interactive-table.component.ts +6 -4
  110. package/src/libs/ui/search/src/lib/results-table/results-table.component.html +6 -23
  111. package/src/libs/ui/search/src/lib/results-table/results-table.component.ts +6 -6
  112. package/src/libs/util/shared/src/lib/links/link-utils.ts +1 -51
  113. package/tailwind.base.config.js +0 -2
  114. package/translations/de.json +6 -29
  115. package/translations/en.json +9 -13
  116. package/translations/es.json +4 -27
  117. package/translations/fr.json +9 -13
  118. package/translations/it.json +218 -243
  119. package/translations/nl.json +4 -27
  120. package/translations/pt.json +4 -27
  121. package/translations/sk.json +4 -27
@@ -201,22 +201,6 @@ export class Gn4Repository implements RecordsRepositoryInterface {
201
201
  )
202
202
  }
203
203
 
204
- getRecordPublicationStatus(uniqueIdentifier: string): Observable<boolean> {
205
- return uniqueIdentifier
206
- ? this.getRecord(uniqueIdentifier).pipe(
207
- map((record) => record.extras['isPublishedToAll'] as boolean)
208
- )
209
- : of(true)
210
- }
211
-
212
- canEditRecord(uniqueIdentifier: string): Observable<boolean> {
213
- return this.getRecord(uniqueIdentifier).pipe(
214
- map((record) => {
215
- return record.extras['edit'] as boolean
216
- })
217
- )
218
- }
219
-
220
204
  openRecordForEdition(
221
205
  uniqueIdentifier: string
222
206
  ): Observable<[CatalogRecord, string, boolean] | null> {
@@ -239,45 +223,31 @@ export class Gn4Repository implements RecordsRepositoryInterface {
239
223
 
240
224
  openRecordForDuplication(
241
225
  uniqueIdentifier: string
242
- ): Observable<[CatalogRecord, string, true] | null> {
243
- return this.gn4RecordsApi
244
- .create(
245
- uniqueIdentifier,
246
- '2',
247
- 'METADATA',
248
- '',
249
- false,
250
- undefined,
251
- true,
252
- false,
253
- undefined,
254
- 'body',
255
- false,
256
- {
257
- httpHeaderAccept: 'application/json',
258
- httpContentTypeSelected: 'application/json;charset=UTF-8',
259
- }
260
- )
261
- .pipe(
262
- switchMap((uniqueIdentifier) => {
263
- return this.getRecordAsXml(uniqueIdentifier)
264
- }),
265
- switchMap((xml) => {
266
- return from(
267
- findConverterForDocument(xml)
268
- .readRecord(xml)
269
- .then((record) => {
270
- return [record, xml, true] as [CatalogRecord, string, true]
271
- })
272
- )
273
- })
274
- )
226
+ ): Observable<[CatalogRecord, string, false] | null> {
227
+ return this.getRecordAsXml(uniqueIdentifier).pipe(
228
+ switchMap(async (fetchedRecordAsXml) => {
229
+ const converter = findConverterForDocument(fetchedRecordAsXml)
230
+ const record = await converter.readRecord(fetchedRecordAsXml)
231
+
232
+ record.uniqueIdentifier = `${TEMPORARY_ID_PREFIX}${Date.now()}`
233
+ record.title = `${record.title} (Copy)`
234
+
235
+ const recordAsXml = await converter.writeRecord(
236
+ record,
237
+ fetchedRecordAsXml
238
+ )
239
+
240
+ this.saveRecordToLocalStorage(recordAsXml, record.uniqueIdentifier)
241
+ this._draftsChanged.next()
242
+
243
+ return [record, recordAsXml, false] as [CatalogRecord, string, false]
244
+ })
245
+ )
275
246
  }
276
247
 
277
248
  saveRecord(
278
249
  record: CatalogRecord,
279
- referenceRecordSource?: string,
280
- publishToAll = true
250
+ referenceRecordSource?: string
281
251
  ): Observable<string> {
282
252
  return this.platformService.getApiVersion().pipe(
283
253
  map((version) => {
@@ -292,7 +262,7 @@ export class Gn4Repository implements RecordsRepositoryInterface {
292
262
  undefined,
293
263
  undefined,
294
264
  undefined,
295
- publishToAll,
265
+ true,
296
266
  undefined,
297
267
  'OVERWRITE',
298
268
  undefined,
@@ -367,6 +337,10 @@ export class Gn4Repository implements RecordsRepositoryInterface {
367
337
  return this.getRecordFromLocalStorage(uniqueIdentifier) !== null
368
338
  }
369
339
 
340
+ isRecordNotYetSaved(uniqueIdentifier: string): boolean {
341
+ return uniqueIdentifier.startsWith(TEMPORARY_ID_PREFIX)
342
+ }
343
+
370
344
  // generated by copilot
371
345
  getAllDrafts(): Observable<CatalogRecord[]> {
372
346
  const items = { ...window.localStorage }
@@ -394,7 +368,7 @@ export class Gn4Repository implements RecordsRepositoryInterface {
394
368
 
395
369
  hasRecordChangedSinceDraft(localRecord: CatalogRecord) {
396
370
  return of({
397
- isUnsaved: !localRecord.uniqueIdentifier,
371
+ isUnsaved: this.isRecordNotYetSaved(localRecord.uniqueIdentifier),
398
372
  hasDraft: this.recordHasDraft(localRecord.uniqueIdentifier),
399
373
  }).pipe(
400
374
  switchMap(({ isUnsaved, hasDraft }) => {
@@ -17,7 +17,7 @@ export abstract class RecordsRepositoryInterface {
17
17
  similarTo: CatalogRecord
18
18
  ): Observable<CatalogRecord[]>
19
19
  abstract fuzzySearch(query: string): Observable<SearchResults>
20
- abstract canEditRecord(uniqueIdentifier: string): Observable<boolean>
20
+
21
21
  /**
22
22
  * This emits once:
23
23
  * - record object; if a draft exists, this will return it
@@ -40,7 +40,7 @@ export abstract class RecordsRepositoryInterface {
40
40
  */
41
41
  abstract openRecordForDuplication(
42
42
  uniqueIdentifier: string
43
- ): Observable<[CatalogRecord, string, true] | null>
43
+ ): Observable<[CatalogRecord, string, false] | null>
44
44
 
45
45
  /**
46
46
  * @param record
@@ -49,8 +49,7 @@ export abstract class RecordsRepositoryInterface {
49
49
  */
50
50
  abstract saveRecord(
51
51
  record: CatalogRecord,
52
- referenceRecordSource?: string,
53
- publishToAll?: boolean
52
+ referenceRecordSource?: string
54
53
  ): Observable<string>
55
54
 
56
55
  /**
@@ -83,6 +82,7 @@ export abstract class RecordsRepositoryInterface {
83
82
 
84
83
  abstract clearRecordDraft(uniqueIdentifier: string): void
85
84
  abstract recordHasDraft(uniqueIdentifier: string): boolean
85
+ abstract isRecordNotYetSaved(uniqueIdentifier: string): boolean
86
86
 
87
87
  /** will return all pending drafts, both published and not published */
88
88
  abstract getAllDrafts(): Observable<CatalogRecord[]>
@@ -91,5 +91,4 @@ export abstract class RecordsRepositoryInterface {
91
91
  abstract hasRecordChangedSinceDraft(
92
92
  localRecord: CatalogRecord
93
93
  ): Observable<{ user: string; date: Date }>
94
- abstract getRecordPublicationStatus(uuid: string): Observable<boolean>
95
94
  }
@@ -1578,7 +1578,7 @@ export const elasticFullResponseFixture = () => ({
1578
1578
  'http://inspire.ec.europa.eu/metadatacodelist/LimitationsOnPublicAccess/noLimitations',
1579
1579
  ],
1580
1580
  },
1581
- edit: true,
1581
+ edit: false,
1582
1582
  owner: false,
1583
1583
  isPublishedToAll: true,
1584
1584
  view: true,
@@ -3249,7 +3249,7 @@ export const elasticFullResponseFixture = () => ({
3249
3249
  userSavedCount: '0',
3250
3250
  sourceCatalogue: '7ea582d4-9ddf-422e-b28f-29760a4c0147',
3251
3251
  },
3252
- edit: true,
3252
+ edit: false,
3253
3253
  canReview: false,
3254
3254
  owner: false,
3255
3255
  isPublishedToAll: true,
@@ -124,9 +124,9 @@ export const elasticHitsOnlyFixture = () => ({
124
124
  sourceCatalogue: '6731be1e-6533-44e0-9b8a-580b45e36e80',
125
125
  link: [],
126
126
  },
127
- edit: true,
127
+ edit: false,
128
128
  owner: false,
129
- isPublishedToAll: true,
129
+ isPublishedToAll: false,
130
130
  view: false,
131
131
  notify: false,
132
132
  download: false,
@@ -203,9 +203,9 @@ export const elasticHitsOnlyFixture = () => ({
203
203
  userSavedCount: '4',
204
204
  link: [],
205
205
  },
206
- edit: true,
206
+ edit: false,
207
207
  owner: false,
208
- isPublishedToAll: true,
208
+ isPublishedToAll: false,
209
209
  view: false,
210
210
  notify: false,
211
211
  download: false,
@@ -299,7 +299,7 @@ export const elasticSummaryHitsFixture = () => ({
299
299
  userSavedCount: '5',
300
300
  },
301
301
  sort: [1660176316000],
302
- edit: true,
302
+ edit: false,
303
303
  owner: false,
304
304
  isPublishedToAll: true,
305
305
  view: true,
@@ -370,7 +370,7 @@ export const elasticSummaryHitsFixture = () => ({
370
370
  userSavedCount: '0',
371
371
  },
372
372
  sort: [1660089739000],
373
- edit: true,
373
+ edit: false,
374
374
  owner: false,
375
375
  isPublishedToAll: true,
376
376
  view: true,
@@ -428,7 +428,7 @@ export const elasticSummaryHitsFixture = () => ({
428
428
  userSavedCount: '0',
429
429
  },
430
430
  sort: [1660089729000],
431
- edit: true,
431
+ edit: false,
432
432
  owner: false,
433
433
  isPublishedToAll: true,
434
434
  view: true,
@@ -1531,7 +1531,7 @@ export const elasticServiceMetadataHistsFixture = () => ({
1531
1531
  },
1532
1532
  ],
1533
1533
  },
1534
- edit: true,
1534
+ edit: false,
1535
1535
  canReview: false,
1536
1536
  owner: false,
1537
1537
  isPublishedToAll: true,
@@ -1715,7 +1715,7 @@ export const elasticServiceMetadataHistsFixture = () => ({
1715
1715
  op3: ['1', '25', '14688'],
1716
1716
  op6: ['1', '14688'],
1717
1717
  op5: ['1', '14688'],
1718
- edit: true,
1718
+ edit: false,
1719
1719
  canReview: false,
1720
1720
  owner: false,
1721
1721
  isPublishedToAll: true,
@@ -2369,7 +2369,7 @@ export const elasticServiceMetadataHistsFixture = () => ({
2369
2369
  inspireAnnexForFirstTheme: 'iii',
2370
2370
  userSavedCount: '0',
2371
2371
  },
2372
- edit: true,
2372
+ edit: false,
2373
2373
  canReview: false,
2374
2374
  owner: false,
2375
2375
  isPublishedToAll: true,
@@ -2796,7 +2796,7 @@ export const elasticServiceMetadataHistsFixture = () => ({
2796
2796
  uuid: 'ebef2115-bee5-40bb-b5cc-4593d82ba334',
2797
2797
  op0: '1',
2798
2798
  resourceType: ['dataset', 'map', 'map/static'],
2799
- edit: true,
2799
+ edit: false,
2800
2800
  canReview: false,
2801
2801
  owner: false,
2802
2802
  isPublishedToAll: true,
@@ -4920,7 +4920,7 @@ export const elasticReuseMetadataHitsFixture = () => ({
4920
4920
  },
4921
4921
  ],
4922
4922
  },
4923
- edit: true,
4923
+ edit: false,
4924
4924
  canReview: false,
4925
4925
  owner: false,
4926
4926
  isPublishedToAll: true,
@@ -5148,7 +5148,7 @@ export const elasticReuseMetadataHitsFixture = () => ({
5148
5148
  op3: '1',
5149
5149
  op6: '1',
5150
5150
  op5: '1',
5151
- edit: true,
5151
+ edit: false,
5152
5152
  canReview: false,
5153
5153
  owner: false,
5154
5154
  isPublishedToAll: true,
@@ -12690,7 +12690,7 @@ export const elasticReuseMetadataHitsFixture = () => ({
12690
12690
  inspireAnnexForFirstTheme: 'iii',
12691
12691
  userSavedCount: '0',
12692
12692
  },
12693
- edit: true,
12693
+ edit: false,
12694
12694
  canReview: false,
12695
12695
  owner: false,
12696
12696
  isPublishedToAll: true,
@@ -13022,7 +13022,7 @@ export const elasticReuseMetadataHitsFixture = () => ({
13022
13022
  userSavedCount: '0',
13023
13023
  sourceCatalogue: 'ce008f24-8e0d-45a8-97f8-9f10399f0190',
13024
13024
  },
13025
- edit: true,
13025
+ edit: false,
13026
13026
  canReview: false,
13027
13027
  owner: false,
13028
13028
  isPublishedToAll: true,
@@ -13349,7 +13349,7 @@ export const elasticReuseMetadataHitsFixture = () => ({
13349
13349
  userSavedCount: '0',
13350
13350
  sourceCatalogue: 'ce008f24-8e0d-45a8-97f8-9f10399f0190',
13351
13351
  },
13352
- edit: true,
13352
+ edit: false,
13353
13353
  canReview: false,
13354
13354
  owner: false,
13355
13355
  isPublishedToAll: true,
@@ -157,10 +157,6 @@ As such, **it is not very interesting at all.**`,
157
157
  },
158
158
  otherLanguages: ['de'],
159
159
  defaultLanguage: 'en',
160
- extras: {
161
- isPublishedToAll: true,
162
- edit: true,
163
- },
164
160
  },
165
161
  {
166
162
  uniqueIdentifier: '7d002c4c-92ef-4b9f-a568-d732f740b99e',
@@ -471,165 +467,6 @@ export const simpleDatasetRecordAsXmlFixture =
471
467
  </mdb:resourceLineage>
472
468
  </mdb:MD_Metadata>`
473
469
 
474
- export const duplicateDatasetRecordAsXmlFixture =
475
- (): string => `<?xml version="1.0" encoding="UTF-8"?>
476
- <mdb:MD_Metadata xmlns:mdb="http://standards.iso.org/iso/19115/-3/mdb/2.0" xmlns:mcc="http://standards.iso.org/iso/19115/-3/mcc/1.0" xmlns:gco="http://standards.iso.org/iso/19115/-3/gco/1.0" xmlns:cit="http://standards.iso.org/iso/19115/-3/cit/2.0" xmlns:mri="http://standards.iso.org/iso/19115/-3/mri/1.0" xmlns:mco="http://standards.iso.org/iso/19115/-3/mco/1.0" xmlns:gcx="http://standards.iso.org/iso/19115/-3/gcx/1.0" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:mmi="http://standards.iso.org/iso/19115/-3/mmi/1.0" xmlns:mrd="http://standards.iso.org/iso/19115/-3/mrd/1.0" xmlns:mrl="http://standards.iso.org/iso/19115/-3/mrl/2.0">
477
- <mdb:metadataIdentifier>
478
- <mcc:MD_Identifier>
479
- <mcc:code>
480
- <gco:CharacterString>my-dataset-001</gco:CharacterString>
481
- </mcc:code>
482
- </mcc:MD_Identifier>
483
- </mdb:metadataIdentifier>
484
- <mdb:metadataScope>
485
- <mdb:MD_MetadataScope>
486
- <mdb:resourceScope>
487
- <mcc:MD_ScopeCode codeList="https://standards.iso.org/iso/19115/resources/Codelists/cat/codelists.xml#MD_ScopeCode" codeListValue="dataset">dataset</mcc:MD_ScopeCode>
488
- </mdb:resourceScope>
489
- </mdb:MD_MetadataScope>
490
- </mdb:metadataScope>
491
- <mdb:contact>
492
- <cit:CI_Responsibility>
493
- <cit:role>
494
- <cit:CI_RoleCode codeList="https://standards.iso.org/iso/19115/resources/Codelists/cat/codelists.xml#CI_RoleCode" codeListValue="pointOfContact">pointOfContact</cit:CI_RoleCode>
495
- </cit:role>
496
- <cit:party>
497
- <cit:CI_Organisation>
498
- <cit:name>
499
- <gco:CharacterString>MyOrganization</gco:CharacterString>
500
- </cit:name>
501
- <cit:contactInfo>
502
- <cit:CI_Contact>
503
- <cit:address>
504
- <cit:CI_Address>
505
- <cit:electronicMailAddress>
506
- <gco:CharacterString>bob@org.net</gco:CharacterString>
507
- </cit:electronicMailAddress>
508
- </cit:CI_Address>
509
- </cit:address>
510
- </cit:CI_Contact>
511
- </cit:contactInfo>
512
- <cit:individual>
513
- <cit:CI_Individual>
514
- <cit:name>
515
- <gco:CharacterString>Bob TheGreat</gco:CharacterString>
516
- </cit:name>
517
- <cit:positionName>
518
- <gco:CharacterString>developer</gco:CharacterString>
519
- </cit:positionName>
520
- </cit:CI_Individual>
521
- </cit:individual>
522
- </cit:CI_Organisation>
523
- </cit:party>
524
- </cit:CI_Responsibility>
525
- </mdb:contact>
526
- <mdb:dateInfo>
527
- <cit:CI_Date>
528
- <cit:date>
529
- <gco:DateTime>2022-02-01T15:12:00</gco:DateTime>
530
- </cit:date>
531
- <cit:dateType>
532
- <cit:CI_DateTypeCode codeList="https://standards.iso.org/iso/19115/resources/Codelists/cat/codelists.xml#CI_DateTypeCode" codeListValue="revision">revision</cit:CI_DateTypeCode>
533
- </cit:dateType>
534
- </cit:CI_Date>
535
- </mdb:dateInfo>
536
- <mdb:identificationInfo>
537
- <mri:MD_DataIdentification>
538
- <mri:citation>
539
- <cit:CI_Citation>
540
- <cit:title>
541
- <gco:CharacterString>Copy of record A very interesting dataset (un jeu de données très intéressant)</gco:CharacterString>
542
- </cit:title>
543
- <cit:date>
544
- <cit:CI_Date>
545
- <cit:date>
546
- <gco:DateTime>2022-09-01T14:18:19</gco:DateTime>
547
- </cit:date>
548
- <cit:dateType>
549
- <cit:CI_DateTypeCode codeList="https://standards.iso.org/iso/19115/resources/Codelists/cat/codelists.xml#CI_DateTypeCode" codeListValue="creation">creation</cit:CI_DateTypeCode>
550
- </cit:dateType>
551
- </cit:CI_Date>
552
- </cit:date>
553
- <cit:date>
554
- <cit:CI_Date>
555
- <cit:date>
556
- <gco:DateTime>2022-12-04T15:12:00</gco:DateTime>
557
- </cit:date>
558
- <cit:dateType>
559
- <cit:CI_DateTypeCode codeList="https://standards.iso.org/iso/19115/resources/Codelists/cat/codelists.xml#CI_DateTypeCode" codeListValue="revision">revision</cit:CI_DateTypeCode>
560
- </cit:dateType>
561
- </cit:CI_Date>
562
- </cit:date>
563
- </cit:CI_Citation>
564
- </mri:citation>
565
- <mri:abstract>
566
- <gco:CharacterString>This dataset has been established for testing purposes.</gco:CharacterString>
567
- </mri:abstract>
568
- <mri:topicCategory>
569
- <mri:MD_TopicCategoryCode>testData</mri:MD_TopicCategoryCode>
570
- </mri:topicCategory>
571
- <mri:status>
572
- <mcc:MD_ProgressCode codeList="https://standards.iso.org/iso/19115/resources/Codelists/cat/codelists.xml#MD_ProgressCode" codeListValue="onGoing">onGoing</mcc:MD_ProgressCode>
573
- </mri:status>
574
- <mri:resourceMaintenance>
575
- <mmi:MD_MaintenanceInformation>
576
- <mmi:userDefinedMaintenanceFrequency>
577
- <gco:TM_PeriodDuration>P0Y0M10D</gco:TM_PeriodDuration>
578
- </mmi:userDefinedMaintenanceFrequency>
579
- </mmi:MD_MaintenanceInformation>
580
- </mri:resourceMaintenance>
581
- <mri:spatialRepresentationType>
582
- <mcc:MD_SpatialRepresentationTypeCode codeList="https://standards.iso.org/iso/19115/resources/Codelists/cat/codelists.xml#MD_SpatialRepresentationTypeCode" codeListValue="grid">grid</mcc:MD_SpatialRepresentationTypeCode>
583
- </mri:spatialRepresentationType>
584
- </mri:MD_DataIdentification>
585
- </mdb:identificationInfo>
586
- <mdb:distributionInfo>
587
- <mrd:MD_Distribution>
588
- <mrd:distributionFormat>
589
- <mrd:MD_Format>
590
- <mrd:formatSpecificationCitation>
591
- <cit:CI_Citation>
592
- <cit:title>
593
- <gco:CharacterString>x-gis/x-shapefile</gco:CharacterString>
594
- </cit:title>
595
- </cit:CI_Citation>
596
- </mrd:formatSpecificationCitation>
597
- </mrd:MD_Format>
598
- </mrd:distributionFormat>
599
- <mrd:transferOptions>
600
- <mrd:MD_DigitalTransferOptions>
601
- <mrd:onLine>
602
- <cit:CI_OnlineResource>
603
- <cit:linkage>
604
- <gco:CharacterString>http://my-org.net/download/1.zip</gco:CharacterString>
605
- </cit:linkage>
606
- <cit:description>
607
- <gco:CharacterString>Dataset downloaded as a shapefile</gco:CharacterString>
608
- </cit:description>
609
- <cit:name>
610
- <gco:CharacterString>Direct download</gco:CharacterString>
611
- </cit:name>
612
- <cit:protocol>
613
- <gco:CharacterString>WWW:DOWNLOAD</gco:CharacterString>
614
- </cit:protocol>
615
- <cit:function>
616
- <cit:CI_OnLineFunctionCode codeList="http://standards.iso.org/iso/19139/resources/gmxCodelists.xml#CI_OnLineFunctionCode" codeListValue="download"/>
617
- </cit:function>
618
- </cit:CI_OnlineResource>
619
- </mrd:onLine>
620
- </mrd:MD_DigitalTransferOptions>
621
- </mrd:transferOptions>
622
- </mrd:MD_Distribution>
623
- </mdb:distributionInfo>
624
- <mdb:resourceLineage>
625
- <mrl:LI_Lineage>
626
- <mrl:statement>
627
- <gco:CharacterString>This record was edited manually to test the conversion processes</gco:CharacterString>
628
- </mrl:statement>
629
- </mrl:LI_Lineage>
630
- </mdb:resourceLineage>
631
- </mdb:MD_Metadata>`
632
-
633
470
  export const NATIONAL_KEYWORD = {
634
471
  key: 'http://inspire.ec.europa.eu/metadata-codelist/SpatialScope/national',
635
472
  label: 'National',
@@ -1371,10 +1371,7 @@ export class RecordsApiService {
1371
1371
  hasAttachmentsOfSource?: boolean,
1372
1372
  observe?: 'body',
1373
1373
  reportProgress?: boolean,
1374
- options?: {
1375
- httpHeaderAccept?: 'application/json'
1376
- httpContentTypeSelected?: 'application/json;charset=UTF-8'
1377
- }
1374
+ options?: { httpHeaderAccept?: 'application/json' }
1378
1375
  ): Observable<string>
1379
1376
  public create(
1380
1377
  sourceUuid: string,
@@ -1392,10 +1389,7 @@ export class RecordsApiService {
1392
1389
  hasAttachmentsOfSource?: boolean,
1393
1390
  observe?: 'response',
1394
1391
  reportProgress?: boolean,
1395
- options?: {
1396
- httpHeaderAccept?: 'application/json'
1397
- httpContentTypeSelected?: 'application/json;charset=UTF-8'
1398
- }
1392
+ options?: { httpHeaderAccept?: 'application/json' }
1399
1393
  ): Observable<HttpResponse<string>>
1400
1394
  public create(
1401
1395
  sourceUuid: string,
@@ -1413,10 +1407,7 @@ export class RecordsApiService {
1413
1407
  hasAttachmentsOfSource?: boolean,
1414
1408
  observe?: 'events',
1415
1409
  reportProgress?: boolean,
1416
- options?: {
1417
- httpHeaderAccept?: 'application/json'
1418
- httpContentTypeSelected?: 'application/json;charset=UTF-8'
1419
- }
1410
+ options?: { httpHeaderAccept?: 'application/json' }
1420
1411
  ): Observable<HttpEvent<string>>
1421
1412
  public create(
1422
1413
  sourceUuid: string,
@@ -1434,10 +1425,7 @@ export class RecordsApiService {
1434
1425
  hasAttachmentsOfSource?: boolean,
1435
1426
  observe: any = 'body',
1436
1427
  reportProgress: boolean = false,
1437
- options?: {
1438
- httpHeaderAccept?: 'application/json'
1439
- httpContentTypeSelected?: 'application/json;charset=UTF-8'
1440
- }
1428
+ options?: { httpHeaderAccept?: 'application/json' }
1441
1429
  ): Observable<any> {
1442
1430
  if (sourceUuid === null || sourceUuid === undefined) {
1443
1431
  throw new Error(
@@ -1522,14 +1510,6 @@ export class RecordsApiService {
1522
1510
 
1523
1511
  let headers = this.defaultHeaders
1524
1512
 
1525
- // to determine the Content-Type header
1526
- const consumes: string[] = ['application/json;charset=UTF-8']
1527
- const httpContentTypeSelected: string | undefined =
1528
- this.configuration.selectHeaderContentType(consumes)
1529
- if (httpContentTypeSelected !== undefined) {
1530
- headers = headers.set('Content-Type', httpContentTypeSelected)
1531
- }
1532
-
1533
1513
  let httpHeaderAcceptSelected: string | undefined =
1534
1514
  options && options.httpHeaderAccept
1535
1515
  if (httpHeaderAcceptSelected === undefined) {
@@ -7,6 +7,7 @@ export const openRecord = createAction(
7
7
  '[Editor] Open record',
8
8
  props<{
9
9
  record: CatalogRecord
10
+ alreadySavedOnce: boolean
10
11
  recordSource?: string | null
11
12
  }>()
12
13
  )
@@ -50,13 +51,3 @@ export const hasRecordChangedSinceDraftSuccess = createAction(
50
51
  '[Editor] Has Record Changed Since Draft Success',
51
52
  props<{ changes: { user: string; date: Date } }>()
52
53
  )
53
-
54
- export const isPublished = createAction(
55
- '[Editor] Record Saved But Not Published',
56
- props<{ isPublished: boolean }>()
57
- )
58
-
59
- export const canEditRecord = createAction(
60
- '[Editor] User can edit record',
61
- props<{ canEditRecord: boolean }>()
62
- )