diff --git a/config.toml b/config.toml index 6d7a27e..e64f846 100644 --- a/config.toml +++ b/config.toml @@ -1,7 +1,7 @@ # [调试] 将更改保存到文件 save = 1 # [调试] 覆写时间 -time_override = 12 +time_override = 11 # 对于每个项目的新记忆核子数量 tasked_number = 12 # 竖屏适配 diff --git a/particles.py b/particles.py index 0e3ff5e..7e2843f 100644 --- a/particles.py +++ b/particles.py @@ -144,6 +144,9 @@ class Nucleon: def __len__(self): return len(self.metadata) + def __hash__(self): + return hash(self.content) + @staticmethod def placeholder(): return Nucleon("核子对象样例内容", {}) @@ -197,7 +200,7 @@ class ElectronUnion(): for i in all.keys(): lst.append(Electron(i, all[i])) self.electrons = lst - self.electrons_dict = {i.content: i.metadata for i in lst} + self.electrons_dict = {i.content: i for i in lst} def sync(self): """同步 electrons_dict 中新增对到 electrons 中""" diff --git a/reactor.py b/reactor.py index 20c0b12..8d70574 100644 --- a/reactor.py +++ b/reactor.py @@ -38,7 +38,7 @@ class Reactor(): self.atoms_new.append(atom) counter -= 1 else: - if atom[0]["next_date"] <= aux.get_daystamp(): + if int(atom[0]["next_date"]) <= aux.get_daystamp(): atom[0]["last_date"] = aux.get_daystamp() self.atoms_review.append(atom) # 设置运行时 @@ -64,6 +64,9 @@ class Reactor(): 2: "新记忆模式", 3: "总复习模式" } + print("Atoms New:", self.atoms_new) + print("Atoms Review:", self.atoms_review) + processions = { 1: self.atoms_review, 2: self.atoms_new,