|
|
@ -61,6 +61,8 @@ import java.io.ByteArrayInputStream; |
|
|
|
import java.io.IOException; |
|
|
|
import java.io.IOException; |
|
|
|
import java.io.InputStream; |
|
|
|
import java.io.InputStream; |
|
|
|
import java.io.InputStreamReader; |
|
|
|
import java.io.InputStreamReader; |
|
|
|
|
|
|
|
import java.net.MalformedURLException; |
|
|
|
|
|
|
|
import java.net.URL; |
|
|
|
import java.util.ArrayList; |
|
|
|
import java.util.ArrayList; |
|
|
|
import java.util.List; |
|
|
|
import java.util.List; |
|
|
|
|
|
|
|
|
|
|
@ -205,7 +207,7 @@ public class FileTableDataPane extends AbstractTableDataPane<FileTableData> { |
|
|
|
|
|
|
|
|
|
|
|
private ActionListener testConnectionListener = new ActionListener() { |
|
|
|
private ActionListener testConnectionListener = new ActionListener() { |
|
|
|
public void actionPerformed(ActionEvent arg0) { |
|
|
|
public void actionPerformed(ActionEvent arg0) { |
|
|
|
String uri = urlText.getText(); |
|
|
|
String uri = ParameterHelper.analyze4Templatee( urlText.getText(), params); |
|
|
|
if (!checkURL(uri)) { |
|
|
|
if (!checkURL(uri)) { |
|
|
|
JOptionPane.showMessageDialog(SwingUtilities.getWindowAncestor(FileTableDataPane.this), Inter.getLocText("FR-Designer_Add_JS_warning")); |
|
|
|
JOptionPane.showMessageDialog(SwingUtilities.getWindowAncestor(FileTableDataPane.this), Inter.getLocText("FR-Designer_Add_JS_warning")); |
|
|
|
return; |
|
|
|
return; |
|
|
@ -318,7 +320,13 @@ public class FileTableDataPane extends AbstractTableDataPane<FileTableData> { |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
private boolean checkURL(String uri){ |
|
|
|
private boolean checkURL(String uri){ |
|
|
|
return (uri.matches("https*://.+|\\$\\{.+\\}.*")); |
|
|
|
try { |
|
|
|
|
|
|
|
new URL(uri); |
|
|
|
|
|
|
|
return true; |
|
|
|
|
|
|
|
} catch (MalformedURLException e) { |
|
|
|
|
|
|
|
return false; |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
// return (uri.matches("https*://.+|\\$\\{.+\\}.*"));
|
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
private JPanel textSetPanel(int width,int height) { |
|
|
|
private JPanel textSetPanel(int width,int height) { |
|
|
|