liquid_feedback_frontend
changeset 1227:e0235b3d19ee
Removed code not used anymore (outdated feature "discussion url")
author | bsw |
---|---|
date | Tue Dec 01 17:29:54 2015 +0100 (2015-12-01) |
parents | b79085a2f92e |
children | 554b739f86d6 |
files | app/main/initiative/_action/update.lua app/main/initiative/edit.lua config/example.lua |
line diff
1.1 --- a/app/main/initiative/_action/update.lua Tue Dec 01 17:30:33 2015 +0100 1.2 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 1.3 @@ -1,28 +0,0 @@ 1.4 -local initiative = Initiative:by_id(param.get_id()) 1.5 - 1.6 -local initiator = Initiator:by_pk(initiative.id, app.session.member.id) 1.7 -if not initiator or not initiator.accepted then 1.8 - error("access denied") 1.9 -end 1.10 - 1.11 --- TODO important m1 selectors returning result _SET_! 1.12 -local issue = initiative:get_reference_selector("issue"):for_share():single_object_mode():exec() 1.13 - 1.14 -if issue.closed then 1.15 - slot.put_into("error", _"This issue is already closed.") 1.16 - return false 1.17 -elseif issue.half_frozen then 1.18 - slot.put_into("error", _"This issue is already frozen.") 1.19 - return false 1.20 -end 1.21 - 1.22 -if initiative.revoked then 1.23 - slot.put_into("error", _"This initiative is revoked") 1.24 - return false 1.25 -end 1.26 - 1.27 -param.update(initiative, "discussion_url") 1.28 -initiative:save() 1.29 - 1.30 -slot.put_into("notice", _"Initiative successfully updated") 1.31 -
2.1 --- a/app/main/initiative/edit.lua Tue Dec 01 17:30:33 2015 +0100 2.2 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 2.3 @@ -1,35 +0,0 @@ 2.4 -local initiative = Initiative:by_id(param.get_id()) 2.5 - 2.6 -slot.put_into("title", _"Edit initiative") 2.7 - 2.8 -slot.select("actions", function() 2.9 - ui.link{ 2.10 - content = function() 2.11 - ui.image{ static = "icons/16/cancel.png" } 2.12 - slot.put(_"Cancel") 2.13 - end, 2.14 - module = "initiative", 2.15 - view = "show", 2.16 - id = initiative.id 2.17 - } 2.18 -end) 2.19 - 2.20 -ui.form{ 2.21 - record = initiative, 2.22 - module = "initiative", 2.23 - action = "update", 2.24 - id = initiative.id, 2.25 - attr = { class = "vertical" }, 2.26 - routing = { 2.27 - default = { 2.28 - mode = "redirect", 2.29 - module = "initiative", 2.30 - view = "show", 2.31 - id = initiative.id 2.32 - } 2.33 - }, 2.34 - content = function() 2.35 - ui.field.text{ label = _"Discussion URL", name = "discussion_url" } 2.36 - ui.submit{ text = _"Save" } 2.37 - end 2.38 -} 2.39 \ No newline at end of file
3.1 --- a/config/example.lua Tue Dec 01 17:30:33 2015 +0100 3.2 +++ b/config/example.lua Tue Dec 01 17:29:54 2015 +0100 3.3 @@ -195,13 +195,6 @@ 3.4 -- config.motd_intern = "<h1>Message of the day (intern)</h1><p>The MOTD is formatted with HTML</p>" 3.5 3.6 3.7 --- Automatic issue related discussion URL 3.8 --- ------------------------------------------------------------------------ 3.9 --- config.issue_discussion_url_func = function(issue) 3.10 --- return "http://example.com/discussion/issue_" .. tostring(issue.id) 3.11 --- end 3.12 - 3.13 - 3.14 -- Integration of Etherpad, disabled by default 3.15 -- ------------------------------------------------------------------------ 3.16 --config.etherpad = {