Let's use AI to Earn!
TypeScript auto-publishdouyindouyin-apielectron-appelectron-reactkuaishoukwaipublishedshipinhaotoolxiaohongshu
feat: 自动任务加数据字段
yikaJasonMice5a4dc08ede8
diff --git a/electron/db/models/autoRun.ts b/electron/db/models/autoRun.tsindex 03fdac98..145de61b 100644--- a/electron/db/models/autoRun.ts+++ b/electron/db/models/autoRun.ts@@ -1,7 +1,7 @@/** @Author: nevin* @Date: 2025-01-20 16:24:16- * @LastEditTime: 2025-03-18 19:44:29+ * @LastEditTime: 2025-03-19 19:31:29* @LastEditors: nevin* @Description: 自动任务 autoRun*/@@ -30,6 +30,13 @@ export class AutoRunModel extends TempModel {@Column({ type: 'int', nullable: false, comment: '账号id,对应account表id' })accountId!: number;+ @Column({+ type: 'varchar',+ nullable: true,+ comment: '对应数据的数据ID',+ })+ dataId?: string;+@Column({ type: 'int', nullable: false, comment: '执行次数', default: 0 })runCount!: number;diff --git a/electron/main/autoRun/controller.ts b/electron/main/autoRun/controller.tsindex 8512d62a..62034e1a 100644--- a/electron/main/autoRun/controller.ts+++ b/electron/main/autoRun/controller.ts@@ -1,7 +1,7 @@/** @Author: nevin* @Date: 2025-01-20 22:02:54- * @LastEditTime: 2025-03-19 15:01:43+ * @LastEditTime: 2025-03-19 19:34:24* @LastEditors: nevin* @Description: autoRun AutoRun*/@@ -27,6 +27,7 @@ export class AutoRunController {accountId: number;type: AutoRunType;cycleType: string;+ dataId?: string;},) {const userInfo = getUserInfo();