bug
lrj
2024-10-25 a6470c4de7867f5478197c390c158ad730ff5bae
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
package com.ycl.scheme.service;
 
 
import com.ycl.scheme.KeywordExample;
import com.ycl.scheme.Parameter;
import com.ycl.scheme.SchemeRunnerBuilder;
import com.ycl.scheme.entity.Keyword;
import com.ycl.scheme.entity.Scheme;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.jdbc.core.JdbcTemplate;
import org.springframework.jdbc.datasource.DataSourceUtils;
import org.springframework.scheduling.annotation.Async;
import org.springframework.stereotype.Service;
 
import java.sql.Connection;
import java.util.List;
import java.util.Map;
 
@Service
public class SchemeService {
 
 
    private JdbcTemplate jdbcTemplate;
 
 
    @Autowired
    public void setJdbcTemplate(JdbcTemplate jdbcTemplate) {
        this.jdbcTemplate = jdbcTemplate;
    }
 
    public void buildScheme(Scheme scheme){
        SchemeRunnerBuilder builder = new SchemeRunnerBuilder(this);
        builder.build(scheme);
 
 
        System.out.println(scheme.getOutCode());
    }
 
    public Object execQuery(String sql, Map<String,Object> pars){
        return 5;
    }
 
    /**
     * 执行action
     * @param schemeId
     */
    public void doAction(Integer schemeId){
 
 
        System.out.println("执行doAction" + schemeId);
    }
 
 
    public List<Keyword> findKeywordTemplates(){
        return KeywordExample.getKeywords();
    }
 
}