m_pGrid = CLuaGridUtil();
m_pGrid:SetGrid(ui:getDialogName(),'id_grid');
m_help = CSelectHelp();
function main()
local sql = [[select * from uums_user with(nolock) where is_delete = 0]]
if db:select(sql,'',m_help) < 0 then
return ui:tip(db:error());
end
m_pGrid:setHelp(m_help);
end
function confirm_close()
local help = CSelectHelp();
m_pGrid:getHelp(help);
if m_help:toString() ~= help:toString() then
if not ui:msgConfirm('修改未保存,是否关闭窗口?') then
ui:setClose(false);
end
end
end
main();
ui:setCloseScript('confirm_close();');