@Test public void isGroupHadDBTest2() throws SQLException { DataBaseInfo dalGroupDB = DataBaseInfo.builder().dbname("name").build(); Assert.assertTrue(groupDatabaseService.isGroupHadDB(dalGroupDB)); }
public boolean isGroupHadDB(Long dbId, Long groupId) throws SQLException { DataBaseInfo dataBaseInfo = dataBaseDao.getDataBaseInfoByDbId(dbId); if (null != dataBaseInfo && null != dataBaseInfo.getDal_group_id() && dataBaseInfo.getDal_group_id().equals(groupId)) { return true; } return false; }
GroupDatabaseService { public boolean isGroupHadDB(Long dbId, Long groupId) throws SQLException { DataBaseInfo dataBaseInfo = dataBaseDao.getDataBaseInfoByDbId(dbId); if (null != dataBaseInfo && null != dataBaseInfo.getDal_group_id() && dataBaseInfo.getDal_group_id().equals(groupId)) { return true; } return false; } }
GroupDatabaseService { public boolean isGroupHadDB(Long dbId, Long groupId) throws SQLException { DataBaseInfo dataBaseInfo = dataBaseDao.getDataBaseInfoByDbId(dbId); if (null != dataBaseInfo && null != dataBaseInfo.getDal_group_id() && dataBaseInfo.getDal_group_id().equals(groupId)) { return true; } return false; }  }
GroupDatabaseService { public boolean isGroupHadDB(Long dbId, Long groupId) throws SQLException { DataBaseInfo dataBaseInfo = dataBaseDao.getDataBaseInfoByDbId(dbId); if (null != dataBaseInfo && null != dataBaseInfo.getDal_group_id() && dataBaseInfo.getDal_group_id().equals(groupId)) { return true; } return false; }  ValidatorChain validatePermision(LoginUser user, Errors errors); boolean isGroupHadDB(Long dbId, Long groupId); boolean isGroupHadDB(DataBaseInfo dataBaseModel); boolean validateTransferPermision(Long userId, Long dbId); }
GroupDatabaseService { public boolean isGroupHadDB(Long dbId, Long groupId) throws SQLException { DataBaseInfo dataBaseInfo = dataBaseDao.getDataBaseInfoByDbId(dbId); if (null != dataBaseInfo && null != dataBaseInfo.getDal_group_id() && dataBaseInfo.getDal_group_id().equals(groupId)) { return true; } return false; }  ValidatorChain validatePermision(LoginUser user, Errors errors); boolean isGroupHadDB(Long dbId, Long groupId); boolean isGroupHadDB(DataBaseInfo dataBaseModel); boolean validateTransferPermision(Long userId, Long dbId);  }