liquid_feedback_frontend

annotate app/main/issue/_details.lua @ 570:b904fc12cc1a

Show only units with voting privilege in member_home page
author bsw
date Tue Jun 19 23:18:39 2012 +0200 (2012-06-19)
parents 3e4f6534bb15
children cc64a4fc6ab6
rev   line source
bsw/jbe@19 1 local issue = param.get("issue", "table")
bsw/jbe@19 2
bsw/jbe@19 3 local policy = issue.policy
bsw/jbe@19 4 ui.form{
bsw/jbe@19 5 record = issue,
bsw/jbe@19 6 readonly = true,
bsw/jbe@19 7 attr = { class = "vertical" },
bsw/jbe@19 8 content = function()
bsw@25 9 ui.field.text{ label = _"Population", name = "population" }
bsw@25 10 ui.field.text{ label = _"State", name = "state" }
bsw@25 11 ui.field.timestamp{ label = _"Created at", name = "created" }
bsw@25 12 ui.field.text{ label = _"Admission time", value = issue.admission_time }
bsw/jbe@19 13 ui.field.text{
bsw/jbe@19 14 label = _"Issue quorum",
bsw/jbe@19 15 value = format.percentage(policy.issue_quorum_num / policy.issue_quorum_den)
bsw/jbe@19 16 }
bsw@255 17 if issue.population then
bsw@255 18 ui.field.text{
bsw@255 19 label = _"Currently required",
bsw@255 20 value = math.ceil(issue.population * policy.issue_quorum_num / policy.issue_quorum_den)
bsw@255 21 }
bsw@255 22 end
bsw@25 23 ui.field.timestamp{ label = _"Accepted at", name = "accepted" }
bsw@25 24 ui.field.text{ label = _"Discussion time", value = issue.discussion_time }
bsw@25 25 ui.field.timestamp{ label = _"Half frozen at", name = "half_frozen" }
bsw@25 26 ui.field.text{ label = _"Verification time", value = issue.verification_time }
bsw/jbe@19 27 ui.field.text{
bsw/jbe@19 28 label = _"Initiative quorum",
bsw/jbe@19 29 value = format.percentage(policy.initiative_quorum_num / policy.initiative_quorum_den)
bsw/jbe@19 30 }
bsw@255 31 if issue.population then
bsw@255 32 ui.field.text{
bsw@255 33 label = _"Currently required",
bsw@255 34 value = math.ceil(issue.population * (issue.policy.initiative_quorum_num / issue.policy.initiative_quorum_den)),
bsw@255 35 }
bsw@255 36 end
bsw@25 37 ui.field.timestamp{ label = _"Fully frozen at", name = "fully_frozen" }
bsw@25 38 ui.field.text{ label = _"Voting time", value = issue.voting_time }
bsw@25 39 ui.field.timestamp{ label = _"Closed", name = "closed" }
bsw/jbe@19 40 end
bsw/jbe@19 41 }
bsw/jbe@19 42 ui.form{
bsw/jbe@19 43 record = issue.policy,
bsw/jbe@19 44 readonly = true,
bsw/jbe@19 45 content = function()
bsw/jbe@19 46 end
bsw/jbe@19 47 }

Impressum / About Us