Skip to content

Commit

Permalink
MODEXPW-52 - Re-use common schemas (#121)
Browse files Browse the repository at this point in the history
* MODEXPW-52 - Re-use common schemas

* MODEXPW-52 - Re-use common schemas
  • Loading branch information
khandramai authored Dec 13, 2021
1 parent f9610a6 commit 2ae9034
Show file tree
Hide file tree
Showing 65 changed files with 36 additions and 2,110 deletions.
3 changes: 3 additions & 0 deletions .gitmodules
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
[submodule "folio-export-common"]
path = folio-export-common
url = https://github.com/folio-org/folio-export-common.git
1 change: 1 addition & 0 deletions folio-export-common
Submodule folio-export-common added at 3bb12f
Original file line number Diff line number Diff line change
Expand Up @@ -80,7 +80,7 @@ public UserFormat process(User user) {
private String fetchDepartments(User user) {
if (nonNull(user.getDepartments())) {
return user.getDepartments().stream()
.map(id -> userReferenceService.getDepartmentById(id).getName())
.map(id -> userReferenceService.getDepartmentById(id.toString()).getName())
.collect(Collectors.joining(ARRAY_DELIMITER));
}
return EMPTY;
Expand Down
12 changes: 6 additions & 6 deletions src/main/resources/swagger.api/bulk-edit.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -54,16 +54,16 @@ components:
type: string
format: uuid
errors:
$ref: 'schemas/common/errors.json#/Errors'
$ref: '../../../../folio-export-common/schemas/common/errors.json#/Errors'
userGroupCollections:
$ref: 'schemas/user/userGroupCollection.json#/UserGroupCollection'
$ref: '../../../../folio-export-common/schemas/user/userGroupCollection.json#/UserGroupCollection'
addressTypeCollection:
$ref: 'schemas/user/addressTypeCollection.json#/AddressTypeCollection'
$ref: '../../../../folio-export-common/schemas/user/addressTypeCollection.json#/AddressTypeCollection'
proxyForCollection:
$ref: 'schemas/user/proxyForCollection.json#/ProxyForCollection'
$ref: '../../../../folio-export-common/schemas/user/proxyForCollection.json#/ProxyForCollection'
departmentCollection:
$ref: 'schemas/user/departmentCollection.json#/DepartmentCollection'
$ref: '../../../../folio-export-common/schemas/user/departmentCollection.json#/DepartmentCollection'
examples:
errors:
value:
$ref: 'examples/errors.sample'
$ref: '../../../../folio-export-common/examples/errors.sample'
28 changes: 14 additions & 14 deletions src/main/resources/swagger.api/bursar-export.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -13,31 +13,31 @@ paths:
components:
schemas:
userdataCollection:
$ref: 'schemas/user/userCollection.json#/UserCollection'
$ref: '../../../../folio-export-common/schemas/user/userCollection.json#/UserCollection'
accountdataCollection:
$ref: 'schemas/feesfines/accountdataCollection.json#/AccountdataCollection'
$ref: '../../../../folio-export-common/schemas/feesfines/accountdataCollection.json#/AccountdataCollection'
feefineactionCollection:
$ref: 'schemas/feesfines/feefineactionCollection.json#/FeefineactionCollection'
$ref: '../../../../folio-export-common/schemas/feesfines/feefineactionCollection.json#/FeefineactionCollection'
transferdataCollection:
$ref: 'schemas/feesfines/transferdataCollection.json#/TransferdataCollection'
$ref: '../../../../folio-export-common/schemas/feesfines/transferdataCollection.json#/TransferdataCollection'
servicepoints:
$ref: 'schemas/feesfines/servicepoints.json#/ServicePoints'
$ref: '../../../../folio-export-common/schemas/feesfines/servicepoints.json#/ServicePoints'
bursarFeeFines:
$ref: 'schemas/bursarFeeFines.json#/BursarFeeFines'
$ref: '../../../../folio-export-common/schemas/bursarFeeFines.json#/BursarFeeFines'
bursarFeeFinesTypeMapping:
$ref: 'schemas/bursarFeeFinesTypeMapping.json#/BursarFeeFinesTypeMapping'
$ref: '../../../../folio-export-common/schemas/bursarFeeFinesTypeMapping.json#/BursarFeeFinesTypeMapping'
edi:
$ref: 'schemas/acquisitions/edi.json#/Edi'
$ref: '../../../../folio-export-common/schemas/acquisitions/edi.json#/Edi'
ediConfig:
$ref: 'schemas/acquisitions/ediConfig.json#/EdiConfig'
$ref: '../../../../folio-export-common/schemas/acquisitions/ediConfig.json#/EdiConfig'
ediEmail:
$ref: 'schemas/acquisitions/ediEmail.json#/EdiEmail'
$ref: '../../../../folio-export-common/schemas/acquisitions/ediEmail.json#/EdiEmail'
ediFtp:
$ref: 'schemas/acquisitions/ediFtp.json#/EdiFtp'
$ref: '../../../../folio-export-common/schemas/acquisitions/ediFtp.json#/EdiFtp'
ediSchedule:
$ref: 'schemas/acquisitions/ediSchedule.json#/EdiSchedule'
$ref: '../../../../folio-export-common/schemas/acquisitions/ediSchedule.json#/EdiSchedule'
scheduleParameters:
$ref: 'schemas/acquisitions/scheduleParameters.json#/ScheduleParameters'
$ref: '../../../../folio-export-common/schemas/acquisitions/scheduleParameters.json#/ScheduleParameters'
vendorEdiOrdersExportConfig:
$ref: 'schemas/acquisitions/vendorEdiOrdersExportConfig.json#/VendorEdiOrdersExportConfig'
$ref: '../../../../folio-export-common/schemas/acquisitions/vendorEdiOrdersExportConfig.json#/VendorEdiOrdersExportConfig'

22 changes: 11 additions & 11 deletions src/main/resources/swagger.api/circulation-log.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -13,24 +13,24 @@ paths:
components:
schemas:
logRecord:
$ref: 'schemas/circulationlog/logRecord.json#/LogRecord'
$ref: '../../../../folio-export-common/schemas/circulationlog/logRecord.json#/LogRecord'
logRecordCollection:
$ref: 'schemas/circulationlog/logRecordCollection.json#/LogRecordCollection'
$ref: '../../../../folio-export-common/schemas/circulationlog/logRecordCollection.json#/LogRecordCollection'
configuration:
$ref: 'schemas/configuration/configuration.json#/Configuration'
$ref: '../../../../folio-export-common/schemas/configuration/configuration.json#/Configuration'
configurationCollection:
$ref: 'schemas/configuration/configurationCollection.json#/ConfigurationCollection'
$ref: '../../../../folio-export-common/schemas/configuration/configurationCollection.json#/ConfigurationCollection'
job:
$ref: 'schemas/job.json#/Job'
$ref: '../../../../folio-export-common/schemas/job.json#/Job'
exportType:
$ref: 'schemas/exportType.json#/ExportType'
$ref: '../../../../folio-export-common/schemas/exportType.json#/ExportType'
entityType:
$ref: 'schemas/entityType.json#/EntityType'
$ref: '../../../../folio-export-common/schemas/entityType.json#/EntityType'
progress:
$ref: 'schemas/progress.json#/Progress'
$ref: '../../../../folio-export-common/schemas/progress.json#/Progress'
identifierType:
$ref: 'schemas/identifierType.json#/IdentifierType'
$ref: '../../../../folio-export-common/schemas/identifierType.json#/IdentifierType'
jobStatus:
$ref: 'schemas/jobStatus.json#/JobStatus'
$ref: '../../../../folio-export-common/schemas/jobStatus.json#/JobStatus'
exportTypeSpecificParameters:
$ref: 'schemas/exportTypeSpecificParameters.json#/ExportTypeSpecificParameters'
$ref: '../../../../folio-export-common/schemas/exportTypeSpecificParameters.json#/ExportTypeSpecificParameters'
11 changes: 0 additions & 11 deletions src/main/resources/swagger.api/examples/error.sample

This file was deleted.

15 changes: 0 additions & 15 deletions src/main/resources/swagger.api/examples/errors.sample

This file was deleted.

66 changes: 0 additions & 66 deletions src/main/resources/swagger.api/schemas/acquisitions/edi.json

This file was deleted.

16 changes: 0 additions & 16 deletions src/main/resources/swagger.api/schemas/acquisitions/ediConfig.json

This file was deleted.

21 changes: 0 additions & 21 deletions src/main/resources/swagger.api/schemas/acquisitions/ediEmail.json

This file was deleted.

66 changes: 0 additions & 66 deletions src/main/resources/swagger.api/schemas/acquisitions/ediFtp.json

This file was deleted.

This file was deleted.

Loading

0 comments on commit 2ae9034

Please sign in to comment.