liquid_feedback_frontend

view app/main/api/support.lua @ 1500:71f54c43d7cb

Added API support interface
author bsw
date Tue Mar 24 16:59:32 2020 +0100 (2020-03-24)
parents
children 37a366b86b49
line source
1 local initiative_id = param.get("initiative_id")
3 local success = util.add_support(initiative_id)
5 slot.set_layout(nil, "application/json")
7 local r = json.array()
9 if success then
10 r.status = "ok"
11 else
12 r.status = "error"
13 end
15 slot.put_into("data", json.export(json.object{ result = r }))
16 slot.put_into("data", "\n")

Impressum / About Us