中国本土应用
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

18 lines
499B

  1. # -*- coding: utf-8 -*-
  2. from odoo import api, models, tools, _
  3. class WecomApiToolsDictionary(models.AbstractModel):
  4. _name = "wecomapi.tools.dictionary"
  5. _description = "Wecom API Tools - Dictionary"
  6. def check_dictionary_keywords(self, dictionary, key):
  7. """
  8. 检查字典中是否存在key
  9. """
  10. # dictionary, key = (self.value[0], self.value[1])
  11. if key in dictionary.keys():
  12. return dictionary[key]
  13. else:
  14. return None
上海开阖软件有限公司 沪ICP备12045867号-1