Signed-off-by: Marinov Avgustin <Avgustin.Marinov@bosch.com>
This commit is contained in:
@@ -111,6 +111,7 @@ public final class MgmtDistributionSetMapper {
|
||||
response.setComplete(distributionSet.isComplete());
|
||||
response.setType(distributionSet.getType().getKey());
|
||||
response.setTypeName(distributionSet.getType().getName());
|
||||
response.setLocked(distributionSet.isLocked());
|
||||
response.setDeleted(distributionSet.isDeleted());
|
||||
response.setValid(distributionSet.isValid());
|
||||
|
||||
|
||||
@@ -198,10 +198,10 @@ public class MgmtDistributionSetResource implements MgmtDistributionSetRestApi {
|
||||
public ResponseEntity<MgmtDistributionSet> updateDistributionSet(
|
||||
@PathVariable("distributionSetId") final Long distributionSetId,
|
||||
@RequestBody final MgmtDistributionSetRequestBodyPut toUpdate) {
|
||||
|
||||
final DistributionSet updated = distributionSetManagement.update(entityFactory.distributionSet()
|
||||
.update(distributionSetId).name(toUpdate.getName()).description(toUpdate.getDescription())
|
||||
.version(toUpdate.getVersion()).requiredMigrationStep(toUpdate.getRequiredMigrationStep()));
|
||||
.version(toUpdate.getVersion()).locked(toUpdate.getLocked())
|
||||
.requiredMigrationStep(toUpdate.getRequiredMigrationStep()));
|
||||
|
||||
final MgmtDistributionSet response = MgmtDistributionSetMapper.toResponse(updated);
|
||||
MgmtDistributionSetMapper.addLinks(updated, response);
|
||||
|
||||
@@ -115,6 +115,7 @@ public final class MgmtSoftwareModuleMapper {
|
||||
response.setType(softwareModule.getType().getKey());
|
||||
response.setTypeName(softwareModule.getType().getName());
|
||||
response.setVendor(softwareModule.getVendor());
|
||||
response.setLocked(softwareModule.isLocked());
|
||||
response.setDeleted(softwareModule.isDeleted());
|
||||
response.setEncrypted(softwareModule.isEncrypted());
|
||||
|
||||
|
||||
@@ -248,7 +248,9 @@ public class MgmtSoftwareModuleResource implements MgmtSoftwareModuleRestApi {
|
||||
@RequestBody final MgmtSoftwareModuleRequestBodyPut restSoftwareModule) {
|
||||
final SoftwareModule module = softwareModuleManagement
|
||||
.update(entityFactory.softwareModule().update(softwareModuleId)
|
||||
.description(restSoftwareModule.getDescription()).vendor(restSoftwareModule.getVendor()));
|
||||
.description(restSoftwareModule.getDescription())
|
||||
.vendor(restSoftwareModule.getVendor())
|
||||
.locked(restSoftwareModule.getLocked()));
|
||||
|
||||
final MgmtSoftwareModule response = MgmtSoftwareModuleMapper.toResponse(module);
|
||||
MgmtSoftwareModuleMapper.addLinks(module, response);
|
||||
|
||||
Reference in New Issue
Block a user