temp定时任务修改
This commit is contained in:
@@ -0,0 +1,239 @@
|
||||
package org.xyzh.common.dto.crontab;
|
||||
|
||||
import org.xyzh.common.dto.BaseDTO;
|
||||
|
||||
import java.util.Date;
|
||||
|
||||
/**
|
||||
* @description 数据采集项表(存储爬取的文章数据)
|
||||
* @filename TbDataCollectionItem.java
|
||||
* @author yslg
|
||||
* @copyright xyzh
|
||||
* @since 2025-11-08
|
||||
*/
|
||||
public class TbDataCollectionItem extends BaseDTO {
|
||||
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/**
|
||||
* @description 关联的定时任务ID
|
||||
*/
|
||||
private String taskId;
|
||||
|
||||
/**
|
||||
* @description 文章标题
|
||||
*/
|
||||
private String title;
|
||||
|
||||
/**
|
||||
* @description 文章内容(HTML格式)
|
||||
*/
|
||||
private String content;
|
||||
|
||||
/**
|
||||
* @description 文章摘要
|
||||
*/
|
||||
private String summary;
|
||||
|
||||
/**
|
||||
* @description 来源(人民日报、新华社等)
|
||||
*/
|
||||
private String source;
|
||||
|
||||
/**
|
||||
* @description 来源URL(用于去重)
|
||||
*/
|
||||
private String sourceUrl;
|
||||
|
||||
/**
|
||||
* @description 分类(政治、社会、国际等)
|
||||
*/
|
||||
private String category;
|
||||
|
||||
/**
|
||||
* @description 作者
|
||||
*/
|
||||
private String author;
|
||||
|
||||
/**
|
||||
* @description 发布时间
|
||||
*/
|
||||
private Date publishTime;
|
||||
|
||||
/**
|
||||
* @description 封面图片URL
|
||||
*/
|
||||
private String coverImage;
|
||||
|
||||
/**
|
||||
* @description 图片列表(JSON格式,存储图片URL数组)
|
||||
*/
|
||||
private String images;
|
||||
|
||||
/**
|
||||
* @description 标签(多个用逗号分隔)
|
||||
*/
|
||||
private String tags;
|
||||
|
||||
/**
|
||||
* @description 状态(0:未处理 1:已转换为资源 2:已忽略)
|
||||
*/
|
||||
private Integer status;
|
||||
|
||||
/**
|
||||
* @description 转换后的资源ID(如果已转换为资源)
|
||||
*/
|
||||
private String resourceId;
|
||||
|
||||
/**
|
||||
* @description 爬取时间
|
||||
*/
|
||||
private Date crawlTime;
|
||||
|
||||
/**
|
||||
* @description 处理时间
|
||||
*/
|
||||
private Date processTime;
|
||||
|
||||
/**
|
||||
* @description 处理人
|
||||
*/
|
||||
private String processor;
|
||||
|
||||
public String getTaskId() {
|
||||
return taskId;
|
||||
}
|
||||
|
||||
public void setTaskId(String taskId) {
|
||||
this.taskId = taskId;
|
||||
}
|
||||
|
||||
public String getTitle() {
|
||||
return title;
|
||||
}
|
||||
|
||||
public void setTitle(String title) {
|
||||
this.title = title;
|
||||
}
|
||||
|
||||
public String getContent() {
|
||||
return content;
|
||||
}
|
||||
|
||||
public void setContent(String content) {
|
||||
this.content = content;
|
||||
}
|
||||
|
||||
public String getSummary() {
|
||||
return summary;
|
||||
}
|
||||
|
||||
public void setSummary(String summary) {
|
||||
this.summary = summary;
|
||||
}
|
||||
|
||||
public String getSource() {
|
||||
return source;
|
||||
}
|
||||
|
||||
public void setSource(String source) {
|
||||
this.source = source;
|
||||
}
|
||||
|
||||
public String getSourceUrl() {
|
||||
return sourceUrl;
|
||||
}
|
||||
|
||||
public void setSourceUrl(String sourceUrl) {
|
||||
this.sourceUrl = sourceUrl;
|
||||
}
|
||||
|
||||
public String getCategory() {
|
||||
return category;
|
||||
}
|
||||
|
||||
public void setCategory(String category) {
|
||||
this.category = category;
|
||||
}
|
||||
|
||||
public String getAuthor() {
|
||||
return author;
|
||||
}
|
||||
|
||||
public void setAuthor(String author) {
|
||||
this.author = author;
|
||||
}
|
||||
|
||||
public Date getPublishTime() {
|
||||
return publishTime;
|
||||
}
|
||||
|
||||
public void setPublishTime(Date publishTime) {
|
||||
this.publishTime = publishTime;
|
||||
}
|
||||
|
||||
public String getCoverImage() {
|
||||
return coverImage;
|
||||
}
|
||||
|
||||
public void setCoverImage(String coverImage) {
|
||||
this.coverImage = coverImage;
|
||||
}
|
||||
|
||||
public String getImages() {
|
||||
return images;
|
||||
}
|
||||
|
||||
public void setImages(String images) {
|
||||
this.images = images;
|
||||
}
|
||||
|
||||
public String getTags() {
|
||||
return tags;
|
||||
}
|
||||
|
||||
public void setTags(String tags) {
|
||||
this.tags = tags;
|
||||
}
|
||||
|
||||
public Integer getStatus() {
|
||||
return status;
|
||||
}
|
||||
|
||||
public void setStatus(Integer status) {
|
||||
this.status = status;
|
||||
}
|
||||
|
||||
public String getResourceId() {
|
||||
return resourceId;
|
||||
}
|
||||
|
||||
public void setResourceId(String resourceId) {
|
||||
this.resourceId = resourceId;
|
||||
}
|
||||
|
||||
public Date getCrawlTime() {
|
||||
return crawlTime;
|
||||
}
|
||||
|
||||
public void setCrawlTime(Date crawlTime) {
|
||||
this.crawlTime = crawlTime;
|
||||
}
|
||||
|
||||
public Date getProcessTime() {
|
||||
return processTime;
|
||||
}
|
||||
|
||||
public void setProcessTime(Date processTime) {
|
||||
this.processTime = processTime;
|
||||
}
|
||||
|
||||
public String getProcessor() {
|
||||
return processor;
|
||||
}
|
||||
|
||||
public void setProcessor(String processor) {
|
||||
this.processor = processor;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,146 +0,0 @@
|
||||
package org.xyzh.common.dto.resource;
|
||||
|
||||
import org.xyzh.common.dto.BaseDTO;
|
||||
import java.util.Date;
|
||||
|
||||
/**
|
||||
* @description 数据采集配置表
|
||||
* @filename TbDataCollectionConfig.java
|
||||
* @author yslg
|
||||
* @copyright xyzh
|
||||
* @since 2025-10-15
|
||||
*/
|
||||
public class TbDataCollectionConfig extends BaseDTO {
|
||||
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/**
|
||||
* @description 配置名称
|
||||
*/
|
||||
private String name;
|
||||
|
||||
/**
|
||||
* @description 采集源URL
|
||||
*/
|
||||
private String sourceUrl;
|
||||
|
||||
/**
|
||||
* @description 采集源类型
|
||||
*/
|
||||
private String sourceType;
|
||||
|
||||
/**
|
||||
* @description 采集频率(daily每天 weekly每周)
|
||||
*/
|
||||
private String frequency;
|
||||
|
||||
/**
|
||||
* @description 默认标签ID(文章分类标签,tagType=1)
|
||||
*/
|
||||
private String tagID;
|
||||
|
||||
/**
|
||||
* @description 状态(0禁用 1启用)
|
||||
*/
|
||||
private Integer status;
|
||||
|
||||
/**
|
||||
* @description 最后采集时间
|
||||
*/
|
||||
private Date lastCollectTime;
|
||||
|
||||
/**
|
||||
* @description 创建者
|
||||
*/
|
||||
private String creator;
|
||||
|
||||
/**
|
||||
* @description 更新者
|
||||
*/
|
||||
private String updater;
|
||||
|
||||
public String getName() {
|
||||
return name;
|
||||
}
|
||||
|
||||
public void setName(String name) {
|
||||
this.name = name;
|
||||
}
|
||||
|
||||
public String getSourceUrl() {
|
||||
return sourceUrl;
|
||||
}
|
||||
|
||||
public void setSourceUrl(String sourceUrl) {
|
||||
this.sourceUrl = sourceUrl;
|
||||
}
|
||||
|
||||
public String getSourceType() {
|
||||
return sourceType;
|
||||
}
|
||||
|
||||
public void setSourceType(String sourceType) {
|
||||
this.sourceType = sourceType;
|
||||
}
|
||||
|
||||
public String getFrequency() {
|
||||
return frequency;
|
||||
}
|
||||
|
||||
public void setFrequency(String frequency) {
|
||||
this.frequency = frequency;
|
||||
}
|
||||
|
||||
public String getTagID() {
|
||||
return tagID;
|
||||
}
|
||||
|
||||
public void setTagID(String tagID) {
|
||||
this.tagID = tagID;
|
||||
}
|
||||
|
||||
public Integer getStatus() {
|
||||
return status;
|
||||
}
|
||||
|
||||
public void setStatus(Integer status) {
|
||||
this.status = status;
|
||||
}
|
||||
|
||||
public Date getLastCollectTime() {
|
||||
return lastCollectTime;
|
||||
}
|
||||
|
||||
public void setLastCollectTime(Date lastCollectTime) {
|
||||
this.lastCollectTime = lastCollectTime;
|
||||
}
|
||||
|
||||
public String getCreator() {
|
||||
return creator;
|
||||
}
|
||||
|
||||
public void setCreator(String creator) {
|
||||
this.creator = creator;
|
||||
}
|
||||
|
||||
public String getUpdater() {
|
||||
return updater;
|
||||
}
|
||||
|
||||
public void setUpdater(String updater) {
|
||||
this.updater = updater;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return "TbDataCollectionConfig{" +
|
||||
"id=" + getID() +
|
||||
", name='" + name + '\'' +
|
||||
", sourceUrl='" + sourceUrl + '\'' +
|
||||
", sourceType='" + sourceType + '\'' +
|
||||
", frequency='" + frequency + '\'' +
|
||||
", status=" + status +
|
||||
", lastCollectTime=" + lastCollectTime +
|
||||
'}';
|
||||
}
|
||||
}
|
||||
@@ -1,120 +0,0 @@
|
||||
package org.xyzh.common.dto.resource;
|
||||
|
||||
import org.xyzh.common.dto.BaseDTO;
|
||||
import java.util.Date;
|
||||
|
||||
/**
|
||||
* @description 数据采集记录表
|
||||
* @filename TbDataCollectionLog.java
|
||||
* @author yslg
|
||||
* @copyright xyzh
|
||||
* @since 2025-10-15
|
||||
*/
|
||||
public class TbDataCollectionLog extends BaseDTO {
|
||||
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/**
|
||||
* @description 配置ID
|
||||
*/
|
||||
private String configID;
|
||||
|
||||
/**
|
||||
* @description 采集数量
|
||||
*/
|
||||
private Integer collectCount;
|
||||
|
||||
/**
|
||||
* @description 成功数量
|
||||
*/
|
||||
private Integer successCount;
|
||||
|
||||
/**
|
||||
* @description 失败数量
|
||||
*/
|
||||
private Integer failCount;
|
||||
|
||||
/**
|
||||
* @description 状态(0失败 1成功 2部分成功)
|
||||
*/
|
||||
private Integer status;
|
||||
|
||||
/**
|
||||
* @description 采集消息
|
||||
*/
|
||||
private String message;
|
||||
|
||||
/**
|
||||
* @description 采集时间
|
||||
*/
|
||||
private Date collectTime;
|
||||
|
||||
public String getConfigID() {
|
||||
return configID;
|
||||
}
|
||||
|
||||
public void setConfigID(String configID) {
|
||||
this.configID = configID;
|
||||
}
|
||||
|
||||
public Integer getCollectCount() {
|
||||
return collectCount;
|
||||
}
|
||||
|
||||
public void setCollectCount(Integer collectCount) {
|
||||
this.collectCount = collectCount;
|
||||
}
|
||||
|
||||
public Integer getSuccessCount() {
|
||||
return successCount;
|
||||
}
|
||||
|
||||
public void setSuccessCount(Integer successCount) {
|
||||
this.successCount = successCount;
|
||||
}
|
||||
|
||||
public Integer getFailCount() {
|
||||
return failCount;
|
||||
}
|
||||
|
||||
public void setFailCount(Integer failCount) {
|
||||
this.failCount = failCount;
|
||||
}
|
||||
|
||||
public Integer getStatus() {
|
||||
return status;
|
||||
}
|
||||
|
||||
public void setStatus(Integer status) {
|
||||
this.status = status;
|
||||
}
|
||||
|
||||
public String getMessage() {
|
||||
return message;
|
||||
}
|
||||
|
||||
public void setMessage(String message) {
|
||||
this.message = message;
|
||||
}
|
||||
|
||||
public Date getCollectTime() {
|
||||
return collectTime;
|
||||
}
|
||||
|
||||
public void setCollectTime(Date collectTime) {
|
||||
this.collectTime = collectTime;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return "TbDataCollectionLog{" +
|
||||
"id=" + getID() +
|
||||
", configID='" + configID + '\'' +
|
||||
", collectCount=" + collectCount +
|
||||
", successCount=" + successCount +
|
||||
", failCount=" + failCount +
|
||||
", status=" + status +
|
||||
", collectTime=" + collectTime +
|
||||
'}';
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,84 @@
|
||||
package org.xyzh.common.vo;
|
||||
|
||||
import org.xyzh.common.dto.crontab.TbDataCollectionItem;
|
||||
import org.xyzh.common.dto.crontab.TbCrontabTask;
|
||||
|
||||
import java.io.Serializable;
|
||||
|
||||
/**
|
||||
* @description 数据采集项VO
|
||||
* @filename DataCollectionItemVO.java
|
||||
* @author yslg
|
||||
* @copyright xyzh
|
||||
* @since 2025-11-08
|
||||
*/
|
||||
public class DataCollectionItemVO implements Serializable {
|
||||
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/**
|
||||
* @description 采集项数据
|
||||
*/
|
||||
private TbDataCollectionItem item;
|
||||
|
||||
/**
|
||||
* @description 关联的定时任务信息
|
||||
*/
|
||||
private TbCrontabTask task;
|
||||
|
||||
/**
|
||||
* @description 状态文本(用于前端显示)
|
||||
*/
|
||||
private String statusText;
|
||||
|
||||
/**
|
||||
* @description 是否可以编辑(未处理和已忽略的可以编辑)
|
||||
*/
|
||||
private Boolean canEdit;
|
||||
|
||||
/**
|
||||
* @description 是否可以转换为资源(未处理的可以转换)
|
||||
*/
|
||||
private Boolean canConvert;
|
||||
|
||||
public TbDataCollectionItem getItem() {
|
||||
return item;
|
||||
}
|
||||
|
||||
public void setItem(TbDataCollectionItem item) {
|
||||
this.item = item;
|
||||
}
|
||||
|
||||
public TbCrontabTask getTask() {
|
||||
return task;
|
||||
}
|
||||
|
||||
public void setTask(TbCrontabTask task) {
|
||||
this.task = task;
|
||||
}
|
||||
|
||||
public String getStatusText() {
|
||||
return statusText;
|
||||
}
|
||||
|
||||
public void setStatusText(String statusText) {
|
||||
this.statusText = statusText;
|
||||
}
|
||||
|
||||
public Boolean getCanEdit() {
|
||||
return canEdit;
|
||||
}
|
||||
|
||||
public void setCanEdit(Boolean canEdit) {
|
||||
this.canEdit = canEdit;
|
||||
}
|
||||
|
||||
public Boolean getCanConvert() {
|
||||
return canConvert;
|
||||
}
|
||||
|
||||
public void setCanConvert(Boolean canConvert) {
|
||||
this.canConvert = canConvert;
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user