Search in sources :

Example 1 with TitleBuffer

use of org.apache.isis.applib.util.TitleBuffer in project estatio by estatio.

the class Order method title.

public String title() {
    final TitleBuffer buf = new TitleBuffer();
    final Optional<Document> document = lookupAttachedPdfService.lookupOrderPdfFrom(this);
    document.ifPresent(d -> buf.append(d.getName()));
    final Party seller = getSeller();
    if (seller != null) {
        buf.append(": ", seller);
    }
    final String orderNumber = getOrderNumber();
    if (orderNumber != null) {
        buf.append(", ", orderNumber);
    }
    return buf.toString();
}
Also used : Party(org.estatio.module.party.dom.Party) TitleBuffer(org.apache.isis.applib.util.TitleBuffer) Document(org.incode.module.document.dom.impl.docs.Document)

Example 2 with TitleBuffer

use of org.apache.isis.applib.util.TitleBuffer in project estatio by estatio.

the class IncomingInvoice method title.

public String title() {
    final TitleBuffer buf = new TitleBuffer();
    final Optional<Document> document = lookupAttachedPdfService.lookupIncomingInvoicePdfFrom(this);
    document.ifPresent(d -> buf.append(d.getName()));
    final Party seller = getSeller();
    if (seller != null) {
        buf.append(": ", seller);
    }
    final String invoiceNumber = getInvoiceNumber();
    if (invoiceNumber != null) {
        buf.append(", ", invoiceNumber);
    }
    return buf.toString();
}
Also used : Party(org.estatio.module.party.dom.Party) TitleBuffer(org.apache.isis.applib.util.TitleBuffer) Document(org.incode.module.document.dom.impl.docs.Document)

Example 3 with TitleBuffer

use of org.apache.isis.applib.util.TitleBuffer in project estatio by estatio.

the class InvoiceCalculationParameters method toString.

public String toString() {
    TitleBuffer tb = new TitleBuffer();
    tb.append(" -", property().getReference()).append(" -", leasesToReferences()).append(" -", leaseItemTypes()).append(" -", invoiceDueDate()).append(" -", new LocalDateInterval(startDueDate, nextDueDate, IntervalEnding.EXCLUDING_END_DATE)).toString();
    return tb.toString();
}
Also used : TitleBuffer(org.apache.isis.applib.util.TitleBuffer) LocalDateInterval(org.incode.module.base.dom.valuetypes.LocalDateInterval)

Example 4 with TitleBuffer

use of org.apache.isis.applib.util.TitleBuffer in project estatio by estatio.

the class Person method change.

public Person change(final PersonGenderType gender, @Parameter(optionality = Optionality.OPTIONAL, regexPattern = InitialsType.Meta.REGEX, regexPatternReplacement = InitialsType.Meta.REGEX_DESCRIPTION) final String initials, final String firstName, final String lastName) {
    setGender(gender);
    setInitials(initials);
    setFirstName(firstName);
    setLastName(lastName);
    TitleBuffer tb = new TitleBuffer();
    setName(tb.append(getLastName()).append(",", getFirstName()).toString());
    return this;
}
Also used : TitleBuffer(org.apache.isis.applib.util.TitleBuffer)

Aggregations

TitleBuffer (org.apache.isis.applib.util.TitleBuffer)4 Party (org.estatio.module.party.dom.Party)2 Document (org.incode.module.document.dom.impl.docs.Document)2 LocalDateInterval (org.incode.module.base.dom.valuetypes.LocalDateInterval)1