|
|
@ -1104,10 +1104,10 @@ public class GenericOperationDAOImpl implements OperationDAO {
|
|
|
|
Map<Integer, List<OperationMapping>> operationMappingsTenantMap = new HashMap<>();
|
|
|
|
Map<Integer, List<OperationMapping>> operationMappingsTenantMap = new HashMap<>();
|
|
|
|
try {
|
|
|
|
try {
|
|
|
|
conn = OperationManagementDAOFactory.getConnection();
|
|
|
|
conn = OperationManagementDAOFactory.getConnection();
|
|
|
|
String sql = "SELECT op.ENROLMENT_ID, op.OPERATION_ID, dt.NAME ,d.TENANT_ID FROM DM_DEVICE d, " +
|
|
|
|
String sql = "SELECT op.ENROLMENT_ID, op.OPERATION_ID, d.DEVICE_IDENTIFICATION, dt.NAME as DEVICE_TYPE, " +
|
|
|
|
"DM_ENROLMENT_OP_MAPPING op, DM_DEVICE_TYPE dt WHERE op.STATUS = ? AND " +
|
|
|
|
"d.TENANT_ID FROM DM_DEVICE d, DM_ENROLMENT_OP_MAPPING op, DM_DEVICE_TYPE dt WHERE op.STATUS = ?" +
|
|
|
|
"op.PUSH_NOTIFICATION_STATUS = ? AND d.DEVICE_TYPE_ID = dt.ID AND d.ID=op.ENROLMENT_ID ORDER BY " +
|
|
|
|
" AND op.PUSH_NOTIFICATION_STATUS = ? AND d.DEVICE_TYPE_ID = dt.ID AND d.ID=op.ENROLMENT_ID ORDER" +
|
|
|
|
"op.OPERATION_ID LIMIT ?";
|
|
|
|
" BY op.OPERATION_ID LIMIT ?";
|
|
|
|
stmt = conn.prepareStatement(sql);
|
|
|
|
stmt = conn.prepareStatement(sql);
|
|
|
|
stmt.setString(1, opStatus.toString());
|
|
|
|
stmt.setString(1, opStatus.toString());
|
|
|
|
stmt.setString(2, pushNotificationStatus.toString());
|
|
|
|
stmt.setString(2, pushNotificationStatus.toString());
|
|
|
@ -1122,8 +1122,11 @@ public class GenericOperationDAOImpl implements OperationDAO {
|
|
|
|
}
|
|
|
|
}
|
|
|
|
operationMapping = new OperationMapping();
|
|
|
|
operationMapping = new OperationMapping();
|
|
|
|
operationMapping.setOperationId(rs.getInt("OPERATION_ID"));
|
|
|
|
operationMapping.setOperationId(rs.getInt("OPERATION_ID"));
|
|
|
|
operationMapping.setDeviceIdentifier(new DeviceIdentifier(String.valueOf(rs.getInt("ENROLMENT_ID")),
|
|
|
|
DeviceIdentifier deviceIdentifier = new DeviceIdentifier();
|
|
|
|
rs.getString("NAME")));
|
|
|
|
deviceIdentifier.setId(rs.getString("DEVICE_IDENTIFICATION"));
|
|
|
|
|
|
|
|
deviceIdentifier.setType(rs.getString("DEVICE_TYPE"));
|
|
|
|
|
|
|
|
operationMapping.setDeviceIdentifier(deviceIdentifier);
|
|
|
|
|
|
|
|
operationMapping.setEnrollmentId(rs.getInt("ENROLMENT_ID"));
|
|
|
|
operationMapping.setTenantId(tenantID);
|
|
|
|
operationMapping.setTenantId(tenantID);
|
|
|
|
operationMappings.add(operationMapping);
|
|
|
|
operationMappings.add(operationMapping);
|
|
|
|
}
|
|
|
|
}
|
|
|
|