File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -160,11 +160,11 @@ With 101% height we essentially force the scrollbar to always appear. -->
160160 <!-- End of page title and user details -->
161161
162162 <!-- Output errors -->
163- { if $errors -> yes ()}
163+ { if $err -> yes ()}
164164 <table cellspacing =" 4" cellpadding =" 7" width =" { $tab_width } " border =" 0" >
165165 <tr >
166166 <td class =" error" >
167- { foreach $errors -> getErrors () as $error }
167+ { foreach $err -> getErrors () as $error }
168168 { $error .message} <br > { * No need to escape as they are not coming from user and may contain a link. *}
169169 { /foreach }
170170 </td >
@@ -174,11 +174,11 @@ With 101% height we essentially force the scrollbar to always appear. -->
174174 <!-- End of output errors -->
175175
176176 <!-- Output messages -->
177- { if $messages -> yes ()}
177+ { if $msg -> yes ()}
178178 <table cellspacing =" 4" cellpadding =" 7" width =" { $tab_width } " border =" 0" >
179179 <tr >
180180 <td class =" info_message" >
181- { foreach $messages -> getErrors () as $message }
181+ { foreach $msg -> getErrors () as $message }
182182 { $message .message} <br > { * No need to escape. *}
183183 { /foreach }
184184 </td >
Original file line number Diff line number Diff line change 5555 <!-- End of top image -->
5656
5757 <!-- Output errors -->
58- { if $errors -> yes ()}
58+ { if $err -> yes ()}
5959 <table cellspacing =" 4" cellpadding =" 7" width =" { $tab_width } " border =" 0" >
6060 <tr >
6161 <td class =" error" >
62- { foreach $errors -> getErrors () as $error }
62+ { foreach $err -> getErrors () as $error }
6363 { $error .message} <br > { * No need to escape as they are not coming from user and may contain a link. *}
6464 { /foreach }
6565 </td >
6969 <!-- End of output errors -->
7070
7171 <!-- Output messages -->
72- { if $messages -> yes ()}
72+ { if $msg -> yes ()}
7373 <table cellspacing =" 4" cellpadding =" 7" width =" { $tab_width } " border =" 0" >
7474 <tr >
7575 <td class =" info_message" >
76- { foreach $messages -> getErrors () as $message }
76+ { foreach $msg -> getErrors () as $message }
7777 { $message .message} <br > { * No need to escape. *}
7878 { /foreach }
7979 </td >
Original file line number Diff line number Diff line change 4545
4646 $ import = new ttImportHelper ($ err );
4747 $ import ->importXml ();
48- if ($ err ->no ())
49- $ messages ->add ($ i18n ->getKey ('form.import.success ' ));
48+ if ($ err ->no ()) $ msg ->add ($ i18n ->getKey ('form.import.success ' ));
5049} // isPost
5150
5251$ smarty ->assign ('forms ' , array ($ form ->getName ()=>$ form ->toArray ()) );
Original file line number Diff line number Diff line change 152152$ request = new ttHttpRequest ();
153153
154154import ('form.ActionErrors ' );
155- $ err = new ActionErrors ();
156- $ messages = new ActionErrors ();
155+ $ err = new ActionErrors (); // Error messages for user.
156+ $ msg = new ActionErrors (); // Notification messages (not errrors) for user.
157157
158158// Create an instance of ttUser class. This gets us most of user details.
159159import ('ttUser ' );
193193
194194// Assign things for smarty to use in template files.
195195$ smarty ->assign ('i18n ' , $ i18n ->keys );
196- $ smarty ->assign ('errors ' , $ err );
197- $ smarty ->assign ('messages ' , $ messages );
196+ $ smarty ->assign ('err ' , $ err );
197+ $ smarty ->assign ('msg ' , $ msg );
198198
199199// TODO: move this code out of here to the files that use it.
200200
Original file line number Diff line number Diff line change 8888 $ mailer ->setReceiverCC ($ cl_cc );
8989 $ mailer ->setSendType (MAIL_MODE );
9090 if ($ mailer ->send ($ cl_subject , $ body ))
91- $ messages ->add ($ i18n ->getKey ('form.mail.invoice_sent ' ));
91+ $ msg ->add ($ i18n ->getKey ('form.mail.invoice_sent ' ));
9292 else
9393 $ err ->add ($ i18n ->getKey ('error.mail_send ' ));
9494 }
Original file line number Diff line number Diff line change 9898 if (($ cl_start == $ cl_finish ) && ($ cl_duration == '0:00 ' )) {
9999 $ cl_finish = '' ;
100100 $ cl_duration = '' ;
101- $ messages ->add ($ i18n ->getKey ('form.time_edit.uncompleted ' ));
101+ $ msg ->add ($ i18n ->getKey ('form.time_edit.uncompleted ' ));
102102 }
103103}
104104
Original file line number Diff line number Diff line change 8585 $ mailer ->setReceiverCC ($ cl_cc );
8686 $ mailer ->setSendType (MAIL_MODE );
8787 if ($ mailer ->send ($ cl_subject , $ body ))
88- $ messages ->add ($ i18n ->getKey ('form.mail.report_sent ' ));
88+ $ msg ->add ($ i18n ->getKey ('form.mail.report_sent ' ));
8989 else
9090 $ err ->add ($ i18n ->getKey ('error.mail_send ' ));
9191 }
Original file line number Diff line number Diff line change 9898 if (($ cl_start == $ cl_finish ) && ($ cl_duration == '0:00 ' )) {
9999 $ cl_finish = '' ;
100100 $ cl_duration = '' ;
101- $ messages ->add ($ i18n ->getKey ('form.time_edit.uncompleted ' ));
101+ $ msg ->add ($ i18n ->getKey ('form.time_edit.uncompleted ' ));
102102 }
103103}
104104
You can’t perform that action at this time.
0 commit comments