- Author
- Lluis TurrĂ³ Cutiller lluis.nosp@m.@tur.nosp@m.ro.or.nosp@m.g
Definition at line 57 of file ContactForm.java.
◆ afterCompose()
void org.turro.contacts.zul.control.ContactForm.afterCompose |
( |
| ) |
|
Definition at line 145 of file ContactForm.java.
147 getChildren().clear();
150 Properties properties =
new Properties();
151 properties.load(FileUtil.getBufferedFile(
152 new File(ElephantContext.getRealPath(
"/WEB-INF/elephant/conf/vCard.properties"))));
153 addFields(properties);
154 }
catch (IOException ex) {
155 Logger.getLogger(ContactForm.class.getName()).log(Level.SEVERE, ElephantContext.logMsg(
null), ex);
void setColumns(int columns)
◆ editContact()
static void org.turro.contacts.zul.control.ContactForm.editContact |
( |
ContactFieldList |
fields, |
|
|
Contact |
contact, |
|
|
final Command |
command |
|
) |
| |
|
static |
Definition at line 97 of file ContactForm.java.
98 final ContactForm cf =
new ContactForm();
99 if(fields.isEmpty()) {
102 cf.setFields(fields);
103 cf.setContact(contact);
104 SelectionDialog.getComponent(Framework.getCurrent().getPage(),
106 cf,
"500px",
"600px",
new Command() {
108 public Object execute(Context context) {
110 final Contact contact = cf.getContact();
111 if(!contact.isEmpty()) {
112 ContactWrapper.saveAnyway(contact,
new Command() {
114 public Object execute(Context context) {
115 Contact newc =
new ContactWrapper(contact).save();
116 if(context ==
null) {
117 context =
new Context();
119 context.put(
"contact", newc);
120 if(command !=
null) command.execute(context);
◆ getContact()
Contact org.turro.contacts.zul.control.ContactForm.getContact |
( |
| ) |
|
◆ newContact()
static void org.turro.contacts.zul.control.ContactForm.newContact |
( |
ContactFieldList |
fields, |
|
|
final Command |
command |
|
) |
| |
|
static |
Definition at line 62 of file ContactForm.java.
63 final ContactForm cf =
new ContactForm();
64 if(fields.isEmpty()) {
68 cf.setContact(
new Contact());
69 SelectionDialog.getComponent(Framework.getCurrent().getPage(),
70 I_.get(
"New contact"),
71 cf,
"500px",
"600px",
new Command() {
74 public Object execute(Context context) {
76 final Contact contact = cf.getContact();
77 if(!contact.isEmpty()) {
78 ContactWrapper.saveAnyway(contact,
new Command() {
80 public Object execute(Context context) {
81 Contact newc =
new ContactWrapper(contact).save();
83 context =
new Context();
85 context.put(
"contact", newc);
86 if(command !=
null) command.execute(context);
◆ setContact()
void org.turro.contacts.zul.control.ContactForm.setContact |
( |
Contact |
contact | ) |
|
◆ setFields()
void org.turro.contacts.zul.control.ContactForm.setFields |
( |
ContactFieldList |
fields | ) |
|
The documentation for this class was generated from the following file: