implemented QR code tips controller, delete email message, delete all email messages
This commit is contained in:
@@ -111,7 +111,7 @@ public class QRCodeTypeService {
|
||||
// Create the QR Code Instance based on the QR Code Type & insert into the respective table
|
||||
QRCodeModel<?> qrCodeModel = qrCodeFactoryProvider.createQRCodeInstance(scannedQR);
|
||||
qrCodeModel.setDetails();
|
||||
// Get classifications based on verificationsv
|
||||
// Get classifications based on verifications
|
||||
scannedQR.setResult(qrCodeModel.retrieveClassification());
|
||||
// update result category in qrcode table
|
||||
qrCodeRepository.save(scannedQR);
|
||||
|
||||
@@ -428,6 +428,19 @@ public class URLVerificationService {
|
||||
|
||||
// Get Classification using ML Model
|
||||
public String getClassification(URLModel urlModel){
|
||||
return predictionService.predict(urlModel);
|
||||
// Call ML model
|
||||
String category = predictionService.predict(urlModel);
|
||||
|
||||
//update in category in url table
|
||||
|
||||
|
||||
// return classification results
|
||||
if (category.equals(CAT_BENIGN)) {
|
||||
if (!urlModel.getDetails().getTrackingDescriptions().isEmpty()) {
|
||||
return CLASSIFY_WARNING;
|
||||
}
|
||||
return CLASSIFY_SAFE;
|
||||
}
|
||||
return CLASSIFY_UNSAFE;
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user