<% if _SESSION["logined"] ~= nil then local domain = _POST["domain"] local group = _POST["group"] local oldname = _POST["oldname"] local resetstat = _POST["resetstat"] or nil if group ~= nil then group = json.decode(group) if oldname ~= group.groupname then local result = c_GroupExist(domain,group.groupname) if result == true then print("0") else c_DeleteGroup(domain,oldname) AddGroup(domain,group) print("1") end else if resetstat ~= nil then c_ResetGroupStatistic(domain,group.groupname) end AddGroup(domain,group) print("1") end end else print("-1") end %>