--修改数据日志查询连接配置错误
This commit is contained in:
@ -1,6 +1,7 @@
|
|||||||
package com.xjrsoft.module.test.controller;
|
package com.xjrsoft.module.test.controller;
|
||||||
|
|
||||||
import org.springframework.beans.factory.annotation.Autowired;
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
|
import org.springframework.transaction.annotation.Transactional;
|
||||||
import org.springframework.web.bind.annotation.GetMapping;
|
import org.springframework.web.bind.annotation.GetMapping;
|
||||||
import org.springframework.web.bind.annotation.RequestMapping;
|
import org.springframework.web.bind.annotation.RequestMapping;
|
||||||
import org.springframework.web.bind.annotation.RequestParam;
|
import org.springframework.web.bind.annotation.RequestParam;
|
||||||
@ -10,6 +11,7 @@ import com.xjrsoft.common.model.result.R;
|
|||||||
import com.xjrsoft.module.common.db.service.CommonCallService;
|
import com.xjrsoft.module.common.db.service.CommonCallService;
|
||||||
import com.xjrsoft.module.dev.entity.Testfrom3;
|
import com.xjrsoft.module.dev.entity.Testfrom3;
|
||||||
import com.xjrsoft.module.dev.vo.Testfrom3Vo;
|
import com.xjrsoft.module.dev.vo.Testfrom3Vo;
|
||||||
|
import com.xjrsoft.module.system.client.ICodeRuleClient;
|
||||||
|
|
||||||
import cn.dev33.satoken.annotation.SaCheckPermission;
|
import cn.dev33.satoken.annotation.SaCheckPermission;
|
||||||
import cn.hutool.core.bean.BeanUtil;
|
import cn.hutool.core.bean.BeanUtil;
|
||||||
@ -24,6 +26,9 @@ public class CallTest {
|
|||||||
@Autowired
|
@Autowired
|
||||||
private CommonCallService callService;
|
private CommonCallService callService;
|
||||||
|
|
||||||
|
@Autowired
|
||||||
|
private ICodeRuleClient client;
|
||||||
|
|
||||||
@GetMapping(value = "/fSave")
|
@GetMapping(value = "/fSave")
|
||||||
@ApiOperation(value="根据id查询Testfrom3信息")
|
@ApiOperation(value="根据id查询Testfrom3信息")
|
||||||
public R info(){
|
public R info(){
|
||||||
@ -31,5 +36,19 @@ public class CallTest {
|
|||||||
System.out.println(out);
|
System.out.println(out);
|
||||||
return R.ok(null);
|
return R.ok(null);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
@GetMapping(value = "/CodeRule")
|
||||||
|
@ApiOperation(value="根据id查询Testfrom3信息")
|
||||||
|
public R CodeRule(){
|
||||||
|
String code = genEncode();
|
||||||
|
System.out.println(code);
|
||||||
|
return R.ok(null);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Transactional
|
||||||
|
public String genEncode() {
|
||||||
|
return client.genEncode("bankCode");
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|||||||
@ -820,7 +820,7 @@ public class DataLogTools {
|
|||||||
String sql = parseSql(SQL_LIST, tableName);
|
String sql = parseSql(SQL_LIST, tableName);
|
||||||
JdbcContext context = null;
|
JdbcContext context = null;
|
||||||
try {
|
try {
|
||||||
context = new JdbcContext(true,false);
|
context = new JdbcContext(true,true);
|
||||||
context.init(sql);
|
context.init(sql);
|
||||||
context.setParams(ListUtils.ofArray(JdbcParam.ofLong(dataId)));
|
context.setParams(ListUtils.ofArray(JdbcParam.ofLong(dataId)));
|
||||||
ResultSet set = context.executeQuery();
|
ResultSet set = context.executeQuery();
|
||||||
|
|||||||
Reference in New Issue
Block a user