Files
test-all/spring-lua/lua/script/index/index.lua
2024-08-08 09:00:28 +08:00

24 lines
679 B
Lua

---
--- Generated by EmmyLua(https://github.com/EmmyLua)
--- Created by troy-chen.
--- DateTime: 2024/7/27 下午11:36
---
function root(request, response, postBody)
responseUtil:responseText(response, "hello world")
end
function index(request, response, postBody)
print("")
print(request:getServletPath())
print("request = " .. tostring(request))
print("response = " .. tostring(response))
redisTemplate:opsForValue():set("lua-dd", "dd");
responseUtil:responseText(response, "lua -- dd")
end
function index3(request, response, postBody)
print("index3")
local obj = { error = 0, msg = "ok" };
responseUtil:responseObj(response, obj)
end