X-Git-Url: http://git.salome-platform.org/gitweb/?a=blobdiff_plain;f=Workspace%2FSiman-Common%2Fsrc%2Forg%2Fsplat%2Fservice%2FDocumentServiceImpl.java;h=c8494b13e70cf1fcd931b082cd3b4ca9ba3152ab;hb=6a2367e3294bdbfeb52db913235e0942898f6586;hp=61cda0b46ee7e5c8ccfa885e202e0548e3f7b13c;hpb=e8e274ac324f2c05bbfd58f4584f03f17a88883b;p=tools%2Fsiman.git diff --git a/Workspace/Siman-Common/src/org/splat/service/DocumentServiceImpl.java b/Workspace/Siman-Common/src/org/splat/service/DocumentServiceImpl.java index 61cda0b..c8494b1 100644 --- a/Workspace/Siman-Common/src/org/splat/service/DocumentServiceImpl.java +++ b/Workspace/Siman-Common/src/org/splat/service/DocumentServiceImpl.java @@ -126,7 +126,7 @@ public class DocumentServiceImpl implements DocumentService { Study owner = dprop.getOwner().getOwnerStudy(); // Synchronize the object with the current Hibernate session. - //owner = getStudyDAO().merge(owner); + // owner = getStudyDAO().merge(owner); SimpleDateFormat tostring = new SimpleDateFormat("yyyy"); // RKV: NOPMD: TODO: Use locale here? String year = tostring.format(owner.getDate()); @@ -144,7 +144,7 @@ public class DocumentServiceImpl implements DocumentService { .toString(); aDoc.getFile().changePath(path); owner = getStudyDAO().merge(owner); -// getStudyDAO().update(owner); + // getStudyDAO().update(owner); } /** @@ -167,8 +167,8 @@ public class DocumentServiceImpl implements DocumentService { encoding.append(scope.getReference()).append("_").append( tostring.format(number)); } else { // title and (temporarily) asis - encoding.append(aDoc.getTitle()).append("_").append( - tostring.format(number)); + encoding.append("_").append(tostring.format(number)).append( + aDoc.getFile().getName()); } return encoding.toString(); } @@ -318,7 +318,7 @@ public class DocumentServiceImpl implements DocumentService { aDoc.getAllRelations().add(attach); getDocumentDAO().merge(aDoc); - + return attach; } @@ -745,6 +745,7 @@ public class DocumentServiceImpl implements DocumentService { /** * Get the relationDAO. + * * @return the relationDAO */ public RelationDAO getRelationDAO() { @@ -753,7 +754,9 @@ public class DocumentServiceImpl implements DocumentService { /** * Set the relationDAO. - * @param relationDAO the relationDAO to set + * + * @param relationDAO + * the relationDAO to set */ public void setRelationDAO(final RelationDAO relationDAO) { _relationDAO = relationDAO;