LAPTOP-5NTQJPUS\LT 1 year ago
parent
commit
5886128ed9
1 changed files with 8 additions and 10 deletions
  1. 8 10
      DataFusion/src/com/zskk/control/ViewController.java

+ 8 - 10
DataFusion/src/com/zskk/control/ViewController.java

@@ -120,16 +120,14 @@ public class ViewController extends Controller {
 		
         String fileName2String ="";
         try {
-//		 List<String> files = new ArrayList<String>();
-//	        File file = new File("/home/zskk/CFIND_XML");
-//	        File[] tempList = file.listFiles();
-//	        for (int m = 0; m < tempList.length; m++) {
-//	            if (tempList[m].isFile()) {
-//	                files.add(tempList[m].toString());
-//	                //文件名,不包含路径
-//	                String fileName = tempList[m].getName();
-//	               fileName2String = fileName2String+fileName+"**";
-	               File fin_floder = new File("/home/zskk/CFIND_XML/STUDYUID_2o2112131.xml");
+        	String dateString = this.getPara("dateStr");
+    		String fileString = dateString.replace("0", "o");
+    		String execCmd = ExecUtil.execCmd("/zskk_system/other/cfind.sh " + dateString + " STUDYUID_" + fileString + ".xml");
+    		if (execCmd.contains("Connection refused")) {
+    			return;
+    		}
+//	               File fin_floder = new File("/home/zskk/CFIND_XML/STUDYUID_tm1.xml");
+	               File fin_floder = new File("/home/zskk/CFIND_XML/STUDYUID_" + fileString + "1.xml");
 	       		// 创建从文件读取数据的FileInputStream流
 	       		FileInputStream fin;