introduce-booking-project-and-nested-booking-items #57
@ -162,10 +162,10 @@ public class HsBookingItemEntity implements Stringifyable, RbacObject, Validatab
|
||||
|
||||
public static RbacView rbac() {
|
||||
return rbacViewFor("bookingItem", HsBookingItemEntity.class)
|
||||
.withIdentityView(SQL.projection("caption")) // FIXME: cleanIdentifier(...)?
|
||||
.withIdentityView(SQL.projection("caption"))
|
||||
.withRestrictedViewOrderBy(SQL.expression("validity"))
|
||||
.withUpdatableColumns("version", "caption", "validity", "resources")
|
||||
.toRole("global", ADMIN).grantPermission(INSERT) // FIXME: Why is this necessary to insert test data?
|
||||
.toRole("global", ADMIN).grantPermission(INSERT) // TODO.impl: Why is this necessary to insert test data?
|
||||
.toRole("global", ADMIN).grantPermission(DELETE)
|
||||
|
||||
.importEntityAlias("project", HsBookingProjectEntity.class, usingDefaultCase(),
|
||||
|
@ -136,7 +136,7 @@ public class HsHostingAssetEntity implements Stringifyable, RbacObject, Validata
|
||||
.withIdentityView(SQL.projection("identifier"))
|
||||
.withRestrictedViewOrderBy(SQL.expression("identifier"))
|
||||
.withUpdatableColumns("version", "caption", "config")
|
||||
.toRole(GLOBAL, ADMIN).grantPermission(INSERT) // FIXME: Why is this necessary to insert test data?
|
||||
.toRole(GLOBAL, ADMIN).grantPermission(INSERT) // TODO.impl: Why is this necessary to insert test data?
|
||||
|
||||
.importEntityAlias("bookingItem", HsBookingItemEntity.class, usingDefaultCase(),
|
||||
dependsOnColumn("bookingItemUuid"),
|
||||
|
@ -178,7 +178,6 @@ class HsHostingAssetRepositoryIntegrationTest extends ContextBasedTestWithCleanu
|
||||
public void normalUser_canViewOnlyRelatedAsset() {
|
||||
// given:
|
||||
context("person-FirbySusan@example.com");
|
||||
// context("superuser-alex@hostsharing.net"); // FIXME
|
||||
final var projectUuid = projectRepo.findAll().stream()
|
||||
.filter(p -> p.getCaption().equals("D-1000111 default project"))
|
||||
.findAny().orElseThrow().getUuid();
|
||||
|
@ -623,6 +623,7 @@ public class ImportOfficeData extends ContextBasedTest {
|
||||
context(rbacSuperuser);
|
||||
em.createNativeQuery("delete from hs_hosting_asset where true").executeUpdate();
|
||||
em.createNativeQuery("delete from hs_booking_item where true").executeUpdate();
|
||||
em.createNativeQuery("delete from hs_booking_project where true").executeUpdate();
|
||||
em.createNativeQuery("delete from hs_office_coopassetstransaction where true").executeUpdate();
|
||||
em.createNativeQuery("delete from hs_office_coopassetstransaction_legacy_id where true").executeUpdate();
|
||||
em.createNativeQuery("delete from hs_office_coopsharestransaction where true").executeUpdate();
|
||||
|
Loading…
Reference in New Issue
Block a user