Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- @Override
- public void execute(GDSModel model) throws GDSCommandExecutionException {
- se.apendo.hls.dto.gds.ObjectFactory objFac = new se.apendo.hls.dto.gds.ObjectFactory();
- if (getInnehavsanteckning() == null) {
- throw new GDSCommandExecutionException("Command CreateInteckning not configured correctly.");
- }
- setup();
- ForandringType f = new ForandringType();
- GDSInnehavsanteckning inneInteck = model.getInnehavsinteckningByUuid(this.innehavsanteckningUuid);
- model.getInnehavsanteckningar().remove(inneInteck);
- InnehavsanteckningType innehavToDelete = inneInteck.getGdsInnehavsanteckning();
- getBerorList().add(innehavToDelete.getAktnummer());
- InskrivningsatgardType atgard = GDSUtils.getNewInskrivningsatgardType(model, InskrivningsatgardstypType.INTECKNING);
- f.setId("ID_" + UUID.randomUUID().toString());
- f.setVerksamhetsatgard(objFac.createInskrivningsatgard(atgard));
- UtbytesobjektPropertyType upRad = new UtbytesobjektPropertyType();
- f.setRaderat(upRad);
- atgard.getUtbytesobjektsreferens().add(GDSUtils.getNewUtbytesobjektReferens(innehavToDelete));
- upRad.getUtbytesobjekt().add(objFac.createInnehavsanteckning(GDSUtils.cloneUtbytesobjekt((innehavToDelete))));
- getFastighetList().addAll(model.getFastighetByInteckningUuid(inteckning.getGdsInteckning().getObjektidentitet()));
- getForandringar().add(f);
- }
Add Comment
Please, Sign In to add comment