@Test @Sql(scripts = { "/sql/instrumenttype/clearInstrumentType.sql", "/sql/instrumenttype/insertInstrumentTypeData.sql" }) public void test_delete() { InstrumentTypeEntity instrumentType = InstrumentTypeEntity.builder().id("1").name("name").description("description") .active(true).build(); instrumentType.setTenantId("default"); InstrumentTypeEntity actualResult = instrumentTypeJdbcRepository.delete(instrumentType); List<Map<String, Object>> result = namedParameterJdbcTemplate.query("SELECT * FROM egf_instrumentType", new InstrumentTypeResultExtractor()); assertTrue("Result set length is zero", result.size() == 0); }
public InstrumentTypeEntity delete(InstrumentTypeEntity entity) { super.delete(InstrumentTypeEntity.TABLE_NAME, entity.getId()); return entity; }
InstrumentTypeJdbcRepository extends JdbcRepository { public InstrumentTypeEntity delete(InstrumentTypeEntity entity) { super.delete(InstrumentTypeEntity.TABLE_NAME, entity.getId()); return entity; } }
InstrumentTypeJdbcRepository extends JdbcRepository { public InstrumentTypeEntity delete(InstrumentTypeEntity entity) { super.delete(InstrumentTypeEntity.TABLE_NAME, entity.getId()); return entity; } InstrumentTypeJdbcRepository(NamedParameterJdbcTemplate namedParameterJdbcTemplate, JdbcTemplate jdbcTemplate); }
InstrumentTypeJdbcRepository extends JdbcRepository { public InstrumentTypeEntity delete(InstrumentTypeEntity entity) { super.delete(InstrumentTypeEntity.TABLE_NAME, entity.getId()); return entity; } InstrumentTypeJdbcRepository(NamedParameterJdbcTemplate namedParameterJdbcTemplate, JdbcTemplate jdbcTemplate); InstrumentTypeEntity create(InstrumentTypeEntity entity); InstrumentTypeEntity update(InstrumentTypeEntity entity); InstrumentTypeEntity delete(InstrumentTypeEntity entity); Pagination<InstrumentType> search(InstrumentTypeSearch domain); InstrumentTypeEntity findById(InstrumentTypeEntity entity); }
InstrumentTypeJdbcRepository extends JdbcRepository { public InstrumentTypeEntity delete(InstrumentTypeEntity entity) { super.delete(InstrumentTypeEntity.TABLE_NAME, entity.getId()); return entity; } InstrumentTypeJdbcRepository(NamedParameterJdbcTemplate namedParameterJdbcTemplate, JdbcTemplate jdbcTemplate); InstrumentTypeEntity create(InstrumentTypeEntity entity); InstrumentTypeEntity update(InstrumentTypeEntity entity); InstrumentTypeEntity delete(InstrumentTypeEntity entity); Pagination<InstrumentType> search(InstrumentTypeSearch domain); InstrumentTypeEntity findById(InstrumentTypeEntity entity);  }