# HG changeset patch # User bsw # Date 1448987394 -3600 # Node ID e0235b3d19ee7b70821ffd1108eb6d68626d5a49 # Parent b79085a2f92edfe0a0a0c371776a81b8ab0e802b Removed code not used anymore (outdated feature "discussion url") diff -r b79085a2f92e -r e0235b3d19ee app/main/initiative/_action/update.lua --- a/app/main/initiative/_action/update.lua Tue Dec 01 17:30:33 2015 +0100 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,28 +0,0 @@ -local initiative = Initiative:by_id(param.get_id()) - -local initiator = Initiator:by_pk(initiative.id, app.session.member.id) -if not initiator or not initiator.accepted then - error("access denied") -end - --- TODO important m1 selectors returning result _SET_! -local issue = initiative:get_reference_selector("issue"):for_share():single_object_mode():exec() - -if issue.closed then - slot.put_into("error", _"This issue is already closed.") - return false -elseif issue.half_frozen then - slot.put_into("error", _"This issue is already frozen.") - return false -end - -if initiative.revoked then - slot.put_into("error", _"This initiative is revoked") - return false -end - -param.update(initiative, "discussion_url") -initiative:save() - -slot.put_into("notice", _"Initiative successfully updated") - diff -r b79085a2f92e -r e0235b3d19ee app/main/initiative/edit.lua --- a/app/main/initiative/edit.lua Tue Dec 01 17:30:33 2015 +0100 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,35 +0,0 @@ -local initiative = Initiative:by_id(param.get_id()) - -slot.put_into("title", _"Edit initiative") - -slot.select("actions", function() - ui.link{ - content = function() - ui.image{ static = "icons/16/cancel.png" } - slot.put(_"Cancel") - end, - module = "initiative", - view = "show", - id = initiative.id - } -end) - -ui.form{ - record = initiative, - module = "initiative", - action = "update", - id = initiative.id, - attr = { class = "vertical" }, - routing = { - default = { - mode = "redirect", - module = "initiative", - view = "show", - id = initiative.id - } - }, - content = function() - ui.field.text{ label = _"Discussion URL", name = "discussion_url" } - ui.submit{ text = _"Save" } - end -} \ No newline at end of file diff -r b79085a2f92e -r e0235b3d19ee config/example.lua --- a/config/example.lua Tue Dec 01 17:30:33 2015 +0100 +++ b/config/example.lua Tue Dec 01 17:29:54 2015 +0100 @@ -195,13 +195,6 @@ -- config.motd_intern = "

Message of the day (intern)

The MOTD is formatted with HTML

" --- Automatic issue related discussion URL --- ------------------------------------------------------------------------ --- config.issue_discussion_url_func = function(issue) --- return "http://example.com/discussion/issue_" .. tostring(issue.id) --- end - - -- Integration of Etherpad, disabled by default -- ------------------------------------------------------------------------ --config.etherpad = {