package com.hr.service.impl;
import com.hjsoft.SynClient;
import com.hr.service.util.DBUtil;
import com.hr.service.util.PersonValue;
import com.hr.service.util.StringHandle;
import java.io.PrintStream;
import java.io.StringReader;
import java.sql.Connection;
import java.sql.Date;
import java.sql.ResultSet;
import java.sql.Statement;
import java.util.List;
import org.jdom.Document;
import org.jdom.Element;
import org.jdom.input.SAXBuilder;
public class HrEmpJobTransfer extends SqlServerImpl {
SqlServerImpl sqlserver = new SqlServerImpl();
public String JobTransfer(String resultXml) {
resultXml = resultXml.replace(" ", "");
resultXml = resultXml.replace("<br>", "");
String resultId = "1";
Document document = null;
Connection dbCon = null;
SAXBuilder builder = new SAXBuilder();
try {
document = builder.build(new StringReader(resultXml));
Element root = document.getRootElement();
List childList = root.getChildren();
for (int i = 0; i < childList.size(); i++) {
Element childInfo = (Element) childList.get(i);
String gh = childInfo.getChild("gh").getText();
String zt = childInfo.getChild("zt").getText();
String bm = childInfo.getChild("bm").getText();
String preNo = "";
if ((bm != null) && (!"".equals(bm.trim()))) {
char[] nos = bm.trim().toCharArray();
for (int j = 0; (j < 4) && (nos.length > 4); j++) {
preNo = preNo + nos[j];
}
}
String xgw = childInfo.getChild("xgw").getText();
String zjsj = childInfo.getChild("zjsj").getText();
Date rzrq = this.sqlserver.getStringToDate(childInfo.getChild(
"rzrq").getText());
String zglx = childInfo.getChild("zglx").getText();
Date zrsj = this.sqlserver.getStringToDate(childInfo.getChild(
"zrsj").getText());
Date sqrq = this.sqlserver.getStringToDate(childInfo.getChild(
"sqrq").getText());
String zrbm1 = childInfo.getChild("zrbm1").getText();
String zrgw1 = childInfo.getChild("zrgw1").getText();
String yggxzrbmsj = childInfo.getChild("yggxzrbmsj").getText();
String gzms = childInfo.getChild("gzms").getText();
String gzpj = childInfo.getChild("gzpj").getText();
String yggxyj = childInfo.getChild("yggxyj").getText();
String yrbmyj = childInfo.getChild("yrbmyj").getText();
String kfzxyj = childInfo.getChild("kfzxyj").getText();
double jbgz = Double.parseDouble(childInfo.getChild("jbgz")
.getText());
double gwjt = Double.parseDouble(childInfo.getChild("gwjt")
.getText());
double zwjt = Double.parseDouble(childInfo.getChild("zwjt")
.getText());
double rzjlydjx = Double.parseDouble(childInfo.getChild(
"rzjlydjx").getText());
double rzjljdjx = Double.parseDouble(childInfo.getChild(