291292293294295296297298299300301
Payee payee = Payee.findByName(register.getPayee()); if (payee == null) { payee = new Payee(); payee.setName(register.getPayee()); payee.setOwner(account.getOwner()); payee.persist(); payee.flush(); } return payee; }
5960616263646566676869
@Override public void createPayee(UserDetails owner, String name) { if (hasText(name) && (owner != null)) { Payee payee = new Payee(); payee.setName(name); payee.setOwner(owner); payee.persist(); owner.getPayees().add(payee); owner.merge(); } }