annotate app/main/issue/_head.lua @ 1279:ec084cda1be9
Fixed wording for notification setting
 | author | 
 bsw | 
 | date | 
 Mon Apr 18 06:58:53 2016 +0200 (2016-04-18) | 
 | parents | 
 701a5cf6b067  | 
 | children | 
 32cc544d5a5b  | 
 
 | rev | 
   line source | 
| 
bsw@525
 | 
     1 local issue = param.get("issue", "table")
 | 
| 
bsw@1045
 | 
     2 local initiative = param.get("initiative", "table")
 | 
| 
bsw@1045
 | 
     3 
 | 
| 
bsw@1045
 | 
     4 local member = param.get ( "member", "table" )
 | 
| 
bsw@1045
 | 
     5 
 | 
| 
bsw@1045
 | 
     6 
 | 
| 
bsw@1045
 | 
     7 ui.title ( function ()
 | 
| 
bsw@1045
 | 
     8 
 | 
| 
bsw@1045
 | 
     9   ui.tag {
 | 
| 
bsw@1045
 | 
    10     attr = { class = "unit" },
 | 
| 
bsw@1045
 | 
    11     content = function()
 | 
| 
bsw@1045
 | 
    12       ui.link {
 | 
| 
bsw@1045
 | 
    13         content = function()
 | 
| 
bsw@1045
 | 
    14           ui.tag{ attr = { class = "name" }, content = issue.area.unit.name }
 | 
| 
bsw@1045
 | 
    15         end,
 | 
| 
bsw@1045
 | 
    16         module = "unit", view = "show",
 | 
| 
bsw@1045
 | 
    17         id = issue.area.unit.id
 | 
| 
bsw@1045
 | 
    18       }
 | 
| 
bsw@1045
 | 
    19     end
 | 
| 
bsw@1045
 | 
    20   }
 | 
| 
bsw@1045
 | 
    21   ui.tag { attr = { class = "spacer" }, content = function()
 | 
| 
bsw@1045
 | 
    22     slot.put ( " » " )
 | 
| 
bsw@1045
 | 
    23   end }
 | 
| 
bsw@1045
 | 
    24 
 | 
| 
bsw@1045
 | 
    25   ui.tag {
 | 
| 
bsw@1045
 | 
    26     attr = { class = "area" },
 | 
| 
bsw@1045
 | 
    27     content = function()
 | 
| 
bsw@1045
 | 
    28       ui.link {
 | 
| 
bsw@1045
 | 
    29         content = function()
 | 
| 
bsw@1045
 | 
    30           ui.tag{ attr = { class = "name" }, content = issue.area.name }
 | 
| 
bsw@1045
 | 
    31         end,
 | 
| 
bsw@1045
 | 
    32         module = "area", view = "show",
 | 
| 
bsw@1045
 | 
    33         id = issue.area.id
 | 
| 
bsw@1045
 | 
    34       }
 | 
| 
bsw@1045
 | 
    35     end
 | 
| 
bsw@1045
 | 
    36   }
 | 
| 
bsw@525
 | 
    37 
 | 
| 
bsw@1045
 | 
    38   ui.tag { attr = { class = "spacer" }, content = function()
 | 
| 
bsw@1045
 | 
    39     slot.put ( " » " )
 | 
| 
bsw@1045
 | 
    40   end }
 | 
| 
bsw@1045
 | 
    41   
 | 
| 
bsw@1045
 | 
    42   ui.tag {
 | 
| 
bsw@1045
 | 
    43     attr = { class = "issue" },
 | 
| 
bsw@1045
 | 
    44     content = function()
 | 
| 
bsw@1045
 | 
    45       -- issue link
 | 
| 
bsw@1045
 | 
    46       ui.link {
 | 
| 
bsw@1045
 | 
    47         text = _("#{policy_name} ##{issue_id}", { 
 | 
| 
bsw@1045
 | 
    48           policy_name = issue.policy.name,
 | 
| 
bsw@1045
 | 
    49           issue_id = issue.id
 | 
| 
bsw@1045
 | 
    50         } ),
 | 
| 
bsw@1045
 | 
    51         module = "issue", view = "show",
 | 
| 
bsw@1045
 | 
    52         id = issue.id
 | 
| 
bsw@1045
 | 
    53       }
 | 
| 
bsw@1045
 | 
    54 
 | 
| 
bsw@1045
 | 
    55       slot.put ( " " )
 | 
| 
bsw@1045
 | 
    56       
 | 
| 
bsw@1045
 | 
    57       if member then
 | 
| 
bsw@1045
 | 
    58         execute.view {
 | 
| 
bsw@1045
 | 
    59           module = "delegation", view = "_info", params = { 
 | 
| 
bsw@1045
 | 
    60             issue = issue, member = member, for_title = true
 | 
| 
bsw@1045
 | 
    61           }
 | 
| 
bsw@1045
 | 
    62         }
 | 
| 
bsw@1045
 | 
    63       end
 | 
| 
bsw@1045
 | 
    64     end
 | 
| 
bsw@1045
 | 
    65   }
 | 
| 
bsw@1045
 | 
    66   
 | 
| 
bsw@1045
 | 
    67   if initiative then
 | 
| 
bsw@1045
 | 
    68     ui.tag{
 | 
| 
bsw@1045
 | 
    69       attr = { class = "initiative" },
 | 
| 
bsw@1045
 | 
    70       content = initiative.display_name
 | 
| 
bsw@1045
 | 
    71     }
 | 
| 
bsw@1045
 | 
    72   end
 | 
| 
bsw@1045
 | 
    73   
 | 
| 
bsw@1045
 | 
    74 end ) -- ui.title
 |