This commit is contained in:
sjvans
2022-02-03 17:57:35 +01:00
parent ea0773071e
commit 6928ae907a
24 changed files with 1006 additions and 164 deletions

29
gdpr/db/schema.cds Normal file
View File

@@ -0,0 +1,29 @@
using {
Country,
managed,
cuid
} from '@sap/cds/common';
using {sap.capire.orders} from '@capire/orders';
namespace sap.capire.gdpr;
extend orders.Orders with {
customer : Association to Customers;
}
entity Customers : cuid, managed {
email : String;
firstName : String;
lastName : String;
creditCardNo : String;
dateOfBirth : Date;
addresses : Composition of many CustomerPostalAddresses
on addresses.customer = $self;
}
entity CustomerPostalAddresses : cuid, managed {
customer : Association to Customers;
street : String(128);
town : String(128);
country : Country;
};