◆ addAttendeesByEntity()
void org.turro.publication.zul.ctrl.SubscriptorsGrid.addAttendeesByEntity |
( |
String |
entityPath, |
|
|
boolean |
deep |
|
) |
| |
Definition at line 116 of file SubscriptorsGrid.java.
117 if(Strings.isBlank(entityPath))
return;
118 AssistantSet as =
new AssistantSet();
119 Assistants.addAssistants(entityPath, deep, as, deep ? AssistantConstants.all() :
null);
120 Dao dao =
new PublicationPU();
121 for(Assistant a : as) {
122 Contact contact = (Contact) a.contact.getContact();
123 Connector email = contact.getConnectorMap().get(IUser.CONNECTOR_EMAIL);
124 if(email !=
null && !Strings.isBlank(email.getValue())) {
125 if(dao.getSingleResultOrNull(
126 "select ps from PublicationSubscription ps " +
127 "where ps.idContact = ? " +
128 "and ps.publicationCategory = ?",
129 new Object[] { contact.getId(), publicationCategory }
131 PublicationSubscription ps =
new PublicationSubscription();
132 ps.setCreation(
new Date());
133 ps.setPublicationCategory(publicationCategory);
134 ps.setIdContact(contact.getId());
136 SystemLogger.getInstance().doLog(SystemLogType.LOG_INFO, publicationCategory,
137 "subscribed", contact.getName());
◆ addContact()
void org.turro.publication.zul.ctrl.SubscriptorsGrid.addContact |
( |
Contact |
contact | ) |
|
Definition at line 63 of file SubscriptorsGrid.java.
67 Dao dao =
new PublicationPU();
68 Connector email = contact.getConnectorMap().get(IUser.CONNECTOR_EMAIL);
69 if(email !=
null && !Strings.isBlank(email.getValue())) {
70 if(dao.getSingleResultOrNull(
71 "select ps from PublicationSubscription ps " +
72 "where ps.idContact = ? " +
73 "and ps.publicationCategory = ?",
74 new Object[] { contact.getId(), publicationCategory }
76 PublicationSubscription ps =
new PublicationSubscription();
77 ps.setCreation(
new Date());
78 ps.setPublicationCategory(publicationCategory);
79 ps.setIdContact(contact.getId());
81 SystemLogger.getInstance().doLog(SystemLogType.LOG_INFO, publicationCategory,
82 "subscribed", contact.getName());
◆ pasteContacts()
void org.turro.publication.zul.ctrl.SubscriptorsGrid.pasteContacts |
( |
| ) |
|
Definition at line 88 of file SubscriptorsGrid.java.
89 List<Contact> contacts = (List<Contact>) Framework.getClipboard().get(
"bbf_clip_contact");
90 if(contacts !=
null && publicationCategory !=
null) {
91 Dao dao =
new PublicationPU();
92 for(Contact contact : contacts) {
93 Connector email = contact.getConnectorMap().get(IUser.CONNECTOR_EMAIL);
94 if(email !=
null && !Strings.isBlank(email.getValue())) {
95 if(dao.getSingleResultOrNull(
96 "select ps from PublicationSubscription ps " +
97 "where ps.idContact = ? " +
98 "and ps.publicationCategory = ?",
99 new Object[] { contact.getId(), publicationCategory }
101 PublicationSubscription ps =
new PublicationSubscription();
102 ps.setCreation(
new Date());
103 ps.setPublicationCategory(publicationCategory);
104 ps.setIdContact(contact.getId());
106 SystemLogger.getInstance().doLog(SystemLogType.LOG_INFO, publicationCategory,
107 "subscribed", contact.getName());
111 Framework.getClipboard().remove(
"bbf_clip_contact");
◆ setPublicationCategory()
void org.turro.publication.zul.ctrl.SubscriptorsGrid.setPublicationCategory |
( |
PublicationCategory |
publicationCategory | ) |
|
The documentation for this class was generated from the following file: