Merge "Omaha #5335 Add alert popup when TAF send fails" into omaha_16.2.2
Former-commit-id: a31f348ff22dcab6d1b652c06c4cb38ec189c8d3
This commit is contained in:
commit
38e3c36653
1 changed files with 9 additions and 3 deletions
|
@ -88,7 +88,8 @@ import com.raytheon.viz.ui.dialogs.CaveSWTDialog;
|
||||||
* 20May2015 4510 rferrel Added {@link #getForecasterId()}.
|
* 20May2015 4510 rferrel Added {@link #getForecasterId()}.
|
||||||
* Sep 25, 2015 4918 rferrel Allow selection of forecaster to send a TAF.
|
* Sep 25, 2015 4918 rferrel Allow selection of forecaster to send a TAF.
|
||||||
* Nov 06, 2015 5108 rferrel Display warning when forecast xmittime will result in a
|
* Nov 06, 2015 5108 rferrel Display warning when forecast xmittime will result in a
|
||||||
* header time the same as any existing pending forecast.
|
* header time the same as any existing pending forecast.
|
||||||
|
* Feb 12, 2016 5335 tgurney Add alert popup when TAF send fails
|
||||||
*
|
*
|
||||||
* </pre>
|
* </pre>
|
||||||
*
|
*
|
||||||
|
@ -337,6 +338,9 @@ public class SendDialog extends CaveSWTDialog {
|
||||||
configMgr.setDefaultFontAndColors(repsonsibleLbl);
|
configMgr.setDefaultFontAndColors(repsonsibleLbl);
|
||||||
|
|
||||||
List<ForecasterConfig> forecasters = getForecasters();
|
List<ForecasterConfig> forecasters = getForecasters();
|
||||||
|
if (forecasters == null) {
|
||||||
|
forecasters = new ArrayList<ForecasterConfig>();
|
||||||
|
}
|
||||||
String forecaster = AviationDialog.getForecaster();
|
String forecaster = AviationDialog.getForecaster();
|
||||||
gd = new GridData(SWT.CENTER, SWT.DEFAULT, false, false);
|
gd = new GridData(SWT.CENTER, SWT.DEFAULT, false, false);
|
||||||
gd.minimumWidth = 100;
|
gd.minimumWidth = 100;
|
||||||
|
@ -454,6 +458,8 @@ public class SendDialog extends CaveSWTDialog {
|
||||||
.getSelectionIndex());
|
.getSelectionIndex());
|
||||||
forecasterId = selString.split("\\s+")[1];
|
forecasterId = selString.split("\\s+")[1];
|
||||||
} catch (IllegalArgumentException ex) {
|
} catch (IllegalArgumentException ex) {
|
||||||
|
String msg = "Cannot send the TAF. No forecaster is selected.";
|
||||||
|
statusHandler.handle(Priority.SIGNIFICANT, msg, ex);
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -673,7 +679,7 @@ public class SendDialog extends CaveSWTDialog {
|
||||||
|
|
||||||
File f = AvnConfigFileUtil.getStaticFile(FORECAST_CONFIG_FILE);
|
File f = AvnConfigFileUtil.getStaticFile(FORECAST_CONFIG_FILE);
|
||||||
if (f == null) {
|
if (f == null) {
|
||||||
statusHandler.handle(Priority.PROBLEM,
|
statusHandler.handle(Priority.SIGNIFICANT,
|
||||||
"Cannot send the TAF. Unable to load, "
|
"Cannot send the TAF. Unable to load, "
|
||||||
+ FORECAST_CONFIG_FILE
|
+ FORECAST_CONFIG_FILE
|
||||||
+ ", unable to obtain forecaster's ID. ");
|
+ ", unable to obtain forecaster's ID. ");
|
||||||
|
@ -683,7 +689,7 @@ public class SendDialog extends CaveSWTDialog {
|
||||||
forecasters = JAXB.unmarshal(f, AviationForecasterConfig.class)
|
forecasters = JAXB.unmarshal(f, AviationForecasterConfig.class)
|
||||||
.getForecasterConfig();
|
.getForecasterConfig();
|
||||||
} catch (RuntimeException ex) {
|
} catch (RuntimeException ex) {
|
||||||
statusHandler.handle(Priority.PROBLEM,
|
statusHandler.handle(Priority.SIGNIFICANT,
|
||||||
"Cannot send the TAF. Unable to parse, "
|
"Cannot send the TAF. Unable to parse, "
|
||||||
+ FORECAST_CONFIG_FILE
|
+ FORECAST_CONFIG_FILE
|
||||||
+ ", unable to obtain forecaster's ID. ", ex);
|
+ ", unable to obtain forecaster's ID. ", ex);
|
||||||
|
|
Loading…
Add table
Reference in a new issue