main
黄海 2 years ago
parent cf0fb53bfa
commit 421bfed421

@ -1607,7 +1607,7 @@ public class CollectController extends Controller {
}
/**
* IDEXCEL
* IDEXCEL()
*
* @param job_id
*/

@ -1727,8 +1727,16 @@ public class CollectModel {
* @return
*/
public List<Record> getTableDataByJobId(int job_id, String table_name) {
String sql = "select * from " + table_name + " where job_id = ?";
return Db.find(sql, job_id);
String sql = "select job_id from t_collect_job where parent_id=?";
List<Record> list = Db.find(sql, job_id);
String ids = job_id + ",";
for (Record record : list) {
ids += record.getStr("job_id") + ",";
}
if (ids.length() > 0) ids = ids.substring(0, ids.length() - 1);
sql = "select * from " + table_name + " where job_id in(" + ids + ")";
return Db.find(sql);
}
/**

Loading…
Cancel
Save