1
This commit is contained in:
@@ -0,0 +1,47 @@
|
||||
package com.ruoyi.jarvis.domain;
|
||||
|
||||
import com.ruoyi.common.core.domain.BaseEntity;
|
||||
import lombok.Data;
|
||||
import lombok.EqualsAndHashCode;
|
||||
|
||||
/**
|
||||
* 腾讯文档操作日志对象 tencent_doc_operation_log
|
||||
*
|
||||
* @author system
|
||||
*/
|
||||
@Data
|
||||
@EqualsAndHashCode(callSuper = true)
|
||||
public class TencentDocOperationLog extends BaseEntity {
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/** 主键ID */
|
||||
private Long id;
|
||||
|
||||
/** 文档ID */
|
||||
private String fileId;
|
||||
|
||||
/** 工作表ID */
|
||||
private String sheetId;
|
||||
|
||||
/** 操作类型 */
|
||||
private String operationType;
|
||||
|
||||
/** 订单单号 */
|
||||
private String orderNo;
|
||||
|
||||
/** 目标行号 */
|
||||
private Integer targetRow;
|
||||
|
||||
/** 写入的物流链接 */
|
||||
private String logisticsLink;
|
||||
|
||||
/** 操作状态 */
|
||||
private String operationStatus;
|
||||
|
||||
/** 错误信息 */
|
||||
private String errorMessage;
|
||||
|
||||
/** 操作人 */
|
||||
private String operator;
|
||||
}
|
||||
|
||||
@@ -0,0 +1,21 @@
|
||||
package com.ruoyi.jarvis.mapper;
|
||||
|
||||
import com.ruoyi.jarvis.domain.TencentDocOperationLog;
|
||||
import org.apache.ibatis.annotations.Mapper;
|
||||
|
||||
/**
|
||||
* 腾讯文档操作日志Mapper接口
|
||||
*
|
||||
* @author system
|
||||
*/
|
||||
@Mapper
|
||||
public interface TencentDocOperationLogMapper {
|
||||
/**
|
||||
* 插入操作日志
|
||||
*
|
||||
* @param log 操作日志
|
||||
* @return 结果
|
||||
*/
|
||||
int insertLog(TencentDocOperationLog log);
|
||||
}
|
||||
|
||||
@@ -1233,10 +1233,11 @@ private String handleTF(String input) {
|
||||
jdOrderService.insertJDOrder(order);
|
||||
}
|
||||
|
||||
// 如果分销标识是 H-TF,自动写入腾讯文档
|
||||
if ("H-TF".equals(order.getDistributionMark())) {
|
||||
asyncWriteToTencentDoc(order);
|
||||
}
|
||||
// 注意:H-TF订单不再自动写入腾讯文档,需通过订单列表手动触发
|
||||
// 原因:防止并发写入和数据覆盖,需要人工确认
|
||||
// if ("H-TF".equals(order.getDistributionMark())) {
|
||||
// asyncWriteToTencentDoc(order);
|
||||
// }
|
||||
|
||||
// 返回完整的表单格式,使用原始输入保留完整物流链接
|
||||
return formatOrderForm(order, originalInput);
|
||||
|
||||
@@ -0,0 +1,53 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<!DOCTYPE mapper
|
||||
PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||
"http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||||
<mapper namespace="com.ruoyi.jarvis.mapper.TencentDocOperationLogMapper">
|
||||
|
||||
<resultMap type="com.ruoyi.jarvis.domain.TencentDocOperationLog" id="TencentDocOperationLogResult">
|
||||
<id property="id" column="id" />
|
||||
<result property="fileId" column="file_id" />
|
||||
<result property="sheetId" column="sheet_id" />
|
||||
<result property="operationType" column="operation_type" />
|
||||
<result property="orderNo" column="order_no" />
|
||||
<result property="targetRow" column="target_row" />
|
||||
<result property="logisticsLink" column="logistics_link" />
|
||||
<result property="operationStatus" column="operation_status" />
|
||||
<result property="errorMessage" column="error_message" />
|
||||
<result property="operator" column="operator" />
|
||||
<result property="createTime" column="create_time" />
|
||||
<result property="remark" column="remark" />
|
||||
</resultMap>
|
||||
|
||||
<insert id="insertLog" parameterType="com.ruoyi.jarvis.domain.TencentDocOperationLog">
|
||||
insert into tencent_doc_operation_log
|
||||
<trim prefix="(" suffix=")" suffixOverrides=",">
|
||||
<if test="fileId != null">file_id,</if>
|
||||
<if test="sheetId != null">sheet_id,</if>
|
||||
<if test="operationType != null">operation_type,</if>
|
||||
<if test="orderNo != null">order_no,</if>
|
||||
<if test="targetRow != null">target_row,</if>
|
||||
<if test="logisticsLink != null">logistics_link,</if>
|
||||
<if test="operationStatus != null">operation_status,</if>
|
||||
<if test="errorMessage != null">error_message,</if>
|
||||
<if test="operator != null">operator,</if>
|
||||
<if test="remark != null">remark,</if>
|
||||
create_time
|
||||
</trim>
|
||||
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
||||
<if test="fileId != null">#{fileId},</if>
|
||||
<if test="sheetId != null">#{sheetId},</if>
|
||||
<if test="operationType != null">#{operationType},</if>
|
||||
<if test="orderNo != null">#{orderNo},</if>
|
||||
<if test="targetRow != null">#{targetRow},</if>
|
||||
<if test="logisticsLink != null">#{logisticsLink},</if>
|
||||
<if test="operationStatus != null">#{operationStatus},</if>
|
||||
<if test="errorMessage != null">#{errorMessage},</if>
|
||||
<if test="operator != null">#{operator},</if>
|
||||
<if test="remark != null">#{remark},</if>
|
||||
now()
|
||||
</trim>
|
||||
</insert>
|
||||
|
||||
</mapper>
|
||||
|
||||
Reference in New Issue
Block a user