n_list_recent_discuss.py 849 B

123456789101112131415161718
  1. from .tool.func import *
  2. async def list_recent_discuss(num = 1, tool = 'normal'):
  3. m_sub = 0
  4. if tool == 'close':
  5. m_sub = '(' + await get_lang('close_discussion') + ')'
  6. elif tool == 'open':
  7. m_sub = '(' + await get_lang('open_discussion') + ')'
  8. return easy_minify(flask.render_template(await skin_check(),
  9. imp = [await get_lang('recent_discussion'), await wiki_set(), await wiki_custom(), wiki_css([m_sub, 0])],
  10. data = '' + \
  11. '<div id="opennamu_list_recent_discuss"></div>' + \
  12. '<script defer src="/views/main_css/js/route/list_recent_discuss.js' + cache_v() + '"></script>' + \
  13. '<script>window.addEventListener("DOMContentLoaded", function() { opennamu_list_recent_discuss(); });</script>' + \
  14. '',
  15. menu = [['other', await get_lang('return')]]
  16. ))