临时工作进度
This commit is contained in:
@@ -20,9 +20,8 @@ import java.lang.annotation.RetentionPolicy;
|
||||
import java.lang.annotation.Target;
|
||||
import java.lang.reflect.Method;
|
||||
|
||||
|
||||
@Aspect
|
||||
@Component
|
||||
@Aspect
|
||||
public class RequireAuthAndProxyAspect {
|
||||
|
||||
@Autowired
|
||||
@@ -58,6 +57,9 @@ public class RequireAuthAndProxyAspect {
|
||||
throw new RuntimeException("鉴权登录失败");
|
||||
}
|
||||
}
|
||||
else if (!EmoneyClient.relogin()) {
|
||||
throw new RuntimeException("检查重鉴权失败");
|
||||
}
|
||||
|
||||
return pjp.proceed();
|
||||
}
|
||||
|
||||
@@ -19,6 +19,8 @@ import com.baomidou.mybatisplus.extension.spring.MybatisSqlSessionFactoryBean;
|
||||
@Configuration
|
||||
@MapperScan(basePackages = "quant.rich.emoney.mapper.postgre", sqlSessionTemplateRef = "postgreSqlSessionTemplate")
|
||||
public class PostgreMybatisConfig {
|
||||
|
||||
public static final String POSTGRE_TRANSACTION_MANAGER = "postgreTransactionManager";
|
||||
|
||||
@Bean("postgreSqlSessionFactory")
|
||||
public SqlSessionFactory postgreSqlSessionFactory(
|
||||
@@ -40,7 +42,7 @@ public class PostgreMybatisConfig {
|
||||
return new SqlSessionTemplate(sqlSessionFactory);
|
||||
}
|
||||
|
||||
@Bean("postgreTransactionManager")
|
||||
@Bean(POSTGRE_TRANSACTION_MANAGER)
|
||||
public DataSourceTransactionManager postgreTransacetionManager(@Qualifier("postgreDataSource") DataSource dataSource) {
|
||||
return new DataSourceTransactionManager(dataSource);
|
||||
}
|
||||
|
||||
@@ -121,7 +121,7 @@ public class SqliteMybatisConfig {
|
||||
return new SqlSessionTemplate(sqlSessionFactory);
|
||||
}
|
||||
|
||||
@Bean("sqliteTransactionManager")
|
||||
@Bean(SQLITE_TRANSACTION_MANAGER)
|
||||
public DataSourceTransactionManager postgreTransacetionManager(@Qualifier("sqliteDataSource") DataSource dataSource) {
|
||||
return new DataSourceTransactionManager(dataSource);
|
||||
}
|
||||
|
||||
@@ -1,5 +1,7 @@
|
||||
package quant.rich.emoney.entity.postgre;
|
||||
|
||||
import java.time.LocalDateTime;
|
||||
|
||||
import lombok.Data;
|
||||
import lombok.experimental.Accessors;
|
||||
|
||||
@@ -12,6 +14,18 @@ public class StockStrategy {
|
||||
|
||||
private String tsCode;
|
||||
|
||||
private LocalDateTime date;
|
||||
|
||||
private String strategyName;
|
||||
|
||||
private Integer strategyId;
|
||||
|
||||
private String poolName;
|
||||
|
||||
private String type;
|
||||
|
||||
private Integer poolId;
|
||||
|
||||
public StockStrategy setTsCodeFromGoodsId(Integer goodsId) {
|
||||
// 自动将益盟 goodsId 转换成 tsCode
|
||||
// 1301325 -> 301325.SZ
|
||||
|
||||
Reference in New Issue
Block a user