暂无描述
您最多选择25个主题 主题必须以字母或数字开头,可以包含连字符 (-),并且长度不得超过35个字符

main.py 524B

1234567891011121314151617
  1. #-*- coding: utf-8 -*-
  2. from lodel.plugin import LodelHook
  3. ##@brief Hook's callback example
  4. @LodelHook('leapi_get_pre')
  5. @LodelHook('leapi_get_post')
  6. @LodelHook('leapi_update_pre')
  7. @LodelHook('leapi_update_post')
  8. @LodelHook('leapi_delete_pre')
  9. @LodelHook('leapi_delete_post')
  10. @LodelHook('leapi_insert_pre')
  11. @LodelHook('leapi_insert_post')
  12. def dummy_callback(hook_name, caller, payload):
  13. if Lodel.settings.Settings.debug:
  14. print("\tHook %s\tcaller %s with %s" % (hook_name, caller, payload))
  15. return payload