use of de.metas.ui.web.window.descriptor.DocumentFieldDescriptor.Builder in project metasfresh-webui-api by metasfresh.
the class OrderLineQuickInputDescriptorFactory method createProductFieldBuilder.
private Builder createProductFieldBuilder(@NonNull final Optional<Boolean> soTrx) {
final ProductLookupDescriptor productLookupDescriptor = createProductLookupDescriptor(soTrx);
final ITranslatableString caption = Services.get(IMsgBL.class).translatable(IOrderLineQuickInput.COLUMNNAME_M_Product_ID);
final Builder productFieldBuilder = DocumentFieldDescriptor.builder(IOrderLineQuickInput.COLUMNNAME_M_Product_ID).setLookupDescriptorProvider(productLookupDescriptor).setCaption(caption).setWidgetType(DocumentFieldWidgetType.Lookup).setReadonlyLogic(ConstantLogicExpression.FALSE).setAlwaysUpdateable(true).setMandatoryLogic(ConstantLogicExpression.TRUE).setDisplayLogic(ConstantLogicExpression.TRUE).addCallout(OrderLineQuickInputDescriptorFactory::onProductChangedCallout).addCharacteristic(Characteristic.PublicField);
return productFieldBuilder;
}
Aggregations