Opraveny chyby v agendě Střediska/komise.

refs #97
multitenant
Josef Rokos 11 years ago
parent 8c204e0d7a
commit 7519f4d04b

@ -40,7 +40,12 @@ public abstract class BaseDaoJPA<T> implements BaseDao<T> {
@Override
public void delete(T entity) {
sessionFactory.getCurrentSession().delete(entity);
try {
sessionFactory.getCurrentSession().delete(entity);
} catch (NonUniqueObjectException e) {
Object o = sessionFactory.getCurrentSession().merge(entity);
sessionFactory.getCurrentSession().delete(o);
}
}
@Override

@ -124,7 +124,7 @@ public class WorkgroupForm extends FormViewModel<Workgroup> {
return;
}
getDataBean().removeMember(u);
workgroupService.removeMember(getDataBean(), u);
if (!target.equals("users")) {
moveUser(u.getMember(), event);

@ -67,7 +67,7 @@
<rows>
<template name="model" var="member">
<row visible="@load(member.role eq each)">
<label value="@load(member.member.fullName)"/>
<hbox><image src="/img/user-small-red.png"/><label value="@load(member.member.fullName)"/></hbox>
</row>
</template>
</rows>

Loading…
Cancel
Save