当前位置: 首页>>代码示例>>Python>>正文


Python timers.getTimers函数代码示例

本文整理汇总了Python中models.timers.getTimers函数的典型用法代码示例。如果您正苦于以下问题:Python getTimers函数的具体用法?Python getTimers怎么用?Python getTimers使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。


在下文中一共展示了getTimers函数的5个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Python代码示例。

示例1: P_epgdialog

	def P_epgdialog(self, request):
		events = self.P_epgpop(request)
		timers = getTimers(self.session)
		at = False
		try:
			from Plugins.Extensions.AutoTimer.AutoTimer import AutoTimer
			at = True
		except ImportError:
			pass
		return { "events": events['events'] , "timers" : timers['timers'] , "at" : at }
开发者ID:system-it,项目名称:e2openplugin-OpenWebif,代码行数:10,代码来源:ajax.py

示例2: P_timers

	def P_timers(self, request):

		timers = getTimers(self.session)
		sorttype = ''
		unsort = timers['timers']

		if "sort" in request.args.keys():
			sorttype = request.args["sort"][0]
		else:
			return timers

		if sorttype == 'name':
			timers['timers'] = sorted(unsort, key=lambda k: k['name'])
		elif sorttype == 'named':
			timers['timers'] = sorted(unsort, key=lambda k: k['name'], reverse=True)
		elif sorttype == 'date':
			timers['timers'] = sorted(unsort, key=lambda k: k['begin'])
		else:
			timers['timers'] = sorted(unsort, key=lambda k: k['begin'], reverse=True)
			sorttype = 'dated'

		timers['sort'] = sorttype
		return timers
开发者ID:E2OpenPlugins,项目名称:e2openplugin-OpenWebif,代码行数:23,代码来源:ajax.py

示例3: P_epgpop

    def P_epgpop(self, request):
        events = []
        timers = []
        if "sref" in request.args.keys():
            ev = getChannelEpg(request.args["sref"][0])
            events = ev["events"]
        elif "sstr" in request.args.keys():
            ev = getSearchEpg(request.args["sstr"][0])
            events = ev["events"]
        at = False
        if len(events) > 0:
            t = getTimers(self.session)
            timers = t["timers"]
            try:
                from Plugins.Extensions.AutoTimer.AutoTimer import AutoTimer

                at = True
            except ImportError:
                pass
        if config.OpenWebif.webcache.theme.value:
            theme = config.OpenWebif.webcache.theme.value
        else:
            theme = "original"
        return {"theme": theme, "events": events, "timers": timers, "at": at, "kinopoisk": getLanguage()}
开发者ID:Dima73,项目名称:e2openplugin-OpenWebif,代码行数:24,代码来源:ajax.py

示例4: P_timerlist

	def P_timerlist(self, request):
		ret = getTimers(self.session)
		ret["locations"] = config.movielist.videodirs.value
		return ret
开发者ID:berkantxx27,项目名称:e2openplugin-OpenWebif,代码行数:4,代码来源:web.py

示例5: P_timers

	def P_timers(self, request):
		return getTimers(self.session)
开发者ID:emedril,项目名称:enigma2-plugin-extensions-openwebif,代码行数:2,代码来源:ajax.py


注:本文中的models.timers.getTimers函数示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。