fix
This commit is contained in:
parent
de988e4132
commit
1dd4e9f41f
@ -23,7 +23,8 @@ class baseComic:
|
|||||||
comics = ListComic.getListComicsLinksUpdateAt()
|
comics = ListComic.getListComicsLinksUpdateAt()
|
||||||
if comics == None: return False
|
if comics == None: return False
|
||||||
(book_name,comic_href,updated) = [comics[0],comics[1],comics[2]]
|
(book_name,comic_href,updated) = [comics[0],comics[1],comics[2]]
|
||||||
return cls.updateOneComic(book_name,comic_href,updated,chapters_xpath)
|
cls.updateOneComic(book_name,comic_href,updated,chapters_xpath)
|
||||||
|
return True
|
||||||
|
|
||||||
@classmethod
|
@classmethod
|
||||||
def updateOneComic(cls,book_name,comic_href,update_at,chapters_xpath):
|
def updateOneComic(cls,book_name,comic_href,update_at,chapters_xpath):
|
||||||
|
|||||||
@ -13,7 +13,10 @@ class comicEntity:
|
|||||||
ListComic.setListComicName(books,"name")
|
ListComic.setListComicName(books,"name")
|
||||||
ListComic.setListComicChapterLink(books,"id",start_add=pathStr.getBaseUrl(url)+"/books/")
|
ListComic.setListComicChapterLink(books,"id",start_add=pathStr.getBaseUrl(url)+"/books/")
|
||||||
ListComic.setListComicUpdateAt(books,"updatedAt")
|
ListComic.setListComicUpdateAt(books,"updatedAt")
|
||||||
return baseComic.updateComics(chapters_xpath='//div[contains(@class,"bookid_chapterBox")]//div[contains(@class,"bookid_chapter")]/a/text()')
|
is_next = True
|
||||||
|
while is_next:
|
||||||
|
is_next = baseComic.updateComics(chapters_xpath='//div[contains(@class,"bookid_chapterBox")]//div[contains(@class,"bookid_chapter")]/a/text()')
|
||||||
|
cls.oneComic()
|
||||||
|
|
||||||
@classmethod
|
@classmethod
|
||||||
def oneComic(cls,sleep=None):
|
def oneComic(cls,sleep=None):
|
||||||
@ -37,4 +40,4 @@ class comicEntity:
|
|||||||
|
|
||||||
@classmethod
|
@classmethod
|
||||||
def start(cls,url):
|
def start(cls,url):
|
||||||
while cls.downladsComcis(url): cls.oneComic()
|
cls.downladsComcis(url)
|
||||||
Loading…
Reference in New Issue
Block a user