diff --git a/pom.xml b/pom.xml
index 5ac9667be..af0b32e11 100644
--- a/pom.xml
+++ b/pom.xml
@@ -3,7 +3,7 @@
4.0.0
de.rwth.idsg
steve
- 1.0.10
+ 1.0.11
jar
diff --git a/src/main/java/de/rwth/idsg/steve/service/CentralSystemService12_Service.java b/src/main/java/de/rwth/idsg/steve/service/CentralSystemService12_Service.java
index f77d70e37..20b169133 100644
--- a/src/main/java/de/rwth/idsg/steve/service/CentralSystemService12_Service.java
+++ b/src/main/java/de/rwth/idsg/steve/service/CentralSystemService12_Service.java
@@ -99,23 +99,17 @@ public DiagnosticsStatusNotificationResponse diagnosticsStatusNotification(Diagn
public StartTransactionResponse startTransaction(StartTransactionRequest parameters, String chargeBoxIdentity) {
log.debug("Executing startTransaction for {}", chargeBoxIdentity);
- // Get the authorization info of the user
String idTag = parameters.getIdTag();
- IdTagInfo idTagInfo = userService.getIdTagInfoV12(idTag);
-
- StartTransactionResponse response = new StartTransactionResponse().withIdTagInfo(idTagInfo);
-
- if (AuthorizationStatus.ACCEPTED.equals(idTagInfo.getStatus())) {
- int connectorId = parameters.getConnectorId();
- Timestamp startTimestamp = new Timestamp(parameters.getTimestamp().getMillis());
- String startMeterValue = Integer.toString(parameters.getMeterStart());
+ int connectorId = parameters.getConnectorId();
+ Timestamp startTimestamp = new Timestamp(parameters.getTimestamp().getMillis());
+ String startMeterValue = Integer.toString(parameters.getMeterStart());
- Integer transactionId = ocppServerRepository.insertTransaction12(chargeBoxIdentity,connectorId, idTag,
- startTimestamp, startMeterValue);
+ Integer transactionId = ocppServerRepository.insertTransaction12(chargeBoxIdentity, connectorId, idTag,
+ startTimestamp, startMeterValue);
- response.setTransactionId(transactionId);
- }
- return response;
+ return new StartTransactionResponse()
+ .withIdTagInfo(userService.getIdTagInfoV12(idTag))
+ .withTransactionId(transactionId);
}
public StopTransactionResponse stopTransaction(StopTransactionRequest parameters, String chargeBoxIdentity) {
diff --git a/src/main/java/de/rwth/idsg/steve/service/CentralSystemService15_Service.java b/src/main/java/de/rwth/idsg/steve/service/CentralSystemService15_Service.java
index 0c1e00ad9..55af9f088 100644
--- a/src/main/java/de/rwth/idsg/steve/service/CentralSystemService15_Service.java
+++ b/src/main/java/de/rwth/idsg/steve/service/CentralSystemService15_Service.java
@@ -112,25 +112,19 @@ public DiagnosticsStatusNotificationResponse diagnosticsStatusNotification(Diagn
public StartTransactionResponse startTransaction(StartTransactionRequest parameters, String chargeBoxIdentity) {
log.debug("Executing startTransaction for {}", chargeBoxIdentity);
- // Get the authorization info of the user
String idTag = parameters.getIdTag();
- IdTagInfo idTagInfo = userService.getIdTagInfoV15(idTag);
-
- StartTransactionResponse response = new StartTransactionResponse().withIdTagInfo(idTagInfo);
-
- if (AuthorizationStatus.ACCEPTED.equals(idTagInfo.getStatus())) {
- int connectorId = parameters.getConnectorId();
- Integer reservationId = parameters.getReservationId();
- Timestamp startTimestamp = new Timestamp(parameters.getTimestamp().getMillis());
+ int connectorId = parameters.getConnectorId();
+ Integer reservationId = parameters.getReservationId();
+ Timestamp startTimestamp = new Timestamp(parameters.getTimestamp().getMillis());
+ String startMeterValue = Integer.toString(parameters.getMeterStart());
- String startMeterValue = Integer.toString(parameters.getMeterStart());
- Integer transactionId = ocppServerRepository.insertTransaction15(chargeBoxIdentity, connectorId, idTag,
- startTimestamp, startMeterValue,
- reservationId);
+ Integer transactionId = ocppServerRepository.insertTransaction15(chargeBoxIdentity, connectorId, idTag,
+ startTimestamp, startMeterValue,
+ reservationId);
- response.setTransactionId(transactionId);
- }
- return response;
+ return new StartTransactionResponse()
+ .withIdTagInfo(userService.getIdTagInfoV15(idTag))
+ .withTransactionId(transactionId);
}
public StopTransactionResponse stopTransaction(StopTransactionRequest parameters, String chargeBoxIdentity) {