annotate app/main/index/email_unconfirmed.lua @ 812:e12f0348b191
Removed files not needed anymore
 | author | 
 bsw | 
 | date | 
 Fri Jul 06 13:34:02 2012 +0200 (2012-07-06) | 
 | parents | 
 418b590fa9ed  | 
 | children | 
 701a5cf6b067  | 
 
 | rev | 
   line source | 
| 
bsw@558
 | 
     1 if app.session.member.notify_email_unconfirmed then
 | 
| 
bsw@558
 | 
     2 
 | 
| 
bsw@558
 | 
     3   local current = Member:new_selector()
 | 
| 
bsw@558
 | 
     4     :add_where{ "id = ?", app.session.member_id }
 | 
| 
bsw@558
 | 
     5     :add_where("notify_email_unconfirmed NOTNULL")
 | 
| 
bsw@558
 | 
     6     :add_where("notify_email_secret_expiry > now()")
 | 
| 
bsw@558
 | 
     7     :optional_object_mode()
 | 
| 
bsw@558
 | 
     8     :exec()
 | 
| 
bsw@558
 | 
     9 
 | 
| 
bsw@564
 | 
    10   slot.select("head", function()
 | 
| 
bsw@564
 | 
    11     ui.container{
 | 
| 
bsw@564
 | 
    12       attr = { class = "title" },
 | 
| 
bsw@564
 | 
    13       content = _"Notification address unconfirmed"
 | 
| 
bsw@564
 | 
    14     }
 | 
| 
bsw@558
 | 
    15   end )
 | 
| 
bsw@558
 | 
    16 
 | 
| 
bsw@558
 | 
    17   if current then
 | 
| 
bsw@558
 | 
    18     ui.tag{
 | 
| 
bsw@558
 | 
    19       tag = "div",
 | 
| 
bsw@558
 | 
    20       content = _("You didn't confirm your email address '#{email}'. You have received an email with an activation link.", { email = app.session.member.notify_email_unconfirmed })
 | 
| 
bsw@558
 | 
    21     }
 | 
| 
bsw@558
 | 
    22   else
 | 
| 
bsw@558
 | 
    23     ui.tag{
 | 
| 
bsw@558
 | 
    24       tag = "div",
 | 
| 
bsw@558
 | 
    25       content = _("You didn't confirm your email address '#{email}' within 7 days.", { email = app.session.member.notify_email_unconfirmed })
 | 
| 
bsw@558
 | 
    26     }
 | 
| 
bsw@558
 | 
    27   end
 | 
| 
bsw@558
 | 
    28   slot.put("<br />")
 | 
| 
bsw@558
 | 
    29 
 | 
| 
bsw@558
 | 
    30   ui.link{
 | 
| 
bsw@558
 | 
    31     text = _"Change email address",
 | 
| 
bsw@558
 | 
    32     module = "member",
 | 
| 
bsw@558
 | 
    33     view = "settings_email",
 | 
| 
bsw@558
 | 
    34   }
 | 
| 
bsw@558
 | 
    35   slot.put("<br />")
 | 
| 
bsw@558
 | 
    36   slot.put("<br />")
 | 
| 
bsw@558
 | 
    37 
 | 
| 
bsw@558
 | 
    38   ui.link{
 | 
| 
bsw@558
 | 
    39     text = _("Resend activation email to '#{email}'", { email = app.session.member.notify_email_unconfirmed }),
 | 
| 
bsw@558
 | 
    40     module = "member",
 | 
| 
bsw@558
 | 
    41     action = "update_email",
 | 
| 
bsw@558
 | 
    42     params = {
 | 
| 
bsw@558
 | 
    43       resend = true
 | 
| 
bsw@558
 | 
    44     },
 | 
| 
bsw@558
 | 
    45     routing = {
 | 
| 
bsw@558
 | 
    46       default = {
 | 
| 
bsw@558
 | 
    47         mode = "redirect",
 | 
| 
bsw@558
 | 
    48         module = "index",
 | 
| 
bsw@558
 | 
    49         view = "index"
 | 
| 
bsw@558
 | 
    50       }
 | 
| 
bsw@558
 | 
    51     }
 | 
| 
bsw@558
 | 
    52   }
 | 
| 
bsw@558
 | 
    53 
 | 
| 
bsw@558
 | 
    54 end
 |