This is an automated email from the git hooks/post-receive script. New commit to branch develop in repository faxtomail. See http://git.codelutin.com/faxtomail.git commit 02c15131eedf2c9752d5ce45753cdbbcfed91a9a Author: Kevin Morin <morin@codelutin.com> Date: Fri Aug 28 15:18:28 2015 +0200 modification du modèle pour configurer les tmapons par utilisateur et groupe ldap (refs #7492) --- faxtomail-persistence/src/main/xmi/faxtomail.zargo | Bin 32540 -> 32658 bytes .../services/service/MailFolderServiceImpl.java | 32 +++++------ .../h2/V1_5_0_150828__configure_stamps_by_ldap.sql | 39 ++++++++++++++ .../V1_5_0_150828__configure_stamps_by_ldap.sql | 59 +++++++++++++++++++++ 4 files changed, 115 insertions(+), 15 deletions(-) diff --git a/faxtomail-persistence/src/main/xmi/faxtomail.zargo b/faxtomail-persistence/src/main/xmi/faxtomail.zargo index dc84d52..ca3e46f 100644 Binary files a/faxtomail-persistence/src/main/xmi/faxtomail.zargo and b/faxtomail-persistence/src/main/xmi/faxtomail.zargo differ diff --git a/faxtomail-service/src/main/java/com/franciaflex/faxtomail/services/service/MailFolderServiceImpl.java b/faxtomail-service/src/main/java/com/franciaflex/faxtomail/services/service/MailFolderServiceImpl.java index 592863d..c60665d 100644 --- a/faxtomail-service/src/main/java/com/franciaflex/faxtomail/services/service/MailFolderServiceImpl.java +++ b/faxtomail-service/src/main/java/com/franciaflex/faxtomail/services/service/MailFolderServiceImpl.java @@ -356,20 +356,22 @@ public class MailFolderServiceImpl extends FaxToMailServiceSupport implements Ma @Override public Collection<Stamp> getPdfEditorStamps(String mailFolderId) { - MailFolder folder = getMailFolder(mailFolderId); - while (folder.getParent() != null && !folder.isUseCurrentLevelPdfEditorStamps()) { - folder = folder.getParent(); - } - - Collection<Stamp> pdfEditorStamps; - if (folder != null) { - pdfEditorStamps = folder.getPdfEditorStamps(); - Hibernate.initialize(pdfEditorStamps); - - } else { - pdfEditorStamps = null; - } - - return pdfEditorStamps; +// MailFolder folder = getMailFolder(mailFolderId); +// while (folder.getParent() != null && !folder.isUseCurrentLevelPdfEditorStamps()) { +// folder = folder.getParent(); +// } +// +// Collection<Stamp> pdfEditorStamps; +// if (folder != null) { +// pdfEditorStamps = folder.getPdfEditorStamps(); +// Hibernate.initialize(pdfEditorStamps); +// +// } else { +// pdfEditorStamps = null; +// } +// +// return pdfEditorStamps; + // FIXME + return null; } } diff --git a/faxtomail-service/src/main/resources/db/migration/h2/V1_5_0_150828__configure_stamps_by_ldap.sql b/faxtomail-service/src/main/resources/db/migration/h2/V1_5_0_150828__configure_stamps_by_ldap.sql new file mode 100644 index 0000000..bdabba6 --- /dev/null +++ b/faxtomail-service/src/main/resources/db/migration/h2/V1_5_0_150828__configure_stamps_by_ldap.sql @@ -0,0 +1,39 @@ +-- remove configuration by mail folder + +alter table mailfolder drop column usecurrentlevelpdfeditorstamps; + +drop table MAILFOLDER_PDFEDITORSTAMPS; + +create table FAXTOMAILUSER_PDFEDITORSTAMPS ( + FAXTOMAILUSER varchar(255) not null, + PDFEDITORSTAMPS varchar(255) not null +); + +alter table FAXTOMAILUSER_PDFEDITORSTAMPS + add constraint FK_9EMRBYUL9EJBXBXDRISLN1W56_INDEX_F + foreign key (FAXTOMAILUSER) + references FAXTOMAILUSER; + +alter table FAXTOMAILUSER_PDFEDITORSTAMPS + add constraint FK_RC8JM7WI0GR4O05CL6BKRCC9T_INDEX_F + foreign key (PDFEDITORSTAMPS) + references STAMP; + +CREATE INDEX idx_FAXTOMAILUSER_PDFEDITORSTAMPS ON FAXTOMAILUSER_PDFEDITORSTAMPS(FAXTOMAILUSER); + +create table FAXTOMAILUSERGROUP_PDFEDITORSTAMPS ( + FAXTOMAILUSERGROUP varchar(255) not null, + PDFEDITORSTAMPS varchar(255) not null +); + +alter table FAXTOMAILUSERGROUP_PDFEDITORSTAMPS + add constraint FK_47041IYC9CUBBX7OB6E1B32QD + foreign key (FAXTOMAILUSERGROUP) + references FAXTOMAILUSERGROUP; + +alter table FAXTOMAILUSERGROUP_PDFEDITORSTAMPS + add constraint FK_6I724UYTC1U81R3LXHKMWVF55_INDEX_F + foreign key (PDFEDITORSTAMPS) + references STAMP; + +CREATE INDEX idx_FAXTOMAILUSERGROUP_PDFEDITORSTAMPS ON FAXTOMAILUSERGROUP_PDFEDITORSTAMPS(FAXTOMAILUSERGROUP); \ No newline at end of file diff --git a/faxtomail-service/src/main/resources/db/migration/sqlserver/V1_5_0_150828__configure_stamps_by_ldap.sql b/faxtomail-service/src/main/resources/db/migration/sqlserver/V1_5_0_150828__configure_stamps_by_ldap.sql new file mode 100644 index 0000000..56183cd --- /dev/null +++ b/faxtomail-service/src/main/resources/db/migration/sqlserver/V1_5_0_150828__configure_stamps_by_ldap.sql @@ -0,0 +1,59 @@ +-- remove configuration by mail folder + +alter table mailfolder drop column usecurrentlevelpdfeditorstamps; + +GO + +drop table MAILFOLDER_PDFEDITORSTAMPS; + +GO + +create table FAXTOMAILUSER_PDFEDITORSTAMPS ( + FAXTOMAILUSER varchar(255) not null, + PDFEDITORSTAMPS varchar(255) not null +); + +GO + +alter table FAXTOMAILUSER_PDFEDITORSTAMPS + add constraint FK_9EMRBYUL9EJBXBXDRISLN1W56_INDEX_F + foreign key (FAXTOMAILUSER) + references FAXTOMAILUSER; + +GO + +alter table FAXTOMAILUSER_PDFEDITORSTAMPS + add constraint FK_RC8JM7WI0GR4O05CL6BKRCC9T_INDEX_F + foreign key (PDFEDITORSTAMPS) + references STAMP; + +GO + +CREATE INDEX idx_FAXTOMAILUSER_PDFEDITORSTAMPS ON FAXTOMAILUSER_PDFEDITORSTAMPS(FAXTOMAILUSER); + +GO + +create table FAXTOMAILUSERGROUP_PDFEDITORSTAMPS ( + FAXTOMAILUSERGROUP varchar(255) not null, + PDFEDITORSTAMPS varchar(255) not null +); + +GO + +alter table FAXTOMAILUSERGROUP_PDFEDITORSTAMPS + add constraint FK_47041IYC9CUBBX7OB6E1B32QD + foreign key (FAXTOMAILUSERGROUP) + references FAXTOMAILUSERGROUP; + +GO + +alter table FAXTOMAILUSERGROUP_PDFEDITORSTAMPS + add constraint FK_6I724UYTC1U81R3LXHKMWVF55_INDEX_F + foreign key (PDFEDITORSTAMPS) + references STAMP; + +GO + +CREATE INDEX idx_FAXTOMAILUSERGROUP_PDFEDITORSTAMPS ON FAXTOMAILUSERGROUP_PDFEDITORSTAMPS(FAXTOMAILUSERGROUP); + +GO \ No newline at end of file -- To stop receiving notification emails like this one, please contact codelutin.com SCM administrator <admin+scm@codelutin.com>.