PyWxDump/pywxdump/dbpreprocess/parsingFavorite.py
2024-05-18 00:26:53 +08:00

29 lines
1.1 KiB
Python
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

# -*- coding: utf-8 -*-#
# -------------------------------------------------------------------------------
# Name: parsingFavorite.py
# Description:
# Author: xaoyaoo
# Date: 2024/05/18
# -------------------------------------------------------------------------------
from .dbbase import DatabaseBase
# * FavItems收藏的消息条目列表
# * FavDataItem收藏的具体数据。大概可以确定以下两点
# * 即使只是简单收藏一篇公众号文章也会在 FavDataItem 中有一个对应的记录
# * 对于收藏的合并转发类型的消息,合并转发中的每一条消息在 FavDataItem 中都是一个独立的记录
# * FavTags为收藏内容添加的标签
class ParsingFavorite(DatabaseBase):
_class_name = "Favorite"
def __init__(self, db_path):
super().__init__(db_path)
def get_favorite(self):
sql1 = "select * from FavItems"
sql2 = "select * from FavDataItem"
sql3 = "select * from FavTags"
DBdata1 = self.execute_sql(sql1)
DBdata2 = self.execute_sql(sql2)
DBdata3 = self.execute_sql(sql3)
return DBdata1, DBdata2, DBdata3