BrightSide Workbench Full Report + Source Code
org.turro.contacts.zul.register.TellSomeoneControl Class Reference
Inheritance diagram for org.turro.contacts.zul.register.TellSomeoneControl:
Collaboration diagram for org.turro.contacts.zul.register.TellSomeoneControl:

Public Member Functions

void onRegister (Event event)
 
- Public Member Functions inherited from org.turro.elephant.TemplateControl
void setRootTmpl (String rootTmpl)
 
void setTmpl (String tmpl)
 
void afterCompose ()
 

Additional Inherited Members

- Protected Member Functions inherited from org.turro.elephant.TemplateControl
void doFinally ()
 

Detailed Description

Author
Lluis TurrĂ³ Cutiller lluis.nosp@m.@tur.nosp@m.ro.or.nosp@m.g

Definition at line 46 of file TellSomeoneControl.java.

Member Function Documentation

◆ onRegister()

void org.turro.contacts.zul.register.TellSomeoneControl.onRegister ( Event  event)

Definition at line 60 of file TellSomeoneControl.java.

60  {
61  SignUp su = new SignUp();
62  su.setName(name.getValue());
63  su.setEmail(email.getValue());
64  su.setComment(comment.getValue());
65  if(su.isValid()) {
66  if(existPending(su.getEmail())) {
67  Messages.confirmProcess().add(I_.get("Email pending to confirm"))
68  .paragraph().add(I_.get("Resend confirmation e-mail")).show(() -> {
69  sendEmail(sue);
70  Clients.showNotification(I_.format("Confirmation e-mail has been sent to %s", sue.getEmail()));
71  });
72  } else if(existEmail(su.getEmail())) {
73  Clients.showNotification(I_.format("%s already exists", su.getEmail()));
74  } else {
75  su = new ContactsPU().saveObject(su);
76  sendEmail(su);
77  Clients.showNotification(I_.format("Confirmation e-mail has been sent to %s", su.getEmail()));
78  }
79  } else {
80  Clients.showNotification("No valid values");
81  }
82  }
Here is the call graph for this function:

The documentation for this class was generated from the following file: