|
@@ -1,9 +1,11 @@
|
|
|
package com.miniframe.tools.file;
|
|
|
|
|
|
+import com.google.gson.Gson;
|
|
|
import com.miniframe.core.ext.UtilTools;
|
|
|
import com.miniframe.model.mdo.MdoProComval;
|
|
|
import com.miniframe.model.mdo.MdoProComvalSQLBuilder;
|
|
|
import com.miniframe.model.mdo.dao.MdoProComvalMapper;
|
|
|
+import com.miniframe.websocket.WebsocketEndPoint;
|
|
|
import org.apache.commons.io.monitor.FileAlterationListenerAdaptor;
|
|
|
|
|
|
import java.io.*;
|
|
@@ -56,6 +58,11 @@ public class SurromdaoFileListener extends FileAlterationListenerAdaptor {
|
|
|
comval.setVars(line1);
|
|
|
comval.setVals(tvals);
|
|
|
comvalDao.insert(comval);
|
|
|
+
|
|
|
+ WebsocketEndPoint webs = (WebsocketEndPoint) UtilTools.getBean("websocketEndPoint");
|
|
|
+ Gson gson = new Gson();
|
|
|
+ webs.sendMessageToUser(String.valueOf(pid),gson.toJson(comval));
|
|
|
+
|
|
|
}
|
|
|
i++;
|
|
|
|