Certificates

Business rules for certificates.

class certificates.business_rules.CE2(transaction=None)[source]

The combination of certificate type and code must be unique.

exception Violation(model: common.models.trackedmodel.TrackedModel, message: Optional[str] = None)

The combination of certificate type and code must be unique.

class certificates.business_rules.CE4(transaction=None)[source]

If a certificate is used in a measure condition then the validity periods of the certificate must span the validity period of the measure.

exception Violation(model: common.models.trackedmodel.TrackedModel, message: Optional[str] = None)

If a certificate is used in a measure condition then the validity periods of the certificate must span the validity period of the measure.

class certificates.business_rules.CE5(transaction=None)[source]

The certificate cannot be deleted if it is used in a measure condition.

exception Violation(model: common.models.trackedmodel.TrackedModel, message: Optional[str] = None)

The certificate cannot be deleted if it is used in a measure condition.

class certificates.business_rules.CE6(transaction=None)[source]

At least one description record is mandatory.

The start date of the first description period must be equal to the start date of the certificate. No two associated description periods for the same certificate and language may have the same start date. The validity period of the certificate must span the validity period of the certificate description.

exception Violation(model: common.models.trackedmodel.TrackedModel, message: Optional[str] = None)

At least one description record is mandatory.

The start date of the first description period must be equal to the start date of the certificate. No two associated description periods for the same certificate and language may have the same start date. The validity period of the certificate must span the validity period of the certificate description.

class certificates.business_rules.CE7(transaction=None)[source]

The validity period of the certificate type must span the validity period of the certificate.

exception Violation(model: common.models.trackedmodel.TrackedModel, message: Optional[str] = None)

The validity period of the certificate type must span the validity period of the certificate.

class certificates.business_rules.CET1(transaction=None)[source]

The type of the certificate must be unique.

exception Violation(model: common.models.trackedmodel.TrackedModel, message: Optional[str] = None)

The type of the certificate must be unique.

class certificates.business_rules.CET2(transaction=None)[source]

The certificate type cannot be deleted if it is used in a certificate.

exception Violation(model: common.models.trackedmodel.TrackedModel, message: Optional[str] = None)

The certificate type cannot be deleted if it is used in a certificate.