resourceDetails.withLoanId(resourceId);
break;
case LOAN_TRANSACTION:
resourceNameForPermissions = "LOANTRANSACTIONNOTE";
// updating loanId, to distinguish saving transaction note and loan transaction note as we are using subEntityId for both.
resourceDetails.withLoanId(resourceId);
resourceDetails.withSubEntityId(resourceId);
break;
case SAVING_ACCOUNT:
resourceNameForPermissions = "SAVINGNOTE";
resourceDetails.withSavingsId(resourceId);