mirror of
https://gitee.com/jmix/cuba.git
synced 2024-12-04 20:28:00 +08:00
PL-1202 Разработать механизм работы с динамическими атрибутами
Fix required message #PL-1202
This commit is contained in:
parent
beead50830
commit
7ad1cacf95
@ -316,7 +316,7 @@ public class RuntimePropertiesFrame extends AbstractWindow {
|
||||
String requiredMessage = messages.formatMessage(
|
||||
AppConfig.getMessagesPack(),
|
||||
"validation.required.defaultMsg",
|
||||
field.getId()
|
||||
categoryAttributeValue.getCategoryAttribute().getName()
|
||||
);
|
||||
fieldGroup.setRequired(field, categoryAttributeValue.getCategoryAttribute().getRequired() && requiredControlEnabled, requiredMessage);
|
||||
}
|
||||
|
@ -187,6 +187,10 @@ public class FieldGroupLoader extends AbstractFieldLoader {
|
||||
field.setCaption(attribute.getName());
|
||||
field.setDatasource(ds);
|
||||
field.setRequired(attribute.getRequired());
|
||||
field.setRequiredError( messages.formatMessage(
|
||||
messages.getMainMessagePack(),
|
||||
"validation.required.defaultMsg",
|
||||
attribute.getName()));
|
||||
|
||||
if (fieldGroup.getWidth() > 0) {
|
||||
field.setWidth("100%");
|
||||
|
Loading…
Reference in New Issue
Block a user