API数据表更新
This commit is contained in:
94
src/main/java/com/mini/capi/biz/domain/DbConfig.java
Normal file
94
src/main/java/com/mini/capi/biz/domain/DbConfig.java
Normal file
@@ -0,0 +1,94 @@
|
||||
package com.mini.capi.biz.domain;
|
||||
|
||||
import com.baomidou.mybatisplus.annotation.IdType;
|
||||
import com.baomidou.mybatisplus.annotation.TableField;
|
||||
import com.baomidou.mybatisplus.annotation.TableId;
|
||||
import com.baomidou.mybatisplus.annotation.TableName;
|
||||
import java.io.Serializable;
|
||||
import java.time.LocalDateTime;
|
||||
import lombok.Getter;
|
||||
import lombok.Setter;
|
||||
|
||||
/**
|
||||
* <p>
|
||||
*
|
||||
* </p>
|
||||
*
|
||||
* @author gaoxq
|
||||
* @since 2025-08-26
|
||||
*/
|
||||
@Getter
|
||||
@Setter
|
||||
@TableName("biz_db_config")
|
||||
public class DbConfig implements Serializable {
|
||||
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
@TableField("create_time")
|
||||
private LocalDateTime createTime;
|
||||
|
||||
@TableId(value = "db_id", type = IdType.AUTO)
|
||||
private String dbId;
|
||||
|
||||
@TableField("db_type")
|
||||
private String dbType;
|
||||
|
||||
@TableField("db_name")
|
||||
private String dbName;
|
||||
|
||||
@TableField("host")
|
||||
private String host;
|
||||
|
||||
@TableField("port")
|
||||
private Integer port;
|
||||
|
||||
@TableField("username")
|
||||
private String username;
|
||||
|
||||
@TableField("password")
|
||||
private String password;
|
||||
|
||||
@TableField("driver_class")
|
||||
private String driverClass;
|
||||
|
||||
@TableField("url_template")
|
||||
private String urlTemplate;
|
||||
|
||||
@TableField("is_active")
|
||||
private Boolean isActive;
|
||||
|
||||
@TableField("update_time")
|
||||
private LocalDateTime updateTime;
|
||||
|
||||
/**
|
||||
* 租户id
|
||||
*/
|
||||
@TableField("f_tenant_id")
|
||||
private String fTenantId;
|
||||
|
||||
/**
|
||||
* 流程id
|
||||
*/
|
||||
@TableField("f_flow_id")
|
||||
private String fFlowId;
|
||||
|
||||
/**
|
||||
* 流程任务主键
|
||||
*/
|
||||
@TableField("f_flow_task_id")
|
||||
private String fFlowTaskId;
|
||||
|
||||
/**
|
||||
* 流程任务状态
|
||||
*/
|
||||
@TableField("f_flow_state")
|
||||
private Integer fFlowState;
|
||||
|
||||
|
||||
// 生成数据库连接URL
|
||||
public String getJdbcUrl() {
|
||||
return urlTemplate.replace("{host}", host)
|
||||
.replace("{port}", port.toString())
|
||||
.replace("{dbName}", dbName);
|
||||
}
|
||||
}
|
||||
89
src/main/java/com/mini/capi/biz/domain/SyncTask.java
Normal file
89
src/main/java/com/mini/capi/biz/domain/SyncTask.java
Normal file
@@ -0,0 +1,89 @@
|
||||
package com.mini.capi.biz.domain;
|
||||
|
||||
import com.baomidou.mybatisplus.annotation.IdType;
|
||||
import com.baomidou.mybatisplus.annotation.TableField;
|
||||
import com.baomidou.mybatisplus.annotation.TableId;
|
||||
import com.baomidou.mybatisplus.annotation.TableName;
|
||||
import java.io.Serializable;
|
||||
import java.time.LocalDateTime;
|
||||
import lombok.Getter;
|
||||
import lombok.Setter;
|
||||
|
||||
/**
|
||||
* <p>
|
||||
*
|
||||
* </p>
|
||||
*
|
||||
* @author gaoxq
|
||||
* @since 2025-08-26
|
||||
*/
|
||||
@Getter
|
||||
@Setter
|
||||
@TableName("biz_sync_task")
|
||||
public class SyncTask implements Serializable {
|
||||
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
@TableField("create_time")
|
||||
private LocalDateTime createTime;
|
||||
|
||||
@TableId(value = "task_id", type = IdType.AUTO)
|
||||
private String taskId;
|
||||
|
||||
@TableField("task_name")
|
||||
private String taskName;
|
||||
|
||||
@TableField("source_db_id")
|
||||
private String sourceDbId;
|
||||
|
||||
@TableField("target_db_id")
|
||||
private String targetDbId;
|
||||
|
||||
@TableField("source_table")
|
||||
private String sourceTable;
|
||||
|
||||
@TableField("target_table")
|
||||
private String targetTable;
|
||||
|
||||
@TableField("sync_type")
|
||||
private String syncType;
|
||||
|
||||
@TableField("increment_column")
|
||||
private String incrementColumn;
|
||||
|
||||
@TableField("cron_expression")
|
||||
private String cronExpression;
|
||||
|
||||
@TableField("is_active")
|
||||
private Boolean isActive;
|
||||
|
||||
@TableField("last_sync_time")
|
||||
private LocalDateTime lastSyncTime;
|
||||
|
||||
@TableField("update_time")
|
||||
private LocalDateTime updateTime;
|
||||
|
||||
/**
|
||||
* 租户id
|
||||
*/
|
||||
@TableField("f_tenant_id")
|
||||
private String fTenantId;
|
||||
|
||||
/**
|
||||
* 流程id
|
||||
*/
|
||||
@TableField("f_flow_id")
|
||||
private String fFlowId;
|
||||
|
||||
/**
|
||||
* 流程任务主键
|
||||
*/
|
||||
@TableField("f_flow_task_id")
|
||||
private String fFlowTaskId;
|
||||
|
||||
/**
|
||||
* 流程任务状态
|
||||
*/
|
||||
@TableField("f_flow_state")
|
||||
private Integer fFlowState;
|
||||
}
|
||||
Reference in New Issue
Block a user