@Test public void getTaskTableByDbNames() throws Exception { List<String> names = Lists.newArrayList("risk_scene_strategy", "risk_template"); List<TaskTable> list = tableEntityDao.getTaskTableByCustomTableNames(39L, names); System.out.println("getTaskTableByCustomTableNames :-------> " + list); Assert.assertTrue(list.size() > 0); }
public List<TaskTable> getTaskTableByCustomTableNames(Long project_id, List<String> names) throws SQLException { TaskTable.TaskTableDefinition t = TaskTable.TASKTABLE; SqlBuilder builder = SqlBuilder.selectAllFrom(t).where().allOf(t.customTableName.in(names), t.projectId.eq(project_id)).into(TaskTable.class); return this.getDasClient().query(builder); }
TableEntityDao extends BaseDao { public List<TaskTable> getTaskTableByCustomTableNames(Long project_id, List<String> names) throws SQLException { TaskTable.TaskTableDefinition t = TaskTable.TASKTABLE; SqlBuilder builder = SqlBuilder.selectAllFrom(t).where().allOf(t.customTableName.in(names), t.projectId.eq(project_id)).into(TaskTable.class); return this.getDasClient().query(builder); } }
TableEntityDao extends BaseDao { public List<TaskTable> getTaskTableByCustomTableNames(Long project_id, List<String> names) throws SQLException { TaskTable.TaskTableDefinition t = TaskTable.TASKTABLE; SqlBuilder builder = SqlBuilder.selectAllFrom(t).where().allOf(t.customTableName.in(names), t.projectId.eq(project_id)).into(TaskTable.class); return this.getDasClient().query(builder); }  }
TableEntityDao extends BaseDao { public List<TaskTable> getTaskTableByCustomTableNames(Long project_id, List<String> names) throws SQLException { TaskTable.TaskTableDefinition t = TaskTable.TASKTABLE; SqlBuilder builder = SqlBuilder.selectAllFrom(t).where().allOf(t.customTableName.in(names), t.projectId.eq(project_id)).into(TaskTable.class); return this.getDasClient().query(builder); }  Long insertTask(TaskTable task); int[] insertTaskTablelist(List<TaskTable> list); int updateTask(TaskTable taskTable); int deleteTask(TaskTable taskTable); int deleteByProjectId(int id); TaskTable getTasksByTaskId(Long id); List<TaskTable> getTaskTableByCustomTableNames(Long project_id, List<String> names); List<TaskTable> getTaskTablesByTableNames(Long project_id, List<String> names); List<TaskTableView> getTasksByProjectId(Long projectId); Long getTableEntityTotalCount(Paging<TaskTable> paging); List<TaskTableView> findTableEntityPageList(Paging<TaskTable> paging); List<TaskTableView> findTableEntitysByDbId(Long paging); }
TableEntityDao extends BaseDao { public List<TaskTable> getTaskTableByCustomTableNames(Long project_id, List<String> names) throws SQLException { TaskTable.TaskTableDefinition t = TaskTable.TASKTABLE; SqlBuilder builder = SqlBuilder.selectAllFrom(t).where().allOf(t.customTableName.in(names), t.projectId.eq(project_id)).into(TaskTable.class); return this.getDasClient().query(builder); }  Long insertTask(TaskTable task); int[] insertTaskTablelist(List<TaskTable> list); int updateTask(TaskTable taskTable); int deleteTask(TaskTable taskTable); int deleteByProjectId(int id); TaskTable getTasksByTaskId(Long id); List<TaskTable> getTaskTableByCustomTableNames(Long project_id, List<String> names); List<TaskTable> getTaskTablesByTableNames(Long project_id, List<String> names); List<TaskTableView> getTasksByProjectId(Long projectId); Long getTableEntityTotalCount(Paging<TaskTable> paging); List<TaskTableView> findTableEntityPageList(Paging<TaskTable> paging); List<TaskTableView> findTableEntitysByDbId(Long paging);  }