Ejemplo n.º 1
0
	def get(self):
		if self.param('delid') == '':
			listit = FeedList()
			querys = listit.all()
			feedDetal = ''
		else:
			listit = FeedList()
			querys = listit.all().filter('name =', self.param('delid')).fetch(1)
			for query in querys:
			    query.delete()
			self.redirect('/admin/feedblog/setup')
			self.response.set_status(301)
		self.template_vals.update({'list':querys})
		self.template_vals.update({'categories':Category.all()})
		content = template.render('plugins/feedblog/feedblog.html', self.template_vals)
		self.render2('views/admin/setup_base.html', {'m_id':'feedblog_setup', 'content':content})
Ejemplo n.º 2
0
 def get(self):
     if self.param('delid') == '':
         listit = FeedList()
         querys = listit.all()
         feedDetal = ''
     else:
         listit = FeedList()
         querys = listit.all().filter('name =',
                                      self.param('delid')).fetch(1)
         for query in querys:
             query.delete()
         self.redirect('/admin/feedblog/setup')
         self.response.set_status(301)
     self.template_vals.update({'list': querys})
     self.template_vals.update({'categories': Category.all()})
     content = template.render('plugins/feedblog/feedblog.html',
                               self.template_vals)
     self.render2('views/admin/setup_base.html', {
         'm_id': 'feedblog_setup',
         'content': content
     })
Ejemplo n.º 3
0
    def __getcategorykey(self, feed_url, defDir):

        resultkry = []

        feedslug = FeedList.all().filter('feedurl = ', feed_url)
        if feedslug != None:
            resultkey = self.__changdir(feedslug[0].acategory)

        else:
            logging.warning('the item of id is  %s, and change it to %s',
                            feedslug.id, defDir)
            resultkey = self.__changdir(defDir)

        return resultkey
Ejemplo n.º 4
0
		def __getcategorykey(self, feed_url, defDir):

				resultkry = []

				feedslug = FeedList.all().filter('feedurl = ', feed_url)
				if feedslug != None:
						resultkey = self.__changdir(feedslug[0].acategory)

				else:
						logging.warning('the item of id is  %s, and change it to %s', feedslug.id, defDir)
						resultkey = self.__changdir(defDir)



				return resultkey
Ejemplo n.º 5
0
		def get(self):
				listit = FeedList()
				feeds = listit.all()
				listits = FeedsList()
				self.getFeed()
Ejemplo n.º 6
0
 def get(self):
     listit = FeedList()
     feeds = listit.all()
     listits = FeedsList()
     self.getFeed()