第三方单据选入相关修改

master
anthonywj 2 years ago
parent 5015ad932c
commit 7e9452d7de

@ -1,26 +1,94 @@
package com.glxp.api.entity.thrsys;
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 lombok.Data;
@Data
public class ThrSystemBusApiEntity {
@TableName(value = "thr_system_bus_api")
public class ThrSystemBusApiEntity implements Serializable {
@TableId(value = "id", type = IdType.AUTO)
private Integer id;
@TableField(value = "code")
private String code;
@TableField(value = "`name`")
private String name;
private String thirdBuyName; //第三方系统单据类型名称
private String thirdBuyCode; //第三方系统单据类型代码
/**
*
*/
@TableField(value = "thirdBuyCode")
private String thirdBuyCode;
@TableField(value = "thirdSys")
private String thirdSys;
@TableField(value = "url")
private String url;
private Integer type;
@TableField(value = "`type`")
private Byte type;
@TableField(value = "remark")
private String remark;
private Integer inoutType;
//扩展字段 暂未启用
/**
*
*/
@TableField(value = "filed")
private String filed;
@TableField(value = "filed1")
private String filed1;
@TableField(value = "filed2")
private String filed2;
@TableField(value = "filed3")
private String filed3;
@TableField(value = "filed4")
private String filed4;
@TableField(exist = false)
private Integer inoutType;
@TableField(exist = false)
private String thirdBuyName; //第三方系统单据类型名称
private static final long serialVersionUID = 1L;
public static final String COL_ID = "id";
public static final String COL_CODE = "code";
public static final String COL_NAME = "name";
public static final String COL_THIRDBUYCODE = "thirdBuyCode";
public static final String COL_THIRDSYS = "thirdSys";
public static final String COL_URL = "url";
public static final String COL_TYPE = "type";
public static final String COL_REMARK = "remark";
public static final String COL_FILED = "filed";
public static final String COL_FILED1 = "filed1";
public static final String COL_FILED2 = "filed2";
public static final String COL_FILED3 = "filed3";
public static final String COL_FILED4 = "filed4";
}

@ -3,16 +3,20 @@ package com.glxp.api.task;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.aop.interceptor.AsyncUncaughtExceptionHandler;
import org.springframework.boot.autoconfigure.condition.ConditionalOnProperty;
import org.springframework.boot.context.properties.EnableConfigurationProperties;
import org.springframework.context.annotation.Configuration;
import org.springframework.scheduling.annotation.AsyncConfigurer;
import org.springframework.scheduling.annotation.EnableAsync;
import org.springframework.scheduling.concurrent.ThreadPoolTaskExecutor;
import org.springframework.stereotype.Component;
import java.lang.reflect.Method;
import java.util.concurrent.Executor;
//@EnableAsync
//@Configuration
@EnableAsync
@Configuration
@ConditionalOnProperty(prefix = "spring.sgrain.async-thread-pool", name = "enable", havingValue = "true", matchIfMissing = false)
public class TaskExecutorConfig implements AsyncConfigurer {
private static final Logger log = LoggerFactory.getLogger(TaskExecutorConfig.class);
@ -31,4 +35,19 @@ public class TaskExecutorConfig implements AsyncConfigurer {
return threadPool;
}
class MyAsyncExceptionHandler implements AsyncUncaughtExceptionHandler {
//手动处理捕获的异常
@Override
public void handleUncaughtException(Throwable throwable, Method method, Object... obj) {
System.out.println("-------------》》》捕获线程异常信息");
log.info("Exception message - " + throwable.getMessage());
log.info("Method name - " + method.getName());
for (Object param : obj) {
log.info("Parameter value - " + param);
}
}
}
}

@ -75,12 +75,11 @@
<insert id="insertBusOriginType" parameterType="com.glxp.api.entity.thrsys.ThrBusTypeOriginEntity">
replace
into thr_bustype_origin
(`name`, `action`, thirdSys, thirdSysName, `enable`, inoutType, updateTime, remark, createUser, updateUser,
(`name`, `action`, thirdSys, `enable`, inoutType, updateTime, remark, createUser, updateUser,
createTime)
values (#{name},
#{action},
#{thirdSys},
#{thirdSysName},
#{enable},
#{inoutType},
#{updateTime},

@ -11,9 +11,6 @@
<if test="name != null">
`name`=#{name},
</if>
<if test="thirdBuyName != null">
`thirdBuyName`=#{thirdBuyName},
</if>
<if test="thirdBuyCode != null">
`thirdBuyCode`=#{thirdBuyCode},
</if>
@ -60,10 +57,9 @@
insert
ignore
INTO thr_system_bus_api
(`code`, `name`, thirdBuyName, thirdBuyCode, `thirdSys`, url, `type`, remark)
(`code`, `name`, thirdBuyCode, `thirdSys`, url, `type`, remark)
values (#{code},
#{name},
#{thirdBuyName},
#{thirdBuyCode},
#{thirdSys},
#{url},
@ -72,12 +68,11 @@
</insert>
<insert id="saveBusTypes">
insert into thr_system_bus_api (code, `name`, thirdBuyName, thirdBuyCode, thirdSys, type)
insert into thr_system_bus_api (code, `name`, thirdBuyCode, thirdSys, type)
values
<foreach collection="list" index="index" item="item" separator=",">
(#{item.code},
#{item.name},
#{item.thirdBuyName},
#{item.thirdBuyCode},
#{item.thirdSys},
#{item.type})

Loading…
Cancel
Save