|
|
@@ -10,19 +10,19 @@ import java.sql.SQLException;
|
|
|
|
|
|
/**
|
|
|
* Created by Pro1 on 2017/7/28.
|
|
|
- */
|
|
|
+ */
|
|
|
//@RunWith(SpringJUnit4ClassRunner.class)
|
|
|
//@SpringBootTest(webEnvironment = SpringBootTest.WebEnvironment.NONE, classes = UasSchedulingApplication.class)
|
|
|
-public class RestJdbcTest {
|
|
|
+ public class RestJdbcTest {
|
|
|
|
|
|
- @Autowired
|
|
|
- private RestJdbcTemplate restJdbcTemplate;
|
|
|
+ @Autowired
|
|
|
+ private RestJdbcTemplate restJdbcTemplate;
|
|
|
|
|
|
-// @Test
|
|
|
- public void testQuery() throws SQLException{
|
|
|
- Master master = new Master();
|
|
|
- master.setMa_user("UAS");
|
|
|
- ContextHolder.setMaster(master);
|
|
|
+ // @Test
|
|
|
+ public void testQuery() throws SQLException{
|
|
|
+ Master master = new Master();
|
|
|
+ master.setMa_user("UAS");
|
|
|
+ ContextHolder.setMaster(master);
|
|
|
|
|
|
Form form = restJdbcTemplate.queryForBean("select * from form where fo_caller=?", Form.class, "Purchase");
|
|
|
System.out.println(JSON.toJSONString(form));
|