Fixed alert behavior
git-svn-id: https://svn.d4science.research-infrastructures.eu/gcube/trunk/portlets/user/tabular-data-column-widget@111652 82a268e6-3cf1-43bd-a215-b396298e98cf
This commit is contained in:
parent
f8963de3af
commit
28f2cefd80
|
@ -263,15 +263,18 @@ public class CreateDefColumnPanel extends FramedPanel {
|
||||||
+ ", locale: " + localeElement + ", default: " + valueDefault);
|
+ ", locale: " + localeElement + ", default: " + valueDefault);
|
||||||
if (lab == null || lab.isEmpty()) {
|
if (lab == null || lab.isEmpty()) {
|
||||||
UtilsGXT3.alert("Attention", "Add a label");
|
UtilsGXT3.alert("Attention", "Add a label");
|
||||||
|
btnSave.enable();
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (typeElement == null) {
|
if (typeElement == null) {
|
||||||
UtilsGXT3.alert("Attention", "No type selected");
|
UtilsGXT3.alert("Attention", "No type selected");
|
||||||
|
btnSave.enable();
|
||||||
return;
|
return;
|
||||||
} else {
|
} else {
|
||||||
if (typeElement.getCode() == null) {
|
if (typeElement.getCode() == null) {
|
||||||
UtilsGXT3.alert("Attention", "No type selected");
|
UtilsGXT3.alert("Attention", "No type selected");
|
||||||
|
btnSave.enable();
|
||||||
return;
|
return;
|
||||||
} else {
|
} else {
|
||||||
currentType = typeElement.getCode();
|
currentType = typeElement.getCode();
|
||||||
|
@ -280,11 +283,13 @@ public class CreateDefColumnPanel extends FramedPanel {
|
||||||
if (currentType != null && currentType == ColumnTypeCode.CODENAME) {
|
if (currentType != null && currentType == ColumnTypeCode.CODENAME) {
|
||||||
if (localeElement == null) {
|
if (localeElement == null) {
|
||||||
UtilsGXT3.alert("Attention", "No locale selected");
|
UtilsGXT3.alert("Attention", "No locale selected");
|
||||||
|
btnSave.enable();
|
||||||
return;
|
return;
|
||||||
} else {
|
} else {
|
||||||
if (localeElement.getLocaleName() == null
|
if (localeElement.getLocaleName() == null
|
||||||
|| localeElement.getLocaleName().isEmpty()) {
|
|| localeElement.getLocaleName().isEmpty()) {
|
||||||
UtilsGXT3.alert("Attention", "No locale selected");
|
UtilsGXT3.alert("Attention", "No locale selected");
|
||||||
|
btnSave.enable();
|
||||||
return;
|
return;
|
||||||
} else {
|
} else {
|
||||||
localeName = localeElement.getLocaleName();
|
localeName = localeElement.getLocaleName();
|
||||||
|
|
Loading…
Reference in New Issue