Package framework.beans

Examples of framework.beans.ModificationInfo


            }
        }

        int auditcount = auditDetailsList.size();
        try {
            ModificationInfo remove = getBean().remove();
      afterRemove();
            auditDetailsList.addAll(remove.getAudit());

        } catch (Exception ex) {
            try {
                clearBean();
                ModificationInfo audit = getBean().remove();
                auditDetailsList.addAll(audit.getAudit());
                afterRemove();
            } catch (Exception ex1) {
                clearBean();
                throw new ClipsException("Не удалось удалить объект \'" + understandableName + "\' (" + this.toString() + ")", ex1);
            }
View Full Code Here


    public void save1() throws ClipsException {
        int auditcount = auditDetailsList.size();
        try {
            ecm.sinchronizePrimaryCache();
            if (isNewlyCreated() || (details != null && !details.equals(detailsOriginal))) {
                ModificationInfo modificationInfo = getBean().update(details);
                if (isNewlyCreated()) {
                    details.setId(modificationInfo.getId());
                    initializedID = modificationInfo.getId();
                }
                detailsOriginal = (DETAILSTYPE) details.clone();
                auditDetailsList.addAll(modificationInfo.getAudit());
            }
        } catch (Exception ex) {
            clearBean();
            throw new ClipsException("Не удалось сохранить объект \'"+ understandableName +"\' (" + this.toString()+")", ex);
        }
View Full Code Here

    }

    public int changePassword(char[] aNewPassword, char[] oldPassword) throws ClipsException {
        int r;
        try {
            ModificationInfo mi = getBean().changePassword(
                    SessionPassword.getPasswordHash(aNewPassword),
                    SessionPassword.getPasswordHash(oldPassword));
            r = mi.getId();
            auditDetailsList.addAll(mi.getAudit());
            fireAuditEvent();
        } catch (Exception ex) {
            clearBean();
            throw new ClipsException("Не удалось сменить пароль", ex);
        }
View Full Code Here

     * @param config конфигурация
     * @throws ClipsException
     */
    public void saveGuiConfig(GUIConfig config) throws ClipsException {
        try {
            ModificationInfo mi = getBean().setGUIConfig(config.toXML());
            auditDetailsList.addAll(mi.getAudit());
            fireAuditEvent();
        } catch (Exception ex) {
            clearBean();
            throw new ClipsException("Не удалось сохранить настройки для текущего пользователя", ex);
        }
View Full Code Here

            super(contaner);
        }

        @Override
        protected void saveDB() throws Exception {
            ModificationInfo mi = getBean().setRightsMask(this.get());
            auditDetailsList.addAll(mi.getAudit());
            fireAuditEvent();
        }
View Full Code Here

            Iterator<UserRight> it = rights.get().iterator();
            while (it.hasNext()) {
                UserRight userRights = it.next();
                si.add(userRights.getID());
            }
            ModificationInfo mi = getBean().setRights(si);
            auditDetailsList.addAll(mi.getAudit());
            fireAuditEvent();
        }
View Full Code Here

            Iterator<UserPanel> it = get().iterator();
            while (it.hasNext()) {
                UserPanel userPanel = it.next();
                si.add(userPanel.getClassName());
            }
            ModificationInfo mi = getBean().setPanelList(si);
            auditDetailsList.addAll(mi.getAudit());
            fireAuditEvent();
        }
View Full Code Here

            dangerJob.setLastExam(details.lastExam);
            dangerJob.setExamManually(details.lastExamManually);
        }
        int id = saveEntity(dangerJob);
        auditDJ.check(dangerJob);
        return new ModificationInfo(id, persistAudit(auditDJ));

    }
View Full Code Here

        DangerJob dangerJob = findEntityList(DangerJob.class, f).get(0);//Должна быть одна
        checkTheSame(findEntity(Job.class, dangerJob.getKey().getJob()));
        AuditDoc<DangerJob> auditDJ = new AuditDoc<DangerJob>(dangerJob, getCollaborator());
        manager.remove(dangerJob);
        auditDJ.check(null);
        return new ModificationInfo(0, persistAudit(auditDJ));
    }
View Full Code Here

//        entity = manager.merge(entity);
//        sbr.remove();//и удалим
        //TODO проверить есть ли другие профчекапитемы, ссылающиеся на это заболевание,
        //если нет - удалить его
        //TODO вернуть список аудита
        return new ModificationInfo(entity.getId(), new LinkedList<AuditDetails>());
    }
View Full Code Here

TOP

Related Classes of framework.beans.ModificationInfo

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.