本文整理汇总了Python中trac.ticket.model.Ticket.values['summary']方法的典型用法代码示例。如果您正苦于以下问题:Python Ticket.values['summary']方法的具体用法?Python Ticket.values['summary']怎么用?Python Ticket.values['summary']使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类trac.ticket.model.Ticket
的用法示例。
在下文中一共展示了Ticket.values['summary']方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Python代码示例。
示例1: _do_enter_sticket
# 需要导入模块: from trac.ticket.model import Ticket [as 别名]
# 或者: from trac.ticket.model.Ticket import values['summary'] [as 别名]
def _do_enter_sticket(self, sticket):
ticket = Ticket(self.env)
ticket.values['status'] = 'new'
ticket.values['reporter'] = 'scheduled'
ticket.values['summary'] = sticket['summary']
ticket.values['description'] = sticket['description']
priorities = Priority.select(self.env)
for priority in priorities:
if int(priority.value) == sticket['priority']:
ticket.values['priority'] = priority.name
for manipulator in self.ticket_manipulators:
manipulator.validate_ticket([], ticket)
# This was largely copied from trac.ticket.web_ui
ticket.insert()
try:
tn = TicketNotifyEmail(self.env)
tn.notify(ticket, newticket=True)
except Exception, e:
error = "Failure sending notification on creation of ticket #%s: %s" % (ticket.id, exception_to_unicode(e))
self.log.error(error)
print error