-
Notifications
You must be signed in to change notification settings - Fork 21
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: added POST /api/subsystems endpoint
- v0.17.12
- v0.17.11
- v0.17.10
- v0.17.9
- v0.17.7
- v0.17.6
- v0.17.5
- v0.17.4
- v0.17.3
- v0.17.2
- v0.17.1
- v0.17.0
- v0.16.9
- v0.16.8
- v0.16.7
- v0.16.6
- v0.16.4
- v0.16.3
- v0.16.0
- v0.14.0
- v0.13.0
- v0.6.0
- v0.5.0
- @aliceo2/bookkeeping@1.7.0
- @aliceo2/bookkeeping@1.6.0
- @aliceo2/bookkeeping@1.5.0
- @aliceo2/bookkeeping@1.4.1
- @aliceo2/bookkeeping@1.4.0
- @aliceo2/bookkeeping@1.3.0
- @aliceo2/bookkeeping@1.2.0
- @aliceo2/bookkeeping@1.1.0
- @aliceo2/bookkeeping@1.0.1
- @aliceo2/bookkeeping@1.0.0
- @aliceo2/bookkeeping@0.99.1
- @aliceo2/bookkeeping@0.99.0
- @aliceo2/bookkeeping@0.98.0
- @aliceo2/bookkeeping@0.97.0
- @aliceo2/bookkeeping@0.96.0
- @aliceo2/bookkeeping@0.95.0
- @aliceo2/bookkeeping@0.94.0
- @aliceo2/bookkeeping@0.93.0
- @aliceo2/bookkeeping@0.92.0
- @aliceo2/bookkeeping@0.91.0
- @aliceo2/bookkeeping@0.90.0
- @aliceo2/bookkeeping@0.89.2
- @aliceo2/bookkeeping@0.89.1
- @aliceo2/bookkeeping@0.89.0
- @aliceo2/bookkeeping@0.88.0
- @aliceo2/bookkeeping@0.87.0
- @aliceo2/bookkeeping@0.86.0
- @aliceo2/bookkeeping@0.85.0
- @aliceo2/bookkeeping@0.84.0
- @aliceo2/bookkeeping@0.83.0
- @aliceo2/bookkeeping@0.82.0
- @aliceo2/bookkeeping@0.81.0
- @aliceo2/bookkeeping@0.80.0
- @aliceo2/bookkeeping@0.79.0
- @aliceo2/bookkeeping@0.78.1
- @aliceo2/bookkeeping@0.78.0
- @aliceo2/bookkeeping@0.77.0
- @aliceo2/bookkeeping@0.76.0
- @aliceo2/bookkeeping@0.75.0
- @aliceo2/bookkeeping@0.74.0
- @aliceo2/bookkeeping@0.73.0
- @aliceo2/bookkeeping@0.72.0
- @aliceo2/bookkeeping@0.71.0
- @aliceo2/bookkeeping@0.70.0
- @aliceo2/bookkeeping@0.69.0
- @aliceo2/bookkeeping@0.68.0
- @aliceo2/bookkeeping@0.67.0
- @aliceo2/bookkeeping@0.66.0
- @aliceo2/bookkeeping@0.65.0
- @aliceo2/bookkeeping@0.64.0
- @aliceo2/bookkeeping@0.63.1
- @aliceo2/bookkeeping@0.63.0
- @aliceo2/bookkeeping@0.62.0
- @aliceo2/bookkeeping@0.61.0
- @aliceo2/bookkeeping@0.60.0
- @aliceo2/bookkeeping@0.59.1
- @aliceo2/bookkeeping@0.59.0
- @aliceo2/bookkeeping@0.58.0
- @aliceo2/bookkeeping@0.57.0
- @aliceo2/bookkeeping@0.56.1
- @aliceo2/bookkeeping@0.56.0
- @aliceo2/bookkeeping@0.55.2
- @aliceo2/bookkeeping@0.55.1
- @aliceo2/bookkeeping@0.55.0
- @aliceo2/bookkeeping@0.54.0
- @aliceo2/bookkeeping@0.53.1
- @aliceo2/bookkeeping@0.53.0
- @aliceo2/bookkeeping@0.52.0
- @aliceo2/bookkeeping@0.51.0
- @aliceo2/bookkeeping@0.50.0
- @aliceo2/bookkeeping@0.49.1
- @aliceo2/bookkeeping@0.49.0
- @aliceo2/bookkeeping@0.48.0
- @aliceo2/bookkeeping@0.47.0
- @aliceo2/bookkeeping@0.46.0
- @aliceo2/bookkeeping@0.45.0
- @aliceo2/bookkeeping@0.44.1
- @aliceo2/bookkeeping@0.44.0
- @aliceo2/bookkeeping@0.43.0
- @aliceo2/bookkeeping@0.42.0
- @aliceo2/bookkeeping@0.41.0
- @aliceo2/bookkeeping@0.40.0
- @aliceo2/bookkeeping@0.39.0
- @aliceo2/bookkeeping@0.38.0
- @aliceo2/bookkeeping@0.37.0
- @aliceo2/bookkeeping@0.36.0
- @aliceo2/bookkeeping@0.35.0
- @aliceo2/bookkeeping@0.34.0
- @aliceo2/bookkeeping@0.33.0
- @aliceo2/bookkeeping@0.32.0
- @aliceo2/bookkeeping@0.31.0
- @aliceo2/bookkeeping@0.30.0
- @aliceo2/bookkeeping@0.29.0
- @aliceo2/bookkeeping@0.28.0
- @aliceo2/bookkeeping@0.27.0
- @aliceo2/bookkeeping@0.26.1
- @aliceo2/bookkeeping@0.26.0
- @aliceo2/bookkeeping@0.25.0
- @aliceo2/bookkeeping@0.24.0
- @aliceo2/bookkeeping@0.23.0
- @aliceo2/bookkeeping@0.22.0
- @aliceo2/bookkeeping@0.21.1
- @aliceo2/bookkeeping@0.21.0
- @aliceo2/bookkeeping@0.20.1
- @aliceo2/bookkeeping@0.20.0
- @aliceo2/bookkeeping@0.19.0
- @aliceo2/bookkeeping@0.18.0
- V0.16.5
- V0.16.2
Showing
11 changed files
with
329 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
/** | ||
* @license | ||
* Copyright CERN and copyright holders of ALICE O2. This software is | ||
* distributed under the terms of the GNU General Public License v3 (GPL | ||
* Version 3), copied verbatim in the file "COPYING". | ||
* | ||
* See http://alice-o2.web.cern.ch/license for full licensing information. | ||
* | ||
* In applying this license CERN does not waive the privileges and immunities | ||
* granted to it by virtue of its status as an Intergovernmental Organization | ||
* or submit itself to any jurisdiction. | ||
*/ | ||
|
||
const Joi = require('@hapi/joi'); | ||
|
||
const BodyDto = Joi.object({ | ||
name: Joi.string() | ||
.required(), | ||
}); | ||
|
||
const QueryDto = Joi.object({ | ||
token: Joi.string(), | ||
}); | ||
|
||
const CreateSubsystemDto = Joi.object({ | ||
query: QueryDto, | ||
body: BodyDto, | ||
params: Joi.object({}), | ||
}); | ||
|
||
module.exports = CreateSubsystemDto; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,39 @@ | ||
/** | ||
* @license | ||
* Copyright CERN and copyright holders of ALICE O2. This software is | ||
* distributed under the terms of the GNU General Public License v3 (GPL | ||
* Version 3), copied verbatim in the file "COPYING". | ||
* | ||
* See http://alice-o2.web.cern.ch/license for full licensing information. | ||
* | ||
* In applying this license CERN does not waive the privileges and immunities | ||
* granted to it by virtue of its status as an Intergovernmental Organization | ||
* or submit itself to any jurisdiction. | ||
*/ | ||
|
||
const { | ||
repositories: { | ||
SubsystemRepository, | ||
}, | ||
utilities: { | ||
TransactionHelper, | ||
}, | ||
} = require('../../database'); | ||
|
||
/** | ||
* CreateSubsystemUseCase | ||
*/ | ||
class CreateSubsystemUseCase { | ||
/** | ||
* Executes this use case. | ||
* | ||
* @param {Object} dto The CreateSubsystemDto containing all data. | ||
* @returns {Promise} Promise object represents the result of this use case. | ||
*/ | ||
async execute(dto) { | ||
const { body } = dto; | ||
return TransactionHelper.provide(() => SubsystemRepository.insert(body)); | ||
} | ||
} | ||
|
||
module.exports = CreateSubsystemUseCase; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.